summaryrefslogtreecommitdiffstats
path: root/LGPL
diff options
context:
space:
mode:
authorColin Guthrie <cguthrie@mandriva.org>2009-09-20 17:29:38 +0100
committerColin Guthrie <cguthrie@mandriva.org>2009-10-01 09:08:30 +0100
commited8af7c8fd7bf845a243518357b6b73667d209c0 (patch)
treef42c187eeb5fbc02c955b61cb0f3ddcdf85bcc7e /LGPL
parentfaae33d808480a34f02bea6e66ba0da0523694cf (diff)
device-manager: Rough framework (slots etc.) for handling routing.
This is incomplete, it just adds the slots in question and assigns noops to them. Some minor cleanup of types. Due to the priority of the hooks, it seems we can actually coexist with module-stream restore so the code to detect and unload it will be removed shortly.
Diffstat (limited to 'LGPL')
0 files changed, 0 insertions, 0 deletions
de'>-rw-r--r--doxygen/doxygen.conf.in2
-rwxr-xr-xgit-version-gen50
-rw-r--r--libpulse-browse.pc.in12
-rw-r--r--libpulse-mainloop-glib.pc.in2
-rw-r--r--libpulse-simple.pc.in2
-rw-r--r--libpulse.pc.in2
-rw-r--r--m4/acx_lirc.m46
-rw-r--r--m4/acx_pthread.m4348
-rw-r--r--m4/attributes.m4258
-rw-r--r--m4/ax_check_define.m492
-rw-r--r--m4/ax_check_flag.m4147
-rw-r--r--m4/ax_define_dir.m449
-rw-r--r--m4/ax_pthread.m4302
-rw-r--r--m4/ax_tls.m476
-rw-r--r--m4/check_define.m413
-rw-r--r--m4/orc.m469
-rw-r--r--m4/shave.m477
-rw-r--r--m4/tls.m417
-rw-r--r--man/Makefile.am54
-rw-r--r--man/default.pa.5.xml.in4
-rw-r--r--man/pabrowse.1.xml.in47
-rw-r--r--man/pacat.1.xml.in96
-rw-r--r--man/pactl.1.xml.in6
-rw-r--r--man/pax11publish.1.xml.in2
-rw-r--r--man/pulse-client.conf.5.xml.in27
-rw-r--r--man/pulse-daemon.conf.5.xml.in193
-rw-r--r--man/pulseaudio.1.xml.in6
-rw-r--r--orc.mak46
-rw-r--r--po/LINGUAS12
-rw-r--r--po/POTFILES.in28
-rw-r--r--po/POTFILES.skip2
-rw-r--r--po/as.po2048
-rw-r--r--po/bn_IN.po1944
-rw-r--r--po/ca.po2329
-rw-r--r--po/cs.po2564
-rw-r--r--po/de.po2058
-rw-r--r--po/de_CH.po2102
-rw-r--r--po/el.po1735
-rw-r--r--po/es.po2099
-rw-r--r--po/fi.po2110
-rw-r--r--po/fr.po2391
-rw-r--r--po/gu.po1913
-rw-r--r--po/he.po2357
-rw-r--r--po/hi.po2691
-rw-r--r--po/hu.po2652
-rw-r--r--po/it.po1943
-rw-r--r--po/ja.po2697
-rw-r--r--po/kn.po1851
-rw-r--r--po/ml.po2682
-rw-r--r--po/mr.po1853
-rw-r--r--po/nl.po2335
-rw-r--r--po/or.po1905
-rw-r--r--po/pa.po2395
-rw-r--r--po/pl.po1965
-rw-r--r--po/pt.po2884
-rw-r--r--po/pt_BR.po2528
-rw-r--r--po/ru.po2700
-rw-r--r--po/sr.po1952
-rw-r--r--po/sr@latin.po1954
-rw-r--r--po/sv.po1746
-rw-r--r--po/ta.po1876
-rw-r--r--po/te.po1829
-rw-r--r--po/uk.po1870
-rw-r--r--po/zh_CN.po1841
-rw-r--r--po/zh_TW.po2367
-rw-r--r--shave-libtool.in69
-rw-r--r--shave.in79
-rw-r--r--src/.gitignore9
-rw-r--r--src/Makefile.am1215
-rw-r--r--src/daemon/.gitignore1
l---------src/daemon/Makefile1
-rw-r--r--src/daemon/caps.c113
-rw-r--r--src/daemon/caps.h3
-rw-r--r--src/daemon/cmdline.c23
-rw-r--r--src/daemon/cpulimit.c16
-rw-r--r--src/daemon/daemon-conf.c160
-rw-r--r--src/daemon/daemon-conf.h9
-rw-r--r--src/daemon/daemon.conf.in33
-rwxr-xr-xsrc/daemon/default.pa.in59
-rw-r--r--src/daemon/default.pa.win3243
-rw-r--r--src/daemon/dumpmodules.c3
-rwxr-xr-xsrc/daemon/esdcompat.in2
-rw-r--r--src/daemon/ltdl-bind-now.c4
-rw-r--r--src/daemon/main.c606
-rw-r--r--src/daemon/org.pulseaudio.policy.in50
-rw-r--r--src/daemon/polkit.c172
-rw-r--r--src/daemon/pulseaudio-kde.desktop.in11
-rw-r--r--src/daemon/pulseaudio-system.conf37
-rw-r--r--src/daemon/server-lookup.c522
-rw-r--r--src/daemon/server-lookup.h40
-rwxr-xr-xsrc/daemon/start-pulseaudio-kde.in30
-rwxr-xr-xsrc/daemon/start-pulseaudio-x11.in2
-rwxr-xr-xsrc/daemon/system.pa.in9
-rw-r--r--src/map-file60
-rw-r--r--src/modules/.gitignore1
l---------src/modules/Makefile1
l---------src/modules/alsa/Makefile1
-rw-r--r--src/modules/alsa/alsa-mixer.c4194
-rw-r--r--src/modules/alsa/alsa-mixer.h328
-rw-r--r--src/modules/alsa/alsa-sink.c1177
-rw-r--r--src/modules/alsa/alsa-sink.h2
-rw-r--r--src/modules/alsa/alsa-source.c1120
-rw-r--r--src/modules/alsa/alsa-source.h2
-rw-r--r--src/modules/alsa/alsa-util.c1416
-rw-r--r--src/modules/alsa/alsa-util.h127
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-aux.conf66
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-dock-mic.conf81
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-fm.conf66
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-front-mic.conf81
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-internal-mic.conf111
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-linein.conf93
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-mic-line.conf67
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-mic.conf104
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-mic.conf.common54
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-rear-mic.conf81
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-tvtuner.conf66
-rw-r--r--src/modules/alsa/mixer/paths/analog-input-video.conf65
-rw-r--r--src/modules/alsa/mixer/paths/analog-input.conf83
-rw-r--r--src/modules/alsa/mixer/paths/analog-input.conf.common290
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-desktop-speaker.conf99
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-headphones-2.conf87
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-headphones.conf87
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-lfe-on-mono.conf89
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-mono.conf86
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-speaker.conf99
-rw-r--r--src/modules/alsa/mixer/paths/analog-output.conf96
-rw-r--r--src/modules/alsa/mixer/paths/analog-output.conf.common147
-rw-r--r--src/modules/alsa/mixer/paths/iec958-stereo-output.conf19
-rw-r--r--src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules40
-rw-r--r--src/modules/alsa/mixer/profile-sets/default.conf180
-rw-r--r--src/modules/alsa/mixer/profile-sets/maudio-fasttrack-pro.conf85
-rw-r--r--src/modules/alsa/mixer/profile-sets/native-instruments-audio4dj.conf91
-rw-r--r--src/modules/alsa/mixer/profile-sets/native-instruments-audio8dj.conf162
-rw-r--r--src/modules/alsa/mixer/profile-sets/native-instruments-korecontroller.conf85
-rw-r--r--src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio10.conf131
-rw-r--r--src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio6.conf92
-rw-r--r--src/modules/alsa/mixer/profile-sets/native-instruments-traktorkontrol-s4.conf81
-rw-r--r--src/modules/alsa/mixer/profile-sets/usb-headset.conf35
-rw-r--r--src/modules/alsa/mixer/samples/ATI IXP--Realtek ALC655 rev 0150
-rw-r--r--src/modules/alsa/mixer/samples/Brooktree Bt878--Bt87x24
-rw-r--r--src/modules/alsa/mixer/samples/Ensoniq AudioPCI--Cirrus Logic CS4297A rev 3135
-rw-r--r--src/modules/alsa/mixer/samples/HDA ATI HDMI--ATI R6xx HDMI4
-rw-r--r--src/modules/alsa/mixer/samples/HDA Intel--Analog Devices AD198162
-rw-r--r--src/modules/alsa/mixer/samples/HDA Intel--Realtek ALC889A113
-rw-r--r--src/modules/alsa/mixer/samples/Intel 82801CA-ICH3--Analog Devices AD1881A128
-rw-r--r--src/modules/alsa/mixer/samples/Logitech USB Speaker--USB Mixer27
-rw-r--r--src/modules/alsa/mixer/samples/USB Audio--USB Mixer37
-rw-r--r--src/modules/alsa/mixer/samples/USB Device 0x46d:0x9a4--USB Mixer5
-rw-r--r--src/modules/alsa/mixer/samples/VIA 8237--Analog Devices AD1888211
-rw-r--r--src/modules/alsa/mixer/samples/VIA 8237--C-Media Electronics CMI9761A+160
-rw-r--r--src/modules/alsa/module-alsa-card.c302
-rw-r--r--src/modules/alsa/module-alsa-sink.c21
-rw-r--r--src/modules/alsa/module-alsa-source.c32
l---------src/modules/bluetooth/Makefile1
-rw-r--r--src/modules/bluetooth/a2dp-codecs.h116
-rw-r--r--src/modules/bluetooth/bluetooth-util.c903
-rw-r--r--src/modules/bluetooth/bluetooth-util.h59
-rw-r--r--src/modules/bluetooth/ipc.c8
-rw-r--r--src/modules/bluetooth/ipc.h13
-rw-r--r--src/modules/bluetooth/module-bluetooth-device.c1128
-rw-r--r--src/modules/bluetooth/module-bluetooth-discover.c31
-rw-r--r--src/modules/bluetooth/module-bluetooth-proximity.c16
-rw-r--r--src/modules/bluetooth/rtp.h2
-rw-r--r--src/modules/bluetooth/sbc/sbc.c (renamed from src/modules/bluetooth/sbc.c)194
-rw-r--r--src/modules/bluetooth/sbc/sbc.h (renamed from src/modules/bluetooth/sbc.h)6
-rw-r--r--src/modules/bluetooth/sbc/sbc_math.h (renamed from src/modules/bluetooth/sbc_math.h)5
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives.c (renamed from src/modules/bluetooth/sbc_primitives.c)92
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives.h (renamed from src/modules/bluetooth/sbc_primitives.h)7
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_armv6.c299
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_armv6.h52
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.c304
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.h42
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_mmx.c (renamed from src/modules/bluetooth/sbc_primitives_mmx.c)61
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_mmx.h (renamed from src/modules/bluetooth/sbc_primitives_mmx.h)3
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_neon.c893
-rw-r--r--src/modules/bluetooth/sbc/sbc_primitives_neon.h (renamed from src/modules/bluetooth/sbc_primitives_neon.h)3
-rw-r--r--src/modules/bluetooth/sbc/sbc_tables.h (renamed from src/modules/bluetooth/sbc_tables.h)3
-rw-r--r--src/modules/bluetooth/sbc_primitives_neon.c246
-rw-r--r--src/modules/dbus/iface-card-profile.c228
-rw-r--r--src/modules/dbus/iface-card-profile.h49
-rw-r--r--src/modules/dbus/iface-card.c561
-rw-r--r--src/modules/dbus/iface-card.h45
-rw-r--r--src/modules/dbus/iface-client.c461
-rw-r--r--src/modules/dbus/iface-client.h45
-rw-r--r--src/modules/dbus/iface-core.c2206
-rw-r--r--src/modules/dbus/iface-core.h52
-rw-r--r--src/modules/dbus/iface-device-port.c190
-rw-r--r--src/modules/dbus/iface-device-port.h50
-rw-r--r--src/modules/dbus/iface-device.c1315
-rw-r--r--src/modules/dbus/iface-device.h53
-rw-r--r--src/modules/dbus/iface-memstats.c230
-rw-r--r--src/modules/dbus/iface-memstats.h45
-rw-r--r--src/modules/dbus/iface-module.c336
-rw-r--r--src/modules/dbus/iface-module.h (renamed from src/modules/module-dbus-protocol.c)53
-rw-r--r--src/modules/dbus/iface-sample.c519
-rw-r--r--src/modules/dbus/iface-sample.h45
-rw-r--r--src/modules/dbus/iface-stream.c933
-rw-r--r--src/modules/dbus/iface-stream.h47
-rw-r--r--src/modules/dbus/module-dbus-protocol.c621
-rw-r--r--src/modules/echo-cancel/adrian-aec.c275
-rw-r--r--src/modules/echo-cancel/adrian-aec.h382
-rw-r--r--src/modules/echo-cancel/adrian-aec.orc8
-rw-r--r--src/modules/echo-cancel/adrian-license.txt17
-rw-r--r--src/modules/echo-cancel/adrian.c117
-rw-r--r--src/modules/echo-cancel/adrian.h31
-rw-r--r--src/modules/echo-cancel/echo-cancel.h90
-rw-r--r--src/modules/echo-cancel/module-echo-cancel.c1778
-rw-r--r--src/modules/echo-cancel/speex.c115
l---------src/modules/gconf/Makefile1
-rw-r--r--src/modules/gconf/module-gconf.c11
-rw-r--r--src/modules/hal-util.c2
-rw-r--r--src/modules/jack/module-jack-sink.c36
-rw-r--r--src/modules/jack/module-jack-source.c28
-rw-r--r--src/modules/jack/module-jackdbus-detect.c298
-rw-r--r--src/modules/macosx/module-bonjour-publish.c513
-rw-r--r--src/modules/macosx/module-coreaudio-detect.c285
-rw-r--r--src/modules/macosx/module-coreaudio-device.c876
-rw-r--r--src/modules/module-always-sink.c9
-rw-r--r--src/modules/module-augment-properties.c124
-rw-r--r--src/modules/module-card-restore.c195
-rw-r--r--src/modules/module-cli.c33
-rw-r--r--src/modules/module-combine-sink.c1414
-rw-r--r--src/modules/module-combine.c1233
-rw-r--r--src/modules/module-console-kit.c20
-rw-r--r--src/modules/module-cork-music-on-phone.c32
-rw-r--r--src/modules/module-default-device-restore.c31
-rw-r--r--src/modules/module-detect.c18
-rw-r--r--src/modules/module-device-manager.c1700
-rw-r--r--src/modules/module-device-restore.c703
-rw-r--r--src/modules/module-equalizer-sink.c2221
-rw-r--r--src/modules/module-esound-compat-spawnfd.c1
-rw-r--r--src/modules/module-esound-compat-spawnpid.c2
-rw-r--r--src/modules/module-esound-sink.c36
-rw-r--r--src/modules/module-filter-apply.c600
-rw-r--r--src/modules/module-filter-heuristics.c217
-rw-r--r--src/modules/module-hal-detect-compat.c84
-rw-r--r--src/modules/module-hal-detect.c71
-rw-r--r--src/modules/module-intended-roles.c464
-rw-r--r--src/modules/module-ladspa-sink.c591
-rw-r--r--src/modules/module-lirc.c54
-rw-r--r--src/modules/module-loopback.c857
-rw-r--r--src/modules/module-match.c143
-rw-r--r--src/modules/module-mmkbd-evdev.c71
-rw-r--r--src/modules/module-null-sink.c24
-rw-r--r--src/modules/module-null-source.c288
-rw-r--r--src/modules/module-pipe-sink.c27
-rw-r--r--src/modules/module-pipe-source.c21
-rw-r--r--src/modules/module-position-event-sounds.c77
-rw-r--r--src/modules/module-protocol-stub.c28
-rw-r--r--src/modules/module-remap-sink.c174
-rw-r--r--src/modules/module-rescue-streams.c185
-rw-r--r--src/modules/module-rygel-media-server.c664
-rw-r--r--src/modules/module-sine-source.c22
-rw-r--r--src/modules/module-sine.c6
-rw-r--r--src/modules/module-solaris.c122
-rw-r--r--src/modules/module-stream-restore.c1720
-rw-r--r--src/modules/module-suspend-on-idle.c100
-rw-r--r--src/modules/module-switch-on-connect.c187
-rw-r--r--src/modules/module-tunnel.c221
-rw-r--r--src/modules/module-udev-detect.c809
-rw-r--r--src/modules/module-virtual-sink.c669
-rw-r--r--src/modules/module-virtual-source.c746
-rw-r--r--src/modules/module-volume-restore.c11
-rw-r--r--src/modules/module-waveout.c499
-rw-r--r--src/modules/module-zeroconf-discover.c5
-rw-r--r--src/modules/module-zeroconf-publish.c3
l---------src/modules/oss/Makefile1
-rw-r--r--src/modules/oss/module-oss.c27
-rw-r--r--src/modules/oss/oss-util.c23
-rw-r--r--src/modules/raop/base64.c13
-rw-r--r--src/modules/raop/module-raop-discover.c (renamed from src/modules/module-raop-discover.c)11
-rw-r--r--src/modules/raop/module-raop-sink.c (renamed from src/modules/module-raop-sink.c)40
-rw-r--r--src/modules/raop/raop_client.c47
-rw-r--r--src/modules/raop/raop_client.h2
-rw-r--r--src/modules/reserve-monitor.c256
-rw-r--r--src/modules/reserve-monitor.h71
-rw-r--r--src/modules/reserve-wrap.c159
-rw-r--r--src/modules/reserve-wrap.h9
-rw-r--r--src/modules/reserve.c49
-rw-r--r--src/modules/reserve.h12
l---------src/modules/rtp/Makefile1
-rw-r--r--src/modules/rtp/module-rtp-recv.c155
-rw-r--r--src/modules/rtp/module-rtp-send.c33
-rw-r--r--src/modules/rtp/rtp.c7
-rw-r--r--src/modules/rtp/rtp.h3
-rw-r--r--src/modules/rtp/rtsp_client.c50
-rw-r--r--src/modules/rtp/rtsp_client.h2
-rw-r--r--src/modules/rtp/sap.c3
-rw-r--r--src/modules/rtp/sdp.c2
-rw-r--r--src/modules/udev-util.c173
-rw-r--r--src/modules/udev-util.h5
-rw-r--r--src/modules/x11/module-x11-bell.c4
-rw-r--r--src/modules/x11/module-x11-cork-request.c2
-rw-r--r--src/modules/x11/module-x11-publish.c49
-rw-r--r--src/modules/x11/module-x11-xsmp.c7
-rw-r--r--src/pulse/Makefile13
-rw-r--r--src/pulse/browser.c464
-rw-r--r--src/pulse/browser.h99
-rw-r--r--src/pulse/channelmap.c159
-rw-r--r--src/pulse/channelmap.h46
-rw-r--r--src/pulse/client-conf-x11.c30
-rw-r--r--src/pulse/client-conf.c33
-rw-r--r--src/pulse/client-conf.h5
-rw-r--r--src/pulse/client.conf.in8
-rw-r--r--src/pulse/context.c235
-rw-r--r--src/pulse/context.h34
-rw-r--r--src/pulse/def.h95
-rw-r--r--src/pulse/error.c10
-rw-r--r--src/pulse/error.h1
-rw-r--r--src/pulse/ext-device-manager.c435
-rw-r--r--src/pulse/ext-device-manager.h129
-rw-r--r--src/pulse/ext-device-restore.c346
-rw-r--r--src/pulse/ext-device-restore.h106
-rw-r--r--src/pulse/ext-stream-restore.c24
-rw-r--r--src/pulse/ext-stream-restore.h3
-rw-r--r--src/pulse/format.c461
-rw-r--r--src/pulse/format.h130
-rw-r--r--src/pulse/gccmacro.h4
-rw-r--r--src/pulse/glib-mainloop.c5
-rw-r--r--src/pulse/glib-mainloop.h9
-rw-r--r--src/pulse/i18n.h1
-rw-r--r--src/pulse/internal.h36
-rw-r--r--src/pulse/introspect.c391
-rw-r--r--src/pulse/introspect.h76
-rw-r--r--src/pulse/mainloop-api.c1
-rw-r--r--src/pulse/mainloop-api.h3
-rw-r--r--src/pulse/mainloop-signal.c6
-rw-r--r--src/pulse/mainloop.c284
-rw-r--r--src/pulse/mainloop.h9
-rw-r--r--src/pulse/operation.h6
-rw-r--r--src/pulse/proplist.c35
-rw-r--r--src/pulse/proplist.h57
-rw-r--r--src/pulse/pulseaudio.h17
-rw-r--r--src/pulse/rtclock.c (renamed from src/pulsecore/rtsig.h)27
-rw-r--r--src/pulse/rtclock.h40
-rw-r--r--src/pulse/sample.c56
-rw-r--r--src/pulse/sample.h13
-rw-r--r--src/pulse/scache.c23
-rw-r--r--src/pulse/scache.h9
-rw-r--r--src/pulse/simple.c64
-rw-r--r--src/pulse/simple.h11
-rw-r--r--src/pulse/stream.c532
-rw-r--r--src/pulse/stream.h150
-rw-r--r--src/pulse/subscribe.c3
-rw-r--r--src/pulse/subscribe.h5
-rw-r--r--src/pulse/thread-mainloop.c33
-rw-r--r--src/pulse/thread-mainloop.h29
-rw-r--r--src/pulse/timeval.c85
-rw-r--r--src/pulse/timeval.h18
-rw-r--r--src/pulse/utf8.c9
-rw-r--r--src/pulse/util.c101
-rw-r--r--src/pulse/util.h1
-rw-r--r--src/pulse/version.h.in8
-rw-r--r--src/pulse/volume.c292
-rw-r--r--src/pulse/volume.h103
-rw-r--r--src/pulse/xmalloc.h13
l---------src/pulsecore/Makefile1
-rw-r--r--src/pulsecore/arpa-inet.c (renamed from src/pulsecore/inet_ntop.c)47
-rw-r--r--src/pulsecore/arpa-inet.h23
-rw-r--r--src/pulsecore/asyncmsgq.c52
-rw-r--r--src/pulsecore/asyncmsgq.h4
-rw-r--r--src/pulsecore/asyncq.c25
-rw-r--r--src/pulsecore/asyncq.h5
-rw-r--r--src/pulsecore/atomic.h104
-rw-r--r--src/pulsecore/aupdate.c8
-rw-r--r--src/pulsecore/aupdate.h6
-rw-r--r--src/pulsecore/auth-cookie.c1
-rw-r--r--src/pulsecore/authkey.c57
-rw-r--r--src/pulsecore/avahi-wrap.c10
-rw-r--r--src/pulsecore/card.c51
-rw-r--r--src/pulsecore/card.h7
-rw-r--r--src/pulsecore/cli-command.c260
-rw-r--r--src/pulsecore/cli-text.c93
-rw-r--r--src/pulsecore/cli.c7
-rw-r--r--src/pulsecore/conf-parser.c99
-rw-r--r--src/pulsecore/conf-parser.h1
-rw-r--r--src/pulsecore/core-error.c2
-rw-r--r--src/pulsecore/core-error.h1
-rw-r--r--src/pulsecore/core-rtclock.c (renamed from src/pulsecore/rtclock.c)159
-rw-r--r--src/pulsecore/core-rtclock.h (renamed from src/pulsecore/rtclock.h)10
-rw-r--r--src/pulsecore/core-scache.c41
-rw-r--r--src/pulsecore/core-subscribe.c1
-rw-r--r--src/pulsecore/core-util.c1266
-rw-r--r--src/pulsecore/core-util.h58
-rw-r--r--src/pulsecore/core.c38
-rw-r--r--src/pulsecore/core.h37
-rw-r--r--src/pulsecore/cpu-arm.c147
-rw-r--r--src/pulsecore/cpu-arm.h43
-rw-r--r--src/pulsecore/cpu-orc.c34
-rw-r--r--src/pulsecore/cpu-orc.h (renamed from src/daemon/polkit.h)20
-rw-r--r--src/pulsecore/cpu-x86.c131
-rw-r--r--src/pulsecore/cpu-x86.h72
-rw-r--r--src/pulsecore/cpu.h45
-rw-r--r--src/pulsecore/creds.h8
-rw-r--r--src/pulsecore/database-gdbm.c7
-rw-r--r--src/pulsecore/database-simple.c508
-rw-r--r--src/pulsecore/database-tdb.c46
-rw-r--r--src/pulsecore/dbus-shared.c7
-rw-r--r--src/pulsecore/dbus-util.c423
-rw-r--r--src/pulsecore/dbus-util.h49
-rw-r--r--src/pulsecore/dllmain.c6
-rw-r--r--src/pulsecore/envelope.c786
-rw-r--r--src/pulsecore/envelope.h53
-rw-r--r--src/pulsecore/fdsem.c67
-rw-r--r--src/pulsecore/fdsem.h1
-rw-r--r--src/pulsecore/ffmpeg/Makefile13
-rw-r--r--src/pulsecore/flist.c211
-rw-r--r--src/pulsecore/flist.h9
-rw-r--r--src/pulsecore/hashmap.c44
-rw-r--r--src/pulsecore/hashmap.h17
-rw-r--r--src/pulsecore/hook-list.c4
-rw-r--r--src/pulsecore/hook-list.h3
-rw-r--r--src/pulsecore/idxset.c15
-rw-r--r--src/pulsecore/idxset.h5
-rw-r--r--src/pulsecore/inet_ntop.h12
-rw-r--r--src/pulsecore/inet_pton.c65
-rw-r--r--src/pulsecore/inet_pton.h12
-rw-r--r--src/pulsecore/iochannel.c172
-rw-r--r--src/pulsecore/iochannel.h5
-rw-r--r--src/pulsecore/ioline.c3
-rw-r--r--src/pulsecore/ioline.h3
-rw-r--r--src/pulsecore/ipacl.c17
-rw-r--r--src/pulsecore/llist.h3
-rw-r--r--src/pulsecore/lock-autospawn.c91
-rw-r--r--src/pulsecore/log.c127
-rw-r--r--src/pulsecore/log.h7
-rw-r--r--src/pulsecore/ltdl-helper.c5
-rw-r--r--src/pulsecore/macro.h93
-rw-r--r--src/pulsecore/memblock.c84
-rw-r--r--src/pulsecore/memblock.h2
-rw-r--r--src/pulsecore/memblockq.c188
-rw-r--r--src/pulsecore/memblockq.h12
-rw-r--r--src/pulsecore/memchunk.c10
-rw-r--r--src/pulsecore/memchunk.h3
-rw-r--r--src/pulsecore/memtrap.c38
-rw-r--r--src/pulsecore/modargs.c16
-rw-r--r--src/pulsecore/modargs.h11
-rw-r--r--src/pulsecore/modinfo.c1
-rw-r--r--src/pulsecore/module.c14
-rw-r--r--src/pulsecore/module.h2
-rw-r--r--src/pulsecore/msgobject.c14
-rw-r--r--src/pulsecore/msgobject.h10
-rw-r--r--src/pulsecore/mutex-posix.c2
-rw-r--r--src/pulsecore/mutex-win32.c25
-rw-r--r--src/pulsecore/namereg.c88
-rw-r--r--src/pulsecore/namereg.h1
-rw-r--r--src/pulsecore/native-common.h8
-rw-r--r--src/pulsecore/object.c20
-rw-r--r--src/pulsecore/object.h52
-rw-r--r--src/pulsecore/once.c3
-rw-r--r--src/pulsecore/once.h1
-rw-r--r--src/pulsecore/parseaddr.c4
-rw-r--r--src/pulsecore/pdispatch.c56
-rw-r--r--src/pulsecore/pdispatch.h6
-rw-r--r--src/pulsecore/pid.c14
-rw-r--r--src/pulsecore/pipe.c7
-rw-r--r--src/pulsecore/play-memblockq.c26
-rw-r--r--src/pulsecore/play-memblockq.h18
-rw-r--r--src/pulsecore/play-memchunk.c14
-rw-r--r--src/pulsecore/play-memchunk.h15
-rw-r--r--src/pulsecore/poll.c69
-rw-r--r--src/pulsecore/poll.h23
-rw-r--r--src/pulsecore/prioq.h2
-rw-r--r--src/pulsecore/proplist-util.c8
-rw-r--r--src/pulsecore/protocol-dbus.c1167
-rw-r--r--src/pulsecore/protocol-dbus.h218
-rw-r--r--src/pulsecore/protocol-esound.c72
-rw-r--r--src/pulsecore/protocol-http.c52
-rw-r--r--src/pulsecore/protocol-native.c846
-rw-r--r--src/pulsecore/protocol-native.h2
-rw-r--r--src/pulsecore/protocol-simple.c26
-rw-r--r--src/pulsecore/pstream.c19
-rw-r--r--src/pulsecore/random.c26
-rw-r--r--src/pulsecore/ratelimit.c9
-rw-r--r--src/pulsecore/ratelimit.h21
-rw-r--r--src/pulsecore/remap.c204
-rw-r--r--src/pulsecore/remap.h48
-rw-r--r--src/pulsecore/remap_mmx.c159
-rw-r--r--src/pulsecore/remap_sse.c157
-rw-r--r--src/pulsecore/resampler.c240
-rw-r--r--src/pulsecore/rtkit.c189
-rw-r--r--src/pulsecore/rtkit.h62
-rw-r--r--src/pulsecore/rtpoll.c244
-rw-r--r--src/pulsecore/rtpoll.h7
-rw-r--r--src/pulsecore/rtsig.c131
-rw-r--r--src/pulsecore/sample-util.c417
-rw-r--r--src/pulsecore/sample-util.h68
-rw-r--r--src/pulsecore/sconv-s16le.c47
-rw-r--r--src/pulsecore/sconv.c195
-rw-r--r--src/pulsecore/sconv.h7
-rw-r--r--src/pulsecore/sconv_sse.c233
-rw-r--r--src/pulsecore/semaphore-osx.c62
-rw-r--r--src/pulsecore/semaphore-win32.c3
-rw-r--r--src/pulsecore/shared.c1
-rw-r--r--src/pulsecore/shm.c20
-rw-r--r--src/pulsecore/shmasyncq.h1
-rw-r--r--src/pulsecore/sink-input.c779
-rw-r--r--src/pulsecore/sink-input.h85
-rw-r--r--src/pulsecore/sink.c1768
-rw-r--r--src/pulsecore/sink.h221
-rw-r--r--src/pulsecore/sndfile-util.c27
-rw-r--r--src/pulsecore/socket-client.c104
-rw-r--r--src/pulsecore/socket-client.h4
-rw-r--r--src/pulsecore/socket-server.c99
-rw-r--r--src/pulsecore/socket-server.h16
-rw-r--r--src/pulsecore/socket-util.c56
-rw-r--r--src/pulsecore/socket-util.h2
-rw-r--r--src/pulsecore/socket.h (renamed from src/pulsecore/winsock.h)9
-rw-r--r--src/pulsecore/sound-file-stream.c25
-rw-r--r--src/pulsecore/sound-file.c7
-rw-r--r--src/pulsecore/source-output.c777
-rw-r--r--src/pulsecore/source-output.h108
-rw-r--r--src/pulsecore/source.c1435
-rw-r--r--src/pulsecore/source.h131
-rw-r--r--src/pulsecore/start-child.c23
-rw-r--r--src/pulsecore/strbuf.c2
-rw-r--r--src/pulsecore/strlist.c2
-rw-r--r--src/pulsecore/svolume.orc84
-rw-r--r--src/pulsecore/svolume_arm.c218
-rw-r--r--src/pulsecore/svolume_c.c307
-rw-r--r--src/pulsecore/svolume_mmx.c344
-rw-r--r--src/pulsecore/svolume_orc.c138
-rw-r--r--src/pulsecore/svolume_sse.c351
-rw-r--r--src/pulsecore/tagstruct.c46
-rw-r--r--src/pulsecore/tagstruct.h8
-rw-r--r--src/pulsecore/thread-mq.c18
-rw-r--r--src/pulsecore/thread-mq.h10
-rw-r--r--src/pulsecore/thread-posix.c67
-rw-r--r--src/pulsecore/thread-win32.c27
-rw-r--r--src/pulsecore/thread.h11
-rw-r--r--src/pulsecore/time-smoother.c57
-rw-r--r--src/pulsecore/time-smoother.h2
-rw-r--r--src/pulsecore/tokenizer.c1
-rw-r--r--src/pulsecore/usergroup.c364
-rw-r--r--src/pulsecore/usergroup.h51
-rw-r--r--src/pulsecore/vector.h3
-rw-r--r--src/pulsecore/x11prop.c127
-rw-r--r--src/pulsecore/x11prop.h9
-rw-r--r--src/pulsecore/x11wrap.c4
-rw-r--r--src/pulsecore/x11wrap.h4
l---------src/tests/Makefile1
-rw-r--r--src/tests/alsa-time-test.c59
-rw-r--r--src/tests/asyncmsgq-test.c5
-rw-r--r--src/tests/asyncq-test.c8
-rw-r--r--src/tests/channelmap-test.c1
-rw-r--r--src/tests/connect-stress.c206
-rw-r--r--src/tests/cpulimit-test.c5
-rw-r--r--src/tests/envelope-test.c246
-rw-r--r--src/tests/extended-test.c197
-rw-r--r--src/tests/flist-test.c2
-rw-r--r--src/tests/format-test.c106
-rw-r--r--src/tests/get-binary-name-test.c26
-rw-r--r--src/tests/interpol-test.c83
-rw-r--r--src/tests/ipacl-test.c18
-rw-r--r--src/tests/lock-autospawn-test.c12
-rw-r--r--src/tests/mainloop-test.c9
-rw-r--r--src/tests/mcalign-test.c2
-rw-r--r--src/tests/memblockq-test.c42
-rw-r--r--src/tests/mix-test.c117
-rw-r--r--src/tests/once-test.c111
-rw-r--r--src/tests/pacat-simple.c1
-rw-r--r--src/tests/parec-simple.c1
-rw-r--r--src/tests/queue-test.c3
-rw-r--r--src/tests/remix-test.c6
-rw-r--r--src/tests/resampler-test.c208
-rw-r--r--src/tests/rtpoll-test.c8
-rw-r--r--src/tests/rtstutter.c61
-rw-r--r--src/tests/stripnul.c2
-rw-r--r--src/tests/strlist-test.c1
-rw-r--r--src/tests/sync-playback.c2
-rw-r--r--src/tests/thread-mainloop-test.c9
-rw-r--r--src/tests/thread-test.c4
-rw-r--r--src/tests/usergroup-test.c155
-rw-r--r--src/tests/voltest.c72
l---------src/utils/Makefile1
-rw-r--r--src/utils/pabrowse.c156
-rw-r--r--src/utils/pacat.c270
-rw-r--r--src/utils/pacmd.c185
-rw-r--r--src/utils/pactl.c832
-rw-r--r--src/utils/padsp.c124
-rw-r--r--src/utils/pasuspender.c8
-rw-r--r--src/utils/pax11publish.c78
-rwxr-xr-xsrc/utils/qpaeq560
-rw-r--r--todo18
-rw-r--r--vala/libpulse-mainloop-glib.deps1
-rw-r--r--vala/libpulse-mainloop-glib.vapi13
-rw-r--r--vala/libpulse.deps1
-rw-r--r--vala/libpulse.vapi1511
594 files changed, 122824 insertions, 38320 deletions
diff --git a/.gitignore b/.gitignore
index fae5b471..eb33e910 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,6 +1,5 @@
+.tarball-version
.version
-shave
-shave-libtool
.*.swp
ABOUT-NLS
intltool-extract.in
@@ -29,3 +28,4 @@ libtool
ltmain.sh
missing
stamp-*
+ChangeLog
diff --git a/LICENSE b/LICENSE
index 612c2341..3a82749e 100644
--- a/LICENSE
+++ b/LICENSE
@@ -10,4 +10,8 @@ LGPL licensed and the server part ('libpulsecore') as being GPL licensed. Since
the PulseAudio daemon and the modules link to 'libpulsecore' they are of course
also GPL licensed.
+Andre Adrian's echo cancellation implementation is licensed under a less
+restrictive license - see src/modules/echo-cancel/adrian-license.txt for
+details.
+
-- Lennart Poettering, April 20th, 2006.
diff --git a/Makefile.am b/Makefile.am
index 2448e748..b0107015 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -17,20 +17,35 @@
ACLOCAL_AMFLAGS = -I m4
-EXTRA_DIST = bootstrap.sh LICENSE GPL LGPL doxygen/Makefile.am doxygen/Makefile.in doxygen/doxygen.conf.in README todo
+EXTRA_DIST = \
+ bootstrap.sh \
+ git-version-gen \
+ LICENSE \
+ GPL \
+ LGPL \
+ doxygen/Makefile.am \
+ doxygen/Makefile.in \
+ doxygen/doxygen.conf.in \
+ README \
+ todo \
+ vala/libpulse.deps \
+ vala/libpulse.vapi \
+ vala/libpulse-mainloop-glib.deps \
+ vala/libpulse-mainloop-glib.vapi
+
SUBDIRS = src doxygen man po
MAINTAINERCLEANFILES =
noinst_DATA =
+vapidir = $(datadir)/vala/vapi
+vapi_DATA = \
+ vala/libpulse.deps vala/libpulse.vapi \
+ vala/libpulse-mainloop-glib.deps vala/libpulse-mainloop-glib.vapi
+
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libpulse.pc libpulse-simple.pc
-if HAVE_AVAHI
-pkgconfig_DATA += \
- libpulse-browse.pc
-endif
-
if HAVE_GLIB20
pkgconfig_DATA += \
libpulse-mainloop-glib.pc
@@ -40,6 +55,7 @@ homepage: all dist doxygen
test -d $$HOME/homepage/private
mkdir -p $$HOME/homepage/private/projects/pulseaudio $$HOME/homepage/private/projects/pulseaudio/doxygen
cp pulseaudio-@PACKAGE_VERSION@.tar.gz $$HOME/homepage/private/projects/pulseaudio
+ cp pulseaudio-@PACKAGE_VERSION@.tar.gz $$HOME/git.fedora/pulseaudio
cp -a doxygen/html/* $$HOME/homepage/private/projects/pulseaudio/doxygen
doxygen:
@@ -52,21 +68,16 @@ untabify:
find \( -name '*.c' -o -name '*.h' \) -exec perl -i -pe 's/\t/ /g;' \{\} \;
fedora-snapshot: dist
- cp $(distdir).tar.gz $$HOME/cvs.fedora/pulseaudio/devel/$(distdir).tar.gz
+ cp $(distdir).tar.gz $$HOME/git.fedora/pulseaudio/$(distdir).tar.gz
dist-hook:
if test -d .git ; then \
- test -z $$SKIP_GIT && git pull ; \
- chmod u+w ${distdir}/ChangeLog || true ; \
+ test -z $$USE_GIT || git pull ; \
+ test -f ${distdir}/ChangeLog && chmod u+w ${distdir}/ChangeLog ; \
( git-changelog.perl || echo "git-changelog.perl failed." ) > ${distdir}/ChangeLog 2>&1 ; \
fi
echo $(VERSION) > $(distdir)/.tarball-version
-
-update-shave:
- for i in shave.in shave.m4 shave-libtool.in; do \
- wget -O $$i http://git.lespiau.name/cgit/shave/blob/\?path=shave/$$i ; \
- done
- mv shave.m4 m4/
+ echo $(VERSION) > $(distdir)/.version
.PHONY: homepage distcleancheck doxygen
@@ -77,3 +88,5 @@ $(top_srcdir)/.version:
DISTCLEANFILES = \
po/.intltool-merge-cache
+
+DISTCHECK_CONFIGURE_FLAGS = --with-udev-rules-dir="$$dc_install_base/lib/udev/rules.d"
diff --git a/PROTOCOL b/PROTOCOL
index 88166f14..6b999af4 100644
--- a/PROTOCOL
+++ b/PROTOCOL
@@ -181,3 +181,93 @@ new messages:
PA_COMMAND_PLAYBACK_BUFFER_ATTR_CHANGED
PA_COMMAND_RECORD_BUFFER_ATTR_CHANGED
+
+### v16, implemented by >= 0.9.15
+
+new messages:
+
+ PA_COMMAND_SET_SINK_PORT
+ PA_COMMAND_SET_SOURCE_PORT
+
+## v17, implemented by >= 0.9.20
+
+new flag at end of CREATE_PLAYBACK_STREAM:
+
+ bool relative_volume
+
+## v18, implemented by >= 0.9.22
+
+new flag at end of CREATE_PLAYBACK_STREAM:
+
+ bool passthrough
+
+## v19, implemented by >= 0.9.22
+
+New flag at the end of sink input and source output introspection data:
+
+ bool corked
+
+## v20, implemented by >= 1.0
+
+Two new flags at the end of sink input introspection data:
+
+ bool has_volume
+ bool volume_writable
+
+## v21, implemented by >= 1.0
+
+Changes for format negotiation in the extended API.
+
+New fields PA_COMMAND_CREATE_PLAYBACK_STREAM:
+
+ uint8_t n_formats
+ format_info format1
+ ...
+ format_info formatn
+
+One new field in reply from PA_COMMAND_CREATE_PLAYBACK_STREAM:
+
+ format_info format
+
+New fields in reply from PA_COMMAND_GET_SINK_INFO (and thus
+PA_COMMAND_GET_SINK_INFO_LIST)
+
+ uint8_t n_formats
+ format_info format1
+ ...
+ format_info formatn
+
+One new field in reply from PA_COMMAND_GET_SINK_INPUT_INFO (and thus
+PA_COMMAND_GET_SINK_INPUT_INFO_LIST)
+
+ format_info format
+
+## v22, implemented by >= 1.0
+
+New fields PA_COMMAND_CREATE_RECORD_STREAM:
+
+ uint8_t n_formats
+ format_info format1
+ ...
+ format_info formatn
+
+One new field in reply from PA_COMMAND_CREATE_RECORD_STREAM:
+
+ format_info format
+
+New fields in reply from PA_COMMAND_GET_SOURCE_INFO (and thus
+PA_COMMAND_GET_SOURCE_INFO_LIST)
+
+ uint8_t n_formats
+ format_info format1
+ ...
+ format_info formatn
+
+Five new fields in reply from PA_COMMAND_GET_SOURCE_OUTPUT_INFO (and thus
+PA_COMMAND_GET_SOURCE_OUTPUT_INFO_LIST)
+
+ format_info format
+ volume
+ bool mute
+ bool has_volume
+ bool volume_writable
diff --git a/bootstrap.sh b/bootstrap.sh
index c7737a6e..c7c85823 100755
--- a/bootstrap.sh
+++ b/bootstrap.sh
@@ -16,7 +16,7 @@
# along with PulseAudio; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
-VERSION=1.10
+VERSION=1.11
run_versioned() {
local P
@@ -40,10 +40,21 @@ run_versioned() {
set -ex
+case $(uname) in
+ *Darwin*)
+ LIBTOOLIZE="glibtoolize"
+ ;;
+esac
+
if [ -f .git/hooks/pre-commit.sample -a ! -f .git/hooks/pre-commit ] ; then
- echo "Activating pre-commit hook."
- cp -av .git/hooks/pre-commit.sample .git/hooks/pre-commit
- chmod -c +x .git/hooks/pre-commit
+ cp -p .git/hooks/pre-commit.sample .git/hooks/pre-commit && \
+ chmod +x .git/hooks/pre-commit && \
+ echo "Activated pre-commit hook."
+fi
+
+if [ -f .tarball-version ]; then
+ echo "Marking tarball version as modified."
+ echo -n `cat .tarball-version | sed 's/-rebootstrapped$//'`-rebootstrapped >.tarball-version
fi
# We check for this here, because if pkg-config is not found in the
@@ -83,7 +94,7 @@ else
run_versioned automake "$VERSION" --copy --foreign --add-missing
if test "x$NOCONFIGURE" = "x"; then
- CFLAGS="-g -O0" ./configure --sysconfdir=/etc --localstatedir=/var --enable-force-preopen --enable-shave "$@"
+ CFLAGS="$CFLAGS -g -O0" ./configure --sysconfdir=/etc --localstatedir=/var --enable-force-preopen "$@"
make clean
fi
fi
diff --git a/configure.ac b/configure.ac
index a3f9f0ef..66dc9ca2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -22,34 +22,29 @@
AC_PREREQ(2.63)
-AC_INIT([pulseaudio], m4_esyscmd([./git-version-gen .tarball-version]),
- [mzchyfrnhqvb (at) 0pointer (dot) net])
+AC_INIT([pulseaudio],[m4_esyscmd(./git-version-gen .tarball-version)],[mzchyfrnhqvb (at) 0pointer (dot) net],[pulseaudio],[http://pulseaudio.org/])
AC_CONFIG_SRCDIR([src/daemon/main.c])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_HEADERS([config.h])
-AM_INIT_AUTOMAKE([foreign 1.10 -Wall -Wno-portability])
+AM_INIT_AUTOMAKE([foreign 1.11 -Wall -Wno-portability silent-rules tar-pax])
-m4_define(pa_major, `echo $VERSION | cut -d. -f 1`)
-m4_define(pa_minor, `echo $VERSION | cut -d. -f 2`)
-m4_define(pa_micro, `echo $VERSION | cut -d. -f 3`)
+m4_define(pa_major, `echo $VERSION | cut -d. -f1 | cut -d- -f1`)
+m4_define(pa_minor, `echo $VERSION | cut -d. -f2 | cut -d- -f1`)
AC_SUBST(PA_MAJOR, pa_major)
AC_SUBST(PA_MINOR, pa_minor)
-AC_SUBST(PA_MICRO, pa_micro)
AC_SUBST(PA_MAJORMINOR, pa_major.pa_minor)
-AC_SUBST(PA_MAJORMINORMICRO, pa_major.pa_minor.pa_micro)
-AC_SUBST(PACKAGE_URL, [http://pulseaudio.org/])
AC_SUBST(PA_API_VERSION, 12)
-AC_SUBST(PA_PROTOCOL_VERSION, 15)
+AC_SUBST(PA_PROTOCOL_VERSION, 22)
# The stable ABI for client applications, for the version info x:y:z
# always will hold y=z
-AC_SUBST(LIBPULSE_VERSION_INFO, [8:0:8])
+AC_SUBST(LIBPULSE_VERSION_INFO, [12:4:12])
# A simplified, synchronous, ABI-stable interface for client
# applications, for the version info x:y:z always will hold y=z
-AC_SUBST(LIBPULSE_SIMPLE_VERSION_INFO, [0:2:0])
+AC_SUBST(LIBPULSE_SIMPLE_VERSION_INFO, [0:3:0])
# The ABI-stable network browsing interface for client applications,
# for the version info x:y:z always will hold y=z
@@ -62,19 +57,15 @@ AC_SUBST(LIBPULSE_MAINLOOP_GLIB_VERSION_INFO, [0:4:0])
AC_CANONICAL_HOST
AC_DEFINE_UNQUOTED([CANONICAL_HOST], "$host", [Canonical host string.])
-if type -p stow > /dev/null && test -d /usr/local/stow ; then
- AC_MSG_NOTICE([*** Found /usr/local/stow: default install prefix set to /usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION} ***])
- ac_default_prefix="/usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION}"
-fi
+AC_CHECK_PROG([STOW], [stow], [yes], [no])
-#### Platform hacks ####
+AS_IF([test "x$STOW" = "xyes" && test -d /usr/local/stow], [
+ AC_MSG_NOTICE([*** Found /usr/local/stow: default install prefix set to /usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION} ***])
+ ac_default_prefix="/usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION}"
+])
+
+AM_SILENT_RULES([yes])
-case $host in
- *-*-solaris* )
- AC_DEFINE(_XOPEN_SOURCE, 600, Needed to get declarations for msg_control and msg_controllen on Solaris)
- AC_DEFINE(__EXTENSIONS__, 1, Needed to get declarations for msg_control and msg_controllen on Solaris)
- ;;
-esac
#### Checks for programs. ####
@@ -93,93 +84,134 @@ AC_USE_SYSTEM_EXTENSIONS
# M4
AC_CHECK_PROGS([M4], gm4 m4, no)
-if test "x$M4" = xno ; then
- AC_MSG_ERROR([m4 missing])
-fi
+AS_IF([test "x$M4" = "xno"], AC_MSG_ERROR([m4 missing]))
+
+# pkg-config
+
+PKG_PROG_PKG_CONFIG
+
+# gettext
+
+IT_PROG_INTLTOOL([0.35.0])
+GETTEXT_PACKAGE=pulseaudio
+AC_SUBST([GETTEXT_PACKAGE])
+AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE],["$GETTEXT_PACKAGE"],[Gettext package])
+AM_GLIB_GNU_GETTEXT
+
+pulselocaledir='${prefix}/${DATADIRNAME}/locale'
+AX_DEFINE_DIR(PULSE_LOCALEDIR, pulselocaledir, [Gettext locale dir])
+
+
+#### Determine host OS ####
+
+os_is_linux=0
+os_is_win32=0
+os_is_darwin=0
+
+AC_MSG_CHECKING([host operating system])
+case "$host_os" in
+ linux*)
+ AC_MSG_RESULT([linux])
+ os_is_linux=1
+ ;;
+ darwin*)
+ AC_MSG_RESULT([darwin])
+ os_is_darwin=1
+ AC_DEFINE([OS_IS_DARWIN], 1, [Build target is Darwin.])
+ ;;
+ mingw*)
+ AC_MSG_RESULT([win32])
+ os_is_win32=1
+ AC_DEFINE([OS_IS_WIN32], 1, [Build target is Windows.])
+ ;;
+ *)
+ AC_MSG_RESULT([unknown])
+ ;;
+esac
+
+AM_CONDITIONAL(OS_IS_DARWIN, test "x$os_is_darwin" = "x1")
+AM_CONDITIONAL(OS_IS_WIN32, test "x$os_is_win32" = "x1")
+AC_SUBST([OS_IS_WIN32], [$os_is_win32])
+
+# Platform specific hacks
+case "$host_os" in
+ darwin* )
+ AC_DEFINE([_DARWIN_C_SOURCE], [200112L], [Needed to get NSIG on Mac OS X])
+ ;;
+ mingw* )
+ AC_DEFINE([WIN32_LEAN_AND_MEAN], 1, [Needed to avoid including unnecessary headers on Windows])
+ ;;
+ solaris* )
+ AC_DEFINE(_XOPEN_SOURCE, 600, [Needed to get declarations for msg_control and msg_controllen on Solaris])
+ AC_DEFINE(__EXTENSIONS__, 1, [Needed to get declarations for msg_control and msg_controllen on Solaris])
+ ;;
+esac
-dnl Compiler flags
-DESIRED_FLAGS="-Wall -W -Wextra -pipe -Wno-long-long -Winline -Wvla -Wno-overlength-strings -Wunsafe-loop-optimizations -Wundef -Wformat=2 -Wlogical-op -Wsign-compare -Wformat-security -Wmissing-include-dirs -Wformat-nonliteral -Wold-style-definition -Wpointer-arith -Winit-self -Wdeclaration-after-statement -Wfloat-equal -Wmissing-prototypes -Wstrict-prototypes -Wredundant-decls -Wmissing-declarations -Wmissing-noreturn -Wshadow -Wendif-labels -Wcast-align -Wstrict-aliasing=2 -Wwrite-strings -Wno-unused-parameter -ffast-math -Wp,-D_FORTIFY_SOURCE=2 -fno-common -fdiagnostics-show-option"
-for flag in $DESIRED_FLAGS ; do
- CC_CHECK_CFLAGS([$flag], [CFLAGS="$CFLAGS $flag"])
-done
+#### Compiler flags ####
-dnl Linker flags.
-dnl Check whether the linker supports the -version-script option.
+AX_APPEND_COMPILE_FLAGS(
+ [-Wall -W -Wextra -pipe -Wno-long-long -Wvla -Wno-overlength-strings -Wunsafe-loop-optimizations -Wundef -Wformat=2 -Wlogical-op -Wsign-compare -Wformat-security -Wmissing-include-dirs -Wformat-nonliteral -Wold-style-definition -Wpointer-arith -Winit-self -Wdeclaration-after-statement -Wfloat-equal -Wmissing-prototypes -Wstrict-prototypes -Wredundant-decls -Wmissing-declarations -Wmissing-noreturn -Wshadow -Wendif-labels -Wcast-align -Wstrict-aliasing -Wwrite-strings -Wno-unused-parameter -ffast-math -Wp,-D_FORTIFY_SOURCE=2 -fno-common -fdiagnostics-show-option],
+ [], [-pedantic -Werror])
-dnl This variable is used to make sure ${srcdir} is expanded and not
-dnl passed to the CC_CHECK_LDFLAGS macro as a name.
-tmp_ldflag="-Wl,-version-script=${srcdir}/src/map-file"
-CC_CHECK_LDFLAGS([${tmp_ldflag}],
+#### Linker flags ####
+
+# Check whether the linker supports the -version-script option.
+# The Make variable $(srcdir) needs to be in the LDFLAGS in that form,
+# so that it is expanded the right way in every subdir.
+AX_CHECK_LINK_FLAG(["-Wl,-version-script=${srcdir}/src/map-file"],
[VERSIONING_LDFLAGS='-Wl,-version-script=$(srcdir)/map-file'])
AC_SUBST([VERSIONING_LDFLAGS])
-dnl Check whether to build tests by default (as compile-test) or not
-AC_ARG_ENABLE([default-build-tests],
- AS_HELP_STRING([--disable-default-build-tests], [Build test programs only during make check]))
+# Use immediate (now) bindings; avoids the funky re-call in itself.
+# The -z now syntax is lifted from Sun's linker and works with GNU's too, other linkers might be added later.
+AX_APPEND_LINK_FLAGS([-Wl,-z,now], [IMMEDIATE_LDFLAGS])
+AC_SUBST([IMMEDIATE_LDFLAGS])
-AM_CONDITIONAL([BUILD_TESTS_DEFAULT], [test "x$enable_default_build_tests" != "xno"])
+# On ELF systems we don't want the libraries to be unloaded since we don't clean them up properly,
+# so we request the nodelete flag to be enabled.
+# On other systems, we don't really know how to do that, but it's welcome if somebody can tell.
+AX_APPEND_LINK_FLAGS([-Wl,-z,nodelete], [NODELETE_LDFLAGS])
+AC_SUBST([NODELETE_LDFLAGS])
+
+# Check for the proper way to build libraries that have no undefined symbols
+case $host in
+ # FreeBSD (et al.) does not complete linking for shared objects when pthreads
+ # are requested, as different implementations are present.
+ *-freebsd* | *-openbsd*) ;;
+ *)
+ for possible_flag in "-Wl,--no-undefined" "-Wl,-z,defs"; do
+ AX_CHECK_LINK_FLAG([$possible_flag], [NOUNDEFINED_LDFLAGS="$possible_flag"; break])
+ done
+ ;;
+esac
+AC_SUBST([NOUNDEFINED_LDFLAGS])
+
+
+#### Atomic operations ####
# Native atomic operation support
AC_ARG_ENABLE([atomic-arm-linux-helpers],
- AS_HELP_STRING([--disable-atomic-arm-linux-helpers],[use inline asm or libatomic_ops instead]),
- [
- case "${enableval}" in
- yes) atomic_arm_linux_helpers=yes ;;
- no) atomic_arm_linux_helpers=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-atomic-arm-linux-helpers) ;;
- esac
- ],
- [atomic_arm_linux_helpers=auto])
+ AS_HELP_STRING([--disable-atomic-arm-linux-helpers],[use inline asm or libatomic_ops instead]))
AC_ARG_ENABLE([atomic-arm-memory-barrier],
- AS_HELP_STRING([--enable-atomic-arm-memory-barrier],[only really needed in SMP arm systems]),
- [
- case "${enableval}" in
- yes) AC_DEFINE_UNQUOTED(ATOMIC_ARM_MEMORY_BARRIER_ENABLED, 1, [Enable memory barriers]) ;;
- no) ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-atomic-arm-linux-helpers) ;;
- esac
- ],)
-
-AC_ARG_ENABLE([netbsd-atomic-ops],
- AS_HELP_STRING([--enable-netbsd-atomic-ops],[Use the native NetBSD atomic_ops implementation]),
- [
- case "${enableval}" in
- yes) atomic_netbsd_helpers=yes ;;
- no) atomic_netbsd_helpers=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --enable-netbsd-atomic-ops) ;;
- esac
- ],
- [atomic_netbsd_helpers=auto])
-
-AC_MSG_CHECKING([target operating system])
-case $host in
- *-*-linux*)
- AC_MSG_RESULT([linux])
- pulse_target_os=linux
- ;;
- *-*-netbsd*)
- AC_MSG_RESULT([netbsd])
- pulse_target_os=netbsd
- ;;
- *)
- AC_MSG_RESULT([unknown])
- pulse_target_os=unknown
- ;;
-esac
+ AS_HELP_STRING([--enable-atomic-arm-memory-barrier],[only really needed in SMP arm systems]))
+
+if test "x$enable_atomic_arm_memory_barrier" = "xyes"; then
+ AC_DEFINE_UNQUOTED(ATOMIC_ARM_MEMORY_BARRIER_ENABLED, 1, [Enable memory barriers])
+fi
# If everything else fails use libatomic_ops
need_libatomic_ops=yes
AC_CACHE_CHECK([whether $CC knows __sync_bool_compare_and_swap()],
- pulseaudio_cv_sync_bool_compare_and_swap,
- [AC_LINK_IFELSE(
- AC_LANG_PROGRAM([], [[int a = 4; __sync_bool_compare_and_swap(&a, 4, 5);]]),
- [pulseaudio_cv_sync_bool_compare_and_swap=yes],
- [pulseaudio_cv_sync_bool_compare_and_swap=no])
- ])
+ pulseaudio_cv_sync_bool_compare_and_swap, [
+ AC_LINK_IFELSE(
+ AC_LANG_PROGRAM([], [[int a = 4; __sync_bool_compare_and_swap(&a, 4, 5);]]),
+ [pulseaudio_cv_sync_bool_compare_and_swap=yes],
+ [pulseaudio_cv_sync_bool_compare_and_swap=no])
+ ])
if test "$pulseaudio_cv_sync_bool_compare_and_swap" = "yes" ; then
AC_DEFINE([HAVE_ATOMIC_BUILTINS], 1, [Have __sync_bool_compare_and_swap() and friends.])
@@ -187,69 +219,90 @@ if test "$pulseaudio_cv_sync_bool_compare_and_swap" = "yes" ; then
else
# HW specific atomic ops stuff
AC_MSG_CHECKING([architecture for native atomic operations])
- case $host_cpu in
+ case $host in
arm*)
AC_MSG_RESULT([arm])
AC_MSG_CHECKING([whether we can use Linux kernel helpers])
# The Linux kernel helper functions have been there since 2.6.16. However
# compile time checking for kernel version in cross compile environment
# (which is usually the case for arm cpu) is tricky (or impossible).
- if test "x$pulse_target_os" = "xlinux" && test "x$atomic_arm_linux_helpers" != "xno"; then
+ if test "x$os_is_linux" = "x1" && test "x$enable_atomic_arm_linux_helpers" != "xno"; then
AC_MSG_RESULT([yes])
AC_DEFINE_UNQUOTED(ATOMIC_ARM_LINUX_HELPERS, 1, [special arm linux implementation])
need_libatomic_ops=no
else
- AC_MSG_RESULT([no])
- AC_CACHE_CHECK([compiler support for arm inline asm atomic operations],
- pulseaudio_cv_support_arm_atomic_ops,
- [AC_COMPILE_IFELSE(
- AC_LANG_PROGRAM([],
- [[volatile int a=0;
- int o=0, n=1, r;
- asm volatile ("ldrex %0, [%1]\n"
- "subs %0, %0, %2\n"
- "strexeq %0, %3, [%1]\n"
- : "=&r" (r)
- : "r" (&a), "Ir" (o), "r" (n)
- : "cc");
- return (a==1 ? 0 : -1);
- ]]),
- [pulseaudio_cv_support_arm_atomic_ops=yes],
- [pulseaudio_cv_support_arm_atomic_ops=no])
- ])
- AS_IF([test "$pulseaudio_cv_support_arm_atomic_ops" = "yes"], [
- AC_DEFINE([ATOMIC_ARM_INLINE_ASM], 1, [Have ARMv6 instructions.])
- need_libatomic_ops=no
- ])
- fi
+ AC_MSG_RESULT([no])
+ AC_CACHE_CHECK([compiler support for arm inline asm atomic operations],
+ pulseaudio_cv_support_arm_atomic_ops, [
+ AC_COMPILE_IFELSE(
+ AC_LANG_PROGRAM([], [[
+ volatile int a=0;
+ int o=0, n=1, r;
+ asm volatile ("ldrex %0, [%1]\n"
+ "subs %0, %0, %2\n"
+ "strexeq %0, %3, [%1]\n"
+ : "=&r" (r)
+ : "r" (&a), "Ir" (o), "r" (n)
+ : "cc");
+ return (a==1 ? 0 : -1);
+ ]]),
+ [pulseaudio_cv_support_arm_atomic_ops=yes],
+ [pulseaudio_cv_support_arm_atomic_ops=no])
+ ])
+ AS_IF([test "$pulseaudio_cv_support_arm_atomic_ops" = "yes"], [
+ AC_DEFINE([ATOMIC_ARM_INLINE_ASM], 1, [Have ARM atomic instructions.])
+ need_libatomic_ops=no
+ ])
+ fi
+ ;;
+ *-netbsdelf5*)
+ AC_MSG_RESULT([yes])
+ need_libatomic_ops=no
+ ;;
+ *-freebsd*)
+ AC_MSG_RESULT([yes])
+ need_libatomic_ops=no
;;
*)
- if test "x$pulse_target_os" = "xnetbsd" && test "x$atomic_netbsd_helpers" = "xyes"; then
- AC_MSG_RESULT([yes])
- AC_DEFINE_UNQUOTED(NETBSD_ATOMIC_OPS, 1, [netbsd implementation])
- need_libatomic_ops=no
- else
- AC_MSG_RESULT([unknown])
- fi
+ AC_MSG_RESULT([unknown])
;;
esac
fi
-CC_CHECK_TLS
-
-AC_CACHE_CHECK([whether $CC knows _Bool],
- pulseaudio_cv__Bool,
- [AC_COMPILE_IFELSE(
- AC_LANG_PROGRAM([], [[_Bool b;]]),
- [pulseaudio_cv__Bool=yes],
- [pulseaudio_cv__Bool=no])
- ])
+# If we're on ARM, check for the ARMV6 instructions we need */
+case $host in
+ arm*)
+ AC_CACHE_CHECK([support for required armv6 instructions],
+ pulseaudio_cv_support_armv6,
+ [AC_COMPILE_IFELSE(
+ AC_LANG_PROGRAM([],
+ [[volatile int a = -60000, b = 0xaaaabbbb, c = 0xccccdddd;
+ asm volatile ("ldr r0, %2 \n"
+ "ldr r2, %3 \n"
+ "ldr r3, %4 \n"
+ "ssat r1, #8, r0 \n"
+ "str r1, %0 \n"
+ "pkhbt r1, r3, r2, LSL #8 \n"
+ "str r1, %1 \n"
+ : "=m" (a), "=m" (b)
+ : "m" (a), "m" (b), "m" (c)
+ : "r0", "r1", "r2", "r3", "cc");
+ return (a == -128 && b == 0xaabbdddd) ? 0 : -1;
+ ]]),
+ [pulseaudio_cv_support_armv6=yes],
+ [pulseaudio_cv_support_armv6=no])
+ ])
+ AS_IF([test "$pulseaudio_cv_support_armv6" = "yes"], [
+ AC_DEFINE([HAVE_ARMV6], 1, [Have ARMv6 instructions.])
+ ])
+ ;;
+ *)
+ ;;
+esac
-AS_IF([test "$pulseaudio_cv__Bool" = "yes"], [
- AC_DEFINE([HAVE_STD_BOOL], 1, [Have _Bool.])
- ])
#### libtool stuff ####
+
LT_PREREQ(2.2)
LT_INIT([dlopen win32-dll disable-static])
@@ -275,21 +328,9 @@ AC_CHECK_HEADER([ltdl.h],
[LIBLTDL=])
AS_IF([test "x$LIBLTDL" = "x"],
- [AC_MSG_ERROR([Unable to find libltdl.])])
+ [AC_MSG_ERROR([Unable to find libltdl version 2. Makes sure you have libtool 2.2 or later installed.])])
AC_SUBST([LIBLTDL])
-#### Determine build environment ####
-
-os_is_win32=0
-
-case "$host_os" in
- mingw*)
- AC_DEFINE([OS_IS_WIN32], 1, [Build target is Windows.])
- os_is_win32=1
- ;;
- esac
-
-AM_CONDITIONAL(OS_IS_WIN32, test "x$os_is_win32" = "x1")
###################################
# Basic environment checks #
@@ -303,7 +344,7 @@ AC_HEADER_STDC
# POSIX
AC_CHECK_HEADERS_ONCE([arpa/inet.h glob.h grp.h netdb.h netinet/in.h \
netinet/in_systm.h netinet/tcp.h poll.h pwd.h sched.h \
- sys/mman.h sys/resource.h sys/select.h sys/socket.h sys/wait.h \
+ sys/mman.h sys/select.h sys/socket.h sys/wait.h \
sys/uio.h syslog.h sys/dl.h dlfcn.h linux/sockios.h])
AC_CHECK_HEADERS([netinet/ip.h], [], [],
[#include <sys/types.h>
@@ -314,15 +355,14 @@ AC_CHECK_HEADERS([netinet/ip.h], [], [],
# include <netinet/in_systm.h>
#endif
])
-AC_CHECK_HEADERS([regex.h], [HAVE_REGEX=1], [HAVE_REGEX=0])
+AC_CHECK_HEADERS([sys/resource.h], [HAVE_SYS_RESOURCE_H=1], [HAVE_SYS_RESOURCE_H=0])
+AC_SUBST(HAVE_SYS_RESOURCE_H)
AC_CHECK_HEADERS([sys/un.h], [HAVE_AF_UNIX=1], [HAVE_AF_UNIX=0])
-
-AM_CONDITIONAL(HAVE_REGEX, test "x$HAVE_REGEX" = "x1")
AM_CONDITIONAL(HAVE_AF_UNIX, test "x$HAVE_AF_UNIX" = "x1")
+AC_SUBST(HAVE_AF_UNIX)
# Linux
AC_CHECK_HEADERS([linux/input.h], [HAVE_EVDEV=1], [HAVE_EVDEV=0])
-
AM_CONDITIONAL([HAVE_EVDEV], [test "x$HAVE_EVDEV" = "x1"])
AC_CHECK_HEADERS_ONCE([sys/prctl.h])
@@ -342,6 +382,9 @@ AC_CHECK_HEADERS_ONCE([byteswap.h])
AC_CHECK_HEADERS_ONCE([sys/syscall.h])
AC_CHECK_HEADERS_ONCE([sys/eventfd.h])
AC_CHECK_HEADERS_ONCE([execinfo.h])
+AC_CHECK_HEADERS_ONCE([langinfo.h])
+AC_CHECK_HEADERS_ONCE([regex.h pcreposix.h])
+
#### Typdefs, structures, etc. ####
@@ -349,27 +392,48 @@ AC_C_CONST
AC_C_BIGENDIAN
AC_TYPE_PID_T
AC_TYPE_SIZE_T
-AC_CHECK_TYPES(ssize_t, , [AC_DEFINE([ssize_t], [signed long],
- [Define ssize_t if it is not done by the standard libs.])])
+AC_CHECK_TYPES(ssize_t, , AC_DEFINE([ssize_t], [signed long], [Define ssize_t if it is not done by the standard libs.]))
AC_TYPE_OFF_T
AC_TYPE_UID_T
AC_CHECK_DECLS(environ)
-AC_CHECK_DEFINE([SIGXCPU], [signal.h], [
-HAVE_SIGXCPU=1
-AC_DEFINE([HAVE_SIGXCPU], 1, [Have SIGXCPU?])
-], [HAVE_SIGXCPU=0])
+# SIGXCPU
+AX_CHECK_DEFINE([signal.h], [SIGXCPU], [HAVE_SIGXCPU=1], [HAVE_SIGXCPU=0])
+AS_IF([test "x$HAVE_SIGXCPU" = "x1"], AC_DEFINE([HAVE_SIGXCPU], 1, [Have SIGXCPU?]))
AM_CONDITIONAL(HAVE_SIGXCPU, test "x$HAVE_SIGXCPU" = "x1")
-# Solaris lacks this
-AC_CHECK_DEFINE([INADDR_NONE], [netinet/in.h], [],
- [AC_CHECK_DEFINE([INADDR_NONE], [winsock2.h], [],
+# INADDR_NONE, Solaris lacks this
+AX_CHECK_DEFINE([netinet/in.h], [INADDR_NONE], [],
+ [AX_CHECK_DEFINE([winsock2.h], [INADDR_NONE], [],
[AC_DEFINE([INADDR_NONE], [0xffffffff], [Define INADDR_NONE if not found in <netinet/in.h>])])])
-#### POSIX threads ####
-ACX_PTHREAD
+# _Bool
+AC_CACHE_CHECK([whether $CC knows _Bool],
+ pulseaudio_cv__Bool,
+ [AC_COMPILE_IFELSE(
+ AC_LANG_PROGRAM([], [[_Bool b;]]),
+ [pulseaudio_cv__Bool=yes],
+ [pulseaudio_cv__Bool=no])
+ ])
+
+AS_IF([test "$pulseaudio_cv__Bool" = "yes"], AC_DEFINE([HAVE_STD_BOOL], 1, [Have _Bool.]))
+
+
+#### Thread support ####
+
+AX_TLS
+AS_IF([test "$ac_cv_tls" == "__thread"],
+ AC_DEFINE([SUPPORT_TLS___THREAD], 1, [Define this if the compiler supports __thread for Thread-Local Storage]))
+
+# Win32 build breaks with win32 pthread installed
+AS_IF([test "x$os_is_win32" != "x1"],
+ [AX_PTHREAD])
+
+AS_IF([test "x$ax_pthread_ok" == "xyes"],
+ AC_DEFINE([_POSIX_PTHREAD_SEMANTICS], 1, [Needed on Solaris]))
+
#### Check for libs ####
@@ -382,16 +446,36 @@ AC_SEARCH_LIBS([dlopen], [dl])
AC_SEARCH_LIBS([shm_open], [rt])
AC_SEARCH_LIBS([inet_ntop], [nsl])
AC_SEARCH_LIBS([timer_create], [rt])
+AC_SEARCH_LIBS([pthread_setaffinity_np], [pthread])
+AC_SEARCH_LIBS([pthread_getname_np], [pthread])
+AC_SEARCH_LIBS([pthread_setname_np], [pthread])
# BSD
AC_SEARCH_LIBS([connect], [socket])
+AC_SEARCH_LIBS([backtrace], [execinfo ubacktrace])
-# Non-standard
+# Darwin/OS X
+if test "x$os_is_darwin" = "x1" ; then
+ AC_MSG_CHECKING([looking for Apple CoreService Framework])
+ # How do I check a framework "library" - AC_CHECK_LIB prob. won't work??, just assign LIBS & hope
+ AC_CHECK_HEADER([/Developer/Headers/FlatCarbon/CoreServices.h],
+ [LIBS="$LIBS -framework CoreServices"],
+ [AC_MSG_ERROR([CoreServices.h header file not found])]
+ )
-# This magic is needed so we do not needlessly add static libs to the win32
-# build, disabling its ability to make dlls.
+ AC_MSG_RESULT([ok])
+ AC_DEFINE([HAVE_CLOCK_GETTIME], 1, [Using clock_gettime() replacement])
+ HAVE_BONJOUR=1
+fi
+
+AM_CONDITIONAL([HAVE_BONJOUR], [test "x$HAVE_BONJOUR" = x1])
+
+# Windows
+AC_SEARCH_LIBS([regexec], [pcreposix])
+# This magic is needed so we do not needlessly add static libs to the win32 build, disabling its ability to make dlls.
AC_CHECK_FUNCS([getopt_long], [], [AC_CHECK_LIB([iberty], [getopt_long])])
+
#### Check for functions ####
# ISO
@@ -401,12 +485,12 @@ AC_CHECK_FUNCS_ONCE([lrintf strtof])
AC_FUNC_FORK
AC_FUNC_GETGROUPS
AC_FUNC_SELECT_ARGTYPES
-AC_CHECK_FUNCS_ONCE([chmod chown clock_gettime getaddrinfo getgrgid_r getgrnam_r \
- getpwnam_r getpwuid_r gettimeofday getuid inet_ntop inet_pton mlock nanosleep \
+AC_CHECK_FUNCS_ONCE([chmod chown fstat fchown fchmod clock_gettime getaddrinfo getgrgid_r getgrnam_r \
+ getpwnam_r getpwuid_r gettimeofday getuid mlock nanosleep \
pipe posix_fadvise posix_madvise posix_memalign setpgid setsid shm_open \
- sigaction sleep sysconf pthread_setaffinity_np])
+ sigaction sleep symlink sysconf uname pthread_setaffinity_np pthread_getname_np pthread_setname_np])
AC_CHECK_FUNCS([mkfifo], [HAVE_MKFIFO=1], [HAVE_MKFIFO=0])
-
+AC_SUBST(HAVE_MKFIFO)
AM_CONDITIONAL(HAVE_MKFIFO, test "x$HAVE_MKFIFO" = "x1")
# X/OPEN
@@ -422,105 +506,51 @@ AC_CHECK_FUNCS_ONCE([strerror_r])
AC_CHECK_FUNCS_ONCE([lstat])
# Non-standard
-
-AC_CHECK_FUNCS_ONCE([setresuid setresgid setreuid setregid seteuid setegid ppoll strsignal sig2str strtof_l])
+AC_CHECK_FUNCS_ONCE([setresuid setresgid setreuid setregid seteuid setegid ppoll strsignal sig2str strtof_l pipe2 accept4])
AC_FUNC_ALLOCA
-AC_CACHE_CHECK([for PTHREAD_PRIO_INHERIT],
- pulseaudio_cv_PTHREAD_PRIO_INHERIT,
- [save_CC=$CC; CC=$PTHREAD_CC
- save_CFLAGS=$CFLAGS; CFLAGS=$PTHREAD_CFLAGS
- save_LIBS=$LIBS; LIBS=$PTHREAD_LIBS
- AC_LINK_IFELSE(
- AC_LANG_PROGRAM(
- [[
- #include <pthread.h>
- ]],
- [[int i = PTHREAD_PRIO_INHERIT;]]),
- [pulseaudio_cv_PTHREAD_PRIO_INHERIT=yes],
- [pulseaudio_cv_PTHREAD_PRIO_INHERIT=no])
- CC=$save_CC
- CFLAGS=$save_CFLAGS
- LIBS=$save_LIBS
- ])
-
-AS_IF([test "$pulseaudio_cv_PTHREAD_PRIO_INHERIT" = "yes"], [
- AC_DEFINE([HAVE_PTHREAD_PRIO_INHERIT], 1, [Have PTHREAD_PRIO_INHERIT.])
- ])
-
-AC_DEFINE_UNQUOTED(PA_CFLAGS,"$CFLAGS", [The CFLAGS used during compilation])
-
-#### Large File-Support (LFS) ####
+AC_CHECK_FUNCS([regexec], [HAVE_REGEX=1], [HAVE_REGEX=0])
+AM_CONDITIONAL(HAVE_REGEX, [test "x$HAVE_REGEX" = "x1"])
+# Large File-Support (LFS)
AC_SYS_LARGEFILE
-
# Check for open64 to know if the current system does have open64() and similar functions
AC_CHECK_FUNCS_ONCE([open64])
-#### [lib]iconv ####
-
-AM_ICONV
-
-IT_PROG_INTLTOOL([0.35.0])
-GETTEXT_PACKAGE=pulseaudio
-AC_SUBST([GETTEXT_PACKAGE])
-AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE],["$GETTEXT_PACKAGE"],[Gettext package])
-AM_GLIB_GNU_GETTEXT
-
-pulselocaledir='${prefix}/${DATADIRNAME}/locale'
-AC_SUBST(pulselocaledir)
###################################
# External libraries #
###################################
-#### pkg-config ####
+#### [lib]iconv ####
-PKG_PROG_PKG_CONFIG
+AM_ICONV
#### X11 (optional) ####
AC_ARG_ENABLE([x11],
- AS_HELP_STRING([--disable-x11],[Disable optional X11 support]),
- [
- case "${enableval}" in
- yes) x11=yes ;;
- no) x11=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-x11) ;;
- esac
- ],
- [x11=auto])
-
-if test "x${x11}" != xno ; then
- PKG_CHECK_MODULES(X11, [ x11 ice sm xtst ],
- HAVE_X11=1,
- [
- HAVE_X11=0
- if test "x$x11" = xyes ; then
- AC_MSG_ERROR([*** X11 not found])
- fi
- ])
-else
- HAVE_X11=0
-fi
+ AS_HELP_STRING([--disable-x11],[Disable optional X11 support]))
-if test "x${HAVE_X11}" = x1 ; then
- AC_DEFINE([HAVE_X11], 1, [Have X11?])
-fi
+AS_IF([test "x$enable_x11" != "xno"],
+ [PKG_CHECK_MODULES(X11, [ x11-xcb xcb >= 1.6 ice sm xtst ], HAVE_X11=1, HAVE_X11=0)],
+ HAVE_X11=0)
+
+AS_IF([test "x$enable_x11" = "xyes" && test "x$HAVE_X11" = "x0"],
+ [AC_MSG_ERROR([*** X11 not found])])
AC_SUBST(X11_CFLAGS)
AC_SUBST(X11_LIBS)
AC_SUBST(HAVE_X11)
AM_CONDITIONAL([HAVE_X11], [test "x$HAVE_X11" = x1])
+AS_IF([test "x$HAVE_X11" = "x1"], AC_DEFINE([HAVE_X11], 1, [Have X11?]))
#### Capabilities (optional) ####
CAP_LIBS=''
-AC_ARG_WITH(
- [caps],
- AS_HELP_STRING([--without-caps],[Omit support for POSIX capabilities.]))
+AC_ARG_WITH([caps],
+ AS_HELP_STRING([--without-caps],[Omit support for POSIX capabilities.]))
if test "x${with_caps}" != "xno"; then
AC_SEARCH_LIBS([cap_init], [cap], [], [
@@ -537,9 +567,15 @@ fi
AC_CHECK_HEADERS_ONCE([valgrind/memcheck.h])
+#### json parsing ####
+
+PKG_CHECK_MODULES(LIBJSON, [ json >= 0.9 ])
+AC_SUBST(LIBJSON_CFLAGS)
+AC_SUBST(LIBJSON_LIBS)
+
#### Sound file ####
-PKG_CHECK_MODULES(LIBSNDFILE, [ sndfile >= 1.0.10 ])
+PKG_CHECK_MODULES(LIBSNDFILE, [ sndfile >= 1.0.20 ])
AC_SUBST(LIBSNDFILE_CFLAGS)
AC_SUBST(LIBSNDFILE_LIBS)
@@ -547,714 +583,475 @@ PKG_CHECK_MODULES(LIBSPEEX, [ speexdsp >= 1.2 ])
AC_SUBST(LIBSPEEX_CFLAGS)
AC_SUBST(LIBSPEEX_LIBS)
-#### atomic-ops ###
+#### atomic-ops ####
AC_MSG_CHECKING([whether we need libatomic_ops])
if test "x$need_libatomic_ops" = "xyes"; then
- AC_MSG_RESULT([yes])
- AC_CHECK_HEADERS([atomic_ops.h], [], [
- AC_MSG_ERROR([*** libatomic-ops headers not found])
- ])
-
- # Win32 does not need the lib and breaks horribly if we try to include it
- if test "x$os_is_win32" != "x1" ; then
- LIBS="$LIBS -latomic_ops"
- fi
+ AC_MSG_RESULT([yes])
+ AC_CHECK_HEADERS([atomic_ops.h],
+ [CFLAGS="$CFLAGS -DAO_REQUIRE_CAS"],
+ [AC_MSG_ERROR([*** libatomic-ops headers not found])])
+
+ # Win32 does not need the lib and breaks horribly if we try to include it
+ AS_IF([test "x$os_is_win32" != "x1"], [LIBS="$LIBS -latomic_ops"])
else
- AC_MSG_RESULT([no])
+ AC_MSG_RESULT([no])
fi
#### Libsamplerate support (optional) ####
AC_ARG_ENABLE([samplerate],
- AS_HELP_STRING([--disable-samplerate],[Disable optional libsamplerate support]),
- [
- case "${enableval}" in
- yes) samplerate=yes ;;
- no) samplerate=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-samplerate) ;;
- esac
- ],
- [samplerate=auto])
-
-if test "x${samplerate}" != xno ; then
- PKG_CHECK_MODULES(LIBSAMPLERATE, [ samplerate >= 0.1.0 ],
- HAVE_LIBSAMPLERATE=1,
- [
- HAVE_LIBSAMPLERATE=0
- if test "x$samplerate" = xyes ; then
- AC_MSG_ERROR([*** Libsamplerate not found])
- fi
- ])
-else
- HAVE_LIBSAMPLERATE=0
-fi
+ AS_HELP_STRING([--disable-samplerate],[Disable optional libsamplerate support]))
-if test "x${HAVE_LIBSAMPLERATE}" = x1 ; then
- AC_DEFINE([HAVE_LIBSAMPLERATE], 1, [Have libsamplerate?])
-fi
+AS_IF([test "x$enable_samplerate" != "xno"],
+ [PKG_CHECK_MODULES(LIBSAMPLERATE, [ samplerate >= 0.1.0 ], HAVE_LIBSAMPLERATE=1, HAVE_LIBSAMPLERATE=0)],
+ HAVE_LIBSAMPLERATE=0)
+
+AS_IF([test "x$enable_samplerate" = "xyes" && test "x$HAVE_LIBSAMPLERATE" = "x0"],
+ [AC_MSG_ERROR([*** Libsamplerate not found])])
AC_SUBST(LIBSAMPLERATE_CFLAGS)
AC_SUBST(LIBSAMPLERATE_LIBS)
-AC_SUBST(HAVE_LIBSAMPLERATE)
AM_CONDITIONAL([HAVE_LIBSAMPLERATE], [test "x$HAVE_LIBSAMPLERATE" = x1])
+AS_IF([test "x$HAVE_LIBSAMPLERATE" = "x1"], AC_DEFINE([HAVE_LIBSAMPLERATE], 1, [Have libsamplerate?]))
#### Database support ####
-HAVE_TDB=0
-HAVE_GDBM=0
+AC_ARG_WITH([database],
+ AS_HELP_STRING([--with-database=auto|tdb|gdbm|simple],[Choose database backend.]),[],[with_database=auto])
-AC_ARG_WITH(
- [database],
- AS_HELP_STRING([--with-database=auto|tdb|gdbm],[Choose database backend.]),[],[with_database=auto])
-
-if test "x${with_database}" = "xauto" -o "x${with_database}" = "xtdb" ; then
- PKG_CHECK_MODULES(TDB, [ tdb ],
- [
- HAVE_TDB=1
- with_database=tdb
- ], [
- if test "x${with_database}" = "xtdb" ; then
- AC_MSG_ERROR([*** tdb not found])
- fi
- ])
-fi
-if test "x${with_database}" = "xauto" -o "x${with_database}" = "xgdbm" ; then
- have_gdbm=yes
+AS_IF([test "x$with_database" = "xauto" -o "x$with_database" = "xtdb"],
+ [PKG_CHECK_MODULES(TDB, [ tdb ], HAVE_TDB=1, HAVE_TDB=0)],
+ HAVE_TDB=0)
+AS_IF([test "x$HAVE_TDB" = "x1"], with_database=tdb)
- AC_CHECK_LIB(gdbm, gdbm_open, [], [have_gdbm=no])
- AC_CHECK_HEADERS(gdbm.h, [], [have_gdbm=no])
+AS_IF([test "x$with_database" = "xtdb" && test "x$HAVE_TDB" = "x0"],
+ [AC_MSG_ERROR([*** tdb not found])])
- if test "x${have_gdbm}" = "xyes" ; then
- HAVE_GDBM=1
- GDBM_CFLAGS=
- GDBM_LIBS=-lgdbm
- with_database=gdbm
- elif test "x${with_database}" = "xgdbm"; then
- AC_MSG_ERROR([*** gdbm not found])
- fi
-fi
-if test "x${HAVE_TDB}" != x1 -a "x${HAVE_GDBM}" != x1; then
- AC_MSG_ERROR([*** missing database backend])
-fi
+AS_IF([test "x$with_database" = "xauto" -o "x$with_database" = "xgdbm"],
+ [
+ HAVE_GDBM=1
+ AC_CHECK_LIB(gdbm, gdbm_open, [], HAVE_GDBM=0)
+ AC_CHECK_HEADERS(gdbm.h, [], HAVE_GDBM=0)
+ ],
+ HAVE_GDBM=0)
+AS_IF([test "x$HAVE_GDBM" = "x1"],
+ [
+ with_database=gdbm
+ GDBM_CFLAGS=
+ GDBM_LIBS=-lgdbm
+ ])
-if test "x${HAVE_TDB}" = x1 ; then
- AC_DEFINE([HAVE_TDB], 1, [Have tdb?])
-fi
+AS_IF([test "x$with_database" = "xgdbm" && test "x$HAVE_GDBM" = "x0"],
+ [AC_MSG_ERROR([*** gdbm not found])])
+
+
+AS_IF([test "x$with_database" = "xauto" -o "x$with_database" = "xsimple"],
+ HAVE_SIMPLEDB=1,
+ HAVE_SIMPLEDB=0)
+AS_IF([test "x$HAVE_SIMPLEDB" = "x1"], with_database=simple)
+
+AS_IF([test "x$HAVE_TDB" != x1 -a "x$HAVE_GDBM" != x1 -a "x$HAVE_SIMPLEDB" != x1],
+ AC_MSG_ERROR([*** missing database backend]))
-if test "x${HAVE_GDBM}" = x1 ; then
- AC_DEFINE([HAVE_GDBM], 1, [Have gdbm?])
-fi
AC_SUBST(TDB_CFLAGS)
AC_SUBST(TDB_LIBS)
-AC_SUBST(HAVE_TDB)
AM_CONDITIONAL([HAVE_TDB], [test "x$HAVE_TDB" = x1])
+AS_IF([test "x$HAVE_TDB" = "x1"], AC_DEFINE([HAVE_TDB], 1, [Have tdb?]))
AC_SUBST(GDBM_CFLAGS)
AC_SUBST(GDBM_LIBS)
-AC_SUBST(HAVE_GDBM)
AM_CONDITIONAL([HAVE_GDBM], [test "x$HAVE_GDBM" = x1])
+AS_IF([test "x$HAVE_GDBM" = "x1"], AC_DEFINE([HAVE_GDBM], 1, [Have gdbm?]))
+
+AM_CONDITIONAL([HAVE_SIMPLEDB], [test "x$HAVE_SIMPLEDB" = x1])
+AS_IF([test "x$HAVE_SIMPLEDB" = "x1"], AC_DEFINE([HAVE_SIMPLEDB], 1, [Have simple?]))
#### OSS support (optional) ####
-AC_ARG_ENABLE([oss],
- AS_HELP_STRING([--disable-oss],[Disable optional OSS support]),
- [
- case "${enableval}" in
- yes) oss=yes ;;
- no) oss=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-oss) ;;
- esac
- ],
- [oss=auto])
-
-if test "x${oss}" != xno ; then
- AC_CHECK_HEADERS([sys/soundcard.h],
- [
- HAVE_OSS=1
- AC_DEFINE([HAVE_OSS], 1, [Have OSS?])
- ],
- [
- HAVE_OSS=0
- if test "x$oss" = xyes ; then
- AC_MSG_ERROR([*** OSS support not found])
- fi
- ])
-else
- HAVE_OSS=0
-fi
+AC_ARG_ENABLE([oss-output],
+ AS_HELP_STRING([--disable-oss-output],[Disable optional OSS output support]))
+
+AC_ARG_ENABLE([oss-wrapper],
+ AS_HELP_STRING([--disable-oss-wrapper],[Disable optional OSS wrapper support]))
-AC_SUBST(HAVE_OSS)
-AM_CONDITIONAL([HAVE_OSS], [test "x$HAVE_OSS" = x1])
+AS_IF([test "x$enable_oss_output" != "xno" -o "x$enable_oss_wrapper" != "xno"],
+ [AC_CHECK_HEADERS([sys/soundcard.h], HAVE_OSS=1, HAVE_OSS=0)],
+ HAVE_OSS=0)
+AS_IF([test "x$enable_oss_output" = "xyes" -o "x$enable_oss_wrapper" = "xyes" && test "x$HAVE_OSS" = "x0"],
+ [AC_MSG_ERROR([*** OSS support not found])])
+
+AS_IF([test "x$enable_oss_output" != "xno"],
+ [AS_IF([test "x$HAVE_OSS" = "x1"], HAVE_OSS_OUTPUT=1, HAVE_OSS_OUTPUT=0)],
+ HAVE_OSS_OUTPUT=0)
+
+AS_IF([test "x$enable_oss_wrapper" != "xno"],
+ [AS_IF([test "x$HAVE_OSS" = "x1"], HAVE_OSS_WRAPPER=1, HAVE_OSS_WRAPPER=0)],
+ HAVE_OSS_WRAPPER=0)
+
+AC_SUBST(HAVE_OSS_OUTPUT)
+AM_CONDITIONAL([HAVE_OSS_OUTPUT], [test "x$HAVE_OSS_OUTPUT" = "x1"])
+AM_CONDITIONAL([HAVE_OSS_WRAPPER], [test "x$HAVE_OSS_WRAPPER" = "x1"])
+AS_IF([test "x$HAVE_OSS_OUTPUT" = "x1"], AC_DEFINE([HAVE_OSS_OUTPUT], 1, [Have OSS output?]))
+AS_IF([test "x$HAVE_OSS_WRAPPER" = "x1"], AC_DEFINE([HAVE_OSS_WRAPPER], 1, [Have OSS wrapper (padsp)?]))
+
+#### CoreAudio support (optional) ####
+
+AC_ARG_ENABLE([coreaudio-output],
+ AS_HELP_STRING([--disable-coreaudio-output],[Disable optional CoreAudio output support]))
+
+AS_IF([test "x$enable_coreaudio_output" != "xno"],
+ [AC_CHECK_HEADERS([CoreAudio/CoreAudio.h], HAVE_COREAUDIO=1, HAVE_COREAUDIO=0)],
+ HAVE_COREAUDIO=0)
+
+AS_IF([test "x$enable_coreaudio_output" = "xyes" && test "x$HAVE_COREAUDIO" = "x0"],
+ [AC_MSG_ERROR([*** CoreAudio output support not found])])
+
+AM_CONDITIONAL([HAVE_COREAUDIO], [test "x$HAVE_COREAUDIO" = "x1" && test "x$enable_coreaudio_output" != "xno"])
#### ALSA support (optional) ####
AC_ARG_ENABLE([alsa],
- AS_HELP_STRING([--disable-alsa],[Disable optional ALSA support]),
- [
- case "${enableval}" in
- yes) alsa=yes ;;
- no) alsa=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-alsa) ;;
- esac
- ],
- [alsa=auto])
-
-if test "x${alsa}" != xno ; then
- PKG_CHECK_MODULES(ASOUNDLIB, [ alsa >= 1.0.19 ],
- [
- HAVE_ALSA=1
- AC_DEFINE([HAVE_ALSA], 1, [Have ALSA?])
- ],
- [
- HAVE_ALSA=0
- if test "x$alsa" = xyes ; then
- AC_MSG_ERROR([*** Needed alsa >= 1.0.19 support not found])
- fi
- ])
-else
- HAVE_ALSA=0
-fi
+ AS_HELP_STRING([--disable-alsa],[Disable optional ALSA support]))
+
+AS_IF([test "x$enable_alsa" != "xno"],
+ [PKG_CHECK_MODULES(ASOUNDLIB, [ alsa >= 1.0.19 ], HAVE_ALSA=1, HAVE_ALSA=0)],
+ HAVE_ALSA=0)
+
+AS_IF([test "x$enable_alsa" = "xyes" && test "x$HAVE_ALSA" = "x0"],
+ [AC_MSG_ERROR([*** Needed alsa >= 1.0.19 support not found])])
AC_SUBST(ASOUNDLIB_CFLAGS)
AC_SUBST(ASOUNDLIB_LIBS)
AC_SUBST(HAVE_ALSA)
AM_CONDITIONAL([HAVE_ALSA], [test "x$HAVE_ALSA" = x1])
+AS_IF([test "x$HAVE_ALSA" = "x1"], AC_DEFINE([HAVE_ALSA], 1, [Have ALSA?]))
#### Solaris audio support (optional) ####
AC_ARG_ENABLE([solaris],
- AS_HELP_STRING([--disable-solaris],[Disable optional Solaris audio support]),
- [
- case "${enableval}" in
- yes) solaris=yes ;;
- no) solaris=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-solaris) ;;
- esac
- ],
- [solaris=auto])
-
-if test "x${solaris}" != xno ; then
- AC_CHECK_HEADERS([sys/audio.h],
- [
- HAVE_SOLARIS=1
- AC_DEFINE([HAVE_SOLARIS], 1, [Have Solaris audio?])
- ],
- [
- HAVE_SOLARIS=0
- if test "x$solaris" = xyes ; then
- AC_MSG_ERROR([*** Solaris audio support not found])
- fi
- ])
-else
- HAVE_SOLARIS=0
-fi
+ AS_HELP_STRING([--disable-solaris],[Disable optional Solaris audio support]))
+
+AS_IF([test "x$enable_solaris" != "xno"],
+ [AC_CHECK_HEADERS([sys/audio.h], HAVE_SOLARIS=1, HAVE_SOLARIS=0)],
+ HAVE_SOLARIS=0)
+
+AS_IF([test "x$enable_solaris" = "xyes" && test "x$HAVE_SOLARIS" = "x0"],
+ [AC_MSG_ERROR([*** Solaris audio support not found])])
-AC_SUBST(HAVE_SOLARIS)
AM_CONDITIONAL([HAVE_SOLARIS], [test "x$HAVE_SOLARIS" = x1])
+AS_IF([test "x$HAVE_SOLARIS" = "x1"], AC_DEFINE([HAVE_SOLARIS], 1, [Have Solaris audio?]))
+
+#### WaveOut audio support (optional) ####
+
+AC_ARG_ENABLE([waveout],
+ AS_HELP_STRING([--disable-waveout],[Disable optional WaveOut audio support]))
+
+AS_IF([test "x$enable_waveout" != "xno"],
+ [AC_CHECK_HEADERS([mmsystem.h], HAVE_WAVEOUT=1, HAVE_WAVEOUT=0, [#include <windows.h>])],
+ HAVE_WAVEOUT=0)
+
+AS_IF([test "x$enable_waveout" = "xyes" && test "x$HAVE_WAVEOUT" = "x0"],
+ [AC_MSG_ERROR([*** WaveOut audio support not found])])
+
+AC_SUBST(HAVE_WAVEOUT)
+AM_CONDITIONAL([HAVE_WAVEOUT], [test "x$HAVE_WAVEOUT" = x1])
+AS_IF([test "x$HAVE_WAVEOUT" = "x1"], AC_DEFINE([HAVE_WAVEOUT], 1, [Have WaveOut audio?]))
#### GLib 2 support (optional) ####
AC_ARG_ENABLE([glib2],
- AS_HELP_STRING([--disable-glib2],[Disable optional GLib 2 support]),
- [
- case "${enableval}" in
- yes) glib2=yes ;;
- no) glib2=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-glib2) ;;
- esac
- ],
- [glib2=auto])
-
-if test "x${glib2}" != xno ; then
- PKG_CHECK_MODULES(GLIB20, [ glib-2.0 >= 2.4.0 ],
- HAVE_GLIB20=1,
- [
- HAVE_GLIB20=0
- if test "x$glib2" = xyes ; then
- AC_MSG_ERROR([*** GLib 2 support not found])
- fi
- ])
-else
- HAVE_GLIB20=0
-fi
+ AS_HELP_STRING([--disable-glib2],[Disable optional GLib 2 support]))
+
+AS_IF([test "x$enable_glib2" != "xno"],
+ [PKG_CHECK_MODULES(GLIB20, [ glib-2.0 >= 2.4.0 ], HAVE_GLIB20=1, HAVE_GLIB20=0)],
+ HAVE_GLIB20=0)
+
+AS_IF([test "x$enable_glib2" = "xyes" && test "x$HAVE_GLIB20" = "x0"],
+ [AC_MSG_ERROR([*** GLib 2 support not found])])
AC_SUBST(GLIB20_CFLAGS)
AC_SUBST(GLIB20_LIBS)
-AC_SUBST(HAVE_GLIB20)
AM_CONDITIONAL([HAVE_GLIB20], [test "x$HAVE_GLIB20" = x1])
-
-if test "x$HAVE_GLIB20" = x1 ; then
- AC_DEFINE([HAVE_GLIB], 1, [Have GLIB?])
-fi
+AS_IF([test "x$HAVE_GLIB20" = "x1"], AC_DEFINE([HAVE_GLIB], 1, [Have GLIB?]))
#### GTK2 support (optional) ####
AC_ARG_ENABLE([gtk2],
- AS_HELP_STRING([--disable-gtk2],[Disable optional Gtk+ 2 support]),
- [
- case "${enableval}" in
- yes) gtk2=yes ;;
- no) gtk2=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-gtk2) ;;
- esac
- ],
- [gtk2=auto])
-
-if test "x${gtk2}" != xno ; then
- PKG_CHECK_MODULES(GTK20, [ gtk+-2.0 >= 2.4.0 ],
- HAVE_GTK20=1,
- [
- HAVE_GTK20=0
- if test "x$gtk2" = xyes ; then
- AC_MSG_ERROR([*** Gtk+ 2 support not found])
- fi
- ])
-else
- HAVE_GTK20=0
-fi
+ AS_HELP_STRING([--disable-gtk2],[Disable optional Gtk+ 2 support]))
+
+AS_IF([test "x$enable_gtk2" != "xno"],
+ [PKG_CHECK_MODULES(GTK20, [ gtk+-2.0 >= 2.4.0 ], HAVE_GTK20=1, HAVE_GTK20=0)],
+ HAVE_GTK20=0)
+
+AS_IF([test "x$enable_gtk2" = "xyes" && test "x$HAVE_GTK20" = "x0"],
+ [AC_MSG_ERROR([*** Gtk+ 2 support not found])])
AC_SUBST(GTK20_CFLAGS)
AC_SUBST(GTK20_LIBS)
-AC_SUBST(HAVE_GTK20)
AM_CONDITIONAL([HAVE_GTK20], [test "x$HAVE_GTK20" = x1])
-
-if test "x$HAVE_GTK20" = x1 ; then
- AC_DEFINE([HAVE_GTK], 1, [Have GTK?])
-fi
+AS_IF([test "x$HAVE_GTK20" = "x1"], AC_DEFINE([HAVE_GTK], 1, [Have GTK?]))
#### GConf support (optional) ####
AC_ARG_ENABLE([gconf],
- AS_HELP_STRING([--disable-gconf],[Disable optional GConf support]),
- [
- case "${enableval}" in
- yes) gconf=yes ;;
- no) gconf=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-gconf) ;;
- esac
- ],
- [gconf=auto])
-
-if test "x${gconf}" != xno ; then
- PKG_CHECK_MODULES(GCONF, [ gconf-2.0 >= 2.4.0 ],
- HAVE_GCONF=1,
- [
- HAVE_GCONF=0
- if test "x$gconf" = xyes ; then
- AC_MSG_ERROR([*** GConf support not found])
- fi
- ])
-else
- HAVE_GCONF=0
-fi
+ AS_HELP_STRING([--disable-gconf],[Disable optional GConf support]))
+
+AS_IF([test "x$enable_gconf" != "xno"],
+ [PKG_CHECK_MODULES(GCONF, [ gconf-2.0 >= 2.4.0 gobject-2.0 ], HAVE_GCONF=1, HAVE_GCONF=0)],
+ HAVE_GCONF=0)
+
+AS_IF([test "x$enable_gconf" = "xyes" && test "x$HAVE_GCONF" = "x0"],
+ [AC_MSG_ERROR([*** GConf support not found])])
AC_SUBST(GCONF_CFLAGS)
AC_SUBST(GCONF_LIBS)
-AC_SUBST(HAVE_GCONF)
AM_CONDITIONAL([HAVE_GCONF], [test "x$HAVE_GCONF" = x1])
#### Avahi support (optional) ####
AC_ARG_ENABLE([avahi],
- AS_HELP_STRING([--disable-avahi],[Disable optional Avahi support]),
- [
- case "${enableval}" in
- yes) avahi=yes ;;
- no) avahi=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-avahi) ;;
- esac
- ],
- [avahi=auto])
-
-if test "x${avahi}" != xno ; then
- PKG_CHECK_MODULES(AVAHI, [ avahi-client >= 0.6.0 ],
- HAVE_AVAHI=1,
- [
- HAVE_AVAHI=0
- if test "x$avahi" = xyes ; then
- AC_MSG_ERROR([*** Avahi support not found])
- fi
- ])
-else
- HAVE_AVAHI=0
-fi
+ AS_HELP_STRING([--disable-avahi],[Disable optional Avahi support]))
+
+AS_IF([test "x$enable_avahi" != "xno"],
+ [PKG_CHECK_MODULES(AVAHI, [ avahi-client >= 0.6.0 ], HAVE_AVAHI=1, HAVE_AVAHI=0)],
+ HAVE_AVAHI=0)
+
+AS_IF([test "x$enable_avahi" = "xyes" && test "x$HAVE_AVAHI" = "x0"],
+ [AC_MSG_ERROR([*** Avahi support not found])])
AC_SUBST(AVAHI_CFLAGS)
AC_SUBST(AVAHI_LIBS)
AC_SUBST(HAVE_AVAHI)
AM_CONDITIONAL([HAVE_AVAHI], [test "x$HAVE_AVAHI" = x1])
-### LIBOIL ####
+#### JACK (optional) ####
-PKG_CHECK_MODULES(LIBOIL, [ liboil-0.3 >= 0.3.0 ])
-AC_SUBST(LIBOIL_CFLAGS)
-AC_SUBST(LIBOIL_LIBS)
+AC_ARG_ENABLE([jack],
+ AS_HELP_STRING([--disable-jack],[Disable optional JACK support]))
-### JACK (optional) ####
+AS_IF([test "x$enable_jack" != "xno"],
+ [PKG_CHECK_MODULES(JACK, [ jack >= 0.100 ], HAVE_JACK=1, HAVE_JACK=0)],
+ HAVE_JACK=0)
-AC_ARG_ENABLE([jack],
- AS_HELP_STRING([--disable-jack],[Disable optional JACK support]),
- [
- case "${enableval}" in
- yes) jack=yes ;;
- no) jack=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-jack) ;;
- esac
- ],
- [jack=auto])
-
-if test "x${jack}" != xno ; then
- PKG_CHECK_MODULES(JACK, [ jack >= 0.100 ],
- HAVE_JACK=1,
- [
- HAVE_JACK=0
- if test "x$jack" = xyes ; then
- AC_MSG_ERROR([*** JACK support not found])
- fi
- ])
-else
- HAVE_JACK=0
-fi
+AS_IF([test "x$enable_jack" = "xyes" && test "x$HAVE_JACK" = "x0"],
+ [AC_MSG_ERROR([*** JACK support not found])])
AC_SUBST(JACK_CFLAGS)
AC_SUBST(JACK_LIBS)
-AC_SUBST(HAVE_JACK)
AM_CONDITIONAL([HAVE_JACK], [test "x$HAVE_JACK" = x1])
#### Async DNS support (optional) ####
AC_ARG_ENABLE([asyncns],
- AS_HELP_STRING([--disable-asyncns],[Disable optional Async DNS support]),
- [
- case "${enableval}" in
- yes) asyncns=yes ;;
- no) asyncns=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-asyncns) ;;
- esac
- ],
- [asyncns=auto])
-
-if test "x${asyncns}" != xno ; then
- PKG_CHECK_MODULES(LIBASYNCNS, [ libasyncns >= 0.1 ],
- HAVE_LIBASYNCNS=1,
- [
- HAVE_LIBASYNCNS=0
- if test "x$asyncns" = xyes ; then
- AC_MSG_ERROR([*** Async DNS support not found])
- fi
- ])
-else
- HAVE_LIBASYNCNS=0
-fi
+ AS_HELP_STRING([--disable-asyncns],[Disable optional Async DNS support]))
+
+AS_IF([test "x$enable_asyncns" != "xno"],
+ [PKG_CHECK_MODULES(LIBASYNCNS, [ libasyncns >= 0.1 ], HAVE_LIBASYNCNS=1, HAVE_LIBASYNCNS=0)],
+ HAVE_LIBASYNCNS=0)
+
+AS_IF([test "x$enable_asyncns" = "xyes" && test "x$HAVE_LIBASYNCNS" = "x0"],
+ [AC_MSG_ERROR([*** Async DNS support not found])])
AC_SUBST(LIBASYNCNS_CFLAGS)
AC_SUBST(LIBASYNCNS_LIBS)
-AC_SUBST(HAVE_LIBASYNCNS)
AM_CONDITIONAL([HAVE_LIBASYNCNS], [test "x$HAVE_LIBASYNCNS" = x1])
-
-if test "x$HAVE_LIBASYNCNS" != "x0" ; then
- AC_DEFINE([HAVE_LIBASYNCNS], 1, [Have libasyncns?])
-fi
+AS_IF([test "x$HAVE_LIBASYNCNS" = "x1"], AC_DEFINE([HAVE_LIBASYNCNS], 1, [Have libasyncns?]))
#### TCP wrappers (optional) ####
AC_ARG_ENABLE([tcpwrap],
- AS_HELP_STRING([--disable-tcpwrap],[Disable optional TCP wrappers support]),
- [
- case "${enableval}" in
- yes) tcpwrap=yes ;;
- no) tcpwrap=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-tcpwrap) ;;
- esac
- ],
- [tcpwrap=auto])
-
-if test "x${tcpwrap}" != xno ; then
- ACX_LIBWRAP
- if test "x${LIBWRAP_LIBS}" = x && test "x$tcpwrap" = xyes ; then
- AC_MSG_ERROR([*** TCP wrappers support not found])
- fi
-else
- LIBWRAP_LIBS=
-fi
+ AS_HELP_STRING([--disable-tcpwrap],[Disable optional TCP wrappers support]))
+
+AS_IF([test "x$enable_tcpwrap" != "xno"],
+ [
+ ACX_LIBWRAP
+ AS_IF([test "x$LIBWRAP_LIBS" != "x"], HAVE_TCPWRAP=1, HAVE_TCPWRAP=0)
+ ],
+ HAVE_TCPWRAP=0)
+
+AS_IF([test "x$enable_tcpwrap" = "xyes" && test "x$HAVE_TCPWRAP" = "x0"],
+ [AC_MSG_ERROR([*** TCP wrappers support not found])])
AC_SUBST(LIBWRAP_LIBS)
#### LIRC support (optional) ####
AC_ARG_ENABLE([lirc],
- AS_HELP_STRING([--disable-lirc],[Disable optional LIRC support]),
- [
- case "${enableval}" in
- yes) lirc=yes ;;
- no) lirc=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-lirc) ;;
- esac
- ],
- [lirc=auto])
-
-if test "x${lirc}" != xno ; then
- ACX_LIRC
- if test "x${HAVE_LIRC}" = x0 && test "x$lirc" = xyes ; then
- AC_MSG_ERROR([*** LIRC support not found])
- fi
-else
- HAVE_LIRC=0
-fi
+ AS_HELP_STRING([--disable-lirc],[Disable optional LIRC support]))
+
+LIRC_CFLAGS=
+LIRC_LIBS=
+
+AS_IF([test "x$enable_lirc" != "xno"],
+ [
+ HAVE_LIRC=1
+ AC_CHECK_HEADER(lirc/lirc_client.h, [], [HAVE_LIRC=0])
+ AC_CHECK_LIB(lirc_client, lirc_init, [LIRC_LIBS=-llirc_client], [HAVE_LIRC=0])
+ ],
+ HAVE_LIRC=0)
+
+AS_IF([test "x$enable_lirc" = "xyes" && test "x$HAVE_LIRC" = "x0"],
+ [AC_MSG_ERROR([*** LIRC support not found])])
AC_SUBST(LIRC_CFLAGS)
AC_SUBST(LIRC_LIBS)
AM_CONDITIONAL([HAVE_LIRC], [test "x$HAVE_LIRC" = x1])
-#### HAL support (optional) ####
+#### D-Bus support (optional) ####
+
+AC_ARG_ENABLE([dbus],
+ AS_HELP_STRING([--disable-dbus],[Disable optional D-Bus support]))
+
+AS_IF([test "x$enable_dbus" != "xno"],
+ [PKG_CHECK_MODULES(DBUS, [ dbus-1 >= 1.0.0 ], HAVE_DBUS=1, HAVE_DBUS=0)],
+ HAVE_DBUS=0)
+
+AS_IF([test "x$enable_dbus" = "xyes" && test "x$HAVE_DBUS" = "x0"],
+ [AC_MSG_ERROR([*** D-Bus support not found])])
+
+AS_IF([test "x$HAVE_DBUS" = "x1"],
+ [
+ save_CFLAGS="$CFLAGS"; CFLAGS="$CFLAGS $DBUS_CFLAGS"
+ save_LIBS="$LIBS"; LIBS="$LIBS $DBUS_LIBS"
+ AC_CHECK_FUNCS(dbus_watch_get_unix_fd)
+ CFLAGS="$save_CFLAGS"
+ LIBS="$save_LIBS"
+ ])
+
+AC_SUBST(DBUS_CFLAGS)
+AC_SUBST(DBUS_LIBS)
+AC_SUBST(HAVE_DBUS)
+AM_CONDITIONAL([HAVE_DBUS], [test "x$HAVE_DBUS" = x1])
+AS_IF([test "x$HAVE_DBUS" = "x1"], AC_DEFINE([HAVE_DBUS], 1, [Have D-Bus.]))
+
+PA_MACHINE_ID="${localstatedir}/lib/dbus/machine-id"
+AX_DEFINE_DIR(PA_MACHINE_ID, PA_MACHINE_ID, [D-Bus machine-id file])
+
+#### HAL support (optional), dependant on D-Bus ####
AC_ARG_ENABLE([hal],
- AS_HELP_STRING([--disable-hal],[Disable optional HAL support]),
- [
- case "${enableval}" in
- yes) hal=yes ;;
- no) hal=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-hal) ;;
- esac
- ],
- [hal=auto])
-if test "x${hal}" != xno -a \( "x$HAVE_OSS" = "x1" -o "x$HAVE_ALSA" = "x1" \) ; then
- PKG_CHECK_MODULES(HAL, [ hal >= 0.5.11 ],
- [
- HAVE_HAL=1
- AC_DEFINE([HAVE_HAL], 1, [Have HAL.])
- ],
- [
- HAVE_HAL=0
- if test "x$hal" = xyes ; then
- AC_MSG_ERROR([*** HAL support not found])
- fi
- ])
-else
- HAVE_HAL=0
-fi
+ AS_HELP_STRING([--disable-hal],[Disable optional HAL support]))
+
+AS_IF([test "x$enable_hal" != "xno" -a \( "x$HAVE_OSS" = "x1" -o "x$HAVE_ALSA" = "x1" \)],
+ [PKG_CHECK_MODULES(HAL, [ hal >= 0.5.11 ], HAVE_HAL=1, HAVE_HAL=0)],
+ HAVE_HAL=0)
+AS_IF([test "x$HAVE_DBUS" != "x1"], HAVE_HAL=0)
+
+AS_IF([test "x$enable_hal" = "xyes" && test "x$HAVE_HAL" = "x0"],
+ [AC_MSG_ERROR([*** HAL support not found (requires D-Bus)])])
AC_SUBST(HAL_CFLAGS)
AC_SUBST(HAL_LIBS)
AC_SUBST(HAVE_HAL)
AM_CONDITIONAL([HAVE_HAL], [test "x$HAVE_HAL" = x1])
+AS_IF([test "x$HAVE_HAL" = "x1"], AC_DEFINE([HAVE_HAL], 1, [Have HAL.]))
-#### UDEV support (optional) ####
+#### BlueZ support (optional, dependant on D-Bus) ####
-AC_ARG_ENABLE([udev],
- AS_HELP_STRING([--disable-udev],[Disable optional UDEV support]),
- [
- case "${enableval}" in
- yes) udev=yes ;;
- no) udev=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-udev) ;;
- esac
- ],
- [udev=auto])
-if test "x${udev}" != xno -a \( "x$HAVE_OSS" = "x1" -o "x$HAVE_ALSA" = "x1" \) ; then
- PKG_CHECK_MODULES(UDEV, [ libudev >= 137 ],
- [
- HAVE_UDEV=1
- AC_DEFINE([HAVE_UDEV], 1, [Have UDEV.])
- ],
- [
- HAVE_UDEV=0
- if test "x$udev" = xyes ; then
- AC_MSG_ERROR([*** UDEV support not found])
- fi
- ])
-else
- HAVE_UDEV=0
-fi
-
-AC_SUBST(UDEV_CFLAGS)
-AC_SUBST(UDEV_LIBS)
-AC_SUBST(HAVE_UDEV)
-AM_CONDITIONAL([HAVE_UDEV], [test "x$HAVE_UDEV" = x1])
-
-AC_DEFINE([LIBUDEV_I_KNOW_THE_API_IS_SUBJECT_TO_CHANGE], 1, [I know the API is subject to change.])
+AC_ARG_ENABLE([bluez],
+ AS_HELP_STRING([--disable-bluez],[Disable optional BlueZ support]))
-#### BlueZ support (optional) ####
+AS_IF([test "x$enable_bluez" != "xno"],
+ [PKG_CHECK_MODULES(BLUEZ, [ bluez >= 3.0 ], HAVE_BLUEZ=1, HAVE_BLUEZ=0)],
+ HAVE_BLUEZ=0)
+AS_IF([test "x$HAVE_DBUS" != "x1"], HAVE_BLUEZ=0)
-AC_ARG_ENABLE([bluez],
- AS_HELP_STRING([--disable-bluez],[Disable optional BlueZ support]),
- [
- case "${enableval}" in
- yes) bluez=yes ;;
- no) bluez=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-bluez) ;;
- esac
- ],
- [bluez=auto])
-if test "x${bluez}" != xno ; then
- PKG_CHECK_MODULES(BLUEZ, [ bluez >= 3.0 ],
- HAVE_BLUEZ=1,
- [
- HAVE_BLUEZ=0
- if test "x$bluez" = xyes ; then
- AC_MSG_ERROR([*** BLUEZ support not found])
- fi
- ])
-else
- HAVE_BLUEZ=0
-fi
+AS_IF([test "x$enable_bluez" = "xyes" && test "x$HAVE_BLUEZ" = "x0"],
+ [AC_MSG_ERROR([*** BLUEZ support not found (requires D-Bus)])])
AC_SUBST(BLUEZ_CFLAGS)
AC_SUBST(BLUEZ_LIBS)
AC_SUBST(HAVE_BLUEZ)
AM_CONDITIONAL([HAVE_BLUEZ], [test "x$HAVE_BLUEZ" = x1])
-#### D-Bus support (optional) ####
+#### UDEV support (optional) ####
-AC_ARG_ENABLE([dbus],
- AS_HELP_STRING([--disable-dbus],[Disable optional D-Bus support]),
- [
- case "${enableval}" in
- yes) dbus=yes ;;
- no) dbus=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-dbus) ;;
- esac
- ],
- [dbus=auto])
-
-if test "x$HAVE_HAL" = x1 ; then
- dbus=yes
-fi
+AC_ARG_ENABLE([udev],
+ AS_HELP_STRING([--disable-udev],[Disable optional UDEV support]))
-if test "x${dbus}" != xno || test "x${bluez}" != xno || test "x${hal}" != xno ; then
-
- PKG_CHECK_MODULES(DBUS, [ dbus-1 >= 1.0.0 ],
- [
- HAVE_DBUS=1
- saved_LIBS="$LIBS"
- LIBS="$LIBS $DBUS_LIBS"
- AC_CHECK_FUNCS(dbus_watch_get_unix_fd)
- LIBS="$saved_LIBS"
- AC_DEFINE([HAVE_DBUS], 1, [Have D-Bus.])
- ],
- [
- HAVE_DBUS=0
- if test "x$dbus" = xyes ; then
- AC_MSG_ERROR([*** D-Bus support not found])
- fi
- ])
-else
- HAVE_DBUS=0
-fi
+AS_IF([test "x$enable_udev" != "xno" -a \( "x$HAVE_OSS" = "x1" -o "x$HAVE_ALSA" = "x1" \)],
+ [PKG_CHECK_MODULES(UDEV, [ libudev >= 143 ], HAVE_UDEV=1, HAVE_UDEV=0)],
+ HAVE_UDEV=0)
-AC_SUBST(DBUS_CFLAGS)
-AC_SUBST(DBUS_LIBS)
-AC_SUBST(HAVE_DBUS)
-AM_CONDITIONAL([HAVE_DBUS], [test "x$HAVE_DBUS" = x1])
+AS_IF([test "x$enable_udev" = "xyes" && test "x$HAVE_UDEV" = "x0"],
+ [AC_MSG_ERROR([*** UDEV support not found])])
-#### PolicyKit support (optional) ####
-
-AC_ARG_ENABLE([polkit],
- AS_HELP_STRING([--disable-polkit],[Disable optional PolicyKit support]),
- [
- case "${enableval}" in
- yes) polkit=yes ;;
- no) polkit=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-polkit) ;;
- esac
- ],
- [polkit=auto])
-
-if test "x${polkit}" != xno ; then
-
- PKG_CHECK_MODULES(POLKIT, [ polkit-dbus >= 0.7 ],
- [
- HAVE_POLKIT=1
- AC_DEFINE([HAVE_POLKIT], 1, [Have PolicyKit])
- policydir=`pkg-config polkit-dbus --variable prefix`/share/PolicyKit/policy/
- AC_SUBST(policydir)
- ],
- [
- HAVE_POLKIT=0
- if test "x$polkit" = xyes ; then
- AC_MSG_ERROR([*** PolicyKit support not found])
- fi
- ])
-else
- HAVE_POLKIT=0
-fi
+AC_SUBST(UDEV_CFLAGS)
+AC_SUBST(UDEV_LIBS)
+AC_SUBST(HAVE_UDEV)
+AM_CONDITIONAL([HAVE_UDEV], [test "x$HAVE_UDEV" = x1])
+AS_IF([test "x$HAVE_UDEV" = "x1"], AC_DEFINE([HAVE_UDEV], 1, [Have UDEV.]))
+
+#### HAL compat support (optional, dependant on UDEV) ####
+
+AC_ARG_ENABLE([hal-compat],
+ AS_HELP_STRING([--disable-hal-compat],[Disable optional HAL->udev transition compatibility support]))
+
+AS_IF([test "x$enable_hal_compat" != "xno"],
+ [AS_IF([test "x$HAVE_HAL" = "x0" -a "x$HAVE_UDEV" = "x1"], HAVE_HAL_COMPAT=1, HAVE_HAL_COMPAT=0)],
+ HAVE_HAL_COMPAT=0)
-AC_SUBST(POLKIT_CFLAGS)
-AC_SUBST(POLKIT_LIBS)
-AC_SUBST(HAVE_POLKIT)
-AM_CONDITIONAL([HAVE_POLKIT], [test "x$HAVE_POLKIT" = x1])
+AS_IF([test "x$enable_hal_compat" = "xyes" && test "x$HAVE_HAL_COMPAT" = "x0"],
+ [AC_MSG_ERROR([*** HAL-compat support requires UDEV and no HAL])])
+AM_CONDITIONAL([HAVE_HAL_COMPAT], [test "x$HAVE_HAL_COMPAT" = x1])
+AS_IF([test "x$HAVE_HAL_COMPAT" = "x1"], AC_DEFINE([HAVE_HAL_COMPAT], 1, [Have HAL compatibility.]))
-### IPv6 connection support (optional) ###
+#### IPv6 connection support (optional) ####
AC_ARG_ENABLE([ipv6],
- AS_HELP_STRING([--disable-ipv6],[Disable optional IPv6 support]),
- [
- case "${enableval}" in
- yes) ipv6=yes ;;
- no) ipv6=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-ipv6) ;;
- esac
- ],
- [ipv6=auto])
-
-if test "x${ipv6}" != xno ; then
- AC_DEFINE([HAVE_IPV6], [1], [Define this to enable IPv6 connection support])
- HAVE_IPV6=1
-else
- HAVE_IPV6=0
-fi
+ AS_HELP_STRING([--disable-ipv6],[Disable optional IPv6 support]))
+
+AS_IF([test "x$enable_ipv6" != "xno"], [HAVE_IPV6=1], [HAVE_IPV6=0])
+
+AS_IF([test "x$HAVE_IPV6" = "x1"], AC_DEFINE([HAVE_IPV6], 1, [Define this to enable IPv6 connection support]))
#### OpenSSL support (optional) ####
AC_ARG_ENABLE([openssl],
- AS_HELP_STRING([--disable-openssl],[Disable OpenSSL support (used for Airtunes/RAOP)]),
- [
- case "${enableval}" in
- yes) openssl=yes ;;
- no) openssl=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-openssl) ;;
- esac
- ],
- [openssl=auto])
-
-if test "x${openssl}" != xno ; then
-
- PKG_CHECK_MODULES(OPENSSL, [ openssl > 0.9 ],
- [
- HAVE_OPENSSL=1
- AC_DEFINE([HAVE_OPENSSL], 1, [Have OpenSSL])
- ],
- [
- HAVE_OPENSSL=0
- if test "x$openssl" = xyes ; then
- AC_MSG_ERROR([*** OpenSSL support not found])
- fi
- ])
-else
- HAVE_OPENSSL=0
-fi
+ AS_HELP_STRING([--disable-openssl],[Disable OpenSSL support (used for Airtunes/RAOP)]))
+
+AS_IF([test "x$enable_openssl" != "xno"],
+ [PKG_CHECK_MODULES(OPENSSL, [ openssl > 0.9 ], HAVE_OPENSSL=1, HAVE_OPENSSL=0)],
+ HAVE_OPENSSL=0)
+
+AS_IF([test "x$enable_openssl" = "xyes" && test "x$HAVE_OPENSSL" = "x0"],
+ [AC_MSG_ERROR([*** OpenSSL support not found])])
AC_SUBST(OPENSSL_CFLAGS)
AC_SUBST(OPENSSL_LIBS)
-AC_SUBST(HAVE_OPENSSL)
AM_CONDITIONAL([HAVE_OPENSSL], [test "x$HAVE_OPENSSL" = x1])
+AS_IF([test "x$HAVE_OPENSSL" = "x1"], AC_DEFINE([HAVE_OPENSSL], 1, [Have OpenSSL]))
+
+#### FFTW (optional) ####
+
+AC_ARG_WITH([fftw],
+ AS_HELP_STRING([--without-fftw],[Omit FFTW-using modules (equalizer)]))
-### Build and Install man pages ###
-AC_ARG_ENABLE(manpages,
- AS_HELP_STRING([--disable-manpages],[Disable building and installation of man pages]),
-[case "${enableval}" in
- yes) manpages=yes ;;
- no) manpages=no ;;
- *) AC_MSG_ERROR([bad value ${enableval} for --disable-manpages]) ;;
-esac],[manpages=yes])
+AS_IF([test "x$with_fftw" != "xno"],
+ [PKG_CHECK_MODULES(FFTW, [ fftw3f ], HAVE_FFTW=1, HAVE_FFTW=0)],
+ HAVE_FFTW=0)
-AM_CONDITIONAL([BUILD_MANPAGES], [test "x$manpages" = xyes])
+AS_IF([test "x$with_fftw" = "xyes" && test "x$HAVE_FFTW" = "x0"],
+ [AC_MSG_ERROR([*** FFTW support not found])])
+
+AM_CONDITIONAL([HAVE_FFTW], [test "x$HAVE_FFTW" = "x1"])
+
+#### ORC (optional) ####
+
+ORC_CHECK([0.4.11])
+
+#### Build and Install man pages ####
+
+AC_ARG_ENABLE([manpages],
+ AS_HELP_STRING([--disable-manpages],[Disable building and installation of man pages]))
+
+AM_CONDITIONAL([BUILD_MANPAGES], [test "x$enable_manpages" != "xno"])
#### PulseAudio system group & user #####
@@ -1276,15 +1073,6 @@ fi
AC_SUBST(PA_SYSTEM_GROUP)
AC_DEFINE_UNQUOTED(PA_SYSTEM_GROUP,"$PA_SYSTEM_GROUP", [Group for the PulseAudio system daemon])
-AC_ARG_WITH(realtime_group,AS_HELP_STRING([--with-realtime-group=<group>],[Group for users that are allowed to start the PulseAudio daemon with realtime scheduling (realtime)]))
-if test -z "$with_realtime_group" ; then
- PA_REALTIME_GROUP=pulse-rt
-else
- PA_REALTIME_GROUP=$with_realtime_group
-fi
-AC_SUBST(PA_REALTIME_GROUP)
-AC_DEFINE_UNQUOTED(PA_REALTIME_GROUP,"$PA_REALTIME_GROUP", [Realtime group])
-
AC_ARG_WITH(access_group,AS_HELP_STRING([--with-access-group=<group>],[Group which is allowed access to a system-wide PulseAudio daemon (pulse-access)]))
if test -z "$with_access_group" ; then
PA_ACCESS_GROUP=pulse-access
@@ -1294,45 +1082,91 @@ fi
AC_SUBST(PA_ACCESS_GROUP)
AC_DEFINE_UNQUOTED(PA_ACCESS_GROUP,"$PA_ACCESS_GROUP", [Access group])
-AC_ARG_ENABLE(
- per_user_esound_socket,
- AS_HELP_STRING([--disable-per-user-esound-socket], [Use global esound socket directory /tmp/.esd/socket.]),
- [
- case "${enableval}" in
- yes) per_user_esound_socket=1 ;;
- no) per_user_esound_socket=0 ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --disable-per-user-esound-socket) ;;
- esac
- ],
- [per_user_esound_socket=1])
-
-if test "x$per_user_esound_socket" = "x1"; then
- AC_DEFINE([USE_PER_USER_ESOUND_SOCKET], [1], [Define this if you want per-user esound socket directories])
+AC_ARG_ENABLE([per-user-esound-socket],
+ AS_HELP_STRING([--disable-per-user-esound-socket],[Use global esound socket directory /tmp/.esd/socket.]))
+
+if test "x$enable_per_user_esound_socket" != "xno"; then
+ USE_PER_USER_ESOUND_SOCKET=1
+ AC_DEFINE([USE_PER_USER_ESOUND_SOCKET], [1], [Define this if you want per-user esound socket directories])
+else
+ USE_PER_USER_ESOUND_SOCKET=0
fi
#### PulseAudio system runtime dir ####
+
PA_SYSTEM_RUNTIME_PATH="${localstatedir}/run/pulse"
-AC_SUBST(PA_SYSTEM_RUNTIME_PATH)
+AX_DEFINE_DIR(PA_SYSTEM_RUNTIME_PATH, PA_SYSTEM_RUNTIME_PATH, [System runtime dir])
PA_SYSTEM_CONFIG_PATH="${localstatedir}/lib/pulse"
-AC_SUBST(PA_SYSTEM_CONFIG_PATH)
+AX_DEFINE_DIR(PA_SYSTEM_CONFIG_PATH, PA_SYSTEM_CONFIG_PATH, [System config dir])
PA_SYSTEM_STATE_PATH="${localstatedir}/lib/pulse"
-AC_SUBST(PA_SYSTEM_STATE_PATH)
+AX_DEFINE_DIR(PA_SYSTEM_STATE_PATH, PA_SYSTEM_STATE_PATH, [System state dir])
+
+PA_BINARY=${bindir}/pulseaudio${EXEEXT}
+AX_DEFINE_DIR(PA_BINARY, PA_BINARY, [Location of pulseaudio binary])
+
+PACTL_BINARY=${bindir}/pactl${EXEEXT}
+AX_DEFINE_DIR(PACTL_BINARY, PACTL_BINARY, [Location of pactl binary])
+
+AC_SUBST(PA_SOEXT, [.so])
+
+AC_SUBST(pulseconfdir, ["${sysconfdir}/pulse"])
+AX_DEFINE_DIR(PA_DEFAULT_CONFIG_DIR, pulseconfdir, [Location of configuration files])
+
+AC_DEFINE_UNQUOTED(PA_BUILDDIR, "${ac_pwd}/src", [Location of uninstalled binaries])
+
+#### Mac OSX specific stuff #####
+
+AC_ARG_ENABLE(mac-universal,
+ AS_HELP_STRING([--enable-mac-universal], [Build Mac universal binaries]),
+ enable_mac_universal=$enableval, enable_mac_universal="no")
+
+AC_ARG_WITH(mac-version-min,
+ AS_HELP_STRING([--with-mac-version-min=<version>], [Defines the earliest version of MacOS X that the executables will run on.]),
+ mac_version_min=$withval, mac_version_min="10.5")
+
+AC_ARG_WITH(mac-sysroot,
+ AS_HELP_STRING([--with-mac-sysroot=<path>], [SDK basedir to use as the logical root directory for headers and libraries.]),
+ mac_sysroot=$withval, mac_sysroot="/Developer/SDKs/MacOSX10.5.sdk")
+
+if test "x$os_is_darwin" = "x1" ; then
+ LDFLAGS="$LDFLAGS -isysroot $mac_sysroot -mmacosx-version-min=$mac_version_min"
+ CFLAGS="$CFLAGS -isysroot $mac_sysroot -mmacosx-version-min=$mac_version_min"
+
+ if test "x$enable_mac_universal" = "xyes" ; then
+ mac_arches="-arch i386 -arch x86_64"
+ LDFLAGS="$LDFLAGS $mac_arches"
+ CFLAGS="$CFLAGS $mac_arches"
+ fi
+fi
+
###################################
# Output #
###################################
+AC_DEFINE_UNQUOTED(PA_CFLAGS, "$CFLAGS", [The CFLAGS used during compilation])
+
+# Check whether to build tests by default (as compile-test) or not
+AC_ARG_ENABLE([default-build-tests],
+ AS_HELP_STRING([--disable-default-build-tests], [Build test programs only during make check]))
+AM_CONDITIONAL([BUILD_TESTS_DEFAULT], [test "x$enable_default_build_tests" != "xno"])
+
AC_ARG_ENABLE([legacy-runtime-dir],
AS_HELP_STRING([--disable-legacy-runtime-dir], [Try to connect on legacy (< 0.9.12) socket paths.]))
if test "x$enable_legacy_runtime_dir" != "xno" ; then
AC_DEFINE(ENABLE_LEGACY_RUNTIME_DIR, [1], [Legacy runtime dir])
fi
-AC_ARG_ENABLE(
- [static-bins],
- AS_HELP_STRING([--enable-static-bins],[Statically link executables.]),
- [STATIC_BINS=1], [STATIC_BINS=0])
-AM_CONDITIONAL([STATIC_BINS], [test "x$STATIC_BINS" = "x1"])
+AC_ARG_ENABLE([legacy-database-entry-format],
+ AS_HELP_STRING([--disable-legacy-database-entry-format], [Try to load legacy (< 1.0) database files (card, device and volume restore).]))
+if test "x$enable_legacy_database_entry_format" != "xno" ; then
+ AC_DEFINE(ENABLE_LEGACY_DATABASE_ENTRY_FORMAT, [1], [Legacy database entry format])
+fi
+AC_DEFINE([WIBBLE], 1, [Just a test.])
+
+AC_ARG_ENABLE([static-bins],
+ AS_HELP_STRING([--enable-static-bins],[Statically link executables.]))
+AM_CONDITIONAL([STATIC_BINS], [test "x$enable_static_bins" = "xyes"])
AC_ARG_WITH(
[preopen-mods],
@@ -1350,146 +1184,101 @@ fi
AC_ARG_WITH(
[module-dir],
- AS_HELP_STRING([--with-module-dir],[Directory where to install the modules to (defaults to ${libdir}/pulse-${PA_MAJORMINORMICRO}/modules/]),
- [modlibexecdir=$withval], [modlibexecdir="${libdir}/pulse-${PA_MAJORMINORMICRO}/modules/"])
+ AS_HELP_STRING([--with-module-dir],[Directory where to install the modules to (defaults to ${libdir}/pulse-${PA_MAJORMINOR}/modules]),
+ [modlibexecdir=$withval], [modlibexecdir="${libdir}/pulse-${PA_MAJORMINOR}/modules"])
AC_SUBST(modlibexecdir)
+AX_DEFINE_DIR(PA_DLSEARCHPATH, modlibexecdir, [Modules dir])
+
+AC_ARG_WITH(
+ [udev-rules-dir],
+ AS_HELP_STRING([--with-udev-rules-dir],[Directory where to install udev rules to (defaults to /lib/udev/rules.d)]),
+ [udevrulesdir=$withval], [udevrulesdir="/lib/udev/rules.d"])
+
+AC_SUBST(udevrulesdir)
+
+AC_ARG_ENABLE([force-preopen],
+ AS_HELP_STRING([--enable-force-preopen],[Preopen modules, even when dlopen() is supported.]))
+
+if test "x$enable_force_preopen" = "xyes"; then
+ FORCE_PREOPEN=yes
+else
+ FORCE_PREOPEN=no
+fi
-AC_ARG_ENABLE(
- [force-preopen],
- AS_HELP_STRING([--enable-force-preopen],[Preopen modules, even when dlopen() is supported.]),
- [FORCE_PREOPEN=$enableval], [FORCE_PREOPEN=no])
AM_CONDITIONAL([FORCE_PREOPEN], [test "x$FORCE_PREOPEN" = "xyes"])
AC_CONFIG_FILES([
Makefile
-shave
-shave-libtool
src/Makefile
man/Makefile
libpulse.pc
libpulse-simple.pc
-libpulse-browse.pc
libpulse-mainloop-glib.pc
doxygen/Makefile
doxygen/doxygen.conf
src/pulse/version.h
po/Makefile.in
+man/pulseaudio.1.xml
+man/esdcompat.1.xml
+man/pax11publish.1.xml
+man/paplay.1.xml
+man/pacat.1.xml
+man/pacmd.1.xml
+man/pactl.1.xml
+man/pasuspender.1.xml
+man/padsp.1.xml
+man/pulse-daemon.conf.5.xml
+man/pulse-client.conf.5.xml
+man/default.pa.5.xml
])
-SHAVE_INIT
+AC_CONFIG_FILES([src/esdcompat:src/daemon/esdcompat.in], [chmod +x src/esdcompat])
+AC_CONFIG_FILES([src/start-pulseaudio-x11:src/daemon/start-pulseaudio-x11.in], [chmod +x src/start-pulseaudio-x11])
+AC_CONFIG_FILES([src/start-pulseaudio-kde:src/daemon/start-pulseaudio-kde.in], [chmod +x src/start-pulseaudio-kde])
+AC_CONFIG_FILES([src/client.conf:src/pulse/client.conf.in])
+AC_CONFIG_FILES([src/daemon.conf:src/daemon/daemon.conf.in],
+ [m4 src/daemon.conf > src/daemon.conf.gen && mv src/daemon.conf.gen src/daemon.conf])
+AC_CONFIG_FILES([src/default.pa:src/daemon/default.pa.in],
+ [m4 src/default.pa > src/default.pa.gen && mv src/default.pa.gen src/default.pa])
+AC_CONFIG_FILES([src/system.pa:src/daemon/system.pa.in],
+ [m4 src/system.pa > src/system.pa.gen && mv src/system.pa.gen src/system.pa])
+
AC_OUTPUT
# ==========================================================================
-ENABLE_X11=no
-if test "x$HAVE_X11" = "x1" ; then
- ENABLE_X11=yes
-fi
-
-ENABLE_OSS=no
-if test "x$HAVE_OSS" = "x1" ; then
- ENABLE_OSS=yes
-fi
-
-ENABLE_ALSA=no
-if test "x$HAVE_ALSA" = "x1" ; then
- ENABLE_ALSA=yes
-fi
-
-ENABLE_SOLARIS=no
-if test "x$HAVE_SOLARIS" = "x1" ; then
- ENABLE_SOLARIS=yes
-fi
-
-ENABLE_GTK20=no
-if test "x$HAVE_GTK20" = "x1" ; then
- ENABLE_GTK20=yes
-fi
-
-ENABLE_GLIB20=no
-if test "x$HAVE_GLIB20" = "x1" ; then
- ENABLE_GLIB20=yes
-fi
-
-ENABLE_GCONF=no
-if test "x$HAVE_GCONF" = "x1" ; then
- ENABLE_GCONF=yes
-fi
-ENABLE_AVAHI=no
-if test "x$HAVE_AVAHI" = "x1" ; then
- ENABLE_AVAHI=yes
-fi
-
-ENABLE_JACK=no
-if test "x$HAVE_JACK" = "x1" ; then
- ENABLE_JACK=yes
-fi
-
-ENABLE_LIBASYNCNS=no
-if test "x$HAVE_LIBASYNCNS" = "x1" ; then
- ENABLE_LIBASYNCNS=yes
-fi
-
-ENABLE_LIRC=no
-if test "x$HAVE_LIRC" = "x1" ; then
- ENABLE_LIRC=yes
-fi
-
-ENABLE_HAL=no
-if test "x$HAVE_HAL" = "x1" ; then
- ENABLE_HAL=yes
-fi
-
-ENABLE_UDEV=no
-if test "x$HAVE_UDEV" = "x1" ; then
- ENABLE_UDEV=yes
-fi
-
-ENABLE_TCPWRAP=no
-if test "x${LIBWRAP_LIBS}" != x ; then
- ENABLE_TCPWRAP=yes
-fi
-
-ENABLE_LIBSAMPLERATE=no
-if test "x${HAVE_LIBSAMPLERATE}" = "x1" ; then
- ENABLE_LIBSAMPLERATE=yes
-fi
-
-ENABLE_BLUEZ=no
-if test "x${HAVE_BLUEZ}" = "x1" ; then
- ENABLE_BLUEZ=yes
-fi
-
-ENABLE_POLKIT=no
-if test "x${HAVE_POLKIT}" = "x1" ; then
- ENABLE_POLKIT=yes
-fi
-
-ENABLE_GDBM=no
-if test "x${HAVE_GDBM}" = "x1" ; then
- ENABLE_GDBM=yes
-fi
-
-ENABLE_TDB=no
-if test "x${HAVE_TDB}" = "x1" ; then
- ENABLE_TDB=yes
-fi
-
-ENABLE_OPENSSL=no
-if test "x${HAVE_OPENSSL}" = "x1" ; then
- ENABLE_OPENSSL=yes
-fi
-
-ENABLE_IPV6=no
-if test "x${HAVE_IPV6}" = "x1" ; then
- ENABLE_IPV6=yes
-fi
-
-ENABLE_PER_USER_ESOUND_SOCKET=no
-if test "x$per_user_esound_socket" = "x1" ; then
- ENABLE_PER_USER_ESOUND_SOCKET=yes
-fi
+AS_IF([test "x$HAVE_X11" = "x1"], ENABLE_X11=yes, ENABLE_X11=no)
+AS_IF([test "x$HAVE_OSS_OUTPUT" = "x1"], ENABLE_OSS_OUTPUT=yes, ENABLE_OSS_OUTPUT=no)
+AS_IF([test "x$HAVE_OSS_WRAPPER" = "x1"], ENABLE_OSS_WRAPPER=yes, ENABLE_OSS_WRAPPER=no)
+AS_IF([test "x$HAVE_ALSA" = "x1"], ENABLE_ALSA=yes, ENABLE_ALSA=no)
+AS_IF([test "x$HAVE_COREAUDIO" = "x1"], ENABLE_COREAUDIO=yes, ENABLE_COREAUDIO=no)
+AS_IF([test "x$HAVE_SOLARIS" = "x1"], ENABLE_SOLARIS=yes, ENABLE_SOLARIS=no)
+AS_IF([test "x$HAVE_WAVEOUT" = "x1"], ENABLE_WAVEOUT=yes, ENABLE_WAVEOUT=no)
+AS_IF([test "x$HAVE_GLIB20" = "x1"], ENABLE_GLIB20=yes, ENABLE_GLIB20=no)
+AS_IF([test "x$HAVE_GTK20" = "x1"], ENABLE_GTK20=yes, ENABLE_GTK20=no)
+AS_IF([test "x$HAVE_GCONF" = "x1"], ENABLE_GCONF=yes, ENABLE_GCONF=no)
+AS_IF([test "x$HAVE_AVAHI" = "x1"], ENABLE_AVAHI=yes, ENABLE_AVAHI=no)
+AS_IF([test "x$HAVE_JACK" = "x1"], ENABLE_JACK=yes, ENABLE_JACK=no)
+AS_IF([test "x$HAVE_LIBASYNCNS" = "x1"], ENABLE_LIBASYNCNS=yes, ENABLE_LIBASYNCNS=no)
+AS_IF([test "x$HAVE_LIRC" = "x1"], ENABLE_LIRC=yes, ENABLE_LIRC=no)
+AS_IF([test "x$HAVE_DBUS" = "x1"], ENABLE_DBUS=yes, ENABLE_DBUS=no)
+AS_IF([test "x$HAVE_HAL" = "x1"], ENABLE_HAL=yes, ENABLE_HAL=no)
+AS_IF([test "x$HAVE_UDEV" = "x1"], ENABLE_UDEV=yes, ENABLE_UDEV=no)
+AS_IF([test "x$HAVE_BLUEZ" = "x1"], ENABLE_BLUEZ=yes, ENABLE_BLUEZ=no)
+AS_IF([test "x$HAVE_HAL_COMPAT" = "x1"], ENABLE_HAL_COMPAT=yes, ENABLE_HAL_COMPAT=no)
+AS_IF([test "x$HAVE_TCPWRAP" = "x1"], ENABLE_TCPWRAP=yes, ENABLE_TCPWRAP=no)
+AS_IF([test "x$HAVE_LIBSAMPLERATE" = "x1"], ENABLE_LIBSAMPLERATE=yes, ENABLE_LIBSAMPLERATE=no)
+AS_IF([test "x$HAVE_IPV6" = "x1"], ENABLE_IPV6=yes, ENABLE_IPV6=no)
+AS_IF([test "x$HAVE_OPENSSL" = "x1"], ENABLE_OPENSSL=yes, ENABLE_OPENSSL=no)
+AS_IF([test "x$HAVE_FFTW" = "x1"], ENABLE_FFTW=yes, ENABLE_FFTW=no)
+AS_IF([test "x$HAVE_ORC" = "xyes"], ENABLE_ORC=yes, ENABLE_ORC=no)
+AS_IF([test "x$HAVE_TDB" = "x1"], ENABLE_TDB=yes, ENABLE_TDB=no)
+AS_IF([test "x$HAVE_GDBM" = "x1"], ENABLE_GDBM=yes, ENABLE_GDBM=no)
+AS_IF([test "x$HAVE_SIMPLEDB" = "x1"], ENABLE_SIMPLEDB=yes, ENABLE_SIMPLEDB=no)
+AS_IF([test "x$USE_PER_USER_ESOUND_SOCKET" = "x1"], ENABLE_PER_USER_ESOUND_SOCKET=yes, ENABLE_PER_USER_ESOUND_SOCKET=no)
+AS_IF([test "x$enable_legacy_runtime_dir" != "xno"], ENABLE_LEGACY_RUNTIME_DIR=yes, ENABLE_LEGACY_RUNTIME_DIR=no)
+AS_IF([test "x$enable_legacy_database_entry_format" != "xno"], ENABLE_LEGACY_DATABASE_ENTRY_FORMAT=yes, ENABLE_LEGACY_DATABASE_ENTRY_FORMAT=no)
echo "
---{ $PACKAGE_NAME $VERSION }---
@@ -1497,16 +1286,21 @@ echo "
prefix: ${prefix}
sysconfdir: ${sysconfdir}
localstatedir: ${localstatedir}
+ modlibexecdir: ${modlibexecdir}
System Runtime Path: ${PA_SYSTEM_RUNTIME_PATH}
System State Path: ${PA_SYSTEM_STATE_PATH}
System Config Path: ${PA_SYSTEM_CONFIG_PATH}
Compiler: ${CC}
CFLAGS: ${CFLAGS}
+ LIBS: ${LIBS}
- Have X11: ${ENABLE_X11}
- Enable OSS: ${ENABLE_OSS}
+ Enable X11: ${ENABLE_X11}
+ Enable OSS Output: ${ENABLE_OSS_OUTPUT}
+ Enable OSS Wrapper: ${ENABLE_OSS_WRAPPER}
Enable Alsa: ${ENABLE_ALSA}
+ Enable CoreAudio: ${ENABLE_COREAUDIO}
Enable Solaris: ${ENABLE_SOLARIS}
+ Enable WaveOut: ${ENABLE_WAVEOUT}
Enable GLib 2.0: ${ENABLE_GLIB20}
Enable Gtk+ 2.0: ${ENABLE_GTK20}
Enable GConf: ${ENABLE_GCONF}
@@ -1514,22 +1308,53 @@ echo "
Enable Jack: ${ENABLE_JACK}
Enable Async DNS: ${ENABLE_LIBASYNCNS}
Enable LIRC: ${ENABLE_LIRC}
- Enable HAL: ${ENABLE_HAL}
+ Enable D-Bus: ${ENABLE_DBUS}
+ Enable HAL: ${ENABLE_HAL}
+ Enable BlueZ: ${ENABLE_BLUEZ}
Enable udev: ${ENABLE_UDEV}
- Enable BlueZ: ${ENABLE_BLUEZ}
+ Enable HAL->udev compat: ${ENABLE_HAL_COMPAT}
Enable TCP Wrappers: ${ENABLE_TCPWRAP}
Enable libsamplerate: ${ENABLE_LIBSAMPLERATE}
- Enable PolicyKit: ${ENABLE_POLKIT}
Enable IPv6: ${ENABLE_IPV6}
Enable OpenSSL (for Airtunes): ${ENABLE_OPENSSL}
- Enable tdb: ${ENABLE_TDB}
- Enable gdbm: ${ENABLE_GDBM}
+ Enable fftw: ${ENABLE_FFTW}
+ Enable orc: ${ENABLE_ORC}
+ Database
+ tdb: ${ENABLE_TDB}
+ gdbm: ${ENABLE_GDBM}
+ simple database: ${ENABLE_SIMPLEDB}
System User: ${PA_SYSTEM_USER}
System Group: ${PA_SYSTEM_GROUP}
- Realtime Group: ${PA_REALTIME_GROUP}
Access Group: ${PA_ACCESS_GROUP}
Enable per-user EsounD socket: ${ENABLE_PER_USER_ESOUND_SOCKET}
Force preopen: ${FORCE_PREOPEN}
Preopened modules: ${PREOPEN_MODS}
+
+ Legacy Runtime Dir Support: ${ENABLE_LEGACY_RUNTIME_DIR}
+ Legacy Database Entry Support: ${ENABLE_LEGACY_DATABASE_ENTRY_FORMAT}
"
+
+if test "${ENABLE_DBUS}" = "no" && test "x$os_is_win32" != "x1" ; then
+ echo "
+===== WARNING WARNING WARNING WARNING WARNING WARNING WARNING =====
+You do not have D-Bus support enabled. It is strongly recommended
+that you enable D-Bus support if your platform supports it.
+Many parts of PulseAudio use D-Bus, from ConsoleKit interaction
+to the Device Reservation Protocol to speak to JACK, Bluetooth
+support and even a native control protocol for communicating and
+controling the PulseAudio daemon itself.
+===== WARNING WARNING WARNING WARNING WARNING WARNING WARNING =====
+"
+fi
+
+if test "${ENABLE_UDEV}" = "no" && test "x$os_is_win32" != "x1" ; then
+ echo "
+===== WARNING WARNING WARNING WARNING WARNING WARNING WARNING =====
+You do not have udev support enabled. It is strongly recommended
+that you enable udev support if your platform supports it as it is
+the primary method used to detect hardware audio devices (on Linux)
+and is thus a critical part of PulseAudio on that platform.
+===== WARNING WARNING WARNING WARNING WARNING WARNING WARNING =====
+"
+fi
diff --git a/doxygen/doxygen.conf.in b/doxygen/doxygen.conf.in
index 6c2021ce..0306114b 100644
--- a/doxygen/doxygen.conf.in
+++ b/doxygen/doxygen.conf.in
@@ -417,7 +417,7 @@ WARN_LOGFILE =
# directories like "/usr/src/myproject". Separate the files or directories
# with spaces.
-INPUT = ../src/pulse/context.h ../src/pulse/stream.h ../src/pulse/pulseaudio.h ../src/pulse/sample.h ../src/pulse/def.h ../src/pulse/subscribe.h ../src/pulse/introspect.h ../src/pulse/scache.h ../src/pulse/mainloop-api.h ../src/pulse/glib-mainloop.h ../src/pulse/mainloop.h ../src/pulse/mainloop-signal.h ../src/pulse/error.h ../src/pulse/operation.h ../src/pulse/simple.h ../src/pulse/version.h ../src/pulse/volume.h ../src/pulse/channelmap.h ../src/pulse/thread-mainloop.h ../src/pulse/xmalloc.h ../src/pulse/utf8.h ../src/pulse/util.h ../src/pulse/timeval.h ../src/pulse/proplist.h ../src/pulse/gccmacro.h ../src/pulse/ext-stream-restore.h
+INPUT = ../src/pulse/context.h ../src/pulse/stream.h ../src/pulse/pulseaudio.h ../src/pulse/sample.h ../src/pulse/def.h ../src/pulse/subscribe.h ../src/pulse/introspect.h ../src/pulse/scache.h ../src/pulse/mainloop-api.h ../src/pulse/glib-mainloop.h ../src/pulse/mainloop.h ../src/pulse/mainloop-signal.h ../src/pulse/error.h ../src/pulse/operation.h ../src/pulse/simple.h ../src/pulse/version.h ../src/pulse/volume.h ../src/pulse/channelmap.h ../src/pulse/thread-mainloop.h ../src/pulse/xmalloc.h ../src/pulse/utf8.h ../src/pulse/util.h ../src/pulse/timeval.h ../src/pulse/proplist.h ../src/pulse/gccmacro.h ../src/pulse/ext-stream-restore.h ../src/pulse/rtclock.h ../src/pulse/format.h
# If the value of the INPUT tag contains directories, you can use the
# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp
diff --git a/git-version-gen b/git-version-gen
index 710870cd..6181ad92 100755
--- a/git-version-gen
+++ b/git-version-gen
@@ -1,6 +1,6 @@
#!/bin/sh
# Print a version string.
-scriptversion=2008-04-08.07
+scriptversion=2008-04-08.07.01
# Copyright (C) 2007-2008 Free Software Foundation
#
@@ -67,6 +67,7 @@ scriptversion=2008-04-08.07
# echo $(VERSION) > $@-t && mv $@-t $@
# dist-hook:
# echo $(VERSION) > $(distdir)/.tarball-version
+# echo $(VERSION) > $(distdir)/.version
case $# in
1) ;;
@@ -76,6 +77,7 @@ esac
tarball_version_file=$1
nl='
'
+v=
# First see if there is a tarball-only version file.
# then try "git describe", then default.
@@ -95,33 +97,41 @@ if test -n "$v"
then
: # use $v
elif test -d .git \
- && v=`git describe --abbrev=4 --match='v*' HEAD 2>/dev/null \
- || git describe --abbrev=4 HEAD 2>/dev/null` \
- && case $v in
- v[0-9]*) ;;
- *) (exit 1) ;;
- esac
+ && v=`git describe --abbrev=4 --match='v[0-9]*' HEAD 2>/dev/null` \
+ && [ -n "$v" ]
then
+ # If we are on a "dev" tag, we need to check that it is not the same
+ # reference as the a previous version tag (this only happens when we are
+ # working with a release tag).
+ # NB The below trick relies on the $v being an exact tag to work which
+ # will only work when HEAD == tag. When further commits have been made on top
+ # of the tag, the $v will be supplimented with the number of commits since
+ # that tag and the commit ref of the most recent commit and thus will
+ # fail the test below (as intended)
+ v2=`git describe --abbrev=4 --match='v[0-9]\.[0-9]' --contains $v 2>/dev/null | cut -d'^' -f1`
+ [ -n "$v2" ] && v=$v2
+
# Is this a new git that lists number of commits since the last
# tag or the previous older version that did not?
# Newer: v6.10-77-g0f8faeb
# Older: v6.10-g0f8faeb
- case $v in
- *-*-*) : git describe is okay three part flavor ;;
- *-*)
- : git describe is older two part flavor
- # Recreate the number of commits and rewrite such that the
- # result is the same as if we were using the newer version
- # of git describe.
- vtag=`echo "$v" | sed 's/-.*//'`
- numcommits=`git rev-list "$vtag"..HEAD | wc -l`
- v=`echo "$v" | sed "s/\(.*\)-\(.*\)/\1-$numcommits-\2/"`;
- ;;
- esac
+# case $v in
+# *-*-*) : git describe is okay three part flavor ;;
+# *-*)
+# : git describe is older two part flavor
+# # Recreate the number of commits and rewrite such that the
+# # result is the same as if we were using the newer version
+# # of git describe.
+# vtag=`echo "$v" | sed 's/-.*//'`
+# numcommits=`git rev-list "$vtag"..HEAD | wc -l`
+# v=`echo "$v" | sed "s/\(.*\)-\(.*\)/\1-$numcommits-\2/"`;
+# ;;
+# esac
# Change the first '-' to a '.', so version-comparing tools work properly.
# Remove the "g" in git describe's output string, to save a byte.
- v=`echo "$v" | sed 's/-/./;s/\(.*\)-g/\1-/'`;
+# v=`echo "$v" | sed 's/-/./;s/\(.*\)-g/\1-/'`;
+ :
else
v=UNKNOWN
fi
diff --git a/libpulse-browse.pc.in b/libpulse-browse.pc.in
deleted file mode 100644
index 54705b3f..00000000
--- a/libpulse-browse.pc.in
+++ /dev/null
@@ -1,12 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: libpulse-browse
-Description: PulseAudio Network Browsing Interface
-Version: @PACKAGE_VERSION@
-Libs: -L${libdir} -lpulse-browse @PTHREAD_LIBS@
-Libs.private: -lpulsecommon-@PA_MAJORMINORMICRO@
-Cflags: -I${includedir} -D_REENTRANT
-Requires: libpulse
diff --git a/libpulse-mainloop-glib.pc.in b/libpulse-mainloop-glib.pc.in
index 45ae47c7..72631c92 100644
--- a/libpulse-mainloop-glib.pc.in
+++ b/libpulse-mainloop-glib.pc.in
@@ -7,6 +7,6 @@ Name: libpulse-mainloop-glib
Description: PulseAudio GLib 2.0 Main Loop Wrapper
Version: @PACKAGE_VERSION@
Libs: -L${libdir} -lpulse-mainloop-glib @PTHREAD_LIBS@
-Libs.private: -lpulsecommon-@PA_MAJORMINORMICRO@
+Libs.private: -lpulsecommon-@PA_MAJORMINOR@
Cflags: -I${includedir} -D_REENTRANT
Requires: libpulse glib-2.0
diff --git a/libpulse-simple.pc.in b/libpulse-simple.pc.in
index 443be289..ce969765 100644
--- a/libpulse-simple.pc.in
+++ b/libpulse-simple.pc.in
@@ -7,6 +7,6 @@ Name: libpulse-simple
Description: PulseAudio Simplified Synchronous Client Interface
Version: @PACKAGE_VERSION@
Libs: -L${libdir} -lpulse-simple @PTHREAD_LIBS@
-Libs.private: -lpulsecommon-@PA_MAJORMINORMICRO@
+Libs.private: -lpulsecommon-@PA_MAJORMINOR@
Cflags: -I${includedir} -D_REENTRANT
Requires: libpulse
diff --git a/libpulse.pc.in b/libpulse.pc.in
index c78b1231..b437255f 100644
--- a/libpulse.pc.in
+++ b/libpulse.pc.in
@@ -8,5 +8,5 @@ Name: libpulse
Description: PulseAudio Client Interface
Version: @PACKAGE_VERSION@
Libs: -L${libdir} -lpulse @PTHREAD_LIBS@
-Libs.private: -lpulsecommon-@PA_MAJORMINORMICRO@
+Libs.private: -lpulsecommon-@PA_MAJORMINOR@
Cflags: -I${includedir} -D_REENTRANT
diff --git a/m4/acx_lirc.m4 b/m4/acx_lirc.m4
deleted file mode 100644
index d3f8ea73..00000000
--- a/m4/acx_lirc.m4
+++ /dev/null
@@ -1,6 +0,0 @@
-AC_DEFUN([ACX_LIRC], [
-LIRC_CFLAGS=
-LIRC_LIBS=
-AC_CHECK_HEADER(lirc/lirc_client.h,[AC_CHECK_LIB(lirc_client,lirc_init,[HAVE_LIRC=1
-LIRC_LIBS=-llirc_client],HAVE_LIRC=0)],HAVE_LIRC=0)
-])
diff --git a/m4/acx_pthread.m4 b/m4/acx_pthread.m4
deleted file mode 100644
index cbd6bfa0..00000000
--- a/m4/acx_pthread.m4
+++ /dev/null
@@ -1,348 +0,0 @@
-dnl @synopsis ACX_PTHREAD([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
-dnl
-dnl @summary figure out how to build C programs using POSIX threads
-dnl
-dnl This macro figures out how to build C programs using POSIX threads.
-dnl It sets the PTHREAD_LIBS output variable to the threads library and
-dnl linker flags, and the PTHREAD_CFLAGS output variable to any special
-dnl C compiler flags that are needed. (The user can also force certain
-dnl compiler flags/libs to be tested by setting these environment
-dnl variables.)
-dnl
-dnl Also sets PTHREAD_CC to any special C compiler that is needed for
-dnl multi-threaded programs (defaults to the value of CC otherwise).
-dnl (This is necessary on AIX to use the special cc_r compiler alias.)
-dnl
-dnl NOTE: You are assumed to not only compile your program with these
-dnl flags, but also link it with them as well. e.g. you should link
-dnl with $PTHREAD_CC $CFLAGS $PTHREAD_CFLAGS $LDFLAGS ... $PTHREAD_LIBS
-dnl $LIBS
-dnl
-dnl If you are only building threads programs, you may wish to use
-dnl these variables in your default LIBS, CFLAGS, and CC:
-dnl
-dnl LIBS="$PTHREAD_LIBS $LIBS"
-dnl CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
-dnl CC="$PTHREAD_CC"
-dnl
-dnl In addition, if the PTHREAD_CREATE_JOINABLE thread-attribute
-dnl constant has a nonstandard name, defines PTHREAD_CREATE_JOINABLE to
-dnl that name (e.g. PTHREAD_CREATE_UNDETACHED on AIX).
-dnl
-dnl ACTION-IF-FOUND is a list of shell commands to run if a threads
-dnl library is found, and ACTION-IF-NOT-FOUND is a list of commands to
-dnl run it if it is not found. If ACTION-IF-FOUND is not specified, the
-dnl default action will define HAVE_PTHREAD.
-dnl
-dnl Please let the authors know if this macro fails on any platform, or
-dnl if you have any other suggestions or comments. This macro was based
-dnl on work by SGJ on autoconf scripts for FFTW (www.fftw.org) (with
-dnl help from M. Frigo), as well as ac_pthread and hb_pthread macros
-dnl posted by Alejandro Forero Cuervo to the autoconf macro repository.
-dnl We are also grateful for the helpful feedback of numerous users.
-dnl
-dnl @category InstalledPackages
-dnl @author Steven G. Johnson <stevenj@alum.mit.edu>
-dnl @version 2006-05-29
-dnl @license GPLWithACException
-dnl
-dnl Checks for GCC shared/pthread inconsistency based on work by
-dnl Marcin Owsiany <marcin@owsiany.pl>
-
-
-AC_DEFUN([ACX_PTHREAD], [
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_LANG_SAVE
-AC_LANG_C
-acx_pthread_ok=no
-
-# We used to check for pthread.h first, but this fails if pthread.h
-# requires special compiler flags (e.g. on True64 or Sequent).
-# It gets checked for in the link test anyway.
-
-# First of all, check if the user has set any of the PTHREAD_LIBS,
-# etcetera environment variables, and if threads linking works using
-# them:
-if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
- save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- save_LIBS="$LIBS"
- LIBS="$PTHREAD_LIBS $LIBS"
- AC_MSG_CHECKING([for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS])
- AC_TRY_LINK_FUNC(pthread_join, acx_pthread_ok=yes)
- AC_MSG_RESULT($acx_pthread_ok)
- if test x"$acx_pthread_ok" = xno; then
- PTHREAD_LIBS=""
- PTHREAD_CFLAGS=""
- fi
- LIBS="$save_LIBS"
- CFLAGS="$save_CFLAGS"
-fi
-
-# We must check for the threads library under a number of different
-# names; the ordering is very important because some systems
-# (e.g. DEC) have both -lpthread and -lpthreads, where one of the
-# libraries is broken (non-POSIX).
-
-# Create a list of thread flags to try. Items starting with a "-" are
-# C compiler flags, and other items are library names, except for "none"
-# which indicates that we try without any flags at all, and "pthread-config"
-# which is a program returning the flags for the Pth emulation library.
-
-acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
-
-# The ordering *is* (sometimes) important. Some notes on the
-# individual items follow:
-
-# pthreads: AIX (must check this before -lpthread)
-# none: in case threads are in libc; should be tried before -Kthread and
-# other compiler flags to prevent continual compiler warnings
-# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
-# -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
-# lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
-# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
-# -pthreads: Solaris/gcc
-# -mthreads: Mingw32/gcc, Lynx/gcc
-# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
-# doesn't hurt to check since this sometimes defines pthreads too;
-# also defines -D_REENTRANT)
-# ... -mt is also the pthreads flag for HP/aCC
-# pthread: Linux, etcetera
-# --thread-safe: KAI C++
-# pthread-config: use pthread-config program (for GNU Pth library)
-
-case "${host_cpu}-${host_os}" in
- *solaris*)
-
- # On Solaris (at least, for some versions), libc contains stubbed
- # (non-functional) versions of the pthreads routines, so link-based
- # tests will erroneously succeed. (We need to link with -pthreads/-mt/
- # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
- # a function called by this macro, so we could check for that, but
- # who knows whether they'll stub that too in a future libc.) So,
- # we'll just look for -pthreads and -lpthread first:
-
- acx_pthread_flags="-pthreads pthread -mt -pthread $acx_pthread_flags"
- ;;
-esac
-
-if test x"$acx_pthread_ok" = xno; then
-for flag in $acx_pthread_flags; do
-
- case $flag in
- none)
- AC_MSG_CHECKING([whether pthreads work without any flags])
- ;;
-
- -*)
- AC_MSG_CHECKING([whether pthreads work with $flag])
- PTHREAD_CFLAGS="$flag"
- ;;
-
- pthread-config)
- AC_CHECK_PROG(acx_pthread_config, pthread-config, yes, no)
- if test x"$acx_pthread_config" = xno; then continue; fi
- PTHREAD_CFLAGS="`pthread-config --cflags`"
- PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
- ;;
-
- *)
- AC_MSG_CHECKING([for the pthreads library -l$flag])
- PTHREAD_LIBS="-l$flag"
- ;;
- esac
-
- save_LIBS="$LIBS"
- save_CFLAGS="$CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
-
- # Check for various functions. We must include pthread.h,
- # since some functions may be macros. (On the Sequent, we
- # need a special flag -Kthread to make this header compile.)
- # We check for pthread_join because it is in -lpthread on IRIX
- # while pthread_create is in libc. We check for pthread_attr_init
- # due to DEC craziness with -lpthreads. We check for
- # pthread_cleanup_push because it is one of the few pthread
- # functions on Solaris that doesn't have a non-functional libc stub.
- # We try pthread_create on general principles.
- AC_TRY_LINK([#include <pthread.h>],
- [pthread_t th; pthread_join(th, 0);
- pthread_attr_init(0); pthread_cleanup_push(0, 0);
- pthread_create(0,0,0,0); pthread_cleanup_pop(0); ],
- [acx_pthread_ok=yes])
-
- LIBS="$save_LIBS"
- CFLAGS="$save_CFLAGS"
-
- AC_MSG_RESULT($acx_pthread_ok)
- if test "x$acx_pthread_ok" = xyes; then
- break;
- fi
-
- PTHREAD_LIBS=""
- PTHREAD_CFLAGS=""
-done
-fi
-
-# Various other checks:
-if test "x$acx_pthread_ok" = xyes; then
- save_LIBS="$LIBS"
- LIBS="$PTHREAD_LIBS $LIBS"
- save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
-
- # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
- AC_MSG_CHECKING([for joinable pthread attribute])
- attr_name=unknown
- for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
- AC_TRY_LINK([#include <pthread.h>], [int attr=$attr; return attr;],
- [attr_name=$attr; break])
- done
- AC_MSG_RESULT($attr_name)
- if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
- AC_DEFINE_UNQUOTED(PTHREAD_CREATE_JOINABLE, $attr_name,
- [Define to necessary symbol if this constant
- uses a non-standard name on your system.])
- fi
-
- AC_MSG_CHECKING([if more special flags are required for pthreads])
- flag=no
- case "${host_cpu}-${host_os}" in
- *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
- *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
- esac
- AC_MSG_RESULT(${flag})
- if test "x$flag" != xno; then
- PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
- fi
-
- LIBS="$save_LIBS"
- CFLAGS="$save_CFLAGS"
- # More AIX lossage: must compile with xlc_r or cc_r
- if test x"$GCC" != xyes; then
- AC_CHECK_PROGS(PTHREAD_CC, xlc_r cc_r, ${CC})
- else
- PTHREAD_CC=$CC
- fi
-
- # The next part tries to detect GCC inconsistency with -shared on some
- # architectures and systems. The problem is that in certain
- # configurations, when -shared is specified, GCC "forgets" to
- # internally use various flags which are still necessary.
-
- AC_MSG_CHECKING([whether to check for GCC pthread/shared inconsistencies])
- check_inconsistencies=yes
- case "${host_cpu}-${host_os}" in
- *-darwin*) check_inconsistencies=no ;;
- esac
- if test x"$GCC" != xyes -o "x$check_inconsistencies" != xyes ; then
- AC_MSG_RESULT([no])
- else
- AC_MSG_RESULT([yes])
-
- # In order not to create several levels of indentation, we test
- # the value of "$ok" until we find out the cure or run out of
- # ideas.
- ok="no"
-
- #
- # Prepare the flags
- #
- save_CFLAGS="$CFLAGS"
- save_LIBS="$LIBS"
- save_CC="$CC"
- # Try with the flags determined by the earlier checks.
- #
- # -Wl,-z,defs forces link-time symbol resolution, so that the
- # linking checks with -shared actually have any value
- #
- # FIXME: -fPIC is required for -shared on many architectures,
- # so we specify it here, but the right way would probably be to
- # properly detect whether it is actually required.
- CFLAGS="-shared -fPIC -Wl,-z,defs $CFLAGS $PTHREAD_CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
- CC="$PTHREAD_CC"
-
- AC_MSG_CHECKING([whether -pthread is sufficient with -shared])
- AC_TRY_LINK([#include <pthread.h>],
- [pthread_t th; pthread_join(th, 0);
- pthread_attr_init(0); pthread_cleanup_push(0, 0);
- pthread_create(0,0,0,0); pthread_cleanup_pop(0); ],
- [ok=yes])
-
- if test "x$ok" = xyes; then
- AC_MSG_RESULT([yes])
- else
- AC_MSG_RESULT([no])
- fi
-
- #
- # Linux gcc on some architectures such as mips/mipsel forgets
- # about -lpthread
- #
- if test x"$ok" = xno; then
- AC_MSG_CHECKING([whether -lpthread fixes that])
- LIBS="-lpthread $PTHREAD_LIBS $save_LIBS"
- AC_TRY_LINK([#include <pthread.h>],
- [pthread_t th; pthread_join(th, 0);
- pthread_attr_init(0); pthread_cleanup_push(0, 0);
- pthread_create(0,0,0,0); pthread_cleanup_pop(0); ],
- [ok=yes])
-
- if test "x$ok" = xyes; then
- AC_MSG_RESULT([yes])
- PTHREAD_LIBS="-lpthread $PTHREAD_LIBS"
- else
- AC_MSG_RESULT([no])
- fi
- fi
- #
- # FreeBSD 4.10 gcc forgets to use -lc_r instead of -lc
- #
- if test x"$ok" = xno; then
- AC_MSG_CHECKING([whether -lc_r fixes that])
- LIBS="-lc_r $PTHREAD_LIBS $save_LIBS"
- AC_TRY_LINK([#include <pthread.h>],
- [pthread_t th; pthread_join(th, 0);
- pthread_attr_init(0); pthread_cleanup_push(0, 0);
- pthread_create(0,0,0,0); pthread_cleanup_pop(0); ],
- [ok=yes])
-
- if test "x$ok" = xyes; then
- AC_MSG_RESULT([yes])
- PTHREAD_LIBS="-lc_r $PTHREAD_LIBS"
- else
- AC_MSG_RESULT([no])
- fi
- fi
- if test x"$ok" = xno; then
- # OK, we have run out of ideas
- AC_MSG_WARN([Impossible to determine how to use pthreads with shared libraries])
-
- # so it's not safe to assume that we may use pthreads
- acx_pthread_ok=no
- fi
-
- CFLAGS="$save_CFLAGS"
- LIBS="$save_LIBS"
- CC="$save_CC"
- fi
-else
- PTHREAD_CC="$CC"
-fi
-
-AC_SUBST(PTHREAD_LIBS)
-AC_SUBST(PTHREAD_CFLAGS)
-AC_SUBST(PTHREAD_CC)
-
-# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
-if test x"$acx_pthread_ok" = xyes; then
- ifelse([$1],,AC_DEFINE(HAVE_PTHREAD,1,[Define if you have POSIX threads libraries and header files.]),[$1])
- :
-else
- acx_pthread_ok=no
- $2
-fi
-AC_LANG_RESTORE
-])dnl ACX_PTHREAD
diff --git a/m4/attributes.m4 b/m4/attributes.m4
deleted file mode 100644
index 65f83788..00000000
--- a/m4/attributes.m4
+++ /dev/null
@@ -1,258 +0,0 @@
-dnl Macros to check the presence of generic (non-typed) symbols.
-dnl Copyright (c) 2006-2007 Diego Pettenò <flameeyes@gmail.com>
-dnl Copyright (c) 2006-2007 xine project
-dnl
-dnl This program is free software; you can redistribute it and/or modify
-dnl it under the terms of the GNU General Public License as published by
-dnl the Free Software Foundation; either version 2, or (at your option)
-dnl any later version.
-dnl
-dnl This program is distributed in the hope that it will be useful,
-dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
-dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-dnl GNU General Public License for more details.
-dnl
-dnl You should have received a copy of the GNU General Public License
-dnl along with this program; if not, write to the Free Software
-dnl Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-dnl 02110-1301, USA.
-dnl
-dnl As a special exception, the copyright owners of the
-dnl macro gives unlimited permission to copy, distribute and modify the
-dnl configure scripts that are the output of Autoconf when processing the
-dnl Macro. You need not follow the terms of the GNU General Public
-dnl License when using or distributing such scripts, even though portions
-dnl of the text of the Macro appear in them. The GNU General Public
-dnl License (GPL) does govern all other use of the material that
-dnl constitutes the Autoconf Macro.
-dnl
-dnl This special exception to the GPL applies to versions of the
-dnl Autoconf Macro released by this project. When you make and
-dnl distribute a modified version of the Autoconf Macro, you may extend
-dnl this special exception to the GPL to apply to your modified version as
-dnl well.
-
-AC_DEFUN([CC_CHECK_CFLAGS_SILENT], [
- AC_CACHE_VAL(AS_TR_SH([cc_cv_cflags_$1]),
- [ac_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $1"
- AC_COMPILE_IFELSE([int a;],
- [eval "AS_TR_SH([cc_cv_cflags_$1])='yes'"],
- [eval "AS_TR_SH([cc_cv_cflags_$1])='no'"])
- CFLAGS="$ac_save_CFLAGS"
- ])
-
- AS_IF([eval test x$]AS_TR_SH([cc_cv_cflags_$1])[ = xyes],
- [$2], [$3])
-])
-
-AC_DEFUN([CC_CHECK_CFLAGS], [
- AC_CACHE_CHECK([if $CC supports $1 flag],
- AS_TR_SH([cc_cv_cflags_$1]),
- CC_CHECK_CFLAGS_SILENT([$1]) dnl Don't execute actions here!
- )
-
- AS_IF([eval test x$]AS_TR_SH([cc_cv_cflags_$1])[ = xyes],
- [$2], [$3])
-])
-
-AC_DEFUN([CC_CHECK_LDFLAGS], [
- AC_CACHE_CHECK([if $CC supports $1 flag],
- AS_TR_SH([cc_cv_ldflags_$1]),
- [ac_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $1"
- AC_LINK_IFELSE([int main() { return 1; }],
- [eval "AS_TR_SH([cc_cv_ldflags_$1])='yes'"],
- [eval "AS_TR_SH([cc_cv_ldflags_$1])='no'"])
- LDFLAGS="$ac_save_LDFLAGS"
- ])
-
- AS_IF([eval test x$]AS_TR_SH([cc_cv_ldflags_$1])[ = xyes],
- [$2], [$3])
-])
-
-dnl Check for a -Werror flag or equivalent. -Werror is the GCC
-dnl and ICC flag that tells the compiler to treat all the warnings
-dnl as fatal. We usually need this option to make sure that some
-dnl constructs (like attributes) are not simply ignored.
-dnl
-dnl Other compilers don't support -Werror per se, but they support
-dnl an equivalent flag:
-dnl - Sun Studio compiler supports -errwarn=%all
-AC_DEFUN([CC_CHECK_WERROR], [
- AC_CACHE_CHECK(
- [for $CC way to treat warnings as errors],
- [cc_cv_werror],
- [CC_CHECK_CFLAGS_SILENT([-Werror], [cc_cv_werror=-Werror],
- [CC_CHECK_CFLAGS_SILENT([-errwarn=%all], [cc_cv_werror=-errwarn=%all])])
- ])
-])
-
-AC_DEFUN([CC_CHECK_ATTRIBUTE], [
- AC_REQUIRE([CC_CHECK_WERROR])
- AC_CACHE_CHECK([if $CC supports __attribute__(( ifelse([$2], , [$1], [$2]) ))],
- AS_TR_SH([cc_cv_attribute_$1]),
- [ac_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $cc_cv_werror"
- AC_COMPILE_IFELSE([$3],
- [eval "AS_TR_SH([cc_cv_attribute_$1])='yes'"],
- [eval "AS_TR_SH([cc_cv_attribute_$1])='no'"])
- CFLAGS="$ac_save_CFLAGS"
- ])
-
- AS_IF([eval test x$]AS_TR_SH([cc_cv_attribute_$1])[ = xyes],
- [AC_DEFINE(
- AS_TR_CPP([SUPPORT_ATTRIBUTE_$1]), 1,
- [Define this if the compiler supports __attribute__(( ifelse([$2], , [$1], [$2]) ))]
- )
- $4],
- [$5])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_CONSTRUCTOR], [
- CC_CHECK_ATTRIBUTE(
- [constructor],,
- [void __attribute__((constructor)) ctor() { int a; }],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_FORMAT], [
- CC_CHECK_ATTRIBUTE(
- [format], [format(printf, n, n)],
- [void __attribute__((format(printf, 1, 2))) printflike(const char *fmt, ...) { fmt = (void *)0; }],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_FORMAT_ARG], [
- CC_CHECK_ATTRIBUTE(
- [format_arg], [format_arg(printf)],
- [char *__attribute__((format_arg(1))) gettextlike(const char *fmt) { fmt = (void *)0; }],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_VISIBILITY], [
- CC_CHECK_ATTRIBUTE(
- [visibility_$1], [visibility("$1")],
- [void __attribute__((visibility("$1"))) $1_function() { }],
- [$2], [$3])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_NONNULL], [
- CC_CHECK_ATTRIBUTE(
- [nonnull], [nonnull()],
- [void __attribute__((nonnull())) some_function(void *foo, void *bar) { foo = (void*)0; bar = (void*)0; }],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_UNUSED], [
- CC_CHECK_ATTRIBUTE(
- [unused], ,
- [void some_function(void *foo, __attribute__((unused)) void *bar);],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_SENTINEL], [
- CC_CHECK_ATTRIBUTE(
- [sentinel], ,
- [void some_function(void *foo, ...) __attribute__((sentinel));],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_DEPRECATED], [
- CC_CHECK_ATTRIBUTE(
- [deprecated], ,
- [void some_function(void *foo, ...) __attribute__((deprecated));],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_ALIAS], [
- CC_CHECK_ATTRIBUTE(
- [alias], [weak, alias],
- [void other_function(void *foo) { }
- void some_function(void *foo) __attribute__((weak, alias("other_function")));],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_MALLOC], [
- CC_CHECK_ATTRIBUTE(
- [malloc], ,
- [void * __attribute__((malloc)) my_alloc(int n);],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_PACKED], [
- CC_CHECK_ATTRIBUTE(
- [packed], ,
- [struct astructure { char a; int b; long c; void *d; } __attribute__((packed));],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_CONST], [
- CC_CHECK_ATTRIBUTE(
- [const], ,
- [int __attribute__((const)) twopow(int n) { return 1 << n; } ],
- [$1], [$2])
-])
-
-AC_DEFUN([CC_FLAG_VISIBILITY], [
- AC_REQUIRE([CC_CHECK_WERROR])
- AC_CACHE_CHECK([if $CC supports -fvisibility=hidden],
- [cc_cv_flag_visibility],
- [cc_flag_visibility_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $cc_cv_werror"
- CC_CHECK_CFLAGS_SILENT([-fvisibility=hidden],
- cc_cv_flag_visibility='yes',
- cc_cv_flag_visibility='no')
- CFLAGS="$cc_flag_visibility_save_CFLAGS"])
-
- AS_IF([test "x$cc_cv_flag_visibility" = "xyes"],
- [AC_DEFINE([SUPPORT_FLAG_VISIBILITY], 1,
- [Define this if the compiler supports the -fvisibility flag])
- $1],
- [$2])
-])
-
-AC_DEFUN([CC_FUNC_EXPECT], [
- AC_REQUIRE([CC_CHECK_WERROR])
- AC_CACHE_CHECK([if compiler has __builtin_expect function],
- [cc_cv_func_expect],
- [ac_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $cc_cv_werror"
- AC_COMPILE_IFELSE(
- [int some_function() {
- int a = 3;
- return (int)__builtin_expect(a, 3);
- }],
- [cc_cv_func_expect=yes],
- [cc_cv_func_expect=no])
- CFLAGS="$ac_save_CFLAGS"
- ])
-
- AS_IF([test "x$cc_cv_func_expect" = "xyes"],
- [AC_DEFINE([SUPPORT__BUILTIN_EXPECT], 1,
- [Define this if the compiler supports __builtin_expect() function])
- $1],
- [$2])
-])
-
-AC_DEFUN([CC_ATTRIBUTE_ALIGNED], [
- AC_REQUIRE([CC_CHECK_WERROR])
- AC_CACHE_CHECK([highest __attribute__ ((aligned ())) supported],
- [cc_cv_attribute_aligned],
- [ac_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $cc_cv_werror"
- for cc_attribute_align_try in 64 32 16 8 4 2; do
- AC_COMPILE_IFELSE([
- int main() {
- static char c __attribute__ ((aligned($cc_attribute_align_try))) = 0;
- return c;
- }], [cc_cv_attribute_aligned=$cc_attribute_align_try; break])
- done
- CFLAGS="$ac_save_CFLAGS"
- ])
-
- if test "x$cc_cv_attribute_aligned" != "x"; then
- AC_DEFINE_UNQUOTED([ATTRIBUTE_ALIGNED_MAX], [$cc_cv_attribute_aligned],
- [Define the highest alignment supported])
- fi
-])
diff --git a/m4/ax_check_define.m4 b/m4/ax_check_define.m4
new file mode 100644
index 00000000..4bc69486
--- /dev/null
+++ b/m4/ax_check_define.m4
@@ -0,0 +1,92 @@
+# ===========================================================================
+# http://www.gnu.org/software/autoconf-archive/ax_check_define.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+# AC_CHECK_DEFINE([symbol], [ACTION-IF-FOUND], [ACTION-IF-NOT])
+# AX_CHECK_DEFINE([includes],[symbol], [ACTION-IF-FOUND], [ACTION-IF-NOT])
+#
+# DESCRIPTION
+#
+# Complements AC_CHECK_FUNC but it does not check for a function but for a
+# define to exist. Consider a usage like:
+#
+# AC_CHECK_DEFINE(__STRICT_ANSI__, CFLAGS="$CFLAGS -D_XOPEN_SOURCE=500")
+#
+# LICENSE
+#
+# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation; either version 3 of the License, or (at your
+# option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
+# Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+# As a special exception, the respective Autoconf Macro's copyright owner
+# gives unlimited permission to copy, distribute and modify the configure
+# scripts that are the output of Autoconf when processing the Macro. You
+# need not follow the terms of the GNU General Public License when using
+# or distributing such scripts, even though portions of the text of the
+# Macro appear in them. The GNU General Public License (GPL) does govern
+# all other use of the material that constitutes the Autoconf Macro.
+#
+# This special exception to the GPL applies to versions of the Autoconf
+# Macro released by the Autoconf Archive. When you make and distribute a
+# modified version of the Autoconf Macro, you may extend this special
+# exception to the GPL to apply to your modified version as well.
+
+#serial 8
+
+AU_ALIAS([AC_CHECK_DEFINED], [AC_CHECK_DEFINE])
+AC_DEFUN([AC_CHECK_DEFINE],[
+AS_VAR_PUSHDEF([ac_var],[ac_cv_defined_$1])dnl
+AC_CACHE_CHECK([for $1 defined], ac_var,
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[
+ #ifdef $1
+ int ok;
+ #else
+ choke me
+ #endif
+]])],[AS_VAR_SET(ac_var, yes)],[AS_VAR_SET(ac_var, no)]))
+AS_IF([test AS_VAR_GET(ac_var) != "no"], [$2], [$3])dnl
+AS_VAR_POPDEF([ac_var])dnl
+])
+
+AU_ALIAS([AX_CHECK_DEFINED], [AX_CHECK_DEFINE])
+AC_DEFUN([AX_CHECK_DEFINE],[
+AS_VAR_PUSHDEF([ac_var],[ac_cv_defined_$2_$1])dnl
+AC_CACHE_CHECK([for $2 defined in $1], ac_var,
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <$1>]], [[
+ #ifdef $2
+ int ok;
+ #else
+ choke me
+ #endif
+]])],[AS_VAR_SET(ac_var, yes)],[AS_VAR_SET(ac_var, no)]))
+AS_IF([test AS_VAR_GET(ac_var) != "no"], [$3], [$4])dnl
+AS_VAR_POPDEF([ac_var])dnl
+])
+
+AC_DEFUN([AX_CHECK_FUNC],
+[AS_VAR_PUSHDEF([ac_var], [ac_cv_func_$2])dnl
+AC_CACHE_CHECK([for $2], ac_var,
+dnl AC_LANG_FUNC_LINK_TRY
+[AC_LINK_IFELSE([AC_LANG_PROGRAM([$1
+ #undef $2
+ char $2 ();],[
+ char (*f) () = $2;
+ return f != $2; ])],
+ [AS_VAR_SET(ac_var, yes)],
+ [AS_VAR_SET(ac_var, no)])])
+AS_IF([test AS_VAR_GET(ac_var) = yes], [$3], [$4])dnl
+AS_VAR_POPDEF([ac_var])dnl
+])# AC_CHECK_FUNC
diff --git a/m4/ax_check_flag.m4 b/m4/ax_check_flag.m4
new file mode 100644
index 00000000..52405fd4
--- /dev/null
+++ b/m4/ax_check_flag.m4
@@ -0,0 +1,147 @@
+# ===========================================================================
+# http://www.gnu.org/software/autoconf-archive/ax_check_flag.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+# AX_CHECK_PREPROC_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS])
+# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS])
+# AX_CHECK_LINK_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS])
+# AX_APPEND_FLAG(FLAG, [FLAGS-VARIABLE])
+# AX_APPEND_COMPILE_FLAGS([FLAG1 FLAG2 ...], [FLAGS-VARIABLE], [EXTRA-FLAGS])
+# AX_APPEND_LINK_FLAGS([FLAG1 FLAG2 ...], [FLAGS-VARIABLE], [EXTRA-FLAGS])
+#
+# DESCRIPTION
+#
+# Check whether the given FLAG works with the current language's
+# preprocessor/compiler/linker, or whether they give an error. (Warnings,
+# however, are ignored.)
+#
+# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on
+# success/failure.
+#
+# If EXTRA-FLAGS is defined, it is added to the current language's default
+# flags (e.g. CFLAGS) when the check is done. The check us thus made
+# with the following flags: "CFLAGS EXTRA-FLAGS FLAG". EXTRA-FLAGS can
+# for example be used to force the compiler to issue an error when a bad
+# flag is given.
+#
+# AX_APPEND_FLAG appends the FLAG to the FLAG-VARIABLE shell variable or
+# the current language's flags if not specified. FLAG is not added to
+# FLAG-VARIABLE if it is already in the shell variable.
+#
+# AX_APPEND_COMPILE_FLAGS checks for each FLAG1, FLAG2, etc. using
+# AX_CHECK_COMPILE_FLAG and if the check is successful the flag is added
+# to the appropriate FLAGS variable with AX_APPEND_FLAG. The
+# FLAGS-VARIABLE and EXTRA-FLAGS arguments are the same as in the other
+# macros. AX_APPEND_LINK_FLAGS does the same for linker flags.
+#
+# NOTE: Based on AX_CHECK_COMPILER_FLAGS and AX_CFLAGS_GCC_OPTION.
+#
+# LICENSE
+#
+# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
+# Copyright (c) 2009 Steven G. Johnson <stevenj@alum.mit.edu>
+# Copyright (c) 2009 Matteo Frigo
+# Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com>
+#
+# This program is free software: you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation, either version 3 of the License, or (at your
+# option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
+# Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+# As a special exception, the respective Autoconf Macro's copyright owner
+# gives unlimited permission to copy, distribute and modify the configure
+# scripts that are the output of Autoconf when processing the Macro. You
+# need not follow the terms of the GNU General Public License when using
+# or distributing such scripts, even though portions of the text of the
+# Macro appear in them. The GNU General Public License (GPL) does govern
+# all other use of the material that constitutes the Autoconf Macro.
+#
+# This special exception to the GPL applies to versions of the Autoconf
+# Macro released by the Autoconf Archive. When you make and distribute a
+# modified version of the Autoconf Macro, you may extend this special
+# exception to the GPL to apply to your modified version as well.
+
+#serial 2
+
+AC_DEFUN([AX_CHECK_PREPROC_FLAG],
+[AC_PREREQ(2.59) dnl for _AC_LANG_PREFIX
+AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]cppflags_$4_$1])dnl
+AC_CACHE_CHECK([whether _AC_LANG preprocessor accepts $1], CACHEVAR, [
+ ax_check_save_flags=$CPPFLAGS
+ CPPFLAGS="$CPPFLAGS $4 $1"
+ AC_PREPROC_IFELSE([AC_LANG_PROGRAM()],
+ [AS_VAR_SET([CACHEVAR],[yes])],
+ [AS_VAR_SET([CACHEVAR],[no])])
+ CPPFLAGS=$ax_check_save_flags])
+AS_VAR_IF([CACHEVAR], "yes",
+ [m4_default([$2], :)],
+ [m4_default([$3], :)])
+AS_VAR_POPDEF([CACHEVAR])dnl
+])dnl AX_CHECK_PREPROC_FLAGS
+
+AC_DEFUN([AX_CHECK_COMPILE_FLAG],
+[AC_PREREQ(2.59) dnl for _AC_LANG_PREFIX
+AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl
+AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [
+ ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS
+ _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
+ [AS_VAR_SET([CACHEVAR],[yes])],
+ [AS_VAR_SET([CACHEVAR],[no])])
+ _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags])
+AS_VAR_IF([CACHEVAR], "yes",
+ [m4_default([$2], :)],
+ [m4_default([$3], :)])
+AS_VAR_POPDEF([CACHEVAR])dnl
+])dnl AX_CHECK_COMPILE_FLAGS
+
+AC_DEFUN([AX_CHECK_LINK_FLAG],
+[AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_ldflags_$4_$1])dnl
+AC_CACHE_CHECK([whether the linker accepts $1], CACHEVAR, [
+ ax_check_save_flags=$LDFLAGS
+ LDFLAGS="$LDFLAGS $4 $1"
+ AC_LINK_IFELSE([AC_LANG_PROGRAM()],
+ [AS_VAR_SET([CACHEVAR],[yes])],
+ [AS_VAR_SET([CACHEVAR],[no])])
+ LDFLAGS=$ax_check_save_flags])
+AS_VAR_IF([CACHEVAR], "yes",
+ [m4_default([$2], :)],
+ [m4_default([$3], :)])
+AS_VAR_POPDEF([CACHEVAR])dnl
+])dnl AX_CHECK_LINK_FLAGS
+
+
+AC_DEFUN([AX_APPEND_FLAG],
+[AC_PREREQ(2.59) dnl for _AC_LANG_PREFIX
+AC_REQUIRE([AC_PROG_GREP])
+AS_VAR_PUSHDEF([FLAGS], [m4_default($2,_AC_LANG_PREFIX[]FLAGS)])dnl
+AS_VAR_SET_IF([FLAGS],
+ [AS_IF([AS_ECHO(" $[]FLAGS ") | $GREP " $1 " 2>&1 >/dev/null],
+ [AC_RUN_LOG([: FLAGS already contains $1])],
+ [AC_RUN_LOG([: FLAGS="$FLAGS $1"])
+ AS_VAR_APPEND([FLAGS], [" $1"])])],
+ [AS_VAR_SET([FLAGS],[$1])])
+AS_VAR_POPDEF([FLAGS])dnl
+])dnl AX_APPEND_FLAG
+
+AC_DEFUN([AX_APPEND_COMPILE_FLAGS],
+[for flag in $1; do
+ AX_CHECK_COMPILE_FLAG([$flag], [AX_APPEND_FLAG([$flag], [$2])], [], [$3])
+done
+])dnl AX_APPEND_COMPILE_FLAGS
+
+AC_DEFUN([AX_APPEND_LINK_FLAGS],
+[for flag in $1; do
+ AX_CHECK_LINK_FLAG([$flag], [AX_APPEND_FLAG([$flag], [m4_default([$2], [LDFLAGS])])], [], [$3])
+done
+])dnl AX_APPEND_LINK_FLAGS
diff --git a/m4/ax_define_dir.m4 b/m4/ax_define_dir.m4
new file mode 100644
index 00000000..b74d155f
--- /dev/null
+++ b/m4/ax_define_dir.m4
@@ -0,0 +1,49 @@
+# ===========================================================================
+# http://www.gnu.org/software/autoconf-archive/ax_define_dir.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+# AX_DEFINE_DIR(VARNAME, DIR [, DESCRIPTION])
+#
+# DESCRIPTION
+#
+# This macro sets VARNAME to the expansion of the DIR variable, taking
+# care of fixing up ${prefix} and such.
+#
+# VARNAME is then offered as both an output variable and a C preprocessor
+# symbol.
+#
+# Example:
+#
+# AX_DEFINE_DIR([DATADIR], [datadir], [Where data are placed to.])
+#
+# LICENSE
+#
+# Copyright (c) 2008 Stepan Kasal <kasal@ucw.cz>
+# Copyright (c) 2008 Andreas Schwab <schwab@suse.de>
+# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
+# Copyright (c) 2008 Alexandre Oliva
+#
+# Copying and distribution of this file, with or without modification, are
+# permitted in any medium without royalty provided the copyright notice
+# and this notice are preserved. This file is offered as-is, without any
+# warranty.
+
+#serial 6
+
+AU_ALIAS([AC_DEFINE_DIR], [AX_DEFINE_DIR])
+AC_DEFUN([AX_DEFINE_DIR], [
+ prefix_NONE=
+ exec_prefix_NONE=
+ test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix
+ test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix
+dnl In Autoconf 2.60, ${datadir} refers to ${datarootdir}, which in turn
+dnl refers to ${prefix}. Thus we have to use `eval' twice.
+ eval ax_define_dir="\"[$]$2\""
+ eval ax_define_dir="\"$ax_define_dir\""
+ AC_SUBST($1, "$ax_define_dir")
+ AC_DEFINE_UNQUOTED($1, "$ax_define_dir", [$3])
+ test "$prefix_NONE" && prefix=NONE
+ test "$exec_prefix_NONE" && exec_prefix=NONE
+])
diff --git a/m4/ax_pthread.m4 b/m4/ax_pthread.m4
new file mode 100644
index 00000000..94a3b0ee
--- /dev/null
+++ b/m4/ax_pthread.m4
@@ -0,0 +1,302 @@
+# ===========================================================================
+# http://www.gnu.org/software/autoconf-archive/ax_pthread.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+# AX_PTHREAD([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
+#
+# DESCRIPTION
+#
+# This macro figures out how to build C programs using POSIX threads. It
+# sets the PTHREAD_LIBS output variable to the threads library and linker
+# flags, and the PTHREAD_CFLAGS output variable to any special C compiler
+# flags that are needed. (The user can also force certain compiler
+# flags/libs to be tested by setting these environment variables.)
+#
+# Also sets PTHREAD_CC to any special C compiler that is needed for
+# multi-threaded programs (defaults to the value of CC otherwise). (This
+# is necessary on AIX to use the special cc_r compiler alias.)
+#
+# NOTE: You are assumed to not only compile your program with these flags,
+# but also link it with them as well. e.g. you should link with
+# $PTHREAD_CC $CFLAGS $PTHREAD_CFLAGS $LDFLAGS ... $PTHREAD_LIBS $LIBS
+#
+# If you are only building threads programs, you may wish to use these
+# variables in your default LIBS, CFLAGS, and CC:
+#
+# LIBS="$PTHREAD_LIBS $LIBS"
+# CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+# CC="$PTHREAD_CC"
+#
+# In addition, if the PTHREAD_CREATE_JOINABLE thread-attribute constant
+# has a nonstandard name, defines PTHREAD_CREATE_JOINABLE to that name
+# (e.g. PTHREAD_CREATE_UNDETACHED on AIX).
+#
+# Also HAVE_PTHREAD_PRIO_INHERIT is defined if pthread is found and the
+# PTHREAD_PRIO_INHERIT symbol is defined when compiling with
+# PTHREAD_CFLAGS.
+#
+# ACTION-IF-FOUND is a list of shell commands to run if a threads library
+# is found, and ACTION-IF-NOT-FOUND is a list of commands to run it if it
+# is not found. If ACTION-IF-FOUND is not specified, the default action
+# will define HAVE_PTHREAD.
+#
+# Please let the authors know if this macro fails on any platform, or if
+# you have any other suggestions or comments. This macro was based on work
+# by SGJ on autoconf scripts for FFTW (http://www.fftw.org/) (with help
+# from M. Frigo), as well as ac_pthread and hb_pthread macros posted by
+# Alejandro Forero Cuervo to the autoconf macro repository. We are also
+# grateful for the helpful feedback of numerous users.
+#
+# Updated for Autoconf 2.68 by Daniel Richard G.
+#
+# LICENSE
+#
+# Copyright (c) 2008 Steven G. Johnson <stevenj@alum.mit.edu>
+# Copyright (c) 2011 Daniel Richard G. <skunk@iSKUNK.ORG>
+#
+# This program is free software: you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation, either version 3 of the License, or (at your
+# option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
+# Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+# As a special exception, the respective Autoconf Macro's copyright owner
+# gives unlimited permission to copy, distribute and modify the configure
+# scripts that are the output of Autoconf when processing the Macro. You
+# need not follow the terms of the GNU General Public License when using
+# or distributing such scripts, even though portions of the text of the
+# Macro appear in them. The GNU General Public License (GPL) does govern
+# all other use of the material that constitutes the Autoconf Macro.
+#
+# This special exception to the GPL applies to versions of the Autoconf
+# Macro released by the Autoconf Archive. When you make and distribute a
+# modified version of the Autoconf Macro, you may extend this special
+# exception to the GPL to apply to your modified version as well.
+
+#serial 14
+
+AU_ALIAS([ACX_PTHREAD], [AX_PTHREAD])
+AC_DEFUN([AX_PTHREAD], [
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_LANG_PUSH([C])
+ax_pthread_ok=no
+
+# We used to check for pthread.h first, but this fails if pthread.h
+# requires special compiler flags (e.g. on True64 or Sequent).
+# It gets checked for in the link test anyway.
+
+# First of all, check if the user has set any of the PTHREAD_LIBS,
+# etcetera environment variables, and if threads linking works using
+# them:
+if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+ save_LIBS="$LIBS"
+ LIBS="$PTHREAD_LIBS $LIBS"
+ AC_MSG_CHECKING([for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS])
+ AC_TRY_LINK_FUNC(pthread_join, ax_pthread_ok=yes)
+ AC_MSG_RESULT($ax_pthread_ok)
+ if test x"$ax_pthread_ok" = xno; then
+ PTHREAD_LIBS=""
+ PTHREAD_CFLAGS=""
+ fi
+ LIBS="$save_LIBS"
+ CFLAGS="$save_CFLAGS"
+fi
+
+# We must check for the threads library under a number of different
+# names; the ordering is very important because some systems
+# (e.g. DEC) have both -lpthread and -lpthreads, where one of the
+# libraries is broken (non-POSIX).
+
+# Create a list of thread flags to try. Items starting with a "-" are
+# C compiler flags, and other items are library names, except for "none"
+# which indicates that we try without any flags at all, and "pthread-config"
+# which is a program returning the flags for the Pth emulation library.
+
+ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
+
+# The ordering *is* (sometimes) important. Some notes on the
+# individual items follow:
+
+# pthreads: AIX (must check this before -lpthread)
+# none: in case threads are in libc; should be tried before -Kthread and
+# other compiler flags to prevent continual compiler warnings
+# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
+# -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
+# lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
+# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
+# -pthreads: Solaris/gcc
+# -mthreads: Mingw32/gcc, Lynx/gcc
+# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
+# doesn't hurt to check since this sometimes defines pthreads too;
+# also defines -D_REENTRANT)
+# ... -mt is also the pthreads flag for HP/aCC
+# pthread: Linux, etcetera
+# --thread-safe: KAI C++
+# pthread-config: use pthread-config program (for GNU Pth library)
+
+case "${host_cpu}-${host_os}" in
+ *solaris*)
+
+ # On Solaris (at least, for some versions), libc contains stubbed
+ # (non-functional) versions of the pthreads routines, so link-based
+ # tests will erroneously succeed. (We need to link with -pthreads/-mt/
+ # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
+ # a function called by this macro, so we could check for that, but
+ # who knows whether they'll stub that too in a future libc.) So,
+ # we'll just look for -pthreads and -lpthread first:
+
+ ax_pthread_flags="-pthreads pthread -mt -pthread $ax_pthread_flags"
+ ;;
+
+ *-darwin*)
+ ax_pthread_flags="-pthread $ax_pthread_flags"
+ ;;
+esac
+
+if test x"$ax_pthread_ok" = xno; then
+for flag in $ax_pthread_flags; do
+
+ case $flag in
+ none)
+ AC_MSG_CHECKING([whether pthreads work without any flags])
+ ;;
+
+ -*)
+ AC_MSG_CHECKING([whether pthreads work with $flag])
+ PTHREAD_CFLAGS="$flag"
+ ;;
+
+ pthread-config)
+ AC_CHECK_PROG(ax_pthread_config, pthread-config, yes, no)
+ if test x"$ax_pthread_config" = xno; then continue; fi
+ PTHREAD_CFLAGS="`pthread-config --cflags`"
+ PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
+ ;;
+
+ *)
+ AC_MSG_CHECKING([for the pthreads library -l$flag])
+ PTHREAD_LIBS="-l$flag"
+ ;;
+ esac
+
+ save_LIBS="$LIBS"
+ save_CFLAGS="$CFLAGS"
+ LIBS="$PTHREAD_LIBS $LIBS"
+ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+
+ # Check for various functions. We must include pthread.h,
+ # since some functions may be macros. (On the Sequent, we
+ # need a special flag -Kthread to make this header compile.)
+ # We check for pthread_join because it is in -lpthread on IRIX
+ # while pthread_create is in libc. We check for pthread_attr_init
+ # due to DEC craziness with -lpthreads. We check for
+ # pthread_cleanup_push because it is one of the few pthread
+ # functions on Solaris that doesn't have a non-functional libc stub.
+ # We try pthread_create on general principles.
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <pthread.h>
+ static void routine(void *a) { a = 0; }
+ static void *start_routine(void *a) { return a; }],
+ [pthread_t th; pthread_attr_t attr;
+ pthread_create(&th, 0, start_routine, 0);
+ pthread_join(th, 0);
+ pthread_attr_init(&attr);
+ pthread_cleanup_push(routine, 0);
+ pthread_cleanup_pop(0) /* ; */])],
+ [ax_pthread_ok=yes],
+ [])
+
+ LIBS="$save_LIBS"
+ CFLAGS="$save_CFLAGS"
+
+ AC_MSG_RESULT($ax_pthread_ok)
+ if test "x$ax_pthread_ok" = xyes; then
+ break;
+ fi
+
+ PTHREAD_LIBS=""
+ PTHREAD_CFLAGS=""
+done
+fi
+
+# Various other checks:
+if test "x$ax_pthread_ok" = xyes; then
+ save_LIBS="$LIBS"
+ LIBS="$PTHREAD_LIBS $LIBS"
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+
+ # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
+ AC_MSG_CHECKING([for joinable pthread attribute])
+ attr_name=unknown
+ for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <pthread.h>],
+ [int attr = $attr; return attr /* ; */])],
+ [attr_name=$attr; break],
+ [])
+ done
+ AC_MSG_RESULT($attr_name)
+ if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
+ AC_DEFINE_UNQUOTED(PTHREAD_CREATE_JOINABLE, $attr_name,
+ [Define to necessary symbol if this constant
+ uses a non-standard name on your system.])
+ fi
+
+ AC_MSG_CHECKING([if more special flags are required for pthreads])
+ flag=no
+ case "${host_cpu}-${host_os}" in
+ *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
+ *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
+ esac
+ AC_MSG_RESULT(${flag})
+ if test "x$flag" != xno; then
+ PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
+ fi
+
+ AC_CACHE_CHECK([for PTHREAD_PRIO_INHERIT],
+ ax_cv_PTHREAD_PRIO_INHERIT, [
+ AC_LINK_IFELSE(
+ AC_LANG_PROGRAM([[#include <pthread.h>]], [[int i = PTHREAD_PRIO_INHERIT;]]),
+ [ax_cv_PTHREAD_PRIO_INHERIT=yes],
+ [ax_cv_PTHREAD_PRIO_INHERIT=no])
+ ])
+ AS_IF([test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"],
+ AC_DEFINE([HAVE_PTHREAD_PRIO_INHERIT], 1, [Have PTHREAD_PRIO_INHERIT.]))
+
+ LIBS="$save_LIBS"
+ CFLAGS="$save_CFLAGS"
+
+ # More AIX lossage: must compile with xlc_r or cc_r
+ if test x"$GCC" != xyes; then
+ AC_CHECK_PROGS(PTHREAD_CC, xlc_r cc_r, ${CC})
+ else
+ PTHREAD_CC=$CC
+ fi
+else
+ PTHREAD_CC="$CC"
+fi
+
+AC_SUBST(PTHREAD_LIBS)
+AC_SUBST(PTHREAD_CFLAGS)
+AC_SUBST(PTHREAD_CC)
+
+# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
+if test x"$ax_pthread_ok" = xyes; then
+ ifelse([$1],,AC_DEFINE(HAVE_PTHREAD,1,[Define if you have POSIX threads libraries and header files.]),[$1])
+ :
+else
+ ax_pthread_ok=no
+ $2
+fi
+AC_LANG_POP
+])dnl AX_PTHREAD
diff --git a/m4/ax_tls.m4 b/m4/ax_tls.m4
new file mode 100644
index 00000000..033e3b13
--- /dev/null
+++ b/m4/ax_tls.m4
@@ -0,0 +1,76 @@
+# ===========================================================================
+# http://www.gnu.org/software/autoconf-archive/ax_tls.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+# AX_TLS([action-if-found], [action-if-not-found])
+#
+# DESCRIPTION
+#
+# Provides a test for the compiler support of thread local storage (TLS)
+# extensions. Defines TLS if it is found. Currently knows about GCC/ICC
+# and MSVC. I think SunPro uses the same as GCC, and Borland apparently
+# supports either.
+#
+# LICENSE
+#
+# Copyright (c) 2008 Alan Woodland <ajw05@aber.ac.uk>
+# Copyright (c) 2010 Diego Elio Petteno` <flameeyes@gmail.com>
+#
+# This program is free software: you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation, either version 3 of the License, or (at your
+# option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
+# Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+# As a special exception, the respective Autoconf Macro's copyright owner
+# gives unlimited permission to copy, distribute and modify the configure
+# scripts that are the output of Autoconf when processing the Macro. You
+# need not follow the terms of the GNU General Public License when using
+# or distributing such scripts, even though portions of the text of the
+# Macro appear in them. The GNU General Public License (GPL) does govern
+# all other use of the material that constitutes the Autoconf Macro.
+#
+# This special exception to the GPL applies to versions of the Autoconf
+# Macro released by the Autoconf Archive. When you make and distribute a
+# modified version of the Autoconf Macro, you may extend this special
+# exception to the GPL to apply to your modified version as well.
+
+#serial 10
+
+AC_DEFUN([AX_TLS], [
+ AC_MSG_CHECKING(for thread local storage (TLS) class)
+ AC_CACHE_VAL(ac_cv_tls, [
+ ax_tls_keywords="__thread __declspec(thread) none"
+ for ax_tls_keyword in $ax_tls_keywords; do
+ AS_CASE([$ax_tls_keyword],
+ [none], [ac_cv_tls=none ; break],
+ [AC_TRY_COMPILE(
+ [#include <stdlib.h>
+ static void
+ foo(void) {
+ static ] $ax_tls_keyword [ int bar;
+ exit(1);
+ }],
+ [],
+ [ac_cv_tls=$ax_tls_keyword ; break],
+ ac_cv_tls=none
+ )])
+ done
+ ])
+ AC_MSG_RESULT($ac_cv_tls)
+
+ AS_IF([test "$ac_cv_tls" != "none"],
+ AC_DEFINE_UNQUOTED([TLS], $ac_cv_tls, [If the compiler supports a TLS storage class define it to that here])
+ m4_ifnblank([$1], [$1]),
+ m4_ifnblank([$2], [$2])
+ )
+])
diff --git a/m4/check_define.m4 b/m4/check_define.m4
deleted file mode 100644
index 43edc78e..00000000
--- a/m4/check_define.m4
+++ /dev/null
@@ -1,13 +0,0 @@
-AC_DEFUN([AC_CHECK_DEFINE],[
-AS_VAR_PUSHDEF([ac_var],[ac_cv_defined_$1_$2])dnl
-AC_CACHE_CHECK([for $1 in $2], ac_var,
-AC_TRY_COMPILE([#include <$2>],[
- #ifdef $1
- int ok;
- #else
- choke me
- #endif
-],AS_VAR_SET(ac_var, yes),AS_VAR_SET(ac_var, no)))
-AS_IF([test AS_VAR_GET(ac_var) != "no"], [$3], [$4])dnl
-AS_VAR_POPDEF([ac_var])dnl
-])
diff --git a/m4/orc.m4 b/m4/orc.m4
new file mode 100644
index 00000000..983d4624
--- /dev/null
+++ b/m4/orc.m4
@@ -0,0 +1,69 @@
+dnl pkg-config-based checks for Orc
+
+dnl specific:
+dnl ORC_CHECK([REQUIRED_VERSION])
+
+AC_DEFUN([ORC_CHECK],
+[
+ ORC_REQ=ifelse([$1], , "0.4.6", [$1])
+
+ AC_ARG_ENABLE(orc,
+ AC_HELP_STRING([--enable-orc],[use Orc if installed]),
+ [case "${enableval}" in
+ auto) enable_orc=auto ;;
+ yes) enable_orc=yes ;;
+ no) enable_orc=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-orc) ;;
+ esac
+ ],
+ [enable_orc=auto]) dnl Default value
+
+ if test "x$enable_orc" != "xno" ; then
+ PKG_CHECK_MODULES(ORC, orc-0.4 >= $ORC_REQ, [
+ AC_DEFINE(HAVE_ORC, 1, [Use Orc])
+ HAVE_ORC=yes
+ if test "x$ORCC" = "x" ; then
+ AC_MSG_CHECKING(for usable orcc)
+ ORCC=`$PKG_CONFIG --variable=orcc orc-0.4`
+ dnl check whether the orcc found by pkg-config can be run from the build environment
+ dnl if this is not the case (e.g. when cross-compiling) fall back to orcc from PATH
+ AS_IF([$ORCC --version 1> /dev/null 2> /dev/null], [], [ORCC=`which orcc`])
+ AC_MSG_RESULT($ORCC)
+ fi
+ AC_SUBST(ORCC)
+ ORCC_FLAGS="--compat $ORC_REQ"
+ AC_SUBST(ORCC_FLAGS)
+ AS_IF([test "x$ORCC" = "x"], [HAVE_ORCC=no], [HAVE_ORCC=yes])
+ ], [
+ if test "x$enable_orc" = "xyes" ; then
+ AC_MSG_ERROR([--enable-orc specified, but Orc >= $ORC_REQ not found])
+ fi
+ AC_DEFINE(DISABLE_ORC, 1, [Disable Orc])
+ HAVE_ORC=no
+ HAVE_ORCC=no
+ ])
+ else
+ AC_DEFINE(DISABLE_ORC, 1, [Disable Orc])
+ HAVE_ORC=no
+ HAVE_ORCC=no
+ fi
+ AM_CONDITIONAL(HAVE_ORC, [test "x$HAVE_ORC" = "xyes"])
+ AM_CONDITIONAL(HAVE_ORCC, [test "x$HAVE_ORCC" = "xyes"])
+
+]))
+
+AC_DEFUN([ORC_OUTPUT],
+[
+ if test "$HAVE_ORC" = yes ; then
+ printf "configure: *** Orc acceleration enabled.\n"
+ else
+ if test "x$enable_orc" = "xno" ; then
+ printf "configure: *** Orc acceleration disabled by --disable-orc. Slower code paths\n"
+ printf " will be used.\n"
+ else
+ printf "configure: *** Orc acceleration disabled. Requires Orc >= $ORC_REQ, which was\n"
+ printf " not found. Slower code paths will be used.\n"
+ fi
+ fi
+ printf "\n"
+])
diff --git a/m4/shave.m4 b/m4/shave.m4
deleted file mode 100644
index 0a3509e5..00000000
--- a/m4/shave.m4
+++ /dev/null
@@ -1,77 +0,0 @@
-dnl Make automake/libtool output more friendly to humans
-dnl Damien Lespiau <damien.lespiau@gmail.com>
-dnl
-dnl SHAVE_INIT([shavedir],[default_mode])
-dnl
-dnl shavedir: the directory where the shave scripts are, it defaults to
-dnl $(top_builddir)
-dnl default_mode: (enable|disable) default shave mode. This parameter
-dnl controls shave's behaviour when no option has been
-dnl given to configure. It defaults to disable.
-dnl
-dnl * SHAVE_INIT should be called late in your configure.(ac|in) file (just
-dnl before AC_CONFIG_FILE/AC_OUTPUT is perfect. This macro rewrites CC and
-dnl LIBTOOL, you don't want the configure tests to have these variables
-dnl re-defined.
-dnl * This macro requires GNU make's -s option.
-
-AC_DEFUN([_SHAVE_ARG_ENABLE],
-[
- AC_ARG_ENABLE([shave],
- AS_HELP_STRING(
- [--enable-shave],
- [use shave to make the build pretty [[default=$1]]]),,
- [enable_shave=$1]
- )
-])
-
-AC_DEFUN([SHAVE_INIT],
-[
- dnl you can tweak the default value of enable_shave
- m4_if([$2], [enable], [_SHAVE_ARG_ENABLE(yes)], [_SHAVE_ARG_ENABLE(no)])
-
- if test x"$enable_shave" = xyes; then
- dnl where can we find the shave scripts?
- m4_if([$1],,
- [shavedir="$ac_pwd"],
- [shavedir="$ac_pwd/$1"])
- AC_SUBST(shavedir)
-
- dnl make is now quiet
- AC_SUBST([MAKEFLAGS], [-s])
- AC_SUBST([AM_MAKEFLAGS], ['`test -z $V && echo -s`'])
-
- dnl we need sed
- AC_CHECK_PROG(SED,sed,sed,false)
-
- dnl substitute libtool
- SHAVE_SAVED_LIBTOOL=$LIBTOOL
- LIBTOOL="${SHELL} ${shavedir}/shave-libtool '${SHAVE_SAVED_LIBTOOL}'"
- AC_SUBST(LIBTOOL)
-
- dnl substitute cc/cxx
- SHAVE_SAVED_CC=$CC
- SHAVE_SAVED_CXX=$CXX
- SHAVE_SAVED_FC=$FC
- SHAVE_SAVED_F77=$F77
- SHAVE_SAVED_OBJC=$OBJC
- CC="${SHELL} ${shavedir}/shave cc ${SHAVE_SAVED_CC}"
- CXX="${SHELL} ${shavedir}/shave cxx ${SHAVE_SAVED_CXX}"
- FC="${SHELL} ${shavedir}/shave fc ${SHAVE_SAVED_FC}"
- F77="${SHELL} ${shavedir}/shave f77 ${SHAVE_SAVED_F77}"
- OBJC="${SHELL} ${shavedir}/shave objc ${SHAVE_SAVED_OBJC}"
- AC_SUBST(CC)
- AC_SUBST(CXX)
- AC_SUBST(FC)
- AC_SUBST(F77)
- AC_SUBST(OBJC)
-
- V=@
- else
- V=1
- fi
- Q='$(V:1=)'
- AC_SUBST(V)
- AC_SUBST(Q)
-])
-
diff --git a/m4/tls.m4 b/m4/tls.m4
deleted file mode 100644
index 3808f06e..00000000
--- a/m4/tls.m4
+++ /dev/null
@@ -1,17 +0,0 @@
-AC_DEFUN([CC_CHECK_TLS], [
- AC_CACHE_CHECK([whether $CC knows __thread for Thread-Local Storage],
- cc_cv_tls___thread,
- [AC_COMPILE_IFELSE(
- AC_LANG_PROGRAM(
- [[static __thread int a = 6;]],
- [[a = 5;]]),
- [cc_cv_tls___thread=yes],
- [cc_cv_tls___thread=no])
- ])
-
- AS_IF([test "x$cc_cv_tls___thread" = "xyes"],
- [AC_DEFINE([SUPPORT_TLS___THREAD], 1,
- [Define this if the compiler supports __thread for Thread-Local Storage])
- $1],
- [$2])
-])
diff --git a/man/Makefile.am b/man/Makefile.am
index 9b229f52..4f42fe2d 100644
--- a/man/Makefile.am
+++ b/man/Makefile.am
@@ -15,26 +15,9 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
# USA.
-pulseconfdir=$(sysconfdir)/pulse
-
-CLEANFILES = \
+DISTCLEANFILES = \
$(noinst_DATA)
-dist_man_MANS = \
- pulseaudio.1 \
- esdcompat.1 \
- pax11publish.1 \
- paplay.1 \
- pacat.1 \
- pacmd.1 \
- pactl.1 \
- pasuspender.1 \
- padsp.1 \
- pabrowse.1 \
- pulse-daemon.conf.5 \
- pulse-client.conf.5 \
- default.pa.5
-
noinst_DATA = \
pulseaudio.1.xml \
esdcompat.1.xml \
@@ -45,28 +28,36 @@ noinst_DATA = \
pactl.1.xml \
pasuspender.1.xml \
padsp.1.xml \
- pabrowse.1.xml \
pulse-daemon.conf.5.xml \
pulse-client.conf.5.xml \
default.pa.5.xml
+xmllint: $(noinst_DATA)
+ for f in $(noinst_DATA) ; do \
+ xmllint --noout --valid "$$f" || exit 1 ; \
+ done
+
if BUILD_MANPAGES
-CLEANFILES += \
- $(dist_man_MANS)
+dist_man_MANS = \
+ pulseaudio.1 \
+ esdcompat.1 \
+ pax11publish.1 \
+ paplay.1 \
+ pacat.1 \
+ pacmd.1 \
+ pactl.1 \
+ pasuspender.1 \
+ padsp.1 \
+ pulse-daemon.conf.5 \
+ pulse-client.conf.5 \
+ default.pa.5
-%.xml: %.xml.in Makefile
- sed -e 's,@pulseconfdir\@,$(pulseconfdir),g' \
- -e 's,@PACKAGE_BUGREPORT\@,$(PACKAGE_BUGREPORT),g' \
- -e 's,@PACKAGE_URL\@,$(PACKAGE_URL),g' $< > $@
+CLEANFILES = \
+ $(dist_man_MANS)
%: %.xml Makefile
- perl $(srcdir)/xmltoman $< > $@ || rm -f $@
-
-xmllint: $(noinst_DATA)
- for f in $(noinst_DATA) ; do \
- xmllint --noout --valid "$$f" || exit 1 ; \
- done
+ $(AM_V_GEN) perl $(srcdir)/xmltoman $< > $@ || rm -f $@
endif
@@ -80,7 +71,6 @@ EXTRA_DIST = \
pactl.1.xml.in \
pasuspender.1.xml.in \
padsp.1.xml.in \
- pabrowse.1.xml.in \
pulse-daemon.conf.5.xml.in \
pulse-client.conf.5.xml.in \
default.pa.5.xml.in \
diff --git a/man/default.pa.5.xml.in b/man/default.pa.5.xml.in
index 4caad7c9..1ec618d5 100644
--- a/man/default.pa.5.xml.in
+++ b/man/default.pa.5.xml.in
@@ -26,13 +26,13 @@ USA.
<synopsis>
<p><file>~/.pulse/default.pa</file></p>
- <p><file>@pulseconfdir@/default.pa</file></p>
+ <p><file>@PA_DEFAULT_CONFIG_DIR@/default.pa</file></p>
</synopsis>
<description>
<p>The PulseAudio sound server interprets the file
<file>~/.pulse/default.pa</file> on startup, and when that file
- doesn't exist <file>@pulseconfdir@/default.pa</file>. It
+ doesn't exist <file>@PA_DEFAULT_CONFIG_DIR@/default.pa</file>. It
should contain directives in the PulseAudio CLI languages, as
documented on <url href="http://pulseaudio.org/wiki/CLI"/>.</p>
diff --git a/man/pabrowse.1.xml.in b/man/pabrowse.1.xml.in
deleted file mode 100644
index 33f071be..00000000
--- a/man/pabrowse.1.xml.in
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0"?><!--*-nxml-*-->
-<!DOCTYPE manpage SYSTEM "xmltoman.dtd">
-<?xml-stylesheet type="text/xsl" href="xmltoman.xsl" ?>
-
-<!--
-This file is part of PulseAudio.
-
-PulseAudio is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License as
-published by the Free Software Foundation; either version 2.1 of the
-License, or (at your option) any later version.
-
-PulseAudio is distributed in the hope that it will be useful, but WITHOUT
-ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
-Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with PulseAudio; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
-USA.
--->
-
-<manpage name="pabrowse" section="1" desc="List PulseAudio sound servers on the network">
-
- <synopsis>
- <cmd>pabrowse</cmd>
- </synopsis>
-
- <description>
- <p><file>pabrowse</file> lists all PulseAudio sound servers on the
- local network that are being announced with Zeroconf/Avahi.</p>
-
- <p>This program takes no command line arguments.</p>
- </description>
-
- <section name="Authors">
- <p>The PulseAudio Developers &lt;@PACKAGE_BUGREPORT@&gt;; PulseAudio is available from <url href="@PACKAGE_URL@"/></p>
- </section>
-
- <section name="See also">
- <p>
- <manref name="pulseaudio" section="1"/>, <manref name="avahi-daemon" section="8"/>
- </p>
- </section>
-
-</manpage>
diff --git a/man/pacat.1.xml.in b/man/pacat.1.xml.in
index 68a3a12a..2e274507 100644
--- a/man/pacat.1.xml.in
+++ b/man/pacat.1.xml.in
@@ -21,18 +21,22 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
USA.
-->
-<manpage name="pacat" section="1" desc="Play back or record raw audio streams on a PulseAudio sound server">
+<manpage name="pacat" section="1" desc="Play back or record raw or encoded audio streams on a PulseAudio sound server">
<synopsis>
+ <cmd>paplay [<arg>options</arg>] [<arg>FILE</arg>]</cmd>
+ <cmd>parecord [<arg>options</arg>] [<arg>FILE</arg>]</cmd>
<cmd>pacat [<arg>options</arg>] [<arg>FILE</arg>]</cmd>
<cmd>parec [<arg>options</arg>] [<arg>FILE</arg>]</cmd>
- <cmd>paplay <opt>--help</opt></cmd>
- <cmd>paplay <opt>--version</opt></cmd>
+ <cmd>pamon [<arg>options</arg>] [<arg>FILE</arg>]</cmd>
+ <cmd>pacat <opt>--help</opt></cmd>
+ <cmd>pacat <opt>--version</opt></cmd>
</synopsis>
<description>
<p><file>pacat</file> is a simple tool for playing back or
- capturing raw audio files on a PulseAudio sound server.</p>
+ capturing raw or encoded audio files on a PulseAudio sound
+ server.</p>
</description>
<options>
@@ -52,13 +56,13 @@ USA.
<option>
<p><opt>-r | --record</opt></p>
- <optdesc><p>Capture raw audio data and write it to the specified file or to STDOUT if none is specified. If the tool is called under the name <file>parec</file> this is the default.</p></optdesc>
+ <optdesc><p>Capture audio data and write it to the specified file or to STDOUT if none is specified. If the tool is called under the name <file>parec</file> this is the default.</p></optdesc>
</option>
<option>
<p><opt>-p | --playback</opt></p>
- <optdesc><p>Read raw audio data from the specified file or STDIN if none is specified, and play it back. If the tool is called under the name <file>pacat</file> this is the default.</p></optdesc>
+ <optdesc><p>Read audio data from the specified file or STDIN if none is specified, and play it back. If the tool is called under the name <file>pacat</file> this is the default.</p></optdesc>
</option>
<option>
@@ -108,14 +112,17 @@ USA.
<optdesc><p>Capture or play back audio with the specified sample
format. Specify one of <opt>u8</opt>, <opt>s16le</opt>,
- <opt>s16be</opt>, <opt>s32le</opt>,
- <opt>s32be</opt>, <opt>float32le</opt>, <opt>float32be</opt>,
- <opt>ulaw</opt>, <opt>alaw</opt>. Depending on the endianess of
- the CPU the
- formats <opt>s16ne</opt>, <opt>s16re</opt>, <opt>s32ne</opt>, <opt>s32re</opt>,
- <opt>float32ne</opt>, <opt>float32re</opt> (for native,
- resp. reverse endian) are available as aliases. Defaults to
- s16ne.</p></optdesc>
+ <opt>s16be</opt>, <opt>s32le</opt>, <opt>s32be</opt>,
+ <opt>float32le</opt>, <opt>float32be</opt>, <opt>ulaw</opt>,
+ <opt>alaw</opt>, <opt>s32le</opt>, <opt>s32be</opt>,
+ <opt>s24le</opt>, <opt>s24be</opt>, <opt>s24-32le</opt>,
+ <opt>s24-32be</opt>. Depending on the endianess of the CPU the
+ formats <opt>s16ne</opt>, <opt>s16re</opt>, <opt>s32ne</opt>,
+ <opt>s32re</opt>, <opt>float32ne</opt>, <opt>float32re</opt>,
+ <opt>s32ne</opt>, <opt>s32re</opt>, <opt>s24ne</opt>,
+ <opt>s24re</opt>, <opt>s24-32ne</opt>, <opt>s24-32re</opt> (for
+ native, resp. reverse endian) are available as aliases. Defaults
+ to s16ne.</p></optdesc>
</option>
<option>
@@ -170,6 +177,65 @@ USA.
<optdesc><p>Never remap channels. Instead of mapping channels by their name this will match them solely by their index/order.</p></optdesc>
</option>
+ <option>
+ <p><opt>--latency</opt><arg>=BYTES</arg></p>
+ <optdesc><p>Explicitly configure the latency, with a time
+ specified in bytes in the selected sample format. If left out
+ the server will pick the latency, usually relatively high for
+ power saving reasons. Use either this option or
+ <opt>--latency-msec</opt>, but not both.</p></optdesc>
+ </option>
+
+ <option>
+ <p><opt>--latency-msec</opt><arg>=MSEC</arg></p>
+ <optdesc><p>Explicitly configure the latency, with a time
+ specified in miliseconds. If left out the server will pick the
+ latency, usually relatively high for power saving reasons. Use
+ either this option or <opt>--latency</opt>, but not
+ both.</p></optdesc>
+ </option>
+
+ <option>
+ <p><opt>--process-time</opt><arg>=BYTES</arg></p>
+ <optdesc><p>Explicitly configure the process time, with a time
+ specified in bytes in the selected sample format. If left out
+ the server will pick the process time. Use either this option or
+ <opt>--process-time-msec</opt>, but not both.</p></optdesc>
+ </option>
+
+ <option>
+ <p><opt>--process-time-msec</opt><arg>=MSEC</arg></p>
+ <optdesc><p>Explicitly configure the process time, with a time
+ specified in miliseconds. If left out the server will pick the
+ process time. Use either this option or <opt>--process-time</opt>,
+ but not both.</p></optdesc>
+ </option>
+
+ <option>
+ <p><opt>--property</opt><arg>=PROPERTY=VALUE</arg></p>
+ <optdesc><p>Attach a property to the client and stream. May be
+ used multiple times</p></optdesc>
+ </option>
+
+ <option>
+ <p><opt>--raw</opt></p>
+ <optdesc><p>Play/record raw audio data. This is the default if
+ this program is invoked as <cmd>pacat</cmd>, <cmd>parec</cmd> or
+ <cmd>pamon</cmd>.</p></optdesc>
+ </option>
+
+ <option>
+ <p><opt>--file-format</opt><arg>[=FFORMAT]</arg></p>
+ <optdesc><p>Play/record encoded audio data in the file format
+ specified. This is the default if this program is invoked as
+ <cmd>paplay</cmd> and <cmd>parecord</cmd>.</p></optdesc>
+ </option>
+
+ <option>
+ <p><opt>--list-file-formats</opt></p>
+ <optdesc><p>List supported file formats.</p></optdesc>
+ </option>
+
</options>
<section name="Authors">
@@ -178,7 +244,7 @@ USA.
<section name="See also">
<p>
- <manref name="pulseaudio" section="1"/>, <manref name="paplay" section="1"/>
+ <manref name="pulseaudio" section="1"/>, <manref name="pactl" section="1"/>
</p>
</section>
diff --git a/man/pactl.1.xml.in b/man/pactl.1.xml.in
index 8d5bf1d3..7ba768a0 100644
--- a/man/pactl.1.xml.in
+++ b/man/pactl.1.xml.in
@@ -143,12 +143,6 @@ USA.
</option>
<option>
- <p><opt>unload-module</opt> <arg>ID</arg></p>
-
- <optdesc><p>Unload the module instance identified by the specified numeric index.</p></optdesc>
- </option>
-
- <option>
<p><opt>suspend-sink</opt> <arg>SINK</arg> <arg>1|0</arg></p>
<optdesc><p>Suspend or resume the specified sink (which my be
diff --git a/man/pax11publish.1.xml.in b/man/pax11publish.1.xml.in
index 3b40b978..be9ce0b8 100644
--- a/man/pax11publish.1.xml.in
+++ b/man/pax11publish.1.xml.in
@@ -84,7 +84,7 @@ USA.
the data from the $PULSE_SERVER, $PULSE_SINK, $PULSE_SOURCE
environment variables and combines them with the data from
<file>~/.pulse/client.conf</file> (or
- <file>@pulseconfdir@/client.conf</file> if that file does not
+ <file>@PA_DEFAULT_CONFIG_DIR@/client.conf</file> if that file does not
exist). If specific options are passed on the command line
(<opt>-S</opt>, <opt>-O</opt>, <opt>-I</opt>, <opt>-c</opt>, see
below), they take precedence. Also uploads the local
diff --git a/man/pulse-client.conf.5.xml.in b/man/pulse-client.conf.5.xml.in
index 26e38908..dc9ae0bd 100644
--- a/man/pulse-client.conf.5.xml.in
+++ b/man/pulse-client.conf.5.xml.in
@@ -26,14 +26,14 @@ USA.
<synopsis>
<p><file>~/.pulse/client.conf</file></p>
- <p><file>@pulseconfdir@/client.conf</file></p>
+ <p><file>@PA_DEFAULT_CONFIG_DIR@/client.conf</file></p>
</synopsis>
<description>
<p>The PulseAudio client library reads configuration directives from
a file <file>~/.pulse/client.conf</file> on startup and when that
file doesn't exist from
- <file>@pulseconfdir@/client.conf</file>.</p>
+ <file>@PA_DEFAULT_CONFIG_DIR@/client.conf</file>.</p>
<p>The configuration file is a simple collection of variable
declarations. If the configuration file parser encounters either ;
@@ -69,7 +69,7 @@ USA.
<option>
<p><opt>autospawn=</opt> Autospawn a PulseAudio daemon when
- needed. Takes a boolean value, defaults to "yes".</p>
+ needed. Takes a boolean value, defaults to <opt>yes</opt>.</p>
</option>
<option>
@@ -92,9 +92,9 @@ USA.
</option>
<option>
- <p><opt>disable-shm=</opt> Disable data transfer via POSIX
+ <p><opt>enable-shm=</opt> Enable data transfer via POSIX
shared memory. Takes a boolean argument, defaults to
- <opt>no</opt>.</p>
+ <opt>yes</opt>.</p>
</option>
<option>
@@ -106,6 +106,23 @@ USA.
memory overcommit.</p>
</option>
+ <option>
+ <p><opt>auto-connect-localhost=</opt> Automatically try to
+ connect to localhost via IP. Enabling this is a potential
+ security hole since connections are only authenticated one-way
+ and a rogue server might hence fool a client into sending it its
+ private (e.g. VoIP call) data. This was enabled by default on
+ PulseAudio version 0.9.21 and older. Defaults to
+ <opt>no</opt>.</p>
+ </option>
+
+ <option>
+ <p><opt>auto-connect-display=</opt> Automatically try to connect
+ to the host X11's $DISPLAY variable is set to. The same security
+ issues apply as to <opt>auto-connect-localhost=</opt>. Defaults
+ to <opt>no</opt>.</p>
+ </option>
+
</section>
<section name="Authors">
diff --git a/man/pulse-daemon.conf.5.xml.in b/man/pulse-daemon.conf.5.xml.in
index afa7ca00..6fcdd0ec 100644
--- a/man/pulse-daemon.conf.5.xml.in
+++ b/man/pulse-daemon.conf.5.xml.in
@@ -26,14 +26,14 @@ USA.
<synopsis>
<p><file>~/.pulse/daemon.conf</file></p>
- <p><file>@pulseconfdir@/daemon.conf</file></p>
+ <p><file>@PA_DEFAULT_CONFIG_DIR@/daemon.conf</file></p>
</synopsis>
<description>
<p>The PulseAudio sound server reads configuration directives from
a file <file>~/.pulse/daemon.conf</file> on startup and when that
file doesn't exist from
- <file>@pulseconfdir@/daemon.conf</file>. Please note that the
+ <file>@PA_DEFAULT_CONFIG_DIR@/daemon.conf</file>. Please note that the
server also reads a configuration script on startup
<file>default.pa</file> which also contains runtime configuration
directives.</p>
@@ -53,32 +53,33 @@ USA.
<option>
<p><opt>daemonize= </opt> Daemonize after startup. Takes a
- boolean value, defaults to "no". The <opt>--daemonize</opt>
+ boolean value, defaults to <opt>no</opt>. The <opt>--daemonize</opt>
command line option takes precedence.</p>
</option>
<option>
<p><opt>fail=</opt> Fail to start up if any of the directives
in the configuration script <file>default.pa</file>
- fail. Takes a boolean argument, defaults to "yes". The <opt>--fail</opt> command line
+ fail. Takes a boolean argument, defaults to <opt>yes</opt>. The <opt>--fail</opt> command line
option takes precedence.</p>
</option>
<option>
- <p><opt>disallow-module-loading=</opt> Disallow module loading
- after startup. This is a security feature that makes sure that
- no further modules may be loaded into the PulseAudio server
- after startup completed. It is recommended to enable this when
- <opt>system-instance</opt> is enabled. Please note that certain
- features like automatic hot-plug support will not work if this
- option is enabled. Takes a boolean argument, defaults to
- <opt>no</opt>. The <opt>--disallow-module-loading</opt> command line
- option takes precedence.</p>
+ <p><opt>allow-module-loading=</opt> Allow/disallow module
+ loading after startup. This is a security feature that if
+ dsabled makes sure that no further modules may be loaded into
+ the PulseAudio server after startup completed. It is recommended
+ to disable this when <opt>system-instance</opt> is
+ enabled. Please note that certain features like automatic
+ hot-plug support will not work if this option is enabled. Takes
+ a boolean argument, defaults to <opt>yes</opt>. The
+ <opt>--disallow-module-loading</opt> command line option takes
+ precedence.</p>
</option>
<option>
- <p><opt>disallow-exit=</opt> Disallow exit on user
- request. Defaults to <opt>no</opt>.</p>
+ <p><opt>allow-exit=</opt> Allow/disallow exit on user
+ request. Defaults to <opt>yes</opt>.</p>
</option>
<option>
@@ -88,56 +89,57 @@ USA.
<opt>src-zero-order-hold</opt>, <opt>src-linear</opt>,
<opt>trivial</opt>, <opt>speex-float-N</opt>,
<opt>speex-fixed-N</opt>, <opt>ffmpeg</opt>. See the
- documentation of libsamplerate for an explanation for the
- different src- methods. The method <opt>trivial</opt> is the most basic
- algorithm implemented. If you're tight on CPU consider using
- this. On the other hand it has the worst quality of them
- all. The Speex resamplers take an integer quality setting in the
- range 0..9 (bad...good). They exist in two flavours: <opt>fixed</opt> and
- <opt>float</opt>. The former uses fixed point numbers, the latter relies on
- floating point numbers. On most desktop CPUs the float point
- resmampler is a lot faster, and it also offers slightly better
- quality. See the output of <opt>dump-resample-methods</opt> for
- a complete list of all available resamplers. Defaults to
- <opt>speex-float-3</opt>. The <opt>--resample-method</opt>
- command line option takes precedence. Note that some modules
- overwrite or allow overwriting of the resampler to use.</p>
+ documentation of libsamplerate and speex for explanations of the
+ different src- and speex- methods, respectively. The method
+ <opt>trivial</opt> is the most basic algorithm implemented. If
+ you're tight on CPU consider using this. On the other hand it has
+ the worst quality of them all. The Speex resamplers take an
+ integer quality setting in the range 0..10 (bad...good). They
+ exist in two flavours: <opt>fixed</opt> and <opt>float</opt>. The former uses fixed point
+ numbers, the latter relies on floating point numbers. On most
+ desktop CPUs the float point resampler is a lot faster, and it
+ also offers slightly better quality. See the output of
+ <opt>dump-resample-methods</opt> for a complete list of all
+ available resamplers. Defaults to <opt>speex-float-3</opt>. The
+ <opt>--resample-method</opt> command line option takes precedence.
+ Note that some modules overwrite or allow overwriting of the
+ resampler to use.</p>
</option>
<option>
- <p><opt>disable-remixing=</opt> Never upmix or downmix channels
- to different channel maps. Instead, do a simple name-based
- matching only.</p>
+ <p><opt>enable-remixing=</opt> If disabled never upmix or
+ downmix channels to different channel maps. Instead, do a simple
+ name-based matching only. Defaults to <opt>yes.</opt></p>
</option>
<option>
- <p><opt>disable-lfe-remixing=</opt> When upmixing or downmixing
- ignore LFE channels. When this option is on the output LFE
- channel will only get a signal when an input LFE channel is
- available as well. If no input LFE channel is available the
- output LFE channel will always be 0. If no output LFE channel is
- available the signal on the input LFE channel will be
- ignored. Defaults to "on".</p>
+ <p><opt>enable-lfe-remixing=</opt> if disabeld when upmixing or
+ downmixing ignore LFE channels. When this option is dsabled the
+ output LFE channel will only get a signal when an input LFE
+ channel is available as well. If no input LFE channel is
+ available the output LFE channel will always be 0. If no output
+ LFE channel is available the signal on the input LFE channel
+ will be ignored. Defaults to <opt>no</opt>.</p>
</option>
<option>
- <p><opt>use-pid-file=</opt> Create a PID file in
- <file>/tmp/pulse-$USER/pid</file>. Of this is enabled you may
+ <p><opt>use-pid-file=</opt> Create a PID file in the runtime directory
+ (<file>$HOME/.pulse/*-runtime/pid</file>). If this is enabled you may
use commands like <opt>--kill</opt> or <opt>--check</opt>. If
you are planning to start more than one PulseAudio process per
user, you better disable this option since it effectively
disables multiple instances. Takes a boolean argument, defaults
- to <opt>yes</opt>. The <opt>--no-cpu-limit</opt> command line
+ to <opt>yes</opt>. The <opt>--use-pid-file</opt> command line
option takes precedence.</p>
</option>
<option>
- <p><opt>no-cpu-limit=</opt> Do not install the CPU load limiter,
- even on platforms where it is supported. This option is useful
- when debugging/profiling PulseAudio to disable disturbing
- SIGXCPU signals. Takes a boolean argument, defaults to <opt>no</opt>. The
- <opt>--no-cpu-limit</opt> command line argument takes
- precedence.</p>
+ <p><opt>cpu-limit=</opt> If disabled do not install the CPU load
+ limiter, even on platforms where it is supported. This option is
+ useful when debugging/profiling PulseAudio to disable disturbing
+ SIGXCPU signals. Takes a boolean argument, defaults to
+ <opt>no</opt>. The <opt>--no-cpu-limit</opt> command line
+ argument takes precedence.</p>
</option>
<option>
@@ -148,9 +150,9 @@ USA.
</option>
<option>
- <p><opt>disable-shm=</opt> Disable data transfer via POSIX
+ <p><opt>enable-shm=</opt> Enable data transfer via POSIX
shared memory. Takes a boolean argument, defaults to
- <opt>no</opt>. The <opt>--disable-shm</opt> command line
+ <opt>yes</opt>. The <opt>--disable-shm</opt> command line
argument takes precedence.</p>
</option>
@@ -164,6 +166,14 @@ USA.
</option>
<option>
+ <p><opt>lock-memory=</opt> Locks the entire PulseAudio process
+ into memory. While this might increase drop-out safety when used
+ in conjunction with real-time scheduling this takes away a lot
+ of memory from other processes and might hence considerably slow
+ down your system. Defaults to <opt>no</opt>.</p>
+ </option>
+
+ <option>
<p><opt>flat-volumes=</opt> Enable 'flat' volumes, i.e. where
possible let the sink volume equal the maximum of the volumes of
the inputs connected to it. Takes a boolean argument, defaults
@@ -182,7 +192,7 @@ USA.
RLIMIT_NICE is used. root is dropped immediately after gaining
the nice level on startup, thus it is presumably safe. See
<manref section="1" name="pulseaudio"/> for more
- information. Takes a boolean argument, defaults to "yes". The <opt>--high-priority</opt>
+ information. Takes a boolean argument, defaults to <opt>yes</opt>. The <opt>--high-priority</opt>
command line option takes precedence.</p>
</option>
@@ -196,7 +206,7 @@ USA.
real-time. The controlling thread is left a normally scheduled
thread. Thus enabling the high-priority option is orthogonal.
See <manref section="1" name="pulseaudio"/> for more
- information. Takes a boolean argument, defaults to "no". The
+ information. Takes a boolean argument, defaults to <opt>yes</opt>. The
<opt>--realtime</opt> command line option takes precedence.</p>
</option>
@@ -206,7 +216,7 @@ USA.
by default, 9 for clients. Thus it is recommended to choose the
PulseAudio real-time priorities lower. Some PulseAudio threads
might choose a priority a little lower or higher than the
- specified value. Defaults to "5".</p>
+ specified value. Defaults to <opt>5</opt>.</p>
</option>
<option>
@@ -222,19 +232,12 @@ USA.
<option>
<p><opt>exit-idle-time=</opt> Terminate the daemon after the
last client quit and this time in seconds passed. Use a negative value to
- disable this feature. Defaults to -1. The
+ disable this feature. Defaults to 20. The
<opt>--exit-idle-time</opt> command line option takes
precedence.</p>
</option>
<option>
- <p><opt>module-idle-time=</opt> Unload autoloaded modules after
- being idle for this time in seconds. Defaults to 20. The
- <opt>--module-idle-time</opt> command line option takes
- precedence.</p>
- </option>
-
- <option>
<p><opt>scache-idle-time=</opt> Unload autoloaded sample cache
entries after being idle for this time in seconds. Defaults to
20. The <opt>--scache-idle-time</opt> command line option takes
@@ -259,17 +262,17 @@ USA.
default script file. The default behaviour is to load
<file>~/.pulse/default.pa</file>, and if that file does not
exist fall back to the system wide installed version
- <file>@pulseconfdir@/default.pa</file>. If run in system-wide
- mode the file <file>@pulseconfdir@/system.pa</file> is used
+ <file>@PA_DEFAULT_CONFIG_DIR@/default.pa</file>. If run in system-wide
+ mode the file <file>@PA_DEFAULT_CONFIG_DIR@/system.pa</file> is used
instead. If <opt>-n</opt> is passed on the command line
or <opt>default-script-file=</opt> is disabled the default
configuration script is ignored.</p>
</option>
<option>
- <p><opt>default-script-file=</opt> Load the default
+ <p><opt>load-default-script-file=</opt> Load the default
configuration script file as specified
- in <opt>default-script-file=</opt>. Defaults to "yes".</p>
+ in <opt>default-script-file=</opt>. Defaults to <opt>yes</opt>.</p>
</option>
</section>
@@ -296,6 +299,23 @@ USA.
might alter this setting.</p>
</option>
+ <option>
+ <p><opt>log-meta=</opt> With each logged message log the code
+ location the message was generated from. Defaults to
+ <opt>no</opt>.</p>
+ </option>
+
+ <option>
+ <p><opt>log-time=</opt> With each logged messages log the
+ relative time since startup. Defaults to <opt>no</opt>.</p>
+ </option>
+
+ <option>
+ <p><opt>log-backtrace=</opt> When greater than 0, with each
+ logged message log a code stack trace up the the specified
+ number of stack frames. Defaults to <opt>0</opt>.</p>
+ </option>
+
</section>
<section name="Resource Limits">
@@ -371,11 +391,13 @@ USA.
<option>
<p><opt>default-sample-format=</opt> The default sampling
format. Specify one of <opt>u8</opt>, <opt>s16le</opt>,
- <opt>s16be</opt>, <opt>s32le</opt>,
- <opt>s32be</opt>, <opt>float32le</opt>, <opt>float32be</opt>,
+ <opt>s16be</opt>, <opt>s24le</opt>, <opt>s24be</opt>,
+ <opt>s24-32le</opt>, <opt>s24-32be</opt>, <opt>s32le</opt>,
+ <opt>s32be</opt> <opt>float32le</opt>, <opt>float32be</opt>,
<opt>ulaw</opt>, <opt>alaw</opt>. Depending on the endianess of
- the CPU the
- formats <opt>s16ne</opt>, <opt>s16re</opt>, <opt>s32ne</opt>, <opt>s32re</opt>,
+ the CPU the formats <opt>s16ne</opt>, <opt>s16re</opt>,
+ <opt>s24ne</opt>, <opt>s24re</opt>, <opt>s24-32ne</opt>,
+ <opt>s24-32re</opt>, <opt>s32ne</opt>, <opt>s32re</opt>,
<opt>float32ne</opt>, <opt>float32re</opt> (for native,
resp. reverse endian) are available as aliases.</p>
</option>
@@ -401,7 +423,8 @@ USA.
these buffer metrics for machines with high scheduling
latencies. Not all possible values that may be configured here are
available in all hardware. The driver will to find the nearest
- setting supported.</p>
+ setting supported. Modern drivers that support timer-based
+ scheduling ignore these options.</p>
<option>
<p><opt>default-fragments=</opt> The default number of
@@ -415,6 +438,36 @@ USA.
</section>
+ <section name="Default Sync Volume Settings">
+
+ <p>With the flat volume feature enabled, the sink HW volume is set
+ to the same level as the highest volume input stream. Any other streams
+ (with lower volumes) have the appropriate adjustment applied in SW to
+ bring them to the correct overall level. Sadly hadware mixer changes
+ cannot be timed accurately and thus this change of volumes can somtimes
+ cause the resulting output sound to be momentarily too loud or too soft.
+ So to ensure SW and HW volumes are applied concurrently without any
+ glitches, their application needs to be synchronized. The sink
+ implementation needs to support synchronized volumes. The following
+ parameters can be used to refine the process.</p>
+
+ <option>
+ <p><opt>enable-sync-volume=</opt> Enable sync volume for the sinks that
+ support it. This feature is enabled by default.</p>
+ </option>
+ <option>
+ <p><opt>sync-volume-safety-margin-usec=</opt> The amount of time (in
+ usec) by which the HW volume increases are delayed and HW volume
+ decreases are advanced. Defaults to 8000 usec.</p>
+ </option>
+ <option>
+ <p><opt>sync-volume-extra-delay-usec=</opt> The amount of time (in usec)
+ by which HW volume changes are delayed. Negative values are also allowed.
+ Defaults to 0.</p>
+ </option>
+
+ </section>
+
<section name="Authors">
<p>The PulseAudio Developers &lt;@PACKAGE_BUGREPORT@&gt;; PulseAudio is available from <url href="@PACKAGE_URL@"/></p>
</section>
diff --git a/man/pulseaudio.1.xml.in b/man/pulseaudio.1.xml.in
index 8810e90c..4e58ffb4 100644
--- a/man/pulseaudio.1.xml.in
+++ b/man/pulseaudio.1.xml.in
@@ -314,21 +314,21 @@ USA.
<section name="Files">
<p><file>~/.pulse/daemon.conf</file>,
- <file>@pulseconfdir@/daemon.conf</file>: configuration settings
+ <file>@PA_DEFAULT_CONFIG_DIR@/daemon.conf</file>: configuration settings
for the PulseAudio daemon. If the version in the user's home
directory does not exist the global configuration file is
loaded. See <manref name="pulse-daemon.conf" section="5"/> for
more information.</p>
<p><file>~/.pulse/default.pa</file>,
- <file>@pulseconfdir@/default.pa</file>: the default configuration
+ <file>@PA_DEFAULT_CONFIG_DIR@/default.pa</file>: the default configuration
script to execute when the PulseAudio daemon is started. If the
version in the user's home directory does not exist the global
configuration script is loaded. See <manref name="default.pa"
section="5"/> for more information.</p>
<p><file>~/.pulse/client.conf</file>,
- <file>@pulseconfdir@/client.conf</file>: configuration settings
+ <file>@PA_DEFAULT_CONFIG_DIR@/client.conf</file>: configuration settings
for PulseAudio client applications. If the version in the user's
home directory does not exist the global configuration file is
loaded. See <manref name="pulse-client.conf" section="5"/> for
diff --git a/orc.mak b/orc.mak
new file mode 100644
index 00000000..5a6ff96b
--- /dev/null
+++ b/orc.mak
@@ -0,0 +1,46 @@
+#
+# This is a Makefile.am fragment to build Orc code. It is based
+# on the orc.mak file distributed in the GStreamer common
+# repository.
+#
+# Include this file like this:
+#
+# include $(top_srcdir)/orc.mak
+#
+# For each Orc source file, append its name (without the extension)
+# to ORC_SOURCE:
+#
+# ORC_SOURCE += gstadderorc
+#
+# This will create gstadder-orc-gen.c and gstadder-orc-gen.h, which
+# you need to add to your nodist_module_SOURCES.
+#
+# Note that this file appends to BUILT_SOURCES and CLEANFILES, so
+# define them before including this file.
+#
+
+
+EXTRA_DIST += $(addsuffix .orc,$(ORC_SOURCE))
+
+ORC_BUILT_SOURCE = $(addsuffix -orc-gen.c,$(ORC_SOURCE))
+ORC_BUILT_HEADER = $(addsuffix -orc-gen.h,$(ORC_SOURCE))
+
+BUILT_SOURCES += $(ORC_BUILT_SOURCE) $(ORC_BUILT_HEADER)
+CLEANFILES += $(BUILT_SOURCES)
+
+
+orcc_v_gen = $(orcc_v_gen_$(V))
+orcc_v_gen_ = $(orcc_v_gen_$(AM_DEFAULT_VERBOSITY))
+orcc_v_gen_0 = @echo " ORCC $@";
+
+cp_v_gen = $(cp_v_gen_$(V))
+cp_v_gen_ = $(cp_v_gen_$(AM_DEFAULT_VERBOSITY))
+cp_v_gen_0 = @echo " CP $@";
+
+%-orc-gen.c: %.orc
+ @mkdir -p $(@D)
+ $(orcc_v_gen)$(ORCC) --implementation -o $@ $<
+
+%-orc-gen.h: %.orc
+ @mkdir -p $(@D)
+ $(orcc_v_gen)$(ORCC) --header -o $@ $<
diff --git a/po/LINGUAS b/po/LINGUAS
index ad7275d9..205e4828 100644
--- a/po/LINGUAS
+++ b/po/LINGUAS
@@ -2,25 +2,33 @@ as
bn_IN
ca
cs
-de
de_CH
+de
el
es
fi
fr
gu
+he
+hi
+hu
it
+ja
kn
+ml
mr
nl
or
pa
pl
pt_BR
-sr
+pt
+ru
sr@latin
+sr
sv
ta
te
uk
zh_CN
+zh_TW
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 2cd451f5..f8936550 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -15,7 +15,7 @@ src/modules/alsa/alsa-util.c
src/modules/module-pipe-source.c
src/modules/module-solaris.c
src/modules/module-default-device-restore.c
-src/modules/module-x11-xsmp.c
+src/modules/x11/module-x11-xsmp.c
src/modules/module-remap-sink.c
src/modules/bluetooth/module-bluetooth-proximity.c
src/modules/module-detect.c
@@ -24,23 +24,23 @@ src/modules/module-lirc.c
src/modules/module-hal-detect.c
src/modules/module-sine.c
src/modules/module-zeroconf-publish.c
-src/modules/module-jack-source.c
+src/modules/jack/module-jack-source.c
src/modules/module-cli.c
src/modules/gconf/module-gconf.c
src/modules/gconf/gconf-helper.c
src/modules/module-esound-sink.c
src/modules/alsa/module-alsa-sink.c
src/modules/module-volume-restore.c
-src/modules/module-x11-bell.c
+src/modules/x11/module-x11-bell.c
src/modules/module-protocol-stub.c
src/modules/module-stream-restore.c
-src/modules/module-jack-sink.c
+src/modules/jack/module-jack-sink.c
src/modules/module-esound-compat-spawnfd.c
src/modules/module-esound-compat-spawnpid.c
#src/modules/module-waveout.c
src/modules/module-combine.c
src/modules/bluetooth/proximity-helper.c
-src/modules/module-x11-publish.c
+src/modules/x11/module-x11-publish.c
src/modules/rtp/module-rtp-recv.c
src/modules/rtp/sdp.c
src/modules/rtp/rtp.c
@@ -55,7 +55,6 @@ src/pulsecore/queue.c
src/pulsecore/core.c
#src/pulsecore/shmasyncq.c
src/pulsecore/x11wrap.c
-src/pulsecore/rtclock.c
src/pulsecore/ioline.c
src/pulsecore/asyncq.c
src/pulsecore/mutex-posix.c
@@ -85,7 +84,6 @@ src/pulsecore/socket-client.c
src/pulsecore/idxset.c
src/pulsecore/pipe.c
src/pulsecore/asyncmsgq.c
-src/pulsecore/inet_pton.c
src/pulsecore/socket-util.c
src/pulsecore/object.c
src/pulsecore/sioman.c
@@ -94,12 +92,10 @@ src/pulsecore/x11prop.c
src/pulsecore/sconv-s16be.c
src/pulsecore/thread-posix.c
src/pulsecore/client.c
-src/pulsecore/inet_ntop.c
src/pulsecore/strlist.c
src/pulsecore/msgobject.c
src/pulsecore/mutex-win32.c
src/pulsecore/dynarray.c
-src/pulsecore/rtsig.c
src/pulsecore/once.c
src/pulsecore/source.c
src/pulsecore/memchunk.c
@@ -111,7 +107,6 @@ src/pulsecore/core-error.c
src/pulsecore/strbuf.c
src/pulsecore/play-memblockq.c
src/pulsecore/dllmain.c
-src/pulsecore/envelope.c
src/pulsecore/pid.c
src/pulsecore/thread-mq.c
src/pulsecore/shm.c
@@ -149,14 +144,13 @@ src/pulsecore/protocol-http.c
src/pulsecore/semaphore-win32.c
src/daemon/cpulimit.c
src/daemon/ltdl-bind-now.c
-src/daemon/polkit.c
src/daemon/main.c
src/daemon/cmdline.c
src/daemon/dumpmodules.c
src/daemon/daemon-conf.c
src/daemon/caps.c
src/daemon/pulseaudio.desktop.in
-src/daemon/org.pulseaudio.policy.in
+src/daemon/pulseaudio-kde.desktop.in
src/pulse/channelmap.c
src/pulse/error.c
src/pulse/proplist.c
@@ -170,7 +164,6 @@ src/pulse/mainloop-api.c
src/pulse/sample.c
src/pulse/client-conf-x11.c
src/pulse/client-conf.c
-src/pulse/browser.c
src/pulse/volume.c
src/pulse/simple.c
src/pulse/subscribe.c
@@ -183,17 +176,22 @@ src/pulse/thread-mainloop.c
src/pulse/scache.c
src/pulse/glib-mainloop.c
src/pulse/timeval.c
+src/pulse/format.c
src/utils/pacat.c
src/utils/pasuspender.c
-src/utils/pabrowse.c
src/utils/pactl.c
src/utils/padsp.c
src/utils/pax11publish.c
src/utils/pacmd.c
-src/utils/paplay.c
src/pulsecore/lock-autospawn.c
src/modules/alsa/alsa-sink.c
src/modules/alsa/alsa-source.c
src/modules/alsa/module-alsa-card.c
src/modules/bluetooth/module-bluetooth-device.c
src/modules/reserve-wrap.c
+src/modules/module-rygel-media-server.c
+src/modules/alsa/alsa-mixer.c
+src/modules/echo-cancel/module-echo-cancel.c
+src/modules/module-equalizer-sink.c
+src/modules/module-filter-apply.c
+src/tests/resampler-test.c
diff --git a/po/POTFILES.skip b/po/POTFILES.skip
index 4622d2fe..8afd0d6b 100644
--- a/po/POTFILES.skip
+++ b/po/POTFILES.skip
@@ -1 +1,3 @@
src/pulsecore/atomic.h
+src/modules/module-virtual-sink.c
+src/modules/module-virtual-source.c
diff --git a/po/as.po b/po/as.po
index 12488e66..0c20a630 100644
--- a/po/as.po
+++ b/po/as.po
@@ -1,66 +1,28 @@
+# translation of pulseaudio.master-tx.as.po to Assamese
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Amitakhya Phukan <aphukan@fedoraproject.org>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio.master-tx.pulseaudio.as\n"
+"Project-Id-Version: pulseaudio.master-tx.as\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-08 12:35+0530\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-11 17:11+0530\n"
"Last-Translator: Amitakhya Phukan <aphukan@fedoraproject.org>\n"
-"Language-Team: Assamese <fedora-trans-as@redhat.com>\n"
+"Language-Team: Assamese <>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Generator: Lokalize 0.3\n"
+"X-Generator: Lokalize 0.2\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analog Mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analog Stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Digital Stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Digital Stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analog ছাৰাউণà§à¦¡ 4.০"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digital ছাৰাউণà§à¦¡ 4.০ (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analog ছাৰাউণà§à¦¡ 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analog ছাৰাউণà§à¦¡ 5.০"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analog ছাৰাউণà§à¦¡ 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digital ছাৰাউণà§à¦¡ 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analog ছাৰাউণà§à¦¡ 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -72,7 +34,7 @@ msgstr ""
"অতি সমà§à¦­à§± à¦à¦‡à¦Ÿà§‹ ALSA চালক '%s' à§° à¦à¦Ÿà¦¾ বাগ । অনà§à¦—à§à§°à¦¹ কৰি à¦à¦‡ সমসà§à¦¯à¦¾ ALSA বিকাশকক "
"জনাওক ।"
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -84,7 +46,7 @@ msgstr ""
"অতি সমà§à¦­à§± à¦à¦‡à¦Ÿà§‹ ALSA চালক '%s' à§° à¦à¦Ÿà¦¾ বাগ । অনà§à¦—à§à§°à¦¹ কৰি à¦à¦‡ সমসà§à¦¯à¦¾ ALSA বিকাশকক "
"জনাওক ।"
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -96,11 +58,45 @@ msgstr ""
"অতি সমà§à¦­à§± à¦à¦‡à¦Ÿà§‹ ALSA চালক '%s' à§° à¦à¦Ÿà¦¾ বাগ । অনà§à¦—à§à§°à¦¹ কৰি à¦à¦‡ সমসà§à¦¯à¦¾ ALSA বিকাশকক "
"জনাওক ।"
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "সদায়ে অনà§à¦¤à¦¤ à¦à¦Ÿà¦¾ sink লোড কৰি ৰখা হ'ব, পà§à§°à§Ÿà§‹à¦œà¦¨à¦¤ null sink বà§à¦¯à§±à¦¹à¦¾à§° কৰা হ'ব"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ডামি নিৰà§à¦—ম"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "ভাৰà§à¦šà§à§Ÿà¦¾à¦² LADSPA sink"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "NULL sink à§° সময় নিৰà§à¦§à¦¾à§°à¦£"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null ফলাফল"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "আভà§à¦¯à¦¨à§à¦¤à§°à§€à¦£ অ'ডিঅ'"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "মোডেম"
@@ -114,414 +110,326 @@ msgstr "নতà§à¦¨ dl loader বিতৰণ কৰিবলৈ বিফল à
#: ../src/daemon/ltdl-bind-now.c:142
msgid "Failed to add bind-now-loader."
-msgstr "bind-now-loader যোগ কৰিবলৈ বিফল ।"
-
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "পà§à§°à¦£à¦¾à¦²à§€à§° bus লৈ সংযোগ কৰিব পৰা ন'গ'ল: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PID ৰ পৰা caller পোৱা ন'গ'ল: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "caller বসà§à¦¤à§à¦¤ UID নিৰà§à¦§à¦¾à§°à¦£ কৰিব পৰা ন'গ'ল ।"
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK অধিবেশন পাবলৈ বিফল ।"
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "অধিবেশনৰ বসà§à¦¤à§à¦¤ UID নিৰà§à¦§à¦¾à§°à¦£ কৰিব নোৱাৰি ।"
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitAction বিতৰণ কৰিব নোৱাৰি ।"
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "action_id নিৰà§à¦§à¦¾à§°à¦£ কৰিব নোৱাৰি ।"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext বিতৰণ কৰিব নোৱাৰি ।"
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContext আৰমà§à¦­ কৰিব নোৱাৰি: %s"
+msgstr "bind now loader যোগ কৰিবলৈ বিফল ।"
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "caller à§° অনà§à¦®à¦¤à¦¿ আছে নে নাই নিৰà§à¦§à¦¾à§°à¦£ কৰিব নোৱাৰি: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "auth পাব নোৱাৰি: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit ঠ'%s' উতà§à¦¤à§° দিলে"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "চিগà§à¦¨à§‡à¦² %s পোৱা গ'ল ।"
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "পà§à§°à¦¸à§à¦¥à¦¾à¦¨ কৰা হৈছে ।"
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "বà§à¦¯à§±à¦¹à¦¾à§°à¦•à§°à§à¦¤à¦¾ '%s' পোৱা ন'গ'ল ।"
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "'%s' সমষà§à¦Ÿà¦¿ পোৱা ন'গ'ল ।"
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "বà§à¦¯à§±à¦¹à¦¾à§°à¦•à§°à§à¦¤à¦¾ '%s' (UID %lu) আৰৠসমষà§à¦Ÿà¦¿ '%s' (GID %lu) পোৱা গ'ল ।"
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "বà§à¦¯à§±à¦¹à¦¾à§°à¦•à§°à§à¦¤à¦¾ '%s' আৰৠসমষà§à¦Ÿà¦¿ '%s' à§° GID অমিল ।"
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "বà§à¦¯à§±à¦¹à¦¾à§°à¦•à§°à§à¦¤à¦¾ '%s' à§° ঘৰৰ পঞà§à¦œà¦¿à¦•া '%s' নহয়, আওকাণ কৰা হৈছে ।"
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s' সৃষà§à¦Ÿà¦¿ কৰিবলৈ বিফল: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "সমষà§à¦Ÿà¦¿à§° তালিকা সলনি কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID সলনি কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID সলনি কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "ৰূটৰ অধিকাৰ সফলভাবে à¦à§°à§‹à§±à¦¾ গ'ল ।"
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "à¦à¦‡ সà§à¦¥à¦¾à¦ªà¦¤à§à¦¯à¦¤ পà§à§°à¦£à¦¾à¦²à§€ বà§à¦¯à¦¾à¦ªà¦• মোড অসমৰà§à¦¥à¦¿à¦¤ ।"
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) বিফল: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "আদেশ শাৰী বিশà§à¦²à§‡à¦·à¦£ কৰিবলৈ বিফল ।"
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "আমি '%s' সমষà§à¦Ÿà¦¿à¦¤, য'ত high-priority scheduling à§° অনà§à¦®à¦¤à¦¿ আছে ।"
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "আমি '%s' সমষà§à¦Ÿà¦¿à¦¤, য'ত real-time scheduling à§° অনà§à¦®à¦¤à¦¿ আছে ।"
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit ঠআমাক acquire-high-priority অধিকাৰ দিয়ে ।"
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit ঠacquire-high-priority অধিকাৰ নিদিয়ে ।"
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit ঠআমাক acquire-real-time অধিকাৰ দিয়ে ।"
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit ঠacquire-real-time অধিকাৰ নিদিয়ে ।"
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"বিনà§à¦¯à¦¾à¦¸ দà§à¦¬à¦¾à§°à¦¾ high-priority scheduling à§° সকà§à§°à¦¿à§Ÿ হ'লেও নিয়মনীতি দà§à¦¬à¦¾à§°à¦¾ সেইটো "
-"অনà§à¦®à§‹à¦¦à¦¿à¦¤ নহয় ।"
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO সফলতাৰে বৃদà§à¦§à¦¿ কৰা হৈছে"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO বিফল: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "CAP_NICE বৰà§à¦œà¦¨ কৰা হৈছে"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"বিনà§à¦¯à¦¾à¦¸ দà§à¦¬à¦¾à§°à¦¾ real-time scheduling à§° সকà§à§°à¦¿à§Ÿ হ'লেও নিয়মনীতি দà§à¦¬à¦¾à§°à¦¾ সেইটো অনà§à¦®à§‹à¦¦à¦¿à¦¤ "
-"নহয় ।"
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "ডেমন নাই চলা"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "PID %u ৰূপে ডেমন চলিছে"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "ডেমন kill কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr ""
-"root পৰিচয়ে à¦à¦‡ পà§à§°à§‹à¦—à§à§°à¦¾à¦® সঞà§à¦šà¦¾à¦²à¦¿à¦¤ হোৱা উচিত নহয় (ন'হ'লে --system উলà§à¦²à¦¿à¦–িত হয়) ।"
+"root পৰিচয়ে à¦à¦‡ পà§à§°à§‹à¦—à§à§°à¦¾à¦® সঞà§à¦šà¦¾à¦²à¦¿à¦¤ হোৱা উচিত নহয় (ন'হ'লে system উলà§à¦²à¦¿à¦–িত হয়) ।"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
-msgstr "Root-à§° অধিকাৰ আৱশà§à¦¯à¦• ।"
+msgstr "Root à§° অধিকাৰ আৱশà§à¦¯à¦• ।"
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
-msgstr "পà§à§°à¦£à¦¾à¦²à§€ চানেকিৰ কà§à¦·à§‡à¦¤à§à§°à¦¤ --start সমৰà§à¦¥à¦¿à¦¤ নহয় ।"
+msgstr "পà§à§°à¦£à¦¾à¦²à§€ চানেকিৰ কà§à¦·à§‡à¦¤à§à§°à¦¤ start সমৰà§à¦¥à¦¿à¦¤ নহয় ।"
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
-msgstr "পà§à§°à¦£à¦¾à¦²à§€ মোডত চলিছে, কিনà§à¦¤à§ --disallow-exit নিৰà§à¦§à¦¾à§°à¦¿à¦¤ নহয়!"
+msgstr "পà§à§°à¦£à¦¾à¦²à§€ মোডত চলিছে, কিনà§à¦¤à§ disallow exit নিৰà§à¦§à¦¾à§°à¦¿à¦¤ নহয়!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
-msgstr "পà§à§°à¦£à¦¾à¦²à§€ মোডত চলিছে, কিনà§à¦¤à§ --disallow-module-loading নিৰà§à¦§à¦¾à§°à¦¿à¦¤ নহয়!"
+msgstr "পà§à§°à¦£à¦¾à¦²à§€ মোডত চলিছে, কিনà§à¦¤à§ disallow module loading নিৰà§à¦§à¦¾à§°à¦¿à¦¤ নহয়!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "পà§à§°à¦£à¦¾à¦²à§€ মোডত চলিছে, SHM মোড বলপূৰà§à¦¬à¦• নিষà§à¦•à§à§°à¦¿à§Ÿ কৰা হৈছে!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"পà§à§°à¦£à¦¾à¦²à§€ মোডত চলিছে, কাম নকৰা সময়ৰ পৰা পà§à§°à¦¸à§à¦¥à¦¾à¦¨ কৰা বলপূৰà§à¦¬à¦• নিষà§à¦•à§à§°à¦¿à§Ÿ কৰা হৈছে!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥ ।"
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "pipe বিফল: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() বিফল: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() বিফল: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "ডেমন আৰমà§à¦­ কৰিবলৈ বিফল ।"
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "সফলতাৰে ডেমন আৰমà§à¦­ কৰা হৈছে ।"
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() বিফল: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "à¦à¦‡à¦Ÿà§‹ PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "সঙà§à¦•লনৰ গৃহসà§à¦¥: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "সঙà§à¦•লনৰ CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "গৃহসà§à¦¥à¦¤ চলোৱা হৈছে: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPU পোৱা গৈছে ।"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "পেজৰ মাপ %lu bytes"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Valgrind সমৰà§à¦¥à¦¨à§° সৈতে সঙà§à¦•লন কৰা হৈছে: হয়"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Valgrind সমৰà§à¦¥à¦¨à§° সৈতে সঙà§à¦•লন কৰা হৈছে: নহয়"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind মোডত চলিছে: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "গৃহসà§à¦¥à¦¤ চলোৱা হৈছে: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Optimized build: হয়"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Optimized build: নহয়"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG বà§à¦¯à¦¾à¦–à§à¦¯à¦¾ কৰা হৈছে, সকলো asserts নিষà§à¦•à§à§°à¦¿à§Ÿ কৰা হৈছে ।"
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH বà§à¦¯à¦¾à¦–à§à¦¯à¦¾ কৰা হৈছে, অকল fast path asserts নিষà§à¦•à§à§°à¦¿à§Ÿ কৰা হৈছে ।"
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "সকলো asserts সকà§à§°à¦¿à§Ÿ কৰা হৈছে ।"
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "যনà§à¦¤à§à§° ID পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "যনà§à¦¤à§à§° ID হ'ল %s ।"
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "যনà§à¦¤à§à§° ID হ'ল %s ।"
+msgstr "সেশান ID হল %s।"
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
-msgstr "ৰান-টাইম পঞà§à¦œà¦¿à¦•া %s বà§à¦¯à§±à¦¹à¦¾à§° কৰা হৈছে ।"
+msgstr "ৰান টাইম পঞà§à¦œà¦¿à¦•া %s বà§à¦¯à§±à¦¹à¦¾à§° কৰা হৈছে ।"
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "অৱসà§à¦¥à¦¾à¦¸à§‚চক পঞà§à¦œà¦¿à¦•া %s বà§à¦¯à§±à¦¹à¦¾à§° কৰা হৈছে ।"
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "মডিউল ডিৰেকà§à¦Ÿà§°à¦¿ %s বà§à¦¯à§±à¦¹à¦¾à§° কৰা হচà§à¦›à§‡à¥¤"
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "পà§à§°à¦£à¦¾à¦²à§€ মোডত চলিছে: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"আপনি সিসà§à¦Ÿà§‡à¦® মোডে PA সঞà§à¦šà¦¾à¦²à¦¿à¦¤ কৰছেন à¦à¦¬à¦‚ à¦à¦Ÿà¦¿ না কৰাই বাঞà§à¦›à¦¨à§€à§Ÿà¥¤\n"
+"à¦à§° ফলে পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¾à¦®à¦¤ ফলাফল না পাওয়াৰ সমà§à¦­à¦¾à¦¬à¦¨à¦¾ ৰয়েছে।\n"
+"সিসà§à¦Ÿà§‡à¦® মোডে বà§à¦¯à§±à¦¹à¦¾à§°à§‡à§° সমসà§à¦¯à¦¾ সমà§à¦ªà§°à§à¦•ে জানতে হলে http://pulseaudio.org/wiki/"
+"WhatIsWrongWithSystemMode দেখà§à¦¨à¥¤"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() বà§à¦¯à§°à§à¦¥ ।"
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
-msgstr "নতà§à¦¨ high-resolution timers পোৱা হয়! অভিননà§à¦¦à¦¨!"
+msgstr "নতà§à¦¨ high resolution timers পোৱা হয়! অভিননà§à¦¦à¦¨!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr ""
-"শà§à§°à§€à¦®à¦¾à¦¨, আপোনাৰ কাৰà§à¦£à§‡à¦² পূৰণি! high-resolution timer সকà§à§°à¦¿à§Ÿ থকা Linux ক আজি "
+"শà§à§°à§€à¦®à¦¾à¦¨, আপোনাৰ কাৰà§à¦£à§‡à¦² পূৰণি! high resolution timer সকà§à§°à¦¿à§Ÿ থকা Linux ক আজি "
"উপদেশ দিয়া হয়!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() বà§à¦¯à§°à§à¦¥ ।"
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "ডেমন আৰমà§à¦­ কৰিবলৈ বà§à¦¯à§°à§à¦¥ ।"
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
"তà§à¦²à¦¿ লোৱা মডিউল নোহোৱাকে ডেমন আৰমà§à¦­ কৰা হৈছে, কোনো কাম সঞà§à¦šà¦¾à¦²à¦¨ কৰা সমà§à¦­à§± নহয় ।"
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "ডেমন আৰমà§à¦­ কৰা সমà§à¦ªà§‚à§°à§à¦£ ।"
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "ডেমন বনà§à¦§ কৰাৰ পà§à§°à¦•à§à§°à¦¿à§Ÿà¦¾ আৰমà§à¦­ কৰা হৈছে ।"
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "ডেমন বনà§à¦§ কৰা হৈছে ।"
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -597,137 +505,137 @@ msgstr ""
"%s [options]\n"
"\n"
"COMMANDS:\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-" --dump-conf Dump default configuration\n"
-" --dump-modules Dump list of available modules\n"
-" --dump-resample-methods Dump available resample methods\n"
-" --cleanup-shm Cleanup stale shared memory "
+" h, help Show this help\n"
+" version Show version\n"
+" dump conf Dump default configuration\n"
+" dump modules Dump list of available modules\n"
+" dump resample methods Dump available resample methods\n"
+" cleanup shm Cleanup stale shared memory "
"segments\n"
-" --start Start the daemon if it is not "
+" start Start the daemon if it is not "
"running\n"
-" -k --kill Kill a running daemon\n"
-" --check Check for a running daemon (only "
+" k kill Kill a running daemon\n"
+" check Check for a running daemon (only "
"returns exit code)\n"
"\n"
"OPTIONS:\n"
-" --system[=BOOL] Run as system-wide instance\n"
-" -D, --daemonize[=BOOL] Daemonize after startup\n"
-" --fail[=BOOL] Quit when startup fails\n"
-" --high-priority[=BOOL] Try to set high nice level\n"
+" system[=BOOL] Run as system wide instance\n"
+" D, daemonize[=BOOL] Daemonize after startup\n"
+" fail[=BOOL] Quit when startup fails\n"
+" high priority[=BOOL] Try to set high nice level\n"
" (only available as root, when SUID "
"or\n"
" with elevated RLIMIT_NICE)\n"
-" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" realtime[=BOOL] Try to enable realtime scheduling\n"
" (only available as root, when SUID "
"or\n"
" with elevated RLIMIT_RTPRIO)\n"
-" --disallow-module-loading[=BOOL] Disallow module user requested "
+" disallow module loading[=BOOL] Disallow module user requested "
"module\n"
" loading/unloading after startup\n"
-" --disallow-exit[=BOOL] Disallow user requested exit\n"
-" --exit-idle-time=SECS Terminate the daemon when idle and "
+" disallow exit[=BOOL] Disallow user requested exit\n"
+" exit idle time=SECS Terminate the daemon when idle and "
"this\n"
" time passed\n"
-" --module-idle-time=SECS Unload autoloaded modules when idle "
+" module idle time=SECS Unload autoloaded modules when idle "
"and\n"
" this time passed\n"
-" --scache-idle-time=SECS Unload autoloaded samples when idle "
+" scache idle time=SECS Unload autoloaded samples when idle "
"and\n"
" this time passed\n"
-" --log-level[=LEVEL] Increase or set verbosity level\n"
-" -v Increase the verbosity level\n"
-" --log-target={auto,syslog,stderr} Specify the log target\n"
-" --log-meta[=BOOL] Include code location in log "
+" log level[=LEVEL] Increase or set verbosity level\n"
+" v Increase the verbosity level\n"
+" log target={auto,syslog,stderr} Specify the log target\n"
+" log meta[=BOOL] Include code location in log "
"messages\n"
-" --log-time[=BOOL] Include timestamps in log messages\n"
-" --log-backtrace=FRAMES Include a backtrace in log messages\n"
-" -p, --dl-search-path=PATH Set the search path for dynamic "
+" log time[=BOOL] Include timestamps in log messages\n"
+" log backtrace=FRAMES Include a backtrace in log messages\n"
+" p, dl search path=PATH Set the search path for dynamic "
"shared\n"
" objects (plugins)\n"
-" --resample-method=METHOD Use the specified resampling method\n"
-" (See --dump-resample-methods for\n"
+" resample method=METHOD Use the specified resampling method\n"
+" (See dump resample methods for\n"
" possible values)\n"
-" --use-pid-file[=BOOL] Create a PID file\n"
-" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" use pid file[=BOOL] Create a PID file\n"
+" no cpu limit[=BOOL] Do not install CPU load limiter on\n"
" platforms that support it.\n"
-" --disable-shm[=BOOL] Disable shared memory support.\n"
+" disable shm[=BOOL] Disable shared memory support.\n"
"\n"
"STARTUP SCRIPT:\n"
-" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+" L, load=\"MODULE ARGUMENTS\" Load the specified plugin module "
"with\n"
" the specified argument\n"
-" -F, --file=FILENAME Run the specified script\n"
-" -C Open a command line on the running "
+" F, file=FILENAME Run the specified script\n"
+" C Open a command line on the running "
"TTY\n"
" after startup\n"
"\n"
-" -n Don't load default script file\n"
+" n Don't load default script file\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
-msgstr "--daemonize দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " daemonize দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
-msgstr "--fail দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " fail দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
msgstr ""
-"--log-level à§° কাৰণে লগ সà§à¦¤à§°à§° তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤ (হয় সংখà§à¦¯à¦¾ ০..৪ à§° সীমাত বা debug, "
+" log level à§° কাৰণে লগ সà§à¦¤à§°à§° তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤ (হয় সংখà§à¦¯à¦¾ ০..৪ à§° সীমাত বা debug, "
"info, notice, warn, error à§° যিকোনো à¦à¦Ÿà¦¾) ।"
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
-msgstr "--high-priority দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " high priority দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
-msgstr "--realtime দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " realtime দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
-msgstr "--disallow-module-loading দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " disallow module loading দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr "--disallow-exit দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " disallow exit দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
-msgstr "--use-pid-file দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " use pid file দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "অবৈধ লগ লকà§à¦·à§à¦¯: 'syslog', 'stderr' বা 'auto' à§° à¦à¦Ÿà¦¾ বà§à¦¯à§±à¦¹à¦¾à§° কৰক"
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr "--log-time দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " log time দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr "--log-meta দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " log meta দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "resample পদà§à¦§à¦¤à¦¿ '%s' বৈধ নহয় ।"
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
-msgstr "--system দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " system দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
-msgstr "--no-cpu-limit দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " no cpu limit দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
-msgstr "--disable-shm দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
+msgstr " disable shm দà§à¦¬à¦¾à§°à¦¾ বà§à¦²à¦¿à§Ÿà§‡à¦¨ তৰà§à¦• পà§à§°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
#: ../src/daemon/dumpmodules.c:60
#, c-format
@@ -764,77 +672,87 @@ msgstr "বà§à¦¯à§±à¦¹à¦¾à§° পদà§à¦§à¦¤à¦¿: %s\n"
msgid "Load Once: %s\n"
msgstr "à¦à¦¬à¦¾à§° তà§à¦²à¦¿ লোৱা হ'ব: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "অবচিত কৰাৰ সতৰà§à¦•বাৰà§à¦¤à¦¾: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "পাথ: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] লগ লকà§à¦·à§à¦¯ '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] লগৰ সà§à¦¤à§° '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] resample পদà§à¦§à¦¤à¦¿ '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] rlimit '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] à¦à¦‡ সà§à¦¥à¦¾à¦ªà¦¤à§à¦¯à¦¤ rlimit সমৰà§à¦¥à¦¿à¦¤ নহয় ।"
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] চানেকিৰ বিনà§à¦¯à¦¾à¦¸ '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] চানেকিৰ মাতà§à§°à¦¾ '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] চানেকিৰ চেনেল '%s' বৈধ নহয়"
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] চেনেল মেপ '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] অংশৰ সংখà§à¦¯à¦¾ '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] অংশৰ মাপ '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] nice সà§à¦¤à§° '%s' বৈধ নহয় ।"
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] চানেকিৰ মাতà§à§°à¦¾ '%s' বৈধ নহয় ।"
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "বিনà§à¦¯à¦¾à¦¸ নথিপতà§à§° খà§à¦²à¦¿à¦¬à¦²à§ˆ বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -842,18 +760,14 @@ msgstr ""
"নিৰà§à¦§à¦¾à§°à¦¿à¦¤ অবিকলà§à¦ªà¦¿à¦¤ চেনেল মেপত নিৰà§à¦§à¦¾à§°à¦¿à¦¤ অবিকলà§à¦ªà¦¿à¦¤ চেনেলৰ সংখà§à¦¯à¦¾à¦¤à¦•ে বেলেগ সংখà§à¦¯à¦• "
"চেনেল আছে ।"
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### চিহà§à¦¨à¦¿à¦¤ বিনà§à¦¯à¦¾à¦¸ নথিপতà§à§°à§° পৰা পà§à¦¾ হ'ব: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "root-à§° অধিকাৰ বৰà§à¦œà¦¨ কৰা হৈছে ।"
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "CAP_SYS_NICE লৈ কাৰà§à¦¯à§à¦¯à¦•à§à¦·à¦®à¦¤à¦¾ সফলভাবে সীমিত কৰা হ'ল ।"
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "অধিকাৰ বৰà§à¦œà¦¨ কৰা হচà§à¦›à§‡à¥¤"
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -863,255 +777,237 @@ msgstr "PulseAudio শবà§à¦¦ বà§à¦¯à§±à¦¸à§à¦¥à¦¾"
msgid "Start the PulseAudio Sound System"
msgstr "PulseAudio শবà§à¦¦ বà§à¦¯à§±à¦¸à§à¦¥à¦¾ আৰমà§à¦­ কৰা হ'ব"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "PulseAudio ডেমনৰ কাৰণে High-priority scheduling (ঋণাতà§à¦®à¦• Unix nice সà§à¦¤à§°)"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio ডেমনৰ কাৰণে Real-time scheduling"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr "পà§à§°à¦£à¦¾à¦²à§€à§° নীতিয়ে PulseAudio ক high-priority scheduling পাবলৈ নিদিয়ে ।"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr "পà§à§°à¦£à¦¾à¦²à§€à§° নীতিয়ে PulseAudio ক real-time scheduling পাবলৈ নিদিয়ে ।"
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "মোনো"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "সনà§à¦®à§à¦–ত কেনà§à¦¦à§à§°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "সনà§à¦®à§à¦–ত কেনà§à¦¦à§à§°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "সনà§à¦®à§à¦–ত বাওà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "পিছত কেনà§à¦¦à§à§°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "পিছত বাওà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "পিছত সোà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Low Frequency Emmiter"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
-msgstr "সনà§à¦®à§à¦–ত কেনà§à¦¦à§à§°à§°-বাওà¦à¦«à¦¾à¦²à§‡"
+msgstr "সনà§à¦®à§à¦–ত কেনà§à¦¦à§à§°à§° বাওà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
-msgstr "সনà§à¦®à§à¦–ত কেনà§à¦¦à§à§°à§°-সোà¦à¦«à¦¾à¦²à§‡"
+msgstr "সনà§à¦®à§à¦–ত কেনà§à¦¦à§à§°à§° সোà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "কাষত বাওà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "কাষত সোà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ০"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ০"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§§"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§©"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ৪"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ৪"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ৬"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§­"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§®"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ৯"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ১০"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§§à§§"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ১২"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§§à§©"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ১৪"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§§à§«"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ১৬"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§§à§­"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§§à§®"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ১৯"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২০"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২১"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২২"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২৩"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২৪"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২৫"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২৬"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২৭"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২৮"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ২৯"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ ৩০"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "অ'কà§à¦¸à¦¿à¦²à§‡à§°à¦¿ à§©à§§"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "ওপৰত কেনà§à¦¦à§à§°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "ওপৰত সনà§à¦®à§à¦–ত কেনà§à¦¦à§à§°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "ওপৰত সনà§à¦®à§à¦–ত বাওà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "ওপৰত সনà§à¦®à§à¦–ত বাওà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "ওপৰত পিছত কেনà§à¦¦à§à§°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "ওপৰত পিছত বাওà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "ওপৰত পিছত সোà¦à¦«à¦¾à¦²à§‡"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(অবৈধ)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
-msgstr "সà§à¦Ÿà¦¿à§°à¦¿à¦“"
+msgstr "সà§à¦Ÿà¦¿à§°à¦¿à¦…'"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "ছাৰাউণà§à¦¡ ৪.০"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "ছাৰাউণà§à¦¡ ৪.à§§"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "ছাৰাউণà§à¦¡ à§«.০"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "ছাৰাউণà§à¦¡ à§«.à§§"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "ছাৰাউণà§à¦¡ à§­.à§§"
@@ -1153,7 +1049,7 @@ msgstr "সময়সীমা"
#: ../src/pulse/error.c:52
msgid "No authorization key"
-msgstr "কোনো অনà§à¦®à§‹à¦¦à¦¨à§°-কি নাই"
+msgstr "কোনো অনà§à¦®à§‹à¦¦à¦¨à§° কি নাই"
#: ../src/pulse/error.c:53
msgid "Internal error"
@@ -1215,27 +1111,35 @@ msgstr "অনà§à¦ªà¦¸à§à¦¥à¦¿à¦¤ বাসà§à¦¤à¦¬à¦¾à§Ÿà¦¨"
msgid "Client forked"
msgstr "গà§à§°à¦¾à¦¹à¦• ফৰà§à¦• কৰা হৈছে"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "নিবেশ/নিৰà§à¦—ম তà§à§°à§à¦Ÿà¦¿"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "যনà§à¦¤à§à§° বা সমà§à¦ªà¦¦ বà§à¦¯à¦¸à§à¦¤"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1248,197 +1152,191 @@ msgstr "XOpenDisplay() বà§à¦¯à§°à§à¦¥"
msgid "Failed to parse cookie data"
msgstr "কà§à¦•িৰ তথà§à¦¯ বিশà§à¦²à§‡à¦·à¦£ কৰিবলৈ বà§à¦¯à§°à§à¦¥"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "বিনà§à¦¯à¦¾à¦¸ নথিপতà§à§° '%s' খà§à¦²à¦¿à¦¬à¦²à§ˆ বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "কোনো কà§à¦•ি তà§à¦²à¦¿ লোৱা নহয় । কà§à¦•ি নোহোৱাকে সংযোগৰ পà§à§°à¦šà§‡à¦·à§à¦Ÿà¦¾ কৰা হৈছে ।"
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
-msgstr "অজানা à¦à¦•à§à¦¸à¦Ÿà§‡à¦¨à¦¶à¦¨ '%s'-à§° বাবে বাৰà§à¦¤à¦¾ পà§à§°à¦¾à¦ªà§à¦¤ হৈছে"
+msgstr "অজানা à¦à¦•à§à¦¸à¦Ÿà§‡à¦¨à¦¶à¦¨ '%s' à§° বাবে বাৰà§à¦¤à¦¾ পà§à§°à¦¾à¦ªà§à¦¤ হৈছে"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "সà§à¦Ÿà§à§°à¦¿à¦® ডà§à§°à§‡à¦‡à¦¨ (অৰà§à¦¥à¦¾à§Ž ফাà¦à¦•া) কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() বà§à¦¯à§°à§à¦¥: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "পà§à¦²à§‡ বà§à¦¯à¦¾à¦• সà§à¦Ÿà§à§°à¦¿à¦® ফাà¦à¦•া কৰা হয়েছে।"
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "সফলতাৰে সà§à¦Ÿà§à§°à¦¿à¦® নিৰà§à¦®à¦¿à¦¤ হৈছে ।\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "সাৰà§à¦­à¦¾à§°à§‡à§° সাথে সà§à¦¥à¦¾à¦ªà¦¿à¦¤ সংযোগ ফাà¦à¦•া কৰা হচà§à¦›à§‡à¥¤"
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Buffer metrics: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "চানেকি spec '%s', চেনেল মেপ '%s'পà§à§°à§Ÿà§‹à¦— কৰা হৈছে\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "যনà§à¦¤à§à§° %s-à§° সৈতে সংযোগ কৰা হৈছে (%u, %ssuspended) ।\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "সাফলà§à¦¯à§‡à§° সাথে সà§à¦Ÿà§à§°à¦¿à¦® নিৰà§à¦®à¦¿à¦¤ হয়েছে।"
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "ষà§à¦Ÿà§à§°à¦¿à¦® সংকà§à§°à¦¾à¦¨à§à¦¤ তà§à§°à§à¦Ÿà¦¿: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "সà§à¦Ÿà§à§°à¦¿à¦® যনà§à¦¤à§à§° সà§à¦¥à¦—িত কৰা হৈছে । %s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "বাফাৰেৰ মাপ: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "সà§à¦Ÿà§à§°à¦¿à¦® যনà§à¦¤à§à§° পà§à¦¨à§°à¦¾à§°à¦®à§à¦­ কৰা হৈছে । %s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "বাফাৰেৰ মাপ: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "ষà§à¦Ÿà§à§°à¦¿à¦® underrun: %s\n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à§° spec '%s', ও চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª '%s' বà§à¦¯à§±à¦¹à¦¾à§° কৰা হচà§à¦›à§‡à¥¤"
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "ষà§à¦Ÿà§à§°à¦¿à¦® overrun: %s\n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "যনà§à¦¤à§à§° %s à§° সাথে সংযোগ কৰা হয়েছে (%u, %ssuspended)।"
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "সà§à¦Ÿà§à§°à¦¿à¦® আৰমà§à¦­ কৰা হৈছে । %s \n"
+msgid "Stream error: %s"
+msgstr "ষà§à¦Ÿà§à§°à¦¿à¦® সংকà§à§°à¦¾à¦¨à§à¦¤ তà§à§°à§à¦Ÿà¦¿: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "%s যনà§à¦¤à§à§°à¦²à§ˆ সà§à¦Ÿà§à§°à¦¿à¦® সà§à¦¥à¦¾à¦¨à¦¾à¦¨à§à¦¤à§° কৰা হৈছে (%u, %ssuspended) ।%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "not "
+msgid "Stream device suspended.%s"
+msgstr "সà§à¦Ÿà§à§°à¦¿à¦® যনà§à¦¤à§à§° সà§à¦¥à¦—িত কৰা হয়েছে। %s"
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "সà§à¦Ÿà§à§°à¦¿à¦® পà§à§°à¦¶à¦®à¦•à§° গà§à¦£ পৰিবৰà§à¦¤à¦¿à¦¤ হৈছে । %s \n"
+msgid "Stream device resumed.%s"
+msgstr "সà§à¦Ÿà§à§°à¦¿à¦® যনà§à¦¤à§à§° পà§à¦¨à§°à¦¾à§°à¦®à§à¦­ কৰা হয়েছে। %s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "সংযোগ সà§à¦¥à¦¾à¦ªà¦¿à¦¤ হৈছে ।%s \n"
+msgid "Stream underrun.%s"
+msgstr "ধীৰ গতিৰ সà§à¦Ÿà§à§°à¦¿à¦®.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Stream overrun.%s"
+msgstr "সà§à¦Ÿà§à§°à¦¿à¦® মাতà§à§°à¦¾ অতিকà§à§°à¦® কৰিছে।%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Stream started.%s"
+msgstr "সà§à¦Ÿà§à§°à¦¿à¦® আৰমà§à¦­ কৰা হয়েছে। %s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "%s যনà§à¦¤à§à§°à§‡ সà§à¦Ÿà§à§°à¦¿à¦® সà§à¦¥à¦¾à¦¨à¦¾à¦¨à§à¦¤à§° কৰা হয়েছে (%u, %ssuspended)।%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "<b>সংযোগৰ মোড</b>: %s<br>\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "not "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "সà§à¦Ÿà§à§°à¦¿à¦® drain কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "সà§à¦Ÿà§à§°à¦¿à¦® বাফাৰেৰ à¦à¦Ÿà§à§°à¦¿à¦¬à¦¿à¦‰à¦Ÿ পৰিবৰà§à¦¤à¦¿à¦¤ হয়েছে। %s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "পà§à¦²à§‡à¦¬à§‡à¦• সà§à¦Ÿà§à§°à¦¿à¦®à¦• drain কৰা হ'ল ।\n"
+msgid "Connection established.%s"
+msgstr "সংযোগ সà§à¦¥à¦¾à¦ªà¦¿à¦¤ হয়েছে।%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "সেৱকৰ সৈতে সংযোগ Drain কৰা হৈছে ।\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF পোৱা গ'ল ।\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Connection failure: %s"
+msgstr "সংযোগ বিফল: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() বà§à¦¯à§°à§à¦¥: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "ফাইলেৰ সমাপà§à¦¤à¦¿ সনাকà§à¦¤ হয়েছে।"
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "চিগà§à¦¨à§‡à¦² পোৱা গ'ল, পà§à§°à¦¸à§à¦¥à¦¾à¦¨ কৰা হৈছে ।\n"
+msgid "write() failed: %s"
+msgstr "write() বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "latency পাবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "সিগনà§à¦¯à¦¾à¦² পà§à§°à¦¾à¦ªà§à¦¤ হয়েছে, পà§à§°à¦¸à§à¦¥à¦¾à¦¨ কৰা হ'ব।"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "সময়: %0.3f sec; Latency: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "লেটেনà§à¦¸à¦¿à§° পৰিমাণ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "সময়: %0.3f ছেকেণà§à¦¡; লেটেনà§à¦¸à¦¿: %0.0f usec ।"
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() বà§à¦¯à§°à§à¦¥: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1464,8 +1362,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1488,57 +1388,73 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
+" h, help Show this help\n"
+" version Show version\n"
"\n"
-" -r, --record Create a connection for recording\n"
-" -p, --playback Create a connection for playback\n"
+" r, record Create a connection for recording\n"
+" p, playback Create a connection for playback\n"
"\n"
-" -v, --verbose Enable verbose operations\n"
+" v, verbose Enable verbose operations\n"
"\n"
-" -s, --server=SERVER The name of the server to connect "
+" s, server=SERVER The name of the server to connect "
"to\n"
-" -d, --device=DEVICE The name of the sink/source to "
+" d, device=DEVICE The name of the sink/source to "
"connect to\n"
-" -n, --client-name=NAME How to call this client on the "
+" n, client name=NAME How to call this client on the "
"server\n"
-" --stream-name=NAME How to call this stream on the "
+" stream name=NAME How to call this stream on the "
"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
+" volume=VOLUME Specify the initial (linear) volume "
"in range 0...65536\n"
-" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+" rate=SAMPLERATE The sample rate in Hz (defaults to "
"44100)\n"
-" --format=SAMPLEFORMAT The sample type, one of s16le, "
+" format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
-" --channels=CHANNELS The number of channels, 1 for mono, "
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24 32le, s24 32be (defaults to "
+"s16ne)\n"
+" channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
-" --channel-map=CHANNELMAP Channel map to use instead of the "
+" channel map=CHANNELMAP Channel map to use instead of the "
"default\n"
-" --fix-format Take the sample format from the sink "
+" fix format Take the sample format from the sink "
"the stream is\n"
" being connected to.\n"
-" --fix-rate Take the sampling rate from the sink "
+" fix rate Take the sampling rate from the sink "
"the stream is\n"
" being connected to.\n"
-" --fix-channels Take the number of channels and the "
+" fix channels Take the number of channels and the "
"channel map\n"
" from the sink the stream is being "
"connected to.\n"
-" --no-remix Don't upmix or downmix channels.\n"
-" --no-remap Map channels by index instead of "
+" no remix Don't upmix or downmix channels.\n"
+" no remap Map channels by index instead of "
"name.\n"
-" --latency=BYTES Request the specified latency in "
+" latency=BYTES Request the specified latency in "
"bytes.\n"
-" --process-time=BYTES Request the specified process time "
+" process time=BYTES Request the specified process time "
"per request in bytes.\n"
+" property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" raw Record/play raw PCM data.\n"
+" file format=FFORMAT Record/play formatted PCM data.\n"
+" list file formats List available file formats.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1549,129 +1465,173 @@ msgstr ""
"libpulse à§° সৈতে সঙà§à¦•লন কৰা হৈছে %s\n"
"libpulse à§° সৈতে যà§à¦•à§à¦¤ %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "চেনেল মেপ '%s' বৈধ নহয়\n"
+msgid "Invalid client name '%s'"
+msgstr "কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿà§‡à§° নাম '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "অবৈধ latency নিৰà§à¦§à¦¾à§°à¦£ '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "সà§à¦Ÿà§à§°à¦¿à¦®à§‡à§° নাম '%s' বৈধ নয়।"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "অবৈধ পà§à§°à¦•à§à§°à¦¿à§Ÿà¦¾à§° সময়ৰ নিৰà§à¦§à¦¾à§°à¦£ '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "অবৈধ চানেকি নিৰà§à¦§à¦¾à§°à¦¿à¦¤\n"
+msgid "Invalid latency specification '%s'"
+msgstr "লেটেনà§à¦¸à¦¿à§° জনà§à¦¯ নিৰà§à¦§à¦¾à§°à¦¿à¦¤ বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "চেনেল মেপ আৰৠনথিপতà§à§° অমিল ।\n"
+msgid "Invalid process time specification '%s'"
+msgstr "পà§à§°à¦¸à§‡à¦¸à§‡à§° সময়েৰ বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "à¦à¦Ÿà¦¾ %s সà§à¦Ÿà§à§°à¦¿à¦® চানেকি নিৰà§à¦§à¦¾à§°à¦£ '%s' à§° সৈতে খোলা হৈছে ।\n"
+msgid "Invalid property '%s'"
+msgstr "বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়।"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "ৰেকৰà§à¦¡ কৰা হৈছে"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "ফাইলেৰ অজানা বিনà§à¦¯à¦¾à¦¸ %s।"
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "পà§à¦²à§‡-বেক"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "অবৈধ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² নিৰà§à¦§à¦¾à§°à¦¿à¦¤"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "অতà§à¦¯à¦¾à¦§à¦¿à¦• তৰà§à¦• ।\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "অতà§à¦¯à¦¾à¦§à¦¿à¦• আৰà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿà¥¤"
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() বà§à¦¯à§°à§à¦¥ ।\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à§° মান নিৰà§à¦§à¦¾à§°à¦£à§‡à§° ফাইল নিৰà§à¦®à¦¾à¦£ কৰতে বà§à¦¯à§°à§à¦¥"
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() বà§à¦¯à§°à§à¦¥ ।\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "শবà§à¦¦à§‡à§° ফাইল খà§à¦²à¦¤à§‡ বà§à¦¯à§°à§à¦¥à¥¤"
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() বà§à¦¯à§°à§à¦¥ ।\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"সতৰà§à¦•বাৰà§à¦¤à¦¾: চিহà§à¦¨à¦¿à¦¤ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² নিৰà§à¦§à¦¾à§°à¦£à§‡à§° ফাইলটিৰ তথà§à¦¯, à¦à¦‡ ফাইলেৰৰ পৰা উপলবà§à¦§ তথà§à¦¯ "
+"দà§à¦¬à¦¾à§°à¦¾ পà§à§°à¦¤à¦¿à¦¸à§à¦¥à¦¾à¦ªà¦¿à¦¤ হ'ব।"
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() বà§à¦¯à§°à§à¦¥: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ফাইলৰ পৰা সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "সতৰà§à¦•বাৰà§à¦¤à¦¾: ফাইলৰ পৰা চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à§° মà§à¦¯à¦¾à¦ª নিৰà§à¦§à¦¾à§°à¦£ কৰতে বà§à¦¯à§°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à§° মà§à¦¯à¦¾à¦ª ও সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à§° নিৰà§à¦§à¦¾à§°à¦¿à¦¤ মানে গৰমিল"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "সতৰà§à¦•বাৰà§à¦¤à¦¾: ফাইলেত চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à§° মà§à¦¯à¦¾à¦ª লিখতে বà§à¦¯à§°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() বà§à¦¯à§°à§à¦¥ ।\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"à¦à¦Ÿà¦¾ %s সà§à¦Ÿà§à§°à¦¿à¦® খোলা হচà§à¦›à§‡à¥¤ à¦à¦Ÿà¦¿à§° জনà§à¦¯ '%s' à§° সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à§° নিৰà§à¦§à¦¾à§°à¦¿à¦¤ মান ও '%s' "
+"চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à§° মà§à¦¯à¦¾à¦ª পà§à§°à§Ÿà§‹à¦— কৰা হ'ব।"
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "ৰেকৰà§à¦¡ কৰা হৈছে"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "পà§à¦²à§‡ বেক"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() বà§à¦¯à§°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() বà§à¦¯à§°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() বà§à¦¯à§°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() বà§à¦¯à§°à§à¦¥ ।\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() বà§à¦¯à§°à§à¦¥: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() বà§à¦¯à§°à§à¦¥à¥¤"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() বà§à¦¯à§°à§à¦¥à¥¤"
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "সà§à¦¥à¦—িত কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "পà§à¦¨à§°à¦¾à§°à¦®à§à¦­ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "সতৰà§à¦•বাৰà§à¦¤à¦¾: ধà§à¦¬à¦¨à¦¿ সেৱক সà§à¦¥à¦¾à¦¨à§€à§Ÿ নহয়, সà§à¦¥à¦—িত কৰা নহয় ।\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "<b>সংযোগৰ মোড</b>: %s<br>\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT পà§à§°à¦¾à¦ªà§à¦¤ হৈছে, পà§à§°à¦¸à§à¦¥à¦¾à¦¨ কৰা হৈছে ।\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "সতৰà§à¦•বাৰà§à¦¤à¦¾: চিগà§à¦¨à§‡à¦² %u দà§à¦¬à¦¾à§°à¦¾ চাইলà§à¦¡ পà§à§°à¦•à§à§°à¦¿à§Ÿà¦¾ বনà§à¦§ কৰা হৈছে\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1684,13 +1644,13 @@ msgid ""
msgstr ""
"%s [options] ... \n"
"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-" -s, --server=SERVER The name of the server to connect "
+" h, help Show this help\n"
+" version Show version\n"
+" s, server=SERVER The name of the server to connect "
"to\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1701,35 +1661,61 @@ msgstr ""
"libpulse à§° সৈতে সঙà§à¦•লন কৰা হৈছে %s\n"
"libpulse à§° সৈতে যà§à¦•à§à¦¤ %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "পৰিসংখà§à¦¯à¦¾à¦¨ পাবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() বà§à¦¯à§°à§à¦¥ ।\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() বà§à¦¯à§°à§à¦¥ ।\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() বà§à¦¯à§°à§à¦¥ ।\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "পৰিসংখà§à¦¯à¦¾à¦¨ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "বৰà§à¦¤à§à¦¤à¦®à¦¾à¦¨à§‡ বà§à¦¯à§±à¦¹à§ƒà¦¤: %u blocks containing %s bytes total.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "সমà§à¦ªà§‚à§°à§à¦£ জীৱনকালত বিতৰণ কৰা: %u blocks containing %s bytes total.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "চানেকি কেশà§à¦¬à§° মাপ: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "সেৱক সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "সাৰà§à¦­à¦¾à§° সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1737,7 +1723,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"বà§à¦¯à§±à¦¹à¦¾à§°à¦•à§°à§à¦¤à¦¾à§° নাম: %s\n"
"গৃহসà§à¦¥à§° নাম: %s\n"
@@ -1749,12 +1735,12 @@ msgstr ""
"অবিকলà§à¦ªà¦¿à¦¤ উৎস: %s\n"
"কà§à¦•ি: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "চিঙà§à¦• সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "sink সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1793,12 +1779,22 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tপোৰà§à¦Ÿ:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tসকà§à§°à¦¿à§Ÿ পোৰà§à¦Ÿ: %s\n"
+
+#: ../src/utils/pactl.c:310
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "উৎস সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get source information: %s"
+msgstr "উৎস সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1837,20 +1833,20 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "মডিউল সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "মডিউল সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1867,12 +1863,12 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "গà§à§°à¦¾à¦¹à¦• সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿ সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1887,12 +1883,12 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "কাৰà§à¦¡ সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "কাৰà§à¦¡ সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1909,22 +1905,22 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tপাৰà§à¦¶à§à¦¬à§°à§‚প:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tসকà§à§°à¦¿à§Ÿ পাৰà§à¦¶à§à¦¬à§°à§‚প: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "চিঙà§à¦• নিবেশ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "sink নিবেশ সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1961,12 +1957,12 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "উৎস আউটপà§à¦Ÿ সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "উৎস নিৰà§à¦—ম সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1995,12 +1991,12 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "চানেকি সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰিবলৈ বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à§°à¦¾à¦ªà§à¦¤ কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2031,23 +2027,80 @@ msgstr ""
"\tগà§à¦£:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "বà§à¦¯à§°à§à¦¥à¦¤à¦¾: %s\n"
+msgid "Failure: %s"
+msgstr "বà§à¦¯à§°à§à¦¥à¦¤à¦¾: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "চানেকি আপল'ড বà§à¦¯à§°à§à¦¥: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² আপলোড কৰতে বà§à¦¯à§°à§à¦¥: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "নথিপতà§à§°à§° অসময়ত হোৱা সমাপà§à¦¤à¦¿\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "সমà§à¦ªà§‚à§°à§à¦£ হওয়াৰ পূৰà§à¦¬à§‡ ফাইল সমাপà§à¦¤ হয়েছে"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "সেৱক বৈধ নহয়"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT পà§à§°à¦¾à¦ªà§à¦¤ হয়েছে, পà§à§°à¦¸à§à¦¥à¦¾à¦¨ কৰা হয়েছে।"
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2055,13 +2108,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2074,26 +2136,34 @@ msgstr ""
"%s [options] stat\n"
"%s [options] list\n"
"%s [options] exit\n"
-"%s [options] upload-sample FILENAME [NAME]\n"
-"%s [options] play-sample NAME [SINK]\n"
-"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
-"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] upload sample FILENAME [NAME]\n"
+"%s [options] play sample NAME [SINK]\n"
+"%s [options] remove sample NAME\n"
+"%s [options] move sink input SINKINPUT SINK\n"
+"%s [options] move source output SOURCEOUTPUT SOURCE\n"
+"%s [options] load module NAME [ARGS ...]\n"
+"%s [options] unload module MODULE\n"
+"%s [options] suspend sink SINK 1|0\n"
+"%s [options] suspend source SOURCE 1|0\n"
+"%s [options] set card profile CARD PROFILE\n"
+"%s [options] set sink port SINK PORT\n"
+"%s [options] set source port SOURCE PORT\n"
+"%s [options] set sink volume SINK VOLUME\n"
+"%s [options] set source volume SOURCE VOLUME\n"
+"%s [options] set sink input volume SINKINPUT VOLUME\n"
+"%s [options] set sink mute SINK 1|0\n"
+"%s [options] set source mute SOURCE 1|0\n"
+"%s [options] set sink input mute SINKINPUT 1|0\n"
"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
+" h, help Show this help\n"
+" version Show version\n"
"\n"
-" -s, --server=SERVER The name of the server to connect "
+" s, server=SERVER The name of the server to connect "
"to\n"
-" -n, --client-name=NAME How to call this client on the "
+" n, client name=NAME How to call this client on the "
"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2102,76 +2172,108 @@ msgid ""
msgstr ""
"pactl %s\n"
"libpulseà§° সৈতে সঙà§à¦•লন কৰা %s\n"
-"libpulse-à§° সৈতে যà§à¦•à§à¦¤ %s\n"
+"libpulse à§° সৈতে যà§à¦•à§à¦¤ %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "তà§à¦²à¦¿ লোৱাৰ উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ অনà§à¦—à§à§°à¦¹ কৰে à¦à¦•টি চানেকি নথিপতà§à§° উলà§à¦²à§‡à¦– কৰà§à¦¨\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "লোড কৰাৰ উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ অনà§à¦—à§à§°à¦¹ কৰি à¦à¦Ÿà¦¾ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– কৰà§à¦¨"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "শবà§à¦¦à§‡à§° নথিপতà§à§° খà§à¦²à¦¿à¦¬à¦²à§ˆ বà§à¦¯à§°à§à¦¥ ।\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "শবà§à¦¦à§‡à§° ফাইল খà§à¦²à¦¤à§‡ বà§à¦¯à§°à§à¦¥à¥¤"
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "বাজানোৰ উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ à¦à¦•টি চানেকি নথিপতà§à§° উলà§à¦²à§‡à¦– কৰা আৱশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "সতৰà§à¦•বাৰà§à¦¤à¦¾: ফাইলৰ পৰা সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à§° নিৰà§à¦§à¦¾à§°à¦¿à¦¤ মাপ নিৰà§à¦®à¦¾à¦£ কৰতে বà§à¦¯à§°à§à¦¥à¥¤"
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "আà¦à¦¤à§°à¦¾à¦¬à¦²à§ˆ à¦à¦Ÿà¦¾ চানেকি নাম দিব লাগিব \n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "বাজানোৰ উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ à¦à¦Ÿà¦¾ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "চিঙà§à¦• ইনপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ আৰৠà¦à¦Ÿà¦¾ চিঙà§à¦• নিৰà§à¦§à¦¾à§°à¦£ কৰা আৱশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "অপসাৰণেৰ উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ à¦à¦Ÿà¦¾ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "উৎস আউটপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ আৰৠà¦à¦•টি উৎস নিৰà§à¦§à¦¾à§°à¦£ কৰা আৱশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "সিংক নিবেশ ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ সিংক নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "মডিউলৰ নাম আৰৠতৰà§à¦• নিৰà§à¦§à¦¾à§°à¦£ কৰা আৱশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "সোৰà§à¦¸ নিৰà§à¦—ম ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ সোৰà§à¦¸ নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "মডিউল ইনà§à¦¡à§‡à¦•à§à¦¸ নিৰà§à¦§à¦¾à§°à¦£ কৰা আৱশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "মডিউলেৰ নাম ও আৰà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•।"
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "মডিউল ইনà§à¦¡à§‡à¦•à§à¦¸ নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr "à¦à¦•াধিক চিঙà§à¦• নিৰà§à¦§à¦¾à§°à¦£ কৰা যাবে না । বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিৰà§à¦§à¦¾à§°à¦£ কৰা আৱশà§à¦¯à¦• ।\n"
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr "à¦à¦•াধিক সিংক নিৰà§à¦§à¦¾à§°à¦£ কৰা যাবে না। বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•।"
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr "à¦à¦•াধিক উৎস নিৰà§à¦§à¦¾à§°à¦£ কৰা যাবে না । বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিৰà§à¦§à¦¾à§°à¦£ কৰা আৱশà§à¦¯à¦• ।\n"
+"value."
+msgstr "à¦à¦•াধিক সোৰà§à¦¸ নিৰà§à¦§à¦¾à§°à¦£ কৰা যাবে না। বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•।"
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "কাৰà§à¦¡à§‡à§° নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ আৰৠà¦à¦•টি পাৰà§à¦¶à§à¦¬à§°à§‚পৰ নাম উলà§à¦²à§‡à¦– কৰা আৱশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "কাৰà§à¦¡à§‡à§° নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ পà§à§°à§‹à¦«à¦¾à¦‡à¦²à§‡à§° নাম উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "সঞà§à¦šà¦¾à¦²à¦¨à§° বাবে আদেশ নিৰà§à¦§à¦¾à§°à¦¿à¦¤ নহয় ।\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "sink à§° নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ পোৰà§à¦Ÿà§‡à§° নাম উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() বà§à¦¯à§°à§à¦¥: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "উৎসেৰ নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ পোৰà§à¦Ÿà§‡ নাম উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "sink à§° নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ পোৰà§à¦Ÿà§‡à§° নাম উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "অবৈধ শবà§à¦¦à§‡à§° মাতà§à§°à¦¾ নিৰà§à¦§à¦¾à§°à¦¿à¦¤"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "উৎসেৰ নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ শবà§à¦¦à§‡à§° মাতà§à§°à¦¾ উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "সিংক নিবেশ ইনà§à¦¡à§‡à¦•à§à¦¸ ও শবà§à¦¦à§‡à§° মাতà§à§°à¦¾ নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "সিংক নিবেশ ইনà§à¦¡à§‡à¦•à§à¦¸ বৈধ নয়"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "sink à§° নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦Ÿà¦¾ নিঃশবà§à¦¦à¦¤à¦¾à§° বà§à¦²à¦¿à§Ÿà¦¾à¦¨ উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "উৎসেৰ নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও নিঃশবà§à¦¦à¦¤à¦¾à§° বà§à¦²à¦¿à§Ÿà¦¾à¦¨ উলà§à¦²à§‡à¦– কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "সিংক নিবেশ ইনà§à¦¡à§‡à¦•à§à¦¸ ও নিঃশবà§à¦¦à¦¤à¦¾à§° বà§à¦²à¦¿à§Ÿà¦¾à¦¨ নিৰà§à¦§à¦¾à§°à¦£ কৰা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "অবৈধ সিংক নিবেশ ইনà§à¦¡à§‡à¦•à§à¦¸ নিৰà§à¦§à¦¾à§°à¦¿à¦¤"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "কোনো বৈধ কমানà§à¦¡ নিৰà§à¦§à¦¾à§°à¦¿à¦¤ হয়নি।"
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2184,18 +2286,18 @@ msgid ""
"variables and cookie file.\n"
" -r Remove PulseAudio data from X11 display\n"
msgstr ""
-"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"%s [ D display] [ S server] [ O sink] [ I source] [ c file] [ d| e| i| r]\n"
"\n"
-" -d Show current PulseAudio data attached to X11 display (default)\n"
-" -e Export local PulseAudio data to X11 display\n"
-" -i Import PulseAudio data from X11 display to local environment "
+" d Show current PulseAudio data attached to X11 display (default)\n"
+" e Export local PulseAudio data to X11 display\n"
+" i Import PulseAudio data from X11 display to local environment "
"variables and cookie file.\n"
-" -r Remove PulseAudio data from X11 display\n"
+" r Remove PulseAudio data from X11 display\n"
#: ../src/utils/pax11publish.c:94
#, c-format
msgid "Failed to parse command line.\n"
-msgstr "আদেশ-শাৰী বিশà§à¦²à§‡à¦·à¦£ কৰিবলৈ বà§à¦¯à§°à§à¦¥ ।\n"
+msgstr "আদেশ শাৰী বিশà§à¦²à§‡à¦·à¦£ কৰিবলৈ বà§à¦¯à§°à§à¦¥ ।\n"
#: ../src/utils/pax11publish.c:108
#, c-format
@@ -2252,129 +2354,48 @@ msgstr "কà§à¦•ি সংকà§à§°à¦¾à¦¨à§à¦¤ তথà§à¦¯ তà§à¦²à¦¿à¦¬à¦²
msgid "Not yet implemented.\n"
msgstr "à¦à¦¤à¦¿à§Ÿà¦¾à¦“ বাসà§à¦¤à¦¬à¦¾à§Ÿà¦¿à¦¤ নহয় ।\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "PulseAudio ডেমন চলছে না বা সেশানৰ ডেমন ৰূপে চলছে না।"
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio ডেমন kill কৰিবলৈ বà§à¦¯à§°à§à¦¥ ।"
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "ডেমনৰ পৰা কোনো পà§à§°à¦¤à¦¿à¦•à§à§°à¦¿à§Ÿà¦¾ পোৱা নাযায় ।"
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "সফলতাৰে সà§à¦Ÿà§à§°à¦¿à¦® নিৰà§à¦®à¦¿à¦¤ হৈছে\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "সà§à¦Ÿà§à§°à¦¿à¦®à§° তà§à§°à§à¦Ÿà¦¿: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "সংযোগ সà§à¦¥à¦¾à¦ªà¦¿à¦¤ ।\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"libpulse à§° সৈতে সঙà§à¦•লন কৰা হৈছে %s\n"
-"libpulse à§° সৈতে যà§à¦•à§à¦¤ %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "অবৈধ চেনেল মেপ\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "'%s' নথিপতà§à§° খà§à¦²à¦¿à¦¬à¦²à§ˆ বà§à¦¯à§°à§à¦¥\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "চেনেল মেপ আৰৠনথিপতà§à§° অমিল ।\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "চানেকি spec '%s' পà§à§°à§Ÿà§‹à¦— কৰা হৈছে\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "autospawn লক পà§à§°à§Ÿà§‹à¦— কৰিবলৈ বà§à¦¯à§°à§à¦¥ ।"
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2387,10 +2408,10 @@ msgstr ""
"ALSA ই আমাক যনà§à¦¤à§à§°à§° পৰা নতà§à¦¨ তথà§à¦¯ লিখিবলৈ উথালে, কিনà§à¦¤à§ à¦à¦•à§‹ লিখিবলৈ নাছিল!\n"
"অতি সমà§à¦­à§± à¦à¦‡à¦Ÿà§‹ ALSA চালক '%s' à§° à¦à¦Ÿà¦¾ বাগ । অনà§à¦—à§à§°à¦¹ কৰি à¦à¦‡ সমসà§à¦¯à¦¾ ALSA বিকাশকক "
"জনাওক ।\n"
-"POLLOUT নিৰà§à¦§à¦¾à§°à¦¿à¦¤ হোৱাৰি পিছতো আমি উথিলো -- কিনà§à¦¤à§ তাৰ পিছৰ snd_pcm_avail() ঠ০ "
+"POLLOUT নিৰà§à¦§à¦¾à§°à¦¿à¦¤ হোৱাৰি পিছতো আমি উথিলো কিনà§à¦¤à§ তাৰ পিছৰ snd_pcm_avail() ঠ০ "
"দিলে বা অনà§à¦¯ à¦à¦Ÿà¦¾ মান < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2403,37 +2424,262 @@ msgstr ""
"ALSA ই আমাক যনà§à¦¤à§à§°à§° পৰা নতà§à¦¨ তথà§à¦¯ পà§à¦¿à¦¬à¦²à§ˆ উথালে, কিনà§à¦¤à§ à¦à¦•à§‹ পà§à¦¿à¦¬à¦²à§ˆ নাছিল!\n"
"অতি সমà§à¦­à§± à¦à¦‡à¦Ÿà§‹ ALSA চালক '%s' à§° à¦à¦Ÿà¦¾ বাগ । অনà§à¦—à§à§°à¦¹ কৰি à¦à¦‡ সমসà§à¦¯à¦¾ ALSA বিকাশকক "
"জনাওক ।\n"
-"POLLIN নিৰà§à¦§à¦¾à§°à¦¿à¦¤ হোৱাৰি পিছতো আমি উথিলো -- কিনà§à¦¤à§ তাৰ পিছৰ snd_pcm_avail() ঠ০ "
+"POLLIN নিৰà§à¦§à¦¾à§°à¦¿à¦¤ হোৱাৰি পিছতো আমি উথিলো কিনà§à¦¤à§ তাৰ পিছৰ snd_pcm_avail() ঠ০ "
"দিলে বা অনà§à¦¯ à¦à¦Ÿà¦¾ মান < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "নিৰà§à¦—ম %s + নিবেশ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "নিৰà§à¦—ম %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "নিবেশ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "বনà§à¦§"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "High Fidelity Playback (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "হাই ফিডেলিটি কà§à¦¯à¦¾à¦ªà¦šà¦¾à§° (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "Telephony Duplex (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio ধà§à¦¬à¦¨à¦¿ সেৱক"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "নিৰà§à¦—ম যনà§à¦¤à§à§°"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "নিবেশ যনà§à¦¤à§à§°"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ ত অ'ডিঅ'"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "নিবেশ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ডকিং সà§à¦Ÿà§‡à¦›à¦¨à§° পৰা নিবেশ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ডকিং সà§à¦Ÿà§‡à¦›à¦¨à§° মাইকà§à§°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "লাইন ইন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "মাইকà§à§°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "বহিসà§à¦¥à¦¿à¦¤ মাইকà§à§°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "অভà§à¦¯à¦¨à§à¦¤à§°à§€à¦£ মাইকà§à§°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "ৰেডিঅ'"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "ভিডিঅ'"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "সà§à¦¬à§Ÿà¦‚কà§à§°à¦¿à§Ÿ গেইন নিয়নà§à¦¤à§à§°à¦£"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "সà§à¦¬à§Ÿà¦‚কà§à§°à¦¿à§Ÿ গেইন নিয়নà§à¦¤à§à§°à¦£ পà§à§°à§Ÿà§‹à¦— কৰা ন'হ'ব"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "বà§à¦¸à§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "বà§à¦¸à§à¦Ÿ পà§à§°à§Ÿà§‹à¦— কৰা ন'হ'ব"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "বিবৰà§à¦§à¦•"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "বিবৰà§à¦§à¦¨ পà§à§°à§Ÿà§‹à¦— কৰা ন'হ'ব"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "বà§à¦¸à§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "বà§à¦¸à§à¦Ÿ পà§à§°à§Ÿà§‹à¦— কৰা ন'হ'ব"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "à¦à¦¨à¦¾à¦²à¦— হেড ফোন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "à¦à¦¨à¦¾à¦²à¦— নিবেশ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "à¦à¦¨à¦¾à¦²à¦— মাইকà§à§°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "à¦à¦¨à¦¾à¦²à¦— লাইন ইন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ৰেডিও"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ভিডিঅ'"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "à¦à¦¨à¦¾à¦²à¦— নিৰà§à¦—ম"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "à¦à¦¨à¦¾à¦²à¦— হেড ফোন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "à¦à¦¨à¦¾à¦²à¦— নিৰà§à¦—ম (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "à¦à¦¨à¦¾à¦²à¦— মোনো নিৰà§à¦—ম"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "à¦à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à§°à¦¿à¦…'"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "à¦à¦¨à¦¾à¦²à¦— মোনো"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "à¦à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à§°à¦¿à¦…'"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ ২.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ à§©.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ à§©.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ ৪.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ ৪.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ à§«.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ à§«.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ ৬.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ ৬.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ à§­.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "à¦à¦¨à¦¾à¦²à¦— ছাৰাউনà§à¦¡ à§­.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "ডিজিটেল সà§à¦Ÿà¦¿à§°à¦¿à¦…' (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "ডিজিটেল ছাৰাউনà§à¦¡ ৪.০ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "ডিজিটেল ছাৰাউনà§à¦¡ ৪.০ (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "ডিজিটেল ছাৰাউনà§à¦¡ à§«.à§§ (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "ডিজিটেল সà§à¦Ÿà¦¿à§°à¦¿à¦…' (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "à¦à¦¨à¦¾à¦²à¦— মোনো ডà§à¦ªà§à¦²à§‡à¦•à§à¦¸"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "à¦à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à§°à¦¿à¦…' ডà§à¦ªà§à¦²à§‡à¦•à§à¦¸"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ডিজিটেল সà§à¦Ÿà¦¿à§°à¦¿à¦…' ডà§à¦ªà§à¦²à§‡à¦•à§à¦¸ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Low Frequency Emmiter"
diff --git a/po/bn_IN.po b/po/bn_IN.po
index fbb90837..1e114573 100644
--- a/po/bn_IN.po
+++ b/po/bn_IN.po
@@ -1,67 +1,29 @@
-# translation of pulseaudio.master-tx.po to Bengali INDIA
+# translation of pulseaudio.master-tx.bn_IN.po to Bengali INDIA
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Runa Bhattacharjee <runab@fedoraproject.org>, 2009.
+# Runa Bhattacharjee <runab@redhat.com>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio.master-tx\n"
+"Project-Id-Version: pulseaudio.master-tx.bn_IN\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-08 16:21+0530\n"
-"Last-Translator: Runa Bhattacharjee <runab@fedoraproject.org>\n"
-"Language-Team: Bengali INDIA <fedora-trans-bn_in@redhat.com>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-08 14:34+0530\n"
+"Last-Translator: Runa Bhattacharjee <runab@redhat.com>\n"
+"Language-Team: Bengali INDIA <anubad@lists.ankur.org.in>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: KBabel 1.11.4\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— মোনো"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à¦°à¦¿à¦“"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "ডিজিটà§à¦¯à¦¾à¦² সà§à¦Ÿà¦¿à¦°à¦¿à¦“ (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "ডিজিটà§à¦¯à¦¾à¦² সà§à¦Ÿà¦¿à¦°à¦¿à¦“ (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à¦°à¦¿à¦“ ৪.০"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "ডিজিটà§à¦¯à¦¾à¦² সারাউনà§à¦¡ ৪.০ (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ ৪.à§§"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§«.০"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§«.à§§"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "ডিজিটà§à¦¯à¦¾à¦² সারাউনà§à¦¡ à§«.à§§ (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§­.à§§"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -73,7 +35,7 @@ msgstr ""
"সমà§à¦­à¦¬à¦¤ à¦à¦Ÿà¦¿ ALSA ডà§à¦°à¦¾à¦‡à¦­à¦¾à¦° '%s'-র à¦à¦•টি বাগ। অনà§à¦—à§à¦°à¦¹ করে à¦à¦‡ সমসà§à¦¯à¦¾ সমà§à¦¬à¦¨à§à¦§à§‡ ALSA "
"ডিভেলপরদের সূচিত করà§à¦¨à¥¤"
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -85,7 +47,7 @@ msgstr ""
"সমà§à¦­à¦¬à¦¤ à¦à¦Ÿà¦¿ ALSA ডà§à¦°à¦¾à¦‡à¦­à¦¾à¦° '%s'-র à¦à¦•টি বাগ। অনà§à¦—à§à¦°à¦¹ করে à¦à¦‡ সমসà§à¦¯à¦¾ সমà§à¦¬à¦¨à§à¦§à§‡ ALSA "
"ডিভেলপরদের সূচিত করà§à¦¨à¥¤"
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -97,11 +59,46 @@ msgstr ""
"সমà§à¦­à¦¬à¦¤ à¦à¦Ÿà¦¿ ALSA ডà§à¦°à¦¾à¦‡à¦­à¦¾à¦° '%s'-র à¦à¦•টি বাগ। অনà§à¦—à§à¦°à¦¹ করে à¦à¦‡ সমসà§à¦¯à¦¾ সমà§à¦¬à¦¨à§à¦§à§‡ ALSA "
"ডিভেলপরদের সূচিত করà§à¦¨à¥¤"
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+"সরà§à¦¬à¦¦à¦¾ অনà§à¦¤à¦¤ à¦à¦•টি sink লোড করে রাখা হবে, পà§à¦°à§Ÿà§‹à¦œà¦¨à§‡ null sink বà§à¦¯à¦¬à¦¹à¦¾à¦° করা হবে"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ডামি আউটপà§à¦Ÿ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "ভারà§à¦šà§à§Ÿà¦¾à¦² LADSPA sink"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "NULL sink-র সময় নিরà§à¦§à¦¾à¦°à¦£"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null ফলাফল"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "অভà§à¦¯à¦¨à§à¦¤à¦°à§€à¦£ অডিও"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "মোডেম"
@@ -117,412 +114,325 @@ msgstr "নতà§à¦¨ dl লোডার বরাদà§à¦¦ করতে বà§à¦
msgid "Failed to add bind-now-loader."
msgstr "bind-now-loader যোগ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "সিসà§à¦Ÿà§‡à¦® বাসের সাথে সংযোগ করতে বà§à¦¯à¦°à§à¦¥: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PID থেকে কলারের তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "কলার অবজেকà§à¦Ÿà§‡à¦° UID নিরà§à¦§à¦¾à¦°à¦£ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK সেশান পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "সেশান অবজেকà§à¦Ÿà§‡à¦° UID নিরà§à¦§à¦¾à¦°à¦£ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitAction বরাদà§à¦¦ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "action_id নিরà§à¦§à¦¾à¦°à¦£ করতে বà§à¦¯à¦°à§à¦¥"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext বরাদà§à¦¦ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContext আরমà§à¦­ করতে বà§à¦¯à¦°à§à¦¥: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "কলার অনà§à¦®à§‹à¦¦à¦¿à¦¤ কি না তা নিরà§à¦§à¦¾à¦°à¦£ করা সমà§à¦­à¦¬ নয়: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "auth পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit থেকে '%s' পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "%s সিগনà§à¦¯à¦¾à¦² পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে।"
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "পà§à¦°à¦¸à§à¦¥à¦¾à¦¨ করা হচà§à¦›à§‡à¥¤"
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "'%s' বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦•ারী সনà§à¦§à¦¾à¦¨ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "দল '%s' সনà§à¦§à¦¾à¦¨ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦•ারী '%s' (UID %lu) ও দল '%s' (GID %lu) পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে।"
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "'%s' বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦•ারীর ও '%s' দলের GID-র মধà§à¦¯à§‡ গরমিল।"
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr ""
"'%s' বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦•ারী বà§à¦¯à¦•à§à¦¤à¦¿à¦—ত ডিরেকà§à¦Ÿà¦°à¦¿ রূপে '%s' ধারà§à¦¯ করা হয়নি, অগà§à¦°à¦¾à¦¹à§à¦¯ করা হবে।"
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s' নিরà§à¦®à¦¾à¦£ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "দলের তালিকা পরিবরà§à¦¤à¦¨ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID পরিবরà§à¦¤à¦¨ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID পরিবরà§à¦¤à¦¨ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "root-র অধিকার সাফলà§à¦¯à§‡à¦° সাথে বরà§à¦œà¦¨ করা হয়েছে।"
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "à¦à¦‡ পà§à¦²à§à¦¯à¦¾à¦Ÿà¦«à¦°à§à¦®à§‡, সিসà§à¦Ÿà§‡à¦®à¦¬à§à¦¯à¦¾à¦ªà§€ মোড সমরà§à¦¥à¦¿à¦¤ নয়।"
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) বিফল: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "কমানà§à¦¡-লাইন পারà§à¦¸ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "অধিক গà§à¦°à§à¦¤à§à¦¬à¦¸à¦¹ শিডিউলিংয়ের সà§à¦¬à¦¿à¦§à¦¾ উপলবà§à¦§à¦•ারী '%s' দলে আমরা উপসà§à¦¥à¦¿à¦¤à¥¤"
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "রিয়েল-টাইম শিডিউলিংয়ের সà§à¦¬à¦¿à¦§à¦¾ উপলবà§à¦§à¦•ারী '%s' দলে আমরা উপসà§à¦¥à¦¿à¦¤à¥¤"
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit-র পকà§à¦· থেকে acquire-high-priority অধিকার পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে।"
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit-র পকà§à¦· থেকে acquire-high-priority অধিকার পà§à¦°à¦¤à§à¦¯à¦¾à¦–à§à¦¯à¦¾à¦¤ হয়েছে।"
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit-র পকà§à¦· থেকে acquire-real-priority অধিকার পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে।"
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit-র পকà§à¦· থেকে acquire-real-priority অধিকার পà§à¦°à¦¤à§à¦¯à¦¾à¦–à§à¦¯à¦¾à¦¤ হয়েছে।"
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"SUID root কল করা হয়েছে à¦à¦¬à¦‚ কনফিগারেশনের মধà§à¦¯à§‡ রিয়েল-টাইম à¦à¦¬à¦‚/অথবা উচà§à¦š-গà§à¦°à§à¦¤à§à¦¬à§‡à¦° "
-"শিডিউলিংয়ের অনà§à¦°à§‹à¦§ জানানো হয়েছে, কিনà§à¦¤à§ পরà§à¦¯à¦¾à¦ªà§à¦¤ অনà§à¦®à¦¤à¦¿ উপসà§à¦¥à¦¿à¦¤ নেই:\n"
-"'%s' দলে অনà§à¦¤à¦°à§à¦­à§à¦•à§à¦¤ নয়, PolicyKit দà§à¦¬à¦¾à¦°à¦¾ পরà§à¦¯à¦¾à¦ªà§à¦¤ অনà§à¦®à¦¤à¦¿ পà§à¦°à¦¦à¦¾à¦¨ করা হয়নি à¦à¦¬à¦‚ "
-"RLIMIT_NICE/RLIMIT_RTPRIO রিসোরà§à¦¸à§‡à¦° সীমা বৃদà§à¦§à¦¿à¦° করতে হবে।\n"
-"রিয়েল-টাইম/উচà§à¦š-গà§à¦°à§à¦¤à§à¦¬à§‡à¦° শিডিউলিং সকà§à¦°à¦¿à§Ÿ করার জনà§à¦¯ অনà§à¦—à§à¦°à¦¹ করে পà§à¦°à¦¯à§‹à¦œà§à¦¯ PolicyKit "
-"অধিকার পà§à¦°à¦¾à¦ªà§à¦¤ করà§à¦¨, অথবা '%s' দলের সদসà§à¦¯ হন, অথবা সংশà§à¦²à¦¿à¦·à§à¦Ÿ বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦•ারীর জনà§à¦¯ "
-"RLIMIT_NICE/RLIMIT_RTPRIO রিসোরà§à¦¸à§‡à¦° সীমা বৃদà§à¦§à¦¿ করà§à¦¨à¥¤"
-
-#: ../src/daemon/main.c:581
+#: ../src/daemon/main.c:535
msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"কনফিগারেশন দà§à¦¬à¦¾à¦°à¦¾ high-priority শিডিইলিংয়ের সà§à¦¬à¦¿à¦§à¦¾ উপলবà§à¦§ হলেও নিয়মনীতি দà§à¦¬à¦¾à¦°à¦¾ "
-"তা অনà§à¦®à§‹à¦¦à¦¿à¦¤ নয়।"
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO সাফলà§à¦¯à§‡à¦° সাথে বৃদà§à¦§à¦¿ করা হয়েছে"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO বিফল: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "CAP_NICE বরà§à¦œà¦¨ করা হচà§à¦›à§‡"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"কনফিগারেশন দà§à¦¬à¦¾à¦°à¦¾ real-time শিডিইলিংয়ের সà§à¦¬à¦¿à¦§à¦¾ উপলবà§à¦§ হলেও নিয়মনীতি দà§à¦¬à¦¾à¦°à¦¾ তা "
-"অনà§à¦®à§‹à¦¦à¦¿à¦¤ নয়।"
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "ডেমন চলছে না"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "PID %u রূপে ডেমন চলছে"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "ডেমন kill করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr ""
"root পরিচয়ে à¦à¦‡ পà§à¦°à§‹à¦—à§à¦°à¦¾à¦®à¦Ÿà¦¿ সঞà§à¦šà¦¾à¦²à¦¿à¦¤ হওয়া উচিত নয় (যদি না --system উলà§à¦²à¦¿à¦–িত হয়)।"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Root-র অধিকার আবশà§à¦¯à¦•।"
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "সিসà§à¦Ÿà§‡à¦® ইনসà§à¦Ÿà§à¦¯à¦¾à¦¨à§à¦¸à§‡à¦° কà§à¦·à§‡à¦¤à§à¦°à§‡ --start সমরà§à¦¥à¦¿à¦¤ নয়।"
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "সিসà§à¦Ÿà§‡à¦® মোডে চলছে, কিনà§à¦¤à§ --disallow-exit নিরà§à¦§à¦¾à¦°à¦¿à¦¤ হয়নি!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "সিসà§à¦Ÿà§‡à¦® মোডে চলছে, কিনà§à¦¤à§ --disallow-module-loading নিরà§à¦§à¦¾à¦°à¦¿à¦¤ হয়নি!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "সিসà§à¦Ÿà§‡à¦® মোডে চলছে, SHM মোড বলপূরà§à¦¬à¦• নিষà§à¦•à§à¦°à¦¿à§Ÿ করা হচà§à¦›à§‡!"
# http://linux.die.net/man/1/pulseaudio à¦à¦–ানে রেফারেনà§à¦¸ পাওয়া যাবে
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"সিসà§à¦Ÿà§‡à¦® মোডে চলছে, করà§à¦®à¦¹à§€à¦¨ অবসà§à¦¥à¦¾à¦° জনà§à¦¯ ধারà§à¦¯ সময়সীমা পূরà§à¦¤à§€ পরে পà§à¦°à¦¸à§à¦¥à¦¾à¦¨à§‡à¦° বà§à¦¯à¦¬à¦¸à§à¦¥à¦¾ "
"বলপূরà§à¦¬à¦• নিষà§à¦•à§à¦°à¦¿à§Ÿ করা হচà§à¦›à§‡!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "পাইপ বিফল: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() বিফল: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() বিফল: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "ডেমন আরমà§à¦­ করতে বিফল।"
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "সাফলà§à¦¯à§‡à¦° সাথে ডেমন আরমà§à¦­ করা হয়েছে।"
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() বিফল: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "à¦à¦Ÿà¦¿ PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "কমà§à¦ªà¦¾à¦‡à¦²à§‡à¦¶à¦¨à§‡à¦° হোসà§à¦Ÿ: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "কমà§à¦ªà¦¾à¦‡à¦²à¦¶à¦¨à§‡à¦° CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "চিহà§à¦¨à¦¿à¦¤ হোসà§à¦Ÿà§‡ চলছে: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPU পাওয়া গিয়েছে।"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "পেজের মাপ %lu বাইট"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Valgrind সমরà§à¦¥à¦¨ সহ কমà§à¦ªà¦¾à¦‡à¦² করা হয়েছে: হà§à¦¯à¦¾à¦"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Valgrind সমরà§à¦¥à¦¨ সহ কমà§à¦ªà¦¾à¦‡à¦² করা হয়েছে: না"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind মোডে চলছে: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "চিহà§à¦¨à¦¿à¦¤ হোসà§à¦Ÿà§‡ চলছে: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "সরà§à¦¬à¦¾à¦ªà§‡à¦•à§à¦· উতà§à¦¤à¦® বিলà§à¦¡: হà§à¦¯à¦¾à¦"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "সরà§à¦¬à¦¾à¦ªà§‡à¦•à§à¦· উতà§à¦¤à¦® বিলà§à¦¡: না"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG বà§à¦¯à¦¾à¦–à§à¦¯à¦¾ করা হয়েছে, সকল অà§à¦¯à¦¾à¦¸à¦¾à¦°à§à¦Ÿ নিষà§à¦•à§à¦°à¦¿à§Ÿ করা হয়েছে।"
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH বà§à¦¯à¦¾à¦–à§à¦¯à¦¾ করা হয়েছে, শà§à¦§à§à¦®à¦¾à¦¤à§à¦° ফাসà§à¦Ÿ পাথ অà§à¦¯à¦¾à¦¸à¦¾à¦°à§à¦Ÿ নিষà§à¦•à§à¦°à¦¿à§Ÿ করা হয়েছে।"
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "সকল অà§à¦¯à¦¾à¦¸à¦¾à¦°à§à¦Ÿ সকà§à¦°à¦¿à§Ÿ করা হয়েছে।"
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "মেশিন ID পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "মেশিন ID হল %s।"
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "মেশিন ID হল %s।"
+msgstr "সেশান ID হল %s।"
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "রান-টাইম ডিরেকà§à¦Ÿà¦°à¦¿ %s বà§à¦¯à¦¬à¦¹à¦¾à¦° করা হচà§à¦›à§‡à¥¤"
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "অবসà§à¦¥à¦¾à¦¸à§‚চক ডিরেকà§à¦Ÿà¦°à¦¿ %s বà§à¦¯à¦¬à¦¹à¦¾à¦° করা হচà§à¦›à§‡à¥¤"
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "মডিউল ডিরেকà§à¦Ÿà¦°à¦¿ %s বà§à¦¯à¦¬à¦¹à¦¾à¦° করা হচà§à¦›à§‡à¥¤"
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "সিসà§à¦Ÿà§‡à¦® মোডে চলছে: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"আপনি সিসà§à¦Ÿà§‡à¦® মোডে PA সঞà§à¦šà¦¾à¦²à¦¿à¦¤ করছেন à¦à¦¬à¦‚ à¦à¦Ÿà¦¿ না করাই বাঞà§à¦›à¦¨à§€à§Ÿà¥¤\n"
+"à¦à¦° ফলে পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¾à¦®à¦¤ ফলাফল না পাওয়ার সমà§à¦­à¦¾à¦¬à¦¨à¦¾ রয়েছে।\n"
+"সিসà§à¦Ÿà§‡à¦® মোডে বà§à¦¯à¦¬à¦¹à¦¾à¦°à§‡à¦° সমসà§à¦¯à¦¾ সমà§à¦ªà¦°à§à¦•ে জানতে হলে http://pulseaudio.org/wiki/"
+"WhatIsWrongWithSystemMode দেখà§à¦¨à¥¤"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "উচà§à¦š-রেসোলিউশনের নতà§à¦¨ টাইমার উপলবà§à¦§ রয়েছে! পরীকà§à¦·à¦¾ করে দেখà§à¦¨!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr "উচà§à¦š-রেসোলিউশনের নতà§à¦¨ টাইমার সহ Linux সকà§à¦°à¦¿à§Ÿ করা বাঞà§à¦›à¦¨à§€à§Ÿ!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "ডেমন আরমà§à¦­ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
"লোড করা মডিউল বিনা ডেমন আরমà§à¦­ করা হয়েছে à¦à¦¬à¦‚ কোনো করà§à¦® সঞà§à¦šà¦¾à¦²à¦¨ করা সমà§à¦­à¦¬ নয়।"
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "ডেমন আরমà§à¦­ করা হয়েছে।"
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "ডেমন বনà§à¦§ করার পà§à¦°à¦•à§à¦°à¦¿à§Ÿà¦¾ আরমà§à¦­ করা হয়েছে।"
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "ডেমন বনà§à¦§ করা হয়েছে।"
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -674,15 +584,15 @@ msgstr ""
"\n"
" -n ডিফলà§à¦Ÿ সà§à¦•à§à¦°à¦¿à¦ªà§à¦Ÿ ফাইল লোড করা হবে না\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -690,52 +600,52 @@ msgstr ""
"--log-level-র কà§à¦·à§‡à¦¤à§à¦°à§‡ লগ সà§à¦¤à¦°à§‡à¦° আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤ (0..4 সীমার মধà§à¦¯à§‡ à¦à¦•টি সংখà§à¦¯à¦¾ "
"অথবা debug, info, notice, warn, ও error-র মধà§à¦¯à§‡ à¦à¦•টি মান)।"
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "লগের উদà§à¦¦à¦¿à¦·à§à¦Ÿ সà§à¦¥à¦¨ বৈধ নয়: 'syslog', 'stderr' অথবা 'auto' পà§à¦°à§Ÿà§‹à¦— করà§à¦¨à¥¤"
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "রি-সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² পদà§à¦§à¦¤à¦¿ '%s' বৈধ নয়।"
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm দà§à¦¬à¦¾à¦°à¦¾ বà§à¦²à¦¿à§Ÿà¦¾à¦¨ আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ পà§à¦°à¦¤à§à¦¯à¦¾à¦¶à¦¿à¦¤"
@@ -774,77 +684,87 @@ msgstr "বà§à¦¯à¦¬à¦¹à¦¾à¦° পদà§à¦§à¦¤à¦¿: %s\n"
msgid "Load Once: %s\n"
msgstr "à¦à¦•বার লোড করা হবে: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "অবচিত করার সতরà§à¦•বারà§à¦¤à¦¾: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "পাথ: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] লগ টারà§à¦—েট '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] লগের সà§à¦¤à¦° '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] রি-সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² পদà§à¦§à¦¤à¦¿ '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] rlimit '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] à¦à¦‡ পà§à¦²à§à¦¯à¦¾à¦Ÿà¦«à¦°à§à¦®à§‡ rlimit সমরà§à¦¥à¦¿à¦¤ নয়।"
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° বিনà§à¦¯à¦¾à¦¸ '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° মাতà§à¦°à¦¾ '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° চà§à¦¯à¦¾à¦¨à§‡à¦² '%s' বৈধ নয়"
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] অংশ সংখà§à¦¯à¦¾ '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] অংশের মাপ '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] nice সà§à¦¤à¦° '%s' বৈধ নয়।"
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° মাতà§à¦°à¦¾ '%s' বৈধ নয়।"
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "কনফিগারেশন ফাইল খà§à¦²à¦¤à§‡ বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -852,18 +772,14 @@ msgstr ""
"ডিফলà§à¦Ÿ চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ªà§‡à¦° মধà§à¦¯à§‡ অনà§à¦¤à¦°à§à¦­à§à¦•à§à¦¤ চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° সংখà§à¦¯à¦¾ ও চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° ডিফলà§à¦Ÿ সংখà§à¦¯à¦¾à¦° মধà§à¦¯à§‡ "
"গরমিল।"
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### চিহà§à¦¨à¦¿à¦¤ কনফিগারেশন ফাইল থেকে পড়া হবে: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "root-র অধিকার বরà§à¦œà¦¨ করা হচà§à¦›à§‡à¥¤"
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "সাফলà§à¦¯à§‡à¦° সাথে CAP_SYS_NICE-ঠকরà§à¦®à¦•à§à¦·à¦®à¦¤à¦¾ সীমিত করা হয়েছে।"
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "অধিকার বরà§à¦œà¦¨ করা হচà§à¦›à§‡à¥¤"
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -873,259 +789,237 @@ msgstr "PulseAudio শবà§à¦¦ বà§à¦¯à¦¬à¦¸à§à¦¥à¦¾"
msgid "Start the PulseAudio Sound System"
msgstr "PulseAudio শবà§à¦¦ বà§à¦¯à¦¬à¦¸à§à¦¥à¦¾ আরমà§à¦­ করা হবে"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "PulseAudio ডেমনের জনà§à¦¯ উচà§à¦š-গà§à¦°à§à¦¤à§à¦¬à§‡à¦° শিডিউলিং (Unix nice-র মাতà§à¦°à¦¾ নঞরà§à¦¥à¦•)"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio ডেমনের জনà§à¦¯ রিয়েল-টাইম শিডিউলিং"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"সিসà§à¦Ÿà§‡à¦®à§‡à¦° নিয়ম-নীতির কারণে PulseAudio দà§à¦¬à¦¾à¦°à¦¾ উচà§à¦š-গà§à¦°à§à¦¤à§à¦¬à§‡à¦° শিডিউলিং পà§à¦°à§Ÿà§‹à¦— করা "
-"সমà§à¦­à¦¬ হচà§à¦›à§‡ না।"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"সিসà§à¦Ÿà§‡à¦®à§‡à¦° নিয়ম-নীতির কারণে PulseAudio দà§à¦¬à¦¾à¦°à¦¾ রিয়েল-টাইম শিডিউলিং পà§à¦°à§Ÿà§‹à¦— করা "
-"সমà§à¦­à¦¬ হচà§à¦›à§‡ না।"
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "মোনো"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "সামনে কেনà§à¦¦à§à¦°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "সামনে বাà¦à¦¦à¦¿à¦•ে"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "সামনে ডানদিকে"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "পিছনে কেনà§à¦¦à§à¦°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "পিছনে বাà¦à¦¦à¦¿à¦•ে"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "পিছনে ডানদিকে"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "কম ফà§à¦°à¦¿à¦•োয়েনà§à¦¸à¦¿à¦° নিঃসরণকারী"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "সামনে কেনà§à¦¦à§à¦°à§‡à¦°-বাà¦à¦¦à¦¿à¦•ে"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "সামনে কেনà§à¦¦à§à¦°à§‡à¦°-ডানদিকে"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "পাশে বাà¦à¦¦à¦¿à¦•ে"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "পাশে ডানদিকে"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ০"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§§"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§©"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ৪"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§«"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ৬"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§­"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§®"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ৯"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ১০"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§§à§§"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ১২"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§§à§©"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ১৪"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§§à§«"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ১৬"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§§à§­"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§§à§®"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ১৯"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২০"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২১"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২২"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২৩"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২৪"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২৫"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২৬"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২৭"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২৮"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ২৯"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ ৩০"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "অকà§à¦¸à¦¿à¦²à¦¾à¦°à¦¿ à§©à§§"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "উপরে কেনà§à¦¦à§à¦°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "উপরে সামনে কেনà§à¦¦à§à¦°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "উপরে সামনে বাà¦à¦¦à¦¿à¦•ে"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "উপরে সামনে ডানদিকে"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "উপরে পিছনে কেনà§à¦¦à§à¦°à¦¸à§à¦¥à¦¿à¦¤"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "উপরে পিছনে বাà¦à¦¦à¦¿à¦•ে"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "উপরে পিছনে ডানদিকে"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(অবৈধ)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "সà§à¦Ÿà¦¿à¦°à¦¿à¦“"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "সারাউনà§à¦¡ ৪.০"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "সারাউনà§à¦¡ ৪.à§§"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "সারাউনà§à¦¡ à§«.০"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "সারাউনà§à¦¡ à§«.à§§"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "সারাউনà§à¦¡ à§­.à§§"
@@ -1229,27 +1123,35 @@ msgstr "অনà§à¦ªà¦¸à§à¦¥à¦¿à¦¤ বাসà§à¦¤à¦¬à¦¾à§Ÿà¦¨"
msgid "Client forked"
msgstr "কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿ ফরà§à¦• করা হয়েছে"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "ইনপà§à¦Ÿ/আউটপà§à¦Ÿ তà§à¦°à§à¦Ÿà¦¿"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "ডিভাইস অথবা রিসোরà§à¦¸à¦Ÿà¦¿ বà§à¦¯à¦¸à§à¦¤"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f গিবিবাইট"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f মিবিবাইট"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f কিবিবাইট"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u বাইট"
@@ -1262,201 +1164,196 @@ msgstr "XOpenDisplay() বà§à¦¯à¦°à§à¦¥"
msgid "Failed to parse cookie data"
msgstr "কà§à¦•ির তথà§à¦¯ পারà§à¦¸ করতে বà§à¦¯à¦°à§à¦¥"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "কনফিগারেশন ফাইল '%s' খà§à¦²à¦¤à§‡ বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "কোনো কà§à¦•ি লোড করা হয়নি। কà§à¦•ি বিনা সংযোগের পà§à¦°à¦šà§‡à¦·à§à¦Ÿà¦¾ করা হচà§à¦›à§‡à¥¤"
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "অজানা à¦à¦•à§à¦¸à¦Ÿà§‡à¦¨à¦¶à¦¨ '%s'-র জনà§à¦¯ বারà§à¦¤à¦¾ পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে"
-#: ../src/utils/pacat.c:94
+# drain a stream = যখন সà§à¦Ÿà§à¦°à¦¿à¦®à§‡à¦° মধà§à¦¯à§‡ উপসà§à¦¥à¦¿à¦¤ সকল তথà§à¦¯ আহরণ করা হয় ও সà§à¦Ÿà§à¦°à¦¿à¦®à¦Ÿà¦¿ সমà§à¦ªà§‚রà§à¦£à¦°à§‚পে ফাà¦à¦•া হয়ে যায়।
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® ডà§à¦°à§‡à¦‡à¦¨ (অরà§à¦¥à¦¾à§Ž ফাà¦à¦•া) করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() বà§à¦¯à¦°à§à¦¥: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "পà§à¦²à§‡-বà§à¦¯à¦¾à¦• সà§à¦Ÿà§à¦°à¦¿à¦® ফাà¦à¦•া করা হয়েছে।"
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "সাফলà§à¦¯à§‡à¦° সাথে সà§à¦Ÿà§à¦°à¦¿à¦® নিরà§à¦®à¦¿à¦¤ হয়েছে।\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "সারà§à¦­à¦¾à¦°à§‡à¦° সাথে সà§à¦¥à¦¾à¦ªà¦¿à¦¤ সংযোগ ফাà¦à¦•া করা হচà§à¦›à§‡à¥¤"
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "বাফারের মাপ: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "বাফারের মাপ: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° spec '%s', ও চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª '%s' বà§à¦¯à¦¬à¦¹à¦¾à¦° করা হচà§à¦›à§‡à¥¤\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "ডিভাইস %s-র সাথে সংযোগ করা হয়েছে (%u, %ssuspended)।\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "সাফলà§à¦¯à§‡à¦° সাথে সà§à¦Ÿà§à¦°à¦¿à¦® নিরà§à¦®à¦¿à¦¤ হয়েছে।"
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "ষà§à¦Ÿà§à¦°à¦¿à¦® সংকà§à¦°à¦¾à¦¨à§à¦¤ তà§à¦°à§à¦Ÿà¦¿: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® ডিভাইস সà§à¦¥à¦—িত করা হয়েছে। %s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "বাফারের মাপ: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® ডিভাইস পà§à¦¨à¦°à¦¾à¦°à¦®à§à¦­ করা হয়েছে। %s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "বাফারের মাপ: maxlength=%u, fragsize=%u"
-# underrun = ধীর গতির সà§à¦Ÿà§à¦°à¦¿à¦®
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "ধীর গতির সà§à¦Ÿà§à¦°à¦¿à¦®.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° spec '%s', ও চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª '%s' বà§à¦¯à¦¬à¦¹à¦¾à¦° করা হচà§à¦›à§‡à¥¤"
-# overrun=the stream fills up the allocated buffer space and there is no more space for it
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® মাতà§à¦°à¦¾ অতিকà§à¦°à¦® করেছে।%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "ডিভাইস %s-র সাথে সংযোগ করা হয়েছে (%u, %ssuspended)।"
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® আরমà§à¦­ করা হয়েছে। %s \n"
+msgid "Stream error: %s"
+msgstr "ষà§à¦Ÿà§à¦°à¦¿à¦® সংকà§à¦°à¦¾à¦¨à§à¦¤ তà§à¦°à§à¦Ÿà¦¿: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "%s ডিভাইসে সà§à¦Ÿà§à¦°à¦¿à¦® সà§à¦¥à¦¾à¦¨à¦¾à¦¨à§à¦¤à¦° করা হয়েছে (%u, %ssuspended)।%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "না "
+msgid "Stream device suspended.%s"
+msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® ডিভাইস সà§à¦¥à¦—িত করা হয়েছে। %s"
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® বাফারের অà§à¦¯à¦¾à¦Ÿà§à¦°à¦¿à¦¬à¦¿à¦‰à¦Ÿ পরিবরà§à¦¤à¦¿à¦¤ হয়েছে। %s \n"
+msgid "Stream device resumed.%s"
+msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® ডিভাইস পà§à¦¨à¦°à¦¾à¦°à¦®à§à¦­ করা হয়েছে। %s"
-#: ../src/utils/pacat.c:278
+# underrun = ধীর গতির সà§à¦Ÿà§à¦°à¦¿à¦®
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "সংযোগ সà§à¦¥à¦¾à¦ªà¦¿à¦¤ হয়েছে।%s \n"
+msgid "Stream underrun.%s"
+msgstr "ধীর গতির সà§à¦Ÿà§à¦°à¦¿à¦®.%s"
-#: ../src/utils/pacat.c:281
+# overrun=the stream fills up the allocated buffer space and there is no more space for it
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Stream overrun.%s"
+msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® মাতà§à¦°à¦¾ অতিকà§à¦°à¦® করেছে।%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Stream started.%s"
+msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® আরমà§à¦­ করা হয়েছে। %s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "%s ডিভাইসে সà§à¦Ÿà§à¦°à¦¿à¦® সà§à¦¥à¦¾à¦¨à¦¾à¦¨à§à¦¤à¦° করা হয়েছে (%u, %ssuspended)।%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "সংযোগ বিফল: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "না "
-# drain a stream = যখন সà§à¦Ÿà§à¦°à¦¿à¦®à§‡à¦° মধà§à¦¯à§‡ উপসà§à¦¥à¦¿à¦¤ সকল তথà§à¦¯ আহরণ করা হয় ও সà§à¦Ÿà§à¦°à¦¿à¦®à¦Ÿà¦¿ সমà§à¦ªà§‚রà§à¦£à¦°à§‚পে ফাà¦à¦•া হয়ে যায়।
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® ডà§à¦°à§‡à¦‡à¦¨ (অরà§à¦¥à¦¾à§Ž ফাà¦à¦•া) করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® বাফারের অà§à¦¯à¦¾à¦Ÿà§à¦°à¦¿à¦¬à¦¿à¦‰à¦Ÿ পরিবরà§à¦¤à¦¿à¦¤ হয়েছে। %s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "পà§à¦²à§‡-বà§à¦¯à¦¾à¦• সà§à¦Ÿà§à¦°à¦¿à¦® ফাà¦à¦•া করা হয়েছে।\n"
+msgid "Connection established.%s"
+msgstr "সংযোগ সà§à¦¥à¦¾à¦ªà¦¿à¦¤ হয়েছে।%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "সারà§à¦­à¦¾à¦°à§‡à¦° সাথে সà§à¦¥à¦¾à¦ªà¦¿à¦¤ সংযোগ ফাà¦à¦•া করা হচà§à¦›à§‡à¥¤\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "ফাইলের সমাপà§à¦¤à¦¿ সনাকà§à¦¤ হয়েছে। \n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Connection failure: %s"
+msgstr "সংযোগ বিফল: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() বà§à¦¯à¦°à§à¦¥: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "ফাইলের সমাপà§à¦¤à¦¿ সনাকà§à¦¤ হয়েছে।"
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "সিগনà§à¦¯à¦¾à¦² পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে, পà§à¦°à¦¸à§à¦¥à¦¾à¦¨ করা হবে।\n"
+msgid "write() failed: %s"
+msgstr "write() বà§à¦¯à¦°à§à¦¥: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "সিগনà§à¦¯à¦¾à¦² পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে, পà§à¦°à¦¸à§à¦¥à¦¾à¦¨ করা হবে।"
# latency here = delay (technical term
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "লেটেনà§à¦¸à¦¿à¦° পরিমাণ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get latency: %s"
+msgstr "লেটেনà§à¦¸à¦¿à¦° পরিমাণ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "সময়: %0.3f সেকেনà§à¦¡; লেটেনà§à¦¸à¦¿: %0.0f usec. \r"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "সময়: %0.3f সেকেনà§à¦¡; লেটেনà§à¦¸à¦¿: %0.0f usec।"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:620
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pacat.c:511
-#, c-format
+# reverting this to english because the command line text gets messed up
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1482,8 +1379,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1506,54 +1405,73 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
-" -h, --help à¦à¦‡ সাহাযà§à¦¯ বারà§à¦¤à¦¾ পà§à¦°à¦¦à¦°à§à¦¶à¦¨ করা হবে\n"
-" --version সংসà§à¦•রণ পà§à¦°à¦¦à¦°à§à¦¶à¦¨ করা হবে\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
"\n"
-" -r, --record রেকরà§à¦¡à¦¿à¦‚য়ের জনà§à¦¯ সংযোগ সà§à¦¥à¦¾à¦ªà¦¨ করা হবে\n"
-" -p, --playback পà§à¦²à§‡-বà§à¦¯à¦¾à¦•ের জনà§à¦¯ সংযোগ সà§à¦¥à¦¾à¦ªà¦¨ করা হবে\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
"\n"
-" -v, --verbose ভারà§à¦¬à§‹à¦¸ করà§à¦® সকà§à¦°à¦¿à§Ÿ করা হবে\n"
+" -v, --verbose Enable verbose operations\n"
"\n"
-" -s, --server=SERVER সংযোগ করার জনà§à¦¯ চিহà§à¦¨à¦¿à¦¤ সারà§à¦­à¦¾à¦°à§‡à¦° নাম\n"
-" -d, --device=DEVICE সংযোগ করার উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ চিহà§à¦¨à¦¿à¦¤ সিংক/"
-"সোরà§à¦¸à§‡à¦° নাম\n"
-" -n, --client-name=NAME সারà§à¦­à¦¾à¦°à§‡à¦° মধà§à¦¯à§‡ à¦à¦‡ কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿà§‡à¦° পরিচয়\n"
-" --stream-name=NAME সারà§à¦­à¦¾à¦°à§‡à¦° মধà§à¦¯à§‡ à¦à¦‡ সà§à¦Ÿà§à¦°à¦¿à¦®à§‡à¦° পরিচয়\n"
-" --volume=VOLUME 0...65536 সীমার মধà§à¦¯à§‡ পà§à¦°à¦¾à¦°à¦®à§à¦­à¦¿à¦• "
-"(লিনিয়ার) আওয়াজ নিরà§à¦§à¦¾à¦°à¦£ করà§à¦¨\n"
-" --rate=SAMPLERATE Hz অনà§à¦¯à¦¾à§Ÿà§€ নিরà§à¦§à¦¾à¦°à¦¿à¦¤ ডিফলà§à¦Ÿ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° "
-"মাতà§à¦°à¦¾ (ডিফলà§à¦Ÿ মান 44100)\n"
-" --format=SAMPLEFORMAT সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° ধরন, সমà§à¦­à¦¾à¦¬à§à¦¯ মান হল s16le, "
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(ডিফলà§à¦Ÿ মান s16ne)\n"
-" --channels=CHANNELS চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° সংখà§à¦¯à¦¾, মোনোর কà§à¦·à§‡à¦¤à§à¦°à§‡ 1, "
-"সà§à¦Ÿà¦¿à¦°à¦¿à¦“র কà§à¦·à§‡à¦¤à§à¦°à§‡ 2\n"
-" (ডিফলà§à¦Ÿ মান 2)\n"
-" --channel-map=CHANNELMAP ডিফলà§à¦Ÿà§‡à¦° পরিবরà§à¦¤à§‡ বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦¯à§‹à¦—à§à¦¯ চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° "
-"মà§à¦¯à¦¾à¦ª\n"
-" --fix-format যে সিংকের সাথে সà§à¦Ÿà§à¦°à¦¿à¦® সংযোগ সà§à¦¥à¦¾à¦ªà¦¨ "
-"করেছে, সেটি থেকে সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦°\n"
-" বিনà§à¦¯à¦¾à¦¸ পà§à¦°à¦¾à¦ªà§à¦¤ করà§à¦¨à¥¤\n"
-" --fix-rate যে সিংকের সাথে সà§à¦Ÿà§à¦°à¦¿à¦® সংযোগ সà§à¦¥à¦¾à¦ªà¦¨ "
-"করেছে, সেটি থেকে সà§à¦¯à¦¾à¦®à§à¦ªà¦²à¦¿à¦‚য়ের\n"
-" হার পà§à¦°à¦¾à¦ªà§à¦¤ করà§à¦¨à¥¤\n"
-" --fix-channels যে সিংকের সাথে সà§à¦Ÿà§à¦°à¦¿à¦® সংযোগ সà§à¦¥à¦¾à¦ªà¦¨ "
-"করেছে, সেটি থেকে চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° সংখà§à¦¯à¦¾ ও\n"
-" চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° নাম পà§à¦°à¦¾à¦ªà§à¦¤ করà§à¦¨à¥¤\n"
-" --no-remix চà§à¦¯à¦¾à¦¨à§‹à¦² আপ-মিকà§à¦¸ অথবা ডাউন-মিকà§à¦¸ করা "
-"হবে না।\n"
-" --no-remap নামের পরিবরà§à¦¤à§‡ ইনà§à¦¡à§‡à¦•à§à¦¸ অনà§à¦¯à¦¾à§Ÿà§€ চà§à¦¯à¦¾à¦¨à§‡à¦² "
-"মà§à¦¯à¦¾à¦ª করা হয়।\n"
-" --latency=BYTES বাইট অনà§à¦¯à¦¾à§Ÿà§€ নিরà§à¦§à¦¾à¦°à¦¿à¦¤ লেটেনà§à¦¸à¦¿à¦° অনà§à¦°à§‹à¦§ "
-"জানান।\n"
-" --process-time=BYTES বাইট অনà§à¦¯à¦¾à§Ÿà§€, পà§à¦°à¦¤à¦¿à¦Ÿà¦¿ অনà§à¦°à§‹à¦§à§‡à¦° জনà§à¦¯ "
-"নিরà§à¦§à¦¾à¦°à¦¿à¦¤ পà§à¦°à¦¸à§‡à¦¸ সময় অনà§à¦°à§‹à¦§ জানিয়ে দিন।\n"
-
-#: ../src/utils/pacat.c:612
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1564,129 +1482,173 @@ msgstr ""
"libpulse সহযোগে কমà§à¦ªà¦¾à¦‡à¦² করা হয়েছে %s\n"
"libpulse-র সাথে যà§à¦•à§à¦¤ %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª '%s' বৈধ নয়\n"
+msgid "Invalid client name '%s'"
+msgstr "কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿà§‡à¦° নাম '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "লেটেনà§à¦¸à¦¿à¦° জনà§à¦¯ নিরà§à¦§à¦¾à¦°à¦¿à¦¤ বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়\n"
+msgid "Invalid stream name '%s'"
+msgstr "সà§à¦Ÿà§à¦°à¦¿à¦®à§‡à¦° নাম '%s' বৈধ নয়।"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "পà§à¦°à¦¸à§‡à¦¸à§‡à¦° সময়ের বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়\n"
+msgid "Invalid channel map '%s'"
+msgstr "চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "অবৈধ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² নিরà§à¦§à¦¾à¦°à¦¿à¦¤\n"
+msgid "Invalid latency specification '%s'"
+msgstr "লেটেনà§à¦¸à¦¿à¦° জনà§à¦¯ নিরà§à¦§à¦¾à¦°à¦¿à¦¤ বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° মà§à¦¯à¦¾à¦ª ও সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° মাপে গরমিল\n"
+msgid "Invalid process time specification '%s'"
+msgstr "পà§à¦°à¦¸à§‡à¦¸à§‡à¦° সময়ের বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "à¦à¦•টি %s সà§à¦Ÿà§à¦°à¦¿à¦® '%s' সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² বৈশিষà§à¦Ÿà§à¦¯ সহ খোলা হচà§à¦›à§‡à¥¤\n"
+msgid "Invalid property '%s'"
+msgstr "বৈশিষà§à¦Ÿà§à¦¯ '%s' বৈধ নয়।"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "রেকরà§à¦¡ করা হচà§à¦›à§‡"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "ফাইলের অজানা বিনà§à¦¯à¦¾à¦¸ %s।"
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "পà§à¦²à§‡-বà§à¦¯à¦¾à¦•"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "অবৈধ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² নিরà§à¦§à¦¾à¦°à¦¿à¦¤"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "অতà§à¦¯à¦¾à¦§à¦¿à¦• আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿà¥¤\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "অতà§à¦¯à¦¾à¦§à¦¿à¦• আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿà¥¤"
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() বà§à¦¯à¦°à§à¦¥à¥¤\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° মান নিরà§à¦§à¦¾à¦°à¦£à§‡à¦° ফাইল নিরà§à¦®à¦¾à¦£ করতে বà§à¦¯à¦°à§à¦¥"
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() বà§à¦¯à¦°à§à¦¥à¥¤\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "শবà§à¦¦à§‡à¦° ফাইল খà§à¦²à¦¤à§‡ বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() বà§à¦¯à¦°à§à¦¥à¥¤\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"সতরà§à¦•বারà§à¦¤à¦¾: চিহà§à¦¨à¦¿à¦¤ সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² নিরà§à¦§à¦¾à¦°à¦£à§‡à¦° ফাইলটির তথà§à¦¯, à¦à¦‡ ফাইলের থেকে উপলবà§à¦§ তথà§à¦¯ "
+"দà§à¦¬à¦¾à¦°à¦¾ পà§à¦°à¦¤à¦¿à¦¸à§à¦¥à¦¾à¦ªà¦¿à¦¤ হবে।"
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() বà§à¦¯à¦°à§à¦¥: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ফাইল থেকে সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "সতরà§à¦•বারà§à¦¤à¦¾: ফাইল থেকে চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° মà§à¦¯à¦¾à¦ª নিরà§à¦§à¦¾à¦°à¦£ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° মà§à¦¯à¦¾à¦ª ও সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° নিরà§à¦§à¦¾à¦°à¦¿à¦¤ মানে গরমিল"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "সতরà§à¦•বারà§à¦¤à¦¾: ফাইলের মধà§à¦¯à§‡ চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° মà§à¦¯à¦¾à¦ª লিখতে বà§à¦¯à¦°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() বà§à¦¯à¦°à§à¦¥à¥¤\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"à¦à¦•টি %s সà§à¦Ÿà§à¦°à¦¿à¦® খোলা হচà§à¦›à§‡à¥¤ à¦à¦Ÿà¦¿à¦° জনà§à¦¯ '%s'-র সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° নিরà§à¦§à¦¾à¦°à¦¿à¦¤ মান ও '%s' "
+"চà§à¦¯à¦¾à¦¨à§‡à¦²à§‡à¦° মà§à¦¯à¦¾à¦ª পà§à¦°à§Ÿà§‹à¦— করা হবে।"
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "রেকরà§à¦¡ করা হচà§à¦›à§‡"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "পà§à¦²à§‡-বà§à¦¯à¦¾à¦•"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() বà§à¦¯à¦°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() বà§à¦¯à¦°à§à¦¥à¥¤"
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() বà§à¦¯à¦°à§à¦¥à¥¤\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() বà§à¦¯à¦°à§à¦¥: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() বà§à¦¯à¦°à§à¦¥à¥¤"
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "সà§à¦¥à¦—িত করতে বà§à¦¯à¦°à§à¦¥: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "পà§à¦¨à¦°à¦¾à¦°à¦®à§à¦­ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "সতরà§à¦•বারà§à¦¤à¦¾: শবà§à¦¦à§‡à¦° সারà§à¦­à¦¾à¦°à¦Ÿà¦¿ সà§à¦¥à¦¾à¦¨à§€à§Ÿ নয় ও সà§à¦¥à¦—িত করা হচà§à¦›à§‡ না।\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "সংযোগ বিফল: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে, পà§à¦°à¦¸à§à¦¥à¦¾à¦¨ করা হয়েছে।\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "সতরà§à¦•বারà§à¦¤à¦¾: সিগনà§à¦¯à¦¾à¦² %u দà§à¦¬à¦¾à¦°à¦¾ চাইলà§à¦¡ পà§à¦°à¦¸à§‡à¦¸ বনà§à¦§ করা হয়েছে\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1705,7 +1667,7 @@ msgstr ""
"নাম\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1716,36 +1678,62 @@ msgstr ""
"libpulse সহযোগে কমà§à¦ªà¦¾à¦‡à¦² করা হয়েছে %s\n"
"libpulse-র সাথে যà§à¦•à§à¦¤ %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() বà§à¦¯à¦°à§à¦¥à¥¤\n"
+
+#: ../src/utils/pasuspender.c:288
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "পরিসংখà§à¦¯à¦¾à¦¨: %s\n"
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() বà§à¦¯à¦°à§à¦¥à¥¤\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() বà§à¦¯à¦°à§à¦¥à¥¤\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "পরিসংখà§à¦¯à¦¾à¦¨ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "বরà§à¦¤à¦®à¦¾à¦¨à§‡ বà§à¦¯à¦¬à¦¹à§ƒà¦¤: %u বà§à¦²à¦•ের মধà§à¦¯à§‡ উপসà§à¦¥à¦¿à¦¤ সরà§à¦¬à¦®à§‹à¦Ÿ %s বাইট।\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"সমà§à¦ªà§‚রà§à¦£ করà§à¦®à¦•ালের জনà§à¦¯ বরাদà§à¦¦ করা হয়েছে: %u বà§à¦²à¦•ের মধà§à¦¯à§‡ উপসà§à¦¥à¦¿à¦¤ সরà§à¦¬à¦®à§‹à¦Ÿ %s বাইট।\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² কà§à¦¯à¦¾à¦¶à§‡à¦° মাপ: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "সারà§à¦­à¦¾à¦° সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "সারà§à¦­à¦¾à¦° সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1753,7 +1741,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦•ারীর নাম: %s\n"
"হোসà§à¦Ÿ-নেম: %s\n"
@@ -1765,12 +1753,12 @@ msgstr ""
"ডিফলà§à¦Ÿ সোরà§à¦¸: %s\n"
"কà§à¦•ি: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "সিংক সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "sink সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1809,12 +1797,22 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tপোরà§à¦Ÿ:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tসকà§à¦°à¦¿à§Ÿ পোরà§à¦Ÿ: %s\n"
+
+#: ../src/utils/pactl.c:310
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "সোরà§à¦¸ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get source information: %s"
+msgstr "উৎস সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1853,20 +1851,20 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "মডিউল সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "মডিউল সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1883,12 +1881,12 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1903,12 +1901,12 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "কারà§à¦¡ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "কারà§à¦¡ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1925,22 +1923,22 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tপà§à¦°à§‹à¦«à¦¾à¦‡à¦²:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tসকà§à¦°à¦¿à§Ÿ পà§à¦°à§‹à¦«à¦¾à¦‡à¦²: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "সিংক ইনপà§à¦Ÿ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "sink ইনপà§à¦Ÿ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1977,12 +1975,12 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "সোরà§à¦¸ আউটপà§à¦Ÿ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "উৎস আউটপà§à¦Ÿ সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2011,13 +2009,13 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ পà§à¦°à¦¾à¦ªà§à¦¤ করতে বà§à¦¯à¦°à§à¦¥: %s"
# Lazy = low quality sample
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2048,23 +2046,81 @@ msgstr ""
"\tবিবিধ বৈশিষà§à¦Ÿà§à¦¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "বà§à¦¯à¦°à§à¦¥à¦¤à¦¾: %s\n"
+msgid "Failure: %s"
+msgstr "বà§à¦¯à¦°à§à¦¥à¦¤à¦¾: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² আপলোড করতে বà§à¦¯à¦°à§à¦¥: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² আপলোড করতে বà§à¦¯à¦°à§à¦¥: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "সমà§à¦ªà§‚রà§à¦£ হওয়ার পূরà§à¦¬à§‡ ফাইল সমাপà§à¦¤ হয়েছে\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "সমà§à¦ªà§‚রà§à¦£ হওয়ার পূরà§à¦¬à§‡ ফাইল সমাপà§à¦¤ হয়েছে"
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "সারà§à¦­à¦¾à¦° বৈধ নয়"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে, পà§à¦°à¦¸à§à¦¥à¦¾à¦¨ করা হয়েছে।"
+
+# reverting to english because the command line output gets messed up
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2072,13 +2128,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2094,21 +2159,31 @@ msgstr ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
-" -h, --help à¦à¦‡ সাহাযà§à¦¯ বারà§à¦¤à¦¾ পà§à¦°à¦¦à¦°à§à¦¶à¦¨ করা হবে\n"
-" --version সংসà§à¦•রণ সংখà§à¦¯à¦¾ পà§à¦°à¦¦à¦°à§à¦¶à¦¨ করা হবে\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
"\n"
-" -s, --server=SERVER সংযোগ করার উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ চিহà§à¦¨à¦¿à¦¤ সারà§à¦­à¦¾à¦°\n"
-" -n, --client-name=NAME সারà§à¦­à¦¾à¦°à§‡à¦° মধà§à¦¯à§‡ à¦à¦‡ কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿà§‡à¦° পরিচয়\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2119,74 +2194,106 @@ msgstr ""
"libpulse সহযোগে কমà§à¦ªà¦¾à¦‡à¦² করা %s\n"
"libpulse-র সাথে যà§à¦•à§à¦¤ %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "লোড করার উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ অনà§à¦—à§à¦°à¦¹ করে à¦à¦•টি সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– করà§à¦¨\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "লোড করার উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ অনà§à¦—à§à¦°à¦¹ করে à¦à¦•টি সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– করà§à¦¨"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "শবà§à¦¦à§‡à¦° ফাইল খà§à¦²à¦¤à§‡ বà§à¦¯à¦°à§à¦¥à¥¤\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "শবà§à¦¦à§‡à¦° ফাইল খà§à¦²à¦¤à§‡ বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "বাজানোর উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ à¦à¦•টি সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "সতরà§à¦•বারà§à¦¤à¦¾: ফাইল থেকে সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦²à§‡à¦° নিরà§à¦§à¦¾à¦°à¦¿à¦¤ মাপ নিরà§à¦®à¦¾à¦£ করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "অপসারণের উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ à¦à¦•টি সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "বাজানোর উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ à¦à¦•টি সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "সিংক ইনপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি সিংক নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "অপসারণের উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ à¦à¦•টি সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² ফাইল উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "সোরà§à¦¸ আউটপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি সোরà§à¦¸ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "সিংক ইনপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি সিংক নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "মডিউলের নাম ও আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "সোরà§à¦¸ আউটপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি সোরà§à¦¸ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "মডিউল ইনà§à¦¡à§‡à¦•à§à¦¸ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "মডিউলের নাম ও আরà§à¦—à§à¦®à§‡à¦¨à§à¦Ÿ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•।"
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "মডিউল ইনà§à¦¡à§‡à¦•à§à¦¸ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr "à¦à¦•াধিক সিংক নিরà§à¦§à¦¾à¦°à¦£ করা যাবে না। বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•।\n"
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr "à¦à¦•াধিক সিংক নিরà§à¦§à¦¾à¦°à¦£ করা যাবে না। বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•।"
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr "à¦à¦•াধিক সোরà§à¦¸ নিরà§à¦§à¦¾à¦°à¦£ করা যাবে না। বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•।\n"
+"value."
+msgstr "à¦à¦•াধিক সোরà§à¦¸ নিরà§à¦§à¦¾à¦°à¦£ করা যাবে না। বà§à¦²à¦¿à§Ÿà§‡à¦¨ মান নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•।"
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "কারà§à¦¡à§‡à¦° নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি পà§à¦°à§‹à¦«à¦¾à¦‡à¦²à§‡à¦° নাম উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "কারà§à¦¡à§‡à¦° নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি পà§à¦°à§‹à¦«à¦¾à¦‡à¦²à§‡à¦° নাম উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "কোনো কমানà§à¦¡ নিরà§à¦§à¦¾à¦°à¦¿à¦¤ হয়নি।\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "sink-র নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি পোরà§à¦Ÿà§‡à¦° নাম উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() বà§à¦¯à¦°à§à¦¥: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "উৎসের নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি পোরà§à¦Ÿà§‡ নাম উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "sink-র নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি পোরà§à¦Ÿà§‡à¦° নাম উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "অবৈধ শবà§à¦¦à§‡à¦° মাতà§à¦°à¦¾ নিরà§à¦§à¦¾à¦°à¦¿à¦¤"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "উৎসের নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি শবà§à¦¦à§‡à¦° মাতà§à¦°à¦¾ উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "সিংক ইনপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ ও শবà§à¦¦à§‡à¦° মাতà§à¦°à¦¾ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "সিংক ইনপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ বৈধ নয়"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "sink-র নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও à¦à¦•টি নিঃশবà§à¦¦à¦¤à¦¾à¦° বà§à¦²à¦¿à§Ÿà¦¾à¦¨ উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "উৎসের নাম/ইনà§à¦¡à§‡à¦•à§à¦¸ ও নিঃশবà§à¦¦à¦¤à¦¾à¦° বà§à¦²à¦¿à§Ÿà¦¾à¦¨ উলà§à¦²à§‡à¦– করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "সিংক ইনপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ ও নিঃশবà§à¦¦à¦¤à¦¾à¦° বà§à¦²à¦¿à§Ÿà¦¾à¦¨ নিরà§à¦§à¦¾à¦°à¦£ করা আবশà§à¦¯à¦•"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "অবৈধ সিংক ইনপà§à¦Ÿ ইনà§à¦¡à§‡à¦•à§à¦¸ নিরà§à¦§à¦¾à¦°à¦¿à¦¤"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "কোনো বৈধ কমানà§à¦¡ নিরà§à¦§à¦¾à¦°à¦¿à¦¤ হয়নি।"
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2267,128 +2374,48 @@ msgstr "কà§à¦•ি সংকà§à¦°à¦¾à¦¨à§à¦¤ তথà§à¦¯ লোড করà¦
msgid "Not yet implemented.\n"
msgstr "à¦à¦–নো বাসà§à¦¤à¦¬à¦¾à§Ÿà¦¿à¦¤ হয়নি।\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "PulseAudio ডেমন চলছে না অথবা সেশানের ডেমন রূপে চলছে না।"
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio ডেমন kill করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "ডেমন থেকে কোনো পà§à¦°à¦¤à¦¿à¦•à§à¦°à¦¿à§Ÿà¦¾ পাওয়া যাচà§à¦›à§‡ না।"
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "সাফলà§à¦¯à§‡à¦° সাথে সà§à¦Ÿà§à¦°à¦¿à¦® নিরà§à¦®à¦¿à¦¤ হয়েছে\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "সà§à¦Ÿà§à¦°à¦¿à¦® সংকà§à¦°à¦¾à¦¨à§à¦¤ তà§à¦°à§à¦Ÿà¦¿: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "সংযোগ সà§à¦¥à¦¾à¦ªà¦¿à¦¤à¥¤\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help à¦à¦‡ সাহাযà§à¦¯ বারà§à¦¤à¦¾ পà§à¦°à¦¦à¦°à§à¦¶à¦¨ করা হবে\n"
-" --version সংসà§à¦•রণ সংখà§à¦¯à¦¾ পà§à¦°à¦¦à¦°à§à¦¶à¦¨ করা হবে\n"
-"\n"
-" -v, --verbose ভারà§à¦¬à§‹à¦¸ করà§à¦® সকà§à¦°à¦¿à§Ÿ করা হবে\n"
-"\n"
-" -s, --server=SERVER সংযোগ করার উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ চিহà§à¦¨à¦¿à¦¤ সারà§à¦­à¦¾à¦°à§‡à¦° "
-"নাম\n"
-" -d, --device=DEVICE সংযোগ করার উদà§à¦¦à§‡à¦¶à§à¦¯à§‡ চিহà§à¦¨à¦¿à¦¤ সিংকের "
-"নাম\n"
-" -n, --client-name=NAME সারà§à¦­à¦¾à¦°à§‡à¦° মধà§à¦¯à§‡ à¦à¦‡ কà§à¦²à¦¾à§Ÿà§‡à¦¨à§à¦Ÿà§‡à¦° নাম\n"
-" --stream-name=NAME সারà§à¦­à¦¾à¦°à§‡à¦° মধà§à¦¯à§‡ à¦à¦‡ সà§à¦Ÿà§à¦°à¦¿à¦®à§‡à¦° নাম\n"
-" --volume=VOLUME 0...65536 সীমার মধà§à¦¯à§‡ পà§à¦°à¦¾à¦°à¦®à§à¦­à¦¿à¦• "
-"(লিনিয়ার) আওয়াজ নিরà§à¦§à¦¾à¦°à¦£ করà§à¦¨\n"
-" --channel-map=CHANNELMAP বà§à¦¯à¦¬à¦¹à¦¾à¦°à¦¯à§‹à¦—à§à¦¯ চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª নিরà§à¦§à¦¾à¦°à¦£\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"libpulse সহযোগে কমà§à¦ªà¦¾à¦‡à¦² করা হয়েছে %s\n"
-"libpulse-র সাথে যà§à¦•à§à¦¤ %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "অবৈধ চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "ফাইল '%s' খà§à¦²à¦¤à§‡ বà§à¦¯à¦°à§à¦¥\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "চà§à¦¯à¦¾à¦¨à§‡à¦² মà§à¦¯à¦¾à¦ª ও ফাইলে গরমিল।\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "সà§à¦¯à¦¾à¦®à§à¦ªà§‡à¦² spec '%s' পà§à¦°à§Ÿà§‹à¦— করা হচà§à¦›à§‡\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "autospawn লক পà§à¦°à§Ÿà§‹à¦— করতে বà§à¦¯à¦°à§à¦¥à¥¤"
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2405,7 +2432,7 @@ msgstr ""
"POLLOUT set দà§à¦¬à¦¾à¦°à¦¾ চেতাবনী সৃষà§à¦Ÿà¦¿ হয়েছে -- পরবরà§à¦¤à§€ snd_pcm_avail() থেকে 0 অথবা < "
"min_avail-র থেকে কম অনà§à¦¯ à¦à¦•টি মান পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে।"
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2422,34 +2449,259 @@ msgstr ""
"POLLIN set দà§à¦¬à¦¾à¦°à¦¾ চেতাবনী সৃষà§à¦Ÿà¦¿ হয়েছে -- পরবরà§à¦¤à§€ snd_pcm_avail() থেকে 0 অথবা < "
"min_avail-র থেকে কম অনà§à¦¯ à¦à¦•টি মান পà§à¦°à¦¾à¦ªà§à¦¤ হয়েছে।"
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "আউটপà§à¦Ÿ %s + ইনপà§à¦Ÿ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "আউটপà§à¦Ÿ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "ইনপà§à¦Ÿ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "বনà§à¦§"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "হাই-ফিডেলিটি পà§à¦²à§‡-বà§à¦¯à¦¾à¦• (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "হাই-ফিডেলিটি কà§à¦¯à¦¾à¦ªà¦šà¦¾à¦° (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "টেলিফোনি ডà§à¦ªà§à¦²à§‡ (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio শবà§à¦¦à§‡à¦° সারà§à¦­à¦¾à¦°"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "আউটপà§à¦Ÿ ডিভাইস"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ইনপà§à¦Ÿ ডিভাইস"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@-র মধà§à¦¯à§‡ অডিও"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "ইনপà§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ডকিং সà§à¦Ÿà§‡à¦¶à¦¨ থেকে ইনপà§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ডকিং সà§à¦Ÿà§‡à¦¶à¦¨à§‡à¦° মাইকà§à¦°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "লাইন-ইন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "মাইকà§à¦°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "বহিসà§à¦¥à¦¿à¦¤ মাইকà§à¦°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "অভà§à¦¯à¦¨à§à¦¤à¦°à§€à¦£ মাইকà§à¦°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "রেডিও"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "ভিডিও"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "সà§à¦¬à§Ÿà¦‚কà§à¦°à¦¿à§Ÿ গেইন নিয়নà§à¦¤à§à¦°à¦£"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "সà§à¦¬à§Ÿà¦‚কà§à¦°à¦¿à§Ÿ গেইন নিয়নà§à¦¤à§à¦°à¦£ পà§à¦°à§Ÿà§‹à¦— করা হবে না"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "বà§à¦¸à§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "বà§à¦¸à§à¦Ÿ পà§à¦°à§Ÿà§‹à¦— করা হবে না"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "বিবরà§à¦§à¦•"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "বিবরà§à¦§à¦¨ পà§à¦°à§Ÿà§‹à¦— করা হবে না"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "বà§à¦¸à§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "বà§à¦¸à§à¦Ÿ পà§à¦°à§Ÿà§‹à¦— করা হবে না"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— হেড-ফোন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— ইনপà§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— মাইকà§à¦°à§‹à¦«à§‹à¦¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— লাইন-ইন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— রেডিও"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— ভিডিও"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— আউটপà§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— হেড-ফোন"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— আউটপà§à¦Ÿ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— মোনো আউটপà§à¦Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à¦°à¦¿à¦“"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— মোনো"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à¦°à¦¿à¦“"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ ২.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§©.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§©.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ ৪.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ ৪.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§«.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§«.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ ৬.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ ৬.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§­.০"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সারাউনà§à¦¡ à§­.à§§"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "ডিজিটà§à¦¯à¦¾à¦² সà§à¦Ÿà¦¿à¦°à¦¿à¦“ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "ডিজিটà§à¦¯à¦¾à¦² সারাউনà§à¦¡ ৪.০ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "ডিজিটà§à¦¯à¦¾à¦² সারাউনà§à¦¡ ৪.০ (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "ডিজিটà§à¦¯à¦¾à¦² সারাউনà§à¦¡ à§«.à§§ (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "ডিজিটà§à¦¯à¦¾à¦² সà§à¦Ÿà¦¿à¦°à¦¿à¦“ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— মোনো ডà§à¦ªà§à¦²à§‡"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "অà§à¦¯à¦¾à¦¨à¦¾à¦²à¦— সà§à¦Ÿà¦¿à¦°à¦¿à¦“ ডà§à¦ªà§à¦²à§‡"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ডিজিটà§à¦¯à¦¾à¦² সà§à¦Ÿà¦¿à¦°à¦¿à¦“ ডà§à¦ªà§à¦²à§‡ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "কম ফà§à¦°à¦¿à¦•োয়েনà§à¦¸à¦¿à¦° নিঃসরণকারী"
diff --git a/po/ca.po b/po/ca.po
index 5a7fa15c..95d93776 100644
--- a/po/ca.po
+++ b/po/ca.po
@@ -1,77 +1,43 @@
# Catalan translation of pulseaudio by Softcatalà
# Copyright (C) 2008 Free Software Foundation
# This file is distributed under the same license as the pulseaudio package.
+#
# Xavier Conde Rueda <xavi.conde@gmail.com>, 2008.
+# Agustí Grau <fletxa@gmail.com>, 2009.
+# Judith Pintó Subirada <judithp@gmail.com>
+# Josep Torné Llavall <josep.torne@gmail.com>, 2009
#
# This file is translated according to the glossary and style guide of
-# Softcatalà. If you plan to modify this file, please read first the page
-# of the Catalan translation team for the Fedora project at:
-# http://www.softcatala.org/projectes/fedora/
-# and contact the previous translator.
+# Softcatalà. If you plan to modify this file, please read first the page
+# of the Catalan translation team for the Fedora project at:
+# http://www.softcatala.org/projectes/fedora/
+# and contact the previous translator.
#
# Aquest fitxer s'ha de traduir d'acord amb el recull de termes i la guia
-# d'estil de Softcatalà. Si voleu modificar aquest fitxer, llegiu si
-# us plau la pàgina de catalanització del projecte Fedora a:
-# http://www.softcatala.org/projectes/fedora/
-# i contacteu l'anterior traductor/a.
+# d'estil de Softcatalà. Si voleu modificar aquest fitxer, llegiu si
+# us plau la pàgina de catalanització del projecte Fedora a:
+# http://www.softcatala.org/projectes/fedora/
+# i contacteu l'anterior traductor/a.
+#
#
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-03-18 21:47+0100\n"
-"Last-Translator: Agustí Grau <fletxa@gmail.com>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-09-12 11:40+0100\n"
+"Last-Translator: Josep Torné Llavall <josep.torne@gmail.com>\n"
"Language-Team: Catalan <fedora@softcatala.net>\n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=utf-8\n"
+"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Mono analògic"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Estèreo analògic"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Estèreo digital (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Estèreo digital (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Envolvent 4.0 analògic"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Envolvent 4.0 digital (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Envolvent 4.1 analògic"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Envolvent 5.0 analògic"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Envolvent 5.1 analògic"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Envolvent 5.1 digital (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Envolvent analògic 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -79,13 +45,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
-"snd_pcm_avail() ha retornat un valor que és excepcionalment gran: %lu bytes "
-"(%lu ms).\n"
-"En la majoria dels casos és un error del controlador ALSA '%s'. Siusplau, "
-"informeu d'aquest\n"
-"incident als desenvolupadors d'ALSA."
+"snd_pcm_avail() ha retornat un valor excepcionalment gran: %lu bytes (%lu "
+"ms).\n"
+"Probablement es tracta d'un error del controlador de l'ALSA '%s'. Informeu "
+"d'aquest incident als desenvolupadors de l'ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -95,11 +60,10 @@ msgid ""
msgstr ""
"snd_pcm_delay() ha retornat un valor excepcionalment gran: %li bytes (%s%lu "
"ms).\n"
-"En la majoria dels casos és un error del controlador ALSA '%s'. Siusplau, "
-"informeu d'aquest\n"
-"incident als desenvolupadors d'ALSA."
+"Probablement es tracta d'un error del controlador de l'ALSA '%s'. Informeu "
+"d'aquest incident als desenvolupadors de l'ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -109,18 +73,50 @@ msgid ""
msgstr ""
"snd_pcm_mmap_begin() ha retornat un valor excepcionalment gran: %lu bytes (%"
"lu ms).\n"
-"En la majoria dels casos és un error del controlador ALSA '%s'. Siusplau, "
-"informeu d'aquest\n"
-"incident als desenvolupadors d'ALSA."
+"Probablement es tracta d'un error del controlador de l'ALSA '%s'. Informeu "
+"d'aquest incident als desenvolupadors de l'ALSA."
-#: ../src/pulsecore/sink.c:2141
-#, fuzzy
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Conserva sempre almenys un conducte carregat fins i tot si és el nul"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Sortida fingida"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Conducte virtual LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nom per al conducte> sink_properties=<propietats per al conducte> "
+"master=<nom del conducte del filtre> format=<format de mostra> rate=<ràtio "
+"de mostra> channels=<nombre de canals> channel_map=<mapa de canals> "
+"pulgin=<nom del connector ladspa> label=<etiqueta del connector ladspa> "
+"control=<llista separada per comes dels valors de control d'entrada>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Conducte NULL"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Sortida nul·la"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
-msgstr "S'ha produït un error intern"
+msgstr "Audio intern"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
-msgstr ""
+msgstr "Mòdem"
#: ../src/daemon/ltdl-bind-now.c:124
msgid "Failed to find original lt_dlopen loader."
@@ -128,229 +124,104 @@ msgstr "No s'ha trobat el carregador lt_dlopen original."
#: ../src/daemon/ltdl-bind-now.c:129
msgid "Failed to allocate new dl loader."
-msgstr "S'ha produït un error en allotjar el nou carregador dl."
+msgstr "No s'ha pogut allotjar el nou carregador dl."
#: ../src/daemon/ltdl-bind-now.c:142
msgid "Failed to add bind-now-loader."
-msgstr "S'ha produït un error en afegir bind-now-loader."
-
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "No s'ha pogut connectar al bus del sistema: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "No s'ha pogut obtenir una crida del PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "No s'ha pogut especificar UID en l'objecte crida."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "S'ha produït un error en obtenir la sessió CK"
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "No s'ha pogut especificar UID en l'objecte sessió"
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "No s'ha pogut introduïr PolKitAction"
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "No s'ha pogut especificar action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "No s'ha pogut introduïr PolKitContext"
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "No s'ha pogut inicialitzar PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "S'ha produït un error en determinar si la crida està autoritzada: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "No s'ha pogut obtenir autorització: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit ha respós '%s'"
+msgstr "No s'ha pogut afegir bind-now-loader."
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "S'ha obtingut la senyal %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "S'està sortint."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
-msgstr "S'ha produït un error en trobar l'usuari '%s'."
+msgstr "No s'ha trobat l'usuari '%s'."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
-msgstr "S'ha produït un error en trobar el grup '%s'."
+msgstr "No s'ha trobat el grup '%s'."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "S'han trobat l'usuari '%s' (UID %lu) i el grup '%s' (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
-msgstr "El GID de l'usuari '%s' i del grup '%s' no coincideixen"
+msgstr "El GID de l'usuari '%s' i del grup '%s' no coincideixen."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "El directori arrel de l'usuari '%s' no és '%s', s'ignorarà."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
-msgstr "S'ha produït un error durant la creació '%s': %s"
+msgstr "No s'ha pogut crear '%s': %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
-msgstr "S'ha produït un error en canviar la llista del grup :%s"
+msgstr "No s'ha pogut canviar la llista del grup: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
-msgstr "S'ha produït un error en canviar la GID: %s"
+msgstr "No s'ha pogut canviar el GID: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
-msgstr "S'ha produït un error en canviar la UID: %s"
+msgstr "No s'ha pogut canviar l'UID: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
-msgstr "S'han lliberat els permissos de root amb éxit."
+msgstr "S'han alliberat els permisos de root."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
-msgstr "El mode de sistema ampli no està suportat en aquesta plataforma."
+msgstr "El mode de sistema global no és compatible amb aquesta plataforma."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "S'ha produït un error en setrlimit(%s, (%u, %u)): %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
-msgstr "S'ha produït un error en interpretar la línia de comandes."
-
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Aquesta aplicació està en el grup '%s', s'està establint la prioritat alta."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Aquesta aplicació està en el grup '%s', s'està establint la prioritat en "
-"temps real."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit ha permés el privilegi acquire-high-priority."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit ha rebutjat el privilegi acquire-high-priority."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit h permés el privilegi acquire-real-time."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit ha rebutjat el privilegi acquire-real-time."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"S'ha demanat SUID de root i una planificació de temps real i/o d'alta "
-"prioritat. De totes formes, falten els privilegis necessaris:\n"
-"No es pertany al grup '%s'. PolicyKit no atorga els privilegis demanats i no "
-"s'ha incrementat els límits de recursos RLIMIT_NICE/RLIMIT_RTPRIO.\n"
-"Per habilitar la planificació en temps real o d'alta prioritat, heu "
-"d'obtenir els privilegis de PolicyKits adequats, o pertànyer al grup '%s', o "
-"incrementar els límits de recursos de RLIMIT_NICE/RLIMIT_RTPRIO per a aquest "
-"usuari."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"La prioritat alta està habilitada en la configuració però no està permesa "
-"per la política."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "S'ha incrementat el valor de RLIMIT_RTPRIO amb éxit."
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "S'ha produït un error amb RLIMIT_RTPRIO: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "S'abandona CAP_NICE"
+msgstr "No s'ha pogut interpretar la línia d'ordres."
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"La prioritat de temps real està habilitada en la configuració però no està "
-"permesa per la política."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "El dimoni no s'està executant"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "El dimoni s'està executant amb PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "S'ha produït un error en matar el dimoni: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -358,165 +229,202 @@ msgstr ""
"No és necessari executar aquesta aplicació com a root (excepte si "
"s'especifica --system)"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Es requereixen privilegis de root."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "La opció --start no està suportada per a instàncies de sistema."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
"S'està executant en mode sistema, però no s'ha especificat l'opció --"
"disallow-exit."
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"S'està executant en mode sistema, però no s'ha especificat l'opció --"
"disallow-module-loading."
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr ""
"S'està executant en mode sistema, es deshabilitarà el mode SHM forçosament."
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"S'està executant en mode sistema, la sortida per temps d'inactivitat es "
"deshabilita."
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "S'ha produït un error en adquirir stdio."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "Ha fallat la canonada: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "Ha fallat fork(): %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "Ha fallat read(): %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "S'ha produït un error en iniciar el dimoni."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "S'ha iniciat el dimoni."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "Ha fallat read(): %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Aquest és el PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Host de compilació: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "CFLAGS de compilació: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "S'està executant en el host: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "S'han trobat %u CPU's"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "La mida de pàgina és de %lu bytes."
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Compilat amb suport per a Valgrind: sí"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Compilat amb suport per a Valgrind: no"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "S'està executant amb el mode valgrind: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "S'està executant en el host: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Construcció optimitzada: sí"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Construcció optmitzada: no"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr ""
+msgstr "NDEBUG està definit, s'han desactivat totes les assercions."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr ""
+"FASTPATH està definit, només s'ha deshabilitat les assercions de camí ràpid."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr ""
+msgstr "S'han habilitat totes les assercions."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
-msgstr "S'ha produït un error en obtenir l'ID de la màquina"
+msgstr "No s'ha pogut obtenir l'ID de la màquina"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "L'ID de la màquina és %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "L'ID de la màquina és %s."
+msgstr "L'ID de la sessió és %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "S'està utilitzant el directori d'execució %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "S'està utilitzant el directori d'estat %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "S'està utilitzant el directori dels móduls %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "S'està executant en mode sistema: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"Esteu utilitzant el PA en mode sistema. Tingueu en compte que molt "
+"probablement no hauríeu de fer-ho.\n"
+"No obstant això, si ho feu és la vostra responsabilitat si no funciona com "
+"s'esperava.\n"
+"Si us plau, llegiu http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode per "
+"a una explicació de per què el mode sistema sol ser una mala idea."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "S'ha produït un error en pa_pid_file_create()."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
-msgstr "Estan disponibles els temporitzadors frescos de alta resolució."
+msgstr "Estan disponibles els temporitzadors frescos d'alta resolució."
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -524,31 +432,31 @@ msgstr ""
"Es recomana la utilització d'un nucli amb els temporitzadors d'alta "
"resolució habilitats."
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "S'ha produït un error en pa_core_new()."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "S'ha produït un error en inicialitzar el dimoni."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
-msgstr "Com el dimoni s'ha iniciat sense cap mòdul carregat, no funciona."
+msgstr "El dimoni s'ha iniciat sense cap mòdul carregat, no funcionarà."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "S'ha completat la inicialització del dimoni."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "S'ha iniciat l'aturada del dimoni."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "S'ha aturat el dimoni."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -632,8 +540,8 @@ msgstr ""
"remostratge\n"
" --cleanup-shm Neteja els segments de memòria "
"compartida sense emprar\n"
-" --start Inicia el dimoni si aquest no està "
-"corrent\n"
+" --start Inicia el dimoni si aquest no s'està "
+"executant\n"
" -k --kill Mata el dimoni en execució\n"
" --check Comprova l'execució del dimoni\n"
"\n"
@@ -644,7 +552,7 @@ msgstr ""
"inicialització\n"
" --fail[=BOOL] Surt quan falli la inicialització\n"
" --high-priority[=BOOL] Prova d'establir un nivell de \n"
-" prioritat alt (només disponible com "
+" Prioritat alta (només disponible com "
"a root,\n"
" amb SUID o amb un RLIMIT_NICE "
"elevat)\n"
@@ -678,12 +586,12 @@ msgstr ""
"missatges de registre\n"
" --log-time[=BOOL] Inclou marques de temps en els "
"missatges de registre\n"
-" --log-backtrace=FRAMES Inclou una traça en els missatges de "
+" --log-backtrace=MARCS Inclou una traça en els missatges de "
"registre\n"
-" -p, --dl-search-path=CAMI Estableix el camí de cerca "
+" -p, --dl-search-path=CAMà Estableix el camí de cerca "
"d'objectes dinàmics\n"
" compartits (plugins)\n"
-" --resample-method=METODE Utilitza el mètode de remostreig\n"
+" --resample-method=MÈTODE Utilitza el mètode de remostreig\n"
" (Per veure els valors possibles "
"utilitza --dump-resample-methods)\n"
" --use-pid-file[=BOOL] Crea un fitxer PID\n"
@@ -694,7 +602,7 @@ msgstr ""
"compartida.\n"
"\n"
"SCRIPT D'INICI:\n"
-" -L, --load=\"ARGUMENTS MODUL\" Carrega el mòdul especificat amb\n"
+" -L, --load=\"ARGUMENTS MÒDUL\" Carrega el mòdul especificat amb\n"
" els arguments especificats\n"
" -F, --file=NOMFITXER Executa l'script especificat\n"
" -C Obre una línia d'ordres en la TTY "
@@ -704,15 +612,15 @@ msgstr ""
" -n No carreguis el fitxer de "
"configuració per omissió\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize necessita un argument booleà"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail necessita un argument booleà"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -720,52 +628,52 @@ msgstr ""
"--log-level necessita un argument de nivell de log (valor númeric 0..4 o "
"debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority necessita un argument booleà"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime necessita un argument booleà"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading necessita un argument booleà"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr "--disallow-exit necessita d'un argument booleà"
+msgstr "--disallow-exit necessita un argument booleà"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file necessita un argument booleà"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "Objectiu de log invàlid: utilitzeu 'syslog', 'stderr' o 'auto'."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--logtime necessita un argument booleà"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta necessita un argument booleà"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Mètode de remostratge invàlid '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system necessita un argument booleà"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit necessita un argument booleà"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm necessita un argument booleà"
@@ -804,77 +712,87 @@ msgstr "Utilització: %s\n"
msgid "Load Once: %s\n"
msgstr "Càrrega: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "Advertència d'obsolescència: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Ruta: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Destí de registre incorrecte '%s'"
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Nivell de registre incorrecte '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Mètode de remostreig incorrecte '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] rlimit incorrecte '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit no disponible en aquesta plataforma."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Format de mostra incorrecte '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Velocitat de mostreig '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Canals de mostreig incorrectes '%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Mapa de canals incorrecte '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Nombre de fragments incorrecte '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Mida de fragment incorrecta '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Nivell de prioritat incorrecte '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Velocitat de mostreig '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Error en obrir el fitxer de configuració: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -882,18 +800,14 @@ msgstr ""
"El mapa de canals especificat per omissió té un número de canals diferent "
"del número de canals especificat per omissió."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Lectura del fitxer de configuració: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Alliberant els privilegis de root."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "S'han limitat les capacitats cap a CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Alliberant els privilegis."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -903,258 +817,237 @@ msgstr "Sistema de so PulseAudio"
msgid "Start the PulseAudio Sound System"
msgstr "Inicialitza el sistema de so PulseAudio"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-#, fuzzy
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Ha fallat en matar el dimoni PulseAudio."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-#, fuzzy
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Aquesta aplicació està en el grup '%s', s'està establint la prioritat alta."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Frontal central"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Frontal esquerra"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Frontal dreta"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Posterior central"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Posterior esquerra"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Posterior dreta"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Emissor de baixa freqüència"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Frontal central part esquerra"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Frontal central part dreta"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Lateral esquerra"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Lateral dreta"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Auxiliar 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Auxiliar 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Auxiliar 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Auxiliar 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Auxiliar 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Auxiliar 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Auxiliar 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Auxiliar 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Auxiliar 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Auxiliar 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Auxiliar 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Auxiliar 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Auxiliar 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Auxiliar 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Auxiliar 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Auxiliar 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Auxiliar 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Auxiliar 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Auxiliar 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Auxiliar 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Auxiliar 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Auxiliar 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Auxiliar 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Auxiliar 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Auxiliar 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Auxiliar 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Auxiliar 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Auxiliar 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Auxiliar 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Auxiliar 31"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Auxiliar 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Auxiliar 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Superior central"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Superior frontal central"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
-msgstr "Superior frontal central"
+msgstr "Superior frontal esquerra"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Superior frontal dreta"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Superior posterior central"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Superior posterior esquerra"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Superior posterior dreta"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(incorrecte)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Estèreo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Envolvent 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Envolvent 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Envolvent 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Envolvent 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Envolvent 7.1"
@@ -1256,29 +1149,37 @@ msgstr "Manca la implementació"
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr ""
+msgstr "Client bifurcat"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Error d'entrada/sortida"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Dispositiu o recurs ocupat"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1291,199 +1192,193 @@ msgstr "Ha fallat XOpenDisplay()"
msgid "Failed to parse cookie data"
msgstr "Ha fallat el parseig de les dades de la cookie"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "S'ha produït un error en obrir el fitxer de configuració '%s': %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "No s'ha carregat cap cookie. S'està intentant connectar sense aquesta."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
-msgstr "S'ha rebut un missatge per a l'extensió desconeguda '%s'"
+msgstr "S'ha rebut un missatge per a una extensió desconeguda '%s'"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "Ha fallat pa_stream_write(): %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "S'ha produït un error en drenar el fluxe: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "Ha fallat pa_stream_peek(): %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Flux de reproducció drenat."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Flux creat correctament.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "S'està drenant la connexió amb el servidor."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "Ha fallat pa_stream_get_buffer_attr(): %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Mètriques del búffer: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "Ha fallat pa_stream_write(): %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Mètriques del búffer: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "Ha fallat pa_stream_begin_write(): %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr ""
-"S'estan utilitzant les especificacions de mostreig '%s', mapejat del canal '%"
-"s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "Ha fallat pa_stream_peek(): %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "S'ha connectat al dispositiu %s (%u, %s suspés).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Flux creat correctament."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "S'ha produït un error en l'stream: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "Ha fallat pa_stream_get_buffer_attr(): %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Flux del dispositiu suspés.%s\n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Mètriques del búffer: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Flux del dispositiu représ.%s\n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Mètriques del búffer: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Dades insuficients al flux .%s\n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr ""
+"S'estan utilitzant les especificacions de mostreig '%s', mapejat del canal '%"
+"s'."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Desbordament de flux.%s\n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "S'ha connectat al dispositiu %s (%u, %ssuspès)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "S'ha iniciat el flux.%s\n"
+msgid "Stream error: %s"
+msgstr "S'ha produït un error en l'stream: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "S'ha mogut el flux al dispositiu %s (%u, %s suspés).%s\n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "no"
+msgid "Stream device suspended.%s"
+msgstr "Flux del dispositiu suspès.%s"
-#: ../src/utils/pacat.c:245
-#, fuzzy, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Dades insuficients al flux .%s\n"
-
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Connection established.%s \n"
-msgstr "S'ha establert la connexió.%s\n"
+msgid "Stream device resumed.%s"
+msgstr "Flux del dispositiu reprès.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "Ha fallat pa_stream_new(): %s\n"
+msgid "Stream underrun.%s"
+msgstr "Dades insuficients al flux.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "Ha fallat pa_stream_connect_playback(): %s\n"
+msgid "Stream overrun.%s"
+msgstr "Desbordament de flux.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "Ha fallat pa_stream_connect_record(): %s\n"
+msgid "Stream started.%s"
+msgstr "S'ha iniciat el flux.%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Ha fallat la connexió: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "S'ha mogut el flux al dispositiu %s (%u, %ssuspès).%s"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "S'ha produït un error en drenar el fluxe: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "no "
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Stream de reproducció drenat.\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Els atributs del flux de memòria intermèdia han canviat.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "S'està drenant la connexió amb el servidor.\n"
+msgid "Connection established.%s"
+msgstr "S'ha establert la connexió.%s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Got EOF.\n"
-msgstr "S'ha llegit EOF.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "Ha fallat pa_stream_new(): %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "Ha fallat pa_stream_connect_playback(): %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "read() failed: %s\n"
-msgstr "Ha fallat read(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "Ha fallat pa_stream_connect_record(): %s"
-#: ../src/utils/pacat.c:438
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "write() failed: %s\n"
-msgstr "Ha fallat write(): %s\n"
+msgid "Connection failure: %s"
+msgstr "Ha fallat la connexió: %s"
-#: ../src/utils/pacat.c:459
-#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "S'ha rebut un senyal, s'està sortint.\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "S'ha llegit el fi del fitxer."
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Ha fallat en obtenir la latència: %s\n"
+msgid "write() failed: %s"
+msgstr "Ha fallat write(): %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "S'ha rebut un senyal, s'està sortint."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Temps: %0.3f segs; Latència: %0.0f microsegs.\r"
+msgid "Failed to get latency: %s"
+msgstr "No s'ha pogut obtenir la latència: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "Ha fallat pa_stream_update_timing_info(): %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Temps: %0.3f segs; Latència: %0.0f microsegs."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "Ha fallat pa_stream_update_timing_info(): %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1509,8 +1404,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1533,6 +1430,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [opcions]\n"
"\n"
@@ -1552,7 +1458,8 @@ msgstr ""
"connectar-se\n"
" -n, --client-name=NOM Com cridar aquest client al "
"servidor\n"
-" --stream-name=NOM Com cridar aquest flux al servidor\n"
+" --stream-name=NOM Com cridar aquest flux de dades al "
+"servidor\n"
" --volume=VOLUM Especifica el volum inicial lineal "
"dins el rang 0...65536\n"
" --rate=VELOCITATMOSTREIG La velocitat de mostreig en Hz (per "
@@ -1565,7 +1472,7 @@ msgstr ""
"per a estèreo\n"
" (per omissió, 2)\n"
" --channel-map=MAPACANAL Mapa de canals a utilitzar\n"
-" --fix-format Pren el format de mostra del "
+" --format-fix Pren el format de mostra del "
"conducte al qual s'està connectant\n"
" el flux.\n"
" --fix-rate Pren la velocitat de mostreig del "
@@ -1574,15 +1481,23 @@ msgstr ""
" --fix-channels Pren el número de canals i el mapa "
"de canals del\n"
" conducte al qual s'està connectant "
-"el flux.\n"
-" --no-remix No mesclar els canals.\n"
-" --no-remap Mapeja els canals per índex enlloc "
-"de per nom .\n"
-" --latency=BYTES Especifica la latència en bytes.\n"
-" --process-time=BYTES Especifica el temps de procés per "
+"el flux de dades.\n"
+" --no-remix No barregis els canals.\n"
+" --no-remap Mapeja els canals per índex en "
+"comptes de per nom .\n"
+" --latencia=BYTES Sol·licita la latència en bytes.\n"
+" --process-time=BYTES Sol·licita el temps de procés per "
"petició en bytes.\n"
+" --property=PROPIETAT=VALOR Establir la propietat especificada "
+"per al valor especificat.\n"
+" --raw Gravació/reproducció de dades crues "
+"PCM.\n"
+" --format-fitxer=FFORMAT Gravació/reproducció de dades amb "
+"format PCM.\n"
+" --list-file-formats Llista disponible de formats de "
+"fitxer.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1590,132 +1505,177 @@ msgid ""
"Linked with libpulse %s\n"
msgstr ""
"pacat %s\n"
-"Compil·lat amb libpulse %s\n"
+"Compilat amb libpulse %s\n"
"Enllaçat amb libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Mapa de canals invàlid '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "Nom del client invàlid '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Especificació de latència invàlida '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "Nom de flux de dades invàlid '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Especificació de temps de procés invàlida '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "Mapa de canals invàlid '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Especificació de mostra invàlida\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Especificació de latència invàlida '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "El mapa de canals no coincideix amb l'especificació de mostra\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Especificació de temps de procés invàlida '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "S'està obrint un flux %s amb especificació de mostra '%s'.\n"
+msgid "Invalid property '%s'"
+msgstr "Propietat invàlida '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "enregistrant"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Format desconegut de fitxer %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "reproducció"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Especificació de mostra invàlida"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Hi han massa arguments.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Massa arguments."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "Ha fallat pa_mainloop_new().\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "No s'ha pogut generar l'especificació de mostra del fitxer."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "Ha fallat io_new().\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "No s'ha pogut obrir el fitxer d'àudio."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "Ha fallat pa_context_new().\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Advertència: l'especificació de mostra especificada se sobreescriurà amb "
+"l'especificació del fitxer."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "Ha fallat pa_context_connect(): %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "No s'ha pogut determinar l'especificació de mostra del fitxer."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr ""
+"Advertència: no s'ha pogut determinar el mapeig de canals des del fitxer."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "El mapa de canals no coincideix amb l'especificació de mostra"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Advertència: no s'ha pogut escriure el mapa de canals en un fitxer."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "Ha fallat time_new().\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"S'està obrint un flux de dades %s amb especificació de mostra '%s' i mapa de "
+"canals '%s'."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "enregistrant"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "reproducció"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "Ha fallat el pa_mainloop_new()."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "Ha fallat el io_new()."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "Ha fallat el pa_context_new()."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "Ha fallat pa_mainloop_run().\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "Ha fallat pa_context_connect(): %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "Ha fallat el pa_context_new()."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "Ha fallat el pa_mainloop_run()."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
-msgstr "Ha fallat en susprendre: %s\n"
+msgstr "No s'ha pogut suspendre: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
-msgstr "Ha fallat en reprendre: %s\n"
+msgstr "No s'ha pogut en rependre: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "ADVERTÈNCIA: el sevidor de so no és local, no s'està suspenent.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Ha fallat la connexió: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "S'ha rebut SIGINT, s'està sortint.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
-msgstr "ADVERTÈNCIA: Procés fill acabat per senyal %u\n"
+msgstr "ADVERTÈNCIA: procés fill acabat pel senyal %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1734,7 +1694,7 @@ msgstr ""
"se\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1742,39 +1702,66 @@ msgid ""
"Linked with libpulse %s\n"
msgstr ""
"pasuspender %s\n"
-"Compil·lat amb libpulse %s\n"
+"Compilat amb libpulse %s\n"
"Enllaçat amb libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Ha fallat en obtenir les estadístiques: %s\n"
+msgid "pa_mainloop_new() failed.\n"
+msgstr "Ha fallat el pa_mainloop_new().\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "Ha fallat el pa_context_new().\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "Ha fallat el pa_mainloop_run().\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "No s'han pogut obtenir les estadístiques: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
-msgstr "Actualment s'estan utilitzant: %u blocs contenent %s bytes en total.\n"
+msgstr ""
+"Actualment s'estan utilitzant: %u blocs que contenen %s bytes en total.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
-"Allotjats durant el temps de vida: %u blocs contenent %s bytes en total.\n"
+"Allotjats durant el temps de vida: %u blocs que contenen %s bytes en total.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
-msgstr "Mida de memòria cau de mostra: %s\n"
+msgstr "Mida de la memòria cau de mostres: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Ha fallat en obtenir la informació del servidor: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "No s'ha pogut obtenir la informació del servidor: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1782,7 +1769,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Nom d'usuari: %s\n"
"Nom del host: %s\n"
@@ -1792,14 +1779,14 @@ msgstr ""
"Mapa de canals per omissió: %s\n"
"Conducte per omissió: %s\n"
"Font per omissió: %s\n"
-"Cookie: %08x\n"
+"Galeta: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Ha fallat en obtenir la informació del conducte: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "No s'ha pogut obtenir la informació del conducte: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1838,12 +1825,22 @@ msgstr ""
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorts:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tPort actiu: %s\n"
+
+#: ../src/utils/pactl.c:310
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Ha fallat en obtenir la informació de la font: %s\n"
+msgid "Failed to get source information: %s"
+msgstr "No s'ha pogut obtenir la informació de la font: %s"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1882,20 +1879,20 @@ msgstr ""
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
-msgstr "n/d"
+msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Ha fallat en obtenir informació del mòdul: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "No s'ha pogut obtenir informació del mòdul: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1912,12 +1909,12 @@ msgstr ""
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Ha fallat en obtenir informació: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "No s'ha pogut obtenir informació del client: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1932,12 +1929,12 @@ msgstr ""
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Ha fallat en obtenir la informació de la targeta: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "No s'ha pogut obtenir la informació de la targeta: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1954,22 +1951,22 @@ msgstr ""
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tPerfils:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tPerfil actiu: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Ha fallat en obtenir informació del conducte d'entrada: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "No s'ha pogut obtenir informació del conducte d'entrada: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1999,19 +1996,19 @@ msgstr ""
"\tSilenciat: %s\n"
"\tVolum: %s\n"
"\t %s\n"
-"\t balacenig %0.2f\n"
+"\t balanç %0.2f\n"
"\tLatència de búffer: %0.0f microsegs.\n"
"\tLatència del conducte: %0.0f microsegs.\n"
"\tMètode de remostreig: %s\n"
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Ha fallat en obtenir la informació del conducte de sortida: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "No s'ha pogut obtenir la informació del conducte de sortida: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2040,12 +2037,12 @@ msgstr ""
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Ha fallat en obtenir informació de la mostra: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "No s'ha pogut obtenir informació de la mostra: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2076,23 +2073,81 @@ msgstr ""
"\tPropietats:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Ha fallat: %s\n"
+msgid "Failure: %s"
+msgstr "Ha fallat: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Ha fallat en pujar la mostra: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "No s'ha pogut pujar la mostra: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "S'ha trobat un fi de fitxer prematurament\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "S'ha trobat un fi de fitxer prematurament"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr "conducte"
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr "font"
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+#, fuzzy
+msgid "source-output"
+msgstr "font"
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Servidor incorrecte"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "S'ha rebut SIGINT, s'està sortint."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2100,13 +2155,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2122,23 +2186,30 @@ msgstr ""
"%s [opcions] upload-sample NOMFITXER [NOM]\n"
"%s [opcions] play-sample NOM [CONDUCTE]\n"
"%s [opcions] remove-sample NOM\n"
-"%s [opcions] move-sink-input ID CONDUCTE\n"
-"%s [opcions] move-source-output ID FONT\n"
-"%s [opcions] load-module NOM [ARGS ...]\n"
-"%s [opcions] unload-module ID\n"
-"%s [opcions] suspend-sink [CONDUCTE] 1|0\n"
-"%s [opcions] suspend-source [FONT] 1|0\n"
-"%s [opcions] set-card-profile [TARGETA] [PERFIL] \n"
+"%s [opcions] move-sink-input CONDUCTEENTRADA CONDUCTE\n"
+"%s [opcions] move-source-output FONTSORTIDA FONT\n"
+"%s [opcions] load-module NOM [ARGUMENTS ...]\n"
+"%s [opcions] unload-module MÃ’DUL\n"
+"%s [opcions] suspend-sink CONDUCTE 1|0\n"
+"%s [opcions] suspend-source FONT 1|0\n"
+"%s [opcions] set-card-profile TARGETA PERFIL \n"
+"%s [opcions] set-sink-port CONDUCTE PORT \n"
+"%s [opcions] set-source-port FONT PORT \n"
+"%s [options] set-sink-volume CONDUCTE VOLUM\n"
+"%s [options] set-source-volume FONT VOLUM\n"
+"%s [options] set-sink-input-volume CONDUCTEENTRADA VOLUM\n"
+"%s [options] set-sink-mute CONDUCTE 1|0\n"
+"%s [options] set-source-mute FONT 1|0\n"
+"%s [options] set-sink-input-mute CONDUCTEENTRADA 1|0\n"
"\n"
" -h, --help Mostra aquesta ajuda\n"
" --version Mostra la versió\n"
"\n"
-" -s, --server=SERVIDOR Nom del servidor al qual connectar-"
-"se\n"
-" -n, --client-name=NOM Com cridar aquest client al "
+" -s, --server=SERVIDOR Nom del servidor on connectar-s'hi\n"
+" -n, --client-name=NOM Com cridar aquest client en el "
"servidor\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2149,77 +2220,113 @@ msgstr ""
"Compilat amb libpulse %s\n"
"Enllaçat amb libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Especifiqueu un fitxer de mostra per a carregar\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Si us plau, especifiqueu un fitxer de mostra per a carregar"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Ha fallat en obrir el fitxer de so.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "No s'ha pogut obrir el fitxer de so."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Heu d'especificar un nom de mostra a reproduir\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+"Advertiment: No s'ha pogut determinar l'especificació de mostra a partir del "
+"fitxer."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Heu d'especificar un nom de mostra a esborrar\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Heu d'especificar un nom de mostra a reproduir"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Heu d'especificar una entrada del conducte i un conducte\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Heu d'especificar un nom de mostra a suprimir"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Heu d'especificar una font de sortida i una font\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Heu d'especificar una entrada del conducte i un conducte"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Heu d'especificar un nom de mòdul i els seus arguments.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Heu d'especificar un índex de font de sortida i una font"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Heu d'especificar un índex de mòdul\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Heu d'especificar un nom de mòdul i els seus arguments."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Heu d'especificar un índex de mòdul"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"No haríeu d'especificar més d'un conducte. Heu d'especifcar un valor "
-"booleà.\n"
+"No haríeu d'especificar més d'un conducte. Heu d'especificar un valor booleà."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"No haríeu d'especificar més d'una font. Heu d'especificar un valor booleà.\n"
+"No haríeu d'especificar més d'una font. Heu d'especificar un valor booleà."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Heu d'especificar un nom o un índex de targeta i un nom de perfil\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Heu d'especificar un nom o un índex de targeta i un nom de perfil"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "S'ha especificat una ordre invàlida.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Heu d'especificar un nom o un índex de conducte i un nom de port"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "Ha fallat pa_context_connect(): %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Heu d'especificar un nom o un índex de font i un nom de port"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Heu d'especificar un nom o un índex de conducte i un volum"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Especificació de volum invàlida"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Heu d'especificar un nom o un índex de font i un volum"
+
+#
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Heu d'especificar un índex entrada del conducte i un volum"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ãndex d'entrada del conducte invàlid"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+"Heu d'especificar un nom o un índex de conducte i un booleà de silenciat"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Heu d'especificar un nom o un índex de font i un booleà de silenciat"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+"Heu d'especificar un índex d'entrada del conducte i un booleà de silenciat"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Especificació d'índex d'entrada del conducte invàlida"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Ordre especificada no vàlida."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2245,7 +2352,7 @@ msgstr ""
#: ../src/utils/pax11publish.c:94
#, c-format
msgid "Failed to parse command line.\n"
-msgstr "Ha fallat en parsejar la línia de comandes.\n"
+msgstr "No s'ha pogut analitzar la línia d'ordres.\n"
#: ../src/utils/pax11publish.c:108
#, c-format
@@ -2265,191 +2372,87 @@ msgstr "Conducte: %s\n"
#: ../src/utils/pax11publish.c:114
#, c-format
msgid "Cookie: %s\n"
-msgstr "Cookie: %s\n"
+msgstr "Galeta: %s\n"
#: ../src/utils/pax11publish.c:132
#, c-format
msgid "Failed to parse cookie data\n"
-msgstr "Ha fallat en parsejar les dades de la cookie\n"
+msgstr "No s'han pogut parsejar les dades de la galeta\n"
#: ../src/utils/pax11publish.c:137
#, c-format
msgid "Failed to save cookie data\n"
-msgstr "Ha fallat en desar les dades de la cookie\n"
+msgstr "No s'han pogut desar les dades de la galeta\n"
#: ../src/utils/pax11publish.c:152
#, c-format
msgid "Failed to load client configuration file.\n"
-msgstr "Ha fallat en carregar el fitxer de configuració del client.\n"
+msgstr "No s'ha pogut carregar el fitxer de configuració del client.\n"
#: ../src/utils/pax11publish.c:157
#, c-format
msgid "Failed to read environment configuration data.\n"
-msgstr "Ha fallat en llegir les dades de configuració de l'entorn.\n"
+msgstr "No s'han pogut llegir les dades de configuració de l'entorn.\n"
#: ../src/utils/pax11publish.c:174
#, c-format
msgid "Failed to get FQDN.\n"
-msgstr "Ha fallat en obtenir FQDN.\n"
+msgstr "No s'ha pogut obtenir el nom de domini qualificat complet.\n"
#: ../src/utils/pax11publish.c:194
#, c-format
msgid "Failed to load cookie data\n"
-msgstr "Ha fallat en carregar les dades de la cookie\n"
+msgstr "No s'han pogut carregar les dades de la galeta\n"
#: ../src/utils/pax11publish.c:211
#, c-format
msgid "Not yet implemented.\n"
-msgstr "No s'ha implementat encara.\n"
+msgstr "Encara no s'ha implementat.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"El dimoni PulseAudio no s'està executant, o no s'està executant com a dimoni "
+"de la sessió."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
-msgstr "Ha fallat en matar el dimoni PulseAudio."
+msgstr "No s'ha pogut matar el dimoni PulseAudio."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "El dimoni no respon."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Flux creat amb èxit\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "S'ha produït un error en el flux: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "S'ha establert la connexió.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [opcions] [FITXER]\n"
-"\n"
-" -h, --help Mostra aquesta ajuda\n"
-" --version Mostra la versió\n"
-"\n"
-" -v, --verbose Habilita les operacions detallades\n"
-"\n"
-" -s, --server=SERVIDOR Nom del servidor al qual connectar-"
-"se\n"
-" -d, --device=DISPOSITIU Nom del conducte/font al qual "
-"connectar-se\n"
-" -n, --client-name=NOM Com cridar aquest client al "
-"servidor\n"
-" --stream-name=NOM Com cridar aquest flux al servidor\n"
-" --volume=VOLUM Especifica el volum inicial lineal "
-"dins el rang 0...65536\n"
-" --rate=VELOCITATMOSTREIG La velocitat de mostreig en Hz (per "
-"omissió, 44100)\n"
-" --format=FORMATMOSTRA El tipus de mostra, una de s16le, "
-"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(per omissió, s16ne)\n"
-" --channels=CANALS Número de canals, 1 per a mono, 2 "
-"per a estèreo\n"
-" (per omissió, 2)\n"
-" --channel-map=MAPACANAL Mapa de canals a utilitzar\n"
-" --fix-format Pren el format de mostra del "
-"conducte al qual s'està connectant\n"
-" el flux.\n"
-" --fix-rate Pren la velocitat de mostreig del "
-"conducte al qual\n"
-" s'està connectant el flux.\n"
-" --fix-channels Pren el número de canals i el mapa "
-"de canals del\n"
-" conducte al qual s'està connectant "
-"el flux.\n"
-" --no-remix No mesclar els canals.\n"
-" --no-remap Mapeja els canals per índex enlloc "
-"de per nom .\n"
-" --latency=BYTES Especifica la latència en bytes.\n"
-" --process-time=BYTES Especifica el temps de procés per "
-"petició en bytes.\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Compil·lat amb libpulse %s\n"
-"Enllaçat amb libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Mapa de canals invàlid\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Ha fallat en obrir el fitxer '%s'\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "El mapa de canals no coincideix amb el fitxer.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "S'estan utilitzant les especificacions de mostra '%s'\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "No s'ha pogut accedir al bloqueig d'autospawn."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2459,8 +2462,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA ens ha despertat per a escriure dades noves al dispositiu però no hi "
+"havia res a escriure!\n"
+"Probablement es tracta d'un error del controlador de l'ALSA '%s'. Informeu "
+"d'aquest problema als desenvolupadors de l'ALSA.\n"
+"Ens han aixecat amb POLLOUT activat -- tanmateix una crida posterior a "
+"snd_pcm_avail() ha retornat 0 o un altre valor < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2470,39 +2479,529 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"Alsa ens ha cridat per a llegir dades noves del dispositiu, però no hi ha "
+"res a llegir!\n"
+"Probablement es tracta d'un error de la controladora '%s' de l'ALSA. "
+"Reporteu aquest problema als desenvolupadors de l'ALSA.\n"
+"Ens han aixecat amb POLLIN activat -- tanmateix una crida posterior a "
+"snd_pcm_avail() ha retornat 0 o un altre valor < min_avail."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "Inactiu"
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "Reproducció d'alta fidelitat (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Captura d'alta fidelitat (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Dúplex de telefonia (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "Servidor de so PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+#, fuzzy
+msgid "Input Devices"
+msgstr "Entrada %s"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
-msgid "Off"
+#: ../src/modules/alsa/alsa-mixer.c:1701
+#, fuzzy
+msgid "Input"
+msgstr "Entrada %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
-msgid "High Fidelity Playback (A2DP)"
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
-msgid "Telephony Duplex (HSP/HFP)"
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
#, fuzzy
-msgid "PulseAudio Sound Server"
-msgstr "Sistema de so PulseAudio"
+msgid "Internal Microphone"
+msgstr "Audio intern"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+msgid "Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+msgid "No Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+#, fuzzy
+msgid "Analog Input"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+#, fuzzy
+msgid "Analog Microphone"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+#, fuzzy
+msgid "Analog Line-In"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+#, fuzzy
+msgid "Analog Radio"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+#, fuzzy
+msgid "Analog Video"
+msgstr "Estèreo analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+#, fuzzy
+msgid "Analog Output"
+msgstr "Sortida nul·la"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+#, fuzzy
+msgid "Analog Headphones"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+#, fuzzy
+msgid "Analog Mono Output"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Estèreo analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, fuzzy, c-format
+msgid "%s+%s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, fuzzy, c-format
+msgid "%s / %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Estèreo analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+#, fuzzy
+msgid "Analog Surround 2.1"
+msgstr "Envolvent analògic 4.1 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+#, fuzzy
+msgid "Analog Surround 3.0"
+msgstr "Envolvent analògic 4.0 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+#, fuzzy
+msgid "Analog Surround 3.1"
+msgstr "Envolvent analògic 4.1 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Envolvent analògic 4.0 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Envolvent analògic 4.1 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Envolvent analògic 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Envolvent analògic 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+#, fuzzy
+msgid "Analog Surround 6.0"
+msgstr "Envolvent analògic 4.0 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+#, fuzzy
+msgid "Analog Surround 6.1"
+msgstr "Envolvent analògic 4.1 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+#, fuzzy
+msgid "Analog Surround 7.0"
+msgstr "Envolvent analògic 4.0 "
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Envolvent analògic 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Estèreo digital (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+#, fuzzy
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Envolvent digital 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Envolvent digital 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Envolvent digital 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Estèreo digital (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+#, fuzzy
+msgid "Analog Mono Duplex"
+msgstr "Mono analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+#, fuzzy
+msgid "Analog Stereo Duplex"
+msgstr "Estèreo analògic"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+#, fuzzy
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Estèreo digital (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Emissor de baixa freqüència"
+
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Nom del client invàlid '%s'\n"
+
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr "No s'ha pogut determinar l'especificació de mostra del fitxer.\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "No s'ha pogut connectar al bus del sistema: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "No s'ha pogut obtenir una crida del PID: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "No s'ha pogut especificar l'UID en l'objecte crida."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "No s'ha pogut obtenir la sessió CK."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "No s'ha pogut definir l'UID en l'objecte sessió."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "No s'ha pogut assignar PolKitAction."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "No s'ha pogut definir action_id"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "No s'ha pogut assignar PolKitContext."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "No s'ha pogut inicialitzar PolKitContext: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "No s'ha pogut determinar si la crida està autoritzada: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "No s'ha pogut obtenir l'autorització: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit ha respós '%s'"
+
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Programació d'alta prioritat (nivell Unix nice negatiu) per al dimoni "
+#~ "PulseAudio"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Programació en temps real per al dimoni PulseAudio"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "Les normes d'ús del sistema no permeten PulseAudio adquirir programació "
+#~ "d'alta prioritat."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "Les normes d'ús del sistema no permeten la programació en temps real de "
+#~ "PulseAudio."
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "Ha fallat read(): %s\n"
+
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "Ha fallat el pa_context_connect(): %s\n"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr ""
+#~ "Aquesta aplicació està en el grup '%s', s'està establint la prioritat "
+#~ "alta."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr ""
+#~ "Aquesta aplicació està en el grup '%s', s'està establint la prioritat en "
+#~ "temps real."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr "PolicyKit ha permés el privilegi acquire-high-priority."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "PolicyKit ha rebutjat el privilegi acquire-high-priority."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "PolicyKit ha permés el privilegi acquire-real-time."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "PolicyKit ha rebutjat el privilegi acquire-real-time."
+
+#~ msgid ""
+#~ "Called SUID root and real-time and/or high-priority scheduling was "
+#~ "requested in the configuration. However, we lack the necessary "
+#~ "privileges:\n"
+#~ "We are not in group '%s', PolicyKit refuse to grant us the requested "
+#~ "privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
+#~ "limits.\n"
+#~ "For enabling real-time/high-priority scheduling please acquire the "
+#~ "appropriate PolicyKit privileges, or become a member of '%s', or increase "
+#~ "the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+#~ msgstr ""
+#~ "S'ha demanat SUID de root i una planificació de temps real i/o d'alta "
+#~ "prioritat. Tanmateix, falten els privilegis necessaris:\n"
+#~ "No es pertany al grup '%s'. PolicyKit no atorga els privilegis demanats i "
+#~ "no s'ha incrementat els límits de recursos RLIMIT_NICE/RLIMIT_RTPRIO.\n"
+#~ "Per habilitar la planificació en temps real o d'alta prioritat, heu "
+#~ "d'obtenir els privilegis de PolicyKit adequats, o pertànyer al grup '%s', "
+#~ "o incrementar els límits de recursos de RLIMIT_NICE/RLIMIT_RTPRIO per a "
+#~ "aquest usuari."
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "La prioritat alta està habilitada en la configuració però no està permesa "
+#~ "per la política."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "S'ha incrementat el valor de RLIMIT_RTPRIO amb éxit."
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "S'ha produït un error amb RLIMIT_RTPRIO: %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "S'abandona CAP_NICE"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "La prioritat de temps real està habilitada en la configuració però no "
+#~ "està permesa per la política."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "S'han limitat les capacitats cap a CAP_SYS_NICE."
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "Ha fallat el time_new().\n"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Flux creat amb èxit\n"
+
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "S'ha produït un error en el flux: %s\n"
+
+#~ msgid "Connection established.\n"
+#~ msgstr "S'ha establert la connexió.\n"
+
+#~ msgid ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Show this help\n"
+#~ " --version Show version\n"
+#~ "\n"
+#~ " -v, --verbose Enable verbose operation\n"
+#~ "\n"
+#~ " -s, --server=SERVER The name of the server to connect "
+#~ "to\n"
+#~ " -d, --device=DEVICE The name of the sink to connect "
+#~ "to\n"
+#~ " -n, --client-name=NAME How to call this client on the "
+#~ "server\n"
+#~ " --stream-name=NAME How to call this stream on the "
+#~ "server\n"
+#~ " --volume=VOLUME Specify the initial (linear) "
+#~ "volume in range 0...65536\n"
+#~ " --channel-map=CHANNELMAP Set the channel map to the use\n"
+#~ msgstr ""
+#~ "%s [opcions] [FITXER]\n"
+#~ "\n"
+#~ " -h, --help Mostra aquesta ajuda\n"
+#~ " --version Mostra la versió\n"
+#~ "\n"
+#~ " -v, --verbose Habilita les operacions "
+#~ "detallades\n"
+#~ "\n"
+#~ " -s, --server=SERVIDOR Nom del servidor al qual "
+#~ "connectar-se\n"
+#~ " -d, --device=DISPOSITIU Nom del conducte al qual "
+#~ "connectar-se\n"
+#~ " -n, --client-name=NOM Com cridar aquest client al "
+#~ "servidor\n"
+#~ " --stream-name=NOM Com cridar aquest flux al "
+#~ "servidor\n"
+#~ " --volume=VOLUM Especifica el volum inicial "
+#~ "(lineal) dins el rang 0...65536\n"
+#~ " --rate=VELOCITATMOSTREIG La velocitat de mostreig en Hz "
+#~ "(per omissió, 44100)\n"
+#~ " --format=FORMATMOSTRA El tipus de mostra, una de s16le, "
+#~ "s16be, u8, float32le,\n"
+#~ " float32be, ulaw, alaw, s32le, "
+#~ "s32be (per omissió, s16ne)\n"
+#~ " --channels=CANALS Número de canals, 1 per a mono, 2 "
+#~ "per a estèreo\n"
+#~ " (per omissió, 2)\n"
+#~ " --channel-map=MAPACANAL Mapa de canals a utilitzar\n"
+#~ " --fix-format Pren el format de mostra del "
+#~ "conducte al qual s'està connectant\n"
+#~ " el flux.\n"
+#~ " --fix-rate Pren la velocitat de mostreig del "
+#~ "conducte al qual\n"
+#~ " s'està connectant el flux.\n"
+#~ " --fix-channels Pren el número de canals i el "
+#~ "mapa de canals del\n"
+#~ " conducte al qual s'està "
+#~ "connectant el flux.\n"
+#~ " --no-remix No mesclar els canals.\n"
+#~ " --no-remap Mapeja els canals per índex "
+#~ "enlloc de per nom .\n"
+#~ " --latency=BYTES Especifica la latència en bytes.\n"
+#~ " --process-time=BYTES Especifica el temps de procés per "
+#~ "petició en bytes.\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Compilat amb libpulse %s\n"
+#~ "Enllaçat amb libpulse %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Mapa de canals invàlid\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "No s'ha pogut obrir el fitxer '%s'\n"
+
+#~ msgid "Channel map doesn't match file.\n"
+#~ msgstr "El mapa de canals no coincideix amb el fitxer.\n"
+
+#~ msgid "Using sample spec '%s'\n"
+#~ msgstr "S'estan utilitzant les especificacions de mostra '%s'\n"
+
+#~ msgid "Output %s + Input %s"
+#~ msgstr "Sortida %s + Entrada %s"
#~ msgid ""
#~ "Called SUID root and real-time/high-priority scheduling was requested in "
@@ -2555,9 +3054,3 @@ msgstr "Sistema de so PulseAudio"
#~ "Tipus: %s\n"
#~ "Mòdul: %s\n"
#~ "Arguments: %s\n"
-
-#~ msgid "sink"
-#~ msgstr "conducte"
-
-#~ msgid "source"
-#~ msgstr "font"
diff --git a/po/cs.po b/po/cs.po
index f42c8553..b9a713cf 100644
--- a/po/cs.po
+++ b/po/cs.po
@@ -1,67 +1,27 @@
# Czech translation of pulseaudio.
-# Copyright (C) 2008 the author(s) of pulseaudio.
+# Copyright (C) 2008, 2009 the author(s) of pulseaudio.
# This file is distributed under the same license as the pulseaudio package.
-# Petr Kovar <pknbe@volny.cz>, 2008.
-#
+# Petr Kovar <pknbe@volny.cz>, 2008, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio\n"
+"Project-Id-Version: pulseaudio.master-tx\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2008-10-19 22:31+0200\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-17 17:08+0200\n"
"Last-Translator: Petr Kovar <pknbe@volny.cz>\n"
"Language-Team: Czech <translation-team-cs@lists.sourceforge.net>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Generator: KBabel 1.11.4\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
+"X-Generator: Lokalize 1.0\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr ""
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -69,8 +29,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_avail() navrátil hodnotu, která je nezvykle vysoká: %lu bajtů (%lu "
+"ms).\n"
+"S nejvÄ›tší pravdÄ›podobností se jedná o chybu v ovladaÄi ALSA \"%s\". "
+"Nahlaste prosím tento problém vývojářům ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -78,8 +42,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_delay() navrátil hodnotu, která je nezvykle vysoká: %li bajtů (%s%lu "
+"ms).\n"
+"S nejvÄ›tší pravdÄ›podobností se jedná o chybu v ovladaÄi ALSA \"%s\". "
+"Nahlaste prosím tento problém vývojářům ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -87,235 +55,157 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_mmap_begin() navrátil hodnotu, která je nezvykle vysoká: %lu bajtů (%"
+"lu ms).\n"
+"S nejvÄ›tší pravdÄ›podobností se jedná o chybu v ovladaÄi ALSA \"%s\". "
+"Nahlaste prosím tento problém vývojářům ALSA."
-#: ../src/pulsecore/sink.c:2141
-#, fuzzy
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Udržuje nahraný vždy alespoň jeden cíl, i když se jedná o \"null\""
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Prázdný výstup"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Virtuální cíl LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<název cíle> sink_properties=<vlastnosti cíle> master=<název "
+"filtrovaného cíle> format=<vzorkovací formát> rate=<vzorkovací frekvence> "
+"channels=<poÄet kanálů> channel_map=<mapa kanálů> plugin=<název zásuvného "
+"modulu ladspa> label=<popisek zásuvného modulu ladspa> control=<Äárkou "
+"oddělený seznam hodnot ovládání vstupu>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Taktovaný cíl NULL"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Výstup \"null\""
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
-msgstr "Vnitřní chyba"
+msgstr "Vnitřní zvukový systém"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
-msgstr ""
+msgstr "Modem"
#: ../src/daemon/ltdl-bind-now.c:124
-#, fuzzy
msgid "Failed to find original lt_dlopen loader."
-msgstr "Nezdařilo se nalezení původního nahrávacího programu dlopen."
+msgstr "Nezdařilo se nalézt původní nahrávací program lt_dlopen."
#: ../src/daemon/ltdl-bind-now.c:129
-#, fuzzy
msgid "Failed to allocate new dl loader."
-msgstr "Nezdařilo se nalezení původního nahrávacího programu dlopen."
+msgstr "Nezdařilo se přidělení nového nahrávacího programu dl."
#: ../src/daemon/ltdl-bind-now.c:142
msgid "Failed to add bind-now-loader."
msgstr "Nezdařilo se přidat bind-now-loader."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Nelze se spojit se systémovou sběrnicí: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Nelze získat volajícího z PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Nelze nastavit UID na objekt volajícího."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Nezdařilo se získání sezení CK."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Nelze nastavit UID na objekt sezení."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Nelze alokovat PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Nelze nastavit action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Nelze alokovat PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Nelze spustit PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "NezdaÅ™ilo se urÄit, zda je volající oprávnÄ›n: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Nezdařilo se získat oprávnění: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit odpověděl s \"%s\""
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Získán signál %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "UkonÄování."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Nezdařilo se nalézt uživatele \"%s\"."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Nezdařilo se nalézt skupinu \"%s\"."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Nalezen uživatel \"%s\" (UID %lu) a skupina \"%s\" (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID uživatele \"%s\" a skupiny \"%s\" nesouhlasí."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Domovský adresář uživatele \"%s\" není \"%s\", bude ignorováno."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Nezdařilo se vytvořit \"%s\": %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Nezdařilo se změnit seznam skupin: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Nezdařilo se změnit GID: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Nezdařilo se změnit UID: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Oprávnění superuživatele úspěšně zrušena."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "Režim celého systému není na této platformě podporován."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) selhalo: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Nezdařila se analýza příkazového řádku."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Nacházíme se ve skupině \"%s\", což umožňuje plánování o vysoké prioritě."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "Nacházíme se ve skupinÄ› \"%s\", což umožňuje plánování v reálném Äase."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit nám udělil oprávnění acquire-high-priority."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit nám neudělil oprávnění acquire-high-priority."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit nám udělil oprávnění acquire-real-time."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit nám neudělil oprávnění acquire-real-time."
-
-#: ../src/daemon/main.c:556
-#, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Plánování o vysoké prioritě v konfiguraci zapnuto, ale nepovoleno pravidly."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "Úspěšně zvýšeno RLIMIT_RTPRIO"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO selhalo: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Vzdávání se CAP_NICE"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Plánování v reálném Äase v konfiguraci zapnuto, ale nepovoleno pravidly."
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Démon neběží"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Démon běží jako PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Zabití démona se nezdařilo: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -323,160 +213,195 @@ msgstr ""
"Tento program není urÄen ke spuÅ¡tÄ›ní pod superuživatelem (není-li zadáno --"
"system)."
-#: ../src/daemon/main.c:720
-#, fuzzy
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Jsou vyžadována oprávnění superuživatele."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start nepodporováno u systémových instancí."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "Běží v systémovém režimu, ale nenastaveno --disallow-exit!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "Běží v systémovém režimu, ale nenastaveno --disallow-module-loading!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "Běží v systémovém režimu, vynuceně se vypíná režim SHM!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr "Běží v systémovém režimu, vynucenÄ› se vypíná Äas neÄinnosti ukonÄení!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Nezdařilo se získání stdio."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "pipe selhalo: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() selhalo: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() selhalo: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Spuštění démona selhalo."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Spuštění démona bylo úspěšné."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() selhalo: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Toto je PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "PÅ™ekladový poÄítaÄ: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "Překladové CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Běží na poÄítaÄi: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
-msgstr ""
+msgstr "Nalezen následující poÄet CPU: %u."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "Velikost stránky je %lu bajtů"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Přeloženo s podporou Valgrind: ano"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Přeloženo s podporou Valgrind: ne"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Běží v režimu valgrind: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Běží na poÄítaÄi: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Optimalizované sestavení: ano"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Optimalizované sestavení: ne"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr ""
+msgstr "NDEBUG definováno, všechny výrazy zakázány."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
-msgstr ""
+msgstr "FASTPATH definováno, zakázány pouze výrazy rychlých cest."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr ""
+msgstr "Všechny výrazy povoleny."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "NezdaÅ™ilo se získání ID poÄítaÄe"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "ID poÄítaÄe je %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "ID poÄítaÄe je %s."
+msgstr "ID sezení je %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Používán běhový adresář %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Používán stavový adresář %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Používán adresář modulů %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Běží v systémovém režimu: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"Dobrá, máte tedy PA spuštěn v systémovém režimu. Vemte prosím na vědomí, že "
+"k tomuto by až na výjimeÄné situace nÄ›melo docházet.\n"
+"Pokud v této Äinnosti pÅ™esto budete pokraÄovat, nesete riziko za možné "
+"špatné a nepředvídatelné chování systému.\n"
+"VysvÄ›tlení, proÄ je systémový režim obvykle velmi Å¡patný nápad, si můžete "
+"pÅ™eÄíst na http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() selhalo."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr ""
"Jsou dostupné výteÄné ÄasovaÄe o vysokém rozliÅ¡ení. Tak s chutí do toho!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -484,32 +409,32 @@ msgstr ""
"Sorry, vole, kernel error! Tip šéfkuchaře na dnešní den zní: Linux se "
"zapnutými ÄasovaÄi o vysokém rozliÅ¡ení."
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() selhalo."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Selhalo spuštění démona."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Spuštění démona bez jakýchkoliv nahraných modulů, běh bude odmítnut."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "SpuÅ¡tÄ›ní démona dokonÄeno."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Vypínání démona spuštěno."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Démon ukonÄen."
-#: ../src/daemon/cmdline.c:121
-#, fuzzy, c-format
+#: ../src/daemon/cmdline.c:115
+#, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -581,62 +506,88 @@ msgid ""
"\n"
" -n Don't load default script file\n"
msgstr ""
-"s n\n"
-" h nápověda Zob_razit nápověda\n"
-" verze Zobrazit verze\n"
-" implicitní\n"
-" seznam z k dispozici\n"
-" k dispozici\n"
-" Úklid\n"
-" ZaÄátek je ne\n"
-" Zabít a\n"
-" Zjistit pro a n\n"
-" Spustit\n"
-" D po\n"
-" UkonÄit\n"
-" vysoká priorita až set vysoká úroveň\n"
-" k dispozici SUID nebo\n"
-" s\n"
-" až povolit\n"
-" k dispozici SUID nebo\n"
-" s\n"
-" modul naÄítám modul uživatel modul\n"
-" naÄítám po\n"
-" uživatel\n"
-" Äas SEKUNDY a\n"
-" Äas\n"
-" modul Äas SEKUNDY a\n"
-" Äas\n"
-" Äas SEKUNDY a\n"
-" Äas\n"
-" úroveň ÚROVEŇ Zvýšit nebo set úroveň\n"
-" Zvýšit úroveň\n"
-" auto\n"
-" p cesta CESTA Nastavit cesta pro\n"
-"\n"
+"%s [pÅ™epínaÄe]\n"
"\n"
-" Viz pro\n"
+"PŘÃKAZY:\n"
+" -h, --help Zobrazí tuto nápovědu\n"
+" --version Zobrazí verzi\n"
+" --dump-conf Vypíše výchozí nastavení\n"
+" --dump-modules Vypíše seznam dostupných modulů\n"
+" --dump-resample-methods Vypíše dostupné metody "
+"převzorkování\n"
+" --cleanup-shm Vyprázdní zastaralé Äásti sdílené "
+"paměti\n"
+" --start Spustí démona, pokud neběží\n"
+" -k --kill Zabije běžícího démona\n"
+" --check Zjistí, zda démon běží (vrací pouze "
+"ukonÄovací kód)\n"
"\n"
-" soubor Vytvořit a PID soubor\n"
-" ne ne CPU zapnuto\n"
+"PŘEPÃNAÄŒE:\n"
+" --system[=BOOLEOVSKÃ] Poběží jako celosystémová instance\n"
+" -D, --daemonize[=BOOLEOVSKÃ] Stane se démonem po spuÅ¡tÄ›ní\n"
+" --fail[=BOOLEOVSKÃ] UkonÄí se v případÄ› selhání "
+"spuštění\n"
+" --high-priority[=BOOLEOVSKÃ] Pokusí se nastavit vysokou úroveň "
+"nice\n"
+" (dostupné pouze u superuživatele, v "
+"případě SUID nebo\n"
+" se zvýšeným RLIMIT_NICE)\n"
+" --realtime[=BOOLEOVSKÃ] Pokusí se zapnout plánování v "
+"reálném Äase\n"
+" (dostupné pouze u superuživatele, v "
+"případě SUID nebo\n"
+" se zvýšeným RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOLEOVSKÃ] Nepovolí nahrání Äi zruÅ¡ení "
+"nahrání modulu po spuštění\n"
+" vyžádané uživatelem modulu\n"
+" --disallow-exit[=BOOLEOVSKÃ] Nepovolí ukonÄení vyžádané "
+"uživatelem\n"
+" --exit-idle-time=SEKUNDY UkonÄí démona v případÄ› neÄinnosti a "
+"po\n"
+" této době\n"
+" --module-idle-time=SEKUNDY Zruší nahrání automaticky nahraných "
+"modulů v případÄ› neÄinnosti\n"
+" a po této době\n"
+" --scache-idle-time=SEKUNDY Zruší nahrání automaticky nahraných "
+"vzorků v případÄ› neÄinnosti a\n"
+" po této době\n"
+" --log-level[=ÚROVEŇ] Zvýší nebo nastaví úroveň "
+"podrobností\n"
+" -v Zvýší úroveň podrobností\n"
+" --log-target={auto,syslog,stderr} UrÄí cíl záznamů\n"
+" --log-meta[=BOOLEOVSKÃ] Do záznamů zahrne umístÄ›ní kódu\n"
+" --log-time[=BOOLEOVSKÃ] Do záznamů zahrne urÄení Äasu\n"
+" --log-backtrace=RÃMCE Do záznamů zahrne backtrace\n"
+" -p, --dl-search-path=CESTA Nastaví cestu hledání z důvodu "
+"dynamického sdílení\n"
+" objektů (zásuvných modulů)\n"
+" --resample-method=METODA Použije zadanou metodu "
+"převzorkování\n"
+" (Možné hodnoty viz\n"
+" --dump-resample-methods)\n"
+" --use-pid-file[=BOOLEOVSKÃ] Vytvoří soubor PID\n"
+" --no-cpu-limit[=BOOLEOVSKÃ] Nenainstaluje omezovaÄ zátěže CPU\n"
+" na platformách, které ho podporují.\n"
+" --disable-shm[=BOOLEOVSKÃ] Vypne podporu sdílené pamÄ›ti.\n"
"\n"
-" Vypnout n\n"
-" L MODUL NaÄíst modul s\n"
+"SPOUÅ TÄšCÃ SKRIPT:\n"
+" -L, --load=\"ARGUMENTY MODULU\" Nahraje zadaný zásuvný modul\n"
+" s urÄeným argumentem\n"
+" -F, --file=NÃZEVSOUBORU Spustí zadaný skript\n"
+" -C Po spuštění otevře příkazový řádek\n"
+" na běžícím TTY\n"
"\n"
-" F soubor NÃZEVSOUBORU Spustit skript\n"
-" C Otevřít a zapnuto TTY\n"
-" po n\n"
-" n implicitní skript soubor n"
+" -n Nenahraje výchozí soubor skriptu\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -644,56 +595,53 @@ msgstr ""
"--log-level pÅ™edpokládá argument protokolovací úrovnÄ› (buÄ Äíselný v rozmezí "
"0..4, nebo jeden z debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:302
-#, fuzzy
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr "--disallow-exit booleovský argument"
+msgstr "--disallow-exit předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"Neplatný cíl protokolu: použijte buÄto \"syslog\", \"stderr\" nebo \"auto\"."
-#: ../src/daemon/cmdline.c:333
-#, fuzzy
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr "--realtime předpokládá booleovský argument"
+msgstr "--log-time předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:340
-#, fuzzy
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr "--disallow-exit booleovský argument"
+msgstr "--log-meta předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Neplatná metoda převzorkování \"%s\"."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit předpokládá booleovský argument"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm předpokládá booleovský argument"
@@ -728,363 +676,348 @@ msgid "Usage: %s\n"
msgstr "Použití: %s\n"
#: ../src/daemon/dumpmodules.c:73
-#, fuzzy, c-format
+#, c-format
msgid "Load Once: %s\n"
-msgstr "NaÄíst Jednou s n"
+msgstr "NaÄíst jednou: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "VAROVÃNÃ ZASTARALOSTI: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Cesta: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Neplatný protokolovací cíl \"%s\"."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Neplatná protokolovací úroveň \"%s\"."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Neplatná metoda převzorkování \"%s\"."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Neplatné rlimit \"%s\"."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit na této platformě není podporováno."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Neplatný vzorkovací formát \"%s\"."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Neplatná vzorkovací frekvence \"%s\"."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Neplatné vzorkovací kanály \"%s\"."
-#: ../src/daemon/daemon-conf.c:353
-#, fuzzy, c-format
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
-msgstr "[%s:%u] Neplatné vzorkovací kanály \"%s\"."
+msgstr "[%s:%u] Neplatná mapa kanálů \"%s\"."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Neplatný poÄet fragmentů \"%s\"."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Neplatná velikost fragmentu \"%s\"."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Neplatná úroveň nice \"%s\"."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Neplatná vzorkovací frekvence \"%s\"."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "NezdaÅ™ilo se otevřít konfiguraÄní soubor: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr ""
+"Zadaná výchozí mapa kanálů obsahuje odliÅ¡ný poÄet kanálů než je zadaný "
+"výchozí poÄet kanálů."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### ÄŒtení z konfiguraÄního souboru: %s ###\n"
-#: ../src/daemon/caps.c:63
-#, fuzzy
-msgid "Dropping root privileges."
-msgstr "Rušení superuživatelských oprávnění."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Schopnosti úspěšně omezeny na CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Rušení oprávnění."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
-msgstr ""
+msgstr "Zvukový systém PulseAudio"
#: ../src/daemon/pulseaudio.desktop.in.h:2
msgid "Start the PulseAudio Sound System"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-#, fuzzy
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Nezdařilo se zabít démona PulseAudio."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-#, fuzzy
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Nacházíme se ve skupině \"%s\", což umožňuje plánování o vysoké prioritě."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
+msgstr "Spustit zvukový systém PulseAudio"
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Přední středový"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Přední levý"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Přední pravý"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Zadní středový"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Zadní levý"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Zadní pravý"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "NízkofrekvenÄní zářiÄ"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Přední levý středový"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Přední pravý středový"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "BoÄní levý"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "BoÄní pravý"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Aux 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Aux 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Aux 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Aux 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Aux 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Aux 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Aux 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Aux 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Aux 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Aux 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Aux 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Aux 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Aux 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Aux 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Aux 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Aux 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Aux 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Aux 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Aux 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Aux 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Aux 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Aux 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Aux 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Aux 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Aux 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Aux 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Aux 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Aux 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Aux 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Aux 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Aux 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Aux 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Horní středový"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Horní přední středový"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Horní přední levý"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Horní přední pravý"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Horní zadní středový"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Horní zadní levý"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Horní zadní pravý"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
-#, fuzzy
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
-msgstr "Neplatné"
+msgstr "(neplatné)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
-msgstr ""
+msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
-msgstr ""
+msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
-msgstr ""
+msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
-msgstr ""
+msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
-msgstr ""
+msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
-msgstr ""
+msgstr "Surround 7.1"
#: ../src/pulse/error.c:43
msgid "OK"
@@ -1176,40 +1109,48 @@ msgstr "Takové rozšíření neexistuje"
#: ../src/pulse/error.c:65
msgid "Obsolete functionality"
-msgstr ""
+msgstr "Zastaralá vlastnost"
#: ../src/pulse/error.c:66
msgid "Missing implementation"
-msgstr ""
+msgstr "Scházející implementace"
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr ""
+msgstr "Klient rozvětven"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Chyba vstupu/výstupu"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Zařízení nebo zdroj se používá"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
-msgstr ""
+msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
-msgstr ""
+msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
-msgstr ""
+msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
-msgstr ""
+msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
-msgstr ""
+msgstr "%u B"
#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
msgid "XOpenDisplay() failed"
@@ -1219,197 +1160,191 @@ msgstr "XOpenDisplay() selhalo"
msgid "Failed to parse cookie data"
msgstr "Selhala analýza dat cookie"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Selhalo otevÅ™ení konfiguraÄního souboru \"%s\": %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Žádný soubor cookie nenahrán. Pokus o spojení bez tohoto kroku."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Přijata zpráva pro neznámé rozšíření \"%s\""
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() selhalo: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Nezdařilo se vyprázdnit proud: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() selhalo: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Proud přehrávání vyprázdněn."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Proud úspěšně vytvořen.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Vyprazdňování spojení se serverem."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() selhalo: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr ""
-"Metrika vyrovnávací paměti: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() selhalo: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Metrika vyrovnávací paměti: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() selhalo: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Používána vzorkovací specifikace \"%s\", mapa kanálů \"%s\".\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() selhalo: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Připojeno k zařízení %s (%u, %ssuspended).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Proud úspěšně vytvořen."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Chyba proudu: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() selhalo: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Proudové zařízení pozastaveno.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr ""
+"Metrika vyrovnávací paměti: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Proudové zařízení obnoveno.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Metrika vyrovnávací paměti: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Podběhnutí proudu.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Používáno urÄení vzorku \"%s\", mapa kanálů \"%s\"."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Přeběhnutí proudu.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Připojeno k zařízení %s (%u, %ssuspended)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Proud spuštěn.%s \n"
+msgid "Stream error: %s"
+msgstr "Chyba proudu: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Proud přesunut na zařízení %s (%u, %ssuspended).%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "nikoliv "
-
-#: ../src/utils/pacat.c:245
-#, fuzzy, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Podběhnutí proudu.%s \n"
+msgid "Stream device suspended.%s"
+msgstr "Proudové zařízení pozastaveno.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Spojení navázáno.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "Proudové zařízení obnoveno.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() selhalo: %s\n"
+msgid "Stream underrun.%s"
+msgstr "Podběhnutí proudu.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() selhalo: %s\n"
+msgid "Stream overrun.%s"
+msgstr "Přeběhnutí proudu.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() selhalo: %s\n"
+msgid "Stream started.%s"
+msgstr "Proud spuštěn.%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Spojení selhalo: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Proud přesunut na zařízení %s (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Nezdařilo se vyprázdnit proud: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "nikoliv "
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Proud přehrávání vyprázdněn.\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Změněny atributy vyrovnávací paměti proudu.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Vyprazdňování spojení se serverem.\n"
+msgid "Connection established.%s"
+msgstr "Spojení navázáno.%s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Got EOF.\n"
-msgstr "Získáno EOF.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() selhalo: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() selhalo: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() selhalo: %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() selhalo: %s"
-#: ../src/utils/pacat.c:438
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() selhalo: %s\n"
+msgid "Connection failure: %s"
+msgstr "Spojení selhalo: %s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Získáno EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Získán signál, ukonÄování.\n"
+msgid "write() failed: %s"
+msgstr "write() selhalo: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Získán signál, ukonÄování."
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Nezdařilo se získat latenci: %s\n"
+msgid "Failed to get latency: %s"
+msgstr "Nezdařilo se získat latenci: %s"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Čas: %0.3f sekund; latence: %0.0f μs. \r"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Čas: %0.3f sekund; latence: %0.0f μs"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:620
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() selhalo: %s\n"
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() selhalo: %s"
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:630
#, fuzzy, c-format
msgid ""
"%s [options]\n"
@@ -1436,8 +1371,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1460,36 +1397,69 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
-msgstr ""
-"s n\n"
-" h nápověda Zobrazit nápověda\n"
-" verze Zobrazit verze n\n"
-" Vytvořit a pro nahrávání\n"
-" p přehrávání Vytvořit a pro přehrávání n\n"
-" Povolit n\n"
-" s SERVER název z až až\n"
-" d zařízení ZAŘÃZENà název z cíl zdroj až až\n"
-" n název NÃZEV Jak až zapnuto\n"
-" název NÃZEV Jak až zapnuto\n"
-" svazek svazek in oblast\n"
-" in Hz až\n"
-" typ z\n"
-" až\n"
-" Äíslo z pro mono pro stereo\n"
-" až\n"
-" kanál mapa Kanál mapa až z implicitní\n"
-" z alba cíl je\n"
-" až\n"
-" z alba cíl je\n"
-" až\n"
-" Äíslo z a kanál mapa\n"
-" z alba cíl je až\n"
-" ne nebo\n"
-" ne od rejstřík z název\n"
-" Požadavek in bajty\n"
-" Äas Požadavek Äas in bajty n"
-
-#: ../src/utils/pacat.c:612
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+"%s [pÅ™epínaÄe]\n"
+"\n"
+" -h, --help Zobrazí tuto nápovědu\n"
+" --version Zobrazí verzi\n"
+"\n"
+" -r, --record Vytvoří spojení z důvodu nahrávání\n"
+" -p, --playback Vytvoří spojení z důvodu přehrávání\n"
+"\n"
+" -v, --verbose Zapne nakládání s úrovní "
+"podrobností\n"
+"\n"
+" -s, --server=SERVER Název připojovaného serveru\n"
+" -d, --device=ZAŘÃZENà Název pÅ™ipojovaného cíle Äi zdroje\n"
+" -n, --client-name=NÃZEV Způsob volání tohoto klienta na "
+"serveru\n"
+" --stream-name=NÃZEV Způsob volání tohoto proudu na "
+"serveru\n"
+" --volume=HLASITOST UrÄí poÄáteÄní (lineární) hlasitost "
+"v rozmezí 0...65536\n"
+" --rate=VZORKOVACÃFREKVENCE Vzorkovací frekvence v Hz (výchozí "
+"je 44100)\n"
+" --format=FORMÃTVZORKU Typ vzorku, jeden z s16le, s16be, "
+"u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be "
+"(výchozí je s16ne)\n"
+" --channels=KANÃLY PoÄet kanálů, u mono 1, u sterea 2\n"
+" (výchozí je 2)\n"
+" --channel-map=MAPAKANÃLÅ® Mapa kanálů urÄená k použití namísto "
+"výchozí\n"
+" --fix-format Získá formát vzorku z cíle, ke "
+"kterému se\n"
+" připojuje proud.\n"
+" --fix-rate Získá vzorkovací frekvenci z cíle, "
+"ke kterému se\n"
+" připojuje proud.\n"
+" --fix-channels Získá poÄet kanálů a mapu kanálů z "
+"cíle, ke kterému se\n"
+" připojuje proud.\n"
+" --no-remix Nesměšuje kanály.\n"
+" --no-remap Mapuje kanály dle indexu namísto "
+"názvu.\n"
+" --latency=BAJTY Vyžádá urÄenou latenci v bajtech.\n"
+" --process-time=BAJTY Vyžádá urÄený Äas zpracování na "
+"požadavek v bajtech.\n"
+" --property=VLASTNOST=HODNOTA Nastaví urÄenou vlastnost na urÄenou "
+"hodnotu.\n"
+" --raw Nahrává/přehrává surová data PCM.\n"
+" --file-format=FORMÃT Nahrává/pÅ™ehrává formátovaná data "
+"PCM.\n"
+" --list-file-formats Zobrazí seznam dostupných formátů "
+"souborů.\n"
+
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1500,130 +1470,171 @@ msgstr ""
"Přeloženo s libpulse %s\n"
"Propojeno s libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Neplatná mapa kanálů \"%s\"\n"
+msgid "Invalid client name '%s'"
+msgstr "Neplatný název klienta \"%s\""
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Neplatné upřesnění latence \"%s\"\n"
+msgid "Invalid stream name '%s'"
+msgstr "Neplatný název proudu \"%s\""
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Neplatné upÅ™esnÄ›ní Äasu zpracování \"%s\"\n"
+msgid "Invalid channel map '%s'"
+msgstr "Neplatná mapa kanálů \"%s\""
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Neplatné upřesnění vzorkování\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Neplatné upřesnění latence \"%s\""
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Mapa kanálů se neshoduje s upřesněním vzorkování\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Neplatné upÅ™esnÄ›ní Äasu zpracování \"%s\""
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Otevírání proudu %s s upřesněním vzorkování \"%s\".\n"
+msgid "Invalid property '%s'"
+msgstr "Neplatná vlastnost \"%s\""
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "nahrávání"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Neznámý formát souboru %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "přehrávání"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Neplatné urÄení vzorku"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Příliš mnoho argumentů.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Příliš mnoho argumentů."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() selhalo.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Selhalo vytvoÅ™ení urÄení vzorku souboru."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() selhalo.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Selhalo otevření zvukového souboru."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() selhalo.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Varování: zadané urÄení vzorku bude pÅ™epsáno urÄením získaným ze souboru."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() selhalo: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Selhalo zjiÅ¡tÄ›ní urÄení vzorku ze souboru."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Varování: Selhalo zjištění mapy kanálů ze souboru."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Mapa kanálů se neshoduje s urÄením vzorku"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Varování: selhal zápis mapy kanálů do souboru."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() selhalo.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "Otevírání proudu %s s urÄením vzorku \"%s\" a mapou kanálů \"%s\"."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "nahrávání"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "přehrávání"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() selhalo."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() selhalo."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() selhalo."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() selhalo.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() selhalo: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() selhalo."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() selhalo."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Nezdařilo se pozastavení: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Nezdařilo se obnovení: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "VAROVÃNÃ: Zvukový server není místní, nedojde k pozastavení.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Spojení selhalo: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Získáno SIGINT, ukonÄování.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "VAROVÃNÃ: Proces potomka ukonÄen signálem %u\n"
-#: ../src/utils/pasuspender.c:212
-#, fuzzy, c-format
+#: ../src/utils/pasuspender.c:210
+#, c-format
msgid ""
"%s [options] ... \n"
"\n"
@@ -1633,12 +1644,14 @@ msgid ""
"to\n"
"\n"
msgstr ""
-"s n\n"
-" h nápověda Zobrazit nápověda\n"
-" verze Zobrazit verze\n"
-" s SERVER název z až až n n"
+"%s [pÅ™epínaÄe] ... \n"
+"\n"
+" -h, --help Zobrazí tuto nápovědu\n"
+" --version Zobrazí verzi\n"
+" -s, --server=SERVER Název připojovaného serveru\n"
+"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1649,35 +1662,61 @@ msgstr ""
"Přeloženo s libpulse %s\n"
"Propojeno s libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() selhalo.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() selhalo.\n"
+
+#: ../src/utils/pasuspender.c:296
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Selhalo získání statistik: %s\n"
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() selhalo.\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Selhalo získání statistik: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Právě používáno: %u bloků obsahujících celkem %s bajtů.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "Alokováno během celého běhu: %u bloků obsahujících celkem %s bajtů.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Velikost vzorkovací vyrovnávací paměti: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Nezdařilo se získání informací o serveru: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Nezdařilo se získání informací o serveru: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
#, fuzzy, c-format
msgid ""
-"User name: %s\n"
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1685,24 +1724,25 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Uživatelské jméno: %s\n"
"Název poÄítaÄe: %s\n"
"Název serveru: %s\n"
"Verze serveru: %s\n"
-"Výchozí upřesnění vzorkování: %s\n"
+"Výchozí urÄení vzorku: %s\n"
+"Výchozí mapa kanálů: %s\n"
"Výchozí cíl: %s\n"
"Výchozí zdroj: %s\n"
"Cookie: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Nezdařilo se získání informací o cíli: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Nezdařilo se získání informací o cíli: %s"
-#: ../src/utils/pactl.c:194
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:234
+#, c-format
msgid ""
"Sink #%u\n"
"\tState: %s\n"
@@ -1722,26 +1762,41 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Cíl Ä. %u ***\n"
-"Název: %s\n"
-"OvladaÄ: %s\n"
-"Upřesnění vzorkování: %s\n"
-"Mapa kanálů: %s\n"
-"Modul vlastníka: %u\n"
-"Hlasitost %s\n"
-"Zdroj monitoru: %s\n"
-"Latence: %0.0f μs, konfigurováno %0.0f μs\n"
-"Příznaky: %s%s%s%s%s%s\n"
-"Vlastnosti:\n"
-"%s"
-
-#: ../src/utils/pactl.c:258
-#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Nezdařilo se získání informací o zdroji: %s\n"
-
-#: ../src/utils/pactl.c:274
-#, fuzzy, c-format
+"Cíl Ä. %u\n"
+"\tStav: %s\n"
+"\tNázev: %s\n"
+"\tPopis: %s\n"
+"\tOvladaÄ: %s\n"
+"\tUrÄení vzorku: %s\n"
+"\tMapa kanálů: %s\n"
+"\tModul vlastníka: %u\n"
+"\tZtlumení: %s\n"
+"\tHlasitost: %s%s%s\n"
+"\t vyvážení %0.2f\n"
+"\tZákladní hlasitost %s%s%s\n"
+"\tZdroj sledování: %s\n"
+"\tLatence: %0.0f μs, konfigurováno %0.0f μs\n"
+"\tPříznaky: %s%s%s%s%s%s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorty:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tAktivní port: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Nezdařilo se získání informací o zdroji: %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
msgid ""
"Source #%u\n"
"\tState: %s\n"
@@ -1761,34 +1816,39 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Zdroj Ä. %u ***\n"
-"Název: %s\n"
-"OvladaÄ: %s\n"
-"Upřesnění vzorkování: %s\n"
-"Mapa kanálů: %s\n"
-"Modul vlastníka: %u\n"
-"Hlasitost %s\n"
-"Monitor zdroje: %s\n"
-"Latence: %0.0f μs, konfigurováno %0.0f μs\n"
-"Příznaky: %s%s%s%s%s%s\n"
-"Vlastnosti:\n"
-"%s"
-
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+"Zdroj Ä. %u\n"
+"\tStav: %s\n"
+"\tNázev: %s\n"
+"\tPopis: %s\n"
+"\tOvladaÄ: %s\n"
+"\tUrÄení vzorku: %s\n"
+"\tMapa kanálů: %s\n"
+"\tModul vlastníka: %u\n"
+"\tZtlumení: %s\n"
+"\tHlasitost: %s%s%s\n"
+"\t vyvážení %0.2f\n"
+"\tZákladní hlasitost %s%s%s\n"
+"\tSledování zdroje: %s\n"
+"\tLatence: %0.0f μs, konfigurováno %0.0f μs\n"
+"\tPříznaky: %s%s%s%s%s%s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "nic"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Selhalo získání informací o modulu: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Selhalo získání informací o modulu: %s"
-#: ../src/utils/pactl.c:342
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:406
+#, c-format
msgid ""
"Module #%u\n"
"\tName: %s\n"
@@ -1797,19 +1857,20 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Modul Ä. %u ***\n"
-"Název: %s\n"
-"Argument: %s\n"
-"PoÄet použití %s\n"
-"Automatické uvolnění: %s\n"
+"Modul Ä. %u\n"
+"\tNázev: %s\n"
+"\tArgument: %s\n"
+"\tPoÄet použití %s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Selhalo získání informací o klientu: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Selhalo získání informací o klientu: %s"
-#: ../src/utils/pactl.c:379
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:443
+#, c-format
msgid ""
"Client #%u\n"
"\tDriver: %s\n"
@@ -1817,19 +1878,19 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Klient Ä. %u ***\n"
-"OvladaÄ: %s\n"
-"Modul vlastníka: %s\n"
-"Vlastnosti:\n"
-"%s"
+"Klient Ä. %u\n"
+"\tOvladaÄ: %s\n"
+"\tModul vlastníka: %s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:396
-#, fuzzy, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Selhalo až get s n"
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "Selhalo získání informací o kartě: %s"
-#: ../src/utils/pactl.c:414
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:478
+#, c-format
msgid ""
"Card #%u\n"
"\tName: %s\n"
@@ -1838,29 +1899,30 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Klient Ä. %u ***\n"
-"OvladaÄ: %s\n"
-"Modul vlastníka: %s\n"
-"Vlastnosti:\n"
-"%s"
+"Karta Ä. %u\n"
+"\tNázev: %s\n"
+"\tOvladaÄ: %s\n"
+"\tModul vlastníka: %s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
-msgstr ""
+msgstr "\tProfily:\n"
-#: ../src/utils/pactl.c:434
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:498
+#, c-format
msgid "\tActive Profile: %s\n"
-msgstr "pipe selhalo: %s"
+msgstr "\tAktivní profil: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Nezdařilo se získání cílových vstupních informací: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Nezdařilo se získání informací o vstupu cíle: %s"
-#: ../src/utils/pactl.c:464
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:528
+#, c-format
msgid ""
"Sink Input #%u\n"
"\tDriver: %s\n"
@@ -1878,15 +1940,31 @@ msgid ""
"\tResample method: %s\n"
"\tProperties:\n"
"\t\t%s\n"
-msgstr "Vstup s Modul s s s s s s n s"
+msgstr ""
+"Vstup cíle Ä. %u\n"
+"\tOvladaÄ: %s\n"
+"\tModul vlastníka: %s\n"
+"\tKlient: %s\n"
+"\tCíl: %u\n"
+"\tUrÄení vzorku: %s\n"
+"\tMapa kanálů: %s\n"
+"\tZtlumení: %s\n"
+"\tHlasitost: %s\n"
+"\t %s\n"
+"\t vyvážení %0.2f\n"
+"\tLatence vyrovnávací paměti: %0.0f μs\n"
+"\tLatence cíle: %0.0f μs\n"
+"\tMetoda převzorkování: %s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:503
-#, fuzzy, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Selhalo až get zdroj s n"
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "Selhalo získání informace o výstupu zdroje: %s"
-#: ../src/utils/pactl.c:523
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:587
+#, c-format
msgid ""
"Source Output #%u\n"
"\tDriver: %s\n"
@@ -1900,15 +1978,27 @@ msgid ""
"\tResample method: %s\n"
"\tProperties:\n"
"\t\t%s\n"
-msgstr "Zdroj Výstup s Modul s s s s s n s"
+msgstr ""
+"Výstup zdroje Ä. %u\n"
+"\tOvladaÄ: %s\n"
+"\tModul vlastníka: %s\n"
+"\tKlient: %s\n"
+"\tZdroj: %u\n"
+"\tUrÄení vzorku: %s\n"
+"\tMapa kanálů: %s\n"
+"\tLatence vyrovnávací paměti: %0.0f μs\n"
+"\tLatence zdroje: %0.0f μs\n"
+"\tMetoda převzorkování: %s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:554
-#, fuzzy, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Selhalo až get s n"
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "Selhalo získání informace o vzorku: %s"
-#: ../src/utils/pactl.c:572
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:636
+#, c-format
msgid ""
"Sample #%u\n"
"\tName: %s\n"
@@ -1923,24 +2013,94 @@ msgid ""
"\tFilename: %s\n"
"\tProperties:\n"
"\t\t%s\n"
-msgstr "Ukázka s s s s s s s n s"
+msgstr ""
+"Vzorek Ä. %u\n"
+"\tNázev: %s\n"
+"\tUrÄení vzorku: %s\n"
+"\tMapa kanálů: %s\n"
+"\tHlasitost: %s\n"
+"\t %s\n"
+"\t vyvážení %0.2f\n"
+"\tDélka: %0.1fs\n"
+"\tVelikost: %s\n"
+"\tOpoždění: %s\n"
+"\tNázev souboru: %s\n"
+"\tVlastnosti:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Selhání: %s\n"
+msgid "Failure: %s"
+msgstr "Selhání: %s"
-#: ../src/utils/pactl.c:636
-#, fuzzy, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Selhalo až s n"
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "Selhalo nahrání vzorku: %s"
-#: ../src/utils/pactl.c:653
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "PÅ™edÄasný konec souboru"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Neplatný server"
+
+#: ../src/utils/pactl.c:787
#, c-format
-msgid "Premature end of file\n"
-msgstr "PÅ™edÄasný konec souboru\n"
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Získáno SIGINT, ukonÄování."
+
+#: ../src/utils/pactl.c:961
#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
@@ -1949,13 +2109,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -1965,15 +2134,36 @@ msgid ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
msgstr ""
-"s n s seznam n s n s NÃZEVSOUBORU NÃZEV n s NÃZEV n s odstranit NÃZEV n s "
-"pÅ™esunout cíl ID n s pÅ™esunout zdroj ID ZDROJ n s modul NÃZEV n s modul ID n "
-"s cíl n s zdroj ZDROJ n\n"
-" h nápověda Zobrazit nápověda\n"
-" verze Zobrazit verze n\n"
-" s SERVER název z až až\n"
-" n název NÃZEV Jak až zapnuto n"
+"%s [pÅ™epínaÄe] stat\n"
+"%s [pÅ™epínaÄe] list\n"
+"%s [pÅ™epínaÄe] exit\n"
+"%s [pÅ™epínaÄe] upload-sample NÃZEVSOUBORU [NÃZEV]\n"
+"%s [pÅ™epínaÄe] play-sample NÃZEV [CÃL]\n"
+"%s [pÅ™epínaÄe] remove-sample NÃZEV\n"
+"%s [pÅ™epínaÄe] move-sink-input VSTUPCÃLE CÃL\n"
+"%s [pÅ™epínaÄe] move-source-output VÃSTUPZDROJE ZDROJ\n"
+"%s [pÅ™epínaÄe] load-module NÃZEV [ARG ...]\n"
+"%s [pÅ™epínaÄe] unload-module MODUL\n"
+"%s [pÅ™epínaÄe] suspend-sink CÃL 1|0\n"
+"%s [pÅ™epínaÄe] suspend-source ZDROJ 1|0\n"
+"%s [pÅ™epínaÄe] set-card-profile KARTA PROFIL\n"
+"%s [pÅ™epínaÄe] set-sink-port CÃL PORT\n"
+"%s [pÅ™epínaÄe] set-source-port ZDROJ PORT\n"
+"%s [pÅ™epínaÄe] set-sink-volume CÃL HLASITOST\n"
+"%s [pÅ™epínaÄe] set-source-volume ZDROJ HLASITOST\n"
+"%s [pÅ™epínaÄe] set-sink-input-volume VSTUPCÃLE HLASITOST\n"
+"%s [pÅ™epínaÄe] set-sink-mute CÃL 1|0\n"
+"%s [pÅ™epínaÄe] set-source-mute ZDROJ 1|0\n"
+"%s [pÅ™epínaÄe] set-sink-input-mute VSTUPCÃLE 1|0\n"
+"\n"
+" -h, --help Zobrazí tuto nápovědu\n"
+" --version Zobrazí verzi\n"
+"\n"
+" -s, --server=SERVER Název připojovaného serveru\n"
+" -n, --client-name=NÃZEV Způsob volání tohoto klienta na "
+"serveru\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -1984,77 +2174,109 @@ msgstr ""
"Přeloženo s libpulse %s\n"
"Propojeno s libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, fuzzy, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Prosím a soubor až n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Zadejte prosím soubor se vzorkem urÄeným k nahrání"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Selhalo otevření zvukového souboru.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Selhalo otevření zvukového souboru."
-#: ../src/utils/pactl.c:899
-#, fuzzy, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Vy až a název až n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Varování: Selhalo zjiÅ¡tÄ›ní urÄení vzorku ze souboru."
-#: ../src/utils/pactl.c:911
-#, fuzzy, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Vy až a název až odstranit n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Je nutné zadat název vzorku urÄeného k pÅ™ehrání"
-#: ../src/utils/pactl.c:919
-#, fuzzy, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Vy až a cíl rejstřík a a cíl n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Je nutné zadat název vzorku urÄeného k odstranÄ›ní"
-#: ../src/utils/pactl.c:928
-#, fuzzy, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Vy až a zdroj rejstřík a a zdroj n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Je nutné zadat vstup cíle a cíl"
-#: ../src/utils/pactl.c:942
-#, fuzzy, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Vy až a modul název a n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Je nutné zadat index výstupu zdroje a zdroj"
-#: ../src/utils/pactl.c:962
-#, fuzzy, c-format
-msgid "You have to specify a module index\n"
-msgstr "Vy až a modul rejstřík n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Je nutné zadat název modulu a argumenty."
-#: ../src/utils/pactl.c:972
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Je nutné zadat index modulu"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr "Vy ne cíl Vy až při booleovská hodnota hodnota n"
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr "Nelze zadat více než jeden cíl. Je nutné zadat booleovskou hodnotu."
-#: ../src/utils/pactl.c:985
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr "Vy ne zdroj Vy až při booleovská hodnota hodnota n"
+"value."
+msgstr "Nelze zadat více než jeden zdroj. Je nutné zadat booleovskou hodnotu."
-#: ../src/utils/pactl.c:997
-#, fuzzy, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Vy až a cíl rejstřík a a cíl n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Je nutné upřesnit název karty/indexu a název profilu"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Nezadán žádný platný příkaz.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Je nutné upřesnit název cíle/indexu a název portu"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() selhalo: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Je nutné upřesnit název zdroje/indexu a název portu"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Je nutné upřesnit název cíle/indexu a hlasitost"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Neplatné urÄení hlasitosti"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Je nutné upřesnit název zdroje/indexu a hlasitost"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Je nutné zadat index vstupu cíle a hlasitost"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Neplatný index vstupu cíle"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Je nutné upřesnit název cíle/indexu a booleovskou hodnotu ztlumení"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Je nutné upřesnit název zdroje/indexu a booleovskou hodnotu ztlumení"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "Je nutné zadat index vstupu cíle a booleovskou hodnotu ztlumení"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Neplatné urÄení indexu vstupu cíle"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Nezadán žádný platný příkaz."
#: ../src/utils/pax11publish.c:61
-#, fuzzy, c-format
+#, c-format
msgid ""
"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
"\n"
@@ -2064,11 +2286,13 @@ msgid ""
"variables and cookie file.\n"
" -r Remove PulseAudio data from X11 display\n"
msgstr ""
-"s D S O cíl I zdroj c soubor d e n\n"
-" d Zobrazit až implicitní\n"
-" e Exportovat místní až\n"
-" Importovat z alba až místní a soubor\n"
-" Odstranit z alba n"
+"%s [-D displej] [-S server] [-O cíl] [-I zdroj] [-c soubor] [-d|-e|-i|-r]\n"
+"\n"
+" -d Zobrazí aktuální data PulseAudio přiřazená k displeji X11 (výchozí)\n"
+" -e Exportuje místní data PulseAudio na displej X11\n"
+" -i Importuje data PulseAudio z displeje X11 mezi místní proměnné "
+"prostředí a soubor cookie.\n"
+" -r Odstraní data PulseAudio z displeje X11\n"
#: ../src/utils/pax11publish.c:94
#, c-format
@@ -2130,123 +2354,48 @@ msgstr "Nezdařilo se nahrát data cookie\n"
msgid "Not yet implemented.\n"
msgstr "Doposud neimplementováno.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "Neběží žádný démon PulseAudio, nebo neběží jako démon sezení."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Nezdařilo se zabít démona PulseAudio."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Démon neodpovídá."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Proud úspěšně vytvořen\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Chyba proudu: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Spojení navázáno.\n"
-
-#: ../src/utils/paplay.c:198
-#, fuzzy, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"s SOUBOR n\n"
-" h nápověda Zobrazit nápověda\n"
-" verze Zobrazit verze n\n"
-" Povolit n\n"
-" s SERVER název z až až\n"
-" d zařízení ZAŘÃZENà název z cíl až až\n"
-" n název NÃZEV Jak až zapnuto\n"
-" název NÃZEV Jak až zapnuto\n"
-" svazek svazek in oblast\n"
-" kanál mapa Nastavit kanál mapa až n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Přeloženo s libpulse %s\n"
-"Propojeno s libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, fuzzy, c-format
-msgid "Invalid channel map\n"
-msgstr "Neplatné kanál mapa n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Selhalo otevření souboru \"%s\"\n"
-
-#: ../src/utils/paplay.c:350
-#, fuzzy, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Kanál mapa soubor n"
-
-#: ../src/utils/paplay.c:376
-#, fuzzy, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "s n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
-#, fuzzy
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
-msgstr "přístup."
+msgstr "Nelze přistoupit k zámku automatického spouštění."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2256,8 +2405,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA nás probudila z důvodu zápisu nových dat na zařízení, ale ve "
+"skuteÄnosti nebylo co zapisovat.\n"
+"S nejvÄ›tší pravdÄ›podobností se jedná o chybu v ovladaÄi ALSA \"%s\". "
+"Nahlaste prosím tento problém vývojářům ALSA.\n"
+"Probudilo nás nastavení POLLOUT - nicméně následné snd_pcm_avail() vrátilo 0 "
+"Äi jinou hodnotu < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2267,92 +2422,477 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA nás probudila z důvodu Ätení nových dat ze zařízení, ale ve skuteÄnosti "
+"nebylo co Äíst.\n"
+"S nejvÄ›tší pravdÄ›podobností se jedná o chybu v ovladaÄi ALSA \"%s\". "
+"Nahlaste prosím tento problém vývojářům ALSA.\n"
+"Probudilo nás nastavení POLLIN - nicméně následné snd_pcm_avail() vrátilo 0 "
+"Äi jinou hodnotu < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
-msgstr ""
+msgstr "Vypnuto"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr ""
+msgstr "Přehrávání s velmi věrnou reprodukcí (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Záznam s velmi věrnou reprodukcí (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Duplexní telefonie (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
+msgstr "Zvukový server PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Výstupní zařízení"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Vstupní zařízení"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Zvuk na @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Vstup"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Vstup dokovací stanice"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Mikrofon dokovací stanice"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Linkový vstup"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Externí mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Interní mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Rádio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Obraz"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Automatické ovládání zesílení"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Bez automatického ovládání zesílení"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Zesílení"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Bez zesílení"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "ZesilovaÄ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Bez zesilovaÄe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Zesílení"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Bez zesílení"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
msgstr ""
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Analogová sluchátka"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Analogový vstup"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Analogový mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Analogový linkový vstup"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Analogové rádio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Analogový obraz"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Analogový výstup"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Analogová sluchátka"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Analogový výstup (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analogový výstup mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analogové stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analogové mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analogové stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analogový Surround 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analogový Surround 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analogový Surround 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analogový Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analogový Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analogový Surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analogový Surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analogový Surround 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analogový Surround 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analogový Surround 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analogový Surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digitální stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digitální Surround 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digitální Surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digitální Surround 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digitální stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analogové duplexní mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analogové duplexní stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Digitální duplexní stereo (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "NízkofrekvenÄní zářiÄ"
+
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Neplatný název klienta \"%s\"\n"
+
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr "Selhalo zjiÅ¡tÄ›ní urÄení vzorku ze souboru.\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "Nelze se spojit se systémovou sběrnicí: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "Nelze získat volajícího z PID: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "Nelze nastavit UID na objekt volajícího."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "Nezdařilo se získání sezení CK."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "Nelze nastavit UID na objekt sezení."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "Nelze alokovat PolKitAction."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "Nelze nastavit action_id"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "Nelze alokovat PolKitContext."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "Nelze spustit PolKitContext: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "NezdaÅ™ilo se urÄit, zda je volající oprávnÄ›n: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "Nezdařilo se získat oprávnění: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit odpověděl s \"%s\""
+
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Plánování o vysoké prioritě (záporná úroveň nice v Unixu) démona "
+#~ "PulseAudio"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Plánování v reálném Äase démona PulseAudio"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "Systémová pravidla znemožňují technologii PulseAudio získat přístup k "
+#~ "plánování o vysoké prioritě."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "Systémová pravidla znemožňují technologii PulseAudio získat přístup k "
+#~ "plánování v reálném Äase."
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "read() selhalo: %s\n"
+
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "pa_context_connect() selhalo: %s\n"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr ""
+#~ "Nacházíme se ve skupině \"%s\", což umožňuje plánování o vysoké prioritě."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr ""
+#~ "Nacházíme se ve skupinÄ› \"%s\", což umožňuje plánování v reálném Äase."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr "PolicyKit nám udělil oprávnění acquire-high-priority."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "PolicyKit nám neudělil oprávnění acquire-high-priority."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "PolicyKit nám udělil oprávnění acquire-real-time."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "PolicyKit nám neudělil oprávnění acquire-real-time."
+
#~ msgid ""
#~ "Called SUID root and real-time and/or high-priority scheduling was "
#~ "requested in the configuration. However, we lack the necessary "
#~ "privileges:\n"
-#~ "We are not in group '"
+#~ "We are not in group '%s', PolicyKit refuse to grant us the requested "
+#~ "privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
+#~ "limits.\n"
+#~ "For enabling real-time/high-priority scheduling please acquire the "
+#~ "appropriate PolicyKit privileges, or become a member of '%s', or increase "
+#~ "the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
#~ msgstr ""
-#~ "Volaný SUID root a plánování v reálném Äase / o vysoké prioritÄ› bylo "
-#~ "zažádáno v konfiguraci. Nedisponujeme ovšem potřebnými oprávněními:\n"
-#~ "Nejsme ve skupinÄ› \""
+#~ "Voláno SUID root a v nastavení bylo požádáno o plánování v reálném Äase "
+#~ "Äi o vysoké prioritÄ›. Schází nám ovÅ¡em potÅ™ebná oprávnÄ›ní.\n"
+#~ "Nejsme ve skupině \"%s\", PolicyKit nám odmítá přidělit požadovaná "
+#~ "oprávnění a je nutné zvýšit omezení zdroje RLIMIT_NICE/RLIMIT_RTPRIO.\n"
+#~ "Plánování v reálném Äase Äi o vysoké prioritÄ› zapnete získáním "
+#~ "přísluÅ¡ných oprávnÄ›ní PolicyKit, nebo tím, že se stanete Äleny \"%s\", "
+#~ "nebo uživateli zvýšíte omezení zdroje RLIMIT_NICE/RLIMIT_RTPRIO."
-#, fuzzy
-#~ msgid "--log-time boolean argument"
-#~ msgstr "--disallow-exit booleovský argument"
-
-#~ msgid "Default sink name (%s) does not exist in name register."
-#~ msgstr "Výchozí jméno cíle (%s) ve jmenném registru neexistuje."
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "Plánování o vysoké prioritě v konfiguraci zapnuto, ale nepovoleno "
+#~ "pravidly."
-#~ msgid "Buffer overrun, dropping incoming data\n"
-#~ msgstr "Přeběh vyrovnávací paměti, zahazují se příchozí data\n"
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "Úspěšně zvýšeno RLIMIT_RTPRIO"
-#~ msgid "pa_stream_drop() failed: %s\n"
-#~ msgstr "pa_stream_drop() selhalo: %s\n"
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO selhalo: %s"
-#~ msgid "muted"
-#~ msgstr "ztlumeno"
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "Vzdávání se CAP_NICE"
-#, fuzzy
#~ msgid ""
-#~ "*** Autoload Entry #%u ***\n"
-#~ "Name: %s\n"
-#~ "Type: %s\n"
-#~ "Module: %s\n"
-#~ "Argument: %s\n"
-#~ msgstr "s s s s n"
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "Plánování v reálném Äase v konfiguraci zapnuto, ale nepovoleno pravidly."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "Schopnosti úspěšně omezeny na CAP_SYS_NICE."
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "time_new() selhalo.\n"
+
+#~ msgid "Output %s + Input %s"
+#~ msgstr "Výstup %s + vstup %s"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Proud úspěšně vytvořen\n"
-#~ msgid "sink"
-#~ msgstr "cíl"
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "Chyba proudu: %s\n"
-#~ msgid "source"
-#~ msgstr "zdroj"
+#~ msgid "Connection established.\n"
+#~ msgstr "Spojení navázáno.\n"
#~ msgid ""
-#~ "' and PolicyKit refuse to grant us priviliges. Dropping SUID again.\n"
-#~ "For enabling real-time scheduling please acquire the appropriate "
-#~ "PolicyKit priviliges, or become a member of '"
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Show this help\n"
+#~ " --version Show version\n"
+#~ "\n"
+#~ " -v, --verbose Enable verbose operation\n"
+#~ "\n"
+#~ " -s, --server=SERVER The name of the server to connect "
+#~ "to\n"
+#~ " -d, --device=DEVICE The name of the sink to connect "
+#~ "to\n"
+#~ " -n, --client-name=NAME How to call this client on the "
+#~ "server\n"
+#~ " --stream-name=NAME How to call this stream on the "
+#~ "server\n"
+#~ " --volume=VOLUME Specify the initial (linear) "
+#~ "volume in range 0...65536\n"
+#~ " --channel-map=CHANNELMAP Set the channel map to the use\n"
#~ msgstr ""
-#~ "\" a PolicyKit odmítl udělit oprávnění. Opětovné zahazování SUID.\n"
-#~ "Chcete-li zapnout plánování v reálném Äase, obstarejte prosím přísluÅ¡ná "
-#~ "oprávnÄ›ní PolicyKit, nebo se staňte Älenem \""
+#~ "%s [pÅ™epínaÄe] [SOUBOR]\n"
+#~ "\n"
+#~ " -h, --help Zobrazí tuto nápovědu\n"
+#~ " --version Zobrazí verzi\n"
+#~ "\n"
+#~ " -v, --verbose Zapne nakládání s úrovní "
+#~ "podrobností\n"
+#~ "\n"
+#~ " -s, --server=SERVER Název připojovaného serveru\n"
+#~ " -d, --device=ZAŘÃZENà Název pÅ™ipojovaného cíle\n"
+#~ " -n, --client-name=NÃZEV Způsob volání tohoto klienta na "
+#~ "serveru\n"
+#~ " --stream-name=NÃZEV Způsob volání tohoto proudu na "
+#~ "serveru\n"
+#~ " --volume=HLASITOST UrÄí poÄáteÄní (lineární) "
+#~ "hlasitost v rozmezí 0...65536\n"
+#~ " --channel-map=MAPAKANÃLÅ® Nastaví mapu kanálů urÄenou k "
+#~ "použití\n"
#~ msgid ""
-#~ "', or increase the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this "
-#~ "user."
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
#~ msgstr ""
-#~ "\", Äi zvyÅ¡te zdrojové limity RLIMIT_NICE/RLIMIT_RTPRIO tohoto uživatele."
+#~ "paplay %s\n"
+#~ "Přeloženo s libpulse %s\n"
+#~ "Propojeno s libpulse %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Neplatná mapa kanálů\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Selhalo otevření souboru \"%s\"\n"
+
+#~ msgid "Channel map doesn't match file.\n"
+#~ msgstr "Mapa kanálů neodpovídá souboru.\n"
+
+#~ msgid "Using sample spec '%s'\n"
+#~ msgstr "Používá se vzorkovací specifikace \"%s\"\n"
diff --git a/po/de.po b/po/de.po
index 222fe781..d08a3fa4 100644
--- a/po/de.po
+++ b/po/de.po
@@ -1,69 +1,33 @@
+# translation of pulseaudio.master-tx.de.po to
# German translation of pulseaudio
# Copyright (C) 2008 pulseaudio
# This file is distributed under the same license as the pulseaudio package.
#
-# Fabian Affolter <fab@fedoraproject.org>, 2008-2009.
-# Micha Pietsch <barney@fedoraproject.org>, 2008
#
+# Fabian Affolter <fab@fedoraproject.org>, 2008-2009.
+# Micha Pietsch <barney@fedoraproject.org>, 2008, 2009.
+# Hedda Peters <hpeters@redhat.com>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio\n"
+"Project-Id-Version: pulseaudio.master-tx.de\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-18 12:43+0100\n"
-"Last-Translator: Fabian Affolter <fab@fedoraproject.org>\n"
-"Language-Team: German <fedora-trans-de@redhat.com>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-08 15:14+1000\n"
+"Last-Translator: Hedda Peters <hpeters@redhat.com>\n"
+"Language-Team: \n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=utf-8\n"
+"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Poedit-Language: German\n"
+"X-Generator: KBabel 1.11.4\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analog Mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analog Stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Digital Stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Digital Stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analog Surround 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digital Surround 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analog Surround 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analog Surround 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analog Surround 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digital Surround 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analog Surround 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -71,12 +35,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
-"snd_pcm_avail() gibt einen Wert zurück, welche außerordentlich groß ist: %lu "
+"snd_pcm_avail() gibt einen Wert zurück, der ausserordentlich gross ist: %lu "
"bytes (%lu ms).\n"
"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
-"diesen Punkt den ALSA-Entwicklern."
+"dieses Problem den ALSA-Entwicklern."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -84,12 +48,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
-"snd_pcm_delay() gibt einen Wert zurück, welche außerordentlich groß ist: %li "
+"snd_pcm_delay() gibt einen Wert zurück, der ausserordentlich gross ist: %li "
"bytes (%s%lu ms).\n"
"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
-"diesen Punkt den ALSA-Entwicklern."
+"dieses Problem den ALSA-Entwicklern."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -97,16 +61,50 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
-"snd_pcm_mmap_begin() gibt einen Wert zurück, welche außerordentlich groß "
-"ist: %lu bytes (%lu ms).\n"
+"snd_pcm_mmap_begin() gibt einen Wert zurück, der ausserordentlich gross ist: "
+"%lu bytes (%lu ms).\n"
"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
-"diesen Punkt den ALSA-Entwicklern."
+"dieses Problem den ALSA-Entwicklern."
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Hält stets einen Sink geladen, selbst wenn dies ein Null-Sink ist"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Dummy-Ausgabe"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Virtueller LADSPA-Sink"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<Name des Sinks> sink_properties=<Eigenschaften des Sinks> "
+"master=<Name des zu filternden Sinks> format=<Sample-Format> rate=<Sample-"
+"Rate> channels=<Anzahl der Channels> channel_map=<Channel-Map> "
+"plugin=<ladspa Plugin-Name> label=<ladspa Plugin-Label> "
+"control=<kommagetrennte Liste von Eingabekontrollwerten>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Clocked NULL Sink"
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null-Ausgabe"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Internes Audio"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Modem"
@@ -122,214 +120,98 @@ msgstr "Neuer dlopen-Loader konnte nicht gefunden werden."
msgid "Failed to add bind-now-loader."
msgstr "Hinzufügen von Bind-Now-Loader fehlgeschlagen."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Kann nicht mit dem System-Bus verbinden: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Kann Caller von PID nicht beziehen: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Kann UID für Caller-Objekt nicht setzen."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Kann CK-Session nicht beziehen."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Kann UID für Session-Objekt nicht setzen."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Konnte PolKitAction nicht zuordnen."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Kann action_id nicht setzen"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Konnte PolKitContext nicht zuordnen."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Konnte PolKitContext nicht initialisieren: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Autorisierung des Callers konnte nicht sichergestellt werden: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Keine Authorisierung erhalten: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit antwortete mit '%s'"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Signal %s empfangen."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Wird beendet."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Benutzer '%s' nicht gefunden."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Gruppe '%s' nicht gefunden."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Benutzer '%s' (UID %lu) und Gruppe '%s' (GID %lu) gefunden."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID von Benutzer '%s' und Gruppe '%s' stimmen nicht überein."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Benutzerverzeichnis von Benutzer '%s' ist nicht '%s', ignoriere."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Konnte '%s' nciht erzeugen: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Wechseln der Gruppen-Liste fehlgeschlagen: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Wechseln der GID fehlgeschlagen: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Wechseln der UID fehlgeschlagen: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Root-Berechtigungen erfolgreich zurückgesetzt."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "System-Modus auf dieser Plattform nicht unterstützt."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) fehlgeschlagen: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Parsen der Kommandzeile fehlgeschlagen."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Wir befinden uns in der Gruppe '%s', was Scheduling höchster Priorität "
-"ermöglicht."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Wir befinden uns in der Gruppe '%s', was Echtzeit-Scheduling ermöglicht."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "Richtlinien gewähren das Recht aquire-high-priority."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "Richtlinien verweigern das Recht acquire-high-priority."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "Richtlinien gewähren das Recht aquire-real-time."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "Richtlinien verweigern das Recht acquire-real-time."
-
-#: ../src/daemon/main.c:556
-#, fuzzy, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"' und PolicyKit verweigern diese Rechte. Verwerfe SUID wieder.\n"
-"Erlangen Sie die den Richtlinien entsprechenden Rechte, um Echtzeit-"
-"Scheduling zu aktivieren oder werden Sie Mitglied der Gruppe '"
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr "Scheduling höchster Priorität konfiguriert, jedoch nicht erlaubt."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO erfolgreich erhöht"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO fehlgeschlagen: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Verwerfe CAP_NICE"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr "Echtzeit-Scheduling konfiguriert, jedoch nicht erlaubt."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Daemon läuft nicht"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Daemon läuft als PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Konnte Prozess nicht abbrechen: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -337,192 +219,224 @@ msgstr ""
"Dieses Programm sollte ohne die Option --system nicht als Administrator "
"ausgeführt werden."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Root-Berechtigungen benötigt."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start nicht unterstützt für System-Instanzen."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "System-Modus aktiv, jeodch --disallow-exit nicht gesetzt!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "System-Modus aktiv, jedoch --disallow-module-loading nicht gesetzt!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "System-Modus aktiv, SHM-Modus gezwungenermaßen deaktiviert!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr "System-Modus aktiv, Exit-Idle-Time gezwungenermaßen deaktiviert!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Reservieren von STDIO fehlgeschlagen."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "pipe fehlgeschlagen: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() fehlgeschlagen: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() fehlgeschlagen: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Start des Daemons fehlgeschlagen."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Start des Daemons erfolgreich."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() fehlgeschlagen: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Dies ist PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Kompilier-Host: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "Kompilier-CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Laufe auf Host: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPUs gefunden."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "Seitengröße ist %lu Bytes."
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Kompiliere mit Valgrind-Unterstützung: ja"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Kompiliere mit Valgrind-Unterstützung: nein"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Läuft im Valgrind-Modus: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Laufe auf Host: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Optimiertes Build: ja"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Optimiertes Build: nein"
-#: ../src/daemon/main.c:898
-#, fuzzy
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG definiert, alle Ansprüche deaktiviert."
-#: ../src/daemon/main.c:900
-#, fuzzy
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH definiert, nur fast-path-Ansprüche deaktiviert."
-#: ../src/daemon/main.c:902
-#, fuzzy
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Alle Ansprüche aktiviert."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Beziehen der Maschinen-ID fehlgeschlagen"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "System- ID ist %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
msgstr "System- ID ist %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Nutze Laufzeit-Verzeichnis %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Nutze Zustands-Verzeichnis %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Modul-Verzeichnis %s benutzen."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Laufe im System-Modus: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"OK, nun wird PA im System Mode betrieben. Vorsicht, dies sollte man nicht "
+"tun.\n"
+"Bei Nichtbeachtung, selber Schuld wenn Dinge nicht funktionieren.\n"
+"Für eine Erklärung warum System Mode eine schlechte Idee ist, bitte http://"
+"pulseaudio.org/wiki/WhatIsWrongWithSystemMode lesen"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() fehlgeschlagen."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Neue hochauslösende Timer verfügbar! Guten Appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr "Der Chefkoch empfiehlt: Linux mit aktivierten hochauslösenden Timern!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() fehlgeschlagen."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Konnte Daemon nicht initialisieren."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Daemon verweigert Ausführung, da keine Module geladen."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "Start des Daemons abgeschlossen."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Herunterfahren des Daemon gestartet."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Daemon beendet."
-#: ../src/daemon/cmdline.c:121
-#, fuzzy, c-format
+#: ../src/daemon/cmdline.c:115
+#, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -602,8 +516,8 @@ msgstr ""
" --dump-conf Zeige Standardkonfiguration\n"
" --dump-modules Zeige Liste verfügbarer Module\n"
" --dump-resample-methods Zeige verfügbare Resample-Methoden\n"
-" --cleanup-shm Cleanup stale shared memory "
-"segments\n"
+" --cleanup-shm Bereinige veraltete Bereiche des "
+"gemeinsamen Speichers\n"
" --start Starte Daemon, falls noch nicht "
"geschehen\n"
" -k --kill Laufenden Daemon beenden\n"
@@ -614,7 +528,8 @@ msgstr ""
" --system[=BOOL] Als systemweite Instanz ausführen\n"
" -D, --daemonize[=BOOL] Nach Start zum Daemon machen\n"
" --fail[=BOOL] Beenden, wenn Start fehlschlägt\n"
-" --high-priority[=BOOL] Nutze höchste Priorität\n"
+" --high-priority[=BOOL] Versuche höchste Priorität zu "
+"setzen\n"
" (Nur verfügbar als root, wenn SUID "
"oder\n"
" mit erhöhtem RLIMIT_NICE)\n"
@@ -624,107 +539,113 @@ msgstr ""
"oder\n"
" mit erhöhtem RLIMIT_RTPRIO)\n"
" --disallow-module-loading[=BOOL] Verbiete (Ent-)laden durch Nutzer "
-"angeforderter\n"
+"angefordertere\n"
" Module nach dem Start\n"
" --disallow-exit[=BOOL] Verbiete Beenden auf Anfrage des "
"Nutzers\n"
-" --exit-idle-time=SECS Beende Daemon, wenn für diese Zeit \n"
+" --exit-idle-time=SECS Beende Daemon, wenn für diese Zeit\n"
" untätig\n"
" --module-idle-time=SECS Entlade untätige Module nach dieser "
"Zeit\n"
" --scache-idle-time=SECS Entlade untätige automatisch "
-"geladene \n"
+"geladene\n"
" Samples nach dieser Zeit\n"
-" --log-level[=STUFE] Grad der Ausführlichkeit angeben\n"
+" --log-level[=LEVEL] Grad der Ausführlichkeit angeben\n"
" -v Ausführliche Meldungen\n"
" --log-target={auto,syslog,stderr} Protokoll-Ziel angeben\n"
-" -p, --dl-search-path=PFAD Suchpfad für dynamisch "
-"freigegebene \n"
-" Objekte (Plugins)\n"
-" --resample-method=METHODE Nutze diese Resampling-Methode\n"
+" --log-meta[=BOOL] Speicherort des Codes in "
+"Protokollnachrichtenangeben\n"
+" --log-time[=BOOL] Zeitstempel in Protokollnachrichten "
+"angeben\n"
+" --log-backtrace=FRAMES Backtrace in Protokollnachrichten "
+"angeben\n"
+" -p, --dl-search-path=PATH Suchpfad für dynamisch freigegebene\n"
+" Objekte (Plugins) angeben\n"
+" --resample-method=METHOD Nutze diese Resampling-Methode\n"
" (Siehe --dump-resample-methods für\n"
" mögliche Werte)\n"
" --use-pid-file[=BOOL] Eine PID-Datei erstellen\n"
" --no-cpu-limit[=BOOL] CPU-Lastbegrenzung auf "
"unterstützten\n"
" Systemen nicht installieren.\n"
-" --disable-shm[=BOOL] Keine Unterstützung für Shared "
-"Memory.\n"
+" --disable-shm[=BOOL] Unterstützung für Shared Memory "
+"deaktivieren.\n"
"\n"
-"STARTUP-SCRIPT:\n"
-" -L, --load=\"MODUL-ARGUMENTE\" Plugin-Modul mit diesen Parametern \n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Plugin-Modul mit diesen "
+"Parametern\n"
" laden.\n"
-" -F, --file=DATEINAMEN Dieses Skript ausführen\n"
-" -C Nach Start auf laufendem TTY \n"
+" -F, --file=FILENAME Dieses Skript ausführen\n"
+" -C Nach Start auf laufendem TTY\n"
" eine Kommandozeile öffnen\n"
"\n"
" -n Standardskript nicht laden\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
-msgstr "Option --daemonize erfordert bool'schen Wert"
+msgstr "--daemonize erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
-msgstr "Option --fail erfordert bool'schen Wert"
+msgstr "--fail erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
msgstr ""
-"--log-level erfordert Wert für Grad der Protokollierung (entweder numerisch "
-"im Bereich 0..4 or einen dieser: debug, info, notice, warn, error)."
+"--log-level erfordert Parameter für Grad der Protokollierung (entweder "
+"numerisch im Bereich 0..4 or einen dieser: debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
-msgstr "Option --high-priority erfordert bool'schen Wert"
+msgstr "--high-priority erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
-msgstr "Option --realtime erfordert bool'schen Wert"
+msgstr "--realtime erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
-msgstr "Option --disallow-module-loading erfordert bool'schen Wert"
+msgstr "--disallow-module-loading erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr "--disallow-exit erfordert boolsches Argument"
+msgstr "--disallow-exit erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
-msgstr "Option --use-pid-file erfordert bool'schen Wert"
+msgstr "--use-pid-file erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"Ungültiges Log-Ziel: Benutzen Sie entweder 'syslog', 'stderr' oder 'auto'."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr "--realtime erfordert boolsches Argument"
+msgstr "--realtime erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr "--log-meta erfordert boolschen Wert"
+msgstr "--log-meta erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Ungültige Resample-Methode '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
-msgstr "--System erwartet Boolean-Argument"
+msgstr "--system erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
-msgstr "Option --no-cpu-limit erfordert bool'schen Wert"
+msgstr "--no-cpu-limit erfordert Boolsche Variable"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
-msgstr "Option --disable-shm erfordert bool'schen Wert"
+msgstr "--disable-shm erfordert Boolsche Variable"
#: ../src/daemon/dumpmodules.c:60
#, c-format
@@ -761,78 +682,87 @@ msgstr "Verwendung: %s\n"
msgid "Load Once: %s\n"
msgstr "Lade einmalig: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "WARNUNG (DEPRECATION): %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Pfad: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Ungültiges Log-Ziel '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Ungültige Log-Stufe '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Ungültige Resample-Methode '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Ungültiges rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit auf dieser Plattform nicht unterstützt."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Ungültiges Sample-Format '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Ungültige Sample-Rate '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Ungültige Sample-Kanäle '%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Ungültige Kanal-Zuordnung '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Ungültige Anzahl von Fragmenten '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Ungültige Fragmentgröße '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Ungültige Nice-Stufe '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Ungültige Sample-Rate '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Öffnen der Konfigurationsdatei fehlgeschlagen : %s"
-#: ../src/daemon/daemon-conf.c:538
-#, fuzzy
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -840,18 +770,14 @@ msgstr ""
"Die angegebene Standard-Kanalzuordnung hat eine andere Anzahl von Kanälen "
"als die angegebene Standard-Kanal-Anzahl."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Lese von Konfigurationsdatei: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Root-Privilegien aufgeben."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Fähigkeiten erfolgreich auf CAP_SYS_NICE reduziert."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Root-Privilegien aufräumen."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -861,262 +787,237 @@ msgstr "PulseAudio Sound System"
msgid "Start the PulseAudio Sound System"
msgstr "Das PulseAudio Sound System starten"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-#, fuzzy
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Echtzeit-Terminierung des PulseAudio-Daemon fehlgeschlagen"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-#, fuzzy
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"System-Richtlinien verhindert PulseAudio beim Erlangen des high-priority "
-"scheduling."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-#, fuzzy
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"System-Richtlinien verhindert PulseAudio beim Erlangen der Echtzeit-"
-"Terminierung.."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Vorne Mitte"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Vorne Links"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Vorne Rechts"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Hinten Mitte"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Hinten Links"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Hinten Rechts"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Niedrigfrequenzemitter"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Vorne Links der Mitte"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Vorne Rechts der Mitte"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Seite Links"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Seite Rechts"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Zusatz 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Zusatz 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Zusatz 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Zusatz 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Zusatz 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Zusatz 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Zusatz 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Zusatz 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Zusatz 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Zusatz 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Zusatz 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Zusatz 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Zusatz 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Zusatz 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Zusatz 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Zusatz 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Zusatz 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Zusatz 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Zusatz 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Zusatz 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Zusatz 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Zusatz 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Zusatz 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Zusatz 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Zusatz 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Zusatz 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Zusatz 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Zusatz 26"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Zusatz 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Zusatz 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Zusatz 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Zusatz 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Oben Mitte"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Oben Vorne Mitte"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Oben Vorne Links"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Oben Vorne Rechts"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Oben Hinten Mitte"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Oben Hinten Links"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Oben Hinten Rechts"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(ungültig)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Surround 7.1"
@@ -1126,7 +1027,7 @@ msgstr "OK"
#: ../src/pulse/error.c:44
msgid "Access denied"
-msgstr "Zugriff abgelehnt"
+msgstr "Zugriff verweigert"
#: ../src/pulse/error.c:45
msgid "Unknown command"
@@ -1134,7 +1035,7 @@ msgstr "Unbekannter Befehl"
#: ../src/pulse/error.c:46
msgid "Invalid argument"
-msgstr "Ungültiges Argument"
+msgstr "Ungültiger Parameter"
#: ../src/pulse/error.c:47
msgid "Entity exists"
@@ -1218,29 +1119,37 @@ msgstr "Fehlende Implementation"
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr ""
+msgstr "Client geteilt"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Eingabe/Ausgabe-Fehler"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Gerät oder Ressource beschäftigt"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1253,197 +1162,191 @@ msgstr "XOpenDisplay() fehlgeschlagen"
msgid "Failed to parse cookie data"
msgstr "Parsen der Cookie-Daten fehlgeschlagen"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Konfigurationsdatei '%s' konnte nicht geöffnet werden: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Verbindungsversuch ohne Cookie, da keines geladen."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Nachricht für unbekannte Erweiterung '%s' erhalten"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() fehlgeschlagen: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Entleeren des Streams fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() fehlgeschlagen: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Wiedergabe-Stream entleert."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Stream wurde erfolgreich erstellt.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Verbindung zu Server entleert."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() fehlgeschlagen: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Pufferdaten: maxlenght=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Pufferdaten: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Benutze Sample-Angabe '%s', Kanalzuordnung '%s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Verbunden mit Gerät %s (%u, %sausgesetzt).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Stream wurde erfolgreich erstellt."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Stream-Fehler: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Stream-Gerät ausgesetzt.%s\n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Pufferdaten: maxlenght=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Stream-Gerät reaktiviert.%s\n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Pufferdaten: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Stream unterlaufen.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Benutze Sample-Angabe '%s', Kanalzuordnung '%s'."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Stream überlief.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Verbunden mit Gerät %s (%u, %sausgesetzt)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Stream gestartet: %s\n"
+msgid "Stream error: %s"
+msgstr "Stream-Fehler: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Stream an Gerät %s übergeben (%u, %sausgesetzt).%s \n"
+msgid "Stream device suspended.%s"
+msgstr "Stream-Gerät ausgesetzt.%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "nicht "
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Stream-Zwischenspeicher-Attribute geändert.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "Stream-Gerät reaktiviert.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Verbindung hergestellt.%s \n"
+msgid "Stream underrun.%s"
+msgstr "Stream leergelaufen.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() fehlgeschlagen: %s\n"
+msgid "Stream overrun.%s"
+msgstr "Stream überlaufen.%s "
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() fehlgeschlagen: %s\n"
+msgid "Stream started.%s"
+msgstr "Stream gestartet: %s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() fehlgeschlagen: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Stream an Gerät %s übergeben (%u, %sausgesetzt).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Verbindungsfehler: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "nicht "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Entleeren des Streams fehlgeschlagen: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Stream-Zwischenspeicher-Attribute geändert.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Wiedergabe-Stream entleert.\n"
+msgid "Connection established.%s"
+msgstr "Verbindung hergestellt.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Draining connection to server.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF empfangen.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() fehlgeschlagen: %s\n"
+msgid "Connection failure: %s"
+msgstr "Verbindungsfehler: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() fehlgeschlagen: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF empfangen."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Signal empfangen, beende.\n"
+msgid "write() failed: %s"
+msgstr "write() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Erhalten der Latenz fehlgeschlagen: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Signal empfangen, beenden."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Zeit: %0.3f sec; Latenz: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "Erhalten der Latenz fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() fehlgeschlagen: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Zeit: %0.3f sec; Latenz: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() fehlgeschlagen: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1469,8 +1372,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1493,11 +1398,20 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
-" -h, --help Zeige diese Hilfe\n"
-" --version Zeige Version\n"
+" -h, --help Diese Hilfe anzeigen\n"
+" --version Version anzeigen\n"
"\n"
" -r, --record Aufnahme-Verbindung aufbauen\n"
" -p, --playback Wiedergabe-Verbindung aufbauen\n"
@@ -1505,7 +1419,8 @@ msgstr ""
" -v, --verbose Ausführliche Meldungen\n"
"\n"
" -s, --server=SERVER Name des zu verbindenden Servers\n"
-" -d, --device=DEVICE Name zu verbindender Sink/Quelle\n"
+" -d, --device=DEVICE Name des/der zu verbindender Sink/"
+"Quelle\n"
" -n, --client-name=NAME Rufname des Clients auf dem Server\n"
" --stream-name=NAME Rufname des Streams auf dem Server\n"
" --volume=VOLUME Initiale (lineare) Lautstärke "
@@ -1513,10 +1428,12 @@ msgstr ""
" --rate=SAMPLERATE Sample-Rate in Hz (Standard 44100)\n"
" --format=SAMPLEFORMAT Ein Sample-Format von s16le, s16be, "
"u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
-" --channels=CHANNELS Anzahl Kanäle, 1 für mono, 2 für "
-"stereo\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (Standard ist "
+"s16ne)\n"
+" --channels=CHANNELS Anzahl Kanäle, 1 für Mono, 2 für "
+"Stereo\n"
" (Standard ist 2)\n"
" --channel-map=CHANNELMAP Diese geänderte Kanalzuordnung "
"nutzen\n"
@@ -1533,8 +1450,14 @@ msgstr ""
" --latency=BYTES Diese Latenz verwenden.\n"
" --process-time=BYTES Diese Prozesszeit pro Anfrage "
"verwenden.\n"
+" --property=PROPERTY=VALUE Die angegebene Eigenschaft auf "
+"denspezifizierten Wert setzen.\n"
+" --raw PCM-Rohdaten aufnehmen/wiedergeben.\n"
+" --file-format=FFORMAT Formatierte PCM-Daten aufnehmen/"
+"wiedergeben.\n"
+" --list-file-formats Verfügbare Dateiformate auflisten.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1545,129 +1468,170 @@ msgstr ""
"Kompiliert mit libpulse %s\n"
"Gelinkt mit libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Ungültige Kanal-Zuweisung '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "Ungültiger Client-Name '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Ungültige Latenz-Angaben '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "Ungültiger Stream-Name '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Ungültige Prozesszeit-Angaben '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "Ungültige Kanal-Zuweisung '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Ungültige Sample-Angaben\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Ungültige Latenz-Angaben '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Kanalzuordnung entspricht nicht Einstellungen des Samples\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Ungültige Prozesszeit-Angaben '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Öffne eine %s-Stream mit Sample-Angabe '%s'.\n"
+msgid "Invalid property '%s'"
+msgstr "Ungültige Eigenschaft '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "aufnehmen"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Unbekanntes Dateiformat %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "abspielen"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Ungültige Sample-Angaben"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Zu viele Argumente.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Zu viele Argumente."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() fehlgeschlagen.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Beziehen der Sample-Informationen für die Datei fehlgeschlagen."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() fehlgeschlagen.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Öffnen der Audio-Datei fehlgeschlagen."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() fehlgeschlagen.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "Warnung: Beziehen der Sample-Angabe aus Datei fehlgeschlagen."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_new() fehlgeschlagen: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Beziehen der Sample-Informationen der Datei fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Warnung: Bestimmung der Kanalzuordnung aus Datei fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Kanalzuordnung entspricht nicht Einstellungen des Samples"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Warnung: Schreiben der Kanalzuordnung in Datei fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() fehlgeschlagen.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Öffnen eines %s-Streams mit Sample-Angabe '%s' und Kanalzuordnung '%s'."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "aufnehmen"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "abspielen"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() fehlgeschlagen"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() fehlgeschlagen."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() fehlgeschlagen.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_new() fehlgeschlagen: %s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_new() fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() fehlgeschlagen."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Aussetzen fehlgeschlagen: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Resume fehlgeschlagen: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "WARNUNG: Sound-Server läuft nicht lokal, nicht ausgesetzt.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Verbindungsfehler: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT empfangen, beende.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "WARNUNG: Kind-Prozess durch Signal %u beendet\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1685,7 +1649,7 @@ msgstr ""
" -s, --server=SERVER Name des Zielservers\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1696,35 +1660,61 @@ msgstr ""
"kompiliert mit libpulse %s\n"
"Gelinkt mit libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() fehlgeschlagen.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() fehlgeschlagen.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() fehlgeschlagen.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Beziehen der Statistik fehlgeschlagen: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "Beziehen der Statistik fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Momentane Nutzung: %u Blöcke mit insgesamt %s Bytes.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "Während gesamter Laufzeit: %u Blöcke mit insgesamt %s Bytes.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Sample-Pufferspeichergrösse: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Beziehen der Server-Information fehlgeschlagen: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Beziehen der Server-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1732,24 +1722,24 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Name des Nutzers: %s\n"
"Rechnername: %s\n"
"Name des Servers: %s\n"
-"Version des Server: %s\n"
+"Version des Servers: %s\n"
"Standard-Sample-Angabe: %s\n"
"Standard-Kanal-Zuordnung: %s\n"
-"Standard-Ausgabe: %s\n"
-"-Standard-Quelle: %s\n"
+"Standard-Sink: %s\n"
+"Standard-Quelle: %s\n"
"Cookie: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Erhalten der Sink-Informationen fehlgeschlagen: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Erhalten der Sink-Informationen fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1770,30 +1760,40 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"Senke #%u\n"
+"Sink #%u\n"
"\tStatus: %s\n"
"\tName: %s\n"
"\tBeschreibung: %s\n"
"\tTreiber: %s\n"
"\tSample-Angabe: %s\n"
"\tKanalzuordnung: %s\n"
-"\tOwner-Modul: %u\n"
+"\tBesitzer-Modul: %u\n"
"\tStumm: %s\n"
"\tLautstärke: %s%s%s\n"
"\t Verteilung %0.2f\n"
"\tBasis-Lautstärke: %s%s%s\n"
-"\tQuelle Monitor: %s\n"
+"\tQuellen-Monitor: %s\n"
"\tLatenz: %0.0f usec, eingestellt %0.0f usec\n"
"\tFlags: %s%s%s%s%s%s\n"
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tProfile:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Beziehen der Quellen-Informationen fehlgeschlagen: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tAktive Profile: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Beziehen der Quellen-Informationen fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1826,26 +1826,26 @@ msgstr ""
"\tLautstärke: %s%s%s\n"
"\t Verteilung %0.2f\n"
"\tBasis-Lautstärke: %s%s%s\n"
-"\tSenke-Monitor: %s\n"
+"\tSink-Monitor: %s\n"
"\tLatenz: %0.0f usec, eingestellt %0.0f usec\n"
"\tFlags: %s%s%s%s%s%s\n"
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "k. A."
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Beziehen der Modul-Information fehlgeschlagen: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Beziehen der Modul-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1862,12 +1862,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Beziehen der Client-Information fehlgeschlagen: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Beziehen der Client-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1882,12 +1882,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Beziehen der Karten-Information fehlgeschlagen: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Beziehen der Karten-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1904,22 +1904,22 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tProfile:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tAktive Profile: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Konnte Sink-Eingabe-Informationen nicht holen: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Erhalten der Sink-Eingabe-Informationen fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1939,9 +1939,9 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"Eingabe-Senke #%u\n"
+"Sink-Eingabe #%u\n"
"\tTreiber: %s\n"
-"\tOwner-Modul: %s\n"
+"\tBesitzer-Modul: %s\n"
"\tClient: %s\n"
"\tSink: %u\n"
"\tSample-Angabe: %s\n"
@@ -1956,12 +1956,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Konnte Informationen über Quell-Ausgabe nicht holen: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "Konnte Informationen über Quell-Ausgabe nicht holen: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1990,12 +1990,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Beziehen der Sample-Informationen fehlgeschlagen: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Beziehen der Sample-Informationen fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2026,23 +2026,80 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Fehlgeschlagen: %s\n"
+msgid "Failure: %s"
+msgstr "Fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Hochladen des Sample fehlgeschlagen: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Hochladen des Sample fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Dateiende ist zu früh aufgetreten\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Dateiende ist zu früh aufgetreten"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Ungültiger Server"
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT empfangen, beenden."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2050,13 +2107,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2069,24 +2135,32 @@ msgstr ""
"%s [options] stat\n"
"%s [options] list\n"
"%s [options] exit\n"
-"%s [options] upload-sample DATEINAMEN [NAME]\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID-QUELLE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [QUELLE] 1|0\n"
-"%s [options] suspend-source [KARTE] [QUELLE] 1|0\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
-" -h, --help Zeige diese Hilfe\n"
-" --version Zeige Version\n"
+" -h, --help Diese Hilfe anzeigen\n"
+" --version Version anzeigen\n"
"\n"
" -s, --server=SERVER Name des Zielservers\n"
" -n, --client-name=NAME Rufname des Clients auf dem Server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2097,79 +2171,117 @@ msgstr ""
"Kompiliert mit libpulse %s\n"
"Gelinkt mit libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Geben Sie eine zu öffnende Sample-Datei an\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Geben Sie eine zu öffnende Sample-Datei an"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Öffnen der Audio-Datei fehlgeschlagen.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Öffnen der Audio-Datei fehlgeschlagen."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Sie müssen eine abzuspielende Sample-Datei angeben\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Warnung: Beziehen der Sample-Angabe aus Datei fehlgeschlagen."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Sie müssen eine zu löschende Sample-Datei angeben\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Sie müssen eine abzuspielende Sample-Datei angeben"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Sie müssen einen Sink-Eingabe-Indexwert und einen Sink angeben\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Sie müssen eine zu löschende Sample-Datei angeben"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Sie müssen einen Sink-Eingabe-Indexwert und einen Sink angeben"
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
msgstr ""
-"Sie müssen eine Indexwert für die Quell-Ausgabe und eine Quelle angeben\n"
+"Sie müssen eine Indexwert für die Quell-Ausgabe und eine Quelle angeben"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Sie müssen einen Modulnamen angeben und Argumente übergeben.\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Sie müssen einen Modulnamen angeben und Argumente übergeben."
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Sie müssen einen Indexwert für ein Modul angeben\n"
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Sie müssen einen Indexwert für ein Modul angeben"
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"Sie sollten nur eine Senke angeben. Sie müssen zumindest einen bool'schen "
-"Wert übergeben.\n"
+"Sie sollten nur einen Sink angeben. Sie müssen zumindest eine Boolsche "
+"Variable übergeben."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"Sie sollten nur eine Quelle angeben. Sie müssen zumindest einen bool'schen "
-"Wert übergeben.\n"
+"Sie sollten nur eine Quelle angeben. Sie müssen zumindest eine Boolsche "
+"Variable übergeben."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Sie müssen einen Karten-Name/Indexwert und einen Profilnamen angeben\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Sie müssen einen Karten-Name/Indexwert und einen Profilnamen angeben"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Kein gültiger Befehl angegeben.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Sie müssen einen Sink-Namen/-Indexwert und einen Portnamen angeben"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_new() fehlgeschlagen: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Sie müssen einen Quellennamen/-Indexwert und einen Portnamen angeben"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Sie müssen einen Sink-Namen/-Indexwert und eine Lautstärke angeben"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Ungültige Sample-Angaben"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Sie müssen einen Quellennamen/-Indexwert und einen Portnamen angeben"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Sie müssen einen Sink-Eingabe-Indexwert und eine Lautstärke angeben."
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ungültiger Sink-Eingabe-Index"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+"Sie müssen einen Sink-Namen/-Indexwert und eine Boolsche Variable für "
+"Stummschaltung angeben"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr ""
+"Sie müssen einen Quellennamen/-Indexwert und eine Boolsche Variable für "
+"Stummschaltung angeben"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+"Sie müssen einen Sink-Eingabe-Indexwert und eine Boolsche Variable für "
+"Stummschaltung angeben"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Ungültige Sink-Eingabe-Index-Angaben"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Kein gültiger Befehl angegeben."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2218,7 +2330,7 @@ msgstr "Cookie: %s\n"
#: ../src/utils/pax11publish.c:132
#, c-format
msgid "Failed to parse cookie data\n"
-msgstr "Paresen der Cookie-Daten fehlgeschlagen.\n"
+msgstr "Parsen der Cookie-Daten fehlgeschlagen.\n"
#: ../src/utils/pax11publish.c:137
#, c-format
@@ -2250,126 +2362,48 @@ msgstr "Laden der Cookie-Daten fehlgeschlagen\n"
msgid "Not yet implemented.\n"
msgstr "Noch nicht implementiert.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "Es läuft kein PulseAudio-Dienst oder nicht als Sessiondienst."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
-msgstr "Terminieren des PulseAudio-Daemon fehlgeschlagen."
+msgstr "Beenden des PulseAudio-Daemon fehlgeschlagen."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Daemon antwortet nicht."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Stream erfolgreich erzeugt\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Stream-Fehler: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Verbindung hergestellt.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Zeige diese Hilfe\n"
-" --version Zeige Version\n"
-"\n"
-" -v, --verbose Ausführliche Meldungen\n"
-"\n"
-" -s, --server=SERVER Name des Zielservers\n"
-" -d, --device=DEVICE Name des Ziel-Sink\n"
-" -n, --client-name=NAME Rufname des Clients auf dem Server\n"
-" --stream-name=NAME Rufname des Streams auf dem Server\n"
-" --volume=VOLUME Initiale (lineare) Lautstärke "
-"zwischen 0...65536\n"
-" --channel-map=CHANNELMAP Diese Kanalzuordnung nutzen\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Kompliert mit libpulse %s\n"
-"Gelinkt mit libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Ungültige Kanal-Zuweisung\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Öffnen der Datei '%s' fehlgeschlagen\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Kanal-Zuweisung stimmt mit Datei nicht überein.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Sampling-Angabe '%s' wird benutzt\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
-msgstr "Fehler beim Zugriff auf Autostart -Sperre."
+msgstr "Fehler beim Zugriff auf Autostart-Sperre."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2379,8 +2413,15 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA weckte uns auf, um neue Daten auf das Gerät zu schreiben, doch es gab "
+"nichts zum Schreiben!\n"
+"Dies ist höchstwahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden "
+"Sie diesen Fehler den ALSA-Entwicklern.\n"
+"Wir wurden durch das POLLOUT-Set geweckt, allerdings lieferte ein "
+"anschliessender snd_pcm_avail() den Wert 0 oder einen anderen Wert < "
+"min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2390,90 +2431,267 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Ausgabe %s + Eingabe %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Ausgang %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Eingang %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+"ALSA weckte uns auf, um neue Daten vom Gerät zu lesen, doch es gab nichts "
+"zum Lesen!\n"
+"Dies ist höchstwahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden "
+"Sie diesen Fehler den ALSA-Entwicklern.\n"
+"Wir wurden durch das POLLIN-Set geweckt, allerdings lieferte ein "
+"anschliessender snd_pcm_avail() den Wert 0 oder einen anderen Wert < "
+"min_avail."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "Aus"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "High Fidelity Playback (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "High Fidelity-Wiedergabe (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "Telephony Duplex (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio Sound Server"
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Ausgabegeräte"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Eingabegeräte"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Audio auf @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Eingabe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Docking Station Eingabe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Docking Station Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Line-In"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Externes Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Internes Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Automatische Verstärkungsregelung"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Keine automatische Verstärkungsregelung"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Kein Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Verstärker"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Kein Verstärker"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
#, fuzzy
-#~ msgid ""
-#~ "Called SUID root and real-time and/or high-priority scheduling was "
-#~ "requested in the configuration. However, we lack the necessary "
-#~ "privileges:\n"
-#~ "We are not in group '"
-#~ msgstr ""
-#~ "Konfiguration fordert Aufruf der SUID root und Echtzeit-Scheduling "
-#~ "höchster Priorität. Allerdings fehlen die nötigen Rechte:\n"
-#~ "Wir befinden uns nicht in der Gruppe '"
-
-#~ msgid "--log-time boolean argument"
-#~ msgstr "--log-time erfordert bool'schen Wert"
-
-#~ msgid ""
-#~ "', or increase the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this "
-#~ "user."
-#~ msgstr ""
-#~ "' oder erhöhen sie die RLIMIT_NICE/RLIMIT_RTPRIO-Ressourcenbegrenzungen "
-#~ "für diesen Nutzer."
-
-#~ msgid "Default sink name (%s) does not exist in name register."
-#~ msgstr "Vorgabename für Sink (%s) existiert nicht im Namensregister."
-
-#~ msgid "Buffer overrun, dropping incoming data\n"
-#~ msgstr "Pufferüberlauf, verwerfe eingehende Daten\n"
-
-#~ msgid "pa_stream_drop() failed: %s\n"
-#~ msgstr "pa_stream_drop() fehlgeschlagen: %s\n"
-
-#~ msgid "muted"
-#~ msgstr "stumm"
-
-#~ msgid ""
-#~ "*** Autoload Entry #%u ***\n"
-#~ "Name: %s\n"
-#~ "Type: %s\n"
-#~ "Module: %s\n"
-#~ "Argument: %s\n"
-#~ msgstr ""
-#~ "*** Autoload-Eintrag #%u ***\n"
-#~ "Name: %s\n"
-#~ "Typ: %s\n"
-#~ "Modul: %s\n"
-#~ "Argument: %s\n"
-
-#~ msgid "sink"
-#~ msgstr "Sink"
-
-#~ msgid "source"
-#~ msgstr "Quelle"
-
-#~ msgid "socketpair(): %s"
-#~ msgstr "socketpair(): %s"
+msgid "No Bass Boost"
+msgstr "Kein Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Analoge Kopfhörer"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Analoge Eingabe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Analoges Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Analoges Line-In"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Analoges Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Analoges Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Analoge Ausgabe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Analoge Kopfhörer"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Analoge Ausgabe (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analoge Mono-Ausgabe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analog Surround 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analog Surround 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analog Surround 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analog Surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analog Surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analog Surround 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analog Surround 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analog Surround 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analog Surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digital Stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digital Surround 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digital Surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digital Surround 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digital Stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analog Mono Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analog Stereo Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Digital Stereo Duplex (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Niedrigfrequenzemitter"
diff --git a/po/de_CH.po b/po/de_CH.po
index 68076bd4..e31419f8 100644
--- a/po/de_CH.po
+++ b/po/de_CH.po
@@ -3,66 +3,28 @@
# This file is distributed under the same license as the pulseaudio package.
#
# Fabian Affolter <fab@fedoraproject.org>, 2008-2009.
+# Micha Pietsch <barney@fedoraproject.org>, 2008, 2009.
#
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-18 12:55+0100\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-09-14 10:22+0100\n"
"Last-Translator: Fabian Affolter <fab@fedoraproject.org>\n"
"Language-Team: German <fedora-trans-de@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-"X-Poedit-Language: Swiss German\n"
+"X-Poedit-Language: German\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analog Mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analog Stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Digital Stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Digital Stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analog Surround 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digital Surround 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analog Surround 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analog Surround 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analog Surround 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digital Surround 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analog Surround 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -70,12 +32,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
-"snd_pcm_avail() gibt einen Wert zurück, welche ausserordentlich gross ist: %"
-"lu bytes (%lu ms).\n"
+"snd_pcm_avail() gibt einen Wert zurück, welche außerordentlich groß ist: %lu "
+"bytes (%lu ms).\n"
"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
"diesen Punkt den ALSA-Entwicklern."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -83,12 +45,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
-"snd_pcm_delay() gibt einen Wert zurück, welche ausserordentlich gross ist: %"
-"li bytes (%s%lu ms).\n"
+"snd_pcm_delay() gibt einen Wert zurück, welche außerordentlich groß ist: %li "
+"bytes (%s%lu ms).\n"
"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
"diesen Punkt den ALSA-Entwicklern."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -96,16 +58,47 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
-"snd_pcm_mmap_begin() gibt einen Wert zurück, welche ausserordentlich gross "
+"snd_pcm_mmap_begin() gibt einen Wert zurück, welche außerordentlich groß "
"ist: %lu bytes (%lu ms).\n"
"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
"diesen Punkt den ALSA-Entwicklern."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Dummy-Ausgabe"
+
+#: ../src/modules/module-ladspa-sink.c:49
+#, fuzzy
+msgid "Virtual LADSPA sink"
+msgstr "Virtueller LADSPA-Sink"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr ""
+
+#: ../src/modules/module-null-sink.c:291
+#, fuzzy
+msgid "Null Output"
+msgstr "Ausgang %s"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Internes Audio"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Modem"
@@ -121,214 +114,98 @@ msgstr "Neuer dlopen-Loader konnte nicht gefunden werden."
msgid "Failed to add bind-now-loader."
msgstr "Hinzufügen von Bind-Now-Loader fehlgeschlagen."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Kann nicht mit dem System-Bus verbinden: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Kann Caller von PID nicht beziehen: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Kann UID für Caller-Objekt nicht setzen."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Kann CK-Session nicht beziehen."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Kann UID für Session-Objekt nicht setzen."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Konnte PolKitAction nicht zuordnen."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Kann action_id nicht setzen"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Konnte PolKitContext nicht zuordnen."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Konnte PolKitContext nicht initialisieren: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Autorisierung des Callers konnte nicht sichergestellt werden: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Keine Authorisierung erhalten: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit antwortete mit '%s'"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Signal %s empfangen."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Wird beendet."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Benutzer '%s' nicht gefunden."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Gruppe '%s' nicht gefunden."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Benutzer '%s' (UID %lu) und Gruppe '%s' (GID %lu) gefunden."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID von Benutzer '%s' und Gruppe '%s' stimmen nicht überein."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Benutzerverzeichnis von Benutzer '%s' ist nicht '%s', ignoriere."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Konnte '%s' nciht erzeugen: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Wechseln der Gruppen-Liste fehlgeschlagen: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Wechseln der GID fehlgeschlagen: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Wechseln der UID fehlgeschlagen: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Root-Berechtigungen erfolgreich zurückgesetzt."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "System-Modus auf dieser Plattform nicht unterstützt."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) fehlgeschlagen: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Parsen der Kommandzeile fehlgeschlagen."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Wir befinden uns in der Gruppe '%s', was Scheduling höchster Priorität "
-"ermöglicht."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Wir befinden uns in der Gruppe '%s', was Echtzeit-Scheduling ermöglicht."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "Richtlinien gewähren das Recht aquire-high-priority."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "Richtlinien verweigern das Recht acquire-high-priority."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "Richtlinien gewähren das Recht aquire-real-time."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "Richtlinien verweigern das Recht acquire-real-time."
-
-#: ../src/daemon/main.c:556
-#, fuzzy, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"' und PolicyKit verweigern diese Rechte. Verwerfe SUID wieder.\n"
-"Erlangen Sie die den Richtlinien entsprechenden Rechte, um Echtzeit-"
-"Scheduling zu aktivieren oder werden Sie Mitglied der Gruppe '"
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr "Scheduling höchster Priorität konfiguriert, jedoch nicht erlaubt."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO erfolgreich erhöht"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO fehlgeschlagen: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Verwerfe CAP_NICE"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr "Echtzeit-Scheduling konfiguriert, jedoch nicht erlaubt."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Daemon läuft nicht"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Daemon läuft als PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Konnte Prozess nicht abbrechen: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -336,191 +213,218 @@ msgstr ""
"Dieses Programm sollte ohne die Option --system nicht als Administrator "
"ausgeführt werden."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Root-Berechtigungen benötigt."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start nicht unterstützt für System-Instanzen."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "System-Modus aktiv, jeodch --disallow-exit nicht gesetzt!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "System-Modus aktiv, jedoch --disallow-module-loading nicht gesetzt!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
-msgstr "System-Modus aktiv, SHM-Modus gezwungenermassen deaktiviert!"
+msgstr "System-Modus aktiv, SHM-Modus gezwungenermaßen deaktiviert!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
-msgstr "System-Modus aktiv, Exit-Idle-Time gezwungenermassen deaktiviert!"
+msgstr "System-Modus aktiv, Exit-Idle-Time gezwungenermaßen deaktiviert!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Reservieren von STDIO fehlgeschlagen."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "pipe fehlgeschlagen: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() fehlgeschlagen: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() fehlgeschlagen: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Start des Daemons fehlgeschlagen."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Start des Daemons erfolgreich."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() fehlgeschlagen: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Dies ist PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Kompilier-Host: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "Kompilier-CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Laufe auf Host: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPUs gefunden."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
-msgstr "Seitengrösse ist %lu Bytes."
+msgstr "Seitengröße ist %lu Bytes."
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Kompiliere mit Valgrind-Unterstützung: ja"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Kompiliere mit Valgrind-Unterstützung: nein"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Läuft im Valgrind-Modus: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Laufe auf Host: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Optimiertes Build: ja"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Optimiertes Build: nein"
-#: ../src/daemon/main.c:898
-#, fuzzy
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG definiert, alle Ansprüche deaktiviert."
-#: ../src/daemon/main.c:900
-#, fuzzy
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH definiert, nur fast-path-Ansprüche deaktiviert."
-#: ../src/daemon/main.c:902
-#, fuzzy
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Alle Ansprüche aktiviert."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Beziehen der Maschinen-ID fehlgeschlagen"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "System- ID ist %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
msgstr "System- ID ist %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Nutze Laufzeit-Verzeichnis %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Nutze Zustands-Verzeichnis %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Modul-Verzeichnis %s benutzen."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Laufe im System-Modus: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() fehlgeschlagen."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Neue hochauslösende Timer verfügbar! Guten Appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr "Der Chefkoch empfiehlt: Linux mit aktivierten hochauslösenden Timern!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() fehlgeschlagen."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Konnte Daemon nicht initialisieren."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Daemon verweigert Ausführung, da keine Module geladen."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "Start des Daemons abgeschlossen."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Herunterfahren des Daemon gestartet."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Daemon beendet."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, fuzzy, c-format
msgid ""
"%s [options]\n"
@@ -659,15 +563,15 @@ msgstr ""
"\n"
" -n Standardskript nicht laden\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "Option --daemonize erfordert bool'schen Wert"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "Option --fail erfordert bool'schen Wert"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -675,53 +579,53 @@ msgstr ""
"--log-level erfordert Wert für Grad der Protokollierung (entweder numerisch "
"im Bereich 0..4 or einen dieser: debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "Option --high-priority erfordert bool'schen Wert"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "Option --realtime erfordert bool'schen Wert"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "Option --disallow-module-loading erfordert bool'schen Wert"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit erfordert boolsches Argument"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "Option --use-pid-file erfordert bool'schen Wert"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"Ungültiges Log-Ziel: Benutzen Sie entweder 'syslog', 'stderr' oder 'auto'."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--realtime erfordert boolsches Argument"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta erfordert boolschen Wert"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Ungültige Resample-Methode '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--System erwartet Boolean-Argument"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "Option --no-cpu-limit erfordert bool'schen Wert"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "Option --disable-shm erfordert bool'schen Wert"
@@ -760,78 +664,87 @@ msgstr "Verwendung: %s\n"
msgid "Load Once: %s\n"
msgstr "Lade einmalig: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, fuzzy, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Pfad: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Ungültiges Log-Ziel '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Ungültige Log-Stufe '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Ungültige Resample-Methode '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Ungültiges rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit auf dieser Plattform nicht unterstützt."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Ungültiges Sample-Format '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Ungültige Sample-Rate '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Ungültige Sample-Kanäle '%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Ungültige Kanal-Zuordnung '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Ungültige Anzahl von Fragmenten '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
-msgstr "[%s:%u] Ungültige Fragmentgrösse '%s'."
+msgstr "[%s:%u] Ungültige Fragmentgröße '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Ungültige Nice-Stufe '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Ungültige Sample-Rate '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Öffnen der Konfigurationsdatei fehlgeschlagen : %s"
-#: ../src/daemon/daemon-conf.c:538
-#, fuzzy
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -839,18 +752,14 @@ msgstr ""
"Die angegebene Standard-Kanalzuordnung hat eine andere Anzahl von Kanälen "
"als die angegebene Standard-Kanal-Anzahl."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Lese von Konfigurationsdatei: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Root-Privilegien aufgeben."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Fähigkeiten erfolgreich auf CAP_SYS_NICE reduziert."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Root-Privilegien aufräumen."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -860,265 +769,237 @@ msgstr "PulseAudio Sound System"
msgid "Start the PulseAudio Sound System"
msgstr "Das PulseAudio Sound System starten"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-#, fuzzy
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"High-priority scheduling (verkleinere Unix nice-Stufe) für den PulseAudio-"
-"Daemon"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-#, fuzzy
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Echtzeit-Terminierung des PulseAudio-Daemon fehlgeschlagen"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-#, fuzzy
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"System-Richtlinien verhindert PulseAudio beim Erlangen des high-priority "
-"scheduling."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-#, fuzzy
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"System-Richtlinien verhindert PulseAudio beim Erlangen der Echtzeit-"
-"Terminierung.."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Vorne Mitte"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Vorne Links"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Vorne Rechts"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Hinten Mitte"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Hinten Links"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Hinten Rechts"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Niedrigfrequenzemitter"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Vorne Links der Mitte"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Vorne Rechts der Mitte"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Seite Links"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Seite Rechts"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Zusatz 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Zusatz 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Zusatz 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Zusatz 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Zusatz 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Zusatz 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Zusatz 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Zusatz 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Zusatz 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Zusatz 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Zusatz 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Zusatz 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Zusatz 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Zusatz 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Zusatz 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Zusatz 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Zusatz 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Zusatz 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Zusatz 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Zusatz 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Zusatz 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Zusatz 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Zusatz 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Zusatz 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Zusatz 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Zusatz 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Zusatz 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Zusatz 26"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Zusatz 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Zusatz 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Zusatz 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Zusatz 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Oben Mitte"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Oben Vorne Mitte"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Oben Vorne Links"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Oben Vorne Rechts"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Oben Hinten Mitte"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Oben Hinten Links"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Oben Hinten Rechts"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(ungültig)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Surround 7.1"
@@ -1196,7 +1077,7 @@ msgstr "Inkompatible Protokollversion"
#: ../src/pulse/error.c:61
msgid "Too large"
-msgstr "Zu gross"
+msgstr "Zu groß"
#: ../src/pulse/error.c:62
msgid "Not supported"
@@ -1219,31 +1100,38 @@ msgid "Missing implementation"
msgstr "Fehlende Implementation"
#: ../src/pulse/error.c:67
-#, fuzzy
msgid "Client forked"
-msgstr "Client geforket"
+msgstr "Client geteilt"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Eingabe/Ausgabe-Fehler"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Gerät oder Ressource beschäftigt"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1256,197 +1144,191 @@ msgstr "XOpenDisplay() fehlgeschlagen"
msgid "Failed to parse cookie data"
msgstr "Parsen der Cookie-Daten fehlgeschlagen"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Konfigurationsdatei '%s' konnte nicht geöffnet werden: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Verbindungsversuch ohne Cookie, da keines geladen."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Nachricht für unbekannte Erweiterung '%s' erhalten"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() fehlgeschlagen: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Entleeren des Streams fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() fehlgeschlagen: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Wiedergabe-Stream entleert."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Stream wurde erfolgreich erstellt.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Verbindung zu Server entleert."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() fehlgeschlagen: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Pufferdaten: maxlenght=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Pufferdaten: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Benutze Sample-Angabe '%s', Kanalzuordnung '%s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Verbunden mit Gerät %s (%u, %sausgesetzt).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Stream wurde erfolgreich erstellt."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Stream-Fehler: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Stream-Gerät ausgesetzt.%s\n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Pufferdaten: maxlenght=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Stream-Gerät reaktiviert.%s\n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Pufferdaten: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Stream unterlaufen.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Benutze Sample-Angabe '%s', Kanalzuordnung '%s'."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Stream überlief.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Verbunden mit Gerät %s (%u, %sausgesetzt)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Stream gestartet: %s\n"
+msgid "Stream error: %s"
+msgstr "Stream-Fehler: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Stream an Gerät %s übergeben (%u, %sausgesetzt).%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "nicht "
+msgid "Stream device suspended.%s"
+msgstr "Stream-Gerät ausgesetzt.%s"
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Stream-Zwischenspeicher-Attribute geändert.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "Stream-Gerät reaktiviert.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Verbindung hergestellt.%s \n"
+msgid "Stream underrun.%s"
+msgstr "Stream leergelaufen.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() fehlgeschlagen: %s\n"
+msgid "Stream overrun.%s"
+msgstr "Stream überlaufen.%s "
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() fehlgeschlagen: %s\n"
+msgid "Stream started.%s"
+msgstr "Stream gestartet: %s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() fehlgeschlagen: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Stream an Gerät %s übergeben (%u, %sausgesetzt).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Verbindungsfehler: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "nicht "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Entleeren des Streams fehlgeschlagen: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Stream-Zwischenspeicher-Attribute geändert.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Wiedergabe-Stream entleert.\n"
+msgid "Connection established.%s"
+msgstr "Verbindung hergestellt.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Draining connection to server.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF empfangen.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() fehlgeschlagen: %s\n"
+msgid "Connection failure: %s"
+msgstr "Verbindungsfehler: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() fehlgeschlagen: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF empfangen."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Signal empfangen, beende.\n"
+msgid "write() failed: %s"
+msgstr "write() fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Erhalten der Latenz fehlgeschlagen: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Signal empfangen, beenden."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Zeit: %0.3f sec; Latenz: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "Erhalten der Latenz fehlgeschlagen: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() fehlgeschlagen: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Zeit: %0.3f sec; Latenz: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() fehlgeschlagen: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1472,8 +1354,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1496,11 +1380,20 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
-" -h, --help Zeige diese Hilfe\n"
-" --version Zeige Version\n"
+" -h, --help Diese Hilfe anzeigen\n"
+" --version Version anzeigen\n"
"\n"
" -r, --record Aufnahme-Verbindung aufbauen\n"
" -p, --playback Wiedergabe-Verbindung aufbauen\n"
@@ -1537,7 +1430,7 @@ msgstr ""
" --process-time=BYTES Diese Prozesszeit pro Anfrage "
"verwenden.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1548,129 +1441,170 @@ msgstr ""
"Kompiliert mit libpulse %s\n"
"Gelinkt mit libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Ungültige Kanal-Zuweisung '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "Ungültiger Client-Name '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Ungültige Latenz-Angaben '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "Ungültiger Stream-Name '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Ungültige Prozesszeit-Angaben '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "Ungültige Kanal-Zuweisung '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Ungültige Sample-Angaben\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Ungültige Latenz-Angaben '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Kanalzuordnung entspricht nicht Einstellungen des Samples\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Ungültige Prozesszeit-Angaben '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Öffne eine %s-Stream mit Sample-Angabe '%s'.\n"
+msgid "Invalid property '%s'"
+msgstr "Ungültige Eigenschaft '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "aufnehmen"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Unbekanntes Dateiformat %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "abspielen"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Ungültige Sample-Angaben"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Zu viele Argumente.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Zu viele Argumente."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() fehlgeschlagen.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Beziehen der Sample-Informationen für die Datei fehlgeschlagen."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() fehlgeschlagen.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Öffnen der Audio-Datei fehlgeschlagen."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() fehlgeschlagen.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "Warnung: Beziehen der Sample-Angabe aus Datei fehlgeschlagen."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_new() fehlgeschlagen: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Beziehen der Sample-Informationen der Datei fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Warnung: Bestimmung der Kanalzuordnung aus Datei fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Kanalzuordnung entspricht nicht Einstellungen des Samples"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Warnung: Schreiben der Kanalzuordnung in Datei fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() fehlgeschlagen.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Öffnen eines %s-Streams mit Sample-Angabe '%s' und Kanalzuordnung '%s'."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "aufnehmen"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "abspielen"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() fehlgeschlagen"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() fehlgeschlagen."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() fehlgeschlagen."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() fehlgeschlagen.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_new() fehlgeschlagen: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_new() fehlgeschlagen."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() fehlgeschlagen."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Aussetzen fehlgeschlagen: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Resume fehlgeschlagen: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "WARNUNG: Sound-Server läuft nicht lokal, nicht ausgesetzt.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Verbindungsfehler: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT empfangen, beende.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "WARNUNG: Kind-Prozess durch Signal %u beendet\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1688,7 +1622,7 @@ msgstr ""
" -s, --server=SERVER Name des Zielservers\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1699,35 +1633,61 @@ msgstr ""
"kompiliert mit libpulse %s\n"
"Gelinkt mit libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Beziehen der Statistik fehlgeschlagen: %s\n"
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() fehlgeschlagen.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() fehlgeschlagen.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() fehlgeschlagen.\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Beziehen der Statistik fehlgeschlagen: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Momentane Nutzung: %u Blöcke mit insgesamt %s Bytes.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "Während gesamter Laufzeit: %u Blöcke mit insgesamt %s Bytes.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Sample-Pufferspeichergrösse: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Beziehen der Server-Information fehlgeschlagen: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Beziehen der Server-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1735,7 +1695,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Name des Nutzers: %s\n"
"Rechnername: %s\n"
@@ -1747,12 +1707,12 @@ msgstr ""
"-Standard-Quelle: %s\n"
"Cookie: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Erhalten der Sink-Informationen fehlgeschlagen: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Erhalten der Sink-Informationen fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1791,12 +1751,22 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Beziehen der Quellen-Informationen fehlgeschlagen: %s\n"
+msgid "\tPorts:\n"
+msgstr "\tProfile:\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tAktive Profile: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Beziehen der Quellen-Informationen fehlgeschlagen: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1835,20 +1805,20 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "k. A."
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Beziehen der Modul-Information fehlgeschlagen: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Beziehen der Modul-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1865,12 +1835,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Beziehen der Client-Information fehlgeschlagen: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Beziehen der Client-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1885,12 +1855,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Beziehen der Karten-Information fehlgeschlagen: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Beziehen der Karten-Information fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1907,22 +1877,22 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tProfile:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tAktive Profile: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Konnte Sink-Eingabe-Informationen nicht holen: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Konnte Sink-Eingabe-Informationen nicht holen: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1959,12 +1929,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Konnte Informationen über Quell-Ausgabe nicht holen: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "Konnte Informationen über Quell-Ausgabe nicht holen: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1993,12 +1963,12 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Beziehen der Sample-Informationen fehlgeschlagen: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Beziehen der Sample-Informationen fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2029,23 +1999,81 @@ msgstr ""
"\tEigenschaften:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Fehlgeschlagen: %s\n"
+msgid "Failure: %s"
+msgstr "Fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Hochladen des Sample fehlgeschlagen: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Hochladen des Sample fehlgeschlagen: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Dateiende ist zu früh aufgetreten\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Dateiende ist zu früh aufgetreten"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr "Sink"
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr "Quelle"
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+#, fuzzy
+msgid "source-output"
+msgstr "Quelle"
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Ungültiger Server"
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT empfangen, beenden."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2053,13 +2081,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2072,24 +2109,32 @@ msgstr ""
"%s [options] stat\n"
"%s [options] list\n"
"%s [options] exit\n"
-"%s [options] upload-sample DATEINAMEN [NAME]\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID-QUELLE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [QUELLE] 1|0\n"
-"%s [options] suspend-source [KARTE] [QUELLE] 1|0\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
-" -h, --help Zeige diese Hilfe\n"
-" --version Zeige Version\n"
+" -h, --help Diese Hilfe anzeigen\n"
+" --version Version anzeigen\n"
"\n"
" -s, --server=SERVER Name des Zielservers\n"
" -n, --client-name=NAME Rufname des Clients auf dem Server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2100,79 +2145,111 @@ msgstr ""
"Kompiliert mit libpulse %s\n"
"Gelinkt mit libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Geben Sie eine zu öffnende Sample-Datei an\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Geben Sie eine zu öffnende Sample-Datei an"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Öffnen der Audio-Datei fehlgeschlagen.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Öffnen der Audio-Datei fehlgeschlagen."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Sie müssen eine abzuspielende Sample-Datei angeben\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Warnung: Beziehen der Sample-Angabe aus Datei fehlgeschlagen."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Sie müssen eine zu löschende Sample-Datei angeben\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Sie müssen eine abzuspielende Sample-Datei angeben"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Sie müssen einen Sink-Eingabe-Indexwert und einen Sink angeben\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Sie müssen eine zu löschende Sample-Datei angeben"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Sie müssen einen Sink-Eingabe-Indexwert und einen Sink angeben"
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
msgstr ""
-"Sie müssen eine Indexwert für die Quell-Ausgabe und eine Quelle angeben\n"
+"Sie müssen eine Indexwert für die Quell-Ausgabe und eine Quelle angeben"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Sie müssen einen Modulnamen angeben und Argumente übergeben.\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Sie müssen einen Modulnamen angeben und Argumente übergeben."
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Sie müssen einen Indexwert für ein Modul angeben\n"
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Sie müssen einen Indexwert für ein Modul angeben"
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
"Sie sollten nur eine Senke angeben. Sie müssen zumindest einen bool'schen "
-"Wert übergeben.\n"
+"Wert übergeben."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
"Sie sollten nur eine Quelle angeben. Sie müssen zumindest einen bool'schen "
-"Wert übergeben.\n"
+"Wert übergeben."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Sie müssen einen Karten-Name/Indexwert und einen Profilnamen angeben\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Sie müssen einen Karten-Name/Indexwert und einen Profilnamen angeben"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Kein gültiger Befehl angegeben.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Sie müssen einen Senkennamen/-Indexwert und einen Portnamen angeben"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_new() fehlgeschlagen: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Sie müssen einen Quellennamen/-Indexwert und einen Portnamen angeben"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Sie müssen einen Senkennamen/-Indexwert und einen Portnamen angeben"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Ungültige Sample-Angaben"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Sie müssen einen Quellennamen/-Indexwert und einen Portnamen angeben"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Sie müssen einen Sink-Eingabe-Indexwert und einen Sink angeben"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ungültiger Sink-Eingabe-Index"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Sie müssen einen Senkennamen/-Indexwert und einen Portnamen angeben"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Sie müssen einen Quellennamen/-Indexwert und einen Portnamen angeben"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "Sie müssen einen Sink-Eingabe-Indexwert und einen Sink angeben"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Ungültige Sink-Eingabe-Index-Angaben"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Kein gültiger Befehl angegeben."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2253,126 +2330,48 @@ msgstr "Laden der Cookie-Daten fehlgeschlagen\n"
msgid "Not yet implemented.\n"
msgstr "Noch nicht implementiert.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "Es läuft kein PulseAudio-Dienst oder nicht als Sessiondienst."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Terminieren des PulseAudio-Daemon fehlgeschlagen."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Daemon antwortet nicht."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Stream erfolgreich erzeugt\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Stream-Fehler: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Verbindung hergestellt.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Zeige diese Hilfe\n"
-" --version Zeige Version\n"
-"\n"
-" -v, --verbose Ausführliche Meldungen\n"
-"\n"
-" -s, --server=SERVER Name des Zielservers\n"
-" -d, --device=DEVICE Name des Ziel-Sink\n"
-" -n, --client-name=NAME Rufname des Clients auf dem Server\n"
-" --stream-name=NAME Rufname des Streams auf dem Server\n"
-" --volume=VOLUME Initiale (lineare) Lautstärke "
-"zwischen 0...65536\n"
-" --channel-map=CHANNELMAP Diese Kanalzuordnung nutzen\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Kompliert mit libpulse %s\n"
-"Gelinkt mit libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Ungültige Kanal-Zuweisung\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Öffnen der Datei '%s' fehlgeschlagen\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Kanal-Zuweisung stimmt mit Datei nicht überein.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Sampling-Angabe '%s' wird benutzt\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Fehler beim Zugriff auf Autostart -Sperre."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2382,15 +2381,8 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
-"ALSA ist aufgewacht zum Schreiben von neuen Daten auf das Gerät, aber es "
-"gibt nicht zum schreiben!\n"
-"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
-"diesen Punkt den ALSA-Entwicklern.\n"
-"Wir wachen auf mit einem POLLOUT-Satz -- wie auch immer, eine Untersequenz "
-"von snd_pcm_avail() liefert 0 oder einen anderen Wert zurück, der < "
-"min_avail ist."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2400,46 +2392,488 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
-"ALSA ist aufgewacht zum Lesen von neuen Daten vom Gerät, aber es gibt nicht "
-"zum Lesen!\n"
-"Dies ist wahrscheinlich ein Fehler im ALSA-Treiber '%s'. Bitte melden Sie "
-"diesen Punkt den ALSA-Entwicklern.\n"
-"Wir wachen auf mit einem POLLIN-Satz -- wie auch immer, eine Untersequenz "
-"von snd_pcm_avail() liefert 0 oder einen anderen Wert zurück, der < "
-"min_avail ist."
-
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Ausgabe %s + Eingabe %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Ausgang %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Eingang %s"
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "Aus"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr "High Fidelity Playback (A2DP)"
+msgstr "High Fidelity-Wiedergabe (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "High Fidelity-Aufnahme (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "Telephony Duplex (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio Sound Server"
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr ""
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+#, fuzzy
+msgid "Input Devices"
+msgstr "Eingang %s"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+#, fuzzy
+msgid "Input"
+msgstr "Eingang %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+#, fuzzy
+msgid "Internal Microphone"
+msgstr "Internes Audio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+msgid "Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+msgid "No Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+#, fuzzy
+msgid "Analog Input"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+#, fuzzy
+msgid "Analog Microphone"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+#, fuzzy
+msgid "Analog Line-In"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+#, fuzzy
+msgid "Analog Radio"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+#, fuzzy
+msgid "Analog Video"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+#, fuzzy
+msgid "Analog Output"
+msgstr "Ausgang %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+#, fuzzy
+msgid "Analog Headphones"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+#, fuzzy
+msgid "Analog Mono Output"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, fuzzy, c-format
+msgid "%s+%s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, fuzzy, c-format
+msgid "%s / %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+#, fuzzy
+msgid "Analog Surround 2.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+#, fuzzy
+msgid "Analog Surround 3.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+#, fuzzy
+msgid "Analog Surround 3.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analog Surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analog Surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+#, fuzzy
+msgid "Analog Surround 6.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+#, fuzzy
+msgid "Analog Surround 6.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+#, fuzzy
+msgid "Analog Surround 7.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analog Surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digital Stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+#, fuzzy
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digital Surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digital Surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digital Surround 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digital Stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+#, fuzzy
+msgid "Analog Mono Duplex"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+#, fuzzy
+msgid "Analog Stereo Duplex"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+#, fuzzy
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Digital Stereo (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Niedrigfrequenzemitter"
+
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Ungültiger Client-Name '%s'\n"
+
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr "Beziehen der Sample-Informationen der Datei fehlgeschlagen.\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "Kann nicht mit dem System-Bus verbinden: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "Kann Caller von PID nicht beziehen: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "Kann UID für Caller-Objekt nicht setzen."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "Kann CK-Session nicht beziehen."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "Kann UID für Session-Objekt nicht setzen."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "Konnte PolKitAction nicht zuordnen."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "Kann action_id nicht setzen"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "Konnte PolKitContext nicht zuordnen."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "Konnte PolKitContext nicht initialisieren: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "Autorisierung des Callers konnte nicht sichergestellt werden: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "Keine Authorisierung erhalten: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit antwortete mit '%s'"
+
+#, fuzzy
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Hochprioritäts-Terminierung () (negative Unix nice level) für den "
+#~ "PulseAudio-Dienst"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Echtzeit-Terminierung des PulseAudio-Daemon"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "System-Richtlinien verhindert PulseAudio beim Erlangen des high-priority "
+#~ "scheduling."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "System-Richtlinien verhindert PulseAudio beim Erlangen der Echtzeit-"
+#~ "Terminierung."
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "read() fehlgeschlagen: %s\n"
+
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "pa_context_connect() fehlgeschlagen: %s\n"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr ""
+#~ "Wir befinden uns in der Gruppe '%s', was Scheduling höchster Priorität "
+#~ "ermöglicht."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr ""
+#~ "Wir befinden uns in der Gruppe '%s', was Echtzeit-Scheduling ermöglicht."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr "Richtlinien gewähren das Recht aquire-high-priority."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "Richtlinien verweigern das Recht acquire-high-priority."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "Richtlinien gewähren das Recht aquire-real-time."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "Richtlinien verweigern das Recht acquire-real-time."
+
+#, fuzzy
+#~ msgid ""
+#~ "Called SUID root and real-time and/or high-priority scheduling was "
+#~ "requested in the configuration. However, we lack the necessary "
+#~ "privileges:\n"
+#~ "We are not in group '%s', PolicyKit refuse to grant us the requested "
+#~ "privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
+#~ "limits.\n"
+#~ "For enabling real-time/high-priority scheduling please acquire the "
+#~ "appropriate PolicyKit privileges, or become a member of '%s', or increase "
+#~ "the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+#~ msgstr ""
+#~ "' und PolicyKit verweigern diese Rechte. Verwerfe SUID wieder.\n"
+#~ "Erlangen Sie die den Richtlinien entsprechenden Rechte, um Echtzeit-"
+#~ "Scheduling zu aktivieren oder werden Sie Mitglied der Gruppe '"
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr "Scheduling höchster Priorität konfiguriert, jedoch nicht erlaubt."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "RLIMIT_RTPRIO erfolgreich erhöht"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO fehlgeschlagen: %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "Verwerfe CAP_NICE"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr "Echtzeit-Scheduling konfiguriert, jedoch nicht erlaubt."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "Fähigkeiten erfolgreich auf CAP_SYS_NICE reduziert."
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "time_new() fehlgeschlagen.\n"
+
+#~ msgid "Output %s + Input %s"
+#~ msgstr "Ausgabe %s + Eingabe %s"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Stream erfolgreich erzeugt\n"
+
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "Stream-Fehler: %s\n"
+
+#~ msgid "Connection established.\n"
+#~ msgstr "Verbindung hergestellt.\n"
+
+#~ msgid ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Show this help\n"
+#~ " --version Show version\n"
+#~ "\n"
+#~ " -v, --verbose Enable verbose operation\n"
+#~ "\n"
+#~ " -s, --server=SERVER The name of the server to connect "
+#~ "to\n"
+#~ " -d, --device=DEVICE The name of the sink to connect "
+#~ "to\n"
+#~ " -n, --client-name=NAME How to call this client on the "
+#~ "server\n"
+#~ " --stream-name=NAME How to call this stream on the "
+#~ "server\n"
+#~ " --volume=VOLUME Specify the initial (linear) "
+#~ "volume in range 0...65536\n"
+#~ " --channel-map=CHANNELMAP Set the channel map to the use\n"
+#~ msgstr ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Zeige diese Hilfe\n"
+#~ " --version Zeige Version\n"
+#~ "\n"
+#~ " -v, --verbose Ausführliche Meldungen\n"
+#~ "\n"
+#~ " -s, --server=SERVER Name des Zielservers\n"
+#~ " -d, --device=DEVICE Name des Ziel-Sink\n"
+#~ " -n, --client-name=NAME Rufname des Clients auf dem "
+#~ "Server\n"
+#~ " --stream-name=NAME Rufname des Streams auf dem "
+#~ "Server\n"
+#~ " --volume=VOLUME Initiale (lineare) Lautstärke "
+#~ "zwischen 0...65536\n"
+#~ " --channel-map=CHANNELMAP Diese Kanalzuordnung nutzen\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Kompliert mit libpulse %s\n"
+#~ "Gelinkt mit libpulse %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Ungültige Kanal-Zuweisung\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Öffnen der Datei '%s' fehlgeschlagen\n"
+
+#~ msgid "Channel map doesn't match file.\n"
+#~ msgstr "Kanal-Zuweisung stimmt mit Datei nicht überein.\n"
+
+#~ msgid "Using sample spec '%s'\n"
+#~ msgstr "Sampling-Angabe '%s' wird benutzt\n"
+
#, fuzzy
#~ msgid ""
#~ "Called SUID root and real-time and/or high-priority scheduling was "
@@ -2486,11 +2920,5 @@ msgstr "PulseAudio Sound Server"
#~ "Modul: %s\n"
#~ "Argument: %s\n"
-#~ msgid "sink"
-#~ msgstr "Sink"
-
-#~ msgid "source"
-#~ msgstr "Quelle"
-
#~ msgid "socketpair(): %s"
#~ msgstr "socketpair(): %s"
diff --git a/po/el.po b/po/el.po
index cc1baaef..de923856 100644
--- a/po/el.po
+++ b/po/el.po
@@ -2,65 +2,27 @@
# This file is distributed under the same license as the PACKAGE package.
#
# Dimitris Glezos <dimitris@glezos.com>, 2008.
+# Thalia Papoutsaki <saliyath@gmail.com>, 2009.
msgid ""
msgstr ""
"Project-Id-Version: el\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2008-08-22 19:40+0300\n"
-"Last-Translator: Dimitris Glezos <dimitris@glezos.com>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-26 17:15+0200\n"
+"Last-Translator: Thalia Papoutsaki <saliyath@gmail.com>\n"
"Language-Team: Greek <fedora-trans-el@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Generator: KAider 0.1\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"X-Generator: KAider 0.1\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr ""
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -69,7 +31,7 @@ msgid ""
"to the ALSA developers."
msgstr ""
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -78,7 +40,7 @@ msgid ""
"to the ALSA developers."
msgstr ""
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -87,385 +49,334 @@ msgid ""
"to the ALSA developers."
msgstr ""
-#: ../src/pulsecore/sink.c:2141
-msgid "Internal Audio"
-msgstr ""
-
-#: ../src/pulsecore/sink.c:2147
-msgid "Modem"
-msgstr ""
-
-#: ../src/daemon/ltdl-bind-now.c:124
-msgid "Failed to find original lt_dlopen loader."
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
msgstr ""
-#: ../src/daemon/ltdl-bind-now.c:129
-msgid "Failed to allocate new dl loader."
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
msgstr ""
-#: ../src/daemon/ltdl-bind-now.c:142
-msgid "Failed to add bind-now-loader."
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
msgstr ""
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr ""
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr ""
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
msgstr ""
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
msgstr ""
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
msgstr ""
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr ""
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "ΕσωτεÏικός ήχος"
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr ""
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "Modem"
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
msgstr ""
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
msgstr ""
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
msgstr ""
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
-msgstr ""
+msgstr "Έγινε λήψη σήματος %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Έξοδος."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Αποτυχία εÏÏεσης ομάδας χÏηστών '%s'."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr ""
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr ""
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr ""
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr ""
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr ""
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr ""
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr ""
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr ""
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr ""
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr ""
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr ""
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:556
-#, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr ""
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr ""
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr ""
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr ""
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr ""
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr ""
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr ""
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr ""
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr ""
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr ""
-#: ../src/daemon/main.c:774
+#: ../src/daemon/main.c:726
#, c-format
-msgid "pipe failed: %s"
+msgid "pipe() failed: %s"
msgstr ""
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr ""
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr ""
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr ""
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr ""
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "Αποτυχία σÏνδεσης: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Αυτό είναι το PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr ""
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr ""
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr ""
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr ""
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr ""
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr ""
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr ""
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr ""
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, c-format
+msgid "Running in VM: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr ""
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr ""
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr ""
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr ""
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr ""
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr ""
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr ""
-#: ../src/daemon/main.c:913
+#: ../src/daemon/main.c:874
#, c-format
msgid "Session ID is %s."
msgstr ""
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr ""
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr ""
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr ""
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr ""
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr ""
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr ""
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -473,31 +384,31 @@ msgstr ""
"Δικέ μου, ο πυÏήνας σου είναι για τα μπάζα! Η Ï€Ïόταση του σεφ σήμεÏα είναι "
"Linux με ενεÏγοποιημένα τα high-resolution timers!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr ""
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr ""
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr ""
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr ""
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr ""
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -571,66 +482,66 @@ msgid ""
" -n Don't load default script file\n"
msgstr ""
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
msgstr ""
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr ""
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr ""
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr ""
@@ -647,115 +558,121 @@ msgstr ""
#: ../src/daemon/dumpmodules.c:66
#, c-format
msgid "Version: %s\n"
-msgstr ""
+msgstr "Έκδοση: %s\n"
#: ../src/daemon/dumpmodules.c:68
#, c-format
msgid "Description: %s\n"
-msgstr ""
+msgstr "ΠεÏιγÏαφή: %s\n"
#: ../src/daemon/dumpmodules.c:70
#, c-format
msgid "Author: %s\n"
-msgstr ""
+msgstr "ΣυγγÏαφέας: %s\n"
#: ../src/daemon/dumpmodules.c:72
#, c-format
msgid "Usage: %s\n"
-msgstr ""
+msgstr "ΧÏήση: %s\n"
#: ../src/daemon/dumpmodules.c:73
#, c-format
msgid "Load Once: %s\n"
msgstr ""
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr ""
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr ""
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr ""
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr ""
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr ""
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr ""
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
msgstr ""
#: ../src/daemon/pulseaudio.desktop.in.h:1
@@ -766,261 +683,243 @@ msgstr ""
msgid "Start the PulseAudio Sound System"
msgstr ""
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
-msgstr ""
+msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr ""
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr ""
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr ""
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr ""
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr ""
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr ""
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
msgstr ""
-#: ../src/pulse/channelmap.c:115
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr ""
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr ""
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr ""
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr ""
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
-msgstr ""
+msgstr "Auxiliary 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
-msgstr ""
+msgstr "Auxiliary 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
-msgstr ""
+msgstr "Auxiliary 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
-msgstr ""
+msgstr "Auxiliary 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
-msgstr ""
+msgstr "Auxiliary 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
-msgstr ""
+msgstr "Auxiliary 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
-msgstr ""
+msgstr "Auxiliary 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
-msgstr ""
+msgstr "Auxiliary 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
-msgstr ""
+msgstr "Auxiliary 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
-msgstr ""
+msgstr "Auxiliary 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
-msgstr ""
+msgstr "Auxiliary 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
-msgstr ""
+msgstr "Auxiliary 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
-msgstr ""
+msgstr "Auxiliary 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
-msgstr ""
+msgstr "Auxiliary 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
-msgstr ""
+msgstr "Auxiliary 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
-msgstr ""
+msgstr "Auxiliary 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
-msgstr ""
+msgstr "Auxiliary 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
-msgstr ""
+msgstr "Auxiliary 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
-msgstr ""
+msgstr "Auxiliary 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
-msgstr ""
+msgstr "Auxiliary 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
-msgstr ""
+msgstr "Auxiliary 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
-msgstr ""
+msgstr "Auxiliary 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
-msgstr ""
+msgstr "Auxiliary 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
-msgstr ""
+msgstr "Auxiliary 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
-msgstr ""
+msgstr "Auxiliary 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
-msgstr ""
+msgstr "Auxiliary 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
-msgstr ""
+msgstr "Auxiliary 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
-msgstr ""
+msgstr "Auxiliary 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
-msgstr ""
+msgstr "Auxiliary 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
-msgstr ""
+msgstr "Auxiliary 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
-msgstr ""
+msgstr "Auxiliary 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
-msgstr ""
+msgstr "Auxiliary 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr ""
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr ""
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr ""
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr ""
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr ""
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr ""
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr ""
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
-msgstr ""
+msgstr "(μη έγκυÏο)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
-msgstr ""
+msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
-msgstr ""
+msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
-msgstr ""
+msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
-msgstr ""
+msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
-msgstr ""
+msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
-msgstr ""
+msgstr "Surround 7.1"
#: ../src/pulse/error.c:43
msgid "OK"
-msgstr ""
+msgstr "Εντάξει"
#: ../src/pulse/error.c:44
msgid "Access denied"
@@ -1118,30 +1017,38 @@ msgstr ""
msgid "Client forked"
msgstr ""
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr ""
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr ""
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
-msgstr ""
+msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
-msgstr ""
+msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
-msgstr ""
+msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
-msgstr ""
+msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
-msgstr ""
+msgstr "%u B"
#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
msgid "XOpenDisplay() failed"
@@ -1151,196 +1058,190 @@ msgstr ""
msgid "Failed to parse cookie data"
msgstr ""
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr ""
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr ""
-#: ../src/pulse/context.c:676
-#, c-format
+#: ../src/pulse/context.c:682
+#, fuzzy, c-format
msgid "fork(): %s"
-msgstr ""
+msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
-#, c-format
+#: ../src/pulse/context.c:737
+#, fuzzy, c-format
msgid "waitpid(): %s"
-msgstr ""
+msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr ""
-#: ../src/utils/pacat.c:94
-#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr ""
+#: ../src/utils/pacat.c:110
+#, fuzzy, c-format
+msgid "Failed to drain stream: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
msgstr ""
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
msgstr ""
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
+msgid "pa_stream_drain(): %s"
msgstr ""
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
+msgid "pa_stream_peek() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
msgstr ""
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
msgstr ""
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
msgstr ""
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
msgstr ""
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
msgstr ""
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
+msgid "Stream error: %s"
msgstr ""
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
+msgid "Stream device suspended.%s"
msgstr ""
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr ""
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
+msgid "Stream device resumed.%s"
msgstr ""
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
+msgid "Stream underrun.%s"
msgstr ""
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
+msgid "Stream overrun.%s"
msgstr ""
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
+msgid "Stream started.%s"
msgstr ""
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
msgstr ""
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
msgstr ""
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
+msgid "Stream buffer attributes changed.%s"
msgstr ""
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
+msgid "Connection established.%s"
msgstr ""
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
+msgid "pa_stream_new() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
+msgid "pa_stream_connect_playback() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr ""
+msgid "Connection failure: %s"
+msgstr "Αποτυχία σÏνδεσης: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
msgstr ""
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
+msgid "write() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
msgstr ""
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
+#, fuzzy, c-format
+msgid "Failed to get latency: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
+
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
msgstr ""
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:620
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
+msgid "pa_stream_update_timing_info() failed: %s"
msgstr ""
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:630
#, c-format
msgid ""
"%s [options]\n"
@@ -1367,8 +1268,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1391,9 +1294,18 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1401,129 +1313,169 @@ msgid ""
"Linked with libpulse %s\n"
msgstr ""
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
+msgid "Invalid client name '%s'"
msgstr ""
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
+msgid "Invalid stream name '%s'"
msgstr ""
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
+msgid "Invalid channel map '%s'"
msgstr ""
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
+msgid "Invalid latency specification '%s'"
msgstr ""
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
+msgid "Invalid process time specification '%s'"
msgstr ""
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
+msgid "Invalid property '%s'"
msgstr ""
-#: ../src/utils/pacat.c:728
-msgid "recording"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
msgstr ""
-#: ../src/utils/pacat.c:728
-msgid "playback"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
msgstr ""
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
+msgid "open(): %s"
msgstr ""
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
+msgid "dup2(): %s"
msgstr ""
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
msgstr ""
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
msgstr ""
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
msgstr ""
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
msgstr ""
-#: ../src/utils/pacat.c:799
-#, c-format
-msgid "pa_context_connect() failed: %s\n"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
msgstr ""
-#: ../src/utils/pacat.c:810
-#, c-format
-msgid "time_new() failed.\n"
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
msgstr ""
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
-#, c-format
-msgid "pa_mainloop_run() failed.\n"
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr ""
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
msgstr ""
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "fork(): %s\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr ""
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr ""
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr ""
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr ""
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
msgstr ""
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "execvp(): %s\n"
+msgid "pa_context_connect() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
msgstr ""
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr ""
+
+#: ../src/utils/pasuspender.c:79
+#, fuzzy, c-format
+msgid "fork(): %s\n"
+msgstr "fork(): %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, fuzzy, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr ""
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr ""
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr ""
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr ""
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr ""
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1535,7 +1487,7 @@ msgid ""
"\n"
msgstr ""
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1543,35 +1495,61 @@ msgid ""
"Linked with libpulse %s\n"
msgstr ""
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
+msgid "pa_mainloop_new() failed.\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
msgstr ""
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:134
+#, fuzzy, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr ""
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr ""
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
+#, fuzzy, c-format
+msgid "Failed to get server information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
+
+#: ../src/utils/pactl.c:160
#, c-format
-msgid "Failed to get server information: %s\n"
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
msgstr ""
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:176
#, c-format
msgid ""
-"User name: %s\n"
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1579,15 +1557,15 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
-#: ../src/utils/pactl.c:178
-#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:218
+#, fuzzy, c-format
+msgid "Failed to get sink information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1609,12 +1587,22 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
+msgid "\tActive Port: %s\n"
msgstr ""
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, fuzzy, c-format
+msgid "Failed to get source information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1636,20 +1624,20 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr ""
-#: ../src/utils/pactl.c:324
-#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:388
+#, fuzzy, c-format
+msgid "Failed to get module information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1660,12 +1648,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:361
-#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:425
+#, fuzzy, c-format
+msgid "Failed to get client information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1675,12 +1663,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:396
-#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:460
+#, fuzzy, c-format
+msgid "Failed to get card information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1691,22 +1679,22 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr ""
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr ""
-#: ../src/utils/pactl.c:445
-#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:509
+#, fuzzy, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1727,12 +1715,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:503
-#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:567
+#, fuzzy, c-format
+msgid "Failed to get source output information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1749,12 +1737,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:554
-#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:618
+#, fuzzy, c-format
+msgid "Failed to get sample information: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -1772,22 +1760,78 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
+msgid "Failure: %s"
+msgstr "Αποτυχία: %s"
+
+#: ../src/utils/pactl.c:700
+#, fuzzy, c-format
+msgid "Failed to upload sample: %s"
+msgstr "Αποτυχία εÏÏεσης χÏήστη '%s'."
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
msgstr ""
-#: ../src/utils/pactl.c:636
-#, c-format
-msgid "Failed to upload sample: %s\n"
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
msgstr ""
-#: ../src/utils/pactl.c:653
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+msgid "server"
+msgstr ""
+
+#: ../src/utils/pactl.c:787
#, c-format
-msgid "Premature end of file\n"
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:961
#, c-format
msgid ""
"%s [options] stat\n"
@@ -1796,13 +1840,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -1813,7 +1866,7 @@ msgid ""
"server\n"
msgstr ""
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -1821,73 +1874,105 @@ msgid ""
"Linked with libpulse %s\n"
msgstr ""
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
msgstr ""
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Αποτυχία ανοίγματος αÏχείου ήχου."
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
msgstr ""
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
msgstr ""
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
msgstr ""
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
msgstr ""
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
msgstr ""
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
msgstr ""
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
msgstr ""
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
msgstr ""
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
msgstr ""
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr ""
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr ""
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr ""
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
msgstr ""
#: ../src/utils/pax11publish.c:61
@@ -1962,158 +2047,316 @@ msgstr ""
msgid "Not yet implemented.\n"
msgstr ""
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr ""
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
-msgstr ""
+msgstr "σÏνδεση(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr ""
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr ""
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
+msgid "poll(): %s"
msgstr ""
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr ""
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr ""
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
msgstr ""
-#: ../src/utils/paplay.c:144
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
-msgid "Stream errror: %s\n"
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
msgstr ""
-#: ../src/utils/paplay.c:165
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
-msgid "Connection established.\n"
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
msgstr ""
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
msgstr ""
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
msgstr ""
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
msgstr ""
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
msgstr ""
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
msgstr ""
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
-msgid "Cannot access autospawn lock."
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
msgstr ""
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
-#, c-format
-msgid ""
-"ALSA woke us up to write new data to the device, but there was actually "
-"nothing to write!\n"
-"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
-"to the ALSA developers.\n"
-"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
-"returned 0 or another value < min_avail."
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
msgstr ""
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
-#, c-format
-msgid ""
-"ALSA woke us up to read new data from the device, but there was actually "
-"nothing to read!\n"
-"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
-"to the ALSA developers.\n"
-"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
-"returned 0 or another value < min_avail."
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
-msgid "Off"
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
-msgid "High Fidelity Playback (A2DP)"
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
-msgid "Telephony Duplex (HSP/HFP)"
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
-msgid "PulseAudio Sound Server"
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+msgid "Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+msgid "No Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+msgid "Headphones"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Analog Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Analog Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Analog Output (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analog Mono Output"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analog Mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analog Stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analog Surround 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analog Surround 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analog Surround 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analog Surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analog Surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analog Surround 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analog Surround 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analog Surround 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analog Surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digital Stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digital Surround 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digital Surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digital Surround 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digital Stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analog Mono Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analog Stereo Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Digital Stereo Duplex (IEC958)"
diff --git a/po/es.po b/po/es.po
index d3221d33..84c67f06 100644
--- a/po/es.po
+++ b/po/es.po
@@ -4,64 +4,27 @@
# Domingo Becker <domingobecker@gmail.com>, 2009.
# Héctor Daniel Cabrera <h.daniel.cabrera@gmail.com>, 2009.
#
+# Fernando Gonzalez Blanco <fgonz@fedoraproject.org>, 2009.
msgid ""
msgstr ""
"Project-Id-Version: PulseAudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-18 12:45-0300\n"
-"Last-Translator: Domingo Becker <domingobecker@gmail.com>\n"
-"Language-Team: Fedora Spanish <fedora-trans-es@redhat.com>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-04 21:16+0200\n"
+"Last-Translator: Fernando Gonzalez Blanco <fgonz@fedoraproject.org>\n"
+"Language-Team: Spanish <fedora-trans-es@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Poedit-Language: Spanish\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Mono Analógico"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Estéreo Analógico"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Estéreo Digital (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Estéreo Digital (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Análogo Envolvente 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digital Envolvente 4.0 (IEC9588/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Análogo Envolvente 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Análogo Envolvente 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Análogo Envolvente 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digital Envolvente 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Análogo Envolvénte 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -74,7 +37,7 @@ msgstr ""
"Lo más probable es que sea un error del controlador ALSA '%s'. Por favor, "
"informe ésto a los desarrolladores de ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -87,7 +50,7 @@ msgstr ""
"Lo más probable es que sea un error del controlador ALSA '%s'. Por favor, "
"informe ésto a los desarrolladores de ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -100,11 +63,46 @@ msgstr ""
"Lo más probable es que sea un error del controlador ALSA '%s'. Por favor, "
"informe ésto a los desarrolladores de ALSA."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Siempre tenga al menos un sumidero cargado aunque sea uno nulo"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Salida Boba"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Sumidero virtual LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nombre para el sumidero> sink_properties=<propiedades para el "
+"sumidero> master=<nombre del sumidero a filtrar> format=<formato de ejemplo> "
+"rate=<tasa de ejemplo> channels=<cantidad de canaless> channel_map=<mapeo de "
+"canales> plugin=<nombre del complemento ladspa> label=<etiqueta del "
+"complemento ladspa> control=<lista separada por comas de valores de control "
+"de entrada>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Sumidero nulo sincronizado"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Salida Nula"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Audio Interno"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Módem"
@@ -120,221 +118,98 @@ msgstr "Falló al asignar el cargador dl nuevo."
msgid "Failed to add bind-now-loader."
msgstr "Falló al agregar bind-now-loader."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "No se puede conectar al bus del sistema: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "No se puede obtener el llamador desde el PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "No se puede poner UID en el objeto llamador."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Falló al obtener sesión CK."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "No se puede poner UID en el objeto de sesión."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "No se puede asignar PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "No se pudo poner action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "No se pudo asignar PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "No se pudo inicializar PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "No se pudo determinar si el llamador está autorizado: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "No se pudo obtener auth: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit respondió con '%s'"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Se obtuvo la señal %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Saliendo."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Falló al buscar usuario '%s'."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Falló al buscar grupo '%s'."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Se encontró el usuario '%s' (UID %lu) y el grupo '%s' (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID del usuario '%s' y del grupo '%s' no son similares."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "El directorio de inicio del usuario '%s' no es '%s', ignorando."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Falló al crear '%s': %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Falló al cambiar la lista de grupo: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Falló al cambiar GID: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Falló al cambiar UID: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Se han liberado con éxitos los privilegios de root."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "El modo a nivel de sistema no es soportado en esta plataforma."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) falló: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Falló al analizar la línea de comando."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "Estamos en el grupo '%s', permitiendo planificación de prioridad alta."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "Estamos en el grupo '%s', permitiendo planificación en tiempo real."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit garantiza que se obtenga el privilegio de alta prioridad."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit se niega a dar acceso al privilegio de alta prioridad."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit garantiza el acceso al privilegio de tiempo real."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit se niega a dar acceso al privilegio de tiempo real."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"Se llamó con SUID root y se pidió planificación en tiempo real y/o de alta "
-"prioridad en la configuración. Sin embargo, no se tiene los privilegios "
-"necesarios:\n"
-"No se está en el grupo '%s'. PolicyKit rechaza darnos el permiso necesario y "
-"no se puede aumentar los límites del recurso RLIMIT_NICE/RLIMIT_RTPRIO.\n"
-"Para habilitar la planifiación de tiempo real/alta prioridad por favor "
-"adquiera los privilegios apropiados en PolicyKit, o hágase miembro de '%s', "
-"o aumente los límites del recurso RLIMIT_NICE/RLIMIT_RTPRIO para este "
-"usuario."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Está habilitadada la planificación de prioridad alta, pero no están "
-"permitidas por la política."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO incrementado en forma exitosa"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "Fallo en RLIMIT_RTPRIO: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Abandonando CAP_NICE"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"Está habilitada la planificación en tiempo real, pero no está permitido por "
-"la política."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "El demonio no está funcionando"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "El demonio está funcionando como PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "No se ha podido detener el demonio: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -342,165 +217,202 @@ msgstr ""
"Este programa no tiene por qué ser ejecutado como root (a menos que --system "
"sea especificado)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Se necesitan privilegios de root."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start no está soportado para las instancias del sistema."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
"Ejecutándose en modo de sistema, ¡pero no se ha configurado --disallow-exit! "
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"Ejecutándose en modo de sistema, ¡pero no se ha configurado --disallow-"
"module-loading!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr ""
"Ejecutándose en modo de sistema, ¡desactivando forzadamente el modo SHM!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"Ejecutándose en modo de sistema, ¡desactivando forzadamente exit idle time!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Fallo al intentar adquirir stdio."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "Falló el pipe: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "Falló el fork(): %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "Falló la operación read(): %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Falló el inicio del demonio. "
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "El demonio se inició exitosamente."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "Falló la operación read(): %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Esto es PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Host de compilación: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "Compilación CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Ejecutándose en el host: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "Se encontraron %u CPUs."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "El tamaño de la página es de %lu bytes"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Soporte para compilar con Valgrind: si"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Soporte para compilar con Valgrind: no"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Ejecutándose en modo valgrind: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Ejecutándose en el host: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Build optimizado: si"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Build optimizado: no"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG definido, todos los chequeos deshabilitados."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH definido, sólo se deshabilitan los chequeos fast path."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Todos los chequeos habilitados."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Fallo al intentar obtener el ID de la máquina"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "El ID de la máquina es %s"
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "El ID de la máquina es %s"
+msgstr "El ID de la sesión es %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Utilizando directorio de tiempo de ejecución %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Utilizando directorio de estado %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Utilizando directorio de módulos %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Ejecutándose en modo de sistema: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"Bien, o sea que está ejecutando PA en modo de sistema. Por favor entienda "
+"que, en general, no debería estar haciéndolo.\n"
+"Si insiste en seguir utilizando este modo, será debido a su propio accionar "
+"que las cosas no funcionen como se esperaba.\n"
+"Por favor lea http://pulseaudio.org/wiki/WhatIsWrongWithSystemMod para "
+"obtener una explicación acerca de por qué es una mala idea utilizar el modo "
+"sistema."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "Ha fallado pa_pid_file_create()."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr ""
"¡Existen cronómetros de alta resolución fresquitos y disponibles! ¡Bon "
"appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -508,33 +420,33 @@ msgstr ""
"¡Amigo, su kernel deja mucho que desear! ¡El plato que hoy recomienda el "
"chef es Linux con cronómetros de alta resolución activados! "
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "Falló pa_core_new()."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Fallo al intentar iniciar el demonio."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
"El demonio se ha iniciado sin ningún módulo cargado, y por ello se niega a "
"funcionar."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "El demonio se inició completamente."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Comienza a apagarse el demonio."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "El demonio se ha apagado."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -686,15 +598,15 @@ msgstr ""
" -n No carga el archivo script "
"predeterminado\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize espera un argumento booleano"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail espera un argumento booleano"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -703,52 +615,52 @@ msgstr ""
"caiga en el rango de 0..4; ya sea uno de debug, info, notice, warn, o "
"error). "
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority espera un argumento booleano"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime espera un argumento booleano"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading espera un argumento booleano"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit espera un argumento booleano"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use pid-file espera un argumento booleano"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "Log target inválido: use o \"syslog\", o \"stderr\", o \"auto\"."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time espera un argumento booleano"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta espera un argumento booleano"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Método de remuestreo inválido '%s'"
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system espera un argumento booleano"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit espera un argumento booleano"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm espera un argumento booleano"
@@ -787,77 +699,87 @@ msgstr "Uso: %s\n"
msgid "Load Once: %s\n"
msgstr "Carga una vez: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "ADVERTENCIA DE COMPATIBILIDAD: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Ruta: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Destino de log inválido '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Nivel de log inválido '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Método de remuestreo inválido '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Rlimit inválido '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] Rlimit no soportado en esta plataforma."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Formato de muestra inválido '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Tasa de muestra inválida '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Canales de muestra inválidos '%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Mapa de canal inválido '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Cantidad de fragmentoa inválidos '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Tamaño inválido de fragmento '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Nivel de nice inválido '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Tasa de muestra inválida '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "No se pudo abrir el archivo de configuración: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -865,18 +787,14 @@ msgstr ""
"El mapa de canal predeterminado especificado tiene un número de canales "
"distinto al especificado como predeterminado."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Leyendo desde el archivo de confioguración: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Abandonando privilegios de root."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Capacidades limitadas con éxito para CAP_SYS_NICE-"
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Abandonando privilegios."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -886,261 +804,237 @@ msgstr "Sistema de Sonido PulseAudio"
msgid "Start the PulseAudio Sound System"
msgstr "Iniciar el Sistema de Sonido PulseAudio"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"Planificación de alta prioridad (nivel Unix negativo) para el demonio "
-"PulseAudio"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Planificación de tiempo real para el demonio de PulseAudio."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Las políticas del sistema impidieron a PulseAudio adquirir la planificación "
-"de alta prioridad."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"Las políticas del sistema impidieron a PulseAudio adquirir la planificación "
-"de tiempo real."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Frente central"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Frente izquierdo"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Frente derecho"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Posterior central"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "POsterior izquierdo"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "POsterior derecho"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Emisor de baja frecuencia"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Frente izquierdo del centro"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Frente derecho del centro"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Lateral izquierdo"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Lateral derecho"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Auxiliar 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Auxiliar 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Auxiliar 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Auxiliar 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Auxiliar 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Auxiliar 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Auxiliar 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Auxiliar 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Auxiliar 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Auxiliar 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Auxiliar 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Auxiliar 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Auxiliar 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Auxiliar 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Auxiliar 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Auxiliar 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Auxiliar 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Auxiliar 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Auxiliar 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Auxiliar 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Auxiliar 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Auxiliar 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Auxiliar 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Auxiliar 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Auxiliar 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Auxiliar 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Auxiliar 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Auxiliar 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Auxiliar 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Auxiliar 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Auxiliar 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Auxiliar 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Central superior"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Central frontal superior"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Frontal superior izquierdo"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Frontal superior derecho"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Posterior central superior "
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Posterior izquierdo superior"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Posterior derecho superior"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(inválido)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Estéreo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Envolvente 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Envolvente 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Envolvente 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Envolvente 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Envolvente 7.1"
@@ -1244,27 +1138,35 @@ msgstr "Falta implementación"
msgid "Client forked"
msgstr "Cliente iniciado"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Error de Entrada/Salida"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Dispositivo o recurso ocupado"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1277,197 +1179,191 @@ msgstr "XOpenDisplay() falló"
msgid "Failed to parse cookie data"
msgstr "Fallo al analizar los datos de la cookie"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Fallo al abrir el archivo de configuración '%s': %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "No se ha cargado ninguna cookie. Intentando conectar de todos modos."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(:) %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Se ha recibido un mensaje para una extensión desconocida '%s'"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() falló: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Falló al drenar el flujo: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() falló: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "El flujo de reproducción ha sido drenado."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Se ha creado exitosamente el flujo (stream).\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Drenando conexión con el servidor."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() falló: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Métrica del búfer: maxlenght=%u, tlenghth=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() falló: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Métrica del búfer: maxlenght=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() falló: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Utilizando especificaciones de muestra '%s', mapa del canal '%s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() falló: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Conectado al dispositivo %s (%u, %ssuspended).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Se ha creado exitosamente el flujo (stream)."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Error de flujo: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() falló: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Dispositivo de flujo suspendido. %s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Métrica del búfer: maxlenght=%u, tlenghth=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Dispositivo de flujo reestablecido. %s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Métrica del búfer: maxlenght=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Flujo agotado. %s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Utilizando especificaciones de muestra '%s', mapa del canal '%s'."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Flujo saturado.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Conectado al dispositivo %s (%u, %ssuspended)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Flujo iniciado. %s \n"
+msgid "Stream error: %s"
+msgstr "Error de flujo: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Fujo trasladado al dispositivo %s (%u, %ssuspended). %s\n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "no"
+msgid "Stream device suspended.%s"
+msgstr "Dispositivo de flujo suspendido.%s"
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Los atributos del buffer de flujo cambiaron. %s \n"
+msgid "Stream device resumed.%s"
+msgstr "Dispositivo de flujo reestablecido.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Conexión establecida. %s \n"
+msgid "Stream underrun.%s"
+msgstr "Flujo agotado.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() falló; %s\n"
+msgid "Stream overrun.%s"
+msgstr "Flujo saturado.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() falló: %s\n"
+msgid "Stream started.%s"
+msgstr "Flujo iniciado.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() falló: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Fujo trasladado al dispositivo %s (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Error en la conexión: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "no"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Error al drenar el flujo: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Los atributos del búfer de flujo han cambiado.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "El flujo de platback se ha drenado.\n"
+msgid "Connection established.%s"
+msgstr "Conexión establecida.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Drenando conexión con el servidor.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() falló: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "Hay EOF.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() falló: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() falló: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() falló: %s\n"
+msgid "Connection failure: %s"
+msgstr "Error en la conexión: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() falló: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Se tiene EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Hay señal, saliendo (exiting).\n"
+msgid "write() failed: %s"
+msgstr "write() falló: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "No se pudo obtener latencia: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Hay señal, saliendo (exiting)."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Tiempo: %0.3f sec; Latencia: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "No se pudo obtener latencia: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() falló: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Tiempo: %0.3f seg; Latencia: %0.0f useg."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() falló: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1493,8 +1389,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1517,6 +1415,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [opciones]\n"
"\n"
@@ -1531,13 +1438,13 @@ msgstr ""
"\n"
" -s, --server=SERVER El nombre del servidor con el que "
"conectarse\n"
-" -d, --device=DEVICE El nombre del destino/fuente a la "
+" -d, --device=DEVICE El nombre del sumidero/fuente a la "
"que conectarse\n"
" -n, --client-name=NAME Cómo llamar a este cliente en el "
"servidor\n"
" --stream-name=NAME Cómo llamar a este flujo en el "
"servidor\n"
-" --volume=VOLUME Especificar el salida inicial "
+" --volume=VOLUME Especifica el salida inicial "
"(linear) de volumen dentro del rango 0...65536\n"
" --rate=SAMPLERATE Tasa de muestra en Hz (establecida "
"en 44100 por defecto)\n"
@@ -1548,27 +1455,36 @@ msgstr ""
" --channels=CHANNELS La cantidad de canales, 1 para mono, "
"2 para stereo\n"
" (establecido en 2 por defecto)\n"
-" --channel-map=CHANNELMAP Mapa de canales a ser usado en lugar "
-"del establecido por defecto\n"
-" --fix-format Obtener el formato de sample desde "
-"el destino al que el flujo\n"
+" --channel-map=CHANNELMAP Mapeo de canales a ser usado en "
+"lugar del establecido por defecto\n"
+" --fix-format Obtener el formato de ejemplo desde "
+"el sumidero al que el flujo\n"
" se ha conectado.\n"
-" --fix-rate Obtener la tasa de sampling desde el "
+" --fix-rate Obtiene la tasa de ejemplo desde el "
"destino al que el flujo\n"
" se ha conectado.\n"
" --fix-channels Obtener el mapa y la cantidad de "
"canales\n"
-" desde el destino al que el flojo se "
+" desde el sumidero al que el flujo se "
"ha conectado.\n"
-" --no-remix No upmix o downmix canales.\n"
-" --no-remap Mapear canales por índices en lugar "
+" --no-remix No realiza un upmix o un downmix de "
+"los canales.\n"
+" --no-remap Mapea canales por índices en lugar "
"de por nombres.\n"
-" --latency=BYTES Solicitar la latencia especificada "
-"en bytes.\n"
-" --process-time=BYTES Solicitar los procesos de tiempo por "
+" --latency=BYTES Solicita la latencia especificada en "
+"bytes.\n"
+" --process-time=BYTES Solicita los procesos de tiempo por "
"pedido especificados en bytes.\n"
+" --property=PROPERTY=VALUE Estabelce la propiedad especificada "
+"al valor especificado.\n"
+" --raw Graba/reproduce datos PCM con "
+"formato raw.\n"
+" --file-format=FFORMAT Graba/reproduce datos PCM "
+"formateados.\n"
+" --list-file-formats Muestra una lista con los formatos "
+"de archivo disponibles.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1579,129 +1495,173 @@ msgstr ""
"Compilado con libpulse %s\n"
"Linkeado con libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Mapa de canales inválido '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "Nombre de cliente '%s' inválido"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Especificación de latencia inválida '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "Nombre de flujo '%s' inválido"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Especificación de tiempo de proceso inválida '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "Mapa de canales '%s' inválido"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Especificación de muestra inválida\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Especificación de latencia '%s' inválida"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "El mapa del canal no se corresponde con la especificación de muestra\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Especificación de tiempo de proceso '%s' inválida"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Abriendo un %s flujo con las especificaciones de muestra '%s'.\n"
+msgid "Invalid property '%s'"
+msgstr "Propiedad '%s' inválida"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "grabando"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Formato de archivo desconocido %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "playback"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Especificación de muestra inválida"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open() %s\n"
+msgid "open(): %s"
+msgstr "open() %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Demasiados argumentos.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Demasiados argumentos."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() falló.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Falló al generar especificación de ejemplo para el archivo."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() falló.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Falló al abrir el archivo de sonido."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() falló.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Aviso: el ejemplo de especificación indicado será sobreescrito con las "
+"especificaciones del archivo."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() falló: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Falló al determinar especificación de ejemplo del archivo."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Aviso: Falló al determinar el mapeo del canal desde el archivo."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "El mapa del canal no se corresponde con la especificación de muestra"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Aviso: Faló al escribir el mapeo del canal en el archivo."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() falló.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Abriendo un flujo %s con especificación de muestra '%s' y mapeo de canal '%"
+"s'."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "grabando"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "playback"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() falló."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() falló."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() falló."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() falló.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() falló: %s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() falló."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() falló."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Error al suspender: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Error al continuar: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "AVISO: El servidor de sonido no es local, no se suspende.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Error en la conexión: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Hay SIGINT, saliendo.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "AVISO: El proceso niño terminado por la señal %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1720,7 +1680,7 @@ msgstr ""
"conectarse\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1731,37 +1691,63 @@ msgstr ""
"Compilado con libpulse %s\n"
"Linkeado con libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Error al intentar obtener estadísticas: %s\n"
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() falló.\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() falló.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() falló.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Error al intentar obtener estadísticas: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Actualmente en uso: %u bloques conteniendo %s bytes en total.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"Ubicados durante a lo largo del tiempo: %u bloques conteniendo %s bytes en "
"total.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Tamaño del cache de muestra: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Error al intentar obtener información del servidor: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Error al intentar obtener información del servidor: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1769,7 +1755,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Nombre de usuario: %s\n"
"Nombre del equipo: %s\n"
@@ -1781,12 +1767,12 @@ msgstr ""
"Fuente por defecto: %s\n"
"Cookie: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Error al intentar obtener información del destino: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Error al intentar obtener información del sumidero: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1825,12 +1811,22 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPuertos:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Error al intentar obtener información de la fuente: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tPuerto Activo: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Error al intentar obtener información de la fuente: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1869,20 +1865,20 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Error al intentar obtener información del módulo: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Error al intentar obtener información del módulo: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1899,12 +1895,12 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Error al intentar obtener información del cliente: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Error al intentar obtener información del cliente: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1919,12 +1915,12 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Fallo al obtener la información de la placa: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Fallo al obtener la información de la placa: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1941,22 +1937,22 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tPerfiles:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tPerfil Activo: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Error al intentar obtener información de entrada del destino: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Error al intentar obtener información de entrada del sumidero: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1993,13 +1989,12 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr ""
-"Error al intentar obtener información acerca de la salida de la fuenta: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "Falló al obtener información de salida de la fuente: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2028,12 +2023,12 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Error al intentar obtener información de muestra: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Falló al obtener información de la muestra: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2064,23 +2059,81 @@ msgstr ""
"\tPropiedades:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Falla: %s\n"
+msgid "Failure: %s"
+msgstr "Falla: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Fallo al cargar muestra: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Falló al subir muestra: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Fin prematuro del archivo\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Fin de archivo prematuro"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr "destino"
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr "fuente"
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+#, fuzzy
+msgid "source-output"
+msgstr "fuente"
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Servidor inválido"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Hay un SIGINT, saliendo."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2088,13 +2141,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2117,6 +2179,14 @@ msgstr ""
"%s [opciones] suspend-sink [SINK] 1|0\n"
"%s [opciones] suspend-source [SOURCE] 1|0\n"
"%s [opciones] set-card-profile [CARD] [PROFILE] \n"
+"%s [opciones] set-sink-port [SINK] [PORT] \n"
+"%s [opciones] set-source-port [SOURCE] [PORT] \n"
+"%s [opciones] set-sink-volume SINK VOLUME\n"
+"%s [opciones] set-source-volume SOURCE VOLUME\n"
+"%s [opciones] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [opciones] set-sink-mute SINK 1|0\n"
+"%s [opciones] set-source-mute SOURCE 1|0\n"
+"%s [opciones] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
" -h, --help Muestra esta ayuda\n"
" --version Muestra la versión\n"
@@ -2126,7 +2196,7 @@ msgstr ""
" -n, --client-name=NAME El nombre de este cliente en el "
"servidor\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2137,80 +2207,113 @@ msgstr ""
"Compilado con libpulse %s\n"
"Linked con libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Por favor, especifique un archivo de muestra a cargar\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Por favor, especifique un archivo de muestra a cargar"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Error al intentar abrir el archivo de sonido.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Error al intentar abrir el archivo de sonido."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Debe especificar un nombre de muestra para ser escuchado\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+"Aviso: Falló al intentar determinar especificación de la muestra desde el "
+"archivo."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Debe especificar un nombre de muestra para ser eliminado\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Debe especificar un nombre de muestra para reproducir"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr ""
-"Debe especificar un índice para las entradas del destino y un destino\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Debe especificar un nombre de muestra a eliminar"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr ""
-"Debe especificar un índice para las salidas de la fuente, y una fuente\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Debe especificar un índice para la entrada al sumidero y un sumidero"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Debe especificar un nombre de módulo y los argumentos\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Debe especificar un índice para las salida de la fuente y una fuente"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Debe especificar un índice de módulo\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Debe especificar un nombre de módulo y los argumentos."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Debe especificar un índice de módulo"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
"No puede especificar más de un sumidero. Tiene que especificar un valor "
-"booleano.\n"
+"booleano."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
"No puede especificar más de una fuente. Tiene que especificar un valor "
-"booleano.\n"
+"booleano."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Debe especificar un nombre de placa/índice y un nombre de perfil\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Debe especificar un nombre/índice de placa y un nombre de perfil"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "No se ha especificadfo ningún comando válido.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Debe especificar un nombre/índice de sumidero y un nombre de puerto"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() falló: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Debe especificar un nombre/índice de fuente y un nombre de puerto"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Debe especificar un nombre/índice de sumidero y el volumen"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Especificación de volumen inválida"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Debe especificar un nombre/índice de fuente y un volumen"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Debe especificar un índice de sumidero y un volumen"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Indice de entrada a sumidero inválido"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Debe especificar un nombre/índice de sumidero y un booleano para mudo"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Debe especificar un nombre/índice de fuente y un booleano para mudo"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+"Debe especificar un índice de entrada a sumidero y un booleano para mudo"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Especificación de índice de entrada a sumidero inválida"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "No se ha especificado ningún comando válido."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2292,132 +2395,50 @@ msgstr "Error al cargar datos de cookie\n"
msgid "Not yet implemented.\n"
msgstr "Aún no se ha implementado.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"El demonio PulseAudio no está ejecutándose, o no se está ejecutando como un "
+"demonio de sesión."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Error al intentar detener el demonio de PulseAudio."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "El demonio no responde."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Se ha creado el flujo exitosamente\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Error de flujo: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Conección establecida.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Muestra esta ayuda\n"
-" --version Muestra la versión\n"
-"\n"
-" -v, --verbose Habilita operación con vocabulario "
-"más detallado\n"
-"\n"
-" -s, --server=SERVER El nombre del servidor al que "
-"conectarse\n"
-" -d, --device=DEVICE El nombre del destino al que "
-"conectarse\n"
-" -n, --client-name=NAME Cómo llamar a este cliente en el "
-"servidor\n"
-" --stream-name=NAME Cómo llamar a este flujo en el "
-"servidor\n"
-" --volume=VOLUME Especifica el volumen inicial "
-"(linear)en el rango de 0...65536\n"
-" --channel-map=CHANNELMAP Establece el mapa del canal para el "
-"uso\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Compilado con libpulse %s\n"
-"Linked con libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Mapa de canal inválido\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Error al intentar abrir el archivo '%s'\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "El mapa del canal no se corresponde con el archivo.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Utilizando especificaciones de muestra '%s'\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "No se puede acceder al candado de autogeneración."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2434,7 +2455,7 @@ msgstr ""
"Nos despertaron con POLLOUT puesto -- sin embargo, una llamada a "
"snd_pcm_avail() devolvió 0 u otro valor < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2451,38 +2472,480 @@ msgstr ""
"Nos despertaron con POLLIN puesto -- sin embargo, una llamada a snd_pcm_avail"
"() devolvió 0 u otro valor < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Salida %s + Entrada %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Salida %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Entrada %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "Apagado"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "Reproducción de Alta Fidelidad (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Captura de Alta Fidelidad (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "Telefonía Duplex (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "Servidor de Sonido PulseAudio"
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Dispositivos de salida"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Dispositivos de entrada"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Audio en @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Entrada"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Estación dock de entrada"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Micrófono de la estación Dock"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "En línea"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Micrófono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Micrófono externo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Micrófono interno"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Vídeo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Control automático de ganancia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Sin control automático de ganancia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Incremento de ganancia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Sin incremento de ganancia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Amplificador"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Sin amplificador"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Incremento de ganancia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Sin incremento de ganancia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Auriculares analógicos"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Entrada analógica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Micrófono analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Entrada en línea analógica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Radio analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Vídeo analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Salida analógica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Auriculares analógicos"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Salida analógica (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Salida Mono analógica "
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Estéreo Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Estéreo Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Análogico Envolvente 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Análogico Envolvente 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Análogico Envolvente 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Análogo Envolvente 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Análogo Envolvente 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Análogo Envolvente 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Análogo Envolvente 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Análogico Envolvente 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Análogico Envolvente 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Análogico Envolvente 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Análogo Envolvénte 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Estéreo Digital (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digital Envolvente 4.0 (IEC9588)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digital Envolvente 4.0 (IEC9588/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digital Envolvente 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Estéreo Digital (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Mono Analógico.Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Estéreo Analógico.Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Estéreo Digital Duplex(IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Emisor de baja frecuencia"
+
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Nombre de cliente inválido '%s'\n"
+
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr ""
+#~ "Error al intentar determinar especificación de ejemplo del archivo.\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "No se puede conectar al bus del sistema: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "No se puede obtener el llamador desde el PID: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "No se puede poner UID en el objeto llamador."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "Falló al obtener sesión CK."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "No se puede poner UID en el objeto de sesión."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "No se puede asignar PolKitAction."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "No se pudo poner action_id"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "No se pudo asignar PolKitContext."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "No se pudo inicializar PolKitContext: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "No se pudo determinar si el llamador está autorizado: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "No se pudo obtener auth: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit respondió con '%s'"
+
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Planificación de alta prioridad (nivel Unix negativo) para el demonio "
+#~ "PulseAudio"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Planificación de tiempo real para el demonio de PulseAudio."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "Las políticas del sistema impidieron a PulseAudio adquirir la "
+#~ "planificación de alta prioridad."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "Las políticas del sistema impidieron a PulseAudio adquirir la "
+#~ "planificación de tiempo real."
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "read() falló: %s\n"
+
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "pa_context_connect() falló: %s\n"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr ""
+#~ "Estamos en el grupo '%s', permitiendo planificación de prioridad alta."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr "Estamos en el grupo '%s', permitiendo planificación en tiempo real."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr "PolicyKit garantiza que se obtenga el privilegio de alta prioridad."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "PolicyKit se niega a dar acceso al privilegio de alta prioridad."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "PolicyKit garantiza el acceso al privilegio de tiempo real."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "PolicyKit se niega a dar acceso al privilegio de tiempo real."
+
+#~ msgid ""
+#~ "Called SUID root and real-time and/or high-priority scheduling was "
+#~ "requested in the configuration. However, we lack the necessary "
+#~ "privileges:\n"
+#~ "We are not in group '%s', PolicyKit refuse to grant us the requested "
+#~ "privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
+#~ "limits.\n"
+#~ "For enabling real-time/high-priority scheduling please acquire the "
+#~ "appropriate PolicyKit privileges, or become a member of '%s', or increase "
+#~ "the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+#~ msgstr ""
+#~ "Se llamó con SUID root y se pidió planificación en tiempo real y/o de "
+#~ "alta prioridad en la configuración. Sin embargo, no se tiene los "
+#~ "privilegios necesarios:\n"
+#~ "No se está en el grupo '%s'. PolicyKit rechaza darnos el permiso "
+#~ "necesario y no se puede aumentar los límites del recurso RLIMIT_NICE/"
+#~ "RLIMIT_RTPRIO.\n"
+#~ "Para habilitar la planifiación de tiempo real/alta prioridad por favor "
+#~ "adquiera los privilegios apropiados en PolicyKit, o hágase miembro de '%"
+#~ "s', o aumente los límites del recurso RLIMIT_NICE/RLIMIT_RTPRIO para este "
+#~ "usuario."
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "Está habilitadada la planificación de prioridad alta, pero no están "
+#~ "permitidas por la política."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "RLIMIT_RTPRIO incrementado en forma exitosa"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "Fallo en RLIMIT_RTPRIO: %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "Abandonando CAP_NICE"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "Está habilitada la planificación en tiempo real, pero no está permitido "
+#~ "por la política."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "Capacidades limitadas con éxito para CAP_SYS_NICE-"
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "time_new() falló.\n"
+
+#~ msgid "Output %s + Input %s"
+#~ msgstr "Salida %s + Entrada %s"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Se ha creado el flujo exitosamente\n"
+
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "Error de flujo: %s\n"
+
+#~ msgid "Connection established.\n"
+#~ msgstr "Conección establecida.\n"
+
+#~ msgid ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Show this help\n"
+#~ " --version Show version\n"
+#~ "\n"
+#~ " -v, --verbose Enable verbose operation\n"
+#~ "\n"
+#~ " -s, --server=SERVER The name of the server to connect "
+#~ "to\n"
+#~ " -d, --device=DEVICE The name of the sink to connect "
+#~ "to\n"
+#~ " -n, --client-name=NAME How to call this client on the "
+#~ "server\n"
+#~ " --stream-name=NAME How to call this stream on the "
+#~ "server\n"
+#~ " --volume=VOLUME Specify the initial (linear) "
+#~ "volume in range 0...65536\n"
+#~ " --channel-map=CHANNELMAP Set the channel map to the use\n"
+#~ msgstr ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Muestra esta ayuda\n"
+#~ " --version Muestra la versión\n"
+#~ "\n"
+#~ " -v, --verbose Habilita operación con "
+#~ "vocabulario más detallado\n"
+#~ "\n"
+#~ " -s, --server=SERVER El nombre del servidor al que "
+#~ "conectarse\n"
+#~ " -d, --device=DEVICE El nombre del destino al que "
+#~ "conectarse\n"
+#~ " -n, --client-name=NAME Cómo llamar a este cliente en el "
+#~ "servidor\n"
+#~ " --stream-name=NAME Cómo llamar a este flujo en el "
+#~ "servidor\n"
+#~ " --volume=VOLUME Especifica el volumen inicial "
+#~ "(linear)en el rango de 0...65536\n"
+#~ " --channel-map=CHANNELMAP Establece el mapa del canal para "
+#~ "el uso\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Compilado con libpulse %s\n"
+#~ "Linked con libpulse %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Mapa de canal inválido\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Error al intentar abrir el archivo '%s'\n"
+
+#~ msgid "Channel map doesn't match file.\n"
+#~ msgstr "El mapa del canal no se corresponde con el archivo.\n"
+
+#~ msgid "Using sample spec '%s'\n"
+#~ msgstr "Utilizando especificaciones de muestra '%s'\n"
+
#, fuzzy
#~ msgid ""
#~ "Called SUID root and real-time and/or high-priority scheduling was "
@@ -2540,9 +3003,3 @@ msgstr "Servidor de Sonido PulseAudio"
#~ "Tipo: %s\n"
#~ "Módulo: %s\n"
#~ "Argumento: %s\n"
-
-#~ msgid "sink"
-#~ msgstr "destino"
-
-#~ msgid "source"
-#~ msgstr "fuente"
diff --git a/po/fi.po b/po/fi.po
index 5b72a3dc..fcdfa2af 100644
--- a/po/fi.po
+++ b/po/fi.po
@@ -7,8 +7,8 @@ msgid ""
msgstr ""
"Project-Id-Version: git trunk\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-05 16:24+0300\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-23 23:45+0200\n"
"Last-Translator: Ville-Pekka Vainio <vpivaini@cs.helsinki.fi>\n"
"Language-Team: Finnish <laatu@lokalisointi.org>\n"
"MIME-Version: 1.0\n"
@@ -16,51 +16,12 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analoginen mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analoginen stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Digitaalinen stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Digitaalinen stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analoginen tilaääni 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digitaalinen tilaääni 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analoginen tilaääni 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analoginen tilaääni 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analoginen tilaääni 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digitaalinen tilaääni 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analoginen tilaääni 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -72,7 +33,7 @@ msgstr ""
"Tämä on todennäköisesti ohjelmavirhe ALSA-ajurissa â€%sâ€. Ilmoita tästä "
"ongelmasta ALSA-kehittäjille."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -85,7 +46,7 @@ msgstr ""
"Tämä on todennäköisesti ohjelmavirhe ALSA-ajurissa â€%sâ€. Ilmoita tästä "
"ongelmasta ALSA-kehittäjille."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -98,11 +59,46 @@ msgstr ""
"Tämä on todennäköisesti ohjelmavirhe ALSA-ajurissa â€%sâ€. Ilmoita tästä "
"ongelmasta ALSA-kehittäjille."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Pidä aina vähintään yksi nielu ladattuna, vaikka se olisi tyhjä nielu"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Valeulostulo"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Virtuaalinen LADSPA-nielu"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nielun nimi> sink_properties=<nielun asetukset> "
+"master=<suodatettavan nielun nimi> format=<näytemuoto> "
+"rate=<näytteenottotaajuus> channels=<kanavien määrä> "
+"channel_map=<kanavakartta> plugin=<ladspa-liitännäisen nimi> label=<ladspa-"
+"liitännäisen nimiö (label)> control=<pilkulla erotettu luettelo "
+"syötteenhallinta-arvoja>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Kellotettu tyhjä nielu"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Tyhjä ulostulo"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Sisäinen äänentoisto"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Modeemi"
@@ -118,220 +114,98 @@ msgstr "Uuden dl-lataaminen varaaminen epäonnistui."
msgid "Failed to add bind-now-loader."
msgstr "bind-now-loaderin lisääminen epäonnistui."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Järjestelmäväylään ei voida yhdistää: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Kutsujaa ei saada PID:stä: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "UID:tä ei voida asettaa kutsujaobjektille."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK-istunnon saaminen epäonnistui."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "UID:tä ei voida asettaa istunto-objektille."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Ei voida varata PolKitActionia."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Ei voida asettaa action_id:tä"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Ei voida varata PolKitContextia."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Ei voida alustaa PolKitContextia: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Ei voida päätellä onko kutsujalla käyttöoikeus: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Tunnistautumista ei saada: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit vastasi â€%sâ€"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Saatiin signaali %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Poistutaan."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Käyttäjää â€%s†ei löydetty."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Ryhmää â€%s†ei löydetty."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Löydettiin käyttäjä â€%s†(UID %lu) ja ryhmä â€%s†(GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "Käyttäjän â€%s†ja ryhmän â€%s†GID:t eivät vastaa toisiaan."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Käyttäjän â€%s†kotihakemisto ei ole â€%sâ€, ohitetaan."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Hakemiston â€%s†luominen epäonnistui: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Ryhmäluettelon vaihtaminen epäonnistui: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID:n vaihtaminen epäonnistui: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID:n vaihtaminen epäonnistui: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Root-oikeuksista luopuminen onnistui."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "Järjestelmänlaajuista tilaa ei tueta tällä alustalla."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) epäonnistui: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Komentorivin jäsentäminen epäonnistui."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "Ollaan ryhmässä â€%sâ€, korkean prioriteetin ajoitus on sallittua."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "Ollaan ryhmässä â€%sâ€, tosiaikainen vuorottaminen on sallittua."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit myöntää acquire-high-priority-oikeuden."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit ei myönnä acquire-high-priority-oikeutta."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit myöntää acquire-real-time-oikeuden."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit ei myönnä acquire-real-time-oikeutta."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"Ohjelmaa kutsuttiin SUID-rootina ja reaaliaikaista ja/tai korkean "
-"prioriteetin ajoitusta pyydettiin asetuksissa. Tarvittavat oikeudet "
-"kuitenkin puuttuvat:\n"
-"Ei olla ryhmässä â€%sâ€, PolicyKit ei myönnä pyydettyjä oikeuksia ja "
-"RLIMIT_NICE/RLIMIT_RTPRIO-resurssirajoja ei ole kasvatettu.\n"
-"Hanki riittävät PolicyKit-oikeudet, liity ryhmään â€%s†tai kasvata tämän "
-"käyttäjän RLIMIT_NICE/RLIMIT_RTPRIO-resurssirajoja reaaliaikaisen ja/tai "
-"korkean prioriteetin ajoituksen ottamiseksi käyttöön."
-
-#: ../src/daemon/main.c:581
+#: ../src/daemon/main.c:535
msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"Korkean prioriteetin ajoitus otettu käyttöön asetuksissa, mutta käytännöt "
-"eivät salli sitä."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO:n kasvatus onnistui"
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO epäonnistui: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Luovutaan CAP_NICE:stä"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Tosiaikainen ajoitus otettu käyttöön asetuksissa, mutta käytännöt eivät "
-"salli sitä."
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Taustaprosessi ei ole käynnissä"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Taustaprosessi käynnissä prosessitunnisteella %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Taustaprosessin lopettaminen epäonnistui: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -339,164 +213,198 @@ msgstr ""
"Tätä ohjelmaa ei ole tarkoitettu suoritettavaksi pääkäyttäjänä (ellei --"
"system ole määritelty)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Pääkäyttäjän (root) oikeudet vaaditaan."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start-valitsinta ei tueta järjestelmätilassa."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
"Suoritetaan järjestelmätilassa, mutta --disallow-exit ei ole asetettuna!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"Suoritetaan järjestelmätilassa, mutta -disallow-module-loading ei ole "
"asetettuna!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr ""
"Suoritetaan järjestelmätilassa, otetaan SHM-tila pakotetusti pois käytöstä."
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"Suoritetaan järjestelmätilassa, otetaan poistumisen joutenoloaika "
"pakotetusti pois käytöstä."
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio:n saaminen epäonnistui."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "putki epäonnistui: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() epäonnistui: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() epäonnistui: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Taustaprosessin käynnistys epäonnistui."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Taustaprosessin käynnistys onnistui."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() epäonnistui: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Tämä on PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Käännöksen isäntäkone: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "Käännösaikaiset C-liput (CFLAGS): %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Käynnissä isäntäkoneella: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "Löydettiin %u CPU:ta."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "Sivun koko on %lu tavua"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Käännetty Valgrind-tuella: kyllä"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Käännetty Valgrind-tuella: ei"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Käynnissä valgrind-tilassa: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Käynnissä isäntäkoneella: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Optimoitu rakentaminen: kyllä"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Optimoitu rakentaminen: ei"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG on määritelty, kaikki assertit ovat poissa käytöstä."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH on määritelty, vain fast path -assertit ovat poissa käytöstä."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Kaikki assertit ovat käytössä."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Konetunnisteen nouto epäonnistui"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "Konetunniste on %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "Konetunniste on %s."
+msgstr "Istunnon tunniste on %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Käytetään ajonaikaista hakemistoa %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Käytetään tilahakemistoa %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Käytetään moduulihakemistoa %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Suoritetaan järjestelmätilassa: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"PA:ta suoritetaan järjestelmätilassa. Näin ei luultavasti pitäisi tehdä.\n"
+"Jos silti teet näin, on sinun vikasi jos kaikki ei toimikaan odotetusti.\n"
+"Lisätietoja siitä, miksi järjestelmätilan käyttäminen on yleensä huono "
+"ajatus on osoitteessa http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() epäonnistui."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Korkean tarkkuuden ajastimet käytettävissä."
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -504,33 +412,33 @@ msgstr ""
"Hei, ytimesi on kehno! Linux korkean tarkkuuden ajastimien tuella on hyvin "
"suositeltava!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() epäonnistui."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Taustaprosessin alustus epäonnistui."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
"Taustaprosessin käynnistys ilman ladattavia moduuleita, kieltäydytään "
"toiminnasta."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "Taustaprosessin käynnistys valmis."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Taustaprosessin sulkeminen käynnistetty."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Taustaprosessi lopetettu."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -685,15 +593,15 @@ msgstr ""
" -n Älä lataa oletuskomentosarja-\n"
" tiedostoa\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -701,54 +609,54 @@ msgstr ""
"--log-level vaatii lokikirjoituksen tason argumentiksi (joko numero väliltä "
"0..4 tai yksi seuraavista: debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"Virheellinen lokikirjoituksen kohde: käytä jotain seuraavista: â€syslogâ€, "
"â€stderr†tai â€autoâ€."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Virheellinen uudelleennäytteistyksen tapa â€%sâ€."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit vaatii totuusarvoisen argumentin"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm vaatii totuusarvoisen argumentin"
@@ -787,77 +695,87 @@ msgstr "Käyttö: %s\n"
msgid "Load Once: %s\n"
msgstr "Lataa kerran: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "VAROITUS VANHENTUNEISUUDESTA: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Polku: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Virheellinen lokikirjoituksen kohde â€%sâ€."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Virheellinen lokikirjoituksen taso â€%sâ€."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Virheellinen uudelleennäytteistyksen tapa â€%sâ€."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Virheellinen rlimit â€%sâ€."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimitiä ei tueta tällä alustalla."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Virheellinen näytemuoto â€%sâ€."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Virheellinen näytteenottotaajuus â€%sâ€."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Virheelliset näytekanavat â€%sâ€."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Virheellinen kanavakartta â€%sâ€."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Virheellinen fragmenttimäärä â€%sâ€."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Virheellinen fragmenttikoko â€%sâ€."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Virheellinen nice-taso â€%sâ€."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Virheellinen näytteenottotaajuus â€%sâ€."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Asetustiedoston avaaminen epäonnistui: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -865,18 +783,14 @@ msgstr ""
"Kanavien oletusmäärä ja oletuskanavakartan kanavien määrä poikkeavat "
"toisistaan."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Luettu asetustiedostosta: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Luovutaan pääkäyttäjän oikeuksista."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Oikeuksien rajoittaminen CAP_SYS_NICEen onnistui."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Luovutaan oikeuksista."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -886,260 +800,237 @@ msgstr "PulseAudio-äänijärjestelmä"
msgid "Start the PulseAudio Sound System"
msgstr "Käynnistä PulseAudio-äänijärjestelmä"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"Korkean prioriteetin ajoitus (negatiivinen Unix-nice-taso) PulseAudio-"
-"taustajärjestelmälle"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Reaaliaikainen ajoitus PulseAudio-taustajärjestelmälle"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Järjestelmäkäytäntö estää PulseAudiota saamasta korkean prioriteetin "
-"ajoitusta."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"Järjestelmäkäytäntö estää PulseAudiota saamasta reaaliaikaista ajoitusta."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Keski"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Vasen etu"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Oikea etu"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Takakeski"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Vasen taka"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Oikea taka"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Alataajuus"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Vasemmalle keskeltä etu"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Oikealle keskeltä etu"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Vasen sivu"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Oikea sivu"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Avustava 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Avustava 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Avustava 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Avustava 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Avustava 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Avustava 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Avustava 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Avustava 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Avustava 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Avustava 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Avustava 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Avustava 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Avustava 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Avustava 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Avustava 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Avustava 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Avustava 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Avustava 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Avustava 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Avustava 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Avustava 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Avustava 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Avustava 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Avustava 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Avustava 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Avustava 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Avustava 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Avustava 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Avustava 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Avustava 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Avustava 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Avustava 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Keski ylä"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Keski ylä etu"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Vasen ylä etu"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Oikea ylä etu"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Keski ylä taka"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Vasen ylä taka"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Oikea ylä taka"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(virheellinen)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "4.0-tilaääni"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "4.1-tilaääni"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "5.0-tilaääni"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "5.1-tilaääni"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "7.1-tilaääni"
@@ -1243,27 +1134,35 @@ msgstr "Puuttuva toteutus"
msgid "Client forked"
msgstr "Asiakasohjelma haarautui"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Siirräntävirhe"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Laite tai resurssi on varattu"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %u kan. %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1276,197 +1175,191 @@ msgstr "XOpenDisplay() epäonnistui"
msgid "Failed to parse cookie data"
msgstr "Evästetietojen jäsennys epäonnistui"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Asetustiedoston avaaminen epäonnistui: â€%sâ€: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Ei ladattua evästettä. Yritetään yhdistämistä ilman."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Saatiin viesti tuntemattomalle laajennokselle â€%sâ€"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() epäonnistui: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Virran tyhjentäminen epäonnistui: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() epäonnistui: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Toistovirta on tyhjennetty."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Virran luonti onnistui.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Tyhjennetään yhteyttä palvelimelle."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() epäonnistui: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Puskuritiedot: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() epäonnistui: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Puskuritiedot: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() epäonnistui: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Käytetään näytemäärittelyä â€%sâ€, kanavakarttaa â€%sâ€.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() epäonnistui: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Yhdistetty laitteeseen %s (%u, %ssuspended).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Virran luonti onnistui."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Virtavirhe: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() epäonnistui: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Virtalaite keskeytetty.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Puskuritiedot: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Virtalaite palautettu.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Puskuritiedot: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Virran alivuoto.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Käytetään näytemäärittelyä â€%sâ€, kanavakarttaa â€%sâ€."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Virran ylivuoto.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Yhdistetty laitteeseen %s (%u, %ssuspended)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Virta käynnistetty.%s \n"
+msgid "Stream error: %s"
+msgstr "Virtavirhe: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Virta siirretty laitteelle %s (%u, %ssuspended).%s \n"
+msgid "Stream device suspended.%s"
+msgstr "Virtalaite keskeytetty.%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "ei "
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Virran puskuriattribuutteja muutettu.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "Virtalaite palautettu.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Yhteys muodostettu.%s \n"
+msgid "Stream underrun.%s"
+msgstr "Virran alivuoto.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() epäonnistui: %s\n"
+msgid "Stream overrun.%s"
+msgstr "Virran ylivuoto.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() epäonnistui: %s\n"
+msgid "Stream started.%s"
+msgstr "Virta käynnistetty.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() epäonnistui: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Virta siirretty laitteelle %s (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Yhteysvirhe: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "ei "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Virran tyhjentäminen epäonnistui: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Virran puskuriattribuutteja muutettu.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Toistovirta on tyhjennetty.\n"
+msgid "Connection established.%s"
+msgstr "Yhteys muodostettu.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Tyhjennetään yhteyttä palvelimelle.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() epäonnistui: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "Saatiin EOF.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() epäonnistui: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() epäonnistui: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() epäonnistui: %s\n"
+msgid "Connection failure: %s"
+msgstr "Yhteysvirhe: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() epäonnistui: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Saatiin EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Saatiin signaali, lopetetaan.\n"
+msgid "write() failed: %s"
+msgstr "write() epäonnistui: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Latenssin selvittäminen epäonnistui: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Saatiin signaali, lopetetaan."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Aika: %0.3f s; latenssi: %0.0f μs. \r"
+msgid "Failed to get latency: %s"
+msgstr "Latenssin selvittäminen epäonnistui: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() epäonnistui: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Aika: %0.3f s; Latenssi: %0.0f μs."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() epäonnistui: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1492,8 +1385,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1516,6 +1411,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [valitsimet]\n"
"\n"
@@ -1527,34 +1431,33 @@ msgstr ""
"\n"
" -v, --verbose Yksityiskohtaiset tulosteet\n"
"\n"
-" -s, --server=PALVELIN Sen palvelimen nimi, johon\n"
-" yhdistetään\n"
-" -d, --device=LAITE Sen nielun/lähteen nimi, johon\n"
-" yhdistetään\n"
+" -s, --server=PALVELIN Sen palvelimen nimi, johon "
+"yhdistetään\n"
+" -d, --device=LAITE Sen nielun/lähteen nimi, johon "
+"yhdistetään\n"
" -n, --client-name=NIMI Kuinka tätä asiakasohjelmaa "
-"kutsutaan\n"
-" palvelimella\n"
-" --stream-name=NIMI Kuinka tätä virtaa kutsutaan\n"
-" palvelimella\n"
-" --volume=ÄÄNENVOIMAKKUUS Määritä (lineaarinen) aloitusäänen-\n"
-" voimakkuus väliltä 0...65536\n"
-" --rate=NÄYTTEENOTTOTAAJUUS Näytteenottotaajuus hertseinä\n"
-" (oletus: 44100)\n"
-" --format=NÄYTEMUOTO Näytteen tyyppi, yksi seuraavista:\n"
-" s16le, s16be, u8, float32le,\n"
+"kutsutaan palvelimella\n"
+" --stream-name=NIMI Kuinka tätä virtaa kutsutaan "
+"palvelimella\n"
+" --volume=ÄÄNENVOIMAKKUUS Määritä (lineaarinen) "
+"aloitusäänenvoimakkuus väliltä 0...65536\n"
+" --rate=NÄYTTEENOTTOTAAJUUS Näytteenottotaajuus hertseinä"
+"(oletus: 44100)\n"
+" --format=NÄYTEMUOTO Näytteen tyyppi, yksi seuraavista:"
+"s16le, s16be, u8, float32le,\n"
" float32be, ulaw, alaw, s32le, s32be\n"
-" (oletus s16ne)\n"
+"s24le, s24be,\n"
+" s24-32le, s24-32be (oletus s16ne)\n"
" --channels=KANAVIA Kanavien määrä, 1=mono, 2=stereo\n"
" (oletus: 2)\n"
-" --channel-map=KANAVAKARTTA Oletuksen sijasta käytettävä\n"
-" kanavakartta\n"
-" --fix-format Valitse näytemuoto nielusta, johon\n"
-" virtaa yhdistetään\n"
+" --channel-map=KANAVAKARTTA Oletuksen sijasta käytettävä "
+"kanavakartta\n"
+" --fix-format Valitse näytemuoto nielusta, jossa "
+"virta on\n"
" --fix-rate Valitse näytteenottotaajuus "
-"nielusta,\n"
-" johon virtaa yhdistetään\n"
-" --fix-channels Valitse kanavien määrä ja kanava-\n"
-" kartta nielusta, johon virtaa\n"
+"nielusta, jossa virta on\n"
+" --fix-channels Valitse kanavien määrä ja "
+"kanavakartta nielusta, johon virtaa\n"
" yhdistetään.\n"
" --no-remix Älä yli- tai alimiksaa kanavia.\n"
" --no-remap Kartoita kanavat indeksin mukaan, "
@@ -1563,8 +1466,15 @@ msgstr ""
"tavuissa.\n"
" --process-time=TAVUA Pyydä määritettyä prosessiaikaa "
"pyyntöä kohti tavuissa.\n"
+" --property=ASETUS=ARVO Anna määritetylle asetukselle "
+"määritetty arvo.\n"
+" --raw Tallenna/soita raakaa PCM-dataa.\n"
+" --file-format=TMUOTO Tallenna/soita tietyn muotoista PCM-"
+"dataa.\n"
+" --list-file-formats Luettele käytettävissä olevat "
+"tiedostomuodot.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1575,129 +1485,170 @@ msgstr ""
"Käännetty libpulsen versiolle %s\n"
"Linkitetty libpulsen versiolle %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Virheellinen kanavakartta â€%sâ€\n"
+msgid "Invalid client name '%s'"
+msgstr "Virheellinen asiakasohjelman nimi â€%sâ€"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Virheellinen latenssimääritys â€%sâ€\n"
+msgid "Invalid stream name '%s'"
+msgstr "Virheellinen virran nimi â€%sâ€"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Virheellinen prosessiajan määritys â€%sâ€\n"
+msgid "Invalid channel map '%s'"
+msgstr "Virheellinen kanavakartta â€%sâ€"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Virheellinen näytemääritys\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Virheellinen latenssimääritys â€%sâ€"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Kanavakartta ei vastaa näytemääritystä\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Virheellinen prosessiajan määritys â€%sâ€"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Avataan %svirta näytemäärityksellä â€%sâ€.\n"
+msgid "Invalid property '%s'"
+msgstr "Virheellinen asetus â€%sâ€"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "nauhoitus"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Tuntematon tiedostomuoto %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "toisto"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Virheellinen näytemääritys"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Liian monta argumenttia.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Liian monta argumenttia."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() epäonnistui.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Näytemäärityksen generointi tiedostolle epäonnistui."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() epäonnistui.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Äänitiedoston avaaminen epäonnistui."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() epäonnistui.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Varoitus: tiedostosta luettava näytemääritys korvaa annetun määrityksen."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() epäonnistui: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Näytemäärityksen selvittäminen tiedostosta epäonnistui."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Varoitus: Kanavakartan selvittäminen tiedostosta epäonnistui."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Kanavakartta ei vastaa näytemääritystä"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Varoitus: kanavakartan kirjoittaminen tiedostoon epäonnistui."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() epäonnistui.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "Avataan %svirta näytemäärityksellä â€%s†ja kanavakartalla â€%sâ€."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "nauhoitus"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "toisto"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() epäonnistui."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() epäonnistui."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() epäonnistui."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() epäonnistui.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() epäonnistui: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_new() epäonnistui."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() epäonnistui."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Keskeytys epäonnistui: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Palautus epäonnistui: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "VAROITUS: Äänipalvelin ei ole paikallinen, ei keskeytetä.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Yhteysvirhe: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Saatiin SIGINT, lopetetaan.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "VAROITUS: Lapsiprosessi lopetettiin signaalilla %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1716,7 +1667,7 @@ msgstr ""
" yhdistetään\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1727,35 +1678,61 @@ msgstr ""
"Käännetty libpulsen versiolle %s\n"
"Linkitetty libpulsen versiolle %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() epäonnistui.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() epäonnistui.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() epäonnistui.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Tilastojen selvittäminen epäonnistui: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "Tilastojen selvittäminen epäonnistui: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Nyt käytössä: %u lohkoa sisältäen yhteensä %s tavua.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "Koko käyttöaikana varattu: %u lohkoa sisältäen yhteensä %s tavua.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Näytevälimuistin koko: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Palvelintietojen selvittäminen epäonnistui: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Palvelintietojen selvittäminen epäonnistui: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1763,7 +1740,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Käyttäjänimi: %s\n"
"Konenimi: %s\n"
@@ -1775,12 +1752,12 @@ msgstr ""
"Oletuslähde: %s\n"
"Eväste: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Nielun tietojen nouto epäonnistui: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Nielun tietojen nouto epäonnistui: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1819,12 +1796,22 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPortit:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Lähteen tietojen nouto epäonnistui: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tAktiivinen portti: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Lähteen tietojen nouto epäonnistui: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1863,20 +1850,20 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "-"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Moduulin tietojen nouto epäonnistui: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Moduulin tietojen nouto epäonnistui: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1893,12 +1880,12 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Asiakkaan tietojen nouto epäonnistui: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Asiakkaan tietojen nouto epäonnistui: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1913,12 +1900,12 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Kortin tietojen nouto epäonnistui: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Kortin tietojen nouto epäonnistui: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1935,22 +1922,22 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tProfiilit:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tAktiivinen profiili: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Nielun sisääntulon tietojen nouto epäonnistui: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Nielun sisääntulon tietojen nouto epäonnistui: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1987,12 +1974,12 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Lähteen ulostulon tietojen nouto epäonnistui: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "Lähteen ulostulon tietojen nouto epäonnistui: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2021,12 +2008,12 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Näytetietojen nouto epäonnistui: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Näytetietojen nouto epäonnistui: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2057,23 +2044,81 @@ msgstr ""
"\tOminaisuudet:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Epäonnistuminen: %s\n"
+msgid "Failure: %s"
+msgstr "Epäonnistuminen: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Näytteen lähettäminen epäonnistui: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Näytteen lähettäminen epäonnistui: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Ennenaikainen tiedoston päättyminen\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Ennenaikainen tiedoston päättyminen"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr "nielu"
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr "lähde"
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+#, fuzzy
+msgid "source-output"
+msgstr "lähde"
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Virheellinen palvelin"
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Saatiin SIGINT, lopetetaan."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2081,13 +2126,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2103,23 +2157,31 @@ msgstr ""
"%s [valitsimet] upload-sample TIEDOSTONIMI [NIMI]\n"
"%s [valitsimet] play-sample NIMI [NIELU]\n"
"%s [valitsimet] remove-sample NIMI\n"
-"%s [valitsimet] move-sink-input TUNNISTE NIELU\n"
-"%s [valitsimet] move-source-output TUNNISTE LÄHDE\n"
+"%s [valitsimet] move-sink-input NIELUSISÄÄNMENO NIELU\n"
+"%s [valitsimet] move-source-output LÄHDEULOSTULO LÄHDE\n"
"%s [valitsimet] load-module NIMI [ARGUMENTIT ...]\n"
-"%s [valitsimet] unload-module TUNNISTE\n"
-"%s [valitsimet] suspend-sink [NIELU] 1|0\n"
-"%s [valitsimet] suspend-source [LÄHDE] 1|0\n"
-"%s [valitsimet] set-card-profile [KORTTI] [PROFIILI] \n"
+"%s [valitsimet] unload-module MODUULI\n"
+"%s [valitsimet] suspend-sink NIELU 1|0\n"
+"%s [valitsimet] suspend-source LÄHDE 1|0\n"
+"%s [valitsimet] set-card-profile KORTTI PROFIILI\n"
+"%s [valitsimet] set-sink-port NIELU PORTTI\n"
+"%s [valitsimet] set-source-port LÄHDE PORTTI\n"
+"%s [valitsimet] set-sink-volume NIELU VOIMAKKUUS\n"
+"%s [valitsimet] set-source-volume LÄHDE VOIMAKKUUS\n"
+"%s [valitsimet] set-sink-input-volume NIELUSISÄÄNMENO VOIMAKKUUS\n"
+"%s [valitsimet] set-sink-mute NIELU 1|0\n"
+"%s [valitsimet] set-source-mute LÄHDE 1|0\n"
+"%s [valitsimet] set-sink-input-mute NIELUSISÄÄNMENO 1|0\n"
"\n"
" -h, --help Näytä tämä ohje\n"
" --version Näytä versio\n"
"\n"
-" -s, --server=PALVELIN Sen palvelimen nimi, johon\n"
-" yhdistetään\n"
-" -n, --client-name=NIMI Kuinka tätä asiakasohjelmaa\n"
-" kutsutaan palvelimella\n"
+" -s, --server=PALVELIN Sen palvelimen nimi, johon "
+"yhdistetään\n"
+" -n, --client-name=NIMI Kuinka tätä asiakasohjelmaa "
+"kutsutaan palvelimella\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2130,74 +2192,106 @@ msgstr ""
"Käännetty libpulsen versiolle %s\n"
"Linkitetty libpulsen versiolle %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Anna ladattava näytetiedosto\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Anna ladattava näytetiedosto"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Äänitiedoston avaaminen epäonnistui.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Äänitiedoston avaaminen epäonnistui."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Soitettavan näytteen nimi on annettava\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Varoitus: näytemäärityksen selvitys tiedostosta epäonnistui."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Poistettavan näytteen nimi on annettava\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Soitettavan näytteen nimi on annettava"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Nielun syöteindeksi ja nielu on annettava\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Poistettavan näytteen nimi on annettava"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Lähteen ulostuloindeksi ja lähde on annettava\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Nielun syöteindeksi ja nielu on annettava"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Moduulin nimi ja argumentit on annettava.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Lähteen ulostuloindeksi ja lähde on annettava"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Moduulin indeksi on annettava\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Moduulin nimi ja argumentit on annettava."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Moduulin indeksi on annettava"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr "Ei voi antaa enempää kuin yhden nielun. Totuusarvo on annettava.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr "Ei voi antaa enempää kuin yhden nielun. Totuusarvo on annettava."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr "Ei voi antaa enempää kuin yhden lähteen. Totuusarvo on annettava.\n"
+"value."
+msgstr "Ei voi antaa enempää kuin yhden lähteen. Totuusarvo on annettava."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Kortin nimi/indeksi ja profiilin nimi on annettava\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Kortin nimi/indeksi ja profiilin nimi on annettava"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Mitään kelvollista komentoa ei annettu.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Nielun nimi/indeksi ja portin nimi on annettava"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() epäonnistui: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Lähteen nimi/indeksi ja portin nimi on annettava"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Nielun nimi/indeksi ja portin nimi on annettava"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Virheellinen äänenvoimakkuuden määritys"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Lähteen nimi/indeksi ja äänenvoimakkuus on annettava"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Nielun syöteindeksi ja äänenvoimakkuus on annettava"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Virheellinen nielun syöteindeksi"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Nielun nimi/indeksi ja vaimennuksen totuusarvo on annettava"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Lähteen nimi/indeksi ja vaimennuksen totuusarvo on annettava"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "Nielun syöteindeksi ja vaimennuksen totuusarvo on annettava"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Virheellinen nielun syöteindeksin määritys"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Mitään kelvollista komentoa ei annettu."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2280,130 +2374,50 @@ msgstr "Evästetietojen lataaminen epäonnistui\n"
msgid "Not yet implemented.\n"
msgstr "Toteutusta ei vielä ole.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"PulseAudio-taustaprosessi ei ole käynnissä eikä PulseAudiota suoriteta "
+"istunnon taustaprosessina."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio-taustaprosessin lopettaminen epäonnistui."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Taustaprosessi ei vastaa."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Virran luonti onnistui\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Virtavirhe: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Yhteys muodostetettu.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [valitsimet] [TIEDOSTO]\n"
-"\n"
-" -h, --help Näytä tämä ohje\n"
-" --version Näytä tiedostot\n"
-"\n"
-" -v, --verbose Yksityiskohtaiset tulosteet\n"
-"\n"
-" -s, --server=PALVELIN Sen palvelimen nimi, johon\n"
-" yhdistetään\n"
-" -d, --device=LAITE Sen nielun nimi, johon yhdistetään\n"
-" -n, --client-name=NIMI Kuinka tätä asiakasohjelmaa "
-"kutsutaan\n"
-" palvelimella\n"
-" --stream-name=NIMI Kuinka tätä virtaa kutsutaan\n"
-" palvelimella\n"
-" --volume=ÄÄNENVOIMAKKUUS Määritä (lineaarinen) aloitusäänen-\n"
-" voimakkuus väliltä 0...65536\n"
-" --channel-map=KANAVAKARTTA Aseta käytettävä kanavakartta\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Käännetty libpulsen versiolle %s\n"
-"Linkitetty libpulsen versiolle %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Virheellinen kanavakartta\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Tiedoston â€%s†avaaminen epäonnistui\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Kanavakartta ei täsmää tiedostoon.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Käytetään näytemäärittelyä â€%sâ€\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Automaattisen käynnistyksen lukkoa ei voida käyttää."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2420,7 +2434,7 @@ msgstr ""
"asetettuna, snd_pcm_avail() palautti kuitenkin 0 tai jonkin muun arvon, "
"joka on < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2436,38 +2450,476 @@ msgstr ""
"ongelmasta ALSA-kehittäjille. Taustaprosessi herätettiin POLLIN asetettuna, "
"snd_pcm_avail() palautti kuitenkin 0 tai jonkin muun arvon, on < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Ulostulo %s + Sisääntulo %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Ulostulo %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Sisääntulo %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "Poissa"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "Korkean äänenlaadun toisto (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Korkean äänenlaadun tallennus (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Puhelut, molemmat suunnat (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio-äänipalvelin"
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Ulostulolaitteet"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Sisääntulolaitteet"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Ääni koneella @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Sisääntulo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Telakan sisääntulo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Telakan mikrofoni"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Linjasisääntulo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Mikrofoni"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Ulkoinen mikrofoni"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Sisäinen mikrofoni"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Automaattinen äänenvoimakkuuden säätö"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Ei automaattista äänenvoimakkuuden säätöä"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Vahvistus"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Ei vahvistusta"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Vahvistin"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Ei vahvistinta"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Vahvistus"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Ei vahvistusta"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Analoginen kuulokeliitäntä"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Analoginen sisääntulo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Analoginen mikrofoni"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Analoginen linjasisääntulo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Analoginen radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Analoginen video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Analoginen ulostulo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Analoginen kuulokeliitäntä"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Analoginen ulostulo (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analoginen monoulostulo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analoginen stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analoginen mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analoginen stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analoginen tilaääni 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analoginen tilaääni 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analoginen tilaääni 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analoginen tilaääni 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analoginen tilaääni 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analoginen tilaääni 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analoginen tilaääni 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analoginen tilaääni 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analoginen tilaääni 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analoginen tilaääni 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analoginen tilaääni 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digitaalinen stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digitaalinen tilaääni 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digitaalinen tilaääni 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digitaalinen tilaääni 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digitaalinen stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analoginen mono, molemmat suunnat"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analoginen stereo, molemmat suunnat"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Digitaalinen stereo, molemmat suunnat (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Alataajuus"
+
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Virheellinen asiakasohjelman nimi â€%sâ€\n"
+
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr "Näytemäärityksen selvitys tiedostosta epäonnistui: %s\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "Järjestelmäväylään ei voida yhdistää: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "Kutsujaa ei saada PID:stä: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "UID:tä ei voida asettaa kutsujaobjektille."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "CK-istunnon saaminen epäonnistui."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "UID:tä ei voida asettaa istunto-objektille."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "Ei voida varata PolKitActionia."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "Ei voida asettaa action_id:tä"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "Ei voida varata PolKitContextia."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "Ei voida alustaa PolKitContextia: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "Ei voida päätellä onko kutsujalla käyttöoikeus: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "Tunnistautumista ei saada: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit vastasi â€%sâ€"
+
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Korkean prioriteetin ajoitus (negatiivinen Unix-nice-taso) PulseAudio-"
+#~ "taustajärjestelmälle"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Reaaliaikainen ajoitus PulseAudio-taustajärjestelmälle"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "Järjestelmäkäytäntö estää PulseAudiota saamasta korkean prioriteetin "
+#~ "ajoitusta."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "Järjestelmäkäytäntö estää PulseAudiota saamasta reaaliaikaista ajoitusta."
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "read() epäonnistui: %s\n"
+
+#, fuzzy
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "pa_context_connect() epäonnistui: %s"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr "Ollaan ryhmässä â€%sâ€, korkean prioriteetin ajoitus on sallittua."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr "Ollaan ryhmässä â€%sâ€, tosiaikainen vuorottaminen on sallittua."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr "PolicyKit myöntää acquire-high-priority-oikeuden."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "PolicyKit ei myönnä acquire-high-priority-oikeutta."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "PolicyKit myöntää acquire-real-time-oikeuden."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "PolicyKit ei myönnä acquire-real-time-oikeutta."
+
+#~ msgid ""
+#~ "Called SUID root and real-time and/or high-priority scheduling was "
+#~ "requested in the configuration. However, we lack the necessary "
+#~ "privileges:\n"
+#~ "We are not in group '%s', PolicyKit refuse to grant us the requested "
+#~ "privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
+#~ "limits.\n"
+#~ "For enabling real-time/high-priority scheduling please acquire the "
+#~ "appropriate PolicyKit privileges, or become a member of '%s', or increase "
+#~ "the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+#~ msgstr ""
+#~ "Ohjelmaa kutsuttiin SUID-rootina ja reaaliaikaista ja/tai korkean "
+#~ "prioriteetin ajoitusta pyydettiin asetuksissa. Tarvittavat oikeudet "
+#~ "kuitenkin puuttuvat:\n"
+#~ "Ei olla ryhmässä â€%sâ€, PolicyKit ei myönnä pyydettyjä oikeuksia ja "
+#~ "RLIMIT_NICE/RLIMIT_RTPRIO-resurssirajoja ei ole kasvatettu.\n"
+#~ "Hanki riittävät PolicyKit-oikeudet, liity ryhmään â€%s†tai kasvata tämän "
+#~ "käyttäjän RLIMIT_NICE/RLIMIT_RTPRIO-resurssirajoja reaaliaikaisen ja/tai "
+#~ "korkean prioriteetin ajoituksen ottamiseksi käyttöön."
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "Korkean prioriteetin ajoitus otettu käyttöön asetuksissa, mutta käytännöt "
+#~ "eivät salli sitä."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "RLIMIT_RTPRIO:n kasvatus onnistui"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO epäonnistui: %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "Luovutaan CAP_NICE:stä"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "Tosiaikainen ajoitus otettu käyttöön asetuksissa, mutta käytännöt eivät "
+#~ "salli sitä."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "Oikeuksien rajoittaminen CAP_SYS_NICEen onnistui."
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "time_new() epäonnistui.\n"
+
+#~ msgid "Output %s + Input %s"
+#~ msgstr "Ulostulo %s + Sisääntulo %s"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Virran luonti onnistui\n"
+
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "Virtavirhe: %s\n"
+
+#~ msgid "Connection established.\n"
+#~ msgstr "Yhteys muodostetettu.\n"
+
+#~ msgid ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Show this help\n"
+#~ " --version Show version\n"
+#~ "\n"
+#~ " -v, --verbose Enable verbose operation\n"
+#~ "\n"
+#~ " -s, --server=SERVER The name of the server to connect "
+#~ "to\n"
+#~ " -d, --device=DEVICE The name of the sink to connect "
+#~ "to\n"
+#~ " -n, --client-name=NAME How to call this client on the "
+#~ "server\n"
+#~ " --stream-name=NAME How to call this stream on the "
+#~ "server\n"
+#~ " --volume=VOLUME Specify the initial (linear) "
+#~ "volume in range 0...65536\n"
+#~ " --channel-map=CHANNELMAP Set the channel map to the use\n"
+#~ msgstr ""
+#~ "%s [valitsimet] [TIEDOSTO]\n"
+#~ "\n"
+#~ " -h, --help Näytä tämä ohje\n"
+#~ " --version Näytä tiedostot\n"
+#~ "\n"
+#~ " -v, --verbose Yksityiskohtaiset tulosteet\n"
+#~ "\n"
+#~ " -s, --server=PALVELIN Sen palvelimen nimi, johon\n"
+#~ " yhdistetään\n"
+#~ " -d, --device=LAITE Sen nielun nimi, johon "
+#~ "yhdistetään\n"
+#~ " -n, --client-name=NIMI Kuinka tätä asiakasohjelmaa "
+#~ "kutsutaan\n"
+#~ " palvelimella\n"
+#~ " --stream-name=NIMI Kuinka tätä virtaa kutsutaan\n"
+#~ " palvelimella\n"
+#~ " --volume=ÄÄNENVOIMAKKUUS Määritä (lineaarinen) "
+#~ "aloitusäänen-\n"
+#~ " voimakkuus väliltä 0...65536\n"
+#~ " --channel-map=KANAVAKARTTA Aseta käytettävä kanavakartta\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Käännetty libpulsen versiolle %s\n"
+#~ "Linkitetty libpulsen versiolle %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Virheellinen kanavakartta\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Tiedoston â€%s†avaaminen epäonnistui\n"
+
+#~ msgid "Channel map doesn't match file.\n"
+#~ msgstr "Kanavakartta ei täsmää tiedostoon.\n"
+
+#~ msgid "Using sample spec '%s'\n"
+#~ msgstr "Käytetään näytemäärittelyä â€%sâ€\n"
+
#~ msgid "muted"
#~ msgstr "vaimennettu"
@@ -2483,9 +2935,3 @@ msgstr "PulseAudio-äänipalvelin"
#~ "Tyyppi: %s\n"
#~ "Moduuli: %s\n"
#~ "Argumentto: %s\n"
-
-#~ msgid "sink"
-#~ msgstr "nielu"
-
-#~ msgid "source"
-#~ msgstr "lähde"
diff --git a/po/fr.po b/po/fr.po
index 89c56066..355ec235 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -1,69 +1,33 @@
# French translation of pulseaudio.
# Copyright (C) 2006-2008 Lennart Poettering
# This file is distributed under the same license as the pulseaudio package.
+#
+#
# Robert-André Mauchin <zebob.m@pengzone.org>, 2008.
# Michaël Ughetto <telimektar esraonline com>, 2008.
# Pablo Martin-Gomez <pablo.martin-gomez@laposte.net>, 2008.
-#
-#
+# Corentin Perard <corentin.perard@gmail.com>, 2009.
+# Thomas Canniot <mrtom@fedoraproject.org>, 2009.
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio trunk\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2008-10-18 20:34+0200\n"
-"Last-Translator: Pablo Martin-Gomez <pablo.martin-gomez@laposte.net>\n"
-"Language-Team: Français <fedora-trans-fr@redhat.com>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-09 21:40+0100\n"
+"Last-Translator: Thomas Canniot <mrtom@fedoraproject.org>\n"
+"Language-Team: French <fedora-trans-fr@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n>1;\n"
+"X-Generator: Lokalize 1.0\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr ""
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -71,8 +35,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_avail() a retourné une valeur qui est exceptionnellement large : %lu "
+"octets (%lu ms).\n"
+"Il s'agit très probablement d'un bogue dans le pilote ALSA « %s ». Veuillez "
+"rapporter ce problème aux développeurs d'ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -80,8 +48,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_delay() a retourné une valeur qui est exceptionnellement large : %li "
+"octets (%s%lu ms).\n"
+"Il s'agit très probablement d'un bogue dans le pilote ALSA « %s ». Veuillez "
+"rapporter ce problème aux développeurs d'ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -89,240 +61,159 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_mmap_begin() a retourné une valeur qui est exceptionnellement "
+"large : %lu octets (%lu·ms).\n"
+"Il s'agit très probablement d'un bogue dans le pilote ALSA « %s ». Veuillez "
+"rapporter ce problème aux développeurs d'ALSA."
-#: ../src/pulsecore/sink.c:2141
-#, fuzzy
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Garde toujours au moins une destination même si elle est vide"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Sortie factice"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Destination virtuelle LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nom de la destination> sink_properties=<propriétés de la "
+"destination> master=<nom de la destination à filter> format=<format de "
+"l'échantillon> rate=<taux d'échantillonage> channels=<nombre de canaux> "
+"channel_map=<plan des canaux> plugin=<nom de l'extension ladspa> "
+"label=<étiquette de l'extension ladspa> control=<liste des valeurs de "
+"contrôle de l'entrée séparées par des virgules>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Horloge de la destination vide"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Sortie vide"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
-msgstr "Erreur interne"
+msgstr "Audio interne"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
-msgstr ""
+msgstr "Modem"
#: ../src/daemon/ltdl-bind-now.c:124
-#, fuzzy
msgid "Failed to find original lt_dlopen loader."
-msgstr "Échec lors de la recherche du chargeur dlopen original."
+msgstr "Échec lors de la recherche du chargeur lt_dlopen original."
#: ../src/daemon/ltdl-bind-now.c:129
-#, fuzzy
msgid "Failed to allocate new dl loader."
-msgstr "Échec lors de la recherche du chargeur dlopen original."
+msgstr "Échec lors de l'allocation du nouveau chargeur dl."
#: ../src/daemon/ltdl-bind-now.c:142
msgid "Failed to add bind-now-loader."
msgstr "Échec lors de l'ajout du chargeur bind-now."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Impossible de se connecter au bus système : %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Impossible d'obtenir le programme appelant à partir du PID : %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Impossible de définir un UID sur l'objet appelant."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Échec lors de l'obtention de la session CK."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Impossible de définir l'UID sur l'objet de session."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Impossible d'allouer PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Impossible de définir action_id."
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Impossible d'allouer PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Impossible d'initialiser PolKitContext : %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Impossible de déterminer si le programme appelant est autorisé : %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Impossible d'obtenir l'authentification : %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit a renvoyé « %s »"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Signal %s obtenu."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Fermeture."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Impossible de trouver l'utilisateur « %s »."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Impossible de trouver le groupe « %s »."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Utilisateur « %s †(UID %lu) et groupe « %s » (GID %lu) trouvé."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr ""
"Le GID de l'utilisateur « %s » et du groupe « %s » ne sont pas identiques."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Le dossier personnel de l'utilisateur « %s » n'est pas « %s », ignoré."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Échec lors de la création de « %s » : %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Échec lors du changement de la liste du groupe : %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Échec lors du changement de GID : %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Échec lors du changement d'UID : %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
-msgstr "Les permissions root ont été correctement abandonnées."
+msgstr "Les privilèges root ont été correctement abandonnés."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "Mode système étendu non pris en charge sur cette plateforme."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) a échoué : %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Échec lors de l'analyse de la ligne de commande"
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Nous sommes dans le groupe « %s », permettant une planification à haute "
-"priorité."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Nous sommes dans le groupe « %s », permettant une planification en temps réel."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit a accordé l'acquisition des permissions de haute priorité."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit a refusé l'acquisition des permissions de haute priorité."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit a accordé l'acquisition des permissions de temps réel."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit a refusé l'acquisition des permissions de temps réel."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"La planification à haute priorité est activée dans la configuration mais "
-"n'est pas permise par la politique."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "Augmentation de RLIMIT_RTPRIO réussie"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO a échoué : %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Abandon de CAP_NICE"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"La planification en temps réel est activée mais n'est pas permise par la "
-"politique."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Lé démon n'est pas lancé"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Le démon est lancé avec le PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Impossible de tuer le démon : %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -330,165 +221,201 @@ msgstr ""
"Le programme n'est pas conçu pour être lancé en tant que root (sauf si --"
"system est renseigné)."
-#: ../src/daemon/main.c:720
-#, fuzzy
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
-msgstr "Les permissions root sont nécessaires."
+msgstr "Les privilèges root sont nécessaires."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start n'est pas pris en charge pour les instances système."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
"Le démon s'exécute en mode système, mais --disallow-exit n'est pas défini."
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"Le démon s'exécute en mode système, mais --disallow-module-loading n'est pas "
"défini."
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "Le démon s'exécute en mode système, désactivation forcée du mode SHM."
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"Le démon s'exécute en mode système, désactivation forcée de la fermeture "
"après délai d'inactivité."
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Échec lors de l'acquisition de stdio."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "Échec du tube : %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "Échec de fork() : %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "Échec de read() : %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Échec lors du démarrage du démon."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Démarrage du démon réussi."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "Échec de read() : %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Pulseaudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Hôte de compilation : %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "CFLAGS de compilation : %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Exécution sur l'hôte : %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
-msgstr ""
+msgstr "%u processeurs trouvés."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "La taille de la page est de %lu octets"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Compilé avec la prise en charge Valgrind : oui"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Compilé avec la prise en charge Valgrind : non"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Exécution en mode valgrind : %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Exécution sur l'hôte : %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Construction optimisée : oui"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Construction optimisée : non"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr ""
+msgstr "NDEBUG défini, tous les messages d'erreur sont désactivés."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr ""
+"FASTPATH défini, seuls les messages d'erreur fastpath ont été désactivés."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr ""
+msgstr "Tous les messages d'erreur sont activés."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Échec lors de l'obtention de l'ID de la machine"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "L'ID de la machine est %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "L'ID de la machine est %s."
+msgstr "L'ID de la session est %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Utilisation du répertoire d'exécution %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Utilisation du répertoire d'état %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Utilisation du répertoire des modules %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Exécution en mode système : %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"Vous exécutez PA dans un mode système. Sachez que vous ne devriez pas faire "
+"cela.\n"
+"Si vous choisissez malgré tout de le faire, vous êtes responsable de tout "
+"dysfonctionnement inattendu.\n"
+"Veuillez lire http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode pour "
+"comprendre pourquoi le mode système est généralement une mauvaise idée."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "Échec de pa_pid_file_create()."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr ""
"De nouvelles horloges à haute résolution sont disponibles ! Bon appétit !"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -496,32 +423,32 @@ msgstr ""
"Eh mec, ton noyau il pue ! La recommandation d'aujourd'hui du patron est "
"d'activer les horloges à haute résolution sur ton Linux."
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "Échec de pa_core_new()."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Échec lors de l'initialisation du démon"
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Démarrage du démon sans aucun module chargé : refus de fonctionner."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "Démarrage du démon effectué."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Fermeture du démon initiée."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Démon terminé."
-#: ../src/daemon/cmdline.c:121
-#, fuzzy, c-format
+#: ../src/daemon/cmdline.c:115
+#, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -609,7 +536,7 @@ msgstr ""
"lancé\n"
" -k --kill Tue un démon en cours d'exécution\n"
" --check Vérifie s'il existe un démon en "
-"cours d'exécution\n"
+"cours d'exécution (ne retourne que le code de sortie)\n"
"\n"
"OPTIONS :\n"
" --system[=BOOL] Exécuter en tant qu'instance "
@@ -648,6 +575,12 @@ msgstr ""
"verbosité\n"
" -v Augmente le niveau de verbosité\n"
" --log-target={auto,syslog,stderr} Indique la cible du journal\n"
+" --log-meta[=BOOL] Inclure la position du code dans les "
+"messages ·du journal\n"
+" --log-time[=BOOL] Inclure la date dans les messages du "
+"journal\n"
+" --log-backtrace=TRAMES Inclure un traçage de la pile dans "
+"les messages du journal\n"
" -p, --dl-search-path=CHEMIN Définit le chemin de recherche pour "
"les objets dynamiques\n"
" partagés (extensions)\n"
@@ -675,15 +608,15 @@ msgstr ""
" -n Ne pas charger les fichiers de "
"scripts par défaut\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -691,55 +624,52 @@ msgstr ""
"--log-level requiert un paramètre de niveau de journal (soit numérique entre "
"0 et 4, soit de débogage : info, notice, warn , error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:302
-#, fuzzy
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "Cible du journal invalide : utilisez « syslog », « stderr » ou « auto »."
-#: ../src/daemon/cmdline.c:333
-#, fuzzy
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr "--realtime requiert un paramètre booléen"
+msgstr "--log-time requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:340
-#, fuzzy
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr "--disallow-exit requiert un paramètre booléen"
+msgstr "--log-meta requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Méthode de rééchantillonnage invalide « %s »."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit requiert un paramètre booléen"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm requiert un paramètre booléen"
@@ -778,360 +708,345 @@ msgstr "Utilisation : %s\n"
msgid "Load Once: %s\n"
msgstr "Chargement unique : %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "AVERTISSEMENT D'OBSOLESCENCE : %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Chemin : %s\n"
# dans les lignes suivantes [%s = nom de fichier: %u = ligne dans celui-ci]
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Cible du journal « %s » invalide."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Niveau du journal « %s » invalide."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Méthode de rééchantillonnage « %s » invalide."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] rlimit « %s » invalide."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit n'est pas pris en charge sur cette plateforme."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Format d'échantillon « %s » invalide."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Taux d'échantillonnage « %s » invalide."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Canaux d'échantillonnage « %s » invalide."
-#: ../src/daemon/daemon-conf.c:353
-#, fuzzy, c-format
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
-msgstr "[%s:%u] Canaux d'échantillonnage « %s » invalide."
+msgstr "[%s:%u] Plan de canaux « %s » invalide."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Nombre de fragments « %s » invalide."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Taille du fragment « %s » invalide."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Niveau de priorité (nice) « %s » invalide."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Taux d'échantillonnage « %s » invalide."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Échec lors de l'ouverture du fichier de configuration : %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr ""
+"Le plan de canaux spécifié par défaut a un nombre de canaux différent du "
+"nombre spécifié par défaut."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Lecture à partir du fichier de configuration : %s ###\n"
-#: ../src/daemon/caps.c:63
-#, fuzzy
-msgid "Dropping root privileges."
-msgstr "Abandon des permissions root."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Limitation des capacités à CAP_SYS_NICE réussie."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Nettoyage des privilèges."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
-msgstr ""
+msgstr "Système de son PulseAudio"
#: ../src/daemon/pulseaudio.desktop.in.h:2
msgid "Start the PulseAudio Sound System"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-#, fuzzy
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Impossible de tuer le démon PulseAudio."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-#, fuzzy
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Nous sommes dans le groupe « %s », permettant une planification à haute "
-"priorité."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
+msgstr "Démarrer le système de son PulseAudio"
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Avant centre"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Avant gauche"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Avant droit"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Arrière centre"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Arrière gauche"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Arrière droit"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Émetteur à basse fréquence"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Avant à gauche du centre"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Avant à droite du centre"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Côté gauche"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Côté droit"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Auxiliaire 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Auxiliaire 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Auxiliaire 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Auxiliaire 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Auxiliaire 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Auxiliaire 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Auxiliaire 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Auxiliaire 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Auxiliaire 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Auxiliaire 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Auxiliaire 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Auxiliaire 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Auxiliaire 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Auxiliaire 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Auxiliaire 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Auxiliaire 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Auxiliaire 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Auxiliaire 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Auxiliaire 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Auxiliaire 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Auxiliaire 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Auxiliaire 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Auxiliaire 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Auxiliaire 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Auxiliaire 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Auxiliaire 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Auxiliaire 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Auxiliaire 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Auxiliaire 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Auxiliaire 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Auxiliaire 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Auxiliaire 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Centre haut"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Avant centre haut"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Avant gauche haut"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Avant droit haut"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Arrière centre haut"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Arrière gauche haut"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Arrière droit haut"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(invalide)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
-msgstr ""
+msgstr "Stéréo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
-msgstr ""
+msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
-msgstr ""
+msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
-msgstr ""
+msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
-msgstr ""
+msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
-msgstr ""
+msgstr "Surround 7.1"
#: ../src/pulse/error.c:43
msgid "OK"
@@ -1223,40 +1138,48 @@ msgstr "Aucune extension de ce type"
#: ../src/pulse/error.c:65
msgid "Obsolete functionality"
-msgstr ""
+msgstr "Fonctionnalité dépréciée"
#: ../src/pulse/error.c:66
msgid "Missing implementation"
-msgstr ""
+msgstr "Implantation manquante"
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr ""
+msgstr "Le client s'est divisé (Client forked)"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Erreur d'entrée/sortie"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Périphérique ou ressource occupé"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
-msgstr ""
+msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
-msgstr ""
+msgstr "%0.1f Gio"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
-msgstr ""
+msgstr "%0.1f Mio"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
-msgstr ""
+msgstr "%0.1f Kio"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
-msgstr ""
+msgstr "%u B"
#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
msgid "XOpenDisplay() failed"
@@ -1266,203 +1189,197 @@ msgstr "Échec de XOpenDisplay()"
msgid "Failed to parse cookie data"
msgstr "Échec lors de l'analyse des données du cookie"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Échec lors de l'ouverture du fichier de configuration « %s » :%s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Aucun cookie chargé. Tentative de connexion sans celui-ci."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork() : %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid() : %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Message reçu pour une extension inconnue « %s »"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "Échec de pa_stream_write() : %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Échec lors du vidage du flux : %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "Échec de pa_stream_peek() : %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Flux de lecture vidé."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Création du flux réussie.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Vidage de la connexion au serveur."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "Échec de pa_stream_get_buffer_attr() : %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain() : %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Mesures du tampon : maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "Échec de pa_stream_write() : %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Mesures du tampon : maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "Échec de pa_stream_begin_write() : %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr ""
-"Utilisation de la spécification d'échantillon « %s », plan des canaux « %s ».\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "Échec de pa_stream_peek() : %s"
-# l'espace manquant entre %s et suspended est voulu
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Connecté au périphérique %s (%u, %ssuspendu).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Création du flux réussie."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Erreur du flux : %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "Échec de pa_stream_get_buffer_attr() : %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Périphérique de flux suspendu %s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Mesures du tampon : maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Périphérique de flux repris %s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Mesures du tampon : maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Flux vide %s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr ""
+"Utilisation de la spécification d'échantillon « %s », plan des canaux « %s »."
-#: ../src/utils/pacat.c:224
+# l'espace manquant entre %s et suspended est voulu
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Flux saturé %s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Connecté au périphérique %s (%u, %ssuspendu)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Flux démarré %s \n"
+msgid "Stream error: %s"
+msgstr "Erreur du flux : %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Flux déplacé vers le périphérique %s (%u, %ssuspendu).%s \n"
+msgid "Stream device suspended.%s"
+msgstr "Périphérique de flux suspendu.%s"
-# suspendu ou non suspendu
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "non "
-
-#: ../src/utils/pacat.c:245
-#, fuzzy, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Flux vide %s \n"
-
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Connection établie.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "Périphérique de flux repris.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "Échec de pa_stream_new() : %s\n"
+msgid "Stream underrun.%s"
+msgstr "Flux vide.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "Échec de pa_stream_connect_playback() : %s\n"
+msgid "Stream overrun.%s"
+msgstr "Flux saturé.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "Échec de pa_stream_connect_record() : %s\n"
+msgid "Stream started.%s"
+msgstr "Flux démarré.%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Échec lors de la connexion : %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Flux déplacé vers le périphérique %s (%u, %ssuspendu).%s"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Échec lors du vidage du flux : %s\n"
+# suspendu ou non suspendu
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "non "
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Flux de lecture vidé.\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Des attributs du tampon de flux ont changé.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Vidage de la connexion au serveur.\n"
+msgid "Connection established.%s"
+msgstr "Connexion établie.%s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF obtenu.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "Échec de pa_stream_new() : %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain() : %s\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "Échec de pa_stream_connect_playback() : %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "read() failed: %s\n"
-msgstr "Échec de read() : %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "Échec de pa_stream_connect_record() : %s"
-#: ../src/utils/pacat.c:438
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "write() failed: %s\n"
-msgstr "Échec de write() : %s\n"
+msgid "Connection failure: %s"
+msgstr "Échec lors de la connexion : %s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF obtenu."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Signal obtenu, fermeture.\n"
+msgid "write() failed: %s"
+msgstr "Échec de write() : %s"
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Signal obtenu, fermeture."
+
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Échec lors de l'obtention de la latence : %s\n"
+msgid "Failed to get latency: %s"
+msgstr "Échec lors de l'obtention de la latence : %s"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Durée : %0.3f s ; Latency : %0.0f µs. \r"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Durée : %0.3f sec. ; Latence : %0.0f µsec."
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:620
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "Échec de pa_stream_update_timing_info() : %s\n"
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "Échec de pa_stream_update_timing_info() : %s"
# downmix = par ex. convertir 5 canaux en 2 canaux
# upmixer = par ex. convertir 2 canaux en 5 canaux
# https://bugzilla.redhat.com/show_bug.cgi?id=460798
-#: ../src/utils/pacat.c:511
-#, c-format
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1488,8 +1405,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1512,6 +1431,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
@@ -1564,8 +1492,16 @@ msgstr ""
"octets.\n"
" --process-time=OCTETS Demande le temps de traitement "
"indiqué par requête en octets.\n"
+" --property=PROPRIÉTÉ=VALEUR Attribut la propriété définie à la "
+"valeur définie.\n"
+" --raw Enregistre/lit les données PCM "
+"brutes.\n"
+" --file-format=FFORMAT Enregistre/lit les données PCM "
+"formatées.\n"
+" --list-file-formats Liste les formats de fichiers "
+"disponibles.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1576,131 +1512,179 @@ msgstr ""
"Compilé avec libpulse %s\n"
"Lié avec libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Plan des canaux invalide « %s »\n"
+msgid "Invalid client name '%s'"
+msgstr "Nom du client invalide « %s »"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Spécification de latence invalide « %s »\n"
+msgid "Invalid stream name '%s'"
+msgstr "Nom du flux invalide « %s »"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Spécification de temps de traitement invalide « %s »\n"
+msgid "Invalid channel map '%s'"
+msgstr "Plan des canaux invalide « %s »"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Spécification d'échantillon invalide\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Spécification de latence invalide « %s »"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr ""
-"Le plan des canaux ne correspond pas à la spécification d'échantillon\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Spécification de temps de traitement invalide « %s »"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Ouverture d'un flux %s avec une spécification d'échantillon « %s ».\n"
+msgid "Invalid property '%s'"
+msgstr "Propriété invalide « %s »"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "enregistrement"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Format de fichier inconnu %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "lecture"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Spécification d'échantillon invalide"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open() : %s\n"
+msgid "open(): %s"
+msgstr "open() : %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2() : %s\n"
+msgid "dup2(): %s"
+msgstr "dup2() : %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Trop de paramètres.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Trop de paramètres."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "Échec de pa_mainloop_new().\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr ""
+"Échec lors de la génération des informations de l'échantillon du fichier."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "Échec de io_new().\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Échec lors de l'ouverture du fichier audio."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "Échec de pa_context_new().\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Avertissement : les spécifications de l'échantillon spécifié seront écrasées "
+"par celles du fichier."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "Échec de pa_context_connect() : %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr ""
+"Échec lors de l'obtention des informations de l'échantillon du fichier."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr ""
+"Avertissement : échec lors de l'obtention des informations du plan des "
+"canaux du fichier."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Le plan des canaux ne correspond pas à la spécification d'échantillon"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr ""
+"Avertissement : Échec lors de l'écriture du plan des canaux dans le fichier."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "Échec de time_new().\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Ouverture d'un flux %s avec une spécification d'échantillon « %s » et un plan "
+"des canaux « %s »."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "enregistrement"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "lecture"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "Échec de pa_mainloop_new()."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "Échec de io_new()."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "Échec de pa_context_new()."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "Échec de pa_mainloop_run().\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "Échec de pa_context_connect() : %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "Échec de pa_context_rttime_new()."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "Échec de pa_mainloop_run()."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork() : %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp() : %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Échec lors de la suspension : %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Échec lors de la reprise : %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr ""
"AVERTISSEMENT : le serveur de son n'est pas local, suspension annulée.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Échec lors de la connexion : %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT reçu, fermeture.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "AVERTISSEMENT : le processus fils a été terminé par le signal %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1719,7 +1703,7 @@ msgstr ""
"connecter\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1730,37 +1714,63 @@ msgstr ""
"Compilé avec libpulse %s\n"
"Lié avec libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "Échec de pa_mainloop_new().\n"
+
+#: ../src/utils/pasuspender.c:288
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Échec lors de l'obtention des statistiques : %s\n"
+msgid "pa_context_new() failed.\n"
+msgstr "Échec de pa_context_new().\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "Échec de pa_mainloop_run().\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Échec lors de l'obtention des statistiques : %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "En cours d'utilisation : %u blocs contenant au total %s octets.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"Alloué pendant l'ensemble de la durée d'exécution : %u blocs contenant au "
"total %s octets.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Taille du cache de l'échantillon : %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Échec lors de l'obtention des informations du serveur : %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Échec lors de l'obtention des informations du serveur : %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
#, fuzzy, c-format
msgid ""
-"User name: %s\n"
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1768,25 +1778,26 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Nom d'utilisateur : %s\n"
"Nom d'hôte : %s\n"
"Nom du serveur : %s\n"
"Version du serveur : %s\n"
"Spécification d'échantillon par défaut : %s\n"
+"Plan de canaux par défaut : %s\n"
"Destination par défaut : %s\n"
"Source par défaut : %s\n"
"Cookie : %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Échec lors de l'obtention des informations sur la destination : %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Échec lors de l'obtention des informations sur la destination : %s"
# demander à Lennart s'il s'agit de monitor of source
-#: ../src/utils/pactl.c:194
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:234
+#, c-format
msgid ""
"Sink #%u\n"
"\tState: %s\n"
@@ -1806,26 +1817,41 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Destination #%u ***\n"
-"Nom : %s\n"
-"Pilote : %s\n"
-"Spécification de l'échantillon : %s\n"
-"Plan des canaux : %s\n"
-"Module propriétaire : %u\n"
-"Volume : %s\n"
-"Moniteur de la source : %s\n"
-"Latence : %0.0f µs, %0.0f µs configurée \n"
-"Drapeaux : %s%s%s%s%s%s\n"
-"Propriétés :\n"
-"%s"
-
-#: ../src/utils/pactl.c:258
-#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Échec lors de l'obtention des informations sur la source : %s\n"
-
-#: ../src/utils/pactl.c:274
-#, fuzzy, c-format
+"Destination #%u\n"
+"\tÉtat : %s\n"
+"\tNom : %s\n"
+"\tDescription : %s\n"
+"\tPilote : %s\n"
+"\tSpécification de l'échantillon : %s\n"
+"\tPlan des canaux : %s\n"
+"\tModule propriétaire : %u\n"
+"\tMuet : %s\n"
+"\tVolume : %s%s%s\n"
+"\t balance %0.2f\n"
+"\tVolume de base : %s%s%s\n"
+"\tMoniteur de la source : %s\n"
+"\tLatence : %0.0f·µs, configurée %0.0f·µs\n"
+"\tDrapeaux : %s%s%s%s%s%s\n"
+"\tPropriétés :\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorts :\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tPort actif : %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Échec lors de l'obtention des informations sur la source : %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
msgid ""
"Source #%u\n"
"\tState: %s\n"
@@ -1845,34 +1871,39 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Source #%u ***\n"
-"Nom : %s\n"
-"Pilote : %s\n"
-"Spécification de l'échantillon : %s\n"
-"Plan des canaux : %s\n"
-"Module propriétaire : %u\n"
-"Volume : %s\n"
-"Moniteur de la destination : %s\n"
-"Latence : %0.0f µs, %0.0f µs configurée \n"
-"Drapeaux : %s%s%s%s%s%s\n"
-"Propriétés :\n"
-"%s"
-
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+"Source #%u\n"
+"\tÉtat : %s\n"
+"\tNom : %s\n"
+"\tDescription : %s\n"
+"\tPilote : %s\n"
+"\tSpécification de l'échantillon : %s\n"
+"\tPlan des canaux : %s\n"
+"\tModule propriétaire : %u\n"
+"\tMuet : %s\n"
+"\tVolume : %s%s%s\n"
+"\t balance %0.2f\n"
+"\tVolume de base : %s%s%s\n"
+"\tMoniteur de la destination : %s\n"
+"\tLatence : %0.0f µs, configurée %0.0f µs\n"
+"\tDrapeaux : %s%s%s%s%s%s\n"
+"\tPropriétés :\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/d"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Échec lors de l'obtention des informations du module : %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Échec lors de l'obtention des informations du module : %s"
-#: ../src/utils/pactl.c:342
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:406
+#, c-format
msgid ""
"Module #%u\n"
"\tName: %s\n"
@@ -1881,19 +1912,20 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Module #%u ***\n"
-"Nom : %s\n"
-"Paramètre : %s\n"
-"Nombre d'utilisations : %s\n"
-"Déchargement automatique : %s\n"
+"Module #%u\n"
+"\tNom : %s\n"
+"\tParamètre : %s\n"
+"\tNombre d'utilisations : %s\n"
+"\tPropriétés : \n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Échec lors de l'obtention des informations du client : %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Échec lors de l'obtention des informations du client : %s"
-#: ../src/utils/pactl.c:379
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:443
+#, c-format
msgid ""
"Client #%u\n"
"\tDriver: %s\n"
@@ -1901,20 +1933,19 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Client #%u ***\n"
-"Pilote : %s\n"
-"Module propriétaire : %s\n"
-"Propriétés :\n"
-"%s"
+"Client #%u\n"
+"\tPilote : %s\n"
+"\tModule propriétaire : %s\n"
+"\tPropriétés :\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:396
-#, fuzzy, c-format
-msgid "Failed to get card information: %s\n"
-msgstr ""
-"Échec lors de l'obtention des informations du chargement automatique : %s\n"
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "Impossible d'obtenir des informations sur la carte : %s"
-#: ../src/utils/pactl.c:414
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:478
+#, c-format
msgid ""
"Card #%u\n"
"\tName: %s\n"
@@ -1923,31 +1954,31 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Client #%u ***\n"
-"Pilote : %s\n"
-"Module propriétaire : %s\n"
-"Propriétés :\n"
-"%s"
+"Carte #%u\n"
+"\tNom : %s\n"
+"\tPilote : %s\n"
+"\tModule propriétaire : %s\n"
+"\tPropriétés :\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
-msgstr ""
+msgstr "\tProfils :\n"
-#: ../src/utils/pactl.c:434
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:498
+#, c-format
msgid "\tActive Profile: %s\n"
-msgstr "Échec du tube : %s"
+msgstr "\tProfil actif : %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
+msgid "Failed to get sink input information: %s"
msgstr ""
-"Échec lors de l'obtention des informations de l'entrée de la destination : %"
-"s\n"
+"Échec lors de l'obtention des informations de l'entrée de la destination : %s"
-#: ../src/utils/pactl.c:464
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:528
+#, c-format
msgid ""
"Sink Input #%u\n"
"\tDriver: %s\n"
@@ -1966,28 +1997,31 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Entrée de la destination #%u ***\n"
-"Pilote : %s\n"
-"Module propriétaire : %s\n"
-"Client : %s\n"
-"Destination : %u\n"
-"Spécification de l'échantillon : %s\n"
-"Plan des canaux : %s\n"
-"Volume : %s\n"
-"Latence du tampon : %0.0f µs\n"
-"Latence de la destination : %0.0f µs\n"
-"Méthode de rééchantillonnage : %s\n"
-"Propriétés :\n"
-"%s"
+"Entrée de la destination #%u\n"
+"\tPilote : %s\n"
+"\tModule propriétaire : %s\n"
+"\tClient : %s\n"
+"\tDestination : %u\n"
+"\tSpécification de l'échantillon : %s\n"
+"\tPlan des canaux : %s\n"
+"\tMuet : %s\n"
+"\tVolume : %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tLatence du tampon : %0.0f µs\n"
+"\tLatence de la destination : %0.0f µs\n"
+"\tMéthode de rééchantillonnage : %s\n"
+"\tPropriétés :\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
+msgid "Failed to get source output information: %s"
msgstr ""
-"Échec lors de l'obtention des informations de la sortie de la source : %s\n"
+"Échec lors de l'obtention des informations de la sortie de la source : %s"
-#: ../src/utils/pactl.c:523
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:587
+#, c-format
msgid ""
"Source Output #%u\n"
"\tDriver: %s\n"
@@ -2002,29 +2036,29 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Source Output #%u ***\n"
-"Pilote : %s\n"
-"Module propriétaire : %s\n"
-"Client : %s\n"
-"Source : %u\n"
-"Spécification de l'échantillon : %s\n"
-"Plan des canaux : %s\n"
-"Latence du tampon : %0.0f µs\n"
-"Latence de la source : %0.0f µs\n"
-"Méthode de rééchantillonnage : %s\n"
-"Propriétés :\n"
-"%s"
+"Sortie de la source #%u\n"
+"\tPilote : %s\n"
+"\tModule propriétaire : %s\n"
+"\tClient : %s\n"
+"\tSource : %u\n"
+"\tSpécification de l'échantillon : %s\n"
+"\tPlan des canaux : %s\n"
+"\tLatence du tampon : %0.0f µs\n"
+"\tLatence de la source : %0.0f µs\n"
+"\tMéthode de rééchantillonnage : %s\n"
+"\tPropriétés :\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Échec lors de l'obtention des informations de l'échantillon : %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Échec lors de l'obtention des informations de l'échantillon : %s"
# Lazy ?
# load-sample-lazy = Create a new entry in the sample cache, but don't load
# the sample immediately. The sample is loaded only when it is first used
-#: ../src/utils/pactl.c:572
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:636
+#, c-format
msgid ""
"Sample #%u\n"
"\tName: %s\n"
@@ -2040,34 +2074,94 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Échantillon #%u ***\n"
-"Nom : %s\n"
-"Volume : %s\n"
-"Spécification de l'échantillon : %s\n"
-"Plan des canaux : %s\n"
-"Durée : %0.1f s\n"
-"Taille : %s\n"
-"Cache retardé : %s\n"
-"Nom de fichier : %s\n"
-"Propriétés :\n"
-"%s"
+"Échantillon #%u\n"
+"\tNom : %s\n"
+"\tSpécification de l'échantillon : %s\n"
+"\tPlan des canaux : %s\n"
+"\tVolume : %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDurée : %0.1f s\n"
+"\tTaille : %s\n"
+"\tCache retardé : %s\n"
+"\tNom de fichier : %s\n"
+"\tPropriétés :\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Échec : %s\n"
+msgid "Failure: %s"
+msgstr "Échec : %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Échec lors de l'envoi de l'échantillon : %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Échec lors de l'envoi de l'échantillon : %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Fin prématurée du fichier"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr "destination"
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr "source"
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+#, fuzzy
+msgid "source-output"
+msgstr "source"
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Serveur invalide"
-#: ../src/utils/pactl.c:653
+#: ../src/utils/pactl.c:787
#, c-format
-msgid "Premature end of file\n"
-msgstr "Fin prématurée du fichier\n"
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT reçu, fermeture."
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:961
#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
@@ -2076,13 +2170,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2104,6 +2207,15 @@ msgstr ""
"%s [options] unload-module ID\n"
"%s [options] suspend-sink [DEST] 1|0\n"
"%s [options] suspend-source [SOURCE] 1|0\n"
+"%s·[options]·set-card-profile·[CARTE]·[PROFIL]·\n"
+"%s [options] set-sink-port DEST PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume DEST VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume ENTREEDEST VOLUME\n"
+"%s [options] set-sink-mute DEST 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute ENTREEDEST 1|0\n"
"\n"
" -h, --help Affiche cette aide\n"
" --version Affiche la version\n"
@@ -2113,7 +2225,7 @@ msgstr ""
" -n, --client-name=NOM Définit le nom de ce client sur le "
"serveur\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2124,80 +2236,114 @@ msgstr ""
"Compilé avec libpulse %s\n"
"Lié avec libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Veuillez indiquer un fichier d'échantillon à charger\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Veuillez indiquer un fichier d'échantillon à charger"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Échec lors de l'ouverture du fichier audio.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Échec lors de l'ouverture du fichier audio."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Vous devez indiquer un nom d'échantillon à lire\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+"Avertissement : Échec lors de l'obtention des spécifications de "
+"l'échantillon du fichier."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Vous devez indiquer un nom d'échantillon à supprimer\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Vous devez indiquer un nom d'échantillon à lire"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Vous devez indiquer un nom d'échantillon à supprimer"
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
msgstr ""
-"Vous devez indiquer un index de sortie de destination et une destination\n"
+"Vous devez indiquer un index d'entrée de destination et une destination"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Vous devez indiquer un index de sortie de source et une source\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Vous devez indiquer un index de sortie de source et une source"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Vous devez indiquer un nom de module et des paramètres.\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Vous devez indiquer un nom de module et des paramètres."
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Vous devez indiquer un index de module\n"
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Vous devez indiquer un index de module"
-#: ../src/utils/pactl.c:972
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"Vous ne pouvez pas indiquer plus d'une destination. Vous devez indiquer au "
-"moins une valeur booléenne.\n"
+"Vous ne pouvez pas indiquer plus d'une destination. Vous devez indiquer une "
+"valeur booléenne."
-#: ../src/utils/pactl.c:985
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"Vous ne pouvez pas indiquer plus d'une source. Vous devez indiquer au moins "
-"une valeur booléenne.\n"
+"Vous ne pouvez pas indiquer plus d'une source. Vous devez indiquer une "
+"valeur booléenne."
-#: ../src/utils/pactl.c:997
-#, fuzzy, c-format
-msgid "You have to specify a card name/index and a profile name\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Vous devez indiquer un nom/un index de carte et un nom de profil"
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Vous devez indiquer un nom/un index de destination et un nom de port"
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Vous devez indiquer un nom/un index de source et un nom de port"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Vous devez indiquer un nom/un index de destination et un volume"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Spécification de volume invalide"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Vous devez indiquer un nom/un index de source et un volume"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Vous devez indiquer un index d'entrée de destination et un volume"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Index invalide d'entrée de la destination"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Vous devez indiquer un nom/un index de destination et un booléen muet"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Vous devez indiquer un nom/un index de source et un booléen muet"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
msgstr ""
-"Vous devez indiquer un index de sortie de destination et une destination\n"
+"Vous devez indiquer un index d'entrée de destination et un booléen muet"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Aucune commande valide indiquée.\n"
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Spécification d'index d'entrée de la destination invalide"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "Échec de pa_context_connect() : %s"
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Aucune commande valide indiquée."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2282,131 +2428,50 @@ msgstr "Échec lors du chargement des données du cookie\n"
msgid "Not yet implemented.\n"
msgstr "Pas encore implémenté.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Aucun démon PulseAudio en cours d'exécution, ou ne s'exécutant pas dans une "
+"session de type démon."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0) : %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect() : %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Impossible de tuer le démon PulseAudio."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Le démon ne répond pas."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select() : %s"
+msgid "poll(): %s"
+msgstr "poll() : %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read() : %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write() : %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Création du flux réussie\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Erreur du flux : %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Connexion établie.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FICHIER]\n"
-"\n"
-" -h, --help Affiche cette aide\n"
-" --version Affiche la version\n"
-"\n"
-" -v, --verbose Active le mode verbeux\n"
-"\n"
-" -s, --server=SERVEUR Le nom du serveur auquel se "
-"connecter\n"
-" -d, --device=PÉRIPHÉRIQUE Le nom de la destination à laquelle "
-"se connecter\n"
-" -n, --client-name=NOM Définit le nom de ce client sur le "
-"serveur\n"
-" --stream-name=NOM Définit le nom de ce flux sur le "
-"serveur\n"
-" --volume=VOLUME Définit le volume initial (linéaire) "
-"entre 0 et 65536\n"
-" --channel-map=PLANDESCANAUX Définit le plan des canaux à "
-"utiliser\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Compilé avec libpulse %s\n"
-"Lié avec libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Plan des canaux invalide\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Échec lors de l'ouverture du fichier « %s »\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Le plan des canaux ne correspond pas au fichier.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Utilisation de la spécification de l'échantillon « %s »\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Impossible d'accèder au verrou autonome."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2416,8 +2481,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA nous a réveillé pour écrire de nouvelles données à partir du "
+"périphérique, mais il n'y avait en fait rien à écrire !\n"
+"Il s'agit très probablement d'un bogue dans le pilote ALSA « %s ». Veuillez "
+"rapporter ce problème aux développeurs d'ALSA.\n"
+"Nous avons été réveillés avec POLLOUT actif, cependant un snd_pcm_avail() "
+"ultérieur a retourné 0 ou une autre valeur < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2427,40 +2498,489 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA nous a réveillé pour lire de nouvelles données à partir du "
+"périphérique, mais il n'y avait en fait rien à lire !\n"
+"Il s'agit très probablement d'un bogue dans le pilote ALSA « %s ». Veuillez "
+"rapporter ce problème aux développeurs d'ALSA.\n"
+"Nous avons été réveillés avec POLLIN actif, cependant un snd_pcm_avail() "
+"ultérieur a retourné 0 ou une autre valeur < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
-msgstr ""
+msgstr "Éteint"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr ""
+msgstr "Lecture haute fidélité (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Capture haute fidélité (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Telephonie en duplex (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
+msgstr "Serveur de son PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Périphériques de sortie"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Périphériques d'entrée"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Audio sur @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Entrée"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Entrée de la station d'accueil"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Microphone de la station d'accueil"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Entrée-ligne"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Microphone"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Microphone externe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Microphone interne"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Vidéo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Contrôle automatique du gain"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Pas de contrôle automatique du gain"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Pas de boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Amplificateur"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Pas d'amplificateur"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Pas de boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
msgstr ""
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Casques analogiques"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Entrée analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Microphone analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Entrée-ligne analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Radio analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Vidéo analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Sortie analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Casques analogiques"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Sortie analogique (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Sortie mono analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
#, fuzzy
+msgid "Analog Speakers"
+msgstr "Stéréo analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Mono analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Stéréo analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Surround analogique 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Surround analogique 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Surround analogique 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Surround analogique 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Surround analogique 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Surround analogique 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Surround analogique 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Surround analogique 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Surround analogique 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Surround analogique 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Surround analogique 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Stéréo numérique (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Surround numérique 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Surround numérique 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Surround numérique 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Stéréo numérique (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Duplex Mono analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Duplex stéréo analogique"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Duplex stéréo numérique (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Émetteur à basse fréquence"
+
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Plan des canaux invalide « %s »\n"
+
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr "Échec lors de l'obtention des informations de l'échantillon : %s\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select() : %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "Impossible de se connecter au bus système : %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "Impossible d'obtenir le programme appelant à partir du PID : %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "Impossible de définir un UID sur l'objet appelant."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "Échec lors de l'obtention de la session CK."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "Impossible de définir l'UID sur l'objet de session."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "Impossible d'allouer PolKitAction."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "Impossible de définir action_id."
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "Impossible d'allouer PolKitContext."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "Impossible d'initialiser PolKitContext : %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "Impossible de déterminer si le programme appelant est autorisé : %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "Impossible d'obtenir l'authentification : %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit a renvoyé « %s »"
+
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Ordonnancement haute priorité (niveau Unix « nice » négatif) pour le démon "
+#~ "PulseAudio"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Ordonnancement en temps réel pour le démon PulseAudio"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "La politique du système empêche PulseAudio d'acquérir un ordonnancement "
+#~ "haute priorité"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "La politique du système empêche PulseAudio d'acquérir un ordonnancement "
+#~ "en temps réel"
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "Échec de read() : %s\n"
+
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "Échec de pa_context_connect() : %s"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr ""
+#~ "Nous sommes dans le groupe « %s », permettant une planification à haute "
+#~ "priorité."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr ""
+#~ "Nous sommes dans le groupe « %s », permettant un ordonnancement en temps "
+#~ "réel."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr ""
+#~ "PolicyKit a accordé l'acquisition des permissions de haute priorité."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "PolicyKit a refusé l'acquisition des permissions de haute priorité."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "PolicyKit a accordé l'acquisition des permissions de temps réel."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "PolicyKit a refusé l'acquisition des permissions de temps réel."
+
+#~ msgid ""
+#~ "Called SUID root and real-time and/or high-priority scheduling was "
+#~ "requested in the configuration. However, we lack the necessary "
+#~ "privileges:\n"
+#~ "We are not in group '%s', PolicyKit refuse to grant us the requested "
+#~ "privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
+#~ "limits.\n"
+#~ "For enabling real-time/high-priority scheduling please acquire the "
+#~ "appropriate PolicyKit privileges, or become a member of '%s', or increase "
+#~ "the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+#~ msgstr ""
+#~ "Le SUID root et l'ordonnancement en temps réel et/ou haute priorité ont "
+#~ "été spécifiés dans la configuration. Cependant, il nous manque les "
+#~ "privilèges nécessaires :\n"
+#~ "Nous ne sommes pas dans le groupe « %s », PolicyKit refuse de nous "
+#~ "accorder les privilèges demandés et nous devons augmenter les limites de "
+#~ "ressources RLIMIT_NICE/RLIMIT_RTPRIO.\n"
+#~ "Pour activer l'ordonnancement en temps réel/haute priorité, veuillez "
+#~ "acquérir les privilèges PolicyKit apropriés, ou devenir membre de « %s », "
+#~ "ou augmenter les limites de ressources RLIMIT_NICE/RLIMIT_RTPRIO pour cet "
+#~ "utilisateur."
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "La planification à haute priorité est activée dans la configuration mais "
+#~ "n'est pas permise par la politique."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "Augmentation de RLIMIT_RTPRIO réussie"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO a échoué : %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "Abandon de CAP_NICE"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "La planification en temps réel est activée mais n'est pas permise par la "
+#~ "politique."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "Limitation des capacités à CAP_SYS_NICE réussie."
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "Échec de time_new().\n"
+
+#~ msgid "Output %s + Input %s"
+#~ msgstr "Sortie %s + Entrée %s"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Création du flux réussie\n"
+
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "Erreur du flux : %s\n"
+
+#~ msgid "Connection established.\n"
+#~ msgstr "Connexion établie.\n"
+
+#~ msgid ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Show this help\n"
+#~ " --version Show version\n"
+#~ "\n"
+#~ " -v, --verbose Enable verbose operation\n"
+#~ "\n"
+#~ " -s, --server=SERVER The name of the server to connect "
+#~ "to\n"
+#~ " -d, --device=DEVICE The name of the sink to connect "
+#~ "to\n"
+#~ " -n, --client-name=NAME How to call this client on the "
+#~ "server\n"
+#~ " --stream-name=NAME How to call this stream on the "
+#~ "server\n"
+#~ " --volume=VOLUME Specify the initial (linear) "
+#~ "volume in range 0...65536\n"
+#~ " --channel-map=CHANNELMAP Set the channel map to the use\n"
+#~ msgstr ""
+#~ "%s [options] [FICHIER]\n"
+#~ "\n"
+#~ " -h, --help Affiche cette aide\n"
+#~ " --version Affiche la version\n"
+#~ "\n"
+#~ " -v, --verbose Active le mode verbeux\n"
+#~ "\n"
+#~ " -s, --server=SERVEUR Le nom du serveur auquel se "
+#~ "connecter\n"
+#~ " -d, --device=PÉRIPHÉRIQUE Le nom de la destination à "
+#~ "laquelle se connecter\n"
+#~ " -n, --client-name=NOM Définit le nom de ce client sur "
+#~ "le serveur\n"
+#~ " --stream-name=NOM Définit le nom de ce flux sur le "
+#~ "serveur\n"
+#~ " --volume=VOLUME Définit le volume initial "
+#~ "(linéaire) entre 0 et 65536\n"
+#~ " --channel-map=PLANDESCANAUX Définit le plan des canaux à "
+#~ "utiliser\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Compilé avec libpulse %s\n"
+#~ "Lié avec libpulse %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Plan des canaux invalide\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Échec lors de l'ouverture du fichier « %s »\n"
+
+#~ msgid "Channel map doesn't match file.\n"
+#~ msgstr "Le plan des canaux ne correspond pas au fichier.\n"
+
+#~ msgid "Using sample spec '%s'\n"
+#~ msgstr "Utilisation de la spécification de l'échantillon « %s »\n"
+
#~ msgid ""
#~ "Called SUID root and real-time and/or high-priority scheduling was "
#~ "requested in the configuration. However, we lack the necessary "
@@ -2472,7 +2992,6 @@ msgstr ""
#~ "permissions nécessaires :\n"
#~ "nous ne somme pas dans le groupe "
-#, fuzzy
#~ msgid "--log-time boolean argument"
#~ msgstr "--disallow-exit requiert un paramètre booléen"
@@ -2503,12 +3022,6 @@ msgstr ""
#~ "Module : %s\n"
#~ "Paramètre : %s\n"
-#~ msgid "sink"
-#~ msgstr "destination"
-
-#~ msgid "source"
-#~ msgstr "source"
-
#~ msgid ""
#~ "' and PolicyKit refuse to grant us priviliges. Dropping SUID again.\n"
#~ "For enabling real-time scheduling please acquire the appropriate "
diff --git a/po/gu.po b/po/gu.po
index 2a0906f2..1d0f38df 100644
--- a/po/gu.po
+++ b/po/gu.po
@@ -1,14 +1,14 @@
-# translation of pulseaudio.po to Gujarati
+# translation of PulseAudio.po to Gujarati
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Sweta Kothari <swkothar@redhat.com>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio\n"
+"Project-Id-Version: PulseAudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-07 14:27+0530\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-07 17:22+0530\n"
"Last-Translator: Sweta Kothari <swkothar@redhat.com>\n"
"Language-Team: Gujarati\n"
"MIME-Version: 1.0\n"
@@ -17,51 +17,12 @@ msgstr ""
"X-Generator: KBabel 1.11.4\n"
"Plural-Forms: nplurals=2; plural=(n!=1);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "àªàª¨àª¾àª²à«‹àª— મોનો"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "àªàª¨àª¾àª²à«‹àª— સà«àªŸà«‡àª°àª¿àª“"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "ડિજિટલ સà«àªŸà«‡àª°àª¿àª“ (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "ડિજિટલ સà«àªŸà«‡àª°àª¿àª“ (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "àªàª¨àª¾àª²à«‹àª— સરાઉનà«àª¡ 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "àªàª¨àª¾àª²à«‹àª— સરાઉનà«àª¡ 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "àªàª¨àª¾àª²à«‹àª— સરાઉનà«àª¡ 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "àªàª¨àª¾àª²à«‹àª— સરાઉનà«àª¡ 4.2"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "àªàª¨àª¾àª²à«‹àª— સરાઉનà«àª¡ 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "àªàª¨àª¾àª²à«‹àª— સરાઉનà«àª¡ 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "àªàª¨àª¾àª²à«‹àª— સરાઉનà«àª¡ 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -73,7 +34,7 @@ msgstr ""
"ALSA ડà«àª°àª¾àª‡àªµàª° '%s' માં મોટેભાગે આ ભૂલ જેવૠછે. ALSA ડેવલà«àªªàª°à«‹àª®àª¾àª‚ આ સમસà«àª¯àª¾àª¨à«‡ મહેરબાની કરીને "
"અહેવાલ કરો."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -86,7 +47,7 @@ msgstr ""
"ALSA ડà«àª°àª¾àª‡àªµàª° '%s' માં મોટેભાગે આ ભૂલ જેવૠછે. ALSA ડેવલà«àªªàª°à«‹àª®àª¾àª‚ આ સમસà«àª¯àª¾àª¨à«‡ મહેરબાની કરીને "
"અહેવાલ કરો."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -99,11 +60,45 @@ msgstr ""
"ALSA ડà«àª°àª¾àª‡àªµàª° '%s' માં મોટેભાગે આ ભૂલ જેવૠછે. ALSA ડેવલà«àªªàª°à«‹àª®àª¾àª‚ આ સમસà«àª¯àª¾àª¨à«‡ મહેરબાની કરીને "
"અહેવાલ કરો."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "હંમેશા ઓછામાં ઓછૠàªàª• સિંક લોડ થયેલ રાખો જો તે શૂનà«àª¯ હોય તો પણ"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ડમી આઉટપà«àªŸ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "વરà«àªšà«àª¯à«àª…લ LADSPA સિંક"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "કà«àª²à«‹àª• થયેલ NULL સિંક"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "શૂનà«àª¯ આઉટપà«àªŸ"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "આંતરિક ઓડિયો"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "મોડેમ"
@@ -119,377 +114,293 @@ msgstr "નવા dl લોડરને ફાળવવાનà«àª‚ નિષà«
msgid "Failed to add bind-now-loader."
msgstr "bind-now-loader ને ઉમેરવાનà«àª‚ નિષà«àª«àª³."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "સિસà«àªŸàª® બસને જોડી શકાતૠનથી: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PID માંથી કોલરને મેળવી શકાતૠનથી: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "કોલર ઓબà«àªœà«‡àª•à«àªŸ પર UID ને સà«àª¯à«‹àªœàª¿àª¤ કરી શકાતૠનથી."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK સતà«àª°àª¨à«‡ મેળવવામાં નિષà«àª«àª³."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "સતà«àª° ઓબà«àªœà«‡àª•à«àªŸ પર UID ને સà«àª¯à«‹àªœàª¿àª¤ કરી શકાતૠનથી."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitAction ને ફાળવી શકાતી નથી."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "action_id ને સà«àª¯à«‹àªœàª¿àª¤ કરી શકાતૠનથી"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext ને ફાળવી શકાતી નથી."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContext નà«àª‚ પà«àª°àª¾àª°àª‚ભ કરી શકાતૠનથી: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "નકà«àª•à«€ કરી શકાયૠનહિં કà«àª¯àª¾àª‚તો કોલર ઠસતà«àª¤àª¾àª§àª¿àª•રણ થયેલ છે: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "auth મેળવા શકાતૠનથી: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "'%s' સાથે PolicyKit ઠપà«àª°àª¤à«àª¯à«àª¤à«àª¤àª° આપેલ છે"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "સંકેત %s મળà«àª¯à«."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "બહાર નીકળી રહà«àª¯àª¾ છે."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "વપરાશકરà«àª¤àª¾ '%s' ને શોધવામાં નિષà«àª«àª³."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "જૂથ '%s' ને શોધવામાં નિષà«àª«àª³."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "વપરાશકરà«àª¤àª¾ '%s' (UID %lu) અને જૂથ '%s' (GID %lu) શોધાયà«."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "વપરાશકરà«àª¤àª¾ '%s' અને જૂથ '%s' ની GID બંધબેસતૠનથી."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "વપરાશકરà«àª¤àª¾àª“ '%s' ની ઘર ડિરેકà«àªŸàª°à«€ '%s' નથી, અવગણી રહà«àª¯àª¾ છે."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s' ને બનાવવામાં નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "જૂથ યાદીને બદલવામાં નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID ને બદલવામાં નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID ને બદલવામાં નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "સફળતાપૂરà«àªµàª• છોડી દીધેલ રà«àªŸ અધિકારો."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "આ પà«àª²à«‡àªŸàª«à«‹àª°à«àª® પર બિનઆધારભૂત સિસà«àªŸàª® વિશાળ સà«àª¥àª¿àª¤àª¿."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "આદેશ વાકà«àª¯àª¨à«‡ પદચà«àª›à«‡àª¦àª¨ કરવામાં નિષà«àª«àª³."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "આપણે જૂથ '%s' માં છીàª, high-priority ગોઠવવાની પરવાનગી આપી રહà«àª¯àª¾ છે."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "આપણે જૂથ '%s' માં છીàª, સાચા સમયે ગોઠવવાની પરવાનગી આપી રહà«àª¯àª¾ છે."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit આપણને acquire-high-priority અધિકારની મંજૂરી આપે છે."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit ઠacquire-high-priority અધિકારને ફરીથી શરૂ કરે છે."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit ઠacquire-real-time અધિકારની મંજૂરી આપે છે."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit ઠacquire-real-time અધિકારને ફરી શરૂ કરે છે."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"કહેવાતી SUID અને real-time અને/અથવા high-priority ગોઠવણી રૂપરેખાંકનમાં સૂચવેલ હતી. "
-"છતાંપણ, આપણને જરૂરી અધિકારો ઓછા પડà«àª¯àª¾:\n"
-"આપણે જૂથ '%s' માં નથી, PolicyKit ઠસૂચિત અધિકારોને આપણને મંજૂરી આપવા માટે માનà«àª¯ કરતૠ"
-"નથી અને આપણે RLIMIT_NICE/RLIMIT_RTPRIO સà«àª¤à«àª°à«‹àª¤ મરà«àª¯àª¾àª¦àª¾àª“ને વધારતા નથી.\n"
-"real-time/high-priority ગોઠવણીને સકà«àª°àª¿àª¯ કરવા માટે મહેરબાની કરીને અનૂકà«àª³ PolicyKit "
-"અધિકારોને મેળવો, અથવા '%s' નાં સભà«àª¯ બનો, અથવા આ વપરાશકરà«àª¤àª¾ માટે RLIMIT_NICE/"
-"RLIMIT_RTPRIO સà«àª¤à«àª°à«‹àª¤ મરà«àª¯àª¾àª¦àª¾àª“ને વધારો."
-
-#: ../src/daemon/main.c:581
+#: ../src/daemon/main.c:535
msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"High-priority ગોઠવવાનà«àª‚ રૂપરેખાંકનમાં સકà«àª°àª¿àª¯ થયેલ છે પરંતૠપોલિસી દà«àª¦àª¾àª°àª¾ પરવાનગી આપેલ નથી."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "સફળતાપૂરà«àªµàª• વધારેલ RLIMIT_RTPRIO"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "CAP_NICE ને છોડી રહà«àª¯àª¾ છે"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Real-time ગોઠવવાનà«àª‚ ઠરૂપરેખાંકનમાં સકà«àª°àª¿àª¯ થયેલ છે પરંતૠપોલિસી દà«àª¦àª¾àª°àª¾ પરવાનગી આપેલ નથી."
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "ડિમન ચાલી રહà«àª¯à« નથી"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "PID %u તરીકે ડિમન ચાલી રહà«àª¯à« છે"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "ડિમનને મારવાનà«àª‚ નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr ""
"આ પà«àª°àª•à«àª°àª¿àª¯àª¾àª¨à«‡ રà«àªŸ તરીકે ચલાવવા માટે વિચાર થયેલ નથી (નહિં તો --system ઠસà«àªªàª·à«àªŸ થયેલ છે)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "રà«àªŸ અધિકારો જરૂરી છે."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start ઠસિસà«àªŸàª® ઉદાહરણો માટે આધારભૂત નથી."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "સિસà«àªŸàª® સà«àª¥àª¿àª¤àª¿àª®àª¾àª‚ ચાલી રહà«àª¯à« છે, પરંતૠ--disallow-exit સà«àª¯à«‹àªœàª¿àª¤ નથી!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "સિસà«àªŸàª® સà«àª¥àª¿àª¤àª¿àª®àª¾àª‚ ચાલી રહà«àª¯à« છે, પરંતૠ--disallow-module-loading ઠસà«àª¯à«‹àªœàª¿àª¤ નથી!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "સિસà«àªŸàª® સà«àª¥àª¿àª¤àª¿àª®àª¾àª‚ ચાલી રહà«àª¯à« છે, SHM સà«àª¥àª¿àª¤àª¿àª¨à«‡ દબાણપૂરà«àªµàª• નિષà«àª•à«àª°àª¿àª¯ કરી રહà«àª¯àª¾ છે!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"સિસà«àªŸàª® સà«àª¥àª¿àª¤àª¿àª®àª¾àª‚ ચાલી રહà«àª¯à« છે, બહાર નીકળવનાં નિષà«àª•ારà«àª¯ સમયને દબાણપૂરà«àªµàª• નિષà«àª•à«àª°àª¿àª¯ કરી "
"રહà«àª¯àª¾ છે!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio ને મેળવવામાં નિષà«àª«àª³."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "પાઇપ નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() નિષà«àª«àª³: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "ડિમન શરૂઆત નિષà«àª«àª³."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "ડિમન શરૂઆત કરવૠસફળ છે."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() નિષà«àª«àª³: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "આ PulseAudio %s છે"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "કમà«àªªàª¾àª‡àª²à«‡àª¶àª¨ યજમાન: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "કમà«àªªàª¾àª‡àª²à«‡àª¶àª¨ CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "યજમાન પર ચાલી રહà«àª¯à« છે: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPUs શોધાયà«."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "પાનાંનૠમાપ %lu બાઇટો છે"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Valgrind આધાર સાથે કમà«àªªàª¾àª‡àª² થયેલ છે: હા"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Valgrind આધાર સાથે કમà«àªªàª¾àª‡àª² થયેલ છે: ના"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind સà«àª¥àª¿àª¤àª¿àª®àª¾àª‚ ચાલી રહà«àª¯à« છે: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "યજમાન પર ચાલી રહà«àª¯à« છે: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "શà«àª°à«‡àª·à«àªŸ થયેલ બિલà«àª¡: હા"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "શà«àª°à«‡àª·à«àªŸ થયેલ બિલà«àª¡: ના"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG વà«àª¯àª¾àª–à«àª¯àª¾àª¯àª¿àª¤ થયેલ છે, બધા હકો નિષà«àª•à«àª°àª¿àª¯ થયેલ છે."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH વà«àª¯àª¾àª–à«àª¯àª¾àª¯àª¿àª¤ થયેલ છે, ફકà«àª¤ àªàª¡àªªà«€ પાથનાં હકો નિષà«àª•à«àª°àª¿àª¯ થયેલ છે."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "બધા હકો સકà«àª°àª¿àª¯ થયેલ છે."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "મશીન ID ને મેળવવામાં નિષà«àª«àª³"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "મશીન ID %s છે."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "મશીન ID %s છે."
+msgstr "સતà«àª° ID %s છે."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "રનટાઇમ ડિરેકà«àªŸàª°à«€ %s ને વાપરી રહà«àª¯àª¾ છે."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "સà«àª¥àª¿àª¤àª¿ ડિરેકà«àªŸàª°à«€ %s ને વાપરી રહà«àª¯àª¾ છે."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "ઇોડà«àª¯à«àª²à«‹àª® ડિરેકà«àªŸàª°à«€ %s ને વાપરી રહà«àª¯àª¾ છે."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "સિસà«àªŸàª® સà«àª¥àª¿àª¤àª¿àª®àª¾àª‚ ચાલી રહà«àª¯à« છે: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"બરાબર, તેથી તમે સિસà«àªŸàª® સà«àª¥àª¿àª¤àª¿àª®àª¾àª‚ PA ચલાવી રહà«àª¯àª¾ છો. મહેરબાની કરીને નોંધો કે જે તમારે "
+"મોટેભાગે કરવૠજોઇઠનહિં.\n"
+"જો તમે તેનાં વગર કરે તો પછી તે તમારી ભૂલ થે જો ઇચà«àª›àª¿àª¤ રીતે તે કામ કરતૠન હોય તો.\n"
+"શા માટે સિસà«àªŸàª® સà«àª¥àª¿àª¤àª¿ સામાનà«àª¯ રીતે ખરાબ વિચાર છે તે માટે વિગતવાર જાણકારી માટે મહેરબાની "
+"કરીને http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode આને વાંચો."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() નિષà«àª«àª³."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "તાજૠhigh-resolution ટાઇમરો ઉપલà«àª¬àª§ છે! બોન àªàªªà«‡àªŸàª¾àª‡àªŸ!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -497,31 +408,31 @@ msgstr ""
"મિતà«àª°, તમારૠકરà«àª¨àª²àª®àª¾àª‚ ગડબડ છે! રસોઇયાનà«àª‚ આજે ભલામણ ઠસકà«àª°àª¿àª¯ થયેલ high-resolution "
"ટાઇમરો સાથે Linux નà«àª‚ છે!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() નિષà«àª«àª³."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "ડિમનને શરૂ કરવામાં નિષà«àª«àª³."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "કોઇપણ લોડ થયેલ મોડà«àª¯à«àª²à«‹ વગર ડિમનને શરૂ કરો, કામ કરવા માટે ફરી શરૂ કરી રહà«àª¯àª¾ છે."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "ડિમન પારંભ કરવાનà«àª‚ સમાપà«àª¤ છે."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "ડિમનને બંધ કરવાનà«àª‚ પà«àª°àª¾àª°àª‚ભ થયેલ છે."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "ડિમનનો અંત આવેલ છે."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -663,15 +574,15 @@ msgstr ""
"\n"
" -n મૂળભૂત સà«àª•à«àª°àª¿àªªà«àªŸ ફાઇલને લોડ કરો નહિં\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -679,52 +590,52 @@ msgstr ""
"--log-level ઠલોગ સà«àª¤àª° દલીલની ઇચà«àª›àª¾ રાખે છે (કà«àª¯àª¾àª‚તો સીમા 0..4 માં પૂરà«àª£àª¸àª‚ખà«àª¯àª¾ છે અથવા "
"ડિબગ, જાણકારી, સૂચના, ચેતવણી, ભૂલ નà«àª‚ àªàª•)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "અયોગà«àª¯ લોગ લકà«àª·à«àª¯: કà«àª¯àª¾àª‚તો 'syslog', 'stderr' અથવા 'auto' ને વાપરો."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "અયોગà«àª¯ resample પદà«àª¦àª¤àª¿ '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm ઠબà«àª²àª¿àª¯àª¨ દલીલની ઇચà«àª›àª¾ રાખે છે"
@@ -763,95 +674,101 @@ msgstr "વપરાશ: %s\n"
msgid "Load Once: %s\n"
msgstr "àªàª•વાર લોડ કરો: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "પાથ: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] અયોગà«àª¯ લોગ લકà«àª·à«àª¯ '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] અયોગà«àª¯ લોગ સà«àª¤àª° '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] અયોગà«àª¯ resample પદà«àª¦àª¤àª¿ '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] અયોગà«àª¯ rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit ઠઆ પà«àª²à«‡àªŸàª«à«‹àª°à«àª® પર આધારભૂત નથી."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] અયોગà«àª¯ નમૂના બંધારણ '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] અયોગà«àª¯ નમૂના દર '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] અયોગà«àª¯ નમૂના ચેનલો '%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] અયોગà«àª¯ ચેનલ મેપ '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] અયોગà«àª¯ ફà«àª°à«‡àª—મેનà«àªŸà«‹àª¨àª¾àª‚ નંબર '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] અયોગà«àª¯ ફà«àª°à«‡àª—મેનà«àªŸ માપ '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] અયોગà«àª¯ સારૠસà«àª¤àª° '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] અયોગà«àª¯ નમૂના દર '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "રૂપરેખાંકન ફાઇલને ખોલવાનà«àª‚ નિષà«àª«àª³: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr ""
"સà«àªªàª·à«àªŸ થયેલ મૂળભૂત ચેનલ મેપ પાસે સà«àªªàª·à«àªŸ થયેલ ચેનલોની મૂળભૂત સંખà«àª¯àª¾ કરતા વિવિધ ચેનલોની સંખà«àª¯àª¾ છે."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### રૂપરેખાંકન ફાઇલમાંથી વાંચો: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "રà«àªŸ અધિકારોને છોડી રહà«àª¯àª¾ છે."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "CAP_SYS_NICE માં સફળતાપૂરà«àªµàª• મરà«àª¯àª¾àª¦àª¿àª¤ કà«àª·àª®àª¤àª¾àª“."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "અધિકારોને છોડી રહà«àª¯àª¾ છે."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -861,256 +778,237 @@ msgstr "PulseAudio સાઉનà«àª¡ સિસà«àªŸàª®"
msgid "Start the PulseAudio Sound System"
msgstr "PulseAudio સાઉનà«àª¡ સિસà«àªŸàª®àª¨à«‡ શરૂ કરો"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "PulseAudio ડિમન માટે High-priority ગોઠવણી (નકારાતà«àª®àª• Unix સારૠસà«àª¤àª°)"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio ડિમન માટે Real-time ગોઠવણી"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"high-priority ગોઠવણીને પà«àª°àª¾àªªà«àª¤ કરવા માંથી સિસà«àªŸàª® પોલિસી PulseAudio ને અટકાવે છે."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr "real-time ગોઠવણી પà«àª°àª¾àªªà«àª¤ કરવા માંથી સિસà«àªŸàª® પોલિસી ઠPulseAudio ને અટકાવે છે."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "મોનો"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "આગળનà«àª‚ કેનà«àª¦à«àª°"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "આગળ ડાબે"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "આગળ જમણે"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "રિઅર કેનà«àª¦à«àª°"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "રિઅર ડાબે"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "રિઅર જમણે"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Low Frequency Emmiter"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "આગળ કેનà«àª¦à«àª°àª¨à«€ ડાબે"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "આગળ કેનà«àª¦à«àª°àª¨à«€ જમણે"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "ડાબી બાજà«"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "જમણી બાજà«"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "ઑગà«àªàª¿àª²àª¿àª…રિ 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "ઊંચે કેનà«àª¦à«àª°"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "ઊંચે આગળ કેનà«àª¦à«àª°"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "ઊંચે આગળ ડાબે"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "ઊંચે આગળ જમણે"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "ઊંચે રિઅર કેનà«àª¦à«àª°"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "ઉપર રિઅર ડાબે"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "ઉપર રિઅર જમણે"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(અયોગà«àª¯)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "સà«àªŸà«‡àª°àª¿àª“"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "સરાઉનà«àª¡ 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "સરાઉનà«àª¡ 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "સરાઉનà«àª¡ 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "સરાઉનà«àª¡ 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "સરાઉનà«àª¡ 7.1"
@@ -1214,27 +1112,35 @@ msgstr "ગà«àª® થયેલ અમલીકરણ"
msgid "Client forked"
msgstr "કà«àª²àª¾àª‡àª¨à«àªŸàª®àª¾àª‚ ફાટા પડેલ છે"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "ઇનપà«àªŸ/આઉટપà«àªŸ ભૂલ"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "ઉપકરણ અથવા સà«àª¤à«àª°à«‹àª¤ વà«àª¯àª¸à«àª¤"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1247,197 +1153,191 @@ msgstr "XOpenDisplay() નિષà«àª«àª³"
msgid "Failed to parse cookie data"
msgstr "કà«àª•ીની માહિતીને પદચà«àª›à«‡àª¦àª¨ કરવામાં નિષà«àª«àª³"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "રૂપરેખાંકન ફાઇલ '%s' ને ખોલવામાં નિષà«àª«àª³: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "કà«àª•à«€ લોડ થયેલ નથી. તેનાં વગર જોડવાનો પà«àª°àª¯àª¤à«àª¨ કરી રહà«àª¯àª¾ છે."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "અજà«àªžàª¾àª¤ àªàª•à«àª¸àªŸà«‡àª¨à«àª¶àª¨ '%s' માટે મળેલ સંદેશ"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() નિષà«àª«àª³: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "સà«àªŸà«àª°à«€àª®àª¨à«‡ નિકાલ કરવામાં નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() નિષà«àª«àª³: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "પà«àª²à«‡àª¬à«‡àª• સà«àªŸà«àª°à«€àª® ને નિકાલ કરેલ છે."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "સà«àªŸà«àª°à«€àª® સફળતાપૂરà«àªµàª• બનાવેલ છે.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "સરà«àªµàª°àª®àª¾àª‚ જોડાણને નિકાલ કરી રહà«àª¯àª¾ છે."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() નિષà«àª«àª³: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "બફર મેટà«àª°àª¿àª•à«àª¸: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "બફર મેટà«àª°àª¿àª•à«àª¸: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "નમૂનો spec '%s' ને વાપરી રહà«àª¯àª¾ છે, ચેનલ મેપ '%s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "ઉપકરણ %s (%u, %ssuspended) સાથે જોડાયેલ છે.\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "સà«àªŸà«àª°à«€àª® સફળતાપૂરà«àªµàª• બનાવેલ છે."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "સà«àªŸà«àª°à«€àª® ભૂલ: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "સà«àªŸà«àª°à«€àª® ઉપકરણ ને થોડા સમય માટે બંધ રાખેલ છે.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "બફર મેટà«àª°àª¿àª•à«àª¸: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "સà«àªŸà«àª°à«€àª® ઉપકરણને ફરી શરૂ કરેલ છે.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "બફર મેટà«àª°àª¿àª•à«àª¸: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "સà«àªŸà«àª°à«€àª® ચલાવવા હેઠળ છે.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "નમૂનો spec '%s' ને વાપરી રહà«àª¯àª¾ છે, ચેનલ મેપ '%s'."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "સà«àªŸà«àª°à«€àª® ઉપર ચાલે છે.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "ઉપકરણ %s (%u, %ssuspended) સાથે જોડાયેલ છે."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "સà«àªŸà«àª°à«€àª® શરૂ થયેલ છે.%s \n"
+msgid "Stream error: %s"
+msgstr "સà«àªŸà«àª°à«€àª® ભૂલ: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "સà«àªŸà«àª°à«€àª® ઠઉપકરણ %s (%u, %ssuspended) માં ખસેડેલ છે.%s \n"
+msgid "Stream device suspended.%s"
+msgstr "સà«àªŸà«àª°à«€àª® ઉપકરણ ને થોડા સમય માટે બંધ રાખેલ છે.%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "નથી "
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "સà«àªŸà«àª°à«€àª® બફર ગà«àª£àª§àª°à«àª®à«‹ બદલાયેલ છે.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "સà«àªŸà«àª°à«€àª® ઉપકરણને ફરી શરૂ કરેલ છે.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "જોડાણ સà«àª¥àª¾àªªàª¿àª¤ થયેલ છે.%s \n"
+msgid "Stream underrun.%s"
+msgstr "સà«àªŸà«àª°à«€àª® ચલાવવા હેઠળ છે.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() નિષà«àª«àª³: %s\n"
+msgid "Stream overrun.%s"
+msgstr "સà«àªŸà«àª°à«€àª® ઉપર ચાલે છે.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() નિષà«àª«àª³: %s\n"
+msgid "Stream started.%s"
+msgstr "સà«àªŸà«àª°à«€àª® શરૂ થયેલ છે.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() નિષà«àª«àª³: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "સà«àªŸà«àª°à«€àª® ઠઉપકરણ %s (%u, %ssuspended) માં ખસેડેલ છે.%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "જોડાણ નિષà«àª«àª³: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "નથી "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "સà«àªŸà«àª°à«€àª®àª¨à«‡ નિકાલ કરવામાં નિષà«àª«àª³: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "સà«àªŸà«àª°à«€àª® બફર ગà«àª£àª§àª°à«àª®à«‹ બદલાયેલ છે.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "પà«àª²à«‡àª¬à«‡àª• સà«àªŸà«àª°à«€àª® ને નિકાલ કરેલ છે.\n"
+msgid "Connection established.%s"
+msgstr "જોડાણ સà«àª¥àª¾àªªàª¿àª¤ થયેલ છે.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "સરà«àªµàª°àª®àª¾àª‚ જોડાણને નિકાલ કરી રહà«àª¯àª¾ છે.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF મળà«àª¯à«.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() નિષà«àª«àª³: %s\n"
+msgid "Connection failure: %s"
+msgstr "જોડાણ નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() નિષà«àª«àª³: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF મળà«àª¯à«."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "સંકેત મળà«àª¯à«àª‚, બહાર નીકળી રહà«àª¯àª¾ છે.\n"
+msgid "write() failed: %s"
+msgstr "write() નિષà«àª«àª³: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "ગà«àªªà«àª¤àª¤àª¾ મેળવવામાં નિષà«àª«àª³: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "સંકેત મળà«àª¯à«àª‚, બહાર નીકળી રહà«àª¯àª¾ છે."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Time: %0.3f sec; Latency: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "ગà«àªªà«àª¤àª¤àª¾ મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() નિષà«àª«àª³: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Time: %0.3f sec; Latency: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() નિષà«àª«àª³: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1463,8 +1363,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1487,57 +1389,63 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
+" -h, --help આ મદદને બતાવો\n"
+" --version આવૃતà«àª¤àª¿àª¨à«‡ બતાવો\n"
"\n"
-" -r, --record Create a connection for recording\n"
-" -p, --playback Create a connection for playback\n"
+" -r, --record રેકોરà«àª¡à«€àª‚ગ માટે જોડાણને બનાવો\n"
+" -p, --playback પà«àª²à«‡àª¬à«‡àª• માટે જોડાણને બનાવો\n"
"\n"
-" -v, --verbose Enable verbose operations\n"
+" -v, --verbose વરà«àª¬à«‹àª¸ કà«àª°àª¿àª¯àª¾àª“ ને સકà«àª°àª¿àª¯ કરો\n"
"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink/source to "
-"connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --rate=SAMPLERATE The sample rate in Hz (defaults to "
-"44100)\n"
-" --format=SAMPLEFORMAT The sample type, one of s16le, "
-"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
-" --channels=CHANNELS The number of channels, 1 for mono, "
-"2 for stereo\n"
-" (defaults to 2)\n"
-" --channel-map=CHANNELMAP Channel map to use instead of the "
-"default\n"
-" --fix-format Take the sample format from the sink "
-"the stream is\n"
-" being connected to.\n"
-" --fix-rate Take the sampling rate from the sink "
-"the stream is\n"
-" being connected to.\n"
-" --fix-channels Take the number of channels and the "
-"channel map\n"
-" from the sink the stream is being "
-"connected to.\n"
-" --no-remix Don't upmix or downmix channels.\n"
-" --no-remap Map channels by index instead of "
-"name.\n"
-" --latency=BYTES Request the specified latency in "
-"bytes.\n"
-" --process-time=BYTES Request the specified process time "
-"per request in bytes.\n"
+" -s, --server=SERVER તેમાં જોડાવા માટે સરà«àªµàª°àª¨à«àª‚ નામ\n"
+" -d, --device=DEVICE તેમાં જોડાવા માટે સિંક/સà«àª¤à«àª°à«‹àª¤ નà«àª‚ નામ\n"
+" -n, --client-name=NAME સરà«àªµàª° પર આ કà«àª²àª¾àª‡àª¨à«àªŸàª¨à«‡ કેવી રીતે કોલ કરવો\n"
+" --stream-name=NAME સરà«àªµàª° પર આ સà«àªŸà«àª°à«€àª®àª¨à«‡ કેવી રીતે કોલ કરવો\n"
+" --volume=VOLUME સીમા 0...65536 માં પà«àª°àª¾àª°àª‚ભનાં (સીધા) "
+"વોલà«àª¯à«àª®àª¨à«‡ સà«àªªàª·à«àªŸ કરો\n"
+" --rate=SAMPLERATE Hz માં નમૂનો(44100 નાં મૂળભૂતો)\n"
+" --format=SAMPLEFORMAT નમૂના પà«àª°àª•ાર, s16le, s16be, u8, "
+"float32le, માંનો àªàª•\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS ચેનલોની સંખà«àª¯àª¾, mono માટે 1, stereo માટે "
+"2\n"
+" (2 ઠમૂળભૂત છે)\n"
+" --channel-map=CHANNELMAP મૂળભૂત ને બદલે વાપરવા માટે ચેનલ મેપ\n"
+" --fix-format સà«àªŸà«àª°à«€àª® તેમાં જોડાયેલ છે તે સિંક માંથી નમૂના "
+"બંધારણને\n"
+" લો.\n"
+" --fix-rate સà«àªŸà«àª°à«€àª® તેમાં જોડાયેલ છે તે સિંક માંથી નમૂના "
+"દરને લો.\n"
+" --fix-channels સà«àªŸà«àª°à«€àª® તેમાં જોડાયેલ છે તે સિંક માંથી ચેનલો "
+"અને ચેનલ માપને લો.\n"
+" --no-remix ચેનલોને upmix અથવા downmix કરો નહિં.\n"
+" --no-remap નામને બદલે અનà«àª•à«àª°àª®àª£àª¿àª•ા દà«àª¦àª¾àª°àª¾ મેપ ચેનલો.\n"
+" --latency=BYTES બાઇટોમાં સà«àªªàª·à«àªŸ થયેલ ગà«àªªà«àª¤àª¤àª¾ ની માંગણી "
+"કરો.\n"
+" --process-time=BYTES બાઇટોમાં માંગણી ની સાથે સà«àªªàª·à«àªŸ થયેલ "
+"પà«àª°àª•à«àª°àª¿àª¯àª¾ સમયની માંગણી કરો.\n"
+" --property=PROPERTY=VALUE સà«àªªàª·à«àªŸ થયેલ કિંમતમાં સà«àªªàª·à«àªŸ થયેલ ગà«àª£àª§àª°à«àª®àª¨à«‡ "
+"સà«àª¯à«‹àªœàª¿àª¤ કરો.\n"
+" --raw કાચી PCM માહિતીનો રેકોરà«àª¡ કરો/વગાડો.\n"
+" --file-format=FFORMAT બંધારણ થયેલ માહિતીનો રેકોરà«àª¡ કરો/વગાડો.\n"
+" --list-file-formats ઉપલà«àª¬àª§ ફાઇલ બંધારણોની યાદી.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1548,129 +1456,169 @@ msgstr ""
"libpulse %s સાથે કમà«àªªàª¾àª‡àª² થયેલ છે\n"
"libpulse %s સાથે કડી થયેલ છે\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "અયોગà«àª¯ ચેનલ મેપ '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "અયોગà«àª¯ કà«àª²àª¾àª‡àª¨à«àªŸ નામ '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "અયોગà«àª¯ ગà«àªªà«àª¤àª¤àª¾ સà«àªªàª·à«àªŸà«€àª•રણ '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "અયોગà«àª¯ સà«àªŸà«àª°à«€àª® નામ '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "અયોગà«àª¯ પà«àª°àª•à«àª°àª¿àª¯àª¾ સમય સà«àªªàª·à«àªŸà«€àª•રણ '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "અયોગà«àª¯ ચેનલ મેપ '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "અયોગà«àª¯ નમૂના સà«àªªàª·à«àªŸà«€àª•રણ\n"
+msgid "Invalid latency specification '%s'"
+msgstr "અયોગà«àª¯ ગà«àªªà«àª¤àª¤àª¾ સà«àªªàª·à«àªŸà«€àª•રણ '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "ચેનલ મેપ ઠસà«àªªàª·à«àªŸà«€àª•રણ નમૂનાને બંધબેસતૠનથી\n"
+msgid "Invalid process time specification '%s'"
+msgstr "અયોગà«àª¯ પà«àª°àª•à«àª°àª¿àª¯àª¾ સમય સà«àªªàª·à«àªŸà«€àª•રણ '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "નમૂના સà«àªªàª·à«àªŸà«€àª•રણ '%s' સાથે %s સà«àªŸà«àª°à«€àª®àª¨à«‡ ખોલી રહà«àª¯àª¾ છે.\n"
+msgid "Invalid property '%s'"
+msgstr "અયોગà«àª¯ ગà«àª£àª§àª°à«àª® '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "રેકોરà«àª¡ કરી રહà«àª¯àª¾ છે"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "અજà«àªžàª¾àª¤ ફાઇલ બંધારણ %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "પà«àª²à«‡àª¬à«‡àª•"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "અયોગà«àª¯ નમૂના સà«àªªàª·à«àªŸà«€àª•રણ"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "ઘણી બધી દલીલો છે.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "ઘણી બધી દલીલો છે."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() નિષà«àª«àª³.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "ફાઇલ માટે નમૂના સà«àªªàª·à«àªŸà«€àª•રણ ને ઉતà«àªªàª¨à«àª¨ કરવામાં નિષà«àª«àª³."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() નિષà«àª«àª³.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "સાઉનà«àª¡ ફાઇલને ખોલવામાં નિષà«àª«àª³àª¤àª¾."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() નિષà«àª«àª³.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "ચેતવણી: સà«àªªàª·à«àªŸ થયેલ નમૂના સà«àªªàª·à«àªŸà«€àª•રણ ફાઇલ માંથી સà«àªªàª·à«àªŸà«€àª•રણ સાથે ઉપર લખાયેલ હશે."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() નિષà«àª«àª³: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ફાઇલ માંથી નમૂના સà«àªªàª·à«àªŸà«€àª•રણને નકà«àª•à«€ કરવામાં નિષà«àª«àª³àª¤àª¾."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "ચેતવણી: ફાઇલમાંથી ચેનલ મેપને નકà«àª•à«€ કરવામાં નિષà«àª«àª³àª¤àª¾."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "ચેનલ મેપ ઠસà«àªªàª·à«àªŸà«€àª•રણ નમૂનાને બંધબેસતૠનથી"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "ચેતણી: ફાઇલમાં ચેનલ મેપને લખવામાં નિષà«àª«àª³àª¤àª¾."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() નિષà«àª«àª³.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "નમૂના સà«àªªàª·à«àªŸà«€àª•રણ '%s' અને ચેનલ નકà«àª·àª¾ '%s' સાથે %s સà«àªŸà«àª°à«€àª®àª¨à«‡ ખોલી રહà«àª¯àª¾ છે."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "રેકોરà«àª¡ કરી રહà«àª¯àª¾ છે"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "પà«àª²à«‡àª¬à«‡àª•"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() નિષà«àª«àª³."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() નિષà«àª«àª³."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() નિષà«àª«àª³."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() નિષà«àª«àª³.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() નિષà«àª«àª³: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_new() નિષà«àª«àª³."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() નિષà«àª«àª³."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "થોડા સમય માટે બંધ કરવા માટે નિષà«àª«àª³àª¤àª¾: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "ફરી શરૂ કરવામાં નિષà«àª«àª³àª¤àª¾: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "ચેતવણી: સાઉનà«àª¡ સરà«àªµàª° ઠસà«àª¥àª¾àª¨àª¿àª• નથી, થોડા સમય માટે બંધ કરવામાં આવà«àª¯à« નથી.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "જોડાણ નિષà«àª«àª³: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT મળà«àª¯à«, બહાર નીકળી રહà«àª¯àª¾ છે.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "ચેતવણી: બાળ પà«àª°àª•à«àª°àª¿àª¯àª¾àª¨à«‹ સંકેત %u દà«àª¦àª¾àª°àª¾ અંત આવેલ છે\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1688,7 +1636,7 @@ msgstr ""
" -s, --server=SERVER જોડાવવા માટે સરà«àªµàª°àª¨à«àª‚ નામ\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1699,35 +1647,61 @@ msgstr ""
"libpulse %s સાથે કમà«àªªàª¾àª‡àª² થયેલ છે\n"
"libpulse %s સાથે કડી થયેલ છે\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() નિષà«àª«àª³.\n"
+
+#: ../src/utils/pasuspender.c:288
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "પરિસà«àª¥àª¿àª¤àª¿àª“ને મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() નિષà«àª«àª³.\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() નિષà«àª«àª³.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "પરિસà«àª¥àª¿àª¤àª¿àª“ને મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "હાલમાં વપરાશમાં છે: %u બà«àª²à«‹àª•à«‹ %s કà«àª² બાઇટોને સમાવી રહà«àª¯àª¾ છે.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "આખી જીંદગી દરમà«àª¯àª¾àª¨ ફાળવેલ છે: %u બà«àª²à«‹àª•à«‹ %s કà«àª² બાઇટોને સમાવી રહà«àª¯àª¾ છે.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "નમૂના કેશ માપ: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "સરà«àªµàª° જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "સરà«àªµàª° જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1735,7 +1709,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"વપરાશકરà«àª¤àª¾ નામ: %s\n"
"યજમાન નામ: %s\n"
@@ -1747,12 +1721,12 @@ msgstr ""
"મૂળભૂત સà«àª¤à«àª°à«‹àª¤: %s\n"
"કà«àª•à«€: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "સિંક જાણકારી મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "સિંક જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1791,12 +1765,22 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tપોરà«àªŸà«‹:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "સà«àª¤à«àª°à«‹àª¤ જાણકારીને મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tસકà«àª°àª¿àª¯ પોરà«àªŸ: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "સà«àª¤à«àª°à«‹àª¤ જાણકારીને મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1835,20 +1819,20 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "મોડà«àª¯à«àª²àª¨à«€ જાણકારી મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "મોડà«àª¯à«àª²àª¨à«€ જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1865,12 +1849,12 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "કà«àª²àª¾àª‡àª¨à«àªŸ જાણકારી મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "કà«àª²àª¾àª‡àª¨à«àªŸ જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1885,12 +1869,12 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "કારà«àª¡ જાણકારી મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "કારà«àª¡ જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1907,22 +1891,22 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tરૂપરેખાઓ:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tસકà«àª°àª¿àª¯ રૂપરેખા: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "સિંક ઇનપà«àªŸ જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "સિંક ઇનપà«àªŸ જાણકારી મેળવવામાં નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1959,12 +1943,12 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "સà«àª¤à«àª°à«‹àª¤ આઉટપà«àªŸ જાણકારી મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "સà«àª¤à«àª°à«‹àª¤ આઉટપà«àªŸ જાણકારી મેળવવામાં નિષà«àª«àª³: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1993,12 +1977,12 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "નમૂના જાણકારી મેળવવામાં નિષà«àª«àª³: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "નમૂના જાણકારી મેળવવામાં નિષà«àª«àª³: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2029,23 +2013,80 @@ msgstr ""
"\tગà«àª£àª§àª°à«àª®à«‹:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "નિષà«àª«àª³àª¤àª¾: %s\n"
+msgid "Failure: %s"
+msgstr "નિષà«àª«àª³àª¤àª¾: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "નમૂનાને અપલોડ કરવામાં નિષà«àª«àª³: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "નમૂનાને અપલોડ કરવામાં નિષà«àª«àª³: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "ફાઇલનો નિયત સમય પહેલા અંત\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "ફાઇલનો નિયત સમય પહેલા અંત"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "અયોગà«àª¯ સરà«àªµàª°"
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT મળà«àª¯à«, બહાર નીકળી રહà«àª¯àª¾ છે."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2053,13 +2094,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2075,21 +2125,31 @@ msgstr ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
-" -h, --help આ મદદ ને બતાવો\n"
-" --version આવૃતà«àª¤àª¿àª¨à«‡ બતાવોShow version\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
"\n"
-" -s, --server=SERVER જોડાવા માટે સરà«àªµàª° નà«àª‚ નામ\n"
-" -n, --client-name=NAME સરà«àªµàª° પર આ કà«àª²àª¾àª‡àª¨à«àªŸàª¨à«‡ કેવી રીતે કોલ કરશો\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2100,76 +2160,108 @@ msgstr ""
"libpulse %s સાથે કમà«àªªàª¾àª‡àª² થયેલ છે\n"
"libpulse %s સાથે કડી થયેલ છે\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "મહેરબાની કરીને લોડ કરવા માટે નમૂના ફાઇલને સà«àªªàª·à«àªŸ કરો\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "મહેરબાની કરીને લોડ કરવા માટે નમૂના ફાઇલને સà«àªªàª·à«àªŸ કરો"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "સાઉનà«àª¡ ફાઇલને ખોલવામાં નિષà«àª«àª³.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "સાઉનà«àª¡ ફાઇલને ખોલવામાં નિષà«àª«àª³."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "વગાડવા માટે તમારે નમૂના નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "ચેતવણી: ફાઇલ માંથી નમૂના સà«àªªàª·à«àªŸà«€àª•રણ કરવાનà«àª‚ નકà«àª•à«€ કરવામાં નિષà«àª«àª³."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "દૂર કરવા માટે તમારે નમૂના નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "વગાડવા માટે તમારે નમૂના નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "સિંક ઇનપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા અને સિંકને તમારે સà«àªªàª·à«àªŸ કરવૠજ પડશે\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "દૂર કરવા માટે તમારે નમૂના નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "તમારે સà«àª¤à«àª°à«‹àª¤ આઉટપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા અને સà«àª¤à«àª°à«‹àª¤àª¨à«‡ સà«àªªàª·à«àªŸ કરવૠજ પડશે\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "સિંક ઇનપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા અને સિંકને તમારે સà«àªªàª·à«àªŸ કરવૠજ પડશે"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "તમારે મોડà«àª¯à«àª² નામ અને દલીલોને સà«àªªàª·à«àªŸ કરવૠજ પડશે.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "તમારે સà«àª¤à«àª°à«‹àª¤ આઉટપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા અને સà«àª¤à«àª°à«‹àª¤àª¨à«‡ સà«àªªàª·à«àªŸ કરવૠજ પડશે"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "તમારે મોડà«àª¯à«àª² અનà«àª•à«àª°àª®àª£àª¿àª•ાને સà«àªªàª·à«àªŸ કરવૠજ પડશે\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "તમારે મોડà«àª¯à«àª² નામ અને દલીલોને સà«àªªàª·à«àªŸ કરવૠજ પડશે."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "તમારે મોડà«àª¯à«àª² અનà«àª•à«àª°àª®àª£àª¿àª•ાને સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"તમે àªàª• સિંક કરતા વધારે સà«àªªàª·à«àªŸ કરી શકશો નહિં. તમારે બà«àª²àª¿àª¯àª¨ કિંમતને સà«àªªàª·à«àªŸ કરવૠજ પડશે.\n"
+"તમે àªàª• સિંક કરતા વધારે સà«àªªàª·à«àªŸ કરી શકશો નહિં. તમારે બà«àª²àª¿àª¯àª¨ કિંમતને સà«àªªàª·à«àªŸ કરવૠજ પડશે."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"તમે àªàª• સà«àª¤à«àª°à«‹àª¤ કરતા વધારે સà«àªªàª·à«àªŸ કરી શકશો નહિં. તમારે બà«àª²àª¿àª¯àª¨ કિંમતને સà«àªªàª·à«àªŸ કરવૠજ પડશે.\n"
+"તમે àªàª• સà«àª¤à«àª°à«‹àª¤ કરતા વધારે સà«àªªàª·à«àªŸ કરી શકશો નહિં. તમારે બà«àª²àª¿àª¯àª¨ કિંમતને સà«àªªàª·à«àªŸ કરવૠજ પડશે."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "તમારે કારà«àª¡ નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને રૂપરેખા નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "તમારે કારà«àª¡ નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને પોરà«àªŸ નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "યોગà«àª¯ આદેશ સà«àªªàª·à«àªŸ થયેલ નથી.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "તમારે કારà«àª¡ નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને પોરà«àªŸ નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() નિષà«àª«àª³: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "તમારે કારà«àª¡ નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને પોરà«àªŸ નામને સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "તમારે કારà«àª¡ નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને વોલà«àª¯à«àª®àª¨à«‡ સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "અયોગà«àª¯ નમૂના સà«àªªàª·à«àªŸà«€àª•રણ"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "તમારે કારà«àª¡ નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને વોલà«àª¯à«àª® સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "સિંક ઇનપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા અને વોલà«àª¯à«àª®àª¨à«‡ તમારે સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "અયોગà«àª¯ સિંક ઇનપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "તમારે સિંક નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને મૂંગા બà«àª²àª¿àª¯àª¨àª¨à«‡ સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "તમારે સિંક નામ/અનà«àª•à«àª°àª®àª£àª¿àª•ા અને મૂંગા બà«àª²àª¿àª¯àª¨àª¨à«‡ સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "સિંક ઇનપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા અને મૂંગા બà«àª²àª¿àª¯àª¨àª¨à«‡ તમારે સà«àªªàª·à«àªŸ કરવૠજ પડશે"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "અયોગà«àª¯ ઇનપà«àªŸ અનà«àª•à«àª°àª®àª£àª¿àª•ા સà«àªªàª·à«àªŸà«€àª•રણ"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "યોગà«àª¯ આદેશ સà«àªªàª·à«àªŸ થયેલ નથી."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2250,126 +2342,48 @@ msgstr "કà«àª•à«€ માહિતીને લોડ કરવામાં àª
msgid "Not yet implemented.\n"
msgstr "હજૠઅમલીકરણ થયેલ નથી.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "PulseAudio ડિમન ચાલી રહà«àª¯à« નથી, અથવા સતà«àª° ડિમન તરીકે ચાલી રહà«àª¯à« નથી."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio ડિમનને મારવામાં નિષà«àª«àª³."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "ડિમન ઠજવાબ આપતૠનથી."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "સà«àªŸà«àª°à«€àª® સફળતાપૂરà«àªµàª• બનાવેલ છે\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "સà«àªŸà«àª°à«€àª® ભૂલ: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "જોડાણ સà«àª¥àª¾àªªàª¿àª¤ થયેલ છે.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help આ મદદને બતાવો\n"
-" --version આવૃતà«àª¤àª¿àª¨à«‡ બતાવો\n"
-"\n"
-" -v, --verbose વરà«àª¬à«‹àª¸ કà«àª°àª¿àª¯àª¾àª¨à«‡ સકà«àª°àª¿àª¯ કરો\n"
-"\n"
-" -s, --server=SERVER જોડાવા માટે સરà«àªµàª°àª¨à«àª‚ નામ\n"
-" -d, --device=DEVICE જોડાવા માટે સિંકનà«àª‚ નામ\n"
-" -n, --client-name=NAME સરà«àªµàª° પર આ કà«àª²àª¾àª‡àª¨à«àªŸàª¨à«‡ કેવી રીતે કોલ કરશો\n"
-" --stream-name=NAME સરà«àªµàª° પર આ સà«àªŸà«àª°à«€àª®àª¨à«‡ કેવી રીતે કોલ કરશો\n"
-" --volume=VOLUME સીમા 0...65536 માં પà«àª°àª¾àª°àª‚ભનાં (àªàª• સરખા) "
-"વોલà«àª¯à«àª®àª¨à«‡ સà«àªªàª·à«àªŸ કરો\n"
-" --channel-map=CHANNELMAP વાપરવા માટે ચેનલ મેપને સà«àª¯à«‹àªœàª¿àª¤ કરો\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"libpulse %s સાથે કમà«àªªàª¾àª‡àª² થયેલ છે\n"
-"libpulse %s સાથે કડી થયેલ છે\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "અયોગà«àª¯ ચેનલ મેપ\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "ફાઇલ '%s' ખોલવામાં નિષà«àª«àª³\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "ચેનલ મેપ ફાઇલ સાથે બંધબેસતૠનથી.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "નમૂના spec '%s' ને વાપરી રહà«àª¯àª¾ છે\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "autospawn તાળાને દાખલ કરી શકાતૠનથી."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2386,7 +2400,7 @@ msgstr ""
"POLLOUT સà«àª¯à«‹àªœàª¨ સાથે આપણે જાગેલ હતા -- છતાંપણ ના પછીનà«àª‚ snd_pcm_avail() ને 0 પાછો મળે "
"છે અથવા બીજી કિંમત < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2403,34 +2417,259 @@ msgstr ""
"POLLOUT સà«àª¯à«‹àªœàª¨ સાથે આપણે જાગેલ હતા -- છતાંપણ ના પછીનà«àª‚ snd_pcm_avail() ને 0 પાછો મળે "
"છે અથવા બીજી કિંમત < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "આઉટપà«àªŸ %s + ઇનપà«àªŸ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "આઉટપà«àªŸ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "ઇનપà«àªŸ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "બંધ"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "High Fidelity Playback (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "High Fidelity Capture (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "Telephony Duplex (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio સાઉનà«àª¡ સરà«àªµàª°"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "આઉટપà«àªŸ ઉપકરણો"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ઇનપà«àªŸ ઉપકરણો"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ પર ઓડિયો"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "ઇનપà«àªŸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ડોકિંગ સà«àªŸà«‡àª¶àª¨ ઇનપà«àªŸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ડોકિંગ સà«àªŸà«‡àª¶àª¨ માઇકà«àª°à«‹àª«à«‹àª¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "લાઇન-ઇન"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "માઇકà«àª°à«‹àª«à«‹àª¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "બહારનાં માઇકà«àª°à«‹àª«à«‹àª¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "આંતરિક માઇકà«àª°à«‹àª«à«‹àª¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "રેડિયો"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "વિડિયો"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Automatic Gain Control"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Automatic Gain Control નથી"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "બà«àª¸à«àªŸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "બà«àª¸à«àªŸ નથી"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "પરિવરà«àª§àª•"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "પરિવરà«àª§àª• નથી"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "બà«àª¸à«àªŸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "બà«àª¸à«àªŸ નથી"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "àªàª¨àª²à«‰àª— હૅડફોનો"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "àªàª¨àª²à«‰àª— ઇનપà«àªŸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "àªàª¨àª²à«‰àª— માઇકà«àª°à«‹àª«à«‹àª¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "àªàª¨àª²à«‰àª— લાઇન-ઇન"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "àªàª¨àª²à«‰àª— રેડિયો"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "àªàª¨àª²à«‰àª— વિડિયો"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "àªàª¨àª²à«‰àª— આઉટપà«àªŸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "àªàª¨àª²à«‰àª— હૅડફોનો"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "àªàª¨àª²à«‰àª— આઉટપà«àªŸ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "àªàª¨àª²à«‰àª— મોનો આઉટપà«àªŸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "àªàª¨àª²à«‰àª— સà«àªŸà«‡àª°àª¿àª“"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "àªàª¨àª²à«‰àª— મોનો"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "àªàª¨àª²à«‰àª— સà«àªŸà«‡àª°àª¿àª“"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "àªàª¨àª²à«‰àª— સરાઉનà«àª¡ 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "ડિજિટલ સà«àªŸà«‡àª°àª¿àª“ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "ડિજિટલ સરાઉનà«àª¡ 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "ડિજિટલ સરાઉનà«àª¡ 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "ડિજિટલ સરાઉનà«àª¡ 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "ડિજિટલ સà«àªŸà«‡àª°àª¿àª“ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "àªàª¨àª²à«‰àª— મોનો ડà«àªªà«àª²à«‡àª•à«àª·"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "àªàª¨àª²à«‰àª— સà«àªŸà«‡àª°àª¿àª“ ડà«àªªà«àª²à«‡àª•à«àª·"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ડિજિટલ સà«àªŸà«‡àª°àª¿àª“ ડà«àªªà«àª²à«‡àª•à«àª· (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Low Frequency Emmiter"
diff --git a/po/he.po b/po/he.po
new file mode 100644
index 00000000..6231bd62
--- /dev/null
+++ b/po/he.po
@@ -0,0 +1,2357 @@
+msgid ""
+msgstr ""
+"Project-Id-Version: pulseaudio\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: \n"
+"Last-Translator: Elad <el.il@doom.co.il>\n"
+"Language-Team: Hebrew <fedora-he-list@redhat.com>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"X-Poedit-Language: Hebrew\n"
+"X-Poedit-Country: Israel\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr ""
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr ""
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr ""
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr ""
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "צליל פנימי"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "מוד×"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr ""
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr ""
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr ""
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr ""
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "יוצ×."
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr ""
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr ""
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr ""
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr ""
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr ""
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr ""
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr ""
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr ""
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr ""
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr ""
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr ""
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr ""
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr ""
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr ""
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr ""
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr ""
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr ""
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr ""
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr ""
+
+#: ../src/daemon/main.c:726
+#, c-format
+msgid "pipe() failed: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr ""
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr ""
+
+#: ../src/daemon/main.c:778
+#, c-format
+msgid "setsid() failed: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr ""
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr ""
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr ""
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr ""
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr ""
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:850
+#, c-format
+msgid "Running in VM: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr ""
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr ""
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr ""
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr ""
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr ""
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr ""
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr ""
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr ""
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr ""
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr ""
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr ""
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr ""
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr ""
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr ""
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr ""
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr ""
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr ""
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr ""
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr ""
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr ""
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr ""
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr ""
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:479
+#, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr ""
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr ""
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "מערכת הקול PulseAudio"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "התחל ×ת מערכת הקול PulseAudio"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "מונו"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "מרכזי קדמי"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "שמ×לי קדמי"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "ימני קדמי"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "מרכזי ×חורי"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "שמ×לי ×חורי"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "ימני ×חורי"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "צד שמ×ל"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "צד ימין"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "מרכזי עליון"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "מרכזי עליון קדמי"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "עליון שמ×לי קדמי"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "עליון ימני קדמי"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "עליון מרכזי ×חורי"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "עליון שמ×לי ×חורי"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "עליון ימני ×חורי"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "(×œ× ×ª×§×£)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "סטר×ו"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "סר×ונד 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "סר×ונד 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "סר×ונד 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "סר×ונד 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "סר×ונד 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "×ישור"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "הגישה נדחתה"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr ""
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr ""
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr ""
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr ""
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "החיבור נדחה"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "שגי×ת פרוטוקול"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr ""
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr ""
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "שגי××” פנימית"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr ""
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr ""
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr ""
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr ""
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr ""
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr ""
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr ""
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "גדול מדי"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "×œ× × ×ª×ž×š"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "קוד שגי××” ×œ× ×ž×•×›×¨"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr ""
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr ""
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr ""
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr ""
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "שגי×ת קלט/פלט"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "התקן ×ו מש×ב עסוקי×"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr ""
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr ""
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr ""
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr ""
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr ""
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr ""
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr ""
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr ""
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr ""
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr ""
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr ""
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr ""
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr ""
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr ""
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr ""
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr ""
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr ""
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr ""
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr ""
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "ל×"
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr ""
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr ""
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr ""
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr ""
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:630
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr ""
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr ""
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr ""
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr ""
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr ""
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr ""
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr ""
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr ""
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr ""
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr ""
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr ""
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr ""
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr ""
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr ""
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr ""
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "מקליט"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "× ×’×™× ×”"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr ""
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr ""
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr ""
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr ""
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr ""
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr ""
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "×œ× ×–×ž×™×Ÿ"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\tפרופילי×:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "כשל: %s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr ""
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr ""
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+msgid "server"
+msgstr ""
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr ""
+
+#: ../src/utils/pactl.c:961
+#, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr ""
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr ""
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr ""
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr ""
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr ""
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr ""
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr ""
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr ""
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr ""
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr ""
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr ""
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr ""
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr ""
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr ""
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr ""
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr ""
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr ""
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr ""
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr ""
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "מכובה"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr ""
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr ""
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr ""
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "שרת הקול PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "התקני פלט"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "התקני קלט"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "פלט"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "קלט של תחנת עגינה"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "מיקרופון של תחנת עגינה"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "קו נכנס"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "מיקרופון"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "מיקרופון חיצוני"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "מיקרופון פנימי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "רדיו"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "ויד×ו"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "מגבר"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "×ין מגבר"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+msgid "Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+msgid "No Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "×וזניות ×נלוגיות"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "קלט ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "מיקרופון ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "קו נכנס ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "רדיו ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "ויד×ו ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "פלט ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "×וזניות ×נלוגיות"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "פלט ×נלוגי (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "פלט מונו ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "סטר×ו ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "מונו ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "סטר×ו ×נלוגי"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "סר×ונד ×נלוגי 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "סר×ונד ×נלוגי 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "סר×ונד ×נלוגי 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "סר×ונד ×נלוגי 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "סר×ונד ×נלוגי 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "סר×ונד ×נלוגי 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "סר×ונד ×נלוגי 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "סר×ונד ×נלוגי 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "סר×ונד ×נלוגי 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "סר×ונד ×נלוגי 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "סר×ונד ×נלוגי 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "סטר×ו דיגיטלי (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "סר×ונד דיגיטלי 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "סר×ונד דיגיטלי 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "סר×ונד דיגיטלי 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "סטר×ו דיגיטלי (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "מונו ×נלוגי משולב"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "סטר×ו ×נלוגי משולב"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "סטר×ו דיגיטלי משולב (IEC958)"
diff --git a/po/hi.po b/po/hi.po
new file mode 100644
index 00000000..cb2b048b
--- /dev/null
+++ b/po/hi.po
@@ -0,0 +1,2691 @@
+# translation of pulseaudio.master-tx.po to Hindi
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+#
+# Rajesh Ranjan <rajesh672@gmail.com>, 2009.
+msgid ""
+msgstr ""
+"Project-Id-Version: pulseaudio.master-tx\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-11-13 15:42+0530\n"
+"Last-Translator: Rajesh Ranjan <rajesh672@gmail.com>\n"
+"Language-Team: Hindi <hindi.sf.net>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Generator: KBabel 1.11.4\n"
+"Plural-Forms: nplurals=2; plural=(n!=1);\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_avail() ने à¤à¤• मान दिया जो अपà¥à¤°à¤¤à¥à¤¯à¤¾à¤¶à¤¿à¤¤ रूप से बड़ा है: %lu बाइट (%lu ms).\n"
+"अधिक संभव है कि यह ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' में à¤à¤• बग है. इस मà¥à¤¦à¥à¤¦à¥‡ को ALSA डेवलेपर को रिपोरà¥à¤Ÿ "
+"करें."
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_delay() ने à¤à¤• मान दिया जो अपà¥à¤°à¤¤à¥à¤¯à¤¾à¤¶à¤¿à¤¤ रूप से बड़ा है: %li बाइट (%s%lu ms).\n"
+"अधिक संभव है कि यह ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' में à¤à¤• बग है. इस मà¥à¤¦à¥à¤¦à¥‡ को ALSA डेवलेपर को रिपोरà¥à¤Ÿ "
+"करें."
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_mmap_begin() ने à¤à¤• मान दिया जो अपà¥à¤°à¤¤à¥à¤¯à¤¾à¤¶à¤¿à¤¤ रूप से बड़ा है: %lu बाइट (%lu "
+"ms).\n"
+"अधिक संभव है कि यह ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' में à¤à¤• बग है. इस मà¥à¤¦à¥à¤¦à¥‡ को ALSA डेवलेपर को रिपोरà¥à¤Ÿ "
+"करें."
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "हमेशा कम से मक à¤à¤• सिंक को लोडेड रखें हालांकि यह à¤à¤• रिकà¥à¤¤ है"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "डमी आउटपà¥à¤Ÿ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "वरà¥à¤šà¥à¤…ल LADSPA सिंक"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "कà¥à¤²à¥‰à¤•à¥à¤¡ रिकà¥à¤¤ सिंक"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "रिकà¥à¤¤ आउटपà¥à¤Ÿ"
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "आंतरिक ऑडियो"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "मॉडेम"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr "मौलिक ltdlopen लोडर ढूà¤à¤¢à¤¼à¤¨à¥‡ में विफल (_d)."
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr "नया dl लोडर आबंटित करने में विफल."
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr "bind-now-loader जोड़ने में विफल."
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr "%s संकेत पाया."
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "बाहर हो रहा है."
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr "'%s' उपयोकà¥à¤¤à¤¾ ढूंढ़ने में विफल."
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr "'%s' समूह ढूंढ़ने में विफल."
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr "'%s' (UID %lu) उपयोकà¥à¤¤à¤¾ व '%s' (GID %lu) समूह पाया."
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr "'%s' उपयोकà¥à¤¤à¤¾ और '%s' समूह का GID मेल नहीं खाता है"
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr "'%s' उपयोकà¥à¤¤à¤¾ की घर निरà¥à¤¦à¥‡à¤¶à¤¿à¤•ा '%s' नहीं है, अनदेखा कर रहा है."
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr "'%s' बनाने में विफल: %s"
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr "समूह सूची पाने में विफल: %s"
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr "GID बदलने में विफल: %s"
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr "UID बदलने में विफल: %s"
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr "रूट अधिकार सफलतापूरà¥à¤µà¤• छोड़ा."
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr "इस पà¥à¤²à¥ˆà¤Ÿà¤«à¥‰à¤°à¥à¤® पर असमरà¥à¤¥à¤¿à¤¤ तंतà¥à¤° वà¥à¤¯à¤¾à¤ªà¤• विधि."
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr "setrlimit(%s, (%u, %u)) विफल: %s"
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr "कमांड लाइन विशà¥à¤²à¥‡à¤·à¤£ में विफल."
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr "डेमॉन नहीं कारà¥à¤¯à¤¶à¥€à¤²"
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr "डेमॉन बतौर PID %u चल रहा है"
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr "डेमॉन हटाने में विफल: %s"
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr ""
+"यह पà¥à¤°à¥‹à¤—à¥à¤°à¤¾à¤® बतौर रूट चलाने के लिठइचà¥à¤›à¤¿à¤¤ नहीं है (unless --system is specified)."
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr "रूट अधिकार जरूरी."
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr "--start not supported for system instances."
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr "तंतà¥à¤° मोड में चल रहा है, लेकिन --disallow-exit सेट नहीं!"
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr "तंतà¥à¤° मोड में चल रहा है, लेकिन --disallow-module-loading सेट नहीं!"
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr "तंतà¥à¤° मोड में चल रहा है, SHM मोड बाधà¥à¤¯ रूप से निषà¥à¤•à¥à¤°à¤¿à¤¯!"
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr "तंतà¥à¤° मोड में चल रहा है, निकास निषà¥à¤•à¥à¤°à¤¿à¤¯ समय बाधà¥à¤¯ रूप से निषà¥à¤•à¥à¤°à¤¿à¤¯!"
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr "stdio पाने में विफल."
+
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "पाइप विफल: %s"
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr "fork() विफल: %s"
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr "read() विफल: %s"
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr "डेमॉन आरंभ विफल."
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr "डेमॉन आरंभ सफल."
+
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() विफल: %s"
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr "यह पलà¥à¤¸à¤‘डियो %s है."
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr "Compilation host: %s"
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr "Compilation CFLAGS: %s"
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr "मेजबान पर चल रहा है: %s"
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr "%u CPU पाया."
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr "पृषà¥à¤  आकार %lu बाइट है."
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr "वेलगà¥à¤°à¤¿à¤‚ड समरà¥à¤¥à¤¨ से कंपाइल: हाà¤"
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr "वेलगà¥à¤°à¤¿à¤‚ड समरà¥à¤¥à¤¨ से कंपाइल: नहीं"
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr "वेलगà¥à¤°à¤¿à¤‚ड विधि में चल रहा है: %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "मेजबान पर चल रहा है: %s"
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr "अनà¥à¤•ूलित बिलà¥à¤¡: हाà¤"
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr "अनà¥à¤•ूलित बिलà¥à¤¡: नहीं"
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr "NDEBUG परिभाषित, सभी निषà¥à¤•à¥à¤°à¤¿à¤¯."
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr "FASTPATH परिभाषित, केव तेज पथ à¤à¤¸à¤°à¥à¤Ÿ निषà¥à¤•à¥à¤°à¤¿à¤¯."
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr "सभी à¤à¤¸à¤°à¥à¤Ÿ सकà¥à¤·à¤®."
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr "मशीन ID पाने में विफल"
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr "मशीन ID %s है."
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr "सतà¥à¤° ID %s है."
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr "रनटाइम निरà¥à¤¦à¥‡à¤¶à¤¿à¤•ा %s का पà¥à¤°à¤¯à¥‹à¤— कर रहा है."
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr "सà¥à¤Ÿà¥‡à¤Ÿ निरà¥à¤¦à¥‡à¤¶à¤¿à¤•ा %s का पà¥à¤°à¤¯à¥‹à¤— कर रहा है."
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "मॉडà¥à¤¯à¥‚ल निरà¥à¤¦à¥‡à¤¶à¤¿à¤•ा %s का पà¥à¤°à¤¯à¥‹à¤— कर रहा है."
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr "तंतà¥à¤° मोड में चल रहा है: %s"
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"तो आप PA तंतà¥à¤° मोड में चला रहे हैं. कृपया नोट करें कि आपको à¤à¤¸à¤¾ नहीं करना चाहिà¤.\n"
+"यदि आप इसे करते हैं तो यह आपकी गलती है यदि कà¥à¤› अपà¥à¤°à¤¤à¥à¤¯à¤¾à¤¶à¤¿à¤¤ होता है.\n"
+"कृपया http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode को पढ़ें जानने के लिठ"
+"कि कà¥à¤¯à¥‹à¤‚ तंतà¥à¤° मोड à¤à¤• बढ़िया विचार नहीं है."
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr "pa_pid_file_create() विफल."
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr "ताज़ा उचà¥à¤š विभेदन टाइमर उपलबà¥à¤§! आनंद लें!"
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr ""
+"आपका करà¥à¤¨à¥‡à¤² बà¥à¤°à¥€ सà¥à¤¥à¤¿à¤¤à¤¿ में है! सलाह है कि उचà¥à¤š विभेदन यà¥à¤•à¥à¤¤ लिनकà¥à¤¸ सकà¥à¤°à¤¿à¤¯ किया जाना चाहिà¤!"
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr "pa_core_new() विफल."
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr "डेमॉन आरंभ करने में विफल."
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr "बिना लोड मॉडà¥à¤¯à¥‚ल के डेमॉन आरंभ, काम करने से असà¥à¤µà¥€à¤•ार कर रहा है."
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr "डेमॉन आरंभन पूरà¥à¤£."
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr "डेमॉन बनà¥à¤¦ किया जाना आरंभ."
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr "डेमॉन अवरोधित."
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr "--daemonize के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr "--fail के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr "--high-priority के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr "--realtime के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr "--disallow-module-loading के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr "--disallow-exit के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr "--use-pid-file के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr "अवैध लॉग लकà¥à¤·à¥à¤¯: use either 'syslog', 'stderr' or 'auto'."
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr "--log-time के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr "--log-meta के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr "अवैध पà¥à¤¨à¤ƒ पà¥à¤°à¤¤à¤¿à¤¦à¤°à¥à¤¶ विधि '%s'."
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr "--system के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr "--no-cpu-limit के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr "--disable-shm के लिठबà¥à¤²à¤¿à¤¯à¤¨ तरà¥à¤• की आशा है"
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr "नाम: %s\n"
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr "कोई मॉडà¥à¤¯à¥‚ल सूचना उपलबà¥à¤§ नहीं\n"
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr "संसà¥à¤•रण: %s\n"
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr "विवरण: %s\n"
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr "लेखक: %s\n"
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr "उपयोग: %s\n"
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr "à¤à¤• बार लोड करें: %s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "अवमूलà¥à¤¯à¤¨ चेतावनी: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr "पथ: %s\n"
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr "[%s:%u] अवैध लॉग लकà¥à¤·à¥à¤¯ '%s'."
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr "[%s:%u] अवैध लॉग सà¥à¤¤à¤° '%s'."
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr "[%s:%u] अवैध पà¥à¤¨à¤ƒ नमूना विधि '%s'."
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr "[%s:%u] अवैध rlimit '%s'."
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr "[%s:%u] rlimit इस पà¥à¤²à¥‡à¤Ÿà¤«à¥‰à¤°à¥à¤® पर समरà¥à¤¥à¤¿à¤¤ नहीं."
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr "[%s:%u] अवैध पà¥à¤°à¤¤à¤¿à¤¦à¤°à¥à¤¶ पà¥à¤°à¤¾à¤°à¥‚प '%s'."
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr "[%s:%u] अवैध पà¥à¤°à¤¤à¤¿à¤¦à¤°à¥à¤¶ दर '%s'."
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr "[%s:%u] अवैध पà¥à¤°à¤¤à¤¿à¤¦à¤°à¥à¤¶ चैनल '%s'."
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr "[%s:%u] अवैध चैनल मानचितà¥à¤° '%s'."
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr "[%s:%u] टà¥à¤•ड़े '%s' की अवैध संखà¥à¤¯à¤¾."
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr "[%s:%u] अवैध खंड आकार '%s'."
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr "[%s:%u] अवैध नाइस सà¥à¤¤à¤° '%s'."
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] अवैध पà¥à¤°à¤¤à¤¿à¤¦à¤°à¥à¤¶ दर '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr "विनà¥à¤¯à¤¾à¤¸ फ़ाइल खोलने में विफल: %s"
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr ""
+"निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ तयशà¥à¤¦à¤¾ चैनल मानचितà¥à¤° के पास चैनल की भिनà¥à¤¨ संखà¥à¤¯à¤¾ है चैनल की तयशà¥à¤¦à¤¾ निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ संखà¥à¤¯à¤¾ "
+"के बनिसà¥à¤ªà¤¤."
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr "### विनà¥à¤¯à¤¾à¤¸ फ़ाइल से पढ़ें: %s ###\n"
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "अधिकार छोड़ रहा है."
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "पलà¥à¤¸à¤‘डियो धà¥à¤µà¤¨à¤¿ तंतà¥à¤°"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "पलà¥à¤¸à¤‘डियो धà¥à¤µà¤¨à¤¿ तंतà¥à¤° पà¥à¤°à¤¾à¤°à¤‚भ करें"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "मोनो"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "अगà¥à¤° केंदà¥à¤°"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "अगà¥à¤° बायाà¤"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "अगà¥à¤° दाहिना"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "पशà¥à¤š केंदà¥à¤°"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "पशà¥à¤š बायां"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "पशà¥à¤š दाहिना"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr "केंदà¥à¤° का अगà¥à¤° वाम"
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr "केंदà¥à¤° का अगà¥à¤° दकà¥à¤·à¤¿à¤£"
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "किनारा वाम"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "किनारा दायाà¤"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr "सहायक 0"
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr "सहायक 1"
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr "सहायक 2"
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr "सहायक 3"
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr "सहायक 4"
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr "सहायक 5"
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr "सहायक 6"
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr "सहायक 7"
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr "सहायक 8"
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr "सहायक 9"
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr "सहायक 10"
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr "सहायक 11"
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr "सहायक 12"
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr "सहायक 13"
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr "सहायक 14"
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr "सहायक 15"
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr "सहायक 16"
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr "सहायक 17"
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr "सहायक 18"
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr "सहायक 19"
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr "सहायक 20"
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr "सहायक 21"
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr "सहायक 22"
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr "सहायक 23"
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr "सहायक 24"
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr "सहायक 25"
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr "सहायक 26"
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr "सहायक 27"
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr "सहायक 28"
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr "सहायक 29"
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr "सहायक 30"
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr "सहायक 31"
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "शीरà¥à¤· केंदà¥à¤°"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "शीरà¥à¤· अगà¥à¤° केंदà¥à¤°"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "शीरà¥à¤· अगà¥à¤° वाम"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "ऊपर अगà¥à¤° दायाà¤"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "ऊपर पशà¥à¤š केंदà¥à¤°"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "ऊपर पशà¥à¤š बायाà¤"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "ऊपर पशà¥à¤š दायाà¤"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "(अवैध)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "सà¥à¤Ÿà¥€à¤°à¤¿à¤¯à¥‹"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "सरà¥à¤°à¤¾à¤‰à¤‚ड 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "सरà¥à¤°à¤¾à¤‰à¤‚ड 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "सरà¥à¤°à¤¾à¤‰à¤‚ड 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "सरà¥à¤°à¤¾à¤‰à¤‚ड 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "सरà¥à¤°à¤¾à¤‰à¤‚ड 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "ठीक"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "पहà¥à¤à¤š मनाही"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr "अनजान कमांड"
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr "अवैध तरà¥à¤•"
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr "à¤à¤‚टिटी मौजूद"
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr "कोई à¤à¤¸à¥€ à¤à¤‚टिटी नहीं"
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "कनेकà¥à¤¶à¤¨ असà¥à¤µà¥€à¤•ृत"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "पà¥à¤°à¥‹à¤Ÿà¥‹à¤•ाल तà¥à¤°à¥à¤Ÿà¤¿"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr "समय ख़तà¥à¤®"
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr "कोई पà¥à¤°à¤¾à¤§à¤¿à¤•रण कà¥à¤‚जी नहीं"
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "आंतरिक तà¥à¤°à¥à¤Ÿà¤¿"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr "कनेकà¥à¤¶à¤¨ समापà¥à¤¤"
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr "à¤à¤‚टिटी मृत"
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr "अवैध सरà¥à¤µà¤°"
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr "मॉडयूल आरंभीकरण असफल"
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr "बà¥à¤°à¥€ सà¥à¤¥à¤¿à¤¤à¤¿"
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr "कोई आà¤à¤•ड़ा नहीं"
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr "बेमेल पà¥à¤°à¥‹à¤Ÿà¥‹à¤•ॉल संसà¥à¤•रण"
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "काफी बड़ा"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "समरà¥à¤¥à¤¿à¤¤ नहीं है"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "अजà¥à¤žà¤¾à¤¤ तà¥à¤°à¥à¤Ÿà¤¿ कोड"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr "कोई à¤à¤¸à¤¾ विसà¥à¤¤à¤¾à¤° नहीं"
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr "पà¥à¤°à¤¾à¤¨à¥€ पà¥à¤°à¤•ारà¥à¤¯à¤¾à¤¤à¥à¤®à¤•ता"
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr "अनà¥à¤ªà¤¸à¥à¤¥à¤¿à¤¤ कारà¥à¤¯à¤¾à¤¨à¥à¤µà¤¯à¤¨"
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr "कà¥à¤²à¤¾à¤à¤‚ट विभाजित"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "इनपà¥à¤Ÿ/आउटपà¥à¤Ÿ तà¥à¤°à¥à¤Ÿà¤¿"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "यà¥à¤•à¥à¤¤à¤¿ या संसाधन वà¥à¤¯à¤¸à¥à¤¤"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr "%s %uch %uHz"
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr "%0.1f GiB"
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr "%0.1f MiB"
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr "%0.1f KiB"
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr "%u B"
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr "XOpenDisplay() विफल"
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr "कà¥à¤•ी आंकड़ा के विशà¥à¤²à¥‡à¤·à¤£ में विफल"
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr "विनà¥à¤¯à¤¾à¤¸ फ़ाइल '%s' खोलने में विफल: %s"
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr "कोई कà¥à¤•ी नहीं लोड किया गया. इसके बिना कनेकà¥à¤Ÿ करने की कोशिश कर रहा हूà¤."
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr "fork(): %s"
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr "waitpid(): %s"
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr "अजà¥à¤žà¤¾à¤¤ विसà¥à¤¤à¤¾à¤° '%s' के लिठसंदेश पà¥à¤°à¤¾à¤ªà¥à¤¤"
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® से खींचने में विफल: %s"
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "पà¥à¤²à¥‡à¤¬à¥ˆà¤• सà¥à¤Ÿà¥à¤°à¥€à¤® खतà¥à¤®."
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "सरà¥à¤µà¤° में कनेकà¥à¤¶à¤¨ ले जा रहा है."
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() विफल: %s"
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() विफल: %s"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() विफल: %s"
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® सफलतापूरà¥à¤µà¤• निरà¥à¤®à¤¿à¤¤."
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() विफल: %s"
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "बफ़र मेटà¥à¤°à¤¿à¤•à¥à¤¸: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "बफ़र मेटà¥à¤°à¤¿à¤•à¥à¤¸: maxlength=%u, fragsize=%u"
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "नमूना सà¥à¤ªà¥‡à¤• '%s' का पà¥à¤°à¤¯à¥‹à¤—, चैनल मैप '%s'."
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "यà¥à¤•à¥à¤¤à¤¿ %s (%u, %ssuspended) से कनेकà¥à¤Ÿà¥‡à¤¡."
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® तà¥à¤°à¥à¤Ÿà¤¿: %s"
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® यà¥à¤•à¥à¤¤à¤¿ सà¥à¤¥à¤—ित.%s "
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® यà¥à¤•à¥à¤¤à¤¿ पà¥à¤¨à¤°à¥à¤¬à¤¹à¤¾à¤².%s "
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® अंडररन.%s "
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® ओवररन.%s"
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® आरंभ.%s"
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® यà¥à¤•à¥à¤¤à¤¿ %s (%u, %ssuspended).%s में खिसकाया गया"
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "नहीं "
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® बफ़र गà¥à¤£ परिवरà¥à¤¤à¤¿à¤¤.%s "
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr "कनेकà¥à¤¶à¤¨ सà¥à¤¥à¤¾à¤ªà¤¿à¤¤.%s "
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() विफल: %s"
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() विफल: %s"
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() विफल: %s"
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr "कनेकà¥à¤¶à¤¨ विफल.%s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF पाया."
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr "write() विफल: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "संकेत पाया, निकल रहा है."
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr "लेटेंसी पाने में विफल: %s"
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "समय: %0.3f सेकेंड; लैटेंसी: %0.0f usec."
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() विफल: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pacat %s\n"
+"लिबपलà¥à¤¸ %s के साथ कंपाइल\n"
+"लिबपलà¥à¤¸ %s के साथ लिंक\n"
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr "अवैध कà¥à¤²à¤¾à¤‡à¤‚ट नाम '%s'"
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr "अवैध सà¥à¤Ÿà¥à¤°à¥€à¤® नाम '%s'"
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr "अवैध चैनल मानचितà¥à¤° '%s'"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr "अवैध लैटेंसी विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ '%s'"
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "अवैध पà¥à¤°à¤•à¥à¤°à¤¿à¤¯à¤¾ समय विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ '%s'"
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr "अवैध गà¥à¤£ '%s'"
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "अजà¥à¤žà¤¾à¤¤ फ़ाइल पà¥à¤°à¤¾à¤°à¥‚प %s."
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "अवैध नमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾"
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr "open(): %s"
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "कई वितरà¥à¤•."
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "फ़ाइल के लिठनमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ पाने में विफल."
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "धà¥à¤µà¤¨à¤¿ फ़ाइल खोलने में विफल."
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "चेतावनी: निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ नमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ को फ़ाइल की विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ से लिखा जाà¤à¤—ा."
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "फ़ाइल से नमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ निरà¥à¤§à¤¾à¤°à¤¿à¤¤ करने में विफल."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "चेतावनी: फ़ाइल से चैनल मैप पाने में विफल."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "चैनल मैप नमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ से मेल नहीं खाता है"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "चेतावनी: फ़ाइल में चैनल मैप लिखने में विफल."
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "किसी %s सà¥à¤Ÿà¥à¤°à¥€à¤® को किसी नमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤¤à¤¾ '%s' और चैनल मैप '%s' से खोल रहा है."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "रिकारà¥à¤¡à¤¿à¤‚ग"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "पà¥à¤²à¥‡à¤¬à¥ˆà¤•"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() विफल."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() विफल."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() विफल."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() विफल: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() विफल."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() विफल."
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr "fork(): %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr "सà¥à¤¥à¤—न में विफल: %s\n"
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr "पà¥à¤¨à¤°à¥à¤¬à¤¹à¤¾à¤²à¥€ में विफल: %s\n"
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr "चेतावनी: धà¥à¤µà¤¨à¤¿ सरà¥à¤µà¤° सà¥à¤¥à¤¾à¤¨à¥€à¤¯ नहीं है, सà¥à¤¥à¤—ित नहीं कर रहा है.\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "कनेकà¥à¤¶à¤¨ विफल.%s \n"
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr "SIGINT पाया, निकल रहा है.\n"
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr "चेतावनी: संतति पà¥à¤°à¤•à¥à¤°à¤¿à¤¯à¤¾ %u संकेत से रूका\n"
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pasuspender %s\n"
+"लिबपलà¥à¤¸ %s से कंपाइल\n"
+"लिबपलà¥à¤¸ %s से कड़ीबदà¥à¤§\n"
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() विफल.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() विफल.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() विफल.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "आंकड़े पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr "पà¥à¤°à¤¯à¥‹à¤— में मà¥à¤¦à¥à¤°à¤¾: %u बà¥à¤²à¥‰à¤• %s बाइट कà¥à¤² समाहित करता है.\n"
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr "संपूरà¥à¤£ जीवनचकà¥à¤° के दौरान आबंटित: %u बà¥à¤²à¥‰à¤• %s बाइट कà¥à¤² को समाहित करता है.\n"
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr "नमूना कैश आकार: %s\n"
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr "सरà¥à¤µà¤° सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+"उपयोकà¥à¤¤à¤¾ नाम: %s\n"
+"मेजबान नाम: %s\n"
+"सरà¥à¤µà¤° नाम: %s\n"
+"सरà¥à¤µà¤° संसà¥à¤•रण: %s\n"
+"तयशà¥à¤¦à¤¾ नमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾: %s\n"
+"तयशà¥à¤¦à¤¾ चैनल मानचितà¥à¤°: %s\n"
+"तयशà¥à¤¦à¤¾ सिंक: %s\n"
+"तयशà¥à¤¦à¤¾ सà¥à¤°à¥‹à¤¤: %s\n"
+"कà¥à¤•ी: %08x\n"
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr "सिंक सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorts:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tActive Port: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "सà¥à¤°à¥‹à¤¤ सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "n/a"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr "मॉडà¥à¤¯à¥‚ल सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr "कà¥à¤²à¤¾à¤‡à¤‚ट सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "कारà¥à¤¡ सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\tProfiles:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr "\tActive Profile: %s\n"
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "सिंक इनपà¥à¤Ÿ सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "सà¥à¤°à¥‹à¤¤ आउटपà¥à¤Ÿ सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "नमूना सूचना पाने में विफल: %s"
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "विफलता: %s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "नमूना अफलोड करने में विफल: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "फ़ाइल का असामयिक अंत"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "अवैध सरà¥à¤µà¤°"
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT पाया, निकल रहा है."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pactl %s\n"
+"लिबपलà¥à¤¸ %s से कंपाइल\n"
+"लिबपलà¥à¤¸ %s से कड़ीबदà¥à¤§\n"
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "लोड करने के लिठकिसी नमूना फ़ाइल निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करें"
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "धà¥à¤µà¤¨à¤¿ फ़ाइल खोलने में विफल."
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "%s सà¥à¤Ÿà¥à¤°à¥€à¤® को किसी नमूना विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾ '%s' के साथ खोल रहा है."
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "आपको किसी नमूना नाम को बजाने के लिठनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है"
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "आपको किसी नमूना नाम को हटाने के लिठनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है"
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "आपको किसी सिंक इनपà¥à¤Ÿ सूची और सिंक को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है"
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "आपको किसी सिंक सà¥à¤°à¥‹à¤¤ आउटपà¥à¤Ÿ और सà¥à¤°à¥‹à¤¤ को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है"
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "आपको किसी मॉडà¥à¤¯à¥‚ल नाम और वितरà¥à¤• को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है"
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "आपको किसी मॉडà¥à¤¯à¥‚ल सूची को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है"
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+"आप à¤à¤• सिंक से अधिक निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ नहीं कर सकते हैं. आपको किसी बà¥à¤²à¤¿à¤¯à¤¨ मान को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr ""
+"आप à¤à¤• सà¥à¤°à¥‹à¤¤ से अधिक निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ नहीं कर सकते हैं. आपको किसी बà¥à¤²à¤¿à¤¯à¤¨ मान को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना "
+"है."
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "आपको किसी कारà¥à¤¡ नाम/सूची और पà¥à¤°à¥‹à¤«à¤¼à¤¾à¤‡à¤² नाम को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "आपको किसी कारà¥à¤¡ नाम/सूची और पोरà¥à¤Ÿ नाम को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "आपको किसी सà¥à¤°à¥‹à¤¤ नाम/सूची और पोरà¥à¤Ÿ नाम को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "आपको किसी सिंक नाम/सूची और वालà¥à¤¯à¥‚म को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "अवैध आयतन विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "आपको किसी सà¥à¤°à¥‹à¤¤ नाम/सूची और आयतन को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "आपने किसी सिंक इनपà¥à¤Ÿ सूची और आयतन को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ किया है"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "अवैध सिंक इनपà¥à¤Ÿ सूची"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "आपको किसी कारà¥à¤¡ नाम/सूची और मूक बà¥à¤²à¤¿à¤¯à¤¨ नाम को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "आपको किसी सà¥à¤°à¥‹à¤¤ नाम/सूची और मूल बà¥à¤²à¤¿à¤¯à¤¨ को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ करना है."
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "आपने किसी सिंक इनपà¥à¤Ÿ सूची और मूल बà¥à¤²à¤¿à¤¯à¤¨ को निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ किया है"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "अवैध सिंक इनपà¥à¤Ÿ सूची विनिरà¥à¤¦à¤¿à¤·à¥à¤Ÿà¤¤à¤¾"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "कोई वैध कमांड निरà¥à¤¦à¤¿à¤·à¥à¤Ÿ नहीं."
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr "कमांड लाइन के विशà¥à¤²à¥‡à¤·à¤£ में असमरà¥à¤¥.\n"
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr "सरà¥à¤µà¤°: %s\n"
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr "सà¥à¤°à¥‹à¤¤: %s\n"
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr "सिंक: %s\n"
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr "कà¥à¤•ी: %s\n"
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr "कà¥à¤•ी आंकड़ा के विशà¥à¤²à¥‡à¤·à¤£ में विफल\n"
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr "कà¥à¤•ी आंकड़ा के सहेजने में विफल\n"
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr "कà¥à¤²à¤¾à¤‡à¤‚ट विनà¥à¤¯à¤¾à¤¸ फ़ाइल लोड करने में विफल\n"
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr "वातावरण विनà¥à¤¯à¤¾à¤¸ आंकड़ा को पढ़ने में विफल.\n"
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr "FQDN पाने में विफल.\n"
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr "कà¥à¤•ी आंकड़ा लोड करने में विफल\n"
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr "अभी तक कारà¥à¤¯à¤¾à¤¨à¥à¤µà¤¿à¤¤ नहीं.\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "कोई पलà¥à¤¸à¤‘डियो डेमॉन चल रहा है, या चयन डेमॉन के तहत चल रहा है."
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr "connect(): %s"
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr "PulseAudio डेमॉन को मारने में विफल."
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr "डेमॉन पà¥à¤°à¤¤à¤¿à¤•à¥à¤°à¤¿à¤¯à¤¾ नहीं दे रहा है."
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr "poll(): %s"
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr "read(): %s"
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr "write(): %s"
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr "autospawn लॉक की पहà¥à¤à¤š नहीं ले सकता है."
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA ने यà¥à¤•à¥à¤¤à¤¿ में नया आंकड़ा लिखने के लिठहमें तैयार किया, लेकिन वहाठवासà¥à¤¤à¤µ में लिखने के लिठ"
+"कà¥à¤› नहीं था!\n"
+"अधिक संभव है कि यह ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' में à¤à¤• बग है. कृपया इस मà¥à¤¦à¥à¤¦à¥‡ को ALSA डेवलेपर को "
+"रिपोरà¥à¤Ÿ करें.\n"
+"हमें POLLOUT सेट के साथ तैयार किया गया है -- हालांकि परवरà¥à¤¤à¥€ snd_pcm_avail() ने 0 या "
+"दूसरा मान < min_avail दिया."
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA ने यà¥à¤•à¥à¤¤à¤¿ में नया आंकड़ा पढ़ने के लिठहमें तैयार किया, लेकिन वहाठवासà¥à¤¤à¤µ में पढ़ने के लिठकà¥à¤› "
+"नहीं था!\n"
+"अधिक संभव है कि यह ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' में à¤à¤• बग है. कृपया इस मà¥à¤¦à¥à¤¦à¥‡ को ALSA डेवलेपर को "
+"रिपोरà¥à¤Ÿ करें.\n"
+"हमें POLLIN सेट के साथ तैयार किया गया है -- हालांकि परवरà¥à¤¤à¥€ snd_pcm_avail() ने 0 या "
+"दूसरा मान < min_avail दिया."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "बंद"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "उचà¥à¤š विशà¥à¤µà¤¸à¤¨à¥€à¤¯à¤¤à¤¾à¤¯à¥à¤•à¥à¤¤à¤¿ पà¥à¤²à¥‡à¤¬à¥ˆà¤• (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "उचà¥à¤š विशà¥à¤µà¤¸à¤¨à¥€à¤¯à¤¤à¤¾ कैपà¥à¤šà¤° (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "टेलिफोनी डà¥à¤¯à¥‚पà¥à¤²à¥‡à¤•à¥à¤¸ (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "पलà¥à¤¸à¤‘डियो धà¥à¤µà¤¨à¤¿ सरà¥à¤µà¤°"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "आउटपà¥à¤Ÿ यà¥à¤•à¥à¤¤à¤¿"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "इनपà¥à¤Ÿ यà¥à¤•à¥à¤¤à¤¿"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ पर ऑडियो"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "इनपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "डॉकिंग सà¥à¤Ÿà¥‡à¤¶à¤¨ इनपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "डॉकिंग सà¥à¤Ÿà¥‡à¤¶à¤¨ माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "लाइन इन"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "बाहरी माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "आंतरिक माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "रेडियो"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "वीडियो"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "सà¥à¤µà¤šà¤¾à¤²à¤¿à¤¤ पà¥à¤°à¤¾à¤ªà¥à¤¤à¤¿ नियंतà¥à¤°à¤£"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "कोई सà¥à¤µà¤šà¤¾à¤²à¤¿à¤¤ पà¥à¤°à¤¾à¤ªà¥à¤¤à¤¿ नियंतà¥à¤°à¤£ नहीं"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "बूसà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "कोई बढ़ावा नहीं"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "à¤à¤‚पà¥à¤²à¥€à¤«à¤¾à¤¯à¤°"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "कोई à¤à¤‚पà¥à¤²à¥€à¤«à¤¾à¤¯à¤° नहीं"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "बूसà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "कोई बढ़ावा नहीं"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— हेडफोन"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— इनपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— लाइन इन"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— रेडियो"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— वीडियो"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— आउटपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— हेडफोन"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— आउटपà¥à¤Ÿ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— à¤à¤•ल आउटपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सà¥à¤Ÿà¥€à¤°à¤¿à¤¯à¥‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— मोनो"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सà¥à¤Ÿà¥€à¤°à¤¿à¤¯à¥‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "डिजिटल सà¥à¤Ÿà¥€à¤°à¤¿à¤¯à¥‹ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "डिजिटल सरà¥à¤°à¤¾à¤‰à¤‚ड 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "डिजिटल सरà¥à¤°à¤¾à¤‰à¤‚ड 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "डिजिटल सरà¥à¤°à¤¾à¤‰à¤‚ड 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "डिजिटल सेटअप (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— à¤à¤•ल डà¥à¤ªà¥à¤²à¥‡à¤•à¥à¤¸"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "à¤à¤¨à¤¾à¤²à¥‰à¤— सà¥à¤Ÿà¥€à¤°à¤¿à¤¯à¥‹ डà¥à¤ªà¥à¤²à¥‡à¤•à¥à¤¸"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "डिजिटल सà¥à¤Ÿà¥€à¤°à¤¿à¤¯à¥‹ डà¥à¤ªà¥à¤²à¥‡à¤•à¥à¤¸ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "निमà¥à¤¨ आवृतà¥à¤¤à¤¿ निकासकरà¥à¤¤à¤¾"
diff --git a/po/hu.po b/po/hu.po
new file mode 100644
index 00000000..6dae81ea
--- /dev/null
+++ b/po/hu.po
@@ -0,0 +1,2652 @@
+msgid ""
+msgstr ""
+"Project-Id-Version: \n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: \n"
+"Last-Translator: KAMI <kami911@gmail.com>\n"
+"Language-Team: \n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-Language: Hungarian\n"
+"X-Poedit-Country: HUNGARY\n"
+"X-Poedit-SourceCharset: utf-8\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"A „snd_pcm_avail()†függvény visszatérési értéke váratlanul nagy értékű: %lu "
+"bájt (%lu ms).\n"
+"Ez egy hiba lehet az ALSA „%s†eszközmeghajtóban. Kérem jelentse ezt a "
+"problémát az ALSA fejlesztői felé."
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"A „snd_pcm_delay()†függvény visszatérési értéke váratlanul nagy értékű: %li "
+"bájt (%s%lu ms).\n"
+"Ez egy hiba lehet az ALSA „%s†eszközmeghajtóban. Kérem jelentse ezt a "
+"problémát az ALSA fejlesztői felé."
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"A „snd_pcm_mmap_begin()†függvény visszatérési értéke váratlanul nagy "
+"értékű: %lu bájt (%lu ms).\n"
+"Ez egy hiba lehet az ALSA „%s†eszközmeghajtóban. Kérem jelentse ezt a "
+"problémát az ALSA fejlesztői felé."
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Mindig maradjon meg legalább egy nyelőt, még ha az csak az üres nyelő."
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Látszólagos kimenet"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Látszólagos LADSPA nyelő"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nyelő neve> sink_properties=<nyelő tulajdonságai> "
+"master=<szűrendő nyelő neve> format=<sample format> rate=<mintavételezési "
+"ráta> channels=<csatornák száma> channel_map=<csatornaleképzés> "
+"plugin=<ladspa bővítmény neve> label=<ladspa bővítmény címkéje> "
+"control=<bemenetszabályzó értékek vesszővel elválasztott listája>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Órajelezett semmis nyelő"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Semmis kimenet"
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "Belső hangforrás"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "Modem"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr "Nem található az eredeti „lt_dlopen†betöltő."
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr "Nem foglalható le hely az új dl betöltő számára."
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr "Nem sikerült hozzáadni az azonnali betöltés csatolást."
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr "Szignál: %s."
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "Kilépés."
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr "Nem található a(z) „%s†felhasználó."
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr "Nem található a(z) „%s†csoport."
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr "Létező felhasználó „%s†(UID: %lu) és csoport „%s†(GID: %lu)."
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr ""
+"A(z) „%s†felhasználó GID azonosítója és „%s†csoportja nem egyezik meg."
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr "A(z) „%s†felhasználó Saját mappája nem „%sâ€. Kihagyás."
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr "Nem sikerült létrehozni a(z) „%s†fájlt: %s"
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr "Nem sikerült megváltoztatni a csoportlistát: %s"
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr "Nem sikerült megváltoztatni az GID azonosítót: %s"
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr "Nem sikerült megváltoztatni az UID azonosítót: %s"
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr "A rendszergazdai jogosultságok sikeresen visszaadva."
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr "A rendszer üzemmód nem támogatott ezen az operációs rendszeren."
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr "setrlimit(%s, (%u, %u)) meghiúsult: %s"
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr "Nem sikerült feldolgozni a parancssort."
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr "A démon nem fut."
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr "A démon a következő PID azonosítóval fut: %u"
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr "A démon kilövése nem sikerült: %s"
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr ""
+"Ez a program nincsen felkészítve arra, hogy rendszergazdai jogosultságokkal "
+"fusson (kivéve, ha a --system paraméter megadásra kerül)."
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr "Rendszergazdai jogosultságok szükségesek."
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr "--start nem támogatott rendszer üzemmód használata esetén."
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr ""
+"Futtatás rendszer üzemmódban, de a --disallow-exit paraméter nincs beállítva."
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr ""
+"Futtatás rendszer üzemmódban, de a --disallow-module-loading paraméter nincs "
+"beállítva."
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr "Futtatás rendszer üzemmódban, az SHM üzemmód forszírozott letiltása."
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr ""
+"Futtatás rendszer üzemmódban, kilépés üresjárati időtúllépés esetén "
+"beállítás forszírozott letiltása."
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr ""
+"Nem sikerült jogot szerezni az alapértelmezett ki- és bemenetre (stdio)."
+
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "Cső létrehozás meghiúsult: %s"
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr "Programindítás meghiúsult: %s"
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr "Olvasás meghiúsult: %s"
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr "A démon elindítása nem sikerült."
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr "A démon sikeresen elindult."
+
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "Olvasás meghiúsult: %s"
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr "PulseAudio %s"
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr "Összeépítő számítógép: %s"
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr "Összeépítési CFLAGS jelzők: %s"
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr "Kiszolgáló: %s"
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr "%u CPU található a rendszerben."
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr "Oldalméret: %lu bájt"
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr "Összeépítés Valgrind támogatással: Igen"
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr "Összeépítés Valgrind támogatással: Nem"
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr "Futás Valgrind üzemmódban: %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Kiszolgáló: %s"
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr "Optimalizált összeépítés: Igen"
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr "Optimalizált összeépítés: Nem"
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr "NDEBUG megadva, minden érvényesítés letiltva."
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr "FASTPATH megadva, így csak a gyors útvonal-érvényesítés lesz letiltva."
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr "Minden érvényesítés engedélyezve."
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr "Nem sikerült lekérdezni a számítógép azonosítóját"
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr "Számítógép-azonosító: %s."
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr "Munkamenet-azonosító: %s."
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr "A futásidőben használt mappa: %s."
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr "Az állapottároló mappa: %s."
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "A modulok mappája: %s."
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr "Futás rendszer üzemmódban: %s"
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"A PulseAudio rendszer üzemmódban fut. Ãltalánosságban ezen üzemmód "
+"használata nem ajánlott.\n"
+"Ha mindenképpen ilyen üzemmódban kívánja futtatni a PulseAudio rendszert, ne "
+"lepődjön meg, ha egyes funkciók esetleg nem az elvárások szerint működnek.\n"
+"További tájékoztatás: http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode "
+"amelyből megtudhatja miért nem tanácsos a rendszer üzemmód használata."
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr "A „pa_pid_file_create()†függvényhívás meghiúsult: %s"
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr "A nagypontosságú időzítők elérhetőek."
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr ""
+"A nagypontosságú időzítők nem érhetőek el. Napjaink Linux rendszereiben "
+"érdemes engedélyezni a nagypontosságú időzítőket."
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr "A „pa_core_new()†függvényhívás meghiúsult: %s"
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr "Nem sikerült előkészíteni a démont."
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr ""
+"A démont noha elindult, de nem töltött be modulokat, így a hangrendszer nem "
+"üzemképes."
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr "A démon elindítása sikeres."
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr "A démon leállítása kezdeményezve."
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr "A démon leállítva."
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr "--daemonize paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr "--fail paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+"--log-level paraméter a naplózás szintjének értékét várja el (Ez lehet a "
+"0..4 számtartomány, vagy a következők egyike: debug, info, notice, warn, "
+"error)."
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr "--high-priority paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr "--realtime paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr "--disallow-module-loading paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr "--disallow-exit paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr "--use-pid-file paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr ""
+"Érvénytelen naplózási cél: használja a „syslogâ€, a „stderr†vagy az „auto†"
+"értéket."
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr "--log-time paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr "--log-meta paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr "Érvénytelen újramintavételezési eljárás: „%sâ€."
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr "--system paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr "--no-cpu-limit paraméter logikai értéket vár el"
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr "--disable-shm paraméter logikai értéket vár el"
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr "Név: %s\n"
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr "Nem áll rendelkezésre modul információ.\n"
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr "Verzió: %s\n"
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr "Leírás: %s\n"
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr "Szerző: %s\n"
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr "Használat: %s\n"
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr "Betöltve: %s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "VISSZAVONÃSI FIGYELMEZTETÉS: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr "Elérési útvonal: %s\n"
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr "[%s:%u] Érvénytelen naplózási cél: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr "[%s:%u] Érvénytelen naplózási szint: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr "[%s:%u] Érvénytelen újramintavételezési eljárás: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr "[%s:%u] Érvénytelen rlimit érték: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr "[%s:%u] Az rlimit nem támogatott ezen az operációs rendszeren."
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr "[%s:%u] Érvénytelen mintavételi formátum: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr "[%s:%u] Érvénytelen mintavételi ráta: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr "[%s:%u] Érvénytelen minta csatornák: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr "[%s:%u] Érvénytelen csatornaleképzés: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr "[%s:%u] Érvénytelen a részek száma: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr "[%s:%u] Érvénytelen a részek mérete: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr "[%s:%u] Érvénytelen a prioritási érték: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Érvénytelen mintavételi ráta: „%sâ€."
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr "Nem sikerült megnyitni a konfigurációs fájlt: %s"
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr ""
+"Az alapértelmezetten megadott mintavételi leírás csatornáinak száma eltér az "
+"alapértelmezetten megadott csatornaszámtól."
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr "### Olvasás a következő konfigurációs fájlból: %s ###\n"
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Jogosultságok letisztázása."
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "PulseAudio hangrendszer"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "A PulseAudio hangrendszer elindítása"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "Mono"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "Első középső"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "Első bal"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "Első jobb"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "Hátsó középső"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "Hátsó bal"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "Hátsó jobb"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr "Első közép-bal"
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr "Első közép-jobb"
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "Bal oldalsó"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "Jobb oldalsó"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr "Külső 0"
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr "Külső 1"
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr "Külső 2"
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr "Külső 3"
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr "Külső 4"
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr "Külső 5"
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr "Külső 6"
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr "Külső 7"
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr "Külső 8"
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr "Külső 9"
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr "Külső 10"
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr "Külső 11"
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr "Külső 12"
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr "Külső 13"
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr "Külső 14"
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr "Külső 15"
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr "Külső 16"
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr "Külső 17"
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr "Külső 18"
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr "Külső 19"
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr "Külső 20"
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr "Külső 21"
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr "Külső 22"
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr "Külső 23"
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr "Külső 24"
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr "Külső 25"
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr "Külső 26"
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr "Külső 27"
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr "Külső 28"
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr "Külső 29"
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr "Külső 30"
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr "Külső 31"
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "Felső középső"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "Felső első középső"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "Felső első bal"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "Felső első jobb"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "Felső hátsó középső"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "Felső hátsó bal"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "Felső hátsó jobb"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "(Érvénytelen)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "Sztereó"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "Térhatású 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "Térhatású 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "Térhatású 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "Térhatású 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "Térhatású 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "OK"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "Hozzáférés megtagadva"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr "Ismeretlen parancs"
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr "Érvénytelen paraméter"
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr "Az egység létezik"
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr "Nincs ilyen egység"
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "Kapcsolat elutasítva"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "Protokollhiba"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr "Időtúllépés"
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr "Nem érhető el hitelesítőkulcs"
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "Belső hiba"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr "A kapcsolat megszakadt."
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr "Egység kilőve"
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr "Érvénytelen kiszolgáló"
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr "A modul előkészítése meghiúsult."
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr "Hibás állapot"
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr "Nincs adat"
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr "Inkompatibilis protokollverzió"
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "Túl nagy"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "Nem támogatott"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "Ismeretlen hibakód"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr "Nincs ilyen kiterjesztés"
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr "Elavult funkcionalitás"
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr "Nincs megvalósítva"
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr "Kliens elindítva"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Kimeneti/bemeneti hiba"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Az eszköz vagy erőforrás foglalt"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr "%s %uch %uHz"
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr "%0.1f GiB"
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr "%0.1f MiB"
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr "%0.1f KiB"
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr "%u B"
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr "Az XOpenDisplay() függvényhívás meghiúsult."
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr "Nem sikerült feldolgozni a süti adatokat."
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr "Nem sikerült megnyitni a(z) „%s†konfigurációs fájlt: %s"
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr ""
+"Nincs betölthető süti. Kísérlet a kapcsolat felvételére sütik használata "
+"nélkül."
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr "Programindítás: %s"
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr "waitpid(): %s"
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr "Üzenet érkezett az ismeretlen „%s†kiterjesztéstől"
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr "Nem sikerült csatlakozni a következő adatfolyamhoz: %s"
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "A lejátszás adatfolyamához csatlakozva."
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Csatlakozás a kiszolgálóhoz kapcsolathoz."
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr "A „pa_stream_write()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "A „pa_stream_begin_write()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr "A „pa_stream_peek()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Az adatfolyam sikeresen létrejött."
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "A „pa_stream_get_buffer_attr()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr ""
+"Pufferméretek: maximális nagyság: %u, hossz: %u, előpufferelés: %u, minimum: "
+"%u"
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Pufferméretek: maximális nagyság: %u, részek mérete: %u"
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Mintavételi leírás: „%s†és csatornaleképzés: „%s†használata."
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Csatlakozva a következő eszközhöz: „%s†(%u, %ssuspended)."
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr "Adatfolyam hiba: %s"
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr "Adatfolyam-eszköz készenléti állapotban: %s"
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr "Adatfolyam-eszköz visszatért a készenléti állapotból: %s"
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr "%s adatfolyam alulcsordulás."
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr "%s adatfolyam túlcsordulás."
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr "%s adatfolyam elindítva."
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr ""
+"Az adatfolyam áthelyezve a következő eszközre: „%s†(%u, %ssuspended). %s"
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "nem"
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr "Az adatfolyam-puffer beállításai megváltoztak: %s"
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr "Kapcsolat létrehozva. %s"
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr "A „pa_stream_new()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "A „pa_stream_connect_playback()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "A „pa_stream_connect_record()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr "Kapcsolódási hiba: %s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "A fájl vége elérve."
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr "Az írás sikertelen: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Kilépés, szignál hatására…"
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr "Nem sikerült lekérdezni a késleltetést: %s"
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Idő: %0.3f másodperc, késleltetés: %0.0f ezredmásodperc."
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "A „pa_stream_update_timing_info()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+"%s [KAPCSOLÓ]\n"
+"\n"
+" -h, --help Ezen súgó megjelenítése\n"
+" --version Az alkalmazás verziószámának "
+"megjelenítése\n"
+"\n"
+" -r, --record Kapcsolat létrehozása felvételhez\n"
+" -p, --playback Kapcsolat létrehozása lejátszáshoz\n"
+"\n"
+" -v, --verbose Történések részletezése\n"
+"\n"
+" -s, --server=KISZOLGÃLÓ Kapcsolódás a megadott "
+"KISZOLGÃLÓ kiszolgálóhoz\n"
+" -d, --device=ESZKÖZ Kapcsolódás az ESZKÖZ nevű nyelőhöz "
+"vagy forráshoz\n"
+" -n, --client-name=NÉV A kliens neve ezen a szerveren\n"
+" --stream-name=NÉV Adatfolyam neve a kiszolgálón\n"
+" --volume=HANGERŠKezdeti (lineáris) hangerő megadása "
+"a következő tartományban: 0...65536\n"
+" --rate=MINTAVÉTEL Mintavételezés érzéke Hz-ben "
+"(alapértelmezés: 44100)\n"
+" --format=MINTAFORMÃTUM A mintavétel típusa a "
+"következőkből: s16le, s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (alapértelmezés: "
+"s16ne)\n"
+" --channels=CSATORNÃK Csatornák száma: 1 - mono, 2 - "
+"sztereó\n"
+" (defaults to 2)\n"
+" --channel-map=CSATORNALEKÉPZÉS Az alapértelmezés helyett "
+"használandó csatornaleképzés\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Nyers PCM adatok felvétele vagy "
+"lejátszása.\n"
+" --file-format=FORMÃTUM FORMÃTUM alakú PCM adatok felvétele "
+"vagy lejátszása.\n"
+" --list-file-formats Elérhető fájlformátumok listája.\n"
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pacat %s\n"
+"Összeépítve a libpulse %s programkönyvtárral\n"
+"Csatolva a libpulse %s programkönyvtárhoz\n"
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr "Érvénytelen kliensnév: „%sâ€"
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr "Érvénytelen adatfolyam-név: „%sâ€"
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr "Érvénytelen csatornaleképzés: „%sâ€"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr "Érvénytelen késleltetés leírás: „%sâ€"
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "Érvénytelen műveleti idÅ‘ leírás: „%sâ€"
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr "Érvénytelen tulajdonság: „%sâ€"
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Ismeretlen fájlformátum: „%sâ€"
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Érvénytelen mintavételi leírás."
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr "Megnyitás: %s"
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Túl sok paraméter."
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Nem sikerült létrehozni a mintavételi leírást a fájlhoz."
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Nem sikerült megnyitni a hangfájlt."
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Figyelmeztetés: a megadott mintavételi leírás felül lesz írva a fájlból "
+"származó mintavételi leírással."
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Nem sikerült meghatározni a mintavételi leírást a fájlból."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr ""
+"Figyelmeztetés: Nem sikerült meghatározni a csatornaleképzést a fájlból."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "A csatornaleképzés nem feleltethető meg a mintavételi leírásnak."
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Hiba történt a csatornaleképzés fájlba írása közben."
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"A(z) „%s†adatfolyam megnyitása a következő mintavételi leírás: „%s†és "
+"csatornaleképzés: „%s†használatával."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "Felvétel"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "Lejátszás"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "A „pa_mainloop_new()†függvényhívás meghiúsult."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "A „io_new()†függvényhívás meghiúsult."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "A „pa_context_new()†függvényhívás meghiúsult."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr "A „pa_context_connect()†függvényhívás meghiúsult: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "A „pa_context_rttime_new()†függvényhívás meghiúsult."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "A „pa_mainloop_run()†függvényhívás meghiúsult."
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr "Programindítás: %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr "Hiba lépett fel a készenléti állapotba térés közben: %s\n"
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr "Hiba lépett fel a készenléti állapotból visszatérés közben: %s\n"
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr ""
+"FIGYELMEZTETÉS: A hangkiszolgáló nem helyi és nincs is felfüggesztve.\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Kapcsolódási hiba: %s\n"
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr "Kilépés, SIGINT szignál hatására…\n"
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr ""
+"FIGYELMEZTETÉS: A gyermek folyamat a következő szignállal fejeződött be: %u\n"
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+"%s [KAPCSOLÓ] ... \n"
+"\n"
+" -h, --help Megjeleníti ezt a súgót\n"
+" --version Az alkalmazás verziószámának "
+"megjelenítése\n"
+"\n"
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pasuspender %s\n"
+"Összeépítve a libpulse %s programkönyvtárral\n"
+"Csatolva a libpulse %s programkönyvtárhoz\n"
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "A „pa_mainloop_new()†függvényhívás meghiúsult.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "A „pa_context_new()†függvényhívás meghiúsult.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "A „pa_mainloop_run()†függvényhívás meghiúsult.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Nem sikerült a statisztika lekérdezése: %s"
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr ""
+"Jelenleg lefoglalt blokkok száma: %u, amely összesen %s bájtot jelent.\n"
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr ""
+"A futás során összesen lefoglalt blokkok száma: %u, amely összesen %s bájtot "
+"jelent.\n"
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr "Minta-gyorsítótár mérete: %s\n"
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr "Nem sikerült lekérdezni a kiszolgáló adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+"Felhasználónév: %s\n"
+"Számítógépnév: %s\n"
+"Kiszolgálónév: %s\n"
+"Kiszolgáló verzió: %s\n"
+"Alapértelmezett mintavételi leírás: %s\n"
+"Alapértelmezett csatornaleképzés: %s\n"
+"Alapértelmezett nyelő: %s\n"
+"Alapértelmezett forrás: %s\n"
+"Süti: %08x\n"
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr "Nem sikerült lekérdezni a nyelÅ‘ adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Nyelő #%u\n"
+"\tÃllapot: %s\n"
+"\tNév: %s\n"
+"\tLeírás: %s\n"
+"\tEszközmeghajtó: %s\n"
+"\tMintavételi leírás: %s\n"
+"\tCsatornaleképzés: %s\n"
+"\tTulajdonos modul: %u\n"
+"\tNémítás: %s\n"
+"\tHangerő: %s%s%s\n"
+"\t egyensúly %0.2f\n"
+"\tAlap hangerő: %s%s%s\n"
+"\tMonitor forrás: %s\n"
+"\tKésleltetés: %0.0f ezredmásodperc, beállítva %0.0f ezredmásodperc\n"
+"\tJelzők: %s%s%s%s%s%s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPort:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tAktív Port: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Nem sikerült lekérdezni a forrás adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Forrás #%u\n"
+"\tÃllapot: %s\n"
+"\tNév: %s\n"
+"\tLeírás: %s\n"
+"\tEszközmeghajtó: %s\n"
+"\tMintavételi leírás: %s\n"
+"\tCsatornaleképzés: %s\n"
+"\tTulajdonos modul: %u\n"
+"\tNémítás: %s\n"
+"\tHangerő: %s%s%s\n"
+"\t egyensúly %0.2f\n"
+"\tAlap hangerő: %s%s%s\n"
+"\tNyelő monitora: %s\n"
+"\tKésleltetés: %0.0f ezredmásodperc, beállítva %0.0f ezredmásodperc\n"
+"\tJelzők: %s%s%s%s%s%s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "ismeretlen"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr "Nem sikerült lekérdezni a modul adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Modul #%u\n"
+"\tNév: %s\n"
+"\tParaméter: %s\n"
+"\tHasználva: %s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr "Nem sikerült lekérdezni a kliens adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Kliens #%u\n"
+"\tEszközmeghajtó: %s\n"
+"\tTulajdonos modul: %s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "Nem sikerült lekérdezni a kártya adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Kártya #%u\n"
+"\tNév: %s\n"
+"\tEszközmeghajtó: %s\n"
+"\tTulajdonos modul: %s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\tProfil:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr "\tAktív profil: %s\n"
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "Nem sikerült lekérdezni a nyelÅ‘ bemeneti adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Nyelő bemenet #%u\n"
+"\tEszközmeghajtó: %s\n"
+"\tTulajdonos modul: %s\n"
+"\tKliens: %s\n"
+"\tNyelő: %u\n"
+"\tMintavételi leírás: %s\n"
+"\tCsatornaleképzés: %s\n"
+"\tNémítás: %s\n"
+"\tHangerő: %s\n"
+"\t %s\n"
+"\t egyensúly %0.2f\n"
+"\tPuffer késleltetés: %0.0f usec\n"
+"\tNyelő késleltetés: %0.0f usec\n"
+"\tÚjramintavételezési eljárás: %s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "Nem sikerült lekérdezni a forrás kimeneti adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Forrás kimenet #%u\n"
+"\tEszközmeghajtó: %s\n"
+"\tTulajdonos modul: %s\n"
+"\tKliens: %s\n"
+"\tForrás: %u\n"
+"\tMintavételi leírás: %s\n"
+"\tCsatornaleképzés: %s\n"
+"\tPuffer késleltetés: %0.0f usec\n"
+"\tForrás késleltetés: %0.0f usec\n"
+"\tÚjramintavételezési eljárás: %s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "Nem sikerült lekérdezni a mintavétel adatait: „%sâ€"
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Minta #%u\n"
+"\tNév: %s\n"
+"\tMintavételi leírás: %s\n"
+"\tCsatornaleképzés: %s\n"
+"\tHangerő: %s\n"
+"\t %s\n"
+"\t egyensúly %0.2f\n"
+"\tIdőtartam: %0.1fs\n"
+"\tMéret: %s\n"
+"\tLassú: %s\n"
+"\tFájlnév: %s\n"
+"\tTulajdonságok:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "Hiba: %s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "Nem sikerült feltölteni a mintát: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Idő előtti fájlvége"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Érvénytelen kiszolgáló"
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Kilépés, SIGINT szignál hatására…"
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FÃJLNÉV [NÉV]\n"
+"%s [options] play-sample NÉV [NYELÅ]\n"
+"%s [options] remove-sample NÉV\n"
+"%s [options] move-sink-input NYELÅBEMENET NYELÅ\n"
+"%s [options] move-source-output FORRÃSKIMENET FORRÃS\n"
+"%s [options] load-module NÉV [PARAMÉTEREK ...]\n"
+"%s [options] unload-module MODUL\n"
+"%s [options] suspend-sink NYELÅ 1|0\n"
+"%s [options] suspend-source FORRÃS 1|0\n"
+"%s [options] set-card-profile KÃRTYA PROFIL\n"
+"%s [options] set-sink-port NYELÅ PORT\n"
+"%s [options] set-source-port FORRÃS PORT\n"
+"%s [options] set-sink-volume NYELÅ HANGERÅ\n"
+"%s [options] set-source-volume FORRÃS HANGERÅ\n"
+"%s [options] set-sink-input-volume NYELÅBEMENET HANGERÅ\n"
+"%s [options] set-sink-mute NYELÅ 1|0\n"
+"%s [options] set-source-mute FORRÃS 1|0\n"
+"%s [options] set-sink-input-mute NYELÅBEMENET 1|0\n"
+"\n"
+" -h, --help Megjeleníti ezt a súgót\n"
+" --version Az alkalmazás verziószámának "
+"megjelenítése\n"
+"\n"
+" -s, --server=KISZOLGÃLÓ Kapcsolódás a megadott "
+"KISZOLGÃLÓ kiszolgálóhoz\n"
+" -n, --client-name=NÉV A kliens neve ezen a szerveren\n"
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pactl %s\n"
+"Összeépítve a libpulse %s programkönyvtárral\n"
+"Csatolva a libpulse %s programkönyvtárhoz\n"
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Adja meg a betöltendő mintafájlt"
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Nem sikerült megnyitni az hangfájlt."
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+"Figyelmeztetés: Nem sikerült meghatározni a mintavételi leírást a fájlból."
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Meg kell adnia lejátszandó minta nevét."
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Meg kell adnia az eltávolítandó minta nevét."
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Meg kell adnia a nyelő bemeneti azonosítóját és a nyelőt."
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Meg kell adnia a forrás kimeneti azonosítóját és a forrást."
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Meg kell adnia a modul nevét és a paramétereit."
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Meg kell adnia a modul azonosítóját."
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr "Nem adhat meg egynél több nyelőt. Egy logikai értéket kell megadnia."
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr "Nem adhat meg egynél több forrást. Egy logikai értéket kell megadnia."
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Meg kell adnia a kártya nevét vagy azonosítóját és a profil nevét"
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Meg kell adnia a nyelő nevét vagy azonosítóját és a port nevét."
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Meg kell adnia a forrás nevét vagy azonosítóját és a port nevét"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Meg kell adnia a nyelő nevét vagy azonosítóját és a hangerejét."
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "A hangerő megadása érvénytelen."
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Meg kell adnia a forrás nevét vagy azonosítóját és a hangerejét"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Meg kell adnia a nyelő bemenet azonosítóját és a hangerejét"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "A nyelő bemeneti azonosítója érvénytelen."
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+"Meg kell adnia a nyelő nevét vagy azonosítóját és a némítás logikai "
+"változóját."
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr ""
+"Meg kell adnia a forrás nevét vagy azonosítóját és a némítás logikai "
+"változóját"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+"Meg kell adnia a nyelő bemenet azonosítóját és a némítás logikai változóját"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "A nyelő bemeneti azonosítójának megadása érvénytelen."
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Érvénytelen parancs lett megadva."
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+"%s [-D megjelenítő] [-S kiszolgáló] [-O nyelő] [-I forrás] [-c fájl] [-d|-"
+"e|-i|-r]\n"
+"\n"
+" -d Megjeleníti az aktuális X11 megjelenítőhöz csatlakoztatott PulseAudio "
+"adatokat (alapértelmezés)\n"
+" -e Helyi PulseAudio adatok exportálása az X11 megjelenítőre\n"
+" -i Helyi PulseAudio adatok importálása az X11 megjelenítőről helyi "
+"környezeti változókba és süti fájlokba\n"
+" -r Eltávolítja a PulseAudio adatokat z X11 megjelenítőről\n"
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr "Nem sikerült feldolgozni a parancssort.\n"
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr "Kiszolgáló: %s\n"
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr "Forrás: %s\n"
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr "Nyelő: %s\n"
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr "Süti: %s\n"
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr "Nem sikerült feldolgozni a süti adatokat.\n"
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr "Nem sikerült elmenteni a süti adatokat.\n"
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr "Nem sikerült betölteni a kliens konfigurációs fájlt.\n"
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr "Nem sikerült elolvasni a környezetváltozó konfigurációs adatokat.\n"
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr "Nem sikerült lekérdezni a teljes tartománynevet (FQDN).\n"
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr "Nem sikerült betölteni a süti adatokat.\n"
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr "Még nincs elkészítve.\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "Nem fut a PulseAudio démon vagy nem fut munkamenet démonként sem."
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr "Kapcsolódás: %s"
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr "A PulseAudio démon kilövése nem sikerült."
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr "A démon nem válaszol."
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr "Lekérdezés: %s"
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr "Olvasás: %s"
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr "Ãrás: %s"
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr "Nem érhető zárolás az automatikus indításhoz."
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"Az ALSA modul értesítése nyomán új adatokat kellett volna írni az eszközre, "
+"de jelenleg semmilyen írandó adat nincsen.\n"
+"Ez egy hiba lehet az ALSA „%s†eszközmeghajtóban. Kérem jelentse ezt a "
+"problémát az ALSA fejlesztői felé.\n"
+"Az értesítés a POLLOUT jelzésen keresztül érkezett – viszont a „snd_pcm_avail"
+"()†függvény visszatérési értéke 0 volt vagy a második érték kisebb volt, "
+"mint a minimum."
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"Az ALSA modul értesítése nyomán új adatokat kellett volna olvasni az "
+"eszközről, de jelenleg semmilyen olvasandó adat nincsen.\n"
+"Ez egy hiba lehet az ALSA „%s†eszközmeghajtóban. Kérem jelentse ezt a "
+"problémát az ALSA fejlesztői felé.\n"
+"Az értesítés a POLLIN jelzésen keresztül érkezett – viszont a „snd_pcm_avail"
+"()†függvény visszatérési értéke 0 volt vagy a második érték kisebb volt, "
+"mint a minimum."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "Kikapcsolva"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "HiFi lejátszás (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "HiFi felvétel (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Telefon duplex (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "PulseAudio hangkiszolgáló"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Kimeneti eszközök"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Bemeneti eszközök"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Hangforrások a(z) @HOSTNAME@ számítógépen"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Bemenet"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Dokkolóállomás bemenet"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Dokkolóállomás mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Vonalbemenet"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Külső mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Belső mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Rádió"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Videó"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Automatikus erősítésszabályzás"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Nincs automatikus erősítésszabályzás"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Erősítés"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Nincs erősítés"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Erősítő"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Nincs erősítő"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Erősítés"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Nincs erősítés"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Analóg fejhallgató"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Analóg bemenet"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Analóg mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Analóg vonalbemenet"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Analóg rádió"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Analóg videó"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Analóg kimenet"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Analóg fejhallgató"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Analóg kimenet (mély)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analóg mono kimenet"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analóg sztereó"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analóg mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analóg sztereó"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analóg térhatású 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analóg térhatású 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analóg térhatású 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analóg térhatású 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analóg térhatású 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analóg térhatású 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analóg térhatású 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analóg térhatású 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analóg térhatású 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analóg térhatású 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analóg térhatású 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digitális sztereó (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digitális térhatású 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digitális térhatású 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digitális térhatású 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digitális térhatású (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analóg mono duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analóg sztereó duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Analóg sztereó duplex (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Mély-hangszóró (LFE)"
diff --git a/po/it.po b/po/it.po
index 27819391..1e8c4b64 100644
--- a/po/it.po
+++ b/po/it.po
@@ -3,67 +3,27 @@
# This file is distributed under the same license as the pulseaudio package.
#
# Luca Ferretti <elle.uca@libero.it>, 2008, 2009.
-# Milo Casagrande <milo@ubuntu.com>, 2009.
# mario_santagiuliana <mario at marionline.it>, 2009.
+# Milo Casagrande <milo@ubuntu.com>, 2009.
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-20 22:34+0200\n"
-"Last-Translator: mario_santagiuliana <mario at marionline.it>\n"
-"Language-Team: Italian <fedora-trans-it at redhat.com>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-18 11:46+0200\n"
+"Last-Translator: Milo Casagrande <milo@ubuntu.com>\n"
+"Language-Team: Italian <tp@lists.linux.it>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Generator: Lokalize 0.3\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Mono analogico"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Stereo analogico"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Stereo digitale (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Stereo digitale (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Surround analogico 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Surround digitale 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Surround analogico 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Surround analogico 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Surround analogico 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Surround digitale 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Surround analogico 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -72,10 +32,10 @@ msgid ""
"to the ALSA developers."
msgstr ""
"snd_pcm_avail() ha restituito un valore molto grande: %lu byte (%lu ms).\n"
-"Molto probabilmente si tratta di un bug nel driver ALSA «%s». Segnalare "
+"Molto probabilmente si tratta di un bug nel driver ALSA \"%s\". Segnalare "
"questo problema agli sviluppatori ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -84,10 +44,10 @@ msgid ""
"to the ALSA developers."
msgstr ""
"snd_pcm_delay() ha restituito un valore molto grande: %li byte (%s%lu ms).\n"
-"Molto probabilmente si tratta di un bug nel driver ALSA «%s». Segnalare "
+"Molto probabilmente si tratta di un bug nel driver ALSA \"%s\". Segnalare "
"questo problema agli sviluppatori ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -97,14 +57,48 @@ msgid ""
msgstr ""
"snd_pcm_mmap_begin() ha restituito un valore molto grande: %lu byte (%lu "
"ms).\n"
-"Molto probabilmente si tratta di un bug nel driver ALSA «%s». Segnalare "
+"Molto probabilmente si tratta di un bug nel driver ALSA \"%s\". Segnalare "
"questo problema agli sviluppatori ALSA."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Mantiene sempre almeno un sink caricato anche se è nullo"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Output dummy"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Sink LADSPA virtuale"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nome del sink> sink_properties=<proprietà del sink> master=<nome "
+"del sink da filtrare> format=<formato campionamento> rate=<frequenza "
+"campionamento> channels=<numero di canali> channel_map=<mappa canale> "
+"plugin=<nome plugin ladspa> label=<etichetta plugin ladspa> control=<valori "
+"di controllo separati da virgole>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Sink NULL temporizzato"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Output nullo"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Audio interno"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Modem"
@@ -120,222 +114,99 @@ msgstr "Allocazione del nuovo loader dl non riuscita."
msgid "Failed to add bind-now-loader."
msgstr "Aggiunta di bind-now-loader non riuscita."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Impossibile effettuare la connessione al bus di sistema: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Impossibile ottenere il chiamante dal PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Impossibile impostare l'UID sull'oggetto chiamante."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Recupero della sessione CK non riuscito."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Impossibile impostare l'UID sull'oggetto sessione."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Impossibile allocare PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Impossibile impostare action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Impossibile allocare PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Impossibile inizializzare PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Impossibile determinare se il chiamante è autorizzato: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Impossibile ottenere l'autorizzazione: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit ha risposto con \"%s\""
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Ottenuto il segnale %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Uscita."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Ricerca dell'utente \"%s\" non riuscita."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Ricerca del gruppo \"%s\" non riuscita."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Trovato l'utente \"%s\" (UID %lu) e il gruppo \"%s\" (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "Il GID dell'utente \"%s\" e del gruppo \"%s\" non corrispondono."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "La directory home dell'utente \"%s\" non è \"%s\", ignorato."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Creazione di \"%s\" non riuscita: %s"
# group list ????
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Cambio dell'elenco di gruppo non riuscito: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Cambio di GID non riuscito: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Cambio di UID non riuscito: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Privilegi di root abbandonati con successo."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
-msgstr "Modalità \"system wide\" non supportata su questa piattaforma."
+msgstr "Modalità di sistema non supportata su questa piattaforma."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) non riuscita: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Analisi della riga di comando non riuscita."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "Attualmente nel gruppo \"%s\", che consente scheduling high-priority."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "Attualmente nel gruppo \"%s\", che consente scheduling real-time."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "Privilegi acquire-high-priority assegnati da PolicyKit."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "Privilegi acquire-high-priority rifiutati da PolicyKit."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "Privilegi acquire-real-time assegnati da PolicyKit."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "Privilegi acquire-real-time rifiutati da PolicyKit."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"Lo SUID root e lo scheduling real-time o high-priority erano richiesti nella "
-"configurazione, ma mancano i privilegi necessari:\n"
-"non si è nel gruppo «%s», PolicyKit non consente di acquisire i privilegi "
-"richiesti e non è possibile incrementare i limiti RLIMIT_NICE/RLIMIT_RTPRIO "
-"della risorsa.\n"
-"Per abilitare lo scheduling real-time/high-priority, acquisire i privilegi "
-"PolicyKit appropriati, diventare un membro di «%s» oppure incrementare i "
-"limiti RLIMIT_NICE/RLIMIT_RTPRIO della risorsa per questo utente."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Scheduling high-priority abilitato nella configurazione, ma non ammesso "
-"dalla politica."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "Incremento di RLIMIT_RTPRIO riuscito"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO non riuscito: %s"
-
-# abbandono??
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Abbandono del CAP_NICE"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"Scheduling real-time abilitato nella configurazione, ma non ammesso dalla "
-"politica."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Demone non in esecuzione"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Demone in esecuzione con PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Terminazione del demone non riuscita: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -343,168 +214,204 @@ msgstr ""
"Questo programma non è pensato per essere eseguito come root (a meno di "
"specificare --system)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Richiesti privilegi di root."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start non supportato per le istanze di sistema."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "In esecuzione in modalità sistema, ma --disallow-exit non impostato."
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"In esecuzione in modalità sistema, ma --disallow-module-loading non "
"impostato."
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr ""
"In esecuzione in modalità sistema, disabilitata in modo forzoso la modalità "
"SHM."
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"In esecuzione in modalità sistema, disabilitato in modo forzoso il tempo di "
"uscita per inattività."
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Acquisizione di STDIO non riuscita."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "pipe non riuscita: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() non riuscita: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() non riuscita: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Avvio del demone non riuscito."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Avvio del demone riuscito."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() non riuscita: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Questo è PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Host di compilazione: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "CFLAGS di compilazione: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "In esecuzione sull'host: %s"
# evviva il rispetto della l10n!!!
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "Trovate %u CPU."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "La dimensione di pagina è %lu byte"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Compilato con supporto a Valgrind: sì"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Compilato con supporto a Valgrind: no"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "In esecuzione in modalità valgrind: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "In esecuzione sull'host: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Build ottimizzata: sì"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Build ottimizzata: no"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG definito, tutte le dichiarazioni sono disabilitate."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr ""
"FASTPATH definito, solo le dichiarazioni veloci di path sono disabilitate."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Tutte le dichiarazioni sono abilitate."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Recupero dell'ID della macchina non riuscito"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "L'ID della macchina è %s"
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "L'ID della macchina è %s"
+msgstr "L'ID della sessione è %s"
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "In uso directory di runtime %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "In uso directory di stato %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "In uso directory dei moduli %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "In esecuzione in modalità sistema: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"PulseAudio è in esecuzione in modalità sistema. È sconsigliato eseguire "
+"PulseAudio in questa modalità.\n"
+"Continuando a usarlo in questo modo molte cose potrebbero non funzionare "
+"come atteso.\n"
+"Consultare http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode per maggiori "
+"informazioni sul perché la modalità sistema è una pessima idea."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() non riuscita."
# io mi domando e dico..... mah!
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Disponibili timer high-resolution freschi freschi! Buon appetito!"
# $REPEAT_PREVIOUS_COMMENT_HERE
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -512,32 +419,32 @@ msgstr ""
"Hey, questo kernel è andato a male! Lo chef oggi raccomanda Linux con i "
"timer high-resolution abilitati!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() non riuscita."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Inizializzazione del demone non riuscita."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Avvio del demone senza alcun modulo caricato, rifiuta di lavorare."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "Completato l'avvio del demone."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Iniziato l'arresto del demone."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Demone terminato."
# mamma mia che impressione
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -612,7 +519,7 @@ msgid ""
msgstr ""
"%s [OPZIONI]\n"
"\n"
-"COMMANDI:\n"
+"COMANDI:\n"
" -h, --help Mostra questo aiuto\n"
" --version Mostra la versione\n"
" --dump-conf Riversa la configurazione "
@@ -676,7 +583,7 @@ msgstr ""
" --log-time[=BOOL] Include i marcatempo nei messaggi "
"di\n"
" registro\n"
-" --log-backtrace=FRAMES Include un backtrace nei messaggi "
+" --log-backtrace=FRAME Include un backtrace nei messaggi "
"di \n"
" registro\n"
" -p, --dl-search-path=PERCORSO Imposta il percorso di ricerca per "
@@ -709,15 +616,15 @@ msgstr ""
" -n Non carica il file script "
"predefinito\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -726,54 +633,54 @@ msgstr ""
"nell'intervallo numerico 0..4 oppure uno tra debug, info, notice, warn, "
"error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"Destinazione del registro non valida: usare \"syslog\", \"stderr\" o \"auto"
"\"."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Metodo di ricampionamento \"%s\" non valido."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit richiede un argomento booleano"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm richiede un argomento booleano"
@@ -813,78 +720,88 @@ msgstr "Uso: %s\n"
msgid "Load Once: %s\n"
msgstr "Caricato una sola volta: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "ATTENZIONE, DEPRECATI: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Percorso: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Destinazione di registro \"%s\" non valida."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Livello di registro \"%s\" non valido."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Metodo di ricampionamento \"%s\" non valido."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] rlimit \"%s\" non valido."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit non supportato su questa piattaforma."
# o campionamento?? ma campionamento non è sampling?
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Formato di campionamento \"%s\" non valido."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Frequenza di campionamento '%s' non valida."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Canali di campionamento \"%s\" non validi."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Mappa del canale \"%s\" non valida."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Numero di frammenti \"%s\" non valido."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Dimensione dei frammenti \"%s\" non valida."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Livello di nice \"%s\" non valido."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Frequenza di campionamento '%s' non valida."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Apertura del file di configurazione non riuscita: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -892,18 +809,14 @@ msgstr ""
"La mappa del canale predefinita specificata presenta un numero diverso di "
"canali rispetto a quello predefinito specificato."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Lettura dal file di configurazione: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Abbandono dei privilegi di root."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Limitazione delle capacità a CAP_SYS_NICE riuscita."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Abbandono dei privilegi."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -913,263 +826,239 @@ msgstr "Sistema sonoro PulseAudio"
msgid "Start the PulseAudio Sound System"
msgstr "Avvia il sistema sonoro PulseAudio"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"Scheduling high-priority (valori negativi di \"nice\") per il demone "
-"PulseAudio"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Scheduling realt-time per il demone PulseAudio"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"La politica di sistema previene PulseAudio dall'ottenere lo scheduling high-"
-"priority."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"La politica di sistema previene PulseAudio dall'ottenere lo scheduling real-"
-"time."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
# frontale centrale non si usa in HiFi
# solo centrale.
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Centrale"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Frontale sinistro"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Frontale destro"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Centrale posteriore"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Posteriore sinistro"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Posteriore destro"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Emettitore basse frequenze"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Frontale sinistra-del-centro"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Frontale destra-del-centro"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Laterale sinistro"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Laterale destro"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Ausiliario 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Ausiliario 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Ausiliario 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Ausiliario 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Ausiliario 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Ausiliario 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Ausiliario 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Ausiliario 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Ausiliario 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Ausiliario 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Ausiliario 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Ausiliario 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Ausiliario 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Ausiliario 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Ausiliario 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Ausiliario 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Ausiliario 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Ausiliario 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Ausiliario 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Ausiliario 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Ausiliario 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Ausiliario 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Ausiliario 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Ausiliario 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Ausiliario 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Ausiliario 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Ausiliario 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Ausiliario 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Ausiliario 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Ausiliario 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Ausiliario 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Ausiliario 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Centrale superiore"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Superiore frontale centrale"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Superiore frontale sinistro"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Superiore frontale destro"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Superiore posteriore centrale"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Superiore posteriore sinistro"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Superiore posteriore destro"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(non valido)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Surround 7.1"
@@ -1273,27 +1162,35 @@ msgstr "Implementazione mancante"
msgid "Client forked"
msgstr "Fork del client"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Errore di input/output"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Dispositivo o risorsa occupata"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s ch %u %u Hz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1306,200 +1203,194 @@ msgstr "XOpenDisplay() non riuscita"
msgid "Failed to parse cookie data"
msgstr "Analisi dei dati cookie non riuscita"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Apertura del file di configurazione \"%s\" non riuscita: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Nessun cookie caricato. Tentativo di connettersi senza."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Ricevuto messaggio per l'estensione sconosciuta \"%s\""
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() non riuscita: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Svuotamento dello stream non riuscito: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() non riuscita: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Stream di riproduzione svuotato."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Creazione dello stream riuscita.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Svuotamento della connessione sul server."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() non riuscita: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-# maxlength, fragsize e gli altri non so se vanno tradotti...
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Metriche del buffer: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() non riuscita: %s"
-# maxlength e fragsize non so se vanno tradotti...
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Metriche del buffer: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() non riuscita: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "In uso specifica di campionamento \"%s\", mappa di canali \"%s\".\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() non riuscita: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Connesso al device %s (%u, %ssospeso).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Creazione dello stream riuscita."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Errore di stream: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() non riuscita: %s"
-#: ../src/utils/pacat.c:207
+# maxlength, fragsize e gli altri non so se vanno tradotti...
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Device stream sospeso.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Metriche del buffer: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+# maxlength e fragsize non so se vanno tradotti...
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Device stream ripristinato.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Metriche del buffer: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Underrun dello stream.%s\n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "In uso specifica di campionamento \"%s\", mappa dei canali \"%s\"."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Overrun dello stream.%s\n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Connesso al device %s (%u, %ssospeso)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Stream avviato.%s \n"
+msgid "Stream error: %s"
+msgstr "Errore di stream: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Stream spostato sul device %s (%u, %ssospeso).%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "non "
+msgid "Stream device suspended.%s"
+msgstr "Device stream sospeso.%s "
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Attributi del buffer di stream cambiati.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "Device stream ripristinato.%s "
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Connessione stabilita.%s \n"
+msgid "Stream underrun.%s"
+msgstr "Underrun dello stream.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() non riuscita: %s\n"
+msgid "Stream overrun.%s"
+msgstr "Overrun dello stream.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() non riuscita: %s\n"
+msgid "Stream started.%s"
+msgstr "Stream avviato.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() non riuscita: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Stream spostato sul device %s (%u, %ssospeso).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Connessione non riuscita: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "non "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Svuotamento dello stream non riuscito: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Attributi del buffer di stream cambiati.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Stream di riproduzione svuotato.\n"
+msgid "Connection established.%s"
+msgstr "Connessione stabilita.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Svuotamento della connessione sul server.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() non riuscita: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "Ricevuto EOF.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() non riuscita: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() non riuscita: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() non riuscita: %s\n"
+msgid "Connection failure: %s"
+msgstr "Connessione non riuscita: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() non riuscita: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Ricevuto EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Ricevuto il segnale, uscita.\n"
+msgid "write() failed: %s"
+msgstr "write() non riuscita: %s"
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Ricevuto il segnale, uscita."
+
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Recupero della latenza non riuscito: %s\n"
+msgid "Failed to get latency: %s"
+msgstr "Recupero della latenza non riuscito: %s"
# dubbio: tempo o durata??
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Tempo: %0.3f sec; Latenza: %0.0f microsec. \\r"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Tempo: %0.3f sec; Latenza: %0.0f microsec."
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:620
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() non riuscita: %s\n"
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() non riuscita: %s"
-#: ../src/utils/pacat.c:511
-#, c-format
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1525,8 +1416,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1549,6 +1442,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [OPZIONI]\n"
"\n"
@@ -1582,36 +1484,42 @@ msgstr ""
" --channels=CANALI Il numero di canali, 1 per mono, 2 "
"per\n"
" stereo (2 come predefinito)\n"
-" --channel-map=MAP_CANALI La mappa di canali da usare al posto "
-"di\n"
+" --channel-map=MAP_CANALI La mappa dei canali da usare al "
+"posto di\n"
" quella predefinita\n"
" --fix-format Recupera il formato di "
"campionamento\n"
" dal sink a cui lo stream sta per "
"essere\n"
-" connesso.\n"
+" connesso\n"
" --fix-rate Recupera la frequenza di "
"campionamento\n"
" dal sink a cui lo stream sta per "
"essere\n"
-" connesso.\n"
+" connesso\n"
" --fix-channels Recupera il numero di canali e la "
"mappa\n"
" dei canali dal sink a cui lo "
"stream \n"
-" sta per essere connesso.\n"
+" sta per essere connesso\n"
" --no-remix Non esegue l'upmix o il downmix \n"
-" dei canali.\n"
+" dei canali\n"
" --no-remap Mappa i canali per indice invece "
"che \n"
-" per nome.\n"
+" per nome\n"
" --latency=BYTE Richiede la latenza specificata in "
-"byte.\n"
+"byte\n"
" --process-time=BYTE Richiede il tempo di elaborazione "
"per\n"
-" richiesta specificato in byte.\n"
+" richiesta specificato in byte\n"
+" --property=PROPRIETÀ=VAL Imposta la proprietà al valore "
+"specificato\n"
+" --raw Registra/riproduce dati PCM grezzi\n"
+" --file-format=FFORMAT Registra/riproduce dati PCM "
+"formattati\n"
+" --list-file-FORMATI Elenca i formati disponibili.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1622,131 +1530,176 @@ msgstr ""
"Compilato con libpulse %s\n"
"Link eseguito con libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Mappa di canali \"%s\" non valida\n"
+msgid "Invalid client name '%s'"
+msgstr "Nome del client \"%s\" non valido"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Specifica di latenza \"%s\" non valida\n"
+msgid "Invalid stream name '%s'"
+msgstr "Nome dello stream \"%s\" non valido"
-# esecuzione???
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Specifica di tempo di elaborazione \"%s\" non valida\n"
+msgid "Invalid channel map '%s'"
+msgstr "Mappa dei canali \"%s\" non valida"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Specifica di campionamento non valida\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Specifica di latenza \"%s\" non valida"
-#: ../src/utils/pacat.c:721
+# esecuzione???
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "La mappa di canali non corrisponde alla specifica di campionamento\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Specifica di tempo di elaborazione \"%s\" non valida"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Apertura di uno stream %s con specifica di campionamento \"%s\".\n"
+msgid "Invalid property '%s'"
+msgstr "Proprietà \"%s\" non valida"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "registrazione"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Formato file %s sconosciuto."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "riproduzione"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Specifica di campionamento non valida"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Troppi argomenti.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Troppi argomenti."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() non riuscita.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Generazione della specifica di campionamento per il file non riuscita."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() non riuscita.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Apertura del file audio non riuscita."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() non riuscita.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Attenzione: la specifica di campionamento indicata verrà soprascritta con "
+"quella dal file."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() non riuscita: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Determinazione della specifica di campionamento dal file non riuscita."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr ""
+"Attenzione: determinazione della mappa dei canali dal file non riuscita."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "La mappa dei canali non corrisponde alla specifica di campionamento"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Attenzione: scrittura della mappa dei canali su file non riuscita."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() non riuscita.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Apertura di uno stream %s con specifica di campionamento \"%s\" e mappa dei "
+"canali \"%s\"."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "registrazione"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "riproduzione"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() non riuscita."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() non riuscita."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() non riuscita."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() non riuscita.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() non riuscita: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() non riuscita."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() non riuscita."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Sospensione non riuscita: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Ripristino non riuscito: %s\n"
# cambiato un po' la parte finale...
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "ATTENZIONE: server audio non locale, impossibile sospendere.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Connessione non riuscita: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Ricevuto SIGINT, in uscita.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "ATTENZIONE: processo figlio terminato dal segnale %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1765,7 +1718,7 @@ msgstr ""
"connettersi\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1776,37 +1729,63 @@ msgstr ""
"Compilato con libpulse %s\n"
"Link eseguito con libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() non riuscita.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() non riuscita.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() non riuscita.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Recupero delle statistiche non riuscito: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "Recupero delle statistiche non riuscito: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Attualmente in uso: %u blocchi contenenti %s byte in totale.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"Allocati durante l'intera esecuzione: %u blocchi contenenti %s byte in "
"totale.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Dimensione della cache dei campioni: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Recupero delle informazioni del server non riuscito: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Recupero delle informazioni del server non riuscito: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1814,7 +1793,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Nome utente: %s\n"
"Nome host: %s\n"
@@ -1826,15 +1805,15 @@ msgstr ""
"Sorgente predefinita: %s\n"
"Cookie: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Recupero delle informazioni del sink non riuscito: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Recupero delle informazioni del sink non riuscito: %s"
# nel relativo messaggio per il source
# c'è "monitor of sink", quindi assumo che
# qui dovesse essere "monitor of source"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1861,7 +1840,7 @@ msgstr ""
"\tDescrizione: %s\n"
"\tDriver: %s\n"
"\tSpecifica di campionamento: %s\n"
-"\tMappa di canali: %s\n"
+"\tMappa dei canali: %s\n"
"\tModulo di appartenenza: %u\n"
"\tMuto: %s\n"
"\tVolume: %s%s%s\n"
@@ -1873,12 +1852,22 @@ msgstr ""
"\tProprietà:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorte:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Recupero delle informazioni della sorgente non riuscito: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tPorta attiva: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Recupero delle informazioni della sorgente non riuscito: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1905,7 +1894,7 @@ msgstr ""
"\tDescrizione: %s\n"
"\tDriver: %s\n"
"\tSpecifica di campionamento: %s\n"
-"\tMappa di canali: %s\n"
+"\tMappa dei canali: %s\n"
"\tModulo di appartenenza: %u\n"
"\tMuto: %s\n"
"\tVolume: %s%s%s\n"
@@ -1917,20 +1906,20 @@ msgstr ""
"\tProprietà:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "N/D"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Recupero delle informazioni del modulo non riuscito: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Recupero delle informazioni del modulo non riuscito: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1947,12 +1936,12 @@ msgstr ""
"\tProprietà:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Recupero delle informazioni del client non riuscito: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Recupero delle informazioni del client non riuscito: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1967,12 +1956,12 @@ msgstr ""
"\tProprietà:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Recupero delle informazioni della scheda non riuscito: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Recupero delle informazioni della scheda non riuscito: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1989,12 +1978,12 @@ msgstr ""
"\tProprietà:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tProfili:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tProfilo attivo: %s\n"
@@ -2003,13 +1992,12 @@ msgstr "\tProfilo attivo: %s\n"
# A stream that is connected to an output device, i.e. an input for a sink.
#
# from http://pulseaudio.org/wiki/WritingVolumeControlUIs
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr ""
-"Recupero delle informazioni dell'ingresso per il sink non riuscito: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Recupero delle informazioni dell'ingresso per il sink non riuscito: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -2050,13 +2038,13 @@ msgstr ""
# A stream that is connected to an input device, i.e. an output of a source.
#
# from http://pulseaudio.org/wiki/WritingVolumeControlUIs
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
+msgid "Failed to get source output information: %s"
msgstr ""
-"Recupero delle informazioni dell'uscita per la sorgente non riuscito: %s\n"
+"Recupero delle informazioni dell'uscita per la sorgente non riuscito: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2085,13 +2073,13 @@ msgstr ""
"\tProprietà:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Recupero delle informazioni del campione non riuscito: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Recupero delle informazioni del campione non riuscito: %s"
# campiona lazy??
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2122,23 +2110,80 @@ msgstr ""
"\tProprietà:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Fallimento: %s\n"
+msgid "Failure: %s"
+msgstr "Fallimento: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Caricamento del campione non riuscito: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Caricamento del campione non riuscito: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Fine del file prematura\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Fine del file prematura"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Server non valido"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Ricevuto SIGINT, uscita."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2146,13 +2191,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2162,19 +2216,27 @@ msgid ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
msgstr ""
-"%s [OPZIONE...] stat\n"
-"%s [OPZIONE...] list\n"
-"%s [OPZIONE...] exit\n"
-"%s [OPZIONE...] upload-sample NOMEFILE [NOME]\n"
-"%s [OPZIONE...] play-sample NOME [SINK]\n"
-"%s [OPZIONE...] remove-sample NOME\n"
-"%s [OPZIONE...] move-sink-input ID SINK\n"
-"%s [OPZIONE...] move-source-output ID SORGENTE\n"
-"%s [OPZIONE...] load-module NOME [ARGOMENTO...]\n"
-"%s [OPZIONE...] unload-module ID\n"
-"%s [OPZIONE...] suspend-sink [SINK] 1|0\n"
-"%s [OPZIONE...] suspend-source [SORGENTE] 1|0\n"
-"%s [OPZIONE...] set-card-profile [SCHEDA] [PROFILO] \n"
+"%s [OPZIONI] stat\n"
+"%s [OPZIONI] list\n"
+"%s [OPZIONI] exit\n"
+"%s [OPZIONI] upload-sample NOMEFILE [NOME]\n"
+"%s [OPZIONI] play-sample NOME [SINK]\n"
+"%s [OPZIONI] remove-sample NOME\n"
+"%s [OPZIONI] move-sink-input SINKINPUT SINK\n"
+"%s [OPZIONI] move-source-output SOURCEOUTPUT SORGENTE\n"
+"%s [OPZIONI] load-module NOME [ARGOMENTI...]\n"
+"%s [OPZIONI] unload-module MODULO\n"
+"%s [OPZIONI] suspend-sink SINK 1|0\n"
+"%s [OPZIONI] suspend-source SORGENTE 1|0\n"
+"%s [OPZIONI] set-card-profile SCHEDA PROFILO\n"
+"%s [OPZIONI] set-sink-port SINK PORTA\n"
+"%s [OPZIONI] set-source-port SORGENTE PORTA\n"
+"%s [OPZIONI] set-sink-volume SINK VOLUME\n"
+"%s [OPZIONI] set-source-volume SORGENTE VOLUME\n"
+"%s [OPZIONI] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [OPZIONI] set-sink-mute SINK 1|0\n"
+"%s [OPZIONI] set-source-mute SORGENTE 1|0\n"
+"%s [OPZIONI] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
" -h, --help Mostra questo aiuto\n"
" --version Mostra la versione\n"
@@ -2182,7 +2244,7 @@ msgstr ""
" -s, --server=SERVER Il nome del server a cui connettersi\n"
" -n, --client-name=NOME Come chiamare questo client sul server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2193,79 +2255,114 @@ msgstr ""
"Compilato con libpulse %s\n"
"Link eseguito con libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Specificare un file campione da caricare\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Specificare un file campione da caricare"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Apertura del file audio non riuscita.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Apertura del file audio non riuscita."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "È necessario specificare un nome di campione da riprodurre\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+"Attenzione: determinazione della specifica di campionamento dal file non "
+"riuscita."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "È necessario specificare un nome di campione da rimuovere\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "È necessario specificare un nome di campione da riprodurre"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "È necessario specificare un ingresso per sink e un sink\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "È necessario specificare un nome di campione da rimuovere"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "È necessario specificare una uscita per sorgente e una sorgente\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "È necessario specificare un indice di ingresso per sink e un sink"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "È necessario specificare un nome di modulo e gli argomenti.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr ""
+"È necessario specificare una indice di uscita per sorgente e una sorgente"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "È necessario specificare un indice di modulo\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "È necessario specificare un nome di modulo e gli argomenti."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "È necessario specificare un indice di modulo"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
"Non è possibile specificare più di un sink. È necessario specificare un "
-"valore booleano.\n"
+"valore booleano."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
"Non è possibile specificare più di una sorgente. È necessario specificare un "
-"valore booleano.\n"
+"valore booleano."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
msgstr ""
-"È necessario specificare un nome/indice di scheda e un nome di profilo.\n"
+"È necessario specificare un nome/indice di scheda e un nome di profilo."
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Nessun comando valido specificato.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "È necessario specificare un nome/indice di sink e un nome di porta"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() non riuscita: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "È necessario specificare un nome/indice di sorgente e un nome di porta"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "È necessario specificare un nome/indice di sink e un nome di porta"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Specifica di volume non valida"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "È necessario specificare un nome/indice di sorgente e un nome di porta"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "È necessario specificare un indice di ingresso per sink e un sink"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Indice dell'input del sink non valido"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "È necessario specificare un nome/indice di sink e un nome di porta"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "È necessario specificare un nome/indice di sorgente e un nome di porta"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "È necessario specificare un indice di ingresso per sink e un sink"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Specifica dell'indice di input del sink non valida"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Nessun comando valido specificato."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2281,9 +2378,9 @@ msgstr ""
"%s [-D DISPLAY] [-S SERVER] [-O SINK] [-I SORGENTE] [-c FILE] [-d|-e|-i|-"
"r]\n"
"\n"
-" -d Mostra i dati PulseAudio attuali attaccati al display X11 (predef)\n"
+" -d Mostra i dati PulseAudio attuali collegati al display X11 (predef)\n"
" -e Esporta i dati PulseAudio locali sul display X11\n"
-" -i Importa i dati PulseAudio dal display X11 alle variabili ambientali "
+" -i Importa i dati PulseAudio dal display X11 alle variabili d'ambiente "
"e\n"
" al file cookie locali \n"
" -r Rimuove i dati PulseAudio dal display X11\n"
@@ -2348,131 +2445,50 @@ msgstr "Caricamento dei dati cookie non riuscito\n"
msgid "Not yet implemented.\n"
msgstr "Non ancora implementato.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Nessun demone PulseAudio in esecuzione o non in esecuzione come demone di "
+"sessione."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Uccisione del demone PulseAudio non riuscita."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Il demone non sta rispondendo."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Creazione dello stream riuscita\n"
-
-# fixme!!! errror
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Errore nello stream: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Connessione stabilita.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [OPZIONI] [FILE]\n"
-"\n"
-" -h, --help Mostra questo aiuto\n"
-" --version Mostra la versione\n"
-"\n"
-" -v, --verbose Abilita la modalità prolissa\n"
-"\n"
-" -s, --server=SERVER Il nome del server a cui "
-"connettersi\n"
-" -d, --device=DEVICE Il nome del sink a cui connettersi\n"
-" -n, --client-name=NOME Come chiamare questo client sul "
-"server\n"
-" --stream-name=NOME Come chiamare questo stream sul "
-"server\n"
-" --volume=VOLUME Specifica il volume iniziale "
-"(lineare) \n"
-" nell'intervallo 0...65536\n"
-" --channel-map=MAPPA_CANALI Imposta la mappa di canali da usare\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Compilato con libpulse %s\n"
-"Link eseguito con libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Mappa dei canali non valida\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Apertura del file \"%s\" non riuscita\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "La mappa dei canali non corrisponde al file.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "In uso la specifica di campionamento \"%s\"\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Impossibile accedere al lock di autospawn."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2482,14 +2498,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
-"ALSA si è svegliato per scrivere nuovi dati sul dispositivo ma non c'era "
-"niente da scrivere!\n"
-"Molto probabilmente questo è un bug dei driver ALSA '%s'. Riportare questo "
-"problema agli sviluppatori di ALSA.\n"
-"Ci si è alzati con impostato POLLOUT -- come sempre un subsequent "
-"snd_pcm_avail() ritorna 0 o un altro valore < min_avail."
+"Attivazione da parte di ALSA per scrivere nuovi dati sul dispositivo, ma non "
+"c'era nulla da scrivere.\n"
+"Molto probabilmente si tratta di un bug nei driver ALSA \"%s\". Segnalare "
+"questo problema agli sviluppatori di ALSA.\n"
+"Attivazione avvenuta con POLLOUT impostato -- tuttavia, una successiva "
+"snd_pcm_avail() ha ritornato 0 o un altro valore < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2499,41 +2515,266 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
-"ALSA si è svegliato per leggere nuovi dati dal dispositivo ma non c'era "
-"niente da leggere!\n"
-"Molto probabilmente questo è un bug dei driver ALSA '%s'. Riportare questo "
-"problema agli sviluppatori di ALSA.\n"
-"Ci si è alzati con impostato POLLIN -- come sempre un subsequent "
-"snd_pcm_avail() ritorna 0 o un altro valore < min_avail."
-
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Output %s + Input %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Output %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Input %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+"Attivazione da parte di ALSA per leggere nuovi dati dal dispositivo, ma non "
+"c'era nulla da leggere.\n"
+"Molto probabilmente si tratta di un bug nei driver ALSA \"%s\". Segnalare "
+"questo problema agli sviluppatori di ALSA.\n"
+"Attivazione avvenuta con POLLIN impostato -- tuttavia, una successiva "
+"snd_pcm_avail() ha ritornato 0 o un altro valore < min_avail."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "Spento"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr "Playback ad alta fidabilità (A2DP)"
+msgstr "Riproduzione ad alta fedeltà (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Cattura ad alta fedeltà (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
-msgstr "Doppino Telefonico (HSP/HFP)"
+msgstr "Doppino telefonico (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "Server sonoro PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Dispositivi di uscita"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Dispositivi di ingresso"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Audio su @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Ingresso"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Ingresso docking station"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Microfono docking station"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Line-In"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Microfono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Microfono esterno"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Microfono interno"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Controllo automatico del guadagno"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Nessun controllo automatico del guadagno"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Nessun boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Amplificatore"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Nessun amplificatore"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Nessun boost"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Cuffie analogiche"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Ingresso analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Microfono analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Line-in analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Radio analogica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Video analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Uscita analogica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Cuffie analogiche"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Uscita analogica (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Uscita mono analogica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Stereo analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Mono analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Stereo analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Surround analogico 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Surround analogico 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Surround analogico 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Surround analogico 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Surround analogico 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Surround analogico 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Surround analogico 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Surround analogico 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Surround analogico 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Surround analogico 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Surround analogico 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Stereo digitale (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Surround digitale 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Surround digitale 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Surround digitale 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Stereo digitale (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Duplex mono analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Duplex stereo analogico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Duplex stereo digitale (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Emettitore basse frequenze"
diff --git a/po/ja.po b/po/ja.po
new file mode 100644
index 00000000..b23297b2
--- /dev/null
+++ b/po/ja.po
@@ -0,0 +1,2697 @@
+# translation of ja.po to Japanese
+# PulseAudio
+# Copyright (C) 2009.
+# This file is distributed under the same license as the PACKAGE package.
+#
+# Hyu_gabaru Ryu_ichi <hyu_gabaru@yahoo.co.jp>, 2009.
+# Kiyoto Hashida <khashida@redhat.com>, 2009.
+msgid ""
+msgstr ""
+"Project-Id-Version: ja\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-10 11:49+0900\n"
+"Last-Translator: Kiyoto Hashida <khashida@redhat.com>\n"
+"Language-Team: Japanese <jp@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Generator: KBabel 1.11.4\n"
+"Plural-Forms: Plural-Forms: nplurals=1; plural=0;\n"
+"\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_avail() 㯠例外的ã«å¤§ããªå€¤ã‚’è¿”ã—ã¾ã—ãŸ: %lu ãƒã‚¤ãƒˆï¼ˆ%lu ms)。\n"
+"ã“れã¯å¤šåˆ†ã€ALSA ドライãƒãƒ¼ '%s' 内ã®ãƒã‚°ã§ã™ã€‚ã“ã®å•題㯠ALSA 開発者宛㫠報"
+"告をæå‡ºã—ã¦ä¸‹ã•ã„。"
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_delay() 㯠例外的ã«å¤§ããªå€¤ã‚’è¿”ã—ã¾ã—ãŸ: %li ãƒã‚¤ãƒˆï¼ˆ%s%lu ms)。\n"
+"ã“れã¯å¤šåˆ†ã€ALSA ドライãƒãƒ¼ '%s' 内ã®ãƒã‚°ã§ã™ã€‚ã“ã®å•題㯠ALSA 開発者宛㫠報"
+"告をæå‡ºã—ã¦ä¸‹ã•ã„。"
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_mmap_begin() 㯠例外的ã«å¤§ããªå€¤ã‚’è¿”ã—ã¾ã—ãŸ: %lu ãƒã‚¤ãƒˆï¼ˆ%lu "
+"ms)。\n"
+"ã“れã¯å¤šåˆ†ã€ALSA ドライãƒãƒ¼ '%s' 内ã®ãƒã‚°ã§ã™ã€‚ã“ã®å•題㯠ALSA 開発者宛㫠報"
+"告をæå‡ºã—ã¦ä¸‹ã•ã„。"
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+"null ã§ã‚ã‚‹å ´åˆã§ã‚‚ã€å¸¸ã«æœ€ä½Žã§ã‚‚シンクãŒï¼‘ã¤ãƒ­ãƒ¼ãƒ‰ã•れるよã†ã«ç¶­æŒã—ã¾ã™"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ダミー出力"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "仮想 LADSPA シンク"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<シンクã®åå‰> sink_properties=<シンクã®ãƒ—ロパティ> master=<フィル"
+"ã‚¿ã™ã‚‹ã‚·ãƒ³ã‚¯å> format=<サンプル形å¼> rate=<サンプルレート> channels=<ãƒãƒ£ãƒ³"
+"ãƒãƒ«æ•°> channel_map=<ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—> plugin=<ladspa plugin ã®åå‰> "
+"label=<ladspa plugin ã®ãƒ©ãƒ™ãƒ«> control=<コンマã§éš”離ã—ãŸå…¥åŠ›åˆ¶å¾¡å€¤ã® ä¸€è¦§>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "クロック付ã NULL シンク"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null 出力"
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "内部オーディオ"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "モデム"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr "オリジナル㮠lt_dlopen ローダーを見ã¤ã‘ã‚‹ã®ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr "æ–°è¦ã® dl ローダーã®å‰²ã‚Šå½“ã¦ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr "bind-now-loader ã®è¿½åŠ ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr "ä¿¡å· %s ã‚’å¾—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "終了ã—ã¦ã„ã¾ã™ã€‚"
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr "ユーザー '%s' ãŒè¦‹ä»˜ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr "グループ '%s' ãŒè¦‹ä»˜ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr "ユーザー'%s' (UID %lu) ã¨ã‚°ãƒ«ãƒ¼ãƒ— '%s' (GID %lu) を見ã¤ã‘ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr "ユーザー'%s' 㨠グループ '%s' ã® GID ãŒä¸€è‡´ã—ã¾ã›ã‚“。"
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr "ユーザー '%s' ã®ãƒ›ãƒ¼ãƒ ãƒ‡ã‚£ãƒ¬ã‚¯ãƒˆãƒªã¯ '%s' ã§ã¯ã‚りã¾ã›ã‚“。無視ã—ã¾ã™ã€‚"
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr "'%s' ã®ä½œæˆã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr "グループ一覧ã®å¤‰æ›´ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr "GID ã®å¤‰æ›´ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr "UID ã®å¤‰æ›´ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr "root ã®æ¨©é™ã‚’æ­£ã—ã破棄ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr "ã“ã®ãƒ—ラットフォームã§ã¯ã‚·ã‚¹ãƒ†ãƒ å…¨åŸŸã®ãƒ¢ãƒ¼ãƒ‰ã¯ã‚µãƒãƒ¼ãƒˆãŒã‚りã¾ã›ã‚“。"
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr "setrlimit(%s, (%u, %u)) ã¯å¤±æ•—: %s "
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr "ã‚³ãƒžãƒ³ãƒ‰ãƒ©ã‚¤ãƒ³ã®æ§‹æ–‡è§£æžã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr "デーモンã¯ç¨¼åƒã—ã¦ã„ã¾ã›ã‚“"
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr "デーモン㯠PID %u ã¨ã—ã¦ç¨¼åƒã—ã¦ã„ã¾ã›ã‚“"
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr "デーモンã®ã‚­ãƒ«ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr ""
+"ã“ã®ãƒ—ログラム㯠root ã¨ã—ã¦å®Ÿè¡Œã•れるよã†ã«æ„図ã•れã¦ã„ã¾ã›ã‚“(--system ã‚’ "
+"指定ã—ã¦ã„ãªã„é™ã‚Šï¼‰ã€‚"
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr "Root ã®æ¨©é™ãŒå¿…è¦ã§ã™ã€‚"
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr "--start ã¯ã‚·ã‚¹ãƒ†ãƒ ã‚¤ãƒ³ã‚¹ã‚¿ãƒ³ã‚¹ã§ã¯ã‚µãƒãƒ¼ãƒˆãŒã‚りã¾ã›ã‚“。"
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr ""
+"システムモードã§å®Ÿè¡Œä¸­ã§ã™ã€ã—ã‹ã— --disallow-exit ãŒã‚»ãƒƒãƒˆã•れã¦ã„ã¾ã›ã‚“!"
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr ""
+"システムモードã§å®Ÿè¡Œä¸­ã§ã™ã€ã—ã‹ã— --disallow-module-loading ãŒã‚»ãƒƒãƒˆã•れã¦ã„"
+"ã¾ã›ã‚“!"
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr "システムモードã§å®Ÿè¡Œä¸­ã§ã™ã€å¼·åˆ¶çš„ã« SHM モードを無効ã«ã—ã¦ã„ã¾ã™!"
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr ""
+"システムモードã§å®Ÿè¡Œä¸­ã§ã™ã€å¼·åˆ¶çš„ã« exit ã®éŠã³æ™‚間を無効ã«ã—ã¦ã„ã¾ã™!"
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr "stdio ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "パイプã¯å¤±æ•—: %s"
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr "fork() ã¯å¤±æ•—: %s"
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr "read() ã¯å¤±æ•—: %s"
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr "デーモン開始ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr "ãƒ‡ãƒ¼ãƒ¢ãƒ³ãŒæ­£å¸¸ã«é–‹å§‹ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() ã¯å¤±æ•—: %s"
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr "ã“れ㯠PulseAudio %s ã§ã™ã€‚"
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr "コンパイルホスト: %s"
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr "コンパイル CFLAGS: %s"
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr "ホスト上ã§å®Ÿè¡Œä¸­: %s"
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr "%u CPU を見ã¤ã‘ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr "ページサイズ㯠%lu ãƒã‚¤ãƒˆã§ã™"
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr "Valgrind サãƒãƒ¼ãƒˆã§ã®ã‚³ãƒ³ãƒ‘イル: ã¯ã„"
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr "Valgrind サãƒãƒ¼ãƒˆã§ã®ã‚³ãƒ³ãƒ‘イル: ã„ã„ãˆ"
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr "valgrind モードã§å®Ÿè¡Œä¸­: %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "ホスト上ã§å®Ÿè¡Œä¸­: %s"
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr "最é©åŒ–ã—ãŸãƒ“ルド: ã¯ã„"
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr "最é©åŒ–ã—ãŸãƒ“ルド: ã„ã„ãˆ"
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr "NDEBUG ã¯å®šç¾©æ¸ˆã¿ã§ã™ã€‚アサーションã¯å…¨ã¦ç„¡åйã§ã™ã€‚"
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr "FASTPATH ã¯å®šç¾©æ¸ˆã¿ã§ã™ã€‚ファーストパスアサーションã®ã¿ãŒç„¡åйã§ã™ã€‚"
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr "アサーションã¯å…¨ã¦æœ‰åйã§ã™ã€‚"
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr "マシン ID ã®å–å¾—ã«å¤±æ•—"
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr "マシン ID 㯠%s"
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr "セッション ID 㯠%s"
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr "ランタイムディレクトリ %s を使用 "
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr "状態ディレクトリ %s を使用"
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "モジュールディレクトリ %s を使用"
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr "システムモードã§å®Ÿè¡Œä¸­: %s"
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"ãã†ã™ã‚‹ã¨ã€ãƒ¦ãƒ¼ã‚¶ãƒ¼ã¯ã‚·ã‚¹ãƒ†ãƒ ãƒ¢ãƒ¼ãƒ‰ã§ PA を実行ã—ã¦ã„る訳ã§ã™ã€‚ãã®å ´åˆã€ 実"
+"éš›ã«ã¯ãã†ã™ã¹ãã§ãªã„ã“ã¨ã«æ³¨æ„ã—ã¦ä¸‹ã•ã„。\n"
+"ãれã§ã‚‚実行ã™ã‚‹ã®ã§ã—ãŸã‚‰ã€æœŸå¾…ã©ãŠã‚Šã«æ©Ÿèƒ½ã—ãªãã¦ã‚‚責任ã¯ãƒ¦ãƒ¼ã‚¶ãƒ¼è‡ªèº«ã« ã‚"
+"りã¾ã™ã€‚\n"
+"システムモードã®ä½¿ç”¨ãŒé€šå¸¸ã¯è‰¯ããªã„æ–¹é‡ã§ã‚ã‚‹ã“ã¨ã®èª¬æ˜Žã«ã¤ã„ã¦ã¯ã€ http://"
+"pulseaudio.org/wiki/WhatIsWrongWithSystemMode ã‚’ãŠèª­ã¿ä¸‹ã•ã„。"
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr "pa_pid_file_create() ã¯å¤±æ•—"
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr "最新ã®é«˜è§£åƒåº¦ã‚¿ã‚¤ãƒžãƒ¼ãŒä½¿ç”¨ã§ãã¾ã™! 楽ã—ã‚“ã§ä¸‹ã•ã„!"
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr ""
+"ã‚らã‚らã€ãƒ¦ãƒ¼ã‚¶ãƒ¼ã®ã‚«ãƒ¼ãƒãƒ«ã¯ãƒ€ãƒ¡ã§ã™ã‚ˆ! 今日ã®ã‚·ã‚§ãƒ•ã®ãŠè–¦ã‚ã¯é«˜è§£åƒåº¦ã‚¿ã‚¤"
+"マー㌠有効ã«ãªã£ã¦ã„ã‚‹ Linux ã§ã™!"
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr "pa_core_new() ã¯å¤±æ•—"
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr "デーモンã®åˆæœŸåŒ–ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr ""
+"デーモンã¯ãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ã®èª­ã¿è¾¼ã¿ãªã—ã§é–‹å§‹ã—ã¦ãŠã‚Šã€å‹•作を拒å¦ã—ã¦ã„ã¾ã™ã€‚"
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr "デーモンã®é–‹å§‹ãŒå®Œäº†ã§ã™ã€‚"
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr "デーモンã®ã‚·ãƒ£ãƒƒãƒˆãƒ€ã‚¦ãƒ³ãŒå§‹ã¾ã‚Šã¾ã—ãŸã€‚"
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr "デーモンã¯å–り消ã•れã¾ã—ãŸã€‚"
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+"%s [オプション]\n"
+"\n"
+"コマンド:\n"
+" -h, --help ã“ã®ãƒ˜ãƒ«ãƒ—を表示\n"
+" --version ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã‚’表示\n"
+" --dump-conf デフォルト設定をダンプ\n"
+" --dump-modules 使用å¯èƒ½ãªãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ä¸€è¦§ã‚’ダンプ\n"
+" --dump-resample-methods 使用å¯èƒ½ãªå†ã‚µãƒ³ãƒ—ル方法をダンプ\n"
+" --cleanup-shm å¤ã„共有メモリーセグメントをクリーン"
+"アップ \n"
+" --start 実行ã—ã¦ã„ãªã„å ´åˆã€ãƒ‡ãƒ¼ãƒ¢ãƒ³ã‚’é–‹å§‹ \n"
+" -k --kill 実行中ã®ãƒ‡ãƒ¼ãƒ¢ãƒ³ã‚’キル\n"
+" --check 実行中ã®ãƒ‡ãƒ¼ãƒ¢ãƒ³ã‚’ãƒã‚§ãƒƒã‚¯ (退出コー"
+"ドを返ã™ã®ã¿)\n"
+"\n"
+"オプション:\n"
+" --system[=BOOL] システム全域インスタンスã¨ã—ã¦å®Ÿè¡Œ\n"
+" -D, --daemonize[=BOOL] 開始後デーモン化\n"
+" --fail[=BOOL] 開始失敗ãªã‚‰çµ‚了\n"
+" --high-priority[=BOOL] 高度ãªãƒŠã‚¤ã‚¹ãƒ¬ãƒ™ãƒ«ã®è¨­å®šã‚’試行\n"
+" (root ã¨ã—ã¦ã®ã¿å¯èƒ½, SUID ã®æ™‚ã€åˆ"
+"ã¯\n"
+" 昇格ã—㟠RLIMIT_NICE ã§)\n"
+" --realtime[=BOOL] リアルタイムスケジュールを有効ã«ã™ã‚‹"
+"試行\n"
+" (root ã¨ã—ã¦ã®ã¿å¯èƒ½, SUID ã®æ™‚ã€åˆ"
+"ã¯\n"
+" 昇格ã—㟠RLIMIT_RTPRIO ã§)\n"
+" --disallow-module-loading[=BOOL] 起動後ã®ãƒ¦ãƒ¼ã‚¶ãƒ¼è¦æ±‚ã®ãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ã® "
+"ロード/アンロードを 許å¯ã—ãªã„\n"
+"\n"
+" --disallow-exit[=BOOL] ãƒ¦ãƒ¼ã‚¶ãƒ¼è¦æ±‚ã®é€€å‡ºã‚’許å¯ã—ãªã„\n"
+" --exit-idle-time=SECS éŠä¼‘æ™‚ã¨æŒ‡å®šæ™‚間後ã«ãƒ‡ãƒ¼ãƒ¢ãƒ³ã‚’終了 \n"
+"\n"
+" --module-idle-time=SECS éŠä¼‘æ™‚ã¨æŒ‡å®šæ™‚間後ã«è‡ªå‹•ロードモ"
+"ジュールをアンロード \n"
+"\n"
+" --scache-idle-time=SECS éŠä¼‘æ™‚ã¨æŒ‡å®šæ™‚間後ã«è‡ªå‹•ロードサンプ"
+"ルをアンロード \n"
+"\n"
+" --log-level[=LEVEL] 詳細レベルを上ã’ã‚‹ã‹ã€åˆã¯ã‚»ãƒƒãƒˆ\n"
+" -v 詳細レベルを上ã’ã‚‹ \n"
+"--log-target={auto,syslog,stderr} ログターゲットを指定 \n"
+"--log-meta[=BOOL] ログメッセージ内ã«ã‚³ãƒ¼ãƒ‰ã®å ´æ‰€ã‚’å«ã‚€ \n"
+" --log-time[=BOOL] ログメッセージ内ã«ã‚¿ã‚¤ãƒ ã‚¹ã‚¿ãƒ³ãƒ—ã‚’å«"
+"ã‚€\n"
+" --log-backtrace=FRAMES ログメッセージ内ã«ãƒãƒƒã‚¯ãƒˆãƒ¬ãƒ¼ã‚¹ã‚’å«"
+"ã‚€\n"
+" -p, --dl-search-path=PATH 動的共有オブジェクト(plugins)ç”¨ã«æ¤œç´¢"
+"パスをセット\n"
+"\n"
+" --resample-method=METHOD 指定ã—ãŸå†ã‚µãƒ³ãƒ—リング方法を使用\n"
+" (使用å¯èƒ½ãªå€¤ã¯ --dump-resample-"
+"methods ã§\n"
+" å‚ç…§)\n"
+" --use-pid-file[=BOOL] PID ファイルを作æˆ\n"
+" --no-cpu-limit[=BOOL] サãƒãƒ¼ãƒˆå…ƒã®ãƒ—ラットフォーム㫠CPU\n"
+" ロードリミッターをインストールã—ãª"
+"ã„\n"
+" --disable-shm[=BOOL] 共有メモリーサãƒãƒ¼ãƒˆã‚’無効ã«ã™ã‚‹\n"
+"\n"
+"スタートアップスクリプト:\n"
+" -L, --load=\"MODULE ARGUMENTS\" 指定ã—ãŸå¼•æ•°ã§æŒ‡å®šã—ãŸãƒ—ラグインモ"
+"ジュールを ロード\n"
+"\n"
+" -F, --file=FILENAME 指定ã—ãŸã‚¹ã‚¯ãƒªãƒ—トを実行\n"
+" -C スタートアップ後ã«å®Ÿè¡Œä¸­ã® TTY 上ã§ã‚³"
+"マンドラインを é–‹ã\n"
+"\n"
+" -n デフォルトã®ã‚¹ã‚¯ãƒªãƒ—トファイルをロー"
+"ドã—ãªã„\n"
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr "--daemonize ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™"
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr "--fail ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™ã€‚"
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+"--log-level ã¯ãƒ­ã‚°ãƒ¬ãƒ™ãƒ«å¼•数を予期ã—ã¾ã™ï¼ˆæ•°å€¤å¹…ï¼ã€œï¼”ã€åˆã¯ãƒ‡ãƒã‚°ã€æƒ…å ±ã€æ³¨"
+"記ã€è­¦å‘Šã€ã‚¨ãƒ©ãƒ¼ã® 中ã®ï¼‘ã¤ï¼‰"
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr "--high-priority 㯠ブーリアン引数を予期ã—ã¾ã™"
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr "--realtime ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™ "
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr "--disallow-module-loading ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™ "
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr "--disallow-exit ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™ "
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr "--use-pid-file ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™ "
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr ""
+"無効ãªãƒ­ã‚°ã‚¿ãƒ¼ã‚²ãƒƒãƒˆ: 'syslog' ã‹ã€ 'stderr' ã‹ã€'auto' を使用ã—ã¦ä¸‹ã•ã„。"
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr "--log-time ブーリアン引数を予期ã—ã¾ã™ "
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr "--log-meta ブーリアン引数を予期ã—ã¾ã™ "
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr "無効ãªå†ã‚µãƒ³ãƒ—ル方法 '%s'"
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr "--system ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™"
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr "--no-cpu-limit ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™"
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr "--disable-shm ã¯ãƒ–ーリアン引数を予期ã—ã¾ã™"
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr "åå‰: %s\n"
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr "モジュール情報ãŒä½¿ç”¨ã§ãã¾ã›ã‚“\n"
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr "ãƒãƒ¼ã‚¸ãƒ§ãƒ³: %s\n"
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr "説明: %s\n"
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr "著者: %s\n"
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr "使用法: %s\n"
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr "1度ã ã‘ロード: %s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "破棄ã®è­¦å‘Š: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr "パス: %s\n"
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr "[%s:%u] 無効ãªãƒ­ã‚°ã‚¿ãƒ¼ã‚²ãƒƒãƒˆ '%s'"
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr "[%s:%u] 無効ãªãƒ­ã‚°ãƒ¬ãƒ™ãƒ« '%s'"
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr "[%s:%u] 無効ãªå†ã‚µãƒ³ãƒ—ル方法 '%s'"
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr "[%s:%u] 無効㪠rlimit '%s'"
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr "[%s:%u] rlimit ã¯ã“ã®ãƒ—ラットフォームã§ã¯ã‚µãƒãƒ¼ãƒˆãŒã‚りã¾ã›ã‚“。"
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr "[%s:%u] 無効ãªã‚µãƒ³ãƒ—ãƒ«å½¢å¼ '%s'"
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr "[%s:%u] 無効ãªã‚µãƒ³ãƒ—ルレート '%s'"
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr "[%s:%u] 無効ãªã‚µãƒ³ãƒ—ルãƒãƒ£ãƒ³ãƒãƒ« '%s'"
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr "[%s:%u] 無効ãªãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ— '%s'"
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr "[%s:%u] 無効ãªãƒ•ãƒ©ã‚°ãƒ¡ãƒ³ãƒˆã®æ•° '%s'"
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr "[%s:%u] 無効ãªãƒ•ラグメントサイズ '%s'"
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr "[%s:%u] 無効ãªãƒŠã‚¤ã‚¹ãƒ¬ãƒ™ãƒ« '%s'"
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] 無効ãªã‚µãƒ³ãƒ—ルレート '%s'"
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr "設定ファイルを開ãã®ã«å¤±æ•—: %s"
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr ""
+"指定ã•れãŸãƒ‡ãƒ•ォルトã®ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—ã¯ã€æŒ‡å®šã•れãŸãƒ‡ãƒ•ォルト㮠ãƒãƒ£ãƒ³ãƒãƒ«æ•°"
+"ã¨ã¯ç•°ãªã‚‹ ãƒãƒ£ãƒ³ãƒãƒ«æ•°ã‚’æŒã£ã¦ã„ã¾ã™ã€‚"
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr "### 設定ファイルã‹ã‚‰èª­ã¿è¾¼ã¿: %s ###\n"
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "権é™ã‚’クリーンアップ"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "PulseAudio サウンドシステム"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "PulseAudio サウンドシステムを開始"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "モノ"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "中央å‰"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "å·¦å‰"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "å³å‰"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "中央後ã‚"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "左後ã‚"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "å³å¾Œã‚"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr "中央ã®å·¦å‰"
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr "中央ã®å³å‰"
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "å·¦å´"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "å³å´"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr "補助 0"
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr "補助 1"
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr "補助 2"
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr "補助 3"
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr "補助 4"
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr "補助 5"
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr "補助 6"
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr "補助 7"
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr "補助 8"
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr "補助 9"
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr "補助 10"
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr "補助 11"
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr "補助 12"
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr "補助 13"
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr "補助 14"
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr "補助 15"
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr "補助 16"
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr "補助 17"
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr "補助 18"
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr "補助 19"
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr "補助 20"
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr "補助 21"
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr "補助 22"
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr "補助 23"
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr "補助 24"
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr "補助 25"
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr "補助 26"
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr "補助 27"
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr "補助 28"
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr "補助 29"
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr "補助 30"
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr "補助 31"
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "上部中央"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "上部中央å‰"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "上部左å‰"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "上部å³å‰"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "上部中央後ã‚"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "上部左後ã‚"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "上部å³å¾Œã‚"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "無効)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "ステレオ"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "サラウンド 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "サラウンド 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "サラウンド 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "サラウンド 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "サラウンド 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "OK"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "アクセス拒å¦"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr "䏿˜Žãªã‚³ãƒžãƒ³ãƒ‰"
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr "無効ãªå¼•æ•°"
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr "エンティティã¯å­˜åœ¨ã—ã¾ã™"
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr "ãã®ã‚ˆã†ãªã‚¨ãƒ³ãƒ†ã‚£ãƒ†ã‚£ã¯ã‚りã¾ã›ã‚“"
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "接続拒å¦"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "プロトコルエラー"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr "タイムアウト"
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr "èªè¨¼ã‚­ãƒ¼ãŒã‚りã¾ã›ã‚“"
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "内部エラー"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr "接続切断"
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr "エンティティã¯ã‚­ãƒ«ã•れã¾ã—ãŸ"
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr "無効ãªã‚µãƒ¼ãƒãƒ¼"
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr "ãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«åˆæœŸåŒ–失敗"
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr "悪ã„状態"
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr "データ無ã—"
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr "äº’æ›æ€§ã®ãªã„プロトコルãƒãƒ¼ã‚¸ãƒ§ãƒ³"
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "大ãéŽãŽã¾ã™"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "サãƒãƒ¼ãƒˆãŒã‚りã¾ã›ã‚“"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "䏿˜Žãªã‚¨ãƒ©ãƒ¼ã‚³ãƒ¼ãƒ‰"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr "ãã®ã‚ˆã†ãªæ‹¡å¼µå­ã¯ã‚りã¾ã›ã‚“"
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr "æ—§æ¥ã®æ©Ÿèƒ½"
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr "å®Ÿè£…ã®æ¬ å¦‚"
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr "クライアントã¯ãƒ•ォークã•れã¦ã„ã¾ã™"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "入力/出力 エラー"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "デãƒã‚¤ã‚¹ã‹ã€ãƒªã‚½ãƒ¼ã‚¹ãŒãƒ“ジー"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr "%s %uch %uHz"
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr "%0.1f GiB"
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr "%0.1f MiB"
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr "%0.1f KiB"
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr "%u B"
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr "XOpenDisplay() ã¯å¤±æ•—"
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr "ã‚¯ãƒƒã‚­ãƒ¼ãƒ‡ãƒ¼ã‚¿ã®æ§‹æ–‡è§£æžã«å¤±æ•—"
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr "設定ファイル'%s' ã‚’é–‹ãã®ã«å¤±æ•—: %s"
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr "クッキーãŒãƒ­ãƒ¼ãƒ‰ã•れã¦ã„ã¾ã›ã‚“。無ã„çŠ¶æ…‹ã§æŽ¥ç¶šã‚’è©¦è¡Œ"
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr "fork(): %s"
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr "waitpid(): %s"
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr "䏿˜Žãªæ‹¡å¼µå­ '%s' ã®ãƒ¡ãƒƒã‚»ãƒ¼ã‚¸ã‚’å—ä¿¡"
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr "ã‚¹ãƒˆãƒªãƒ¼ãƒ ã®æŽ’å‡ºã«å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "排出ã—ãŸã‚¹ãƒˆãƒªãƒ¼ãƒ ã‚’å†ç”Ÿ"
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "サーãƒãƒ¼ã¸ã®æŽ’出接続"
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "ã‚¹ãƒˆãƒªãƒ¼ãƒ ã¯æ­£å¸¸ã«ä½œæˆå®Œäº†"
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "ãƒãƒƒãƒ•ァメトリックス: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "ãƒãƒƒãƒ•ァメトリックス: maxlength=%u, fragsize=%u"
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "サンプル仕様 '%s' ã€ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ— '%s' を使用。"
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "デãƒã‚¤ã‚¹ %s ã«æŽ¥ç¶š (%u, %ssuspended)"
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr "ストリームエラー: %s"
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr "ストリームデãƒã‚¤ã‚¹ä¼‘æ­¢ %s"
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr "ストリームデãƒã‚¤ã‚¹å¾©å¸° %s"
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr "ストリームアンダーラン %s"
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr "ストリームオーãƒãƒ¼ãƒ©ãƒ³ %s"
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr "ストリーム開始 %s"
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "ストリームã¯ãƒ‡ãƒã‚¤ã‚¹ %s ã¸ç§»å‹• (%u, %ssuspended).%s"
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "not "
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr "ストリームãƒãƒƒãƒ•ã‚¡ã®å±žæ€§å¤‰æ›´ %s"
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr "接続ãŒç¢ºç«‹ %s"
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr "接続失敗: %s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF å–å¾—"
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr "write() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "ä¿¡å·å–å¾—ã€é€€å‡ºä¸­"
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr "レイテンシーå–å¾—ã«å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "時間: %0.3f sec ; レイテンシー: %0.0f usec"
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+"%s [options]\n"
+"\n"
+" -h, --help ã“ã®ãƒ˜ãƒ«ãƒ—を表示\n"
+" --version ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã‚’表示\n"
+"\n"
+" -r, --record éŒ²éŸ³ç”¨ã®æŽ¥ç¶šã‚’ä½œæˆ\n"
+" -p, --playback å†ç”Ÿç”¨ã®æŽ¥ç¶šã‚’作æˆ\n"
+"\n"
+" -v, --verbose 詳細æ“作を有効ã«ã™ã‚‹\n"
+"\n"
+" -s, --server=SERVER 接続先サーãƒãƒ¼ã®åå‰ \n"
+" -d, --device=DEVICE 接続先シンク/ソースã®åå‰ \n"
+" -n, --client-name=NAME サーãƒãƒ¼ã§ã“ã®ã‚¯ãƒ©ã‚¤ã‚¢ãƒ³ãƒˆã¸ã®ã‚³ãƒ¼ãƒ«"
+"方法 \n"
+" --stream-name=NAME サーãƒãƒ¼ä¸Šã§ã“ã®ã‚¹ãƒˆãƒªãƒ¼ãƒ ã¸ã®ã‚³ãƒ¼ãƒ«"
+"方法\n"
+" --volume=VOLUME åˆæœŸ (リニア) ボリューム幅を指定 "
+"0...65536\n"
+" --rate=SAMPLERATE サンプルレートを Hz ã§è¡¨ç¤º (デフォル"
+"ト㯠44100)\n"
+" --format=SAMPLEFORMAT サンプルタイプ, 次ã®ï¼‘㤠s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (デフォルト㯠"
+"s16ne)\n"
+" --channels=CHANNELS ãƒãƒ£ãƒ³ãƒãƒ«ã®æ•°, モノ用ã«ï¼‘, ステレオ"
+"用ã«ï¼’\n"
+" (デフォルト㯠2)\n"
+" --channel-map=CHANNELMAP デフォルトã®ä»£ã‚りã«ä½¿ç”¨ã™ã‚‹ãƒãƒ£ãƒ³ãƒ"
+"ルマップ \n"
+" --fix-format ã‚¹ãƒˆãƒªãƒ¼ãƒ ã®æŽ¥ç¶šå…ˆã§ã‚るシンクã‹ã‚‰ã‚µ"
+"ンプル形å¼ã‚’å–ã‚‹ \n"
+"\n"
+" --fix-rate ã‚¹ãƒˆãƒªãƒ¼ãƒ ã®æŽ¥ç¶šå…ˆã§ã‚るシンクã‹ã‚‰ã‚µ"
+"ンプルレートをå–ã‚‹ \n"
+"\n"
+" --fix-channels ã‚¹ãƒˆãƒªãƒ¼ãƒ ã®æŽ¥ç¶šå…ˆã§ã‚るシンクã‹ã‚‰"
+"ãƒãƒ£ãƒ³ãƒãƒ«æ•°ã¨ ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—ã‚’å–ã‚‹\n"
+"\n"
+" --no-remix ãƒãƒ£ãƒ³ãƒãƒ«ã®ã‚¢ãƒƒãƒ—ミックスやダウン"
+"ミックスをã—ãªã„\n"
+" --no-remap åå‰ã®ä»£ã‚りã«ã‚¤ãƒ³ãƒ‡ãƒƒã‚¯ã‚¹ã§ãƒãƒ£ãƒ³ãƒ"
+"ルをマップã™ã‚‹\n"
+" --latency=BYTES 指定レイテンシーをãƒã‚¤ãƒˆã§è¦æ±‚ \n"
+" --process-time=BYTES è¦æ±‚æ¯Žã®æŒ‡å®šãƒ—ロセスタイムをãƒã‚¤ãƒˆã§"
+"è¦æ±‚ \n"
+" --property=PROPERTY=VALUE 指定プロパティを指定値ã«ã‚»ãƒƒãƒˆ\n"
+" --raw 録音/å†ç”Ÿã®ç”Ÿã® PCM データ\n"
+" --file-format=FFORMAT 録音/å†ç”Ÿã®ãƒ•ォーマットã—㟠PCM デー"
+"ã‚¿\n"
+" --list-file-formats 利用å¯èƒ½ãªãƒ•ァイル形å¼ã‚’一覧表示\n"
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pacat %s\n"
+"libpulse %s ã§ã‚³ãƒ³ãƒ‘イル \n"
+"libpulse %s ã§æŽ¥ç¶š\n"
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr "無効ãªã‚¯ãƒ©ã‚¤ã‚¢ãƒ³ãƒˆå '%s'"
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr "無効ãªã‚¹ãƒˆãƒªãƒ¼ãƒ å '%s'"
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr "無効ãªãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ— '%s'"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr "無効ãªãƒ¬ã‚¤ãƒ†ãƒ³ã‚·ãƒ¼ä»•様 '%s'"
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "無効ãªãƒ—ロセスタイム仕様 '%s'"
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr "無効ãªãƒ—ロパティ '%s'"
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "䏿˜Žãªãƒ•ã‚¡ã‚¤ãƒ«å½¢å¼ '%s'"
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "無効ãªã‚µãƒ³ãƒ—ル仕様"
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr "open(): %s"
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "引数ãŒå¤šéŽãŽã¾ã™ã€‚"
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "ファイル用ã®ã‚µãƒ³ãƒ—ル仕様ã®ç”Ÿæˆã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "オーディオファイルを開ãã®ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "警告: 指定ã•れãŸã‚µãƒ³ãƒ—ルã®ä»•様ã¯ãƒ•ァイルã‹ã‚‰ã®ä»•様ã§ä¸Šæ›¸ãã•れã¾ã™ã€‚"
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ファイルã‹ã‚‰ã®ã‚µãƒ³ãƒ—ãƒ«ä»•æ§˜ã®æ±ºå®šã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "警告: ファイルã‹ã‚‰ã®ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—ã®æ±ºå®šã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—ã¯ã‚µãƒ³ãƒ—ル仕様ã«ä¸€è‡´ã—ã¾ã›ã‚“。"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "警告: ファイルã¸ã®ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—書ãè¾¼ã¿ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"サンプル仕様 '%s' 㨠ãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ— '%s' ã§ %s ストリームを開ã„ã¦ã„ã¾ã™ã€‚"
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "録音"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "å†ç”Ÿ"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() ã¯å¤±æ•—"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() ã¯å¤±æ•—"
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() ã¯å¤±æ•—"
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() ã¯å¤±æ•—: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() ã¯å¤±æ•—"
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() ã¯å¤±æ•—"
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr "fork(): %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr "休止ã®å¤±æ•—: %s\n"
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr "復帰ã®å¤±æ•—: %s\n"
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr "警告: サウンドサーãƒãƒ¼ã¯ãƒ­ãƒ¼ã‚«ãƒ«ã§ã¯ã‚りã¾ã›ã‚“。休止ã—ã¾ã›ã‚“。\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "接続失敗 : %s\n"
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr "SIGINT å–å¾—ã€é€€å‡ºä¸­ \n"
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr "警告: å­ãƒ—ロセスã¯ä¿¡å· %u ã§çµ‚了ã—ã¾ã—ãŸ\n"
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+"%s [オプション] ... \n"
+"\n"
+" -h, --help ã“ã®ãƒ˜ãƒ«ãƒ—を表示\n"
+" --version ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã‚’表示\n"
+" -s, --server=SERVER 接続先サーãƒãƒ¼ã®åå‰ \n"
+"\n"
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pasuspender %s\n"
+"libpulse %s ã§ã‚³ãƒ³ãƒ‘イル\n"
+"libpulse %s ã§ãƒªãƒ³ã‚¯\n"
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() ã¯å¤±æ•—\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() ã¯å¤±æ•—\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() ã¯å¤±æ•—\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "統計ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr "ç¾åœ¨ä½¿ç”¨ä¸­: %u ブロックã¯åˆè¨ˆ %s ãƒã‚¤ãƒˆã‚’å«ã‚€ \n"
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr "ç·å¯¿å‘½ã®æœŸé–“中ã«å‰²ã‚Šå½“ã¦: %u ブロックã¯åˆè¨ˆ %s ãƒã‚¤ãƒˆã‚’å«ã‚€\n"
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr "サンプルã®ã‚­ãƒ£ãƒƒã‚·ãƒ¥ã‚µã‚¤ã‚º: %s\n"
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr "サーãƒãƒ¼æƒ…å ±ã®å–å¾—ã«å¤±æ•— : %s"
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+"ユーザーå: %s\n"
+"ホストå: %s\n"
+"サーãƒãƒ¼å: %s\n"
+"サーãƒãƒ¼ãƒãƒ¼ã‚¸ãƒ§ãƒ³: %s\n"
+"デフォルトサンプル仕様: %s\n"
+"デフォルトãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—: %s\n"
+"デフォルトシンク: %s\n"
+"デフォルトソース: %s\n"
+"クッキー: %08x\n"
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr "シンク情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"シンク #%u\n"
+"\t状態: %s\n"
+"\tåå‰: %s\n"
+"\t説明: %s\n"
+"\tドライãƒãƒ¼: %s\n"
+"\tサンプル仕様: %s\n"
+"\tãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—: %s\n"
+"\tオーナーモジュール: %u\n"
+"\tミュート: %s\n"
+"\tボリューム: %s%s%s\n"
+"\t ãƒãƒ©ãƒ³ã‚¹ %0.2f\n"
+"\tベースボリューム: %s%s%s\n"
+"\tモニターソース: %s\n"
+"\tレイテンシー: %0.0f usec, 設定 %0.0f usec\n"
+"\tフラグ: %s%s%s%s%s%s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tãƒãƒ¼ãƒˆ:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\t活動中ãƒãƒ¼ãƒˆ: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "ソース情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"ソース #%u\n"
+"\t状態: %s\n"
+"\tåå‰: %s\n"
+"\t説明: %s\n"
+"\tドライãƒãƒ¼: %s\n"
+"\tサンプル仕様: %s\n"
+"\tãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—: %s\n"
+"\tオーナーモジュール: %u\n"
+"\tミュート: %s\n"
+"\tボリューム: %s%s%s\n"
+"\t ãƒãƒ©ãƒ³ã‚¹ %0.2f\n"
+"\tベースボリューム: %s%s%s\n"
+"\tシンクã®ãƒ¢ãƒ‹ã‚¿ãƒ¼: %s\n"
+"\tレイテンシー: %0.0f usec, 設定 %0.0f usec\n"
+"\tフラグ: %s%s%s%s%s%s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "n/a"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr "モジュール情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"モジュール #%u\n"
+"\tåå‰: %s\n"
+"\t引数: %s\n"
+"\t使用度カウンター: %s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr "クライアント情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"クライアント #%u\n"
+"\tドライãƒãƒ¼: %s\n"
+"\tオーナーモジュール: %s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "カード情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"カード #%u\n"
+"\tåå‰: %s\n"
+"\tドライãƒãƒ¼: %s\n"
+"\tモジュール: %s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\tプロフィール:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr "\t有効ãªãƒ—ロフィール: %s\n"
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "シンク入力情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"シンク入力 #%u\n"
+"\tドライãƒãƒ¼: %s\n"
+"\tオーナーモジュール: %s\n"
+"\tクライアント: %s\n"
+"\tシンク: %u\n"
+"\tサンプル仕様: %s\n"
+"\tãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—: %s\n"
+"\tミュート: %s\n"
+"\tボリューム: %s\n"
+"\t %s\n"
+"\t ãƒãƒ©ãƒ³ã‚¹ %0.2f\n"
+"\tãƒãƒƒãƒ•ァレイテンシー: %0.0f usec\n"
+"\tシンクレイテンシー: %0.0f usec\n"
+"\tå†ã‚µãƒ³ãƒ—ル方法: %s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "ソース出力情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"ソース出力 #%u\n"
+"\tドライãƒãƒ¼: %s\n"
+"\tオーナーモジュール: %s\n"
+"\tクライアント: %s\n"
+"\tソース: %u\n"
+"\tサンプル仕様: %s\n"
+"\tãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—: %s\n"
+"\tãƒãƒƒãƒ•ァレイテンシー: %0.0f usec\n"
+"\tソースレイテンシー: %0.0f usec\n"
+"\tå†ã‚µãƒ³ãƒ—ル方法: %s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "サンプル情報ã®å–å¾—ã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"サンプル #%u\n"
+"\tåå‰: %s\n"
+"\tサンプル仕様: %s\n"
+"\tãƒãƒ£ãƒ³ãƒãƒ«ãƒžãƒƒãƒ—: %s\n"
+"\tボリューム: %s\n"
+"\t %s\n"
+"\t ãƒãƒ©ãƒ³ã‚¹ %0.2f\n"
+"\t継続期間: %0.1fs\n"
+"\tサイズ: %s\n"
+"\tレイジー: %s\n"
+"\tファイルåe: %s\n"
+"\tプロパティ:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "失敗: %s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "サンプルã®ã‚¢ãƒƒãƒ—ロードã«å¤±æ•—ã—ã¾ã—ãŸ: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "ãƒ•ã‚¡ã‚¤ãƒ«ã®æ—©æœŸçµ‚了"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "無効ãªã‚µãƒ¼ãƒãƒ¼"
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT ã‚’å–å¾—ã€é€€å‡ºä¸­"
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+"%s [オプション] stat\n"
+"%s [オプション] list\n"
+"%s [オプション] exit\n"
+"%s [オプション] upload-sample FILENAME [NAME]\n"
+"%s [オプション] play-sample NAME [SINK]\n"
+"%s [オプション] remove-sample NAME\n"
+"%s [オプション] move-sink-input SINKINPUT SINK\n"
+"%s [オプション] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [オプション] load-module NAME [ARGS ...]\n"
+"%s [オプション] unload-module MODULE\n"
+"%s [オプション] suspend-sink SINK 1|0\n"
+"%s [オプション] suspend-source SOURCE 1|0\n"
+"%s [オプション] set-card-profile CARD PROFILE\n"
+"%s [オプション] set-sink-port SINK PORT\n"
+"%s [オプション] set-source-port SOURCE PORT\n"
+"%s [オプション] set-sink-volume SINK VOLUME\n"
+"%s [オプション] set-source-volume SOURCE VOLUME\n"
+"%s [オプション] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [オプション] set-sink-mute SINK 1|0\n"
+"%s [オプション] set-source-mute SOURCE 1|0\n"
+"%s [オプション] set-sink-input-mute SINKINPUT 1|0\n"
+"\n"
+" -h, --help ã“ã®ãƒ˜ãƒ«ãƒ—を表示\n"
+" --version ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã‚’表示\n"
+"\n"
+" -s, --server=SERVER 接続先サーãƒãƒ¼ã®åå‰ \n"
+" -n, --client-name=NAME サーãƒãƒ¼ã§ã“ã®ã‚¯ãƒ©ã‚¤ã‚¢ãƒ³ãƒˆã¸ã®ã‚³ãƒ¼ãƒ«"
+"方法 \n"
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pactl %s\n"
+"libpulse %s ã§ã‚³ãƒ³ãƒ‘イル\n"
+"libpulse %s ã§ãƒªãƒ³ã‚¯\n"
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "ロードã™ã‚‹ã‚µãƒ³ãƒ—ルファイルを指定ã—ã¦ä¸‹ã•ã„"
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "サウンドファイルを開ãã®ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "警告: ファイルã‹ã‚‰ã‚µãƒ³ãƒ—ル仕様を決定ã™ã‚‹ã®ã«å¤±æ•—ã—ã¾ã—ãŸã€‚"
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "å†ç”Ÿã™ã‚‹ã‚µãƒ³ãƒ—ルåを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "削除ã™ã‚‹ã‚µãƒ³ãƒ—ルåを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™ã€‚"
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "シンク入力インデックスã¨ã‚·ãƒ³ã‚¯ã‚’指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "ソース出力インデックスã¨ã‚½ãƒ¼ã‚¹ã‚’指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "モジュールåã¨å¼•数を指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "モジュールインデックスを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+"シンクã¯ï¼‘ã¤ä»¥ä¸Šã¯æŒ‡å®šã§ãã¾ã›ã‚“ã€‚ãƒ–ãƒ¼ãƒªã‚¢ãƒ³å€¤ã‚’ï¼‘ã¤æŒ‡å®šã™ã‚‹å¿…è¦ãŒã‚りã¾ã™ã€‚"
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr ""
+"ソースã¯ï¼‘ã¤ä»¥ä¸Šã¯æŒ‡å®šã§ãã¾ã›ã‚“ã€‚ãƒ–ãƒ¼ãƒªã‚¢ãƒ³å€¤ã‚’ï¼‘ã¤æŒ‡å®šã™ã‚‹å¿…è¦ãŒã‚りã¾ã™ã€‚"
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "カードã®åå‰/インデックスã¨ãƒ—ロフィールåを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "シンクã®åå‰/インデックスã¨ãƒãƒ¼ãƒˆåを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "ソースã®åå‰/インデックスã¨ãƒãƒ¼ãƒˆåを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "シンクã®åå‰/インデックスã¨ãƒœãƒªãƒ¥ãƒ¼ãƒ ã‚’指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "無効ãªãƒœãƒªãƒ¥ãƒ¼ãƒ ä»•様"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "ソースã®åå‰/インデックスã¨ãƒœãƒªãƒ¥ãƒ¼ãƒ ã‚’指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "シンク入力インデックスã¨ãƒœãƒªãƒ¥ãƒ¼ãƒ ã‚’指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "無効ãªã‚·ãƒ³ã‚¯å…¥åŠ›ã‚¤ãƒ³ãƒ‡ãƒƒã‚¯ã‚¹"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "シンクã®åå‰/インデックスã¨ãƒŸãƒ¥ãƒ¼ãƒˆãƒ–ーリアンを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "ソースã®åå‰/インデックスã¨ãƒŸãƒ¥ãƒ¼ãƒˆãƒ–ーリアンを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "シンク入力インデックスã¨ãƒŸãƒ¥ãƒ¼ãƒˆãƒ–ーリアンを指定ã™ã‚‹å¿…è¦ãŒã‚りã¾ã™"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "無効ãªã‚·ãƒ³ã‚¯å…¥åŠ›ã‚¤ãƒ³ãƒ‡ãƒƒã‚¯ã‚¹ä»•æ§˜"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "有効ãªã‚³ãƒžãƒ³ãƒ‰ãŒæŒ‡å®šã•れã¦ã„ã¾ã›ã‚“"
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d X11 ãƒ‡ã‚£ã‚¹ãƒ—ãƒ¬ã‚¤ã«æŽ¥ç¶šã—ãŸç¾åœ¨ã® PulseAudio ã®ãƒ‡ãƒ¼ã‚¿ã‚’表示 (デフォル"
+"ト)\n"
+" -e X11 ディスプレイã«ãƒ­ãƒ¼ã‚«ãƒ« PulseAudio データをエキスãƒãƒ¼ãƒˆ\n"
+" -i X11 ディスプレイã‹ã‚‰ãƒ­ãƒ¼ã‚«ãƒ«ç’°å¢ƒå¤‰æ•°ã¨ã‚¯ãƒƒã‚­ãƒ¼ã« PulseAudio データをイ"
+"ンãƒãƒ¼ãƒˆ \n"
+" -r X11 ディスプレイã‹ã‚‰ PulseAudio データを削除\n"
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr "ã‚³ãƒžãƒ³ãƒ‰ãƒ©ã‚¤ãƒ³ã®æ§‹æ–‡è§£æžã«å¤±æ•—\n"
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr "サーãƒãƒ¼: %s\n"
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr "ソース: %s\n"
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr "シンク: %s\n"
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr "クッキー: %s\n"
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr "ã‚¯ãƒƒã‚­ãƒ¼ãƒ‡ãƒ¼ã‚¿ã®æ§‹æ–‡è§£æžã«å¤±æ•—\n"
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr "クッキーデータã®ä¿å­˜ã«å¤±æ•—\n"
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr "クライアント設定ファイルã®ãƒ­ãƒ¼ãƒ‰ã«å¤±æ•—\n"
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr "環境設定データã®èª­ã¿è¾¼ã¿ã«å¤±æ•— \n"
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr "FQDN ã®å–å¾—ã«å¤±æ•— \n"
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr "クッキーデータã®ãƒ­ãƒ¼ãƒ‰ã«å¤±æ•—\n"
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr "ã¾ã å®Ÿè£…ã•れã¦ã„ã¾ã›ã‚“\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"PulseAudio デーモン自身ãŒç¨¼åƒã—ã¦ã„ãªã„ã‹ã€åˆã¯ã‚»ãƒƒã‚·ãƒ§ãƒ³ãƒ‡ãƒ¼ãƒ¢ãƒ³ã¨ã—ã¦ç¨¼åƒã—"
+"ã¦ã„ã¾ã›ã‚“。"
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr "ソケット (PF_UNIX, SOCK_STREAM, 0): %s"
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr "connect(): %s"
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr "PulseAudio ã®ã‚­ãƒ«ã«å¤±æ•—"
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr "デーモンãŒå¿œç­”ã—ã¾ã›ã‚“"
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr "poll(): %s"
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr "read(): %s"
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr "write(): %s"
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr "autospawn ロックã«ã‚¢ã‚¯ã‚»ã‚¹ã§ãã¾ã›ã‚“"
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA ãŒæ–°è¦ã®ãƒ‡ãƒ¼ã‚¿ã‚’デãƒã‚¤ã‚¹ã«æ›¸ã込むよã†ã«å‚¬ä¿ƒã—ã¾ã—ãŸãŒã€æ›¸ã込むã“ã¨ãŒ "
+"ã‚りã¾ã›ã‚“!\n"
+"ã“れã¯å¤šåˆ†ã€ALSA ドライãƒãƒ¼ '%s' 内ã®ãƒã‚°ã§ã™ã€‚ã“ã®å•題を ALSA 開発者㫠報告"
+"ã—ã¦ä¸‹ã•ã„。\n"
+"POLLOUT セットã§å‘¼ã³èµ·ã“ã•れã¾ã—ãŸãŒã€ãã®çµæžœã¨ã—ã¦ã® snd_pcm_avail() 㯠0 "
+"åˆã¯ ä»–ã®å€¤ < min_avail ã‚’è¿”ã—ã¾ã—ãŸã€‚"
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA ã¯ãƒ‡ãƒã‚¤ã‚¹ã‹ã‚‰æ–°è¦ãƒ‡ãƒ¼ã‚¿ã‚’読ã¿è¾¼ã‚€ã‚ˆã†ã«å‚¬ä¿ƒã—ã¾ã—ãŸãŒã€èª­ã¿è¾¼ã‚€ã‚‚ã®ãŒ "
+"ã‚りã¾ã›ã‚“!\n"
+"ã“れã¯å¤šåˆ†ã€ALSA ドライãƒãƒ¼'%s' 内ã®ãƒã‚°ã§ã™ã€‚ã“ã®å•題を ALSA 開発者㫠報告ã—"
+"ã¦ä¸‹ã•ã„。\n"
+"POLLIN セットã§å‘¼ã³èµ·ã“ã•れã¾ã—ãŸãŒã€ãã®çµæžœã¨ã—ã¦ã® snd_pcm_avail() 㯠0 åˆ"
+"㯠他ã®å€¤ < min_avail ã‚’è¿”ã—ã¾ã—ãŸã€‚"
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "オフ"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "ãƒã‚¤ãƒ•ァイå†ç”Ÿ (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "ãƒã‚¤ãƒ•ァイキャプãƒãƒ£ (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "テレフォニーデュプレックス (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "PulseAudio サウンドサーãƒãƒ¼"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "出力デãƒã‚¤ã‚¹"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "入力デãƒã‚¤ã‚¹"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ 上ã®ã‚ªãƒ¼ãƒ‡ã‚£ã‚ª"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "入力"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ドッキングステーション入力"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ドッキングステーションマイクロフォン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "ラインイン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "マイクロフォン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "外部マイクロフォン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "内部マイクロフォン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "ラジオ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "ビデオ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "自動ゲイン制御"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "自動ゲイン制御ãªã—"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "ブースト"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "ブーストãªã—"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "アンプ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "アンプãªã—"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "ブースト"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "ブーストãªã—"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "アナログヘッドフォン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "アナログ入力"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "アナログマイクロフォン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "アナログラインイン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "アナログラジオ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "アナログビデオ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "アナログ出力"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "アナログヘッドフォン"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "アナログ出力 (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "アナログモノ出力"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "アナログステレオ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "アナログモノ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "アナログステレオ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "アナログサラウンド 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "アナログサラウンド 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "アナログサラウンド 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "アナログサラウンド 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "アナログサラウンド 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "アナログサラウンド 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "アナログサラウンド 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "アナログサラウンド 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "アナログサラウンド 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "アナログサラウンド 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "アナログサラウンド 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "デジタルステレオ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "デジタルサラウンド 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "デジタルサラウンド 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "デジタルサラウンド 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "デジタルステレオ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "アナログモノデュプレックス"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "アナログステレオデュプレックス"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "デジタルステレオデュプレックス (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "低周波エミッタ"
diff --git a/po/kn.po b/po/kn.po
index 0a5ba6be..96afa315 100644
--- a/po/kn.po
+++ b/po/kn.po
@@ -1,67 +1,28 @@
-# translation of pulseaudio.master-tx.pulseaudio.po to Kannada
+# translation of pulseaudio.master-tx.kn.po to Kannada
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Shankar Prasad <svenkate@redhat.com>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio.master-tx.pulseaudio\n"
+"Project-Id-Version: pulseaudio.master-tx.kn\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-07 11:13+0530\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-08 11:50+0530\n"
"Last-Translator: Shankar Prasad <svenkate@redhat.com>\n"
-"Language-Team: Kannada <en@li.org>\n"
+"Language-Team: Kannada <kde-l10n-kn@kde.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Generator: KBabel 1.11.4\n"
+"X-Generator: Lokalize 1.0\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "ಅನಲಾಗೠಮೊನೊ"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "ಅನಲಾಗೠಸà³à²Ÿà³€à²°à²¿à²¯à³‹"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "ಡಿಜಿಟಲೠಸà³à²Ÿà³€à²°à²¿à²¯à³‹ (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "ಡಿಜಿಟಲೠಸà³à²Ÿà³€à²°à²¿à²¯à³‹ (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "ಅನಲಾಗೠ4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "ಡಿಜಿಟಲೠಸರೌಂಡೠ4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "ಅನಲಾಗೠಸರೌಂಡೠ4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "ಅನಲಾಗೠಸರೌಂಡೠ5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "ಅನಲಾಗೠಸರೌಂಡೠ5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "ಡಿಜಿಟಲೠಸರೌಂಡೠ5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "ಡಿಜಿಟಲೠಸರೌಂಡೠ7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -73,7 +34,7 @@ msgstr ""
"ಇದಕà³à²•ೆ ALSA ಚಾಲಕ '%s' ದಲà³à²²à²¿à²¨ ಒಂದೠದೋಷದ ಕಾರಣವಿರಬಹà³à²¦à³. ದಯವಿಟà³à²Ÿà³à²ˆ ತೊಂದರೆಯನà³à²¨à³ ALSA "
"ವಿಕಸನಗಾರರ ಗಮನಕà³à²•ೆ ತನà³à²¨à²¿."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -85,7 +46,7 @@ msgstr ""
"ಇದಕà³à²•ೆ ALSA ಚಾಲಕ '%s' ದಲà³à²²à²¿à²¨ ಒಂದೠದೋಷದ ಕಾರಣವಿರಬಹà³à²¦à³. ದಯವಿಟà³à²Ÿà³à²ˆ ತೊಂದರೆಯನà³à²¨à³ ALSA "
"ವಿಕಸನಗಾರರ ಗಮನಕà³à²•ೆ ತನà³à²¨à²¿."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -97,13 +58,47 @@ msgstr ""
"ಇದಕà³à²•ೆ ALSA ಚಾಲಕ '%s' ದಲà³à²²à²¿à²¨ ಒಂದೠದೋಷದ ಕಾರಣವಿರಬಹà³à²¦à³. ದಯವಿಟà³à²Ÿà³à²ˆ ತೊಂದರೆಯನà³à²¨à³ ALSA "
"ವಿಕಸನಗಾರರ ಗಮನಕà³à²•ೆ ತನà³à²¨à²¿."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "ಯಾವಾಗಲೂ ಒಂದೠಸಿಂಕà³â€Œ ಅನà³à²¨à³ ಲೋಡೠಮಾಡಿರà³à²¤à³à²¤à²¦à³†, ಅದೠಶೂನà³à²¯à²µà²¾à²—ಿದà³à²¦à²°à³‚ ಸಹ"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ಡಮà³à²®à²¿ ಔಟà³â€Œà²ªà³à²Ÿà³"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "ವರà³à²šà³à²µà²²à³ LADSPA ಸಿಂಕà³"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<ಸಿಂಕà³â€Œà²¨ ಹೆಸರà³> sink_properties=<ಸಿಂಕà³â€Œà²¨ ಗà³à²£à²—ಳà³> master=<ಫಿಲà³à²Ÿà²°à³ "
+"ಮಾಡಬೇಕಿರà³à²µ ಸಿಂಕà³â€Œà²¨ ಹೆಸರà³> format=<ನಮೂನೆ ವಿನà³à²¯à²¾à²¸> rate=<ನಮೂನೆ ದರ> "
+"channels=<ಚಾನಲà³â€Œà²—ಳ ಸಂಖà³à²¯à³†> channel_map=<ಚಾನಲೠನಕà³à²·à³†> plugin=<ladspa ಪà³à²²à²—à³â€Œà²‡à²¨à³ ಹೆಸರà³> "
+"label=<ladspa ಪà³à²²à²—à³â€Œà²‡à²¨à³ ಹೆಸರà³> control=<ವಿರಾಮ ಚಿಹà³à²¨à³†à²—ಳನà³à²¨à³ ಹೊಂದಿರà³à²µ ಇನà³â€Œà²ªà³à²Ÿà³ ನಿಯಂತà³à²°à²£ "
+"ಮೌಲà³à²¯à²—ಳ ಪಟà³à²Ÿà²¿>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "ಕà³à²²à²¾à²•à³â€Œ ಮಾಡಲಾದ NULL ಸಿಂಕà³"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "ಶೂನà³à²¯ ಔಟà³â€Œà²ªà³à²Ÿà³"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "ಆಂತರಿಕ ಆಡಿಯೊ"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
-msgstr "ಮಾಡೆಮà³:"
+msgstr "ಮಾಡೆಮà³"
#: ../src/daemon/ltdl-bind-now.c:124
msgid "Failed to find original lt_dlopen loader."
@@ -117,220 +112,98 @@ msgstr "ಹೊಸ dl ಲೋಡರೠಅನà³à²¨à³ ನಿಯೋಜಿಸà³à²µ
msgid "Failed to add bind-now-loader."
msgstr "bind-now-ಲೋಡರೠಅನà³à²¨à³ ಸೇರಿಸಲಾಗಿಲà³à²²."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಬಸà³â€Œà²—ೆ ಸಂಪರà³à²•ಜೋಡಿಸಲೠಸಾಧà³à²¯à²µà²¾à²—ಿಲà³à²²: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PID ಇಂದ ಕಾಲರೠಅನà³à²¨à³ ಪಡೆಯಲಾಗಿಲà³à²²: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "ಕಾಲರೠವಸà³à²¤à³à²µà²¿à²¨à²²à³à²²à²¿ UID ಅನà³à²¨à³ ಅಣಿಗೊಳಿಸಲಾಗಲಿಲà³à²²."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK ಅಧಿವೇಶನವನà³à²¨à³ ಪಡೆಯಲಾಗಲಿಲà³à²²."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "ಅಧಿವೇಶನದ ವಸà³à²¤à³à²µà²¿à²¨à²²à³à²²à²¿ UID ಅನà³à²¨à³ ಅಣಿಗೊಳಿಸಲಾಗಲಿಲà³à²²."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitAction ಅನà³à²¨à³ ನಿಯೋಜಿಸಲಾಗಿಲà³à²²."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "action_id ಅನà³à²¨à³ ಹೊಂದಿಸಲೠಸಾಧà³à²¯à²µà²¾à²—ಿಲà³à²²"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext ಅನà³à²¨à³ ನಿಯೋಜಿಸಲಾಗಿಲà³à²²."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContext ಅನà³à²¨à³ ಆರಂಭಿಸಲಾಗಿಲà³à²²: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "ಕಾಲರೠಅಧೀಕೃತವಾಗಿದà³à²¦à³† ಎಂದೠನಿರà³à²§à²°à²¿à²¸à²²à³ ಸಾಧà³à²¯à²µà²¾à²—ಿಲà³à²²: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "auth ಅನà³à²¨à³ ಪಡೆಯಲೠಸಾಧà³à²¯à²µà²¾à²—ಿಲà³à²²: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit '%s' ನೊಂದಿಗೆ ಪà³à²°à²¤à³à²¯à³à²¤à³à²¤à²°à²¿à²¸à²¿à²¦à³†"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "%s ನಿಂದ ಸಂಕೇತವೠದೊರೆತಿದೆ."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "ನಿರà³à²—ಮಿಸà³à²¤à³à²¤à²¿à²¦à³†."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "ಬಳಕೆದಾರ '%s' ಅನà³à²¨à³ ಪತà³à²¤à³† ಮಾಡಲೠವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "ಗà³à²‚ಪೠ'%s' ಅನà³à²¨à³ ಪತà³à²¤à³† ಮಾಡಲೠವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "ಬಳಕೆದಾರ '%s' (UID %lu) ಹಾಗೠಗà³à²‚ಪೠ'%s' (GID %lu) ಕಂಡà³à²¬à²‚ದಿದೆ."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "ಬಳಕೆದಾರ '%s' ರ GID ಹಾಗೠಗà³à²‚ಪೠ'%s' ತಾಳೆಯಾಗà³à²¤à³à²¤à²¿à²²à³à²²."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "ಬಳಕೆದಾರ '%s' ರ ನೆಲೆ ಕೋಶವೠ'%s' ಆಗಿಲà³à²², ಆಲಕà³à²·à²¿à²¸à²²à²¾à²—à³à²¤à³à²¤à²¿à²¦à³†."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s' ಅನà³à²¨à³ ರಚಿಸà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "ಗà³à²‚ಪಿನ ಪಟà³à²Ÿà²¿à²¯à²¨à³à²¨à³ ಬದಲಾಯಿಸಲೠವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID ಅನà³à²¨à³ ಬದಲಾಯಿಸಲೠವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID ಅನà³à²¨à³ ಬದಲಾಯಿಸಲೠವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "ರೂಟೠಸವಲತà³à²¤à³à²—ಳನà³à²¨à³ ಯಶಸà³à²µà²¿à²¯à²¾à²—ಿ ಬಿಡಲಾಗಿದೆ."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "ವà³à²¯à²µà²¸à³à²¥à³†à²¯à²¾à²¦à³à²¯à²‚ತದ ಕà³à²°à²®à²•à³à²•ೆ ಈ ಪà³à²²à²¾à²Ÿà³â€Œà²«à²¾à²°à³à²®à²¿à²¨à²²à³à²²à²¿ ಬೆಂಬಲವಿಲà³à²²."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "ಆಜà³à²žà²¾ ಸಾಲನà³à²¨à³ ಪಾರà³à²¸à³ ಮಾಡà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"ನಾವೠ'%s' ಗà³à²‚ಪಿನಲà³à²²à²¿à²¦à³à²¦à³‡à²µà³†, ಹಾಗೠಹೆಚà³à²šà³-ಆದà³à²¯à²¤à³† ಶೆಡà³à²¯à³‚ಲಿಂಗೠಅನà³à²¨à³ ಅನà³à²®à²¤à²¿à²¸à³à²¤à³à²¤à³‡à²µà³†."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "ನಾವೠ'%s' ಗà³à²‚ಪಿನಲà³à²²à²¿à²¦à³à²¦à³‡à²µà³†, ಹಾಗೠರಿಯಲà³-ಟೈಮೠಶೆಡà³à²¯à³‚ಲಿಂಗೠಅನà³à²¨à³ ಅನà³à²®à²¤à²¿à²¸à³à²¤à³à²¤à³‡à²µà³†."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "ಹೆಚà³à²šà³-ಆದà³à²¯à²¤à³† ಸವಲತà³à²¤à²¨à³à²¨à³ ಪಡೆದà³à²•ೊ ಅನà³à²¨à³ PolicyKit ಅನà³à²®à²¤à²¿à²¸à³à²¤à³à²¤à²¦à³†."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "ಹೆಚà³à²šà³-ಆದà³à²¯à²¤à³† ಸವಲತà³à²¤à²¨à³à²¨à³ ಪಡೆದà³à²•ೊ ಅನà³à²¨à³ PolicyKit ನಿರಾಕರಿಸà³à²¤à³à²¤à²¦à³†."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "ರಿಯಲà³-ಟೈಮೠಸವಲತà³à²¤à²¨à³à²¨à³ ಪಡೆದà³à²•ೊ ಅನà³à²¨à³ PolicyKit ಅನà³à²®à²¤à²¿à²¸à³à²¤à³à²¤à²¦à³†."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "ರಿಯಲà³-ಟೈಮೠಸವಲತà³à²¤à²¨à³à²¨à³ ಪಡೆದà³à²•ೊ ಅನà³à²¨à³ PolicyKit ನಿರಾಕರಿಸà³à²¤à³à²¤à²¦à³†."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"SUID ರೂಟೠಅನà³à²¨à³ ಕರೆಯಲಾಗಿದೆ ಹಾಗೠಸಂರಚನೆಯಲà³à²²à²¿ ರಿಯಲà³-ಟೈಲೠಹಾಗà³/ಅಥವ ಹೆಚà³à²šà³-ಆದà³à²¯à²¤à³† "
-"ಶೆಡà³à²¯à³‚ಲಿಂಗà³â€Œà²—ೆ ಮನವಿ ಸಲà³à²²à²¿à²¸à²²à²¾à²—ಿದೆ. ಆದರೆ, ಅಗತà³à²¯à²µà²¿à²°à³à²µ ಸವಲತà³à²¤à³à²—ಳೠನಮà³à²®à²²à³à²²à²¿à²²à³à²²:\n"
-"ನಾವೠ'%s' ಗà³à²‚ಪಿನಲà³à²²à²¿à²²à³à²²,ಮನವಿ ಸಲà³à²²à²¿à²¸à²²à²¾à²¦ ಸವಲತà³à²¤à³à²—ಳನà³à²¨à³ ಒದಗಿಸಲೠPolicyKit "
-"ನಿರಾಕರಿಸಿದೆ ಹಾಗೠRLIMIT_NICE/RLIMIT_RTPRIO ಸಂಪನà³à²®à³‚ಲದ ಮಿತಿಯನà³à²¨à³ ಹೆಚà³à²šà²¿à²¸à²²à³ ನಮà³à²®à²¿à²‚ದ "
-"ಸಾಧà³à²¯à²µà²¿à²²à³à²².\n"
-"ರಿಯಲà³-ಟೈಲೠಹಾಗà³/ಅಥವ ಹೆಚà³à²šà³-ಆದà³à²¯à²¤à³† ಶೆಡà³à²¯à³‚ಲಿಂಗà³â€Œ ಅನà³à²¨à³ ಶಕà³à²¤à²—ೊಳಿಸಲೠದಯವಿಟà³à²Ÿà³ ಸೂಕà³à²¤à²µà²¾à²¦ "
-"PolicyKit ಸವಲತà³à²¤à³à²—ಳನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à²¿, ಅಥವ '%s' ನ ಸದಸà³à²¯à²°à²¾à²—ಿ, ಅಥವ ಈ ಬಳಕೆದಾರನಿಗಾಗಿ "
-"RLIMIT_NICE/RLIMIT_RTPRIO ಸಂಪನà³à²®à³‚ಲ ಮಿತಿಯನà³à²¨à³ ಹೆಚà³à²šà²¿à²¸à²¿."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"ಸಂರಚನೆಯಲà³à²²à²¿ ಹೆಚà³à²šà³-ಆದà³à²¯à²¤à³†à²¯ ಶೆಡà³à²¯à³‚ಲಿಂಗೠಅನà³à²¨à³ ಶಕà³à²¤à²—ೊಳಿಸಲಾಗಿದೆ ಆದರೆ ಪಾಲಿಸಿಯಿಂದ ಅನà³à²®à²¤à²¿ "
-"ಇಲà³à²²."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO ಅನà³à²¨à³ ಯಶಸà³à²µà²¿à²¯à²¾à²—ಿ ಹೆಚà³à²šà²¿à²¸à²²à²¾à²—ಿದೆ"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO ವಿಫಲಗೊಂಡಿದೆ: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "CAP_NICE ಅನà³à²¨à³ ಬಿಡಲಾಗà³à²¤à³à²¤à²¿à²¦à³†"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"ಸಂರಚನೆಯಲà³à²²à²¿ ರಿಯಲà³-ಟೈಮೠಶೆಡà³à²¯à³‚ಲಿಂಗೠಅನà³à²¨à³ ಶಕà³à²¤à²—ೊಳಿಸಲಾಗಿದೆ ಆದರೆ ಪಾಲಿಸಿಯಿಂದ ಅನà³à²®à²¤à²¿ ಇಲà³à²²."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "ಡೀಮನೠಚಲಾಯಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³†"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "ಡೀಮನೠPID %u ಯಾಗಿ ಚಲಾಯಿಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³†"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "ಡೀಮನೠಅನà³à²¨à³ ಕೊಲà³à²²à²²à³ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -338,166 +211,202 @@ msgstr ""
"ಈ ಪà³à²°à³‹à²—à³à²°à²¾à²®à²¨à³à²¨à³ ರೂಟà³â€Œ ಆಗಿ ಚಲಾಯಿಸà³à²µ ಉದà³à²§à³‡à²¶à²µà²¨à³à²¨à³ ಹೊಂದಿಲà³à²² (--system ಅನà³à²¨à³ ಸೂಚಿಸದೆ "
"ಇದà³à²¦à²²à³à²²à²¿ ಮಾತà³à²°)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "ನಿರà³à²µà²¾à²¹à²• ಸವಲತà³à²¤à³à²—ಳ ಅಗತà³à²¯à²µà²¿à²¦à³†."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಸನà³à²¨à²¿à²µà³‡à²¶à²¦à²¿à²‚ದ --start ಬೆಂಬಲಿತವಾಗಿಲà³à²²."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
"ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಕà³à²°à²®à²¦à²²à³à²²à²¿ ಚಲಾಯಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³†, ಆದರೆ --disallow-exit ಅನà³à²¨à³ ಹೊಂದಿಸಲಾಗಿಲà³à²²!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಕà³à²°à²®à²¦à²²à³à²²à²¿ ಚಲಾಯಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³†, ಆದರೆ --disallow-module-loading ಅನà³à²¨à³ "
"ಹೊಂದಿಸಲಾಗಿಲà³à²²!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr ""
"ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಕà³à²°à²®à²¦à²²à³à²²à²¿ ಚಲಾಯಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³à²¦à³, SHM ಕà³à²°à²®à²µà²¨à³à²¨à³ ಒತà³à²¤à²¾à²¯à²ªà³‚ರà³à²µà²•ವಾಗಿ "
"ಅಶಕà³à²¤à²—ೊಳಿಸà³à²¤à³à²¤à²¿à²¦à³†!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಕà³à²°à²®à²¦à²²à³à²²à²¿ ಚಲಾಯಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³à²¦à³, ನಿರà³à²—ಮಿಸà³à²µ ಜಡ ಸಮಯವನà³à²¨à³ ಒತà³à²¤à²¾à²¯à²ªà³‚ರà³à²µà²•ವಾಗಿ "
"ಅಶಕà³à²¤à²—ೊಳಿಸà³à²¤à³à²¤à²¿à²¦à³†!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio ಅನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "ಪೈಪà³â€Œ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "ಡೀಮನೠಆರಂಭಗೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "ಡೀಮನೠಅನà³à²¨à³ ಯಶಸà³à²µà²¿à²¯à²¾à²—ಿ ಆರಂಭಿಸಲಾಗಿದೆ."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() ವಿಫಲಗೊಂಡಿದೆ: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "ಇದೠPulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "ಕಂಪೈಲೠಮಾಡà³à²µ ಅತಿಥೇಯ: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "ಕಂಪೈಲೠಮಾಡà³à²µ CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "ಅತಿಥೇಯದಲà³à²²à²¿ ಚಲಾಯಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³†: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPUಗಳೠಕಂಡà³à²¬à²‚ದಿವೆ."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "ಪà³à²Ÿà²¦ ಗಾತà³à²°à²µà³ %lu ಬೈಟà³â€Œà²—ಳಾಗಿವೆ"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Valgrind ಬೆಂಬಲದೊಂದಿಗೆ ಕಂಪೈಲೠಮಾಡಲಾಗಿದೆ: ಹೌದà³"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Valgrind ಬೆಂಬಲದೊಂದಿಗೆ ಕಂಪೈಲೠಮಾಡಲಾಗಿದೆ: ಇಲà³à²²"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind ಕà³à²°à²®à²¦à²²à³à²²à²¿ ಚಲಾಯಿಸಲಾಗà³à²¤à³à²¤à²¿à²¦à³†: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "ಅತಿಥೇಯದಲà³à²²à²¿ ಚಲಾಯಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²¦à³†: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "ಪà³à²°à²¶à²¸à³à²¤à²µà²¾à²¦ ನಿರà³à²®à²¾à²£: ಹೌದà³"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "ಪà³à²°à²¶à²¸à³à²¤à²µà²¾à²¦ ನಿರà³à²®à²¾à²£: ಇಲà³à²²"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG ಅನà³à²¨à³ ಸೂಚಿಸಲಾಗಿದೆ, ಎಲà³à²²à²¾ ಪà³à²°à²¤à²¿à²ªà²¾à²¦à²¨à³†à²—ಳನà³à²¨à³‚ ಅಶಕà³à²¤à²—ೊಳಿಸಲಾಗಿದೆ."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr ""
"FASTPATH ಅನà³à²¨à³ ಸೂಚಿಸಲಾಗಿದೆ, ಕೇವಲ ವೇಗ ಮಾರà³à²—ದ ಪà³à²°à²¤à²¿à²ªà²¾à²¦à²¨à³†à²—ಳನà³à²¨à³‚ ಅಶಕà³à²¤à²—ೊಳಿಸಲಾಗಿದೆ."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "ಎಲà³à²²à²¾ ಪà³à²°à²¤à²¿à²ªà²¾à²¦à²¨à³†à²—ಳನà³à²¨à³‚ ಶಕà³à²¤à²—ೊಳಿಸಲಾಗಿದೆ."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "ಮೆಶೀನೠID ಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "ಮೆಶೀನೠID ಯೠ%s ಆಗಿದೆ."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "ಮೆಶೀನೠID ಯೠ%s ಆಗಿದೆ."
+msgstr "ಅಧಿವೇಶನ ID ಯೠ%s ಆಗಿದೆ."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "ಚಲಾವಣಾಸಮಯ(ರನà³â€Œà²Ÿà³ˆà²®à³) ಕೋಶ %s ಅನà³à²¨à³ ಬಳಸಿಕೊಂಡà³."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "ಸà³à²¥à²¿à²¤à²¿ ಕೋಶ %s ಅನà³à²¨à³ ಬಳಸಿಕೊಂಡà³."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "ಘಟಕಗಳ ಕೋಶ %s ಅನà³à²¨à³ ಬಳಸಿಕೊಂಡà³."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಕà³à²°à²®à²¦à²²à³à²²à²¿ ಚಲಾಯಿಸಲಾಗà³à²¤à³à²¤à²¿à²¦à³†: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"ಸರಿ, ನೀವೠPA ಅನà³à²¨à³ ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಕà³à²°à²®à²¦à²²à³à²²à²¿ (ಸಿಸà³à²Ÿà²®à³ ಮೋಡà³) ಚಲಾಯಿಸà³à²¤à³à²¤à²¿à²¦à³à²¦à³€à²°à²¿. ಸಾಮಾನà³à²¯à²µà²¾à²—ಿ "
+"ನೀವೠಹಾಗೆ ಮಾಡಬಾರದೠಎನà³à²¨à³à²µà³à²¦à²¨à³à²¨à³ ದಯವಿಟà³à²Ÿà³ ನೆನಪಿಡಿ.\n"
+"ನೀವೠಹಾಗೆ ಮಾಡಿದಲà³à²²à²¿, ಮà³à²‚ದೆ à²à²¨à²¾à²¦à²°à³‚ ತೊಂದರೆ ಆದಲà³à²²à²¿ ಅದೠನಿಮà³à²®à²¦à³† ತಪà³à²ªà²¿à²¨ "
+"ಕಾರಣದಿಂದಾಗಿರà³à²¤à³à²¤à²¦à³†.\n"
+"ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಕà³à²°à²®à²µà³ (ಸಿಸà³à²Ÿà²®à³ ಮೋಡà³) à²à²•ೆ ಒಂದೠಸರಿಯಲà³à²²à²¦ ಬಳಕೆ ಎಂದೠಅರಿಯಲೠದಯವಿಟà³à²Ÿà³ http://"
+"pulseaudio.org/wiki/WhatIsWrongWithSystemMode ಅನà³à²¨à³ ನೋಡಿ."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "ತಾಜಾ ರೆಸಲà³à²¯à³‚ಶನೠಟೈಮರೠಲಭà³à²¯à²µà²¿à²¦à³†! Bon appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -505,31 +414,31 @@ msgstr ""
"ಮಹಾಶಯರೆ, ನಿಮà³à²® ಕರà³à²¨à²²à³ ಕೊಳೆತà³à²¹à³‹à²—ಿದೆ! ಅತà³à²¯à³à²¤à³à²¤à²® ರೆಸಲà³à²¯à³‚ಶನೠಟೈಮರೠಅನà³à²¨à³ ಶಕà³à²¤à²—ೊಳಿಸಲಾದ "
"ಲಿನಕà³à²¸à²¨à³à²¨à³ ಬಳಸà³à²µà²‚ತೆ ಅಡà³à²—ೆಯವರೠಸಲಹೆ ಮಾಡà³à²¤à³à²¤à²¿à²¦à³à²¦à²¾à²°à³†!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "ಡೀಮನೠಅನà³à²¨à³ ಆರಂಭಿಸಲೠವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "ಲೋಡೠಮಾಡಲಾದ ಯಾವà³à²¦à³† ಡೀಮನೠಇಲà³à²²à²¦à³† ಆರಂಭಗೊಂಡಿದೆ, ಕೆಲಸ ಮಾಡಲೠನಿರಾಕರಿಸಿದೆ."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "ಡೀಮನೠಆರಂಭಗೊಳಿಕೆ ಪೂರà³à²£à²—ೊಂಡಿದೆ."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "ಡೀಮನೠಸà³à²¥à²—ಿತಗೊಳಿಕೆಯನà³à²¨à³ ಆರಂಭಿಸಲಾಗಿದೆ."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "ಡೀಮನೠಅನà³à²¨à³ ಅಂತà³à²¯à²—ೊಳಿಸಲಾಗಿದೆ."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -677,15 +586,15 @@ msgstr ""
" -n ಪೂರà³à²µà²¨à²¿à²¯à³‹à²œà²¿à²¤ ಸà³à²•à³à²°à²¿à²ªà³à²Ÿà²¿à²¨ ಕಡತವನà³à²¨à³ ಲೋಡೠ"
"ಮಾಡಬೇಡ\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -693,52 +602,52 @@ msgstr ""
"--log-level ದಾಖಲೆ ಮಟà³à²Ÿà²¦ ಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³† (0..4 ವà³à²¯à²¾à²ªà³à²¤à²¿à²¯à²²à³à²²à²¿à²¨ ಅಂಕೆಯನà³à²¨à³ "
"ಅಥವ debug, info, notice, warn, error ಅನà³à²¨à³)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ದಾಖಲೆ ಗà³à²°à²¿: 'syslog', 'stderr' ಅಥವ 'auto' ಅನà³à²¨à³ ಬಳಸಿ."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಮರà³à²¨à²®à³‚ನೆ ವಿಧಾನ '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm ಬೂಲಿಯನೠಆರà³à²—à³à²®à³†à²‚ಟನà³à²¨à³ ನಿರೀಕà³à²·à²¿à²¸à³à²¤à³à²¤à²¦à³†"
@@ -777,77 +686,87 @@ msgstr "ಬಳಕೆ: %s\n"
msgid "Load Once: %s\n"
msgstr "ಒಮà³à²®à³† ಲೋಡೠಮಾಡà³: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "ಮಾರà³à²—: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ದಾಖಲೆ ಗà³à²°à²¿ '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ದಾಖಲೆ ಮಟà³à²Ÿ '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ಮರà³à²¨à²®à³‚ನೆ ವಿಧಾನ '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit ಗೆ ಈ ಪà³à²²à²¾à²Ÿà³â€Œà²«à²¾à²°à³à²®à²¿à²¨à²²à³à²²à²¿ ಬೆಂಬಲವಿಲà³à²²."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ನಮೂನೆ ರಚನೆ '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ನಮೂನೆ ದರ '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ನಮೂನೆ ಚಾನಲà³â€Œà²—ಳೠ'%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ಚಾನಲೠನಕà³à²·à³† '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¤à²µà²¾à²¦ ಫà³à²°à²¾à²—à³à²®à³†à²‚ಟà³à²—ಳ ಸಂಖà³à²¯à³† '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ಫà³à²°à²¾à²—à³à²®à³†à²‚ಟೠಗಾತà³à²° '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ನೈಸà³â€Œ ಹಂತ '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] ಅಮಾನà³à²¯à²µà²¾à²¦ ನಮೂನೆ ದರ '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "ಸಂರಚನಾ ಕಡತವನà³à²¨à³ ತೆರೆಯಲೠವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -855,18 +774,14 @@ msgstr ""
"ಸೂಚಿಸಲಾದ ಪೂರà³à²µà²¨à²¿à²¯à³‹à²œà²¿à²¤ ಚಾನಲೠನಕà³à²·à³†à²¯à³ ಪೂರà³à²µà²¨à²¿à²¯à³‹à²œà²¿à²¤ ಚಾನಲà³â€Œà²—ಳ ಸಂಖà³à²¯à³†à²—ಳಿಗಿಂತ ವಿಭಿನà³à²¨à²µà²¾à²¦ "
"ಮಾರà³à²—ಗಳ ಸಂಖà³à²¯à³†à²¯à²¨à³à²¨à³ ಹೊಂದಿದೆ."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### ಸಂರಚನಾ ಕಡತದಿಂದ ಓದà³: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "ರೂಟà³â€Œ ಸವಲತà³à²¤à³à²—ಳನà³à²¨à³ ಬಿಡಲಾಗà³à²¤à³à²¤à²¿à²¦à³†."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "CAP_SYS_NICE ಗಾಗಿನ ಯಶಸà³à²µà²¿ ನಿಯಮಿತ ಸಾಮರà³à²¥à³à²¯à²—ಳà³."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "ಸವಲತà³à²¤à³à²—ಳನà³à²¨à³ ಸà³à²µà²šà³à²›à²—ೊಳಿಸಲಾಗà³à²¤à³à²¤à²¿à²¦à³†."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -876,258 +791,237 @@ msgstr "PulseAudio ಧà³à²µà²¨à²¿ ವà³à²¯à²µà²¸à³à²¥à³†"
msgid "Start the PulseAudio Sound System"
msgstr "PulseAudio ಧà³à²µà²¨à²¿ ವà³à²¯à²µà²¸à³à²¥à³†à²¯à²¨à³à²¨à³ ಆರಂಭಿಸಿ"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "PulseAudio ಡೀಮನà³â€Œà²—ಾಗಿ ಹೆಚà³à²šà²¿à²¨ ಆದà³à²¯à²¤à³†à²¯ ಶೆಡà³à²¯à³‚ಲಿಂಗೠ(ಋಣಾತà³à²®à²• ಯೂನಿಕà³à²¸à³â€Œ ನೈಸೠಹಂತ)"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio ಡೀಮನà³â€Œà²—ಾಗಿ ರಿಯಲà³-ಟೈಮೠಶೆಡà³à²¯à³‚ಲಿಂಗà³"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"PulseAudio ಹೆಚà³à²šà²¿à²¨ ಆದà³à²¯à²¤à³†à²¯ ಶೆಡà³à²¯à³‚ಲಿಂಗೠಅನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à²¦à²‚ತೆ ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಪಾಲಿಸಿಯೠ"
-"ತಡೆಯà³à²¤à³à²¤à²¦à³†."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"PulseAudio ರಿಯಲà³-ಟೈಮà³â€Œ ಶೆಡà³à²¯à³‚ಲಿಂಗೠಅನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à²¦à²‚ತೆ ವà³à²¯à²µà²¸à³à²¥à³†à²¯ ಪಾಲಿಸಿಯೠತಡೆಯà³à²¤à³à²¤à²¦à³†."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "ಮೊನೊ"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "ಎದà³à²°à²¿à²¨ ಮಧà³à²¯à²­à²¾à²—"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "ಎದà³à²°à²¿à²¨ ಎಡಭಾಗ"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "ಎದà³à²°à²¿à²¨ ಬಲಭಾಗ"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "ಹಿಂಬದಿಯ ಮಧà³à²¯à²­à²¾à²—"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "ಹಿಂಬದಿಯ ಎಡಭಾಗ"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "ಹಿಂಬದಿಯ ಬಲಭಾಗ"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "ಕೆಳಮಟà³à²Ÿà²¦ ಫà³à²°à³€à²•à³à²µà³†à²¨à³à²¸à²¿ ಉತà³à²ªà²¾à²¦à²•"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "ಮಧà³à²¯à²¦ ಎಡಭಾಗದ ಎದà³à²°à³à²­à²¾à²—"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "ಮಧà³à²¯à²¦ ಬಲಭಾಗದ ಎದà³à²°à³à²­à²¾à²—"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "ಬದಿಯ ಎಡಭಾಗ"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "ಬದಿಯ ಬಲಭಾಗ"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "ಸಹಾಯಕ 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "ಸಹಾಯಕ 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "ಸಹಾಯಕ 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "ಸಹಾಯಕ 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "ಸಹಾಯಕ 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "ಸಹಾಯಕ 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "ಸಹಾಯಕ 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "ಸಹಾಯಕ 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "ಸಹಾಯಕ 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "ಸಹಾಯಕ 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "ಸಹಾಯಕ 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "ಸಹಾಯಕ 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "ಸಹಾಯಕ 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "ಸಹಾಯಕ 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "ಸಹಾಯಕ 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "ಸಹಾಯಕ 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "ಸಹಾಯಕ 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "ಸಹಾಯಕ 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "ಸಹಾಯಕ 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "ಸಹಾಯಕ 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "ಸಹಾಯಕ 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "ಸಹಾಯಕ 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "ಸಹಾಯಕ 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "ಸಹಾಯಕ 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "ಸಹಾಯಕ 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "ಸಹಾಯಕ 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "ಸಹಾಯಕ 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "ಸಹಾಯಕ 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "ಸಹಾಯಕ 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "ಸಹಾಯಕ 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "ಸಹಾಯಕ 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "ಸಹಾಯಕ 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "ಮೇಲಿನ ಮಧà³à²¯à²­à²¾à²—"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "ಮೇಲಿನ ಎದà³à²°à²¿à²¨ ಮಧà³à²¯à²­à²¾à²—"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "ಮೇಲಿನ ಎದà³à²°à²¿à²¨ ಎಡಭಾಗ"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "ಮೇಲಿನ ಎದà³à²°à²¿à²¨ ಬಲಭಾಗ"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "ಮೇಲಿನ ಹಿಂಬದಿಯ ಮಧà³à²¯à²­à²¾à²—"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "ಮೇಲಿನ ಹಿಂಬದಿಯ ಎಡಭಾಗ"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "ಮೇಲಿನ ಹಿಂಬದಿಯ ಬಲಭಾಗ"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(ಅಮಾನà³à²¯)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "ಸà³à²Ÿà³€à²°à²¿à²¯à³‹"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "ಸರೌಂಡà³â€Œ 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "ಸರೌಂಡà³â€Œ 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "ಸರೌಂಡà³â€Œ 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "ಸರೌಂಡà³â€Œ 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "ಸರೌಂಡà³â€Œ 7.1"
@@ -1231,27 +1125,35 @@ msgstr "ಅನà³à²µà²¯à²¿à²¸à³à²µà²¿à²•ೆಯೠಕಾಣಿಸà³à²¤à³à²¤à²
msgid "Client forked"
msgstr "ಕà³à²²à³ˆà²‚ಟೠಅನà³à²¨à³ ಫೋರà³à²•ೠಮಾಡಲಾಗಿದೆ"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "ಇನà³â€Œà²ªà³à²Ÿà³/ಔಟà³â€Œà²ªà³à²Ÿà³ ದೋಷ"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "ಸಾಧನ ಅಥವ ಸಂಪನà³à²®à³‚ಲವೠಕಾರà³à²¯à²¨à²¿à²°à²¤à²µà²¾à²—ಿದೆ"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1264,198 +1166,192 @@ msgstr "XOpenDisplay() ವಿಫಲಗೊಂಡಿದೆ"
msgid "Failed to parse cookie data"
msgstr "ಕà³à²•ಿ ದತà³à²¤à²¾à²‚ಶವನà³à²¨à³ ಪಾರà³à²¸à³ ಮಾಡà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "ಸಂರಚನಾ ಕಡತ '%s' ಅನà³à²¨à³ ಲೋಡೠಮಾಡà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr ""
"ಯಾವà³à²¦à³† ಕà³à²•ಿಯನà³à²¨à³ ಲೋಡೠಮಾಡಲಾಗಿಲà³à²². ಕà³à²•ಿ ಇಲà³à²²à²¦à³† ಸಂಪರà³à²•ಸಾಧಿಸಲೠಪà³à²°à²¯à²¤à³à²¨à²¿à²¸à²²à²¾à²—à³à²¤à³à²¤à²¿à²¦à³†."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "ಫೋರà³à²•à³(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "ಅಜà³à²žà²¾à²¤ ವಿಸà³à²¤à²°à²£à³† '%s' ಇಂದ ಸಂದೇಶವನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à²²à²¾à²—ಿದೆ"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() failed: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à²¨à³à²¨à³ ಬರಿದಾಗಿಸà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() failed: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "ಪà³à²²à³‡à²¬à³à²¯à²¾à²•ೠಸà³à²Ÿà³à²°à³€à²®à²¨à³à²¨à³ ಬರಿದಾಗಿಸಲಾಗಿದೆ."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à²¨à³à²¨à³ ಯಶಸà³à²µà²¿à²¯à²¾à²—ಿ ನಿರà³à²®à²¿à²¸à²²à²¾à²—ಿದೆ.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "ಪರಿಚಾರಕಕà³à²•ೆ ಬರಿದಾಗಿಸà³à²µ ಸಂಪರà³à²•."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() failed: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "ಬಫರೠಮೆಟà³à²°à²¿à²•à³â€Œà²—ಳà³: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "ಬಫರೠಮೆಟà³à²°à²¿à²•à³â€Œà²—ಳà³: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "ನಮೂನೆಯ ವಿವರ '%s' ಅನà³à²¨à³ ಬಳಸಿಕೊಂಡà³, ಚಾನಲà³â€Œ ನಕà³à²·à³† '%s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "ಸಾಧನ %s ಕà³à²•ೆ ಸಂಪರà³à²• ಜೋಡಿಸಲಾಗಿದೆ (%u, %ssuspended).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à²¨à³à²¨à³ ಯಶಸà³à²µà²¿à²¯à²¾à²—ಿ ನಿರà³à²®à²¿à²¸à²²à²¾à²—ಿದೆ."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ದೋಷ: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಸಾಧನವನà³à²¨à³ ತಾತà³à²•ಾಲಿಕವಾಗಿ ತಡೆಹಿಡಿಯಲಾಗಿದೆ.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "ಬಫರೠಮೆಟà³à²°à²¿à²•à³â€Œà²—ಳà³: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಸಾಧನವನà³à²¨à³ ಮರಳಿ ಆರಂಭಿಸಲಾಗಿದೆ.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "ಬಫರೠಮೆಟà³à²°à²¿à²•à³â€Œà²—ಳà³: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಅನà³à²¨à³ ಕಡಿಮೆ ಚಲಾಯಿಸಲಾಗಿದೆ.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "ನಮೂನೆಯ ವಿವರ '%s' ಅನà³à²¨à³, ಚಾನಲà³â€Œ ನಕà³à²·à³† '%s' ಅನà³à²¨à³ ಬಳಸಿಕೊಂಡà³."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಅನà³à²¨à³ ಹೆಚà³à²šà³ ಚಲಾಯಿಸಲಾಗಿದೆ.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "ಸಾಧನ %s ಕà³à²•ೆ ಸಂಪರà³à²• ಜೋಡಿಸಲಾಗಿದೆ (%u, %ssuspended)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಅನà³à²¨à³ ಆರಂಭಿಸಲಾಗಿದೆ.%s \n"
+msgid "Stream error: %s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ದೋಷ: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "ಸಾಧನ %s ಅನà³à²¨à³ ಸà³à²Ÿà³à²°à³€à²®à³â€Œ ಸà³à²¥à²³à²¾à²‚ತರಿಸಲಾಗಿದೆ (%u, %ssuspended).%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "ಇಲà³à²² "
+msgid "Stream device suspended.%s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಸಾಧನವನà³à²¨à³ ತಾತà³à²•ಾಲಿಕವಾಗಿ ತಡೆಹಿಡಿಯಲಾಗಿದೆ.%s"
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಬಫರೠಗà³à²£à²µà²¿à²¶à³‡à²·à²¤à³†à²—ಳನà³à²¨à³ ಬದಲಾಯಿಸಲಾಗಿದೆ.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಸಾಧನವನà³à²¨à³ ಮರಳಿ ಆರಂಭಿಸಲಾಗಿದೆ.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "ಸಂಪರà³à²•ವನà³à²¨à³ ಸಾಧಿಸಲಾಗಿದೆ.%s \n"
+msgid "Stream underrun.%s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಅನà³à²¨à³ ಕಡಿಮೆ ಚಲಾಯಿಸಲಾಗಿದೆ.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() failed: %s\n"
+msgid "Stream overrun.%s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಅನà³à²¨à³ ಹೆಚà³à²šà³ ಚಲಾಯಿಸಲಾಗಿದೆ.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() failed: %s\n"
+msgid "Stream started.%s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಅನà³à²¨à³ ಆರಂಭಿಸಲಾಗಿದೆ.%s "
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() failed: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "ಸಾಧನ %s ಕà³à²•ೆ ಸà³à²Ÿà³à²°à³€à²®à³â€Œ ಅನà³à²¨à³ ಸà³à²¥à²³à²¾à²‚ತರಿಸಲಾಗಿದೆ (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "ಸಂಪರà³à²•ದ ವಿಫಲತೆ: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "ಇಲà³à²² "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à²¨à³à²¨à³ ಬರಿದಾಗಿಸà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ಬಫರೠಗà³à²£à²µà²¿à²¶à³‡à²·à²¤à³†à²—ಳನà³à²¨à³ ಬದಲಾಯಿಸಲಾಗಿದೆ.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "ಪà³à²²à³‡à²¬à³à²¯à²¾à²•ೠಸà³à²Ÿà³à²°à³€à²®à²¨à³à²¨à³ ಬರಿದಾಗಿಸಲಾಗಿದೆ.\n"
+msgid "Connection established.%s"
+msgstr "ಸಂಪರà³à²•ವನà³à²¨à³ ಸಾಧಿಸಲಾಗಿದೆ.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "ಪರಿಚಾರಕಕà³à²•ೆ ಬರಿದಾಗಿಸà³à²µ ಸಂಪರà³à²•.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF ಅನà³à²¨à³ ಪಡೆಯಲಾಗಿದೆ.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "ಓದà³à²µà²¿à²•ೆ() ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Connection failure: %s"
+msgstr "ಸಂಪರà³à²•ದ ವಿಫಲತೆ: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "ಬರೆಯà³à²µà²¿à²•ೆ() ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF ಅನà³à²¨à³ ಪಡೆಯಲಾಗಿದೆ."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "ಸಂಕೇತ ದೊರೆತಿದೆ, ನಿರà³à²—ಮಿಸà³à²¤à³à²¤à²¿à²¦à³†.\n"
+msgid "write() failed: %s"
+msgstr "write() ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "ಅಗೋಚರತೆಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "ಸಂಕೇತ ದೊರೆತಿದೆ, ನಿರà³à²—ಮಿಸà³à²¤à³à²¤à²¿à²¦à³†."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "ಸಮಯ: %0.3f sec; ಅಗೋಚರತೆ: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "ಅಗೋಚರತೆಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() failed: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "ಸಮಯ: %0.3f sec; ಅಗೋಚರತೆ: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() ವಿಫಲಗೊಂಡಿದೆ: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1481,8 +1377,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1505,6 +1403,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [ಆಯà³à²•ೆಗಳà³]\n"
"\n"
@@ -1512,7 +1419,7 @@ msgstr ""
" --version ಆವೃತà³à²¤à²¿à²¯à²¨à³à²¨à³ ತೋರಿಸà³\n"
"\n"
" -r, --record ರೆಕಾರà³à²¡à²¿à²‚ಗಿಗಾಗಿ ಒಂದೠಸಂಪರà³à²•ವನà³à²¨à³ ರಚಿಸà³\n"
-" -p, --playback ಪà³à²²à³‡à²¬à³à²¯à²¾à²•ಿಗಾಗಿ ಒಂದೠಸಂಪರà³à²•ವನà³à²¨à³ ರಚಿಸಿ\n"
+" -p, --playback ಪà³à²²à³‡à²¬à³à²¯à²¾à²•ಿಗಾಗಿ ಒಂದೠಸಂಪರà³à²•ವನà³à²¨à³ ರಚಿಸà³\n"
"\n"
" -v, --verbose ವರà³à²¬à³‹à²¸à³ ಕಾರà³à²¯à²µà²¨à³à²¨à³ ಶಕà³à²¤à²—ೊಳಿಸà³\n"
"\n"
@@ -1520,7 +1427,7 @@ msgstr ""
" -d, --device=DEVICE ಸಂಪರà³à²•ಸಾಧಿಸಬೇಕಿರà³à²µ ಸಿಂಕಿನ/ಆಕರದ ಹೆಸರà³\n"
" -n, --client-name=NAME ಪರಿಚಾರಕದಲà³à²²à²¿ ಈ ಕà³à²²à³ˆà²‚ಟಿನಲà³à²²à²¿ à²à²¨à³†à²‚ದೠ"
"ಕರೆಯಬೇಕà³\n"
-" --stream-name=NAME ಪರಿಚಾರಕದಲà³à²²à²¿ ಈ ಕà³à²²à³ˆà²‚ಟಿನಲà³à²²à²¿ à²à²¨à³†à²‚ದೠ"
+" --stream-name=NAME ಪರಿಚಾರಕದಲà³à²²à²¿ ಈ ಸà³à²Ÿà³à²°à³€à²®à³ ಅನà³à²¨à³ à²à²¨à³†à²‚ದೠ"
"ಕರೆಯಬೇಕà³\n"
" --volume=VOLUME ಆರಂಭಿಕ (ರೇಖೀಯ) ಪರಿಮಾಣವನà³à²¨à³ 0...65536 "
"ವà³à²¯à²¾à²ªà³à²¤à²¿à²¯à²²à³à²²à²¿ ತೋರಿಸà³\n"
@@ -1551,8 +1458,15 @@ msgstr ""
"ಮಾಡà³.\n"
" --process-time=BYTES ಸೂಚಿಸಲಾದ ಪà³à²°à²¤à²¿ ಮನವಿಯ ಪà³à²°à²•à³à²°à²¿à²¯à³†à²¯ ಸಮಯವನà³à²¨à³ "
"ಬೈಟà³â€Œà²—ಳಲà³à²²à²¿ ಮನವಿ ಮಾಡà³.\n"
+" --property=PROPERTY=VALUE ನಿಶà³à²šà²¿à²¤ ಗà³à²£à²²à²•à³à²·à²£à²µà²¨à³à²¨à³ ನಿಶà³à²šà²¿à²¤ ಮೌಲà³à²¯à²µà²¨à³à²¨à³ "
+"ಹೊಂದಿಸಿ.\n"
+" --raw ಕಚà³à²›à²¾ PCM ದತà³à²¤à²¾à²‚ಶವನà³à²¨à³ ರೆಕಾರà³à²¡à³ ಮಾಡà³/"
+"ಚಲಾಯಿಸà³.\n"
+" --file-format=FFORMAT ಫಾರà³à²®à²¾à²Ÿà³ ಮಾಡಲಾದ PCM ದತà³à²¤à²¾à²‚ಶವನà³à²¨à³ ರೆಕಾರà³à²¡à³ "
+"ಮಾಡà³/ಚಲಾಯಿಸà³.\n"
+" --list-file-formats ಲಭà³à²¯à²µà²¿à²°à³à²µ ಕಡತ ವಿನà³à²¯à²¾à²¸à²—ಳ ಪಟà³à²Ÿà²¿.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1563,129 +1477,172 @@ msgstr ""
"libpulse %s ನೊಂದಿಗೆ ಕಂಪೈಲೠಮಾಡಲಾಗಿದೆ\n"
"libpulse %s ನೊಂದಿಗೆ ಜೋಡಿಸಲಾಗಿದೆ\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಚಾನಲೠನಕà³à²·à³† '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಕà³à²²à³ˆà²‚ಟಿನ ಹೆಸರೠ'%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಅಗೋಚರತೆ ವಿವರಣೆ '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಸà³à²Ÿà³à²°à³€à²®à³â€Œà²¨ ಹೆಸರೠ'%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಪà³à²°à²•à³à²°à²¿à²¯à³† ಸಮಯದ ವಿವರಣೆ '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಚಾನಲೠನಕà³à²·à³† '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ನಮೂನೆ ವಿವರ\n"
+msgid "Invalid latency specification '%s'"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಅಗೋಚರತೆ ವಿವರಣೆ '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "ಚಾನಲೠನಕà³à²·à³†à²¯à³ ನಮೂನೆಯ ವಿವರಣೆಯೊಂದಿಗೆ ತಾಳೆಯಾಗà³à²¤à³à²¤à²¿à²²à³à²²\n"
+msgid "Invalid process time specification '%s'"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಪà³à²°à²•à³à²°à²¿à²¯à³† ಸಮಯದ ವಿವರಣೆ '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "ಒಂದೠ%s ಸà³à²Ÿà³à²°à³€à²®à³â€Œ ಅನà³à²¨à³ ನಮೂನೆ ವಿವರಣೆ '%s' ಯೊಂದಿಗೆ ತೆರೆಯಲಾಗà³à²¤à³à²¤à²¿à²¦à³†.\n"
+msgid "Invalid property '%s'"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಗà³à²£à²²à²•à³à²·à²£ '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "ರೆಕಾರà³à²¡à²¿à²‚ಗà³"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಕಡತ ವಿನà³à²¯à²¾à²¸ %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "ಪà³à²²à³‡à²¬à³à²¯à²¾à²•à³â€Œ"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ನಮೂನೆ ವಿವರ"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "ತೆರೆ(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "ಬಹಳಷà³à²Ÿà³ ಆರà³à²—à³à²®à³†à²‚ಟà³â€Œà²—ಳà³.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "ಬಹಳಷà³à²Ÿà³ ಆರà³à²—à³à²®à³†à²‚ಟà³â€Œà²—ಳà³."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() failed.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "ನಮೂನೆಯ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() ವಿಫಲಗೊಂಡಿದೆ.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "ಧà³à²µà²¨à²¿ ಕಡತವನà³à²¨à³ ತೆರೆಯà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() failed.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"ಎಚà³à²šà²°à²¿à²•ೆ: ಸೂಚಿಸಲಾದ ನಮೂನೆ ವಿವರಣೆಯನà³à²¨à³ ಕಡತದಲà³à²²à²¿à²¨ ವಿವರಣೆಯಿಂದ ತಿದà³à²¦à²¿à²¬à²°à³†à²¯à²²à²¾à²—à³à²¤à³à²¤à²¦à³†."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() failed: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ಕಡತದಿಂದ ನಮೂನೆಯ ವಿವರಣೆಯನà³à²¨à³ ನಿರà³à²§à²°à²¿à²¸à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "ಎಚà³à²šà²°à²¿à²•ೆ: ಕಡತದಿಂದ ಚಾನಲೠನಕà³à²·à³†à²¯à²¨à³à²¨à³ ನಿರà³à²§à²°à²¿à²¸à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "ಚಾನಲೠನಕà³à²·à³†à²¯à³ ನಮೂನೆಯ ವಿವರಣೆಯೊಂದಿಗೆ ತಾಳೆಯಾಗà³à²¤à³à²¤à²¿à²²à³à²²"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "ಎಚà³à²šà²°à²¿à²•ೆ: ಕಡತಕà³à²•ೆ ಚಾನಲೠನಕà³à²·à³†à²¯à²¨à³à²¨à³ ಬರೆಯà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() failed.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"ಒಂದೠ%s ಸà³à²Ÿà³à²°à³€à²®à³â€Œ ಅನà³à²¨à³ ನಮೂನೆ ವಿವರಣೆ '%s' ಯೊಂದಿಗೆ ಹಾಗೠಚಾನಲೠನಕà³à²·à³† '%s' ಯೊಂದಿಗೆ "
+"ತೆರೆಯಲಾಗà³à²¤à³à²¤à²¿à²¦à³†."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "ರೆಕಾರà³à²¡à²¿à²‚ಗà³"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "ಪà³à²²à³‡à²¬à³à²¯à²¾à²•à³â€Œ"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() ವಿಫಲಗೊಂಡಿದೆ."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() ವಿಫಲಗೊಂಡಿದೆ."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() failed.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() ವಿಫಲಗೊಂಡಿದೆ: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() ವಿಫಲಗೊಂಡಿದೆ."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "ಫೋರà³à²•à³(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "ಸà³à²¥à²—ಿತಗೊಳಿಸಲೠವಿಫಲಗೊಂಡಿದೆ: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "ಮರಳಿ ಆರಂಭಿಸಲೠವಿಫಲಗೊಂಡಿದೆ: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "ಎಚà³à²šà²°à²¿à²•ೆ: ಧà³à²µà²¨à²¿ ಪರಿಚಾರಕವೠಸà³à²¥à²³à³€à²¯à²µà²¾à²—ಿಲà³à²², ತಾತà³à²•ಾಲಿಕವಾಗಿ ತಡೆಹಿಡಿಯಲಾಗà³à²¤à³à²¤à²¿à²²à³à²².\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "ಸಂಪರà³à²•ದ ವಿಫಲತೆ: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT ದೊರೆತಿದೆ, ನಿರà³à²—ಮಿಸà³à²¤à³à²¤à²¿à²¦à³†.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "ಎಚà³à²šà²°à²¿à²•ೆ: ಉಪ ಪà³à²°à²•à³à²°à²¿à²¯à³†à²¯à³ %u ಸಂಕೇತದೊಂದಿಗೆ ಅಂತà³à²¯à²—ೊಂಡಿದೆ\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1703,7 +1660,7 @@ msgstr ""
" -s, --server=SERVER ಸಂಪರà³à²•ಸಾಧಿಸಬೇಕಿರà³à²µ ಪರಿಚಾರಕದ ಹೆಸರà³\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1714,37 +1671,63 @@ msgstr ""
"libpulse %s ನೊಂದಿಗೆ ಕಂಪೈಲೠಮಾಡಲಾಗಿದೆ\n"
"libpulse %s ನೊಂದಿಗೆ ಜೋಡಿಸಲಾಗಿದೆ\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() ವಿಫಲಗೊಂಡಿದೆ.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() ವಿಫಲಗೊಂಡಿದೆ.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() ವಿಫಲಗೊಂಡಿದೆ.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "ಅಂಕಿಅಂಶಗಳನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "ಅಂಕಿಅಂಶಗಳನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "ಪà³à²°à²¸à²•à³à²¤ ಬಳಕೆಯಲà³à²²à²¿à²°à³à²µà³à²¦à³: %u ಖಂಡಗಳೠಒಟà³à²Ÿà³ %s ಬೈಟà³â€Œà²—ಳನà³à²¨à³ ಹೊಂದಿದೆ.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"ಸಂಪೂರà³à²£ ಜೀವಿತಾವಧಿಯ ಸಮಯದಲà³à²²à²¿ ನಿಯೋಜಿಸಲಾಗಿದà³à²¦à³: %u ಖಂಡಗಳೠಒಟà³à²Ÿà³ %s ಬೈಟà³â€Œà²—ಳನà³à²¨à³ "
"ಹೊಂದಿದೆ.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "ನಮೂನೆಯ ಕà³à²¯à²¾à²¶à³† ಗಾತà³à²°: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "ಪರಿಚಾರಕದ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "ಪರಿಚಾರಕದ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1752,7 +1735,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"ಬಳಕೆದಾರ ಹೆಸರà³: %s\n"
"ಅತಿಥೇಯದ ಹೆಸರà³: %s\n"
@@ -1764,12 +1747,12 @@ msgstr ""
"ಪೂರà³à²µà²¨à²¿à²¯à³‹à²œà²¿à²¤ ಆಕರ: %s\n"
"ಕà³à²•ಿ: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "ಸಿಂಕà³â€Œ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "ಸಿಂಕà³â€Œ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1808,12 +1791,22 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tಸಂಪರà³à²•ಸà³à²¥à²¾à²¨à²—ಳà³:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "ಆಕರದ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tಸಕà³à²°à²¿à²¯ ಸಂಪರà³à²•ಸà³à²¥à²¾à²¨: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "ಆಕರದ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1852,20 +1845,20 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "ಅನà³à²µà²¯à²¿à²¸à³à²µà³à²¦à²¿à²²à³à²²"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "ಘಟಕದ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "ಘಟಕದ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1882,12 +1875,12 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "ಕà³à²²à³ˆà²‚ಟಿನ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "ಕà³à²²à³ˆà²‚ಟಿನ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1902,12 +1895,12 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "ಕಾರà³à²¡à²¿à²¨ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "ಕಾರà³à²¡à²¿à²¨ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1924,22 +1917,22 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tಪà³à²°à³Šà²«à³ˆà²²à³à²—ಳà³:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tಸಕà³à²°à²¿à²¯ ಪà³à²°à³Šà²«à³ˆà²²à³à²—ಳà³: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "ಸಿಂಕà³â€Œ ಇನà³â€Œà²ªà³à²Ÿà³ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "ಸಿಂಕà³â€Œ ಇನà³â€Œà²ªà³à²Ÿà³ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1976,12 +1969,12 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "ಆಕರದ ಔಟà³â€Œà²ªà³à²Ÿà³ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "ಆಕರದ ಔಟà³â€Œà²ªà³à²Ÿà³ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2010,12 +2003,12 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "ನಮೂನೆಯ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "ನಮೂನೆಯ ಮಾಹಿತಿಯನà³à²¨à³ ಪಡೆದà³à²•ೊಳà³à²³à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2046,23 +2039,80 @@ msgstr ""
"\tಗà³à²£à²—ಳà³:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "ವಿಫಲತೆ: %s\n"
+msgid "Failure: %s"
+msgstr "ವಿಫಲತೆ: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "ನಮೂನೆಯನà³à²¨à³ ಅಪà³â€Œà²²à³‹à²¡à³ ಮಾಡà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "ನಮೂನೆಯನà³à²¨à³ ಅಪà³â€Œà²²à³‹à²¡à³ ಮಾಡà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "ಕಡತದ ಅಪà³à²°à²¾à²ªà³à²¤ ಸಮಯದಲà³à²²à²¿ ಅಂತà³à²¯\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "ಕಡತದ ಅಪà³à²°à²¾à²ªà³à²¤ ಸಮಯದಲà³à²²à²¿ ಅಂತà³à²¯"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಪರಿಚಾರಕ"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT ದೊರೆತಿದೆ, ನಿರà³à²—ಮಿಸà³à²¤à³à²¤à²¿à²¦à³†."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2070,13 +2120,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2092,13 +2151,21 @@ msgstr ""
"%s [ಆಯà³à²•ೆಗಳà³] upload-sample FILENAME [NAME]\n"
"%s [ಆಯà³à²•ೆಗಳà³] play-sample NAME [SINK]\n"
"%s [ಆಯà³à²•ೆಗಳà³] remove-sample NAME\n"
-"%s [ಆಯà³à²•ೆಗಳà³] move-sink-input ID SINK\n"
-"%s [ಆಯà³à²•ೆಗಳà³] move-source-output ID SOURCE\n"
+"%s [ಆಯà³à²•ೆಗಳà³] move-sink-input SINKINPUT SINK\n"
+"%s [ಆಯà³à²•ೆಗಳà³] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [ಆಯà³à²•ೆಗಳà³] load-module NAME [ARGS ...]\n"
-"%s [ಆಯà³à²•ೆಗಳà³] unload-module ID\n"
-"%s [ಆಯà³à²•ೆಗಳà³] suspend-sink [SINK] 1|0\n"
-"%s [ಆಯà³à²•ೆಗಳà³] suspend-source [SOURCE] 1|0\n"
-"%s [ಆಯà³à²•ೆಗಳà³] set-card-profile [CARD] [PROFILE] \n"
+"%s [ಆಯà³à²•ೆಗಳà³] unload-module MODULE\n"
+"%s [ಆಯà³à²•ೆಗಳà³] suspend-sink SINK 1|0\n"
+"%s [ಆಯà³à²•ೆಗಳà³] suspend-source SOURCE 1|0\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-card-profile CARD PROFILE\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-sink-port SINK PORT\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-source-port SOURCE PORT\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-sink-volume SINK VOLUME\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-source-volume SOURCE VOLUME\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-sink-mute SINK 1|0\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-source-mute SOURCE 1|0\n"
+"%s [ಆಯà³à²•ೆಗಳà³] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
" -h, --help ಈ ನೆರವನà³à²¨à³ ತೋರಿಸà³\n"
" --version ಆವೃತà³à²¤à²¿à²¯à²¨à³à²¨à³ ತೋರಿಸà³\n"
@@ -2107,7 +2174,7 @@ msgstr ""
" -n, --client-name=NAME ಪರಿಚಾರಕದಲà³à²²à²¿ ಈ ಕà³à²²à³ˆà²‚ಟಿನಲà³à²²à²¿ à²à²¨à³†à²‚ದೠ"
"ಕರೆಯಬೇಕà³\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2118,78 +2185,110 @@ msgstr ""
"libpulse %s ನೊಂದಿಗೆ ಕಂಪೈಲೠಮಾಡಲಾಗಿದೆ\n"
"libpulse %s ನೊಂದಿಗೆ ಜೋಡಿಸಲಾಗಿದೆ\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "ಲೋಡೠಮಾಡಬೇಕಿರà³à²µ ಒಂದೠಕಡತದ ನಮೂನೆಯನà³à²¨à³ ಸೂಚಿಸಿ\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "ಲೋಡೠಮಾಡಬೇಕಿರà³à²µ ಒಂದೠಕಡತದ ನಮೂನೆಯನà³à²¨à³ ಸೂಚಿಸಿ"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "ಧà³à²µà²¨à²¿ ಕಡತವನà³à²¨à³ ತೆರೆಯà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "ಧà³à²µà²¨à²¿ ಕಡತವನà³à²¨à³ ತೆರೆಯà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "ಚಲಾಯಿಸಲೠನೀವೠಒಂದೠನಮೂನೆಯ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕಾಗà³à²¤à³à²¤à²¦à³†\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "ಎಚà³à²šà²°à²¿à²•ೆ: ಕಡತದಿಂದ ನಮೂನೆಯ ವಿವರವನà³à²¨à³ ನಿರà³à²§à²°à²¿à²¸à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "ತೆಗೆದೠಹಾಕಲೠನೀವೠಒಂದೠನಮೂನೆಯ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "ಚಲಾಯಿಸಲೠನೀವೠಒಂದೠನಮೂನೆಯ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕಾಗà³à²¤à³à²¤à²¦à³†"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "ನೀವೠಒಂದೠಸಿಂಕೠಇನà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಒಂದೠಸಿಂಕà³â€Œ ಅನà³à²¨à³ ಸೂಚಿಸಬೇಕà³.\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "ತೆಗೆದೠಹಾಕಲೠನೀವೠಒಂದೠನಮೂನೆಯ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "ನೀವೠಒಂದೠಆಕರ ಔಟà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಒಂದೠಆಕರವನà³à²¨à³ ಸೂಚಿಸಬೇಕà³.\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "ನೀವೠಒಂದೠಸಿಂಕೠಇನà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಒಂದೠಸಿಂಕà³â€Œ ಅನà³à²¨à³ ಸೂಚಿಸಬೇಕà³."
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "ನೀವೠಒಂದೠಘಟಕದ ಹೆಸರನà³à²¨à³ ಹಾಗೠಆರà³à²—à³à²®à³†à²‚ಟà³à²—ಳನà³à²¨à³ ಸೂಚಿಸಬೇಕà³\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "ನೀವೠಒಂದೠಆಕರ ಔಟà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಒಂದೠಆಕರವನà³à²¨à³ ಸೂಚಿಸಬೇಕà³."
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "ನೀವೠಒಂದೠಘಟಕ ಸೂಚಿಯನà³à²¨à³ ಸೂಚಿಸಬೇಕà³\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "ನೀವೠಒಂದೠಘಟಕದ ಹೆಸರನà³à²¨à³ ಹಾಗೠಆರà³à²—à³à²®à³†à²‚ಟà³à²—ಳನà³à²¨à³ ಸೂಚಿಸಬೇಕà³."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "ನೀವೠಒಂದೠಘಟಕ ಸೂಚಿಯನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
"ನೀವೠಒಂದಕà³à²•ಿಂತ ಹೆಚà³à²šà²¿à²¨ ಸಿಂಕನà³à²¨à³ ಸೂಚಿಸಲಾಗà³à²µà³à²¦à²¿à²²à³à²². ನೀವೠಒಂದೠಬೂಲಿಯನà³â€Œ ಮೌಲà³à²¯à²µà²¨à³à²¨à³ "
-"ಸೂಚಿಸಬೇಕಾಗà³à²¤à³à²¤à²¦à³†.\n"
+"ಸೂಚಿಸಬೇಕಾಗà³à²¤à³à²¤à²¦à³†."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
"ನೀವೠಒಂದಕà³à²•ಿಂತ ಹೆಚà³à²šà²¿à²¨ ಆಕರವನà³à²¨à³ ಸೂಚಿಸಲಾಗà³à²µà³à²¦à²¿à²²à³à²². ನೀವೠಒಂದೠಬೂಲಿಯನà³â€Œ ಮೌಲà³à²¯à²µà²¨à³à²¨à³ "
-"ಸೂಚಿಸಬೇಕಾಗà³à²¤à³à²¤à²¦à³†.\n"
+"ಸೂಚಿಸಬೇಕಾಗà³à²¤à³à²¤à²¦à³†."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "ಒಂದೠಕಾರà³à²¡à²¿à²¨ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಪà³à²°à³Šà²«à³ˆà²²à³â€Œ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "ಒಂದೠಕಾರà³à²¡à²¿à²¨ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಪà³à²°à³Šà²«à³ˆà²²à³â€Œ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "ಯಾವà³à²¦à³† ಆಜà³à²žà³†à²¯à²¨à³à²¨à³ ಸೂಚಿಸಲಾಗಿಲà³à²².\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "ನೀವೠಒಂದೠಸಿಂಕಿನ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಸಂಪರà³à²•ಸà³à²¥à²¾à²¨à²¦ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() failed: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "ನೀವೠಒಂದೠಆಕರದ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಸಂಪರà³à²•ಸà³à²¥à²¾à²¨à²¦ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "ನೀವೠಒಂದೠಸಿಂಕಿನ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಸಂಪರà³à²•ಸà³à²¥à²¾à²¨à²¦ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಧà³à²µà²¨à²¿ ಪà³à²°à²®à²¾à²£à²¦ ವಿವರ"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "ನೀವೠಒಂದೠಆಕರದ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಸಂಪರà³à²•ಸà³à²¥à²¾à²¨à²¦ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "ನೀವೠಒಂದೠಸಿಂಕೠಇನà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಒಂದೠಸಿಂಕà³â€Œ ಅನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಸಿಂಕೠಇನà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿ"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "ನೀವೠಒಂದೠಸಿಂಕಿನ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಸಂಪರà³à²•ಸà³à²¥à²¾à²¨à²¦ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "ನೀವೠಒಂದೠಆಕರದ ಹೆಸರà³/ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಸಂಪರà³à²•ಸà³à²¥à²¾à²¨à²¦ ಹೆಸರನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "ನೀವೠಒಂದೠಸಿಂಕೠಇನà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿಯನà³à²¨à³ ಹಾಗೠಒಂದೠಸಿಂಕà³â€Œ ಅನà³à²¨à³ ಸೂಚಿಸಬೇಕà³"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಸಿಂಕೠಇನà³â€Œà²ªà³à²Ÿà³ ಸೂಚಿ ವಿವರ"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "ಮಾನà³à²¯à²µà²¾à²¦ ಯಾವà³à²¦à³† ಆಜà³à²žà³†à²¯à²¨à³à²¨à³ ಸೂಚಿಸಲಾಗಿಲà³à²²."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2271,128 +2370,49 @@ msgstr "ಕà³à²•ಿ ದತà³à²¤à²¾à²‚ಶವನà³à²¨à³ ಲೋಡೠಮಾಡ
msgid "Not yet implemented.\n"
msgstr "ಇನà³à²¨à³‚ ಸಹ ಅನà³à²µà²¯à²¿à²¸à²²à²¾à²—ಿಲà³à²².\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"ಯಾವà³à²¦à³† PulseAudio ಡೆಮನೠಚಾಲಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²²à³à²², ಅಥವ ಅಧಿವೇಶನ ಡೆಮನೠಆಗಿ ಚಾಲಿತಗೊಳà³à²³à³à²¤à³à²¤à²¿à²²à³à²²."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "ಸಾಕೆಟà³(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "ಸಂಪರà³à²•ಿಸà³(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio ಡೀಮನೠಅನà³à²¨à³ ಕೊಲà³à²²à³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "ಡೀಮನೠಪà³à²°à²¤à²¿à²•à³à²°à²¿à²¯à²¿à²¸à³à²¤à³à²¤à²¿à²²à³à²²."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "ಆಯà³à²•ೆಮಾಡà³(): %s"
+msgid "poll(): %s"
+msgstr "ಪೋಲà³(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "ಓದà³(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "ಬರೆ(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à²¨à³à²¨à³ ಯಶಸà³à²µà²¿à²¯à²¾à²—ಿ ನಿರà³à²®à²¿à²¸à²²à²¾à²—ಿದೆ\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "ಸà³à²Ÿà³à²°à³€à²®à³ ದೋಷ: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "ಸಂಪರà³à²•ವನà³à²¨à³ ಸಾಧಿಸಲಾಗಿದೆ.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [ಆಯà³à²•ೆಗಳà³] [FILE]\n"
-"\n"
-" -h, --help ಈ ನೆರವನà³à²¨à³ ತೋರಿಸà³\n"
-" --version ಆವೃತà³à²¤à²¿à²¯à²¨à³à²¨à³ ತೋರಿಸà³\n"
-"\n"
-" -v, --verbose ವರà³à²¬à³‹à²¸à³ ಕಾರà³à²¯à²µà²¨à³à²¨à³ ಶಕà³à²¤à²—ೊಳಿಸà³\n"
-"\n"
-" -s, --server=SERVER ಸಂಪರà³à²•ಸಾಧಿಸಬೇಕಿರà³à²µ ಪರಿಚಾರಕದ ಹೆಸರà³\n"
-" -d, --device=DEVICE ಸಂಪರà³à²•ಸಾಧಿಸಬೇಕಿರà³à²µ ಸಿಂಕಿನ ಹೆಸರà³\n"
-" -n, --client-name=NAME ಪರಿಚಾರಕದಲà³à²²à²¿ ಈ ಕà³à²²à³ˆà²‚ಟಿನಲà³à²²à²¿ à²à²¨à³†à²‚ದೠ"
-"ಕರೆಯಬೇಕà³\n"
-" --stream-name=NAME ಪರಿಚಾರಕದಲà³à²²à²¿ ಈ ಸà³à²Ÿà³à²°à³€à²®à²¿à²¨à²²à³à²²à²¿ à²à²¨à³†à²‚ದೠ"
-"ಕರೆಯಬೇಕà³\n"
-" --volume=VOLUME ಆರಂಭಿಕ (ರೇಖೀಯ) ಪರಿಮಾಣವನà³à²¨à³ 0...65536 "
-"ವà³à²¯à²¾à²ªà³à²¤à²¿à²¯à²²à³à²²à²¿ ತೋರಿಸà³\n"
-" --channel-map=CHANNELMAP ಬಳಕೆಗಾಗಿ ಚಾನಲೠನಕà³à²·à³†à²¯à²¨à³à²¨à³ ಹೊಂದಿಸà³\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"libpulse %s ನೊಂದಿಗೆ ಕಂಪೈಲೠಮಾಡಲಾಗಿದೆ\n"
-"libpulse %s ನೊಂದಿಗೆ ಜೋಡಿಸಲಾಗಿದೆ\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "ಅಮಾನà³à²¯à²µà²¾à²¦ ಚಾನಲೠನಕà³à²·à³†\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "ಕಡತ '%s' ಅನà³à²¨à³ ತೆರೆಯà³à²µà²²à³à²²à²¿ ವಿಫಲಗೊಂಡಿದೆ\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "ಮಾರà³à²—ದ ನಕà³à²·à³†à²¯à³ ಕಡತಕೆ ಹೊಂದಿಕೆಯಾಗà³à²¤à³à²¤à²¿à²²à³à²².\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "ಸರಳ ವಿವರಣೆ(ಸà³à²ªà³†à²•à³) '%s' ಅನà³à²¨à³ ಬಳಸಿಕೊಂಡà³\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "ಸà³à²µà²¯à²‚ಹೆಚà³à²šà²¿à²¸à³à²µà²¿à²•ೆಯ ಲಾಕೠಅನà³à²¨à³ ನಿಲà³à²•ಿಸಿಕೊಳà³à²³à²²à³ ಸಾಧà³à²¯à²µà²¿à²²à³à²²."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2407,7 +2427,7 @@ msgstr ""
"ವಿಕಸನಗಾರರ ಗಮನಕà³à²•ೆ ತನà³à²¨à²¿.POLLOUT ಸೆಟà³â€Œà²¨à²¿à²‚ದ ನಾವೠಎಚà³à²šà³†à²¤à³à²¤à³à²—ೊಂಡಿದà³à²¦à³‡à²µà³† -- ಆದರೆ ನಂತರದ "
"snd_pcm_avail() 0 ಅಥವ min_avail ಕà³à²•ಿಂತ ಚಿಕà³à²•ದಾದ ಇನà³à²¨à³Šà²‚ದೠಮೌಲà³à²¯à²µà²¨à³à²¨à³ ಮರಳಿಸಿದೆ."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2422,34 +2442,259 @@ msgstr ""
"ವಿಕಸನಗಾರರ ಗಮನಕà³à²•ೆ ತನà³à²¨à²¿.POLLIN ಸೆಟà³â€Œà²¨à²¿à²‚ದ ನಾವೠಎಚà³à²šà³†à²¤à³à²¤à³à²—ೊಂಡಿದà³à²¦à³‡à²µà³† -- ಆದರೆ ನಂತರದ "
"snd_pcm_avail() 0 ಅಥವ min_avail ಕà³à²•ಿಂತ ಚಿಕà³à²•ದಾದ ಇನà³à²¨à³Šà²‚ದೠಮೌಲà³à²¯à²µà²¨à³à²¨à³ ಮರಳಿಸಿದೆ."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "ಔಟà³â€Œà²ªà³à²Ÿà³ %s + ಇನà³â€Œà²ªà³à²Ÿà³ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "ಔಟà³â€Œà²ªà³à²Ÿà³ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "ಇನà³â€Œà²ªà³à²Ÿà³ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "ಜಡ"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "ಹೈ ಫಿಡಿಲಿಟಿ ಪà³à²²à³‡à²¬à³à²¯à²¾à²•à³ (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "ಹೈ ಫಿಡಿಲಿಟಿ ಕà³à²¯à²¾à²ªà³à²šà²°à³ (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "ಟೆಲಿಫೋನಿ ಡà³à²¯à³‚ಪà³à²²à³†à²•à³à²¸à³â€Œ (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
-msgstr "ಪಲà³à²¸à³â€à²†à²¡à²¿à²¯à³‹ ಧà³à²µà²¨à²¿ ಪರಿಚಾರಕ"
+msgstr "PulseAudio ಧà³à²µà²¨à²¿ ಪರಿಚಾರಕ"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "ಔಟà³â€Œà²ªà³à²Ÿà³ ಸಾಧನಗಳà³"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ಇನà³â€Œà²ªà³à²Ÿà³â€Œ ಸಾಧನಗಳà³"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ ನಲà³à²²à²¿à²¨ ಆಡಿಯೊ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "ಇನà³â€Œà²ªà³à²Ÿà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ಡಾಕಿಂಗೠಸà³à²Ÿà³‡à²¶à²¨à³ ಇನà³â€Œà²ªà³à²Ÿà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ಡಾಕಿಂಗೠಸà³à²Ÿà³‡à²¶à²¨à³ ಮೈಕà³à²°à³Šà²«à³‹à²¨à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "ಲೈನà³-ಇನà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "ಮೈಕà³à²°à³Šà²«à³‹à²¨à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "ಬಾಹà³à²¯ ಮೈಕà³à²°à³Šà²«à³‹à²¨à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "ಆಂತರಿಕ ಮೈಕà³à²°à³Šà²«à³‹à²¨à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "ರೇಡಿಯೊ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "ವೀಡಿಯೊ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "ಆಟೊಮà³à²¯à²¾à²Ÿà²¿à²•ೠಗೇನೠಕಂಟà³à²°à³‹à²²à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "ಯಾವà³à²¦à³† ಆಟೊಮà³à²¯à²¾à²Ÿà²¿à²•ೠಗೇನೠಕಂಟà³à²°à³‹à²²à³ ಇಲà³à²²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "ಬೂಸà³à²Ÿà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "ಯಾವà³à²¦à³† ಬೂಸà³à²Ÿà³ ಇಲà³à²²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "ಆಂಪà³à²²à²¿à²«à²¯à²°à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "ಯಾವà³à²¦à³† ಆಂಪà³à²²à²¿à²«à²¯à²°à³ ಇಲà³à²²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "ಬೂಸà³à²Ÿà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "ಯಾವà³à²¦à³† ಬೂಸà³à²Ÿà³ ಇಲà³à²²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "ಅನಲಾಗೠಹೆಡà³â€Œà²«à³‹à²¨à³â€Œà²—ಳà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "ಅನಲಾಗೠಇನà³â€Œà²ªà³à²Ÿà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "ಅನಲಾಗೠಮೈಕà³à²°à³Šà²«à³‹à²¨à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "ಅನಲಾಗೠಲೈನà³-ಇನà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "ಅನಲಾಗೠರೇಡಿಯೊ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "ಅನಲಾಗೠವೀಡಿಯೊ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "ಅನಲಾಗೠಔಟà³â€Œà²ªà³à²Ÿà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "ಅನಲಾಗೠಹೆಡà³â€Œà²«à³‹à²¨à³â€Œà²—ಳà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "ಅನಲಾಗೠಔಟà³â€Œà²ªà³à²Ÿà³ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "ಅನಲಾಗೠಮೊನೊ ಔಟà³â€Œà²ªà³à²Ÿà³"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "ಅನಲಾಗೠಸà³à²Ÿà³€à²°à²¿à²¯à³‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "ಅನಲಾಗೠಮೊನೊ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "ಅನಲಾಗೠಸà³à²Ÿà³€à²°à²¿à²¯à³‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "ಅನಲಾಗೠಸರೌಂಡà³â€Œ 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "ಡಿಜಿಟಲೠಸà³à²Ÿà³€à²°à²¿à²¯à³Š (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "ಡಿಜಿಟಲೠಸರೌಂಡೠ4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "ಡಿಜಿಟಲೠಸರೌಂಡೠ4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "ಡಿಜಿಟಲೠಸರೌಂಡೠ5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "ಡಿಜಿಟಲೠಸà³à²Ÿà³€à²°à²¿à²¯à³Š (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "ಅನಲಾಗೠಮೊನೊ ಡà³à²¯à³‚ಪà³à²²à³†à²•à³à²¸à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "ಅನಲಾಗೠಸà³à²Ÿà³€à²°à²¿à²¯à³Š ಡà³à²¯à³‚ಪà³à²²à³†à²•à³à²¸à³"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ಅನಲಾಗೠಸà³à²Ÿà³€à²°à²¿à²¯à³Š ಡà³à²¯à³‚ಪà³à²²à³†à²•à³à²¸à³ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "ಕೆಳಮಟà³à²Ÿà²¦ ಫà³à²°à³€à²•à³à²µà³†à²¨à³à²¸à²¿ ಉತà³à²ªà²¾à²¦à²•"
diff --git a/po/ml.po b/po/ml.po
new file mode 100644
index 00000000..492070f5
--- /dev/null
+++ b/po/ml.po
@@ -0,0 +1,2682 @@
+# translation of pulseaudio.master-tx.ml.po to
+# translation of pulseaudio.master-tx.pulseaudio.ml.po to
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: pulseaudio.master-tx.ml\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-09 12:18+0530\n"
+"Last-Translator: \n"
+"Language-Team: <en@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Generator: KBabel 1.11.4\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_avail() നലàµâ€à´•à´¿à´¯ മൂലàµà´²àµà´¯à´‚ വളരെ വലàµà´¤à´¾à´£àµàµ: %lu ബൈറàµà´±àµà´•à´³àµâ€ (%lu ms).\n"
+"ഇതàµàµ ALSA à´¡àµà´°àµˆà´µà´°àµâ€ '%s'-à´²àµà´³àµà´³ ഒരൠബഗാവാം. ദയവായി à´ˆ à´ªàµà´°à´¶àµà´¨à´‚ ALSA ഡവലപàµà´ªà´°àµâ€à´¸à´¿à´¨àµ† അറിയികàµà´•àµà´•."
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_delay() നലàµâ€à´•à´¿à´¯ മൂലàµà´²àµà´¯à´‚ വളരെ വലàµà´¤à´¾à´£àµàµ: %li ബൈറàµà´±àµà´•à´³àµâ€ (%s%lu ms).\n"
+"ഇതàµàµ ALSA à´¡àµà´°àµˆà´µà´°àµâ€ '%s'-à´²àµà´³àµà´³ ഒരൠബഗാവാം. ദയവായി à´ˆ à´ªàµà´°à´¶àµà´¨à´‚ ALSA ഡവലപàµà´ªà´°àµâ€à´¸à´¿à´¨àµ† അറിയികàµà´•àµà´•."
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_mmap_begin() നലàµâ€à´•à´¿à´¯ മൂലàµà´²àµà´¯à´‚ വളരെ വലàµà´¤à´¾à´£àµàµ: %lu ബൈറàµà´±àµà´•à´³àµâ€(%lu ms).\n"
+"ഇതàµàµ ALSA à´¡àµà´°àµˆà´µà´°àµâ€ '%s'-à´²àµà´³àµà´³ ഒരൠബഗാവാം. ദയവായി à´ˆ à´ªàµà´°à´¶àµà´¨à´‚ ALSA ഡവലപàµà´ªà´°àµâ€à´¸à´¿à´¨àµ† അറിയികàµà´•àµà´•."
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "നളàµâ€ ആണെങàµà´•à´¿à´²àµà´‚ ഒരൠസിങàµà´•െങàµà´•à´¿à´²àµà´‚ à´Žà´ªàµà´ªàµ‹à´´àµà´‚ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´•"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "à´¡à´®àµà´®à´¿ ഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "വിരàµâ€à´šàµà´šàµà´µà´²àµâ€ LADSPA സിങàµà´•àµ"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "à´•àµà´²àµ‹à´•àµà´•ഡൠNULL സിങàµà´•àµ"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "നളàµâ€ ഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ"
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "ഇനàµà´±àµ‡à´°àµâ€à´£à´²àµâ€ ഓഡിയോ"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "മോഡം"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr "യഥാരàµâ€à´¤àµà´¥ lt_dlopen ലോഡരàµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr "à´ªàµà´¤à´¿à´¯ dl ലോഡരàµâ€ à´…à´¨àµà´µà´¦à´¿à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr "bind-now-loader ചേരàµâ€à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr "%s സിഗàµà´¨à´²àµâ€ ലഭàµà´¯à´®à´¾à´¯à´¿."
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "à´ªàµà´±à´¤àµà´¤àµàµ à´•à´Ÿà´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr "'%s' à´Žà´¨àµà´¨ ഉപയോകàµà´¤à´¾à´µàµàµ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr "'%s' à´Žà´¨àµà´¨ à´—àµà´°àµ‚à´ªàµà´ªàµ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr "ഉപയോകàµà´¤à´¾à´µàµàµ '%s' (UID %lu) , à´—àµà´°àµ‚à´ªàµà´ªàµ '%s' (GID %lu) ലഭàµà´¯à´®à´¾à´¯à´¿."
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr "ഉപയോകàµà´¤à´¾à´µàµàµ '%s'-à´¨àµà´±àµ†à´¯àµà´‚ à´—àµà´°àµ‚à´ªàµà´ªàµ '%s'-à´¨àµà´±àµ†à´¯àµà´‚ GID ചേരàµà´¨àµà´¨à´¿à´²àµà´²."
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr "ഉപയോകàµà´¤à´¾à´µàµàµ '%s'-à´¨àµà´±àµ† ഹോം ഡയറകàµà´Ÿà´±à´¿ '%s' à´…à´²àµà´², ഉപേകàµà´·à´¿à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr "'%s' ഉണàµà´Ÿà´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr "à´—àµà´°àµ‚à´ªàµà´ªàµ ലിസàµà´±àµà´±àµ മാറàµà´±àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr "GID മാറàµà´±àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr "UID മാറàµà´±àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr "റൂടàµà´Ÿàµ ആനàµà´•ൂലàµà´¯à´™àµà´™à´³àµâ€ വിജയകരമായി ഉപേകàµà´·à´¿à´šàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr "à´ˆ à´ªàµà´²à´¾à´±àµà´±àµà´«àµ‹à´®à´¿à´²àµâ€ സിസàµà´±àµà´±à´‚ വൈഡൠമോഡൠപിനàµà´¤àµà´£à´¯àµà´•àµà´•àµà´¨àµà´¨à´¿à´²àµà´²."
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr "setrlimit(%s, (%u, %u)) പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr "കമാനàµâ€à´¡àµ ലൈനàµâ€ പാഴàµà´¸àµ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr "ഡെമണàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¨à´¤àµà´¤à´¿à´²à´¿à´²àµà´²"
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr "ഡെമണàµâ€ PID %u ആയി à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr "ഡെമണàµâ€ നശിപàµà´ªà´¿à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr ""
+"à´ˆ à´ªàµà´°àµ‹à´—àµà´°à´¾à´‚ റൂടàµà´Ÿà´¾à´¯à´¿ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´ªàµà´ªà´¿à´•àµà´•േണàµà´Ÿà´¤à´²àµà´² (--system à´Žà´¨àµà´¨àµàµ പറഞàµà´žà´¿à´Ÿàµà´Ÿàµà´£àµà´Ÿàµ†à´™àµà´•à´¿à´²àµâ€ മാതàµà´°à´‚ റൂടàµà´Ÿàµ "
+"ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ)."
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr "റൂടàµà´Ÿàµ ആനàµà´•ൂലàµà´¯à´™àµà´™à´³àµâ€ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ."
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr "സിസàµà´±àµà´±à´‚ ഇനàµâ€à´¸àµà´±àµà´±à´¨àµâ€à´¸àµà´•à´³àµâ€à´•àµà´•ൠ--start പിനàµà´¤àµà´£à´¯àµà´•àµà´•àµà´¨àµà´¨à´¿à´²àµà´²."
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr "സിസàµà´±àµà´±à´‚ മോഡിലàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ, പകàµà´·àµ‡ --disallow-exit സജàµà´œà´®à´¾à´•àµà´•ിയിടàµà´Ÿà´¿à´²àµà´²!"
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr ""
+"സിസàµà´±àµà´±à´‚ മോഡിലàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ, പകàµà´·àµ‡ --disallow-module-loading സജàµà´œà´®à´¾à´•àµà´•ിയിടàµà´Ÿà´¿à´²àµà´²!"
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr "സിസàµà´±àµà´±à´‚ മോഡിലàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ, നിരàµâ€à´¬à´¨àµà´§à´®à´¾à´¯àµà´‚ SHM മോഡൠപàµà´°à´µà´°àµâ€à´¤àµà´¤ രഹിതമാകàµà´•àµà´¨àµà´¨àµ!"
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr ""
+"സിസàµà´±àµà´±à´‚ മോഡിലàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ, നിരàµâ€à´¬à´¨àµà´§à´®à´¾à´¯àµà´‚ à´Žà´•àµà´¸à´¿à´±àµà´±àµ à´à´¡à´¿à´²àµâ€ സമയം à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤ രഹിതമാകàµà´•àµà´¨àµà´¨àµ!"
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr "stdio ലഭികàµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "pipe പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr "fork() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr "read() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr "ഡെമണിനàµà´±àµ† à´¤àµà´Ÿà´•àµà´•à´‚ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr "ഡെമണിനàµà´±àµ† à´¤àµà´Ÿà´•àµà´•à´‚ വിജയിചàµà´šàµ."
+
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr "ഇതàµàµ PulseAudio %s ആണàµàµ"
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr "കംപൈലേഷനàµâ€ ഹോസàµà´±àµà´±àµ: %s"
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr "കംപൈലേഷനàµâ€ CFLAGS: %s"
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr "ഹോസàµà´±àµà´±à´¿à´²àµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ: %s"
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr "%u സിപിയൠലഭàµà´¯à´®à´¾à´¯à´¿."
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr "താളിനàµà´±àµ† à´µàµà´¯à´¾à´ªàµà´¤à´¿ %lu ബൈറàµà´±àµà´•ളാണàµàµ"
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr "Valgrind പിനàµà´¤àµà´£à´¯àµ‹à´Ÿàµ† കംപൈലàµâ€ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ: ഉവàµà´µàµàµ"
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr "Valgrind പിനàµà´¤àµà´£à´¯àµ‹à´Ÿàµ† കംപൈലàµâ€ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ: ഇലàµà´²"
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr "valgrind മോഡിലàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´ªàµà´ªà´¿à´•àµà´•àµà´¨àµà´¨àµ: %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "ഹോസàµà´±àµà´±à´¿à´²àµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ: %s"
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr "à´’à´ªàµà´Ÿà´¿à´®àµˆà´¸àµà´¡àµ ബിളàµâ€à´¡àµ: ഉവàµà´µàµàµ"
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr "à´’à´ªàµà´Ÿà´¿à´®àµˆà´¸àµà´¡àµ ബിളàµâ€à´¡àµ: ഇലàµà´²"
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr "NDEBUG നിഷàµà´•à´°àµâ€à´·à´¿à´šàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ, à´Žà´²àµà´²à´¾ asserts-ഉം à´ªàµà´°à´µà´°àµâ€â€Œà´¤àµà´¤ രഹിതം."
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr "FASTPATH നിഷàµà´•à´°àµâ€à´·à´¿à´šàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ, fast path asserts മാതàµà´°à´‚ à´ªàµà´°à´µà´°àµâ€â€Œà´¤àµà´¤ രഹിതം."
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr "à´Žà´²àµà´²à´¾ asserts-ഉം à´ªàµà´°à´µà´°àµâ€â€Œà´¤àµà´¤ സജàµà´œà´‚"
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr "മഷീനàµâ€ ID ലഭàµà´¯à´®à´¾à´•àµà´•àµà´µà´¾à´¨àµâ€ സാധàµà´¯à´®à´¾à´¯à´¿à´²àµà´²"
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr "മഷീനàµâ€ ID %s ആണàµàµ."
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr "സെഷനàµâ€ ID %s ആണàµàµ."
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr "റണàµâ€à´Ÿàµˆà´‚ ഡയറകàµà´Ÿà´±à´¿ %s ഉപയോഗികàµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr "à´¸àµà´±àµà´±àµ‡à´±àµà´±àµ ഡയറകàµà´Ÿà´±à´¿ %s ഉപയോഗികàµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "മൊഡàµà´¯àµ‚à´³àµâ€à´¸àµ ഡയറകàµà´Ÿà´±à´¿ %s ഉപയോഗികàµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr "സിസàµà´±àµà´±à´‚ മോഡിലàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨àµ: %s"
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"à´¶à´°à´¿, à´…à´ªàµà´ªàµ‹à´³àµâ€ നിങàµà´™à´³àµâ€ പിഎ സിസàµà´±àµà´±à´‚ മോഡിലാണàµàµ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´ªàµà´ªà´¿à´•àµà´•àµà´¨àµà´¨à´¤àµàµ. ദയവായി ഇതàµà´ªàµ‡à´•àµà´·à´¿à´•àµà´•àµà´•.\n"
+"ഇങàµà´™à´¨àµ† ചെയàµà´¤àµà´£àµà´Ÿà´¾à´•àµà´¨àµà´¨ സകല തകരാറàµà´•à´³àµà´Ÿàµ‡à´¯àµà´‚ ഉതàµà´¤à´°à´µà´¾à´¦à´¿ നിങàµà´™à´³àµâ€ à´¸àµà´µà´¯à´®à´¾à´•àµà´¨àµà´¨àµ.\n"
+"സിസàµà´±àµà´±à´‚ മോഡിലàµà´³àµà´³ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¨à´‚ ഉതàµà´¤à´®à´®à´²àµà´²à´¾à´¤àµà´¤à´¤à´¿à´¨àµà´±àµ† കാരണങàµà´™à´³àµâ€à´•àµà´•ായിhttp://pulseaudio.org/"
+"wiki/WhatIsWrongWithSystemMode കാണàµà´•."
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr "pa_pid_file_create() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr "Fresh high-resolution timers available! Bon appetit!"
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr "pa_core_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr "ഡെമണàµâ€ ആരംഭികàµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr "ഒരൠഘടകങàµà´™à´³àµà´‚ ലഭàµà´¯à´®à´¾à´•ാതെ ഡെമണàµâ€ ആരംഭിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ, à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¨à´‚ നിഷേധിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr "ഡെമണിനàµà´±àµ† à´¤àµà´Ÿà´•àµà´•à´‚ പൂരàµâ€à´£àµà´£à´®à´¾à´¯à´¿."
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr "ഡെമണàµâ€ à´…à´Ÿà´šàµà´šàµà´ªàµ‚à´Ÿàµà´Ÿàµà´¨àµà´¨à´¤àµàµ ആരംഭിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr "ഡെമണàµâ€ നിരàµâ€à´¤àµà´¤à´¿à´¯à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr "--daemonize-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr "--fail-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+"--log-level-à´¨àµàµ ലോഗൠലവലàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ (à´’à´¨àµà´¨àµà´•à´¿à´²àµâ€ 0..4 വരെയàµà´³àµà´³ à´¨àµà´¯àµ‚മറികൠപരിധി "
+"à´…à´²àµà´²àµ†à´™àµà´•à´¿à´²àµâ€ debug, info, notice, warn, error à´Žà´¨àµà´¨à´¿à´µà´¯à´¿à´²àµâ€ à´’à´¨àµà´¨àµàµ)."
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr "--high-priority-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr "--realtime-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr "--disallow-module-loading-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr "--disallow-exit-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr "--use-pid-file-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr "തെറàµà´±à´¾à´¯ ലോഗൠടാരàµâ€à´—à´±àµà´±àµ: 'syslog', 'stderr' à´…à´²àµà´²àµ†à´™àµà´•à´¿à´²àµâ€ 'auto' ഉപയോഗികàµà´•àµà´•."
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr "--log-time-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr "--log-meta-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr "തെറàµà´±à´¾à´¯ റീസാംപിളàµâ€ മാരàµâ€à´—àµà´—à´‚ '%s'."
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr "--system-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr "--no-cpu-limit-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr "--disable-shm-à´¨àµàµ ബൂളിയനàµâ€ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ ആവശàµà´¯à´®àµà´£àµà´Ÿàµàµ"
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr "പേരàµàµ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr "ഘടകതàµà´¤àµ†à´ªàµà´ªà´±àµà´±à´¿à´¯àµà´³àµà´³ വിവരം ലഭàµà´¯à´®à´²àµà´²\n"
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr "പതിപàµà´ªàµàµ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr "വിവരണം: %s\n"
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr "രചയിതാവàµàµ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr "ഉപയോഗം: %s\n"
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr "à´’à´°à´¿à´•àµà´•à´²àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´•: %s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr "പാഥàµ: %s\n"
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ ലോഗൠടാരàµâ€à´—à´±àµà´±àµ '%s'."
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ ലോഗൠലവലàµâ€ '%s'."
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ റീസാംപിളàµâ€ മാരàµâ€à´—àµà´—à´‚ '%s'."
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr "[%s:%u] അസാധàµà´µà´¾à´¯ rlimit '%s'."
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr "[%s:%u] à´ˆ à´ªàµà´²à´¾à´±àµà´±àµà´«àµ‹à´®à´¿à´²àµâ€ rlimit-à´¨àµà´³àµà´³ പിനàµà´¤àµà´£ ലഭàµà´¯à´®à´²àµà´²."
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ സാംപിളàµâ€ മാതൃക '%s'."
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ സാംപിളàµâ€ റേറàµà´±àµ '%s'."
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ സാംപിളàµâ€ ചാനലàµà´•à´³àµâ€ '%s'."
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr "[%s:%u] അസാധàµà´µà´¾à´¯ ചാനലàµâ€ മാപàµà´ªàµ '%s'."
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr "[%s:%u] '%s' à´«àµà´°à´¾à´—àµà´®àµ†à´¨àµà´±àµà´•à´³àµà´Ÿàµ† തെറàµà´±à´¾à´¯ à´Žà´£àµà´£à´‚."
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ à´«àµà´°à´¾à´—àµà´®àµ†à´¨àµà´±àµ à´µàµà´¯à´¾à´ªàµà´¤à´¿ '%s'."
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr "[%s:%u] അസാധàµà´µà´¾à´¯ nice à´¸àµà´¥à´¾à´¨à´‚ '%s'."
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] തെറàµà´±à´¾à´¯ സാംപിളàµâ€ റേറàµà´±àµ '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr "à´•àµà´°à´®àµ€à´•à´°à´£ ഫയലàµâ€ à´¤àµà´±à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr ""
+"à´µàµà´¯à´•àµà´¤à´®à´¾à´•àµà´•ിയിടàµà´Ÿàµà´³àµà´³ à´¸àµà´µà´¤à´µàµ‡à´¯àµà´³àµà´³ ചാനലàµâ€ മാപàµà´ªà´¿à´¨àµà´³àµà´³ ചാനലàµà´•à´³àµà´Ÿàµ† à´Žà´£àµà´£à´‚ നലàµâ€à´•ിയിരികàµà´•àµà´¨àµà´¨ à´¸àµà´µà´¤à´µàµ‡à´¯àµà´³àµà´³ "
+"ചാനലàµà´•à´³àµà´Ÿàµ† à´Žà´£àµà´£à´¤àµà´¤àµ‡à´•àµà´•ാളàµâ€ à´µàµà´¯à´¤àµà´¯à´¸àµà´¥à´®à´¾à´£àµàµ."
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr "### à´•àµà´°à´®àµ€à´•à´°à´£ ഫയലിലàµâ€ നിനàµà´¨àµà´‚ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´•: %s ###\n"
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "à´…à´¨àµà´®à´¤à´¿à´•à´³àµâ€ വെടിപàµà´ªà´¾à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "PulseAudio സൌണàµà´Ÿàµ സിസàµà´±àµà´±à´‚"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "PulseAudio സൌണàµà´Ÿàµ സിസàµà´±àµà´±à´‚ ആരംഭികàµà´•àµà´•"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "മോണോ"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "മദàµà´§àµà´¯à´‚ à´®àµà´¨àµà´¨à´¿à´²àµâ€"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "ഇടതàµàµàµ à´®àµà´¨àµà´¨à´¿à´²àµâ€"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "വലതàµàµ à´®àµà´¨àµà´¨à´¿à´²àµâ€"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "മദàµà´§àµà´¯à´‚ അവസാനം"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "ഇടതàµàµ അവസാനം"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "വലതàµàµ അവസാനം"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr "à´®àµà´®àµà´ªà´¿à´²àµâ€ ഇടതàµàµ മദàµà´§àµà´¯à´‚"
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr "à´®àµà´®àµà´ªà´¿à´²àµâ€ വലതàµàµ മദàµà´§àµà´¯à´‚"
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "ഇടതàµà´¤àµàµ വശം"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "വലതàµà´¤àµàµ വശം"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 0"
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 1"
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 2"
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 3"
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 4"
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 5"
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 6"
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 7"
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 8"
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 9"
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 10"
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 11"
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 12"
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 13"
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 14"
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 15"
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 16"
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 17"
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 18"
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 19"
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 20"
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 21"
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 22"
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 23"
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 24"
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 25"
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 26"
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 27"
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 28"
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 29"
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 30"
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr "à´“à´•àµà´¸à´¿à´²à´±à´¿ 31"
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "à´®àµà´•ളിലàµâ€ à´®àµà´®àµà´ªà´¿à´²àµâ€"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "à´®àµà´•ളിലàµâ€ à´®àµà´®àµà´ªà´¿à´²àµâ€ മദàµà´§àµà´¯à´‚"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "à´®àµà´•ളിലàµâ€ à´®àµà´®àµà´ªà´¿à´²àµâ€ ഇടതàµà´¤àµàµ"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "à´®àµà´•ളിലàµâ€ à´®àµà´®àµà´ªà´¿à´²àµâ€ വലതàµà´¤àµàµ"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "à´®àµà´•ളിലàµâ€ അവസാനം മദàµà´§àµà´¯à´‚"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "à´®àµà´•ളിലàµâ€ അവസാനം ഇടതàµà´¤àµàµ"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "à´®àµà´•ളിലàµâ€ അവസാനം വലതàµà´¤àµàµ"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "(അസാധàµ)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "à´¸àµà´±àµà´±àµ€à´°à´¿à´¯àµ‹"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "സറൌണàµà´Ÿàµ 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "സറൌണàµà´Ÿàµ 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "സറൌണàµà´Ÿàµ 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "സറൌണàµà´Ÿàµ 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "സറൌണàµà´Ÿàµ 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "à´¶à´°à´¿"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "à´…à´¨àµà´®à´¤à´¿ നിഷേധിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr "അപരിചിതമായ കമാനàµâ€à´¡àµ"
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr "തെറàµà´±à´¾à´¯ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµ"
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr "à´Žà´¨àµà´±à´¿à´±àµà´±à´¿ നിലവിലàµà´£àµà´Ÿàµàµ"
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr "à´…à´¤àµà´¤à´°à´‚ à´Žà´¨àµà´±à´¿à´±àµà´±à´¿à´¯à´¿à´²àµà´²"
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "കണകàµà´·à´¨àµâ€ നിഷേധിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "à´ªàµà´°àµ‹à´Ÿàµà´Ÿàµ‹à´•àµà´•ോളിലàµâ€ പിശകàµ"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr "സമയം à´•à´´à´¿à´žàµà´žà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr "ഓഥറൈസേഷനàµâ€ കീ നിലവിലിലàµà´²"
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "ആനàµà´¤à´°à´¿à´• പിശകàµ"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr "കണകàµà´·à´¨àµâ€ വിഛേദിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr "à´Žà´¨àµà´±à´¿à´±àµà´±à´¿ ഇലàµà´²à´¾à´¤à´¾à´•àµà´•ിയിരികàµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr "തെറàµà´±à´¾à´¯ സരàµâ€à´µà´°àµâ€"
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr "ഘടകം ആരംഭികàµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ"
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr "തെറàµà´±à´¾à´¯ അവസàµà´¥"
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr "ഡേറàµà´±à´¾ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr "പൊരàµà´¤àµà´¤à´ªàµà´ªàµ†à´Ÿà´¾à´¤àµà´¤ à´ªàµà´°àµ‹à´Ÿàµà´Ÿàµ‹à´•àµà´•ോളàµâ€ പതിപàµà´ªàµàµ"
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "വളരെ വലàµà´¤àµàµ"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "പിനàµà´¤àµà´£ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "അപരിചിതമായ പിശകൠകോഡàµ"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr "à´…à´¤àµà´¤à´°à´‚ à´Žà´•àµà´¸àµà´±àµà´±àµ†à´¨àµâ€à´·à´¨àµâ€ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr "ഇലàµà´²à´¾à´¤à´¾à´•àµà´•à´¿à´¯ വിശേഷത"
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr "à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¨à´‚ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr "à´•àµà´²àµˆà´¨àµà´±àµ ഫോരàµâ€à´•àµà´•ൠചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "ഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ/ഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ പിശകàµ"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "ഉപകരണം à´…à´²àµà´²àµ†à´™àµà´•à´¿à´²àµâ€ ഉറവിടം ഉപയോഗതàµà´¤à´¿à´²àµâ€"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr "%s %uch %uHz"
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr "%0.1f GiB"
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr "%0.1f MiB"
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr "%0.1f KiB"
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr "%u B"
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr "XOpenDisplay() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ"
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr "à´•àµà´•àµà´•à´¿ ഡേറàµà´±à´¾ പാഴàµà´¸àµ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ"
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr "à´•àµà´°à´®àµ€à´•à´°à´£ ഫയലàµâ€ '%s' à´¤àµà´±à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr "ഒരൠകàµà´•àµà´•à´¿à´¯àµà´‚ ലഭàµà´¯à´®à´²àµà´². അതിലàµà´²à´¾à´¤àµ† കണകàµà´Ÿàµ ചെയàµà´¯àµà´µà´¾à´¨àµâ€â€Œ à´¶àµà´°à´®à´¿à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr "fork(): %s"
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr "waitpid(): %s"
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr "അപരിചിതമായ à´Žà´•àµà´¸àµà´±àµà´±àµ†à´¨àµâ€à´·à´¨àµâ€ '%s'-à´¨àµà´³àµà´³ സനàµà´¦àµ‡à´¶à´‚ ലഭിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ à´¡àµà´°àµ†à´¯à´¿à´¨àµâ€ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "à´ªàµà´²àµ‡à´¬à´¾à´•àµà´•ൠസàµà´Ÿàµà´°àµ€à´‚ à´¡àµà´°àµ†à´¯à´¿à´¨àµâ€ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "സരàµâ€à´µà´±à´¿à´²àµ‡à´•àµà´•àµà´³àµà´³ കണകàµà´·à´¨àµâ€ à´¡àµà´°àµ†à´¯à´¿à´¨àµâ€ ചെയàµà´¯àµà´¨àµà´¨àµ."
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ വിജയകരമായി ഉണàµà´Ÿà´¾à´•àµà´•ിയിരികàµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "ബഫരàµâ€ മെടàµà´°à´¿à´•àµà´¸àµ: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "ബഫരàµâ€ മെടàµà´°à´¿à´•àµà´¸àµ: maxlength=%u, fragsize=%u"
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "സാംപിളàµâ€ à´¸àµà´ªàµ†à´•ൠ'%s', ചാനലàµâ€ മാപàµà´ªàµ '%s' ഉപയോഗികàµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "ഡിവൈസൠ%s-ലേകàµà´•ൠകണകàµà´Ÿàµ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ (%u, %ssuspended)."
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ പിശകàµ: %s"
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ ഡിവൈസൠസസàµà´ªàµ†à´¨àµâ€à´¡àµ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ.%s"
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ ഡിവൈസൠവീണàµà´Ÿàµà´‚ ആരംഭിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ.%s"
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ à´…à´£àµà´Ÿà´°àµâ€à´±à´£àµâ€.%s"
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€ ഓവരàµâ€à´±à´£àµâ€.%s"
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ ആരംഭിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ.%s"
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "ഡിവൈസൠ%s-ലേകàµà´•ൠസàµà´Ÿàµà´°àµ€à´‚ നീകàµà´•à´‚ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ (%u, %ssuspended).%s"
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "à´…à´²àµà´²"
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr "à´¸àµà´Ÿàµà´°àµ€à´‚ ബഫരàµâ€ വിശേഷതകളàµâ€ മാറàµà´±à´¿à´¯à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ.%s"
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr "കണകàµà´·à´¨àµâ€ à´¸àµà´¥à´¾à´ªà´¿à´šàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ.%s"
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr "കണകàµà´·à´¨à´¿à´²àµâ€ തകരാരàµâ€: %s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF ലഭàµà´¯à´®à´¾à´¯à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ"
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr "write() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "സിഗàµà´¨à´²àµâ€ ലഭàµà´¯à´®à´¾à´¯à´¿, à´ªàµà´±à´¤àµà´¤àµàµ à´•à´Ÿà´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr "ലാറàµà´±à´¨àµâ€à´¸à´¿ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "സമയം: %0.3f sec; ലാറàµà´±à´¨àµâ€à´¸à´¿: %0.0f usec."
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pacat %s\n"
+"libpulse %s-നൊപàµà´ªà´‚ കംപൈലàµâ€ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ\n"
+"libpulse %s-നൊപàµà´ªà´‚ ലിങàµà´•ൠചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ\n"
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr "തെറàµà´±à´¾à´¯ à´•àµà´²àµˆà´¨àµà´±àµ നാമം '%s'"
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr "തെറàµà´±à´¾à´¯ à´¸àµà´Ÿàµà´°àµ€à´‚ നാമം '%s'"
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr "തെറàµà´±à´¾à´¯ ചാനലàµâ€ മാപàµà´ªàµ '%s'"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr "തെറàµà´±à´¾à´¯ ലാറàµà´±à´¨àµâ€à´¸à´¿ വിവരണം '%s'"
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "തെറàµà´±à´¾à´¯ à´ªàµà´°à´•àµà´°à´¿à´¯ സമയ വിവരണം '%s'"
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr "തെറàµà´±à´¾à´¯ വിശേഷത '%s'"
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "അപരിചിതമായ ഫയലàµâ€ രീതി %s."
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "തെറàµà´±à´¾à´¯ മാതൃക വിവരണം"
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr "open(): %s"
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "അനവധി ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµà´•à´³àµâ€."
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "ഫയലിനàµà´³àµà´³ സാംപിളàµâ€ വിവരണം ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "à´“â€à´¡à´¿à´¯àµ‹ ഫയലàµâ€ à´¤àµà´±à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"à´®àµà´¨àµà´¨à´±à´¿à´¯à´¿à´ªàµà´ªàµàµ: ഫയലിലàµâ€ നിനàµà´¨àµà´³àµà´³ വിവരണം à´µàµà´¯à´•àµà´¤à´®à´¾à´•àµà´•ിയിരികàµà´•àµà´¨àµà´¨ സാംപിളàµâ€ വിവരണം മാറàµà´±à´¿à´¯àµ†à´´àµà´¤àµà´¨àµà´¨àµ."
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ഫയലിലàµâ€ നിനàµà´¨àµà´‚ സാംപിളàµâ€ വിവരണം ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "à´®àµà´¨àµà´¨à´±à´¿à´¯à´¿à´ªàµà´ªàµàµ: ഫയലിലàµâ€ നിനàµà´¨àµà´‚ ചാനലàµâ€ മാപàµà´ªàµ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "ചാനലàµâ€ മാപàµà´ªàµ സാംപിളàµâ€ വിവരണവàµà´®à´¾à´¯à´¿ ചേരàµà´¨àµà´¨à´¿à´²àµà´²"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "à´®àµà´¨àµà´¨à´±à´¿à´¯à´¿à´ªàµà´ªàµàµ: ഫയലിലേകàµà´•ൠചാനലàµâ€ മാപàµà´ªàµ സൂകàµà´·à´¿à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "%s à´¸àµà´Ÿàµà´°àµ€à´‚ à´¤àµà´±à´•àµà´•àµà´¨àµà´¨àµ. ഇതിനàµà´±àµ† സാംപിളàµâ€ വിവരണം '%s'-ഉം ചാനലàµâ€ മാപàµà´ªàµ '%s'-ഉം ആണàµàµ."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "റികàµà´•ോരàµâ€à´¡àµ ചെയàµà´¯àµà´¨àµà´¨àµ"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "à´ªàµà´²àµ‡à´¬à´¾à´•àµà´•àµ"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr "fork(): %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr "സസàµà´ªàµ†à´¨àµâ€à´¡àµ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s\n"
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr "വീണàµà´Ÿàµà´‚ ആരംഭികàµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s\n"
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr "à´®àµà´¨àµà´¨à´±à´¿à´¯à´¿à´ªàµà´ªàµàµ: à´¶à´¬àµà´¦ സരàµâ€à´µà´°àµâ€ ലോകàµà´•ലലàµà´², സസàµà´ªàµ†à´¨àµâ€à´¡àµ ചെയàµà´¯àµà´¨àµà´¨à´¿à´²àµà´².\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "കണകàµà´·à´¨à´¿à´²àµâ€ തകരാരàµâ€: %s\n"
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr "SIGINT ലഭിചàµà´šàµ, à´ªàµà´±à´¤àµà´¤àµàµ à´•à´Ÿà´•àµà´•àµà´¨àµà´¨àµ.\n"
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr "à´®àµà´¨àµà´¨à´±à´¿à´¯à´¿à´ªàµà´ªàµàµ: %u സിഗàµà´¨à´²àµâ€ വഴി ചൈളàµâ€ à´ªàµà´°à´•àµà´°à´¿à´¯ അവസാനിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ\n"
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pasuspender %s\n"
+"libpulse %s-നൊപàµà´ªà´‚ കംപൈലàµâ€ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ\n"
+"libpulse %s-നൊപàµà´ªà´‚ ലിങàµà´•ൠചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ\n"
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ..\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "à´¸àµà´¥à´¿à´¤à´¿à´µà´¿à´µà´°à´•àµà´•ണകàµà´•àµà´•à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr "നിലവിലàµâ€ ഉപയോഗതàµà´¤à´¿à´²àµâ€: %u à´¬àµà´²àµ‹à´•àµà´•àµà´•à´³àµâ€, മൊതàµà´¤à´‚ %s ബൈറàµà´±àµà´•à´³àµâ€ à´…à´Ÿà´™àµà´™àµà´¨àµà´¨àµ.\n"
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr "കാലാവധിയàµà´•àµà´•àµà´³àµà´³à´¿à´²àµâ€ à´…à´¨àµà´µà´¦à´¿à´•àµà´•àµà´¨àµà´¨àµ: %u à´¬àµà´²àµ‹à´•àµà´•àµà´•à´³àµâ€, മൊതàµà´¤à´‚ %s ബൈറàµà´±àµà´•à´³àµâ€ à´…à´Ÿà´™àµà´™àµà´¨àµà´¨àµ.\n"
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr "സാംപിളàµâ€ കാഷൠവàµà´¯à´ªàµà´¤à´¿: %s\n"
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr "സരàµâ€à´µà´°àµâ€ വിവരങàµà´™à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+"User name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %08x\n"
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr "സിങàµà´•ൠവിവരം ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tപോരàµâ€à´Ÿàµà´Ÿàµà´•à´³àµâ€:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tസജീവമായ പോരàµâ€à´Ÿàµà´Ÿàµ: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "സോഴàµà´¸àµ വിവരങàµà´™à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "n/a"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr "ഘടക വിവരങàµà´™à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr "à´•àµà´²àµˆà´¨àµà´±àµ വിവരങàµà´™à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "കാരàµâ€à´¡àµ വിവരങàµà´™à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\tà´ªàµà´°àµŠà´«àµˆà´²àµà´•à´³àµâ€:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr "\tസജീവമായ à´ªàµà´°àµŠà´«àµˆà´²àµâ€: %s\n"
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "സിങàµà´•ൠഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ വിവരങàµà´™à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "സോഴàµà´¸àµ ഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ വിവരം ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "മാതൃകയàµà´Ÿàµ† വിവരങàµà´™à´³àµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "പരാജയം: %s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "മാതൃക à´…à´ªàµà´²àµ‹à´¡àµ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "ഫയലàµâ€ à´…à´¨àµà´šà´¿à´¤à´®à´¾à´¯ അവസാനം"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "തെറàµà´±à´¾à´¯ സരàµâ€à´µà´°àµâ€"
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT ലഭàµà´¯à´®à´¾à´¯à´¿, à´ªàµà´±à´¤àµà´¤àµàµ à´•à´Ÿà´•àµà´•àµà´¨àµà´¨àµ."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pactl %s\n"
+"libpulse %s-നൊപàµà´ªà´‚ കംപൈലàµâ€ ചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ\n"
+"libpulse %s-നൊപàµà´ªà´‚ ലിങàµà´•ൠചെയàµà´¤à´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ\n"
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµà´³àµà´³ മാതൃകാ ഫയലàµâ€ ദയവായി à´µàµà´¯à´•àµà´¤à´®à´¾à´•àµà´•àµà´•"
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "à´¶à´¬àµà´¦ ഫയലàµâ€ à´¤àµà´±à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "à´®àµà´¨àµà´¨à´±à´¿à´¯à´¿à´ªàµà´ªàµàµ: ഫയലിലàµâ€ നിനàµà´¨àµà´‚ മാതൃകയàµà´Ÿàµ† വിവരണം à´•à´£àµà´Ÿàµà´ªà´¿à´Ÿà´¿à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´ªàµà´ªà´¿à´•àµà´•àµà´µà´¾à´¨àµà´³àµà´³ മാതൃകയàµà´Ÿàµ† പേരàµàµ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "നീകàµà´•à´‚ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´¨àµà´³àµà´³ മാതൃകയàµà´Ÿàµ† പേരàµàµ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "ഒരൠസിങàµà´•ൠഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ ഇനàµâ€à´¡à´•àµà´¸àµà´‚ സിങàµà´•àµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "ഒരൠസോഴàµà´¸àµ ഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ ഇനàµâ€à´¡à´•àµà´¸àµà´‚ സോഴàµà´¸àµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "ഒരൠമൌഡàµà´¯àµ‚à´³àµâ€ നാമവàµà´‚ ആരàµâ€à´—àµà´¯àµà´®àµ†à´¨àµà´±àµà´•à´³àµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ."
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "ഒരൠമൌഡàµà´¯àµ‚à´³àµâ€ ഇനàµâ€à´¡à´•àµà´¸àµ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+"ഒരൠസിങàµà´•à´¿à´²àµâ€ കൂടàµà´¤à´²àµâ€ നിങàµà´™à´³àµâ€ നലàµâ€à´•േണàµà´Ÿà´¤à´¿à´²àµà´². കൂടാതെ, ഒരൠബൂളിയനàµâ€ മൂലàµà´²àµà´¯à´µàµà´‚ നിങàµà´™à´³àµâ€ നലàµâ€à´•േണàµà´Ÿà´¤à´¾à´£àµàµ."
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr ""
+"ഒരൠസോഴàµà´¸à´¿à´²àµâ€ കൂടàµà´¤à´²àµâ€ നിങàµà´™à´³àµâ€ നലàµâ€à´•േണàµà´Ÿà´¤à´¿à´²àµà´². കൂടാതെ, ഒരൠബൂളിയനàµâ€ മൂലàµà´²àµà´¯à´µàµà´‚ നിങàµà´™à´³àµâ€ നലàµâ€à´•േണàµà´Ÿà´¤à´¾à´£àµàµ."
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "ഒരൠകാരàµâ€à´¡àµ നാമം/ഇനàµâ€à´¡à´•àµà´¸àµà´‚ à´ªàµà´°àµŠà´«àµˆà´²àµâ€ നാമവàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "ഒരൠസിങàµà´•ൠനാമം/ഇനàµâ€à´¡à´•àµà´¸àµà´‚ പോരàµâ€à´Ÿàµà´Ÿàµ നാമവàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "ഒരൠസോഴàµà´¸àµ നാമം/ഇനàµâ€à´¡à´•àµà´¸àµà´‚ പോരàµâ€à´Ÿàµà´Ÿàµ നാമവàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "ഒരൠസിങàµà´•ൠനാമം/ഇനàµâ€à´¡à´•àµà´¸àµà´‚ വോളàµà´¯à´µàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "തെറàµà´±à´¾à´¯ വോളàµà´¯à´‚ വിവരണങàµà´™à´³àµâ€"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "ഒരൠസോഴàµà´¸àµ നാമം/ഇനàµâ€à´¡à´•àµà´¸àµà´‚ വോളàµà´¯à´µàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "ഒരൠസിങàµà´•ൠഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ ഇനàµâ€à´¡à´•àµà´¸àµà´‚ വോളàµà´¯à´µàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "തെറàµà´±à´¾à´¯ സിങàµà´•ൠഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ ഇനàµâ€à´¡à´•àµà´¸àµ"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "ഒരൠസിങàµà´•ൠനാമം/ഇനàµâ€à´¡à´•àµà´¸àµà´‚ à´®àµà´¯àµ‚à´Ÿàµà´Ÿàµ ബൂളിയനàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "ഒരൠസോഴàµà´¸àµ നാമം/ഇനàµâ€à´¡à´•àµà´¸àµà´‚ à´®àµà´¯àµ‚à´Ÿàµà´Ÿàµ ബൂളിയനàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "ഒരൠസിങàµà´•ൠഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ ഇനàµâ€à´¡à´•àµà´¸àµà´‚ à´®àµà´¯àµ‚à´Ÿàµà´Ÿàµ ബൂളിയനàµà´‚ നലàµâ€à´•േണàµà´Ÿà´¤àµà´£àµà´Ÿàµàµ"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "തെറàµà´±à´¾à´¯ സിങàµà´•ൠഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ ഇനàµâ€à´¡à´•àµà´¸àµ à´¸àµà´ªàµ†à´¸à´¿à´«à´¿à´•àµà´•േഷനàµâ€"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "ശരിയായ കമാനàµâ€à´¡àµà´•à´³àµâ€ നലàµâ€à´•ിയിടàµà´Ÿà´¿à´²àµà´²."
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr "കമാനàµâ€à´¡àµ ലൈനàµâ€ പാഴàµà´¸àµ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ.\n"
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr "സരàµâ€à´µà´°àµâ€: %s\n"
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr "സോഴàµà´¸àµ: %s\n"
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr "സിങàµà´•àµ: %s\n"
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr "à´•àµà´•àµà´•à´¿: %s\n"
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr "à´•àµà´•àµà´•ീ ഡേറàµà´±à´¾ പാഴàµà´¸àµ ചെയàµà´¯àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ\n"
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr "à´•àµà´•àµà´•ീ ഡേറàµà´±à´¾ സൂകàµà´·à´¿à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ\n"
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr "à´•àµà´²àµˆà´¨àµà´±àµ à´•àµà´°à´®àµ€à´•à´°à´£ ഫയലàµâ€ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ\n"
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr "à´Žà´¨àµâ€à´µà´¯àµ‹à´£àµà´®àµ†à´¨àµà´±àµ à´•àµà´°à´®àµ€à´•à´°à´£ ഡേറàµà´±à´¾ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ\n"
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr "FQDN ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ\n"
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr "à´•àµà´•àµà´•ീ ഡേറàµà´±à´¾ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ\n"
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr "ഇതàµà´µà´°àµ† ലഭàµà´¯à´®à´¾à´•àµà´•ിയിടàµà´Ÿà´¿à´²àµà´².\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "പളàµâ€à´¸àµà´“ഡിയോ ഡെമണàµâ€ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¨à´¤à´¿à´²à´¿à´²àµà´², സെഷനàµâ€ ഡെമണായàµà´‚ à´ªàµà´°à´µà´°àµâ€à´¤àµà´¤à´¿à´•àµà´•àµà´¨àµà´¨à´¿à´²àµà´²."
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr "connect(): %s"
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr "പളàµâ€à´¸àµà´“ഡിയോ ഡെമണàµâ€ ഇലàµà´²à´¾à´¤à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´²àµâ€ പരാജയപàµà´ªàµ†à´Ÿàµà´Ÿàµ."
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr "ഡെമണàµâ€ മറàµà´ªà´Ÿà´¿ നലàµâ€à´•àµà´¨àµà´¨à´¿à´²àµà´²."
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr "poll(): %s"
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr "read(): %s"
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr "write(): %s"
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr "à´“à´Ÿàµà´Ÿàµ‹à´¸àµà´ªàµŒà´£àµâ€ ലോകàµà´•ൠലഭàµà´¯à´®à´¾à´•àµà´•àµà´µà´¾à´¨àµâ€ സാധàµà´¯à´®à´²àµà´²."
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ഡിവൈസിലàµâ€ നിനàµà´¨àµà´‚ à´ªàµà´¤à´¿à´¯ ഡേറàµà´±à´¾ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´¨à´¾à´¯à´¿ ALSA നമàµà´•àµà´•àµàµ അറിയിപàµà´ªàµàµ നലàµâ€à´•ിയിരികàµà´•àµà´¨àµà´¨àµ, "
+"പകàµà´·àµ‡ ഡേറàµà´±à´¾ ലഭàµà´¯à´®à´²àµà´²!\n"
+"ഇതàµàµ ALSA à´¡àµà´°àµˆà´µà´°àµâ€ '%s'-à´²àµà´³àµà´³ ഒരൠബഗാവാം. ദയവായി à´ˆ à´ªàµà´°à´¶àµà´¨à´‚ ALSA ഡവലപàµà´ªà´°àµâ€à´¸à´¿à´¨àµ† അറിയികàµà´•àµà´•.\n"
+"POLLOUT സെറàµà´±àµ വഴി നമàµà´®àµ† അറിയിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ -- പകàµà´·àµ‡, snd_pcm_avail() ലഭàµà´¯à´®à´¾à´•àµà´•ിയതàµàµ 0 "
+"à´…à´²àµà´²àµ†à´™àµà´•à´¿à´²àµâ€ മറàµà´±àµŠà´°àµ മൂലàµà´²àµà´¯à´‚ < min_avail ആണàµàµ."
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ഡിവൈസിലàµâ€ നിനàµà´¨àµà´‚ à´ªàµà´¤à´¿à´¯ ഡേറàµà´±à´¾ ലഭàµà´¯à´®à´¾à´•àµà´•àµà´¨àµà´¨à´¤à´¿à´¨à´¾à´¯à´¿ ALSA നമàµà´•àµà´•àµàµ അറിയിപàµà´ªàµàµ നലàµâ€à´•ിയിരികàµà´•àµà´¨àµà´¨àµ, "
+"പകàµà´·àµ‡ ഡേറàµà´±à´¾ ലഭàµà´¯à´®à´²àµà´²!\n"
+"ഇതàµàµ ALSA à´¡àµà´°àµˆà´µà´°àµâ€ '%s'-à´²àµà´³àµà´³ ഒരൠബഗാവാം. ദയവായി à´ˆ à´ªàµà´°à´¶àµà´¨à´‚ ALSA ഡവലപàµà´ªà´°àµâ€à´¸à´¿à´¨àµ† അറിയികàµà´•àµà´•.\n"
+"POLLIN സെറàµà´±àµ വഴി നമàµà´®àµ† അറിയിചàµà´šà´¿à´°à´¿à´•àµà´•àµà´¨àµà´¨àµ -- പകàµà´·àµ‡, snd_pcm_avail() ലഭàµà´¯à´®à´¾à´•àµà´•ിയതàµàµ 0 "
+"à´…à´²àµà´²àµ†à´™àµà´•à´¿à´²àµâ€ മറàµà´±àµŠà´°àµ മൂലàµà´²àµà´¯à´‚ < min_avail ആണàµàµ."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "à´“à´«àµ"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "ഹൈ ഫിഡലിറàµà´±à´¿ à´ªàµà´²àµ‡à´¬à´¾à´•àµà´•ൠ(A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "ഹൈ ഫിഡലിറàµà´±à´¿ കാപàµà´šà´°àµâ€ (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "ടെലിഫോണി à´¡àµà´¯àµ‚à´ªàµà´²àµ†à´•àµà´¸àµ (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "പളàµâ€à´¸àµà´“ഡിയോ സൌണàµà´Ÿàµ സരàµâ€à´µà´°àµâ€"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "ഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ ഡിവൈസàµà´•à´³àµâ€"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ ഡിവൈസàµà´•à´³àµâ€"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@-à´²àµà´³àµà´³ ഓഡിയോ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "ഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ഡോകàµà´•ിങൠസàµà´±àµà´±àµ‡à´·à´¨àµâ€ ഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ഡോകàµà´•ിങൠസàµà´±àµà´±àµ‡à´·à´¨àµâ€ മൈകàµà´°àµ‹à´«àµ‹à´£àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "ലൈനàµâ€-ഇനàµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "മൈകàµà´°àµ‹à´«àµ‹à´£àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "à´Žà´•àµà´¸àµà´±àµà´±àµ‡à´£à´²àµâ€ മൈകàµà´°àµ‹à´«àµ‹à´£àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "ഇനàµà´±àµ‡à´£à´²àµâ€ മൈകàµà´°àµ‹à´«àµ‹à´£àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "റേഡിയോ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "വീഡിയോ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "à´“à´Ÿàµà´Ÿàµ‹à´®à´¾à´±àµà´±à´¿à´•ൠഗെയിനàµâ€ à´•à´£àµà´Ÿàµà´°àµ‹à´³àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "à´“à´Ÿàµà´Ÿàµ‹à´®à´¾à´±àµà´±à´¿à´•ൠഗെയിനàµâ€ à´•à´£àµà´Ÿàµà´°àµ‹à´³àµâ€ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "ബൂസàµà´±àµà´±àµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "ബൂസàµà´±àµà´±àµ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "ആംപàµà´²à´¿à´«à´¯à´°àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "ആംപàµà´²à´¿à´«à´¯à´°àµâ€ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "ബൂസàµà´±àµà´±àµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "ബൂസàµà´±àµà´±àµ ലഭàµà´¯à´®à´²àµà´²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "അനലോഗൠഹെഡàµà´«àµ‹à´£àµà´•à´³àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "അനലോഗൠഇനàµâ€à´ªàµà´Ÿàµà´Ÿàµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "അനലോഗൠമൈകàµà´°àµ‹à´«àµ‹à´£àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "അനലോഗൠലൈനàµâ€-ഇനàµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "അനലോഗൠറേഡിയോ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "അനലോഗൠവീഡിയോ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "അനലോഗൠഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "അനലോഗൠഹെഡàµà´«àµ‹à´£àµà´•à´³àµâ€"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "അനലോഗൠഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "അനലോഗൠമോണോ ഔടàµà´Ÿàµà´ªàµà´Ÿàµà´Ÿàµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "അനലോഗൠസàµà´±àµà´±àµ€à´°à´¿à´¯àµ‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "അനലോഗൠമോണോ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "അനലോഗൠസàµà´±àµà´±àµ€à´°à´¿à´¯àµ‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "അനലോഗൠസറൌണàµà´Ÿàµ 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "ഡിജിറàµà´±à´²àµâ€ à´¸àµà´±àµà´±àµ€à´°à´¿à´¯àµ‹ (IEC958) "
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "ഡിജിറàµà´±à´²àµâ€ സറൌണàµà´Ÿàµ 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "ഡിജിറàµà´±à´²àµâ€ സറൌണàµà´Ÿàµ 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "ഡിജിറàµà´±à´²àµâ€ സറൌണàµà´Ÿàµ 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "ഡിജിറàµà´±à´²àµâ€ à´¸àµà´±àµà´±àµ€à´°à´¿à´¯àµ‹ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "അനലോഗൠമോണോ à´¡àµà´¯àµ‚à´ªàµà´²àµ†à´•àµà´¸àµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "അനലോഗൠസàµà´±àµà´±àµ€à´°à´¿à´¯àµ‹ à´¡àµà´¯àµ‚à´ªàµà´²àµ†à´•àµà´¸àµ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ഡിജിറàµà´±à´²àµâ€ à´¸àµà´±àµà´±àµ€à´°à´¿à´¯àµ‹ à´¡àµà´¯àµ‚à´ªàµà´²àµ†à´•àµà´¸àµ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "ലോ à´«àµà´°àµ€à´•àµà´µà´¨àµâ€à´¸à´¿ à´Žà´®àµà´®à´¿à´±àµà´±à´°àµâ€"
diff --git a/po/mr.po b/po/mr.po
index 5aba3b9b..329b271d 100644
--- a/po/mr.po
+++ b/po/mr.po
@@ -1,67 +1,29 @@
-# translation of pulseaudio.master-tx.pulseaudio.po to marathi
+# translation of pulseaudio.master-tx.po to Marathi
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Sandeep Shedmake <sandeep.shedmake@gmail.com>, 2009.
+# Sandeep Shedmake <sshedmak@redhat.com>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio.master-tx.pulseaudio\n"
+"Project-Id-Version: pulseaudio.master-tx\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-06 13:43+0530\n"
-"Last-Translator: Sandeep Shedmake <sandeep.shedmake@gmail.com>\n"
-"Language-Team: marathi\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-09 18:30+0530\n"
+"Last-Translator: Sandeep Shedmake <sshedmak@redhat.com>\n"
+"Language-Team: Marathi <fedora-trans-mr@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: KBabel 1.11.4\n"
"Plural-Forms: nplurals=2; plural=(n!=1);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "à¤à¤¨à¤²à¥‰à¤— मोनो"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "à¤à¤¨à¤²à¥‰à¤— सà¥à¤Ÿà¤¿à¤°à¥€à¤“"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "डिजीटल सà¥à¤Ÿà¤¿à¤°à¥€à¤“ (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "डिजीटल सà¥à¤Ÿà¤¿à¤°à¥€à¤“ (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "à¤à¤¨à¤²à¥‰à¤— सराऊनà¥à¤¡ 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "डिजीटल सराऊनà¥à¤¡ 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "à¤à¤¨à¤²à¥‰à¤— सराऊनà¥à¤¡ 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "à¤à¤¨à¤²à¥‰à¤— सराऊनà¥à¤¡ 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "à¤à¤¨à¤²à¥‰à¤— सराऊनà¥à¤¡ 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "डिजीटल सराऊनà¥à¤¡ 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "à¤à¤¨à¤²à¥‰à¤— सराऊनà¥à¤¡ 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -73,7 +35,7 @@ msgstr ""
"हे सहसा ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' अंतरà¥à¤—त बग अशू शकते. कृपया या अडचणीस ALSA डेवà¥à¤¹à¤²à¤ªà¤° करीता "
"कळवा."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -85,7 +47,7 @@ msgstr ""
"हे सहसा ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' अंतरà¥à¤—त बग अशू शकते. कृपया या अडचणीस ALSA डेवà¥à¤¹à¤²à¤ªà¤° करीता "
"कळवा."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -97,11 +59,45 @@ msgstr ""
"हे सहसा ALSA डà¥à¤°à¤¾à¤‡à¤µà¤° '%s' अंतरà¥à¤—त बग अशू शकते. कृपया या अडचणीस ALSA डेवà¥à¤¹à¤²à¤ªà¤° करीता "
"कळवा."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "नलà¥à¤² असलà¥à¤¯à¤¾à¤µà¤°à¤¹à¥€ नेहमी किमान à¤à¤• सींक लोड करून ठेवा"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "डमà¥à¤®à¥€ आऊटपà¥à¤Ÿ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "आभासी LADSPA सींक"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<सींक करीता नाव> sink_properties=<सींक करीता गà¥à¤£à¤§à¤°à¥à¤®> "
+"master=<फिलà¥à¤Ÿà¤°à¤œà¥‹à¤—ी सींकचे नाव> format=<चाचणी रूपण> rate=<चाचणी दर> "
+"channels=<वाहिनींची संखà¥à¤¯à¤¾> channel_map=<वाहिनी नकाशा> plugin=<ladspa पà¥à¤²à¤—इन "
+"नाव> label=<ladspa पà¥à¤²à¤—इन लेबल> control=<इंपà¥à¤Ÿ कंटà¥à¤°à¥‹à¤² मà¥à¤²à¥à¤¯à¤¾à¤‚ची सà¥à¤µà¤²à¥à¤ªà¤µà¤¿à¤°à¤¾à¤® विभाजीत "
+"सूची>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "कà¥à¤²à¥‰à¤•à¥à¤¡à¥ NULL सींक"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null आऊटपà¥à¤Ÿ"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "आंतरीक ऑडिओ"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "मोडेम"
@@ -117,375 +113,292 @@ msgstr "नवीन dl दाखलकरà¥à¤¤à¤¾ वाटप करणà¥à¤¯
msgid "Failed to add bind-now-loader."
msgstr "bind-now-loader समावेष करणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ बसशी जà¥à¤³à¤µà¤£à¥€ करणà¥à¤¯à¤¾à¤¸ अशकà¥à¤¯: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PID पासून कॉलर पà¥à¤°à¤¾à¤ªà¥à¤¤ करणे अशकà¥à¤¯: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "कॉलर ऑबजेकà¥à¤Ÿ वरील UID निशà¥à¤šà¤¿à¤¤ करणे अशकà¥à¤¯."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK सतà¥à¤° पà¥à¤°à¤¾à¤ªà¥à¤¤ करणे अपयशी."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "सतà¥à¤° ऑबजेकà¥à¤Ÿ वरील UID निशà¥à¤šà¤¿à¤¤ करणे अशकà¥à¤¯."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitAction वाटप करणे अशकà¥à¤¯."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "action_id निशà¥à¤šà¤¿à¤¤ करणे अशकà¥à¤¯"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext वाटप करणे अशकà¥à¤¯."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContext पà¥à¤°à¤¾à¤°à¤‚भ करणे अशकà¥à¤¯: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "कॉलर अधिकृत आहे की नाही हे ओळखणे शकà¥à¤¯ नाही: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "परवानगी पà¥à¤°à¤¾à¤ªà¥à¤¤ करणे अशकà¥à¤¯: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit ने '%s' सह पà¥à¤°à¤¤à¤¿à¤¸à¤¾à¤¦ दिला"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "संकेत %s पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "बाहेर पडत आहे."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "वापरकरà¥à¤¤à¤¾ '%s' शोधणे अशकà¥à¤¯."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "गट '%s' शोधणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "वापरकरà¥à¤¤à¤¾ '%s' (UID %lu) व गट '%s' (GID %lu) आढळले."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "वापरकरà¥à¤¤à¤¾ '%s' व गट '%s' चे GID जà¥à¤³à¤¤ नाही."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "वापरकरà¥à¤¤à¤¾ '%s' ची मà¥à¤–à¥à¤¯ डिरेकà¥à¤Ÿà¥à¤°à¥€ '%s' नाही, दà¥à¤°à¥à¤²à¤•à¥à¤· करत आहे."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s' बनवणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "गट यादी बदलवणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID बदलवणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID बदलवणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "रूट परवानगी यशसà¥à¤µà¥€à¤°à¤¿à¤¤à¥à¤¯à¤¾ वगळले."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ भर पदà¥à¤§à¤¤ या पà¥à¤²à¥…टफॉरà¥à¤® करीता समरà¥à¤¥à¥€à¤¤ नाही."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) अपयशी: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "आदेश ओळ वाचणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "आपण गट '%s' अंतरà¥à¤—त आहोत, उचà¥à¤š-पà¥à¤°à¤¾à¤§à¤¨à¥à¤¯à¤•à¥à¤°à¤® वेळपतà¥à¤°à¤• करीता परवानगी देते."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "आपण गट '%s' अंतरà¥à¤—त आहोत, रियल-टाईम वेळपतà¥à¤°à¤• करीता परवानगी देते."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit आपलà¥à¤¯à¤¾à¤²à¤¾ acquire-high-priority परवानगी देतो."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit acquire-high-priority परवानगी नकारतो."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit acquire-real-time परवानगी पà¥à¤°à¤µà¤¿à¤¤à¥‹."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit acquire-real-time परवानगी नकारतो."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"SUID रूटला कॉल केले व वासà¥à¤¤à¤µà¤¿à¤•-वेळ व/किंवा संयोजना अंतरà¥à¤—त उचà¥à¤š-पà¥à¤°à¤¾à¤§à¤¾à¤¨à¥à¤¯à¤•à¥à¤°à¤® वेळपतà¥à¤°à¤• "
-"विनंतीकृत केले. तरी, आमचà¥à¤¯à¤¾à¤•डे आवशà¥à¤¯à¤• परवानगी नाही:\n"
-"आमà¥à¤¹à¥€ गट '%s' अंतरà¥à¤—त नाही, PolicyKit ने विनंतीकृत परवानगी देणà¥à¤¯à¤¾à¤¸ नकार दिला व "
-"RLIMIT_NICE/RLIMIT_RTPRIO सà¥à¤¤à¥à¤°à¥‹à¤¤ मरà¥à¤¯à¤¾à¤¦à¤¾ वाढविणे आवशà¥à¤¯à¤• आहे.\n"
-"रियल-टाइम/उचà¥à¤š-पà¥à¤°à¤¾à¤§à¤¾à¤¨à¥à¤¯à¤•à¥à¤°à¤® वेळपतà¥à¤°à¤• कारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ करणà¥à¤¯à¤¾à¤•रीता कृपयायोगà¥à¤¯ PolicyKit "
-"परवानगी पà¥à¤°à¤¾à¤ªà¥à¤¤ करा, किंवा '%s' चे सदसà¥à¤¯ बनवा, किंवा या वापरकरà¥à¤¤à¤¾ करीताRLIMIT_NICE/"
-"RLIMIT_RTPRIO सà¥à¤¤à¥à¤°à¥‹à¤¤ मरà¥à¤¯à¤¾à¤¦à¤¾ वाढवा."
-
-#: ../src/daemon/main.c:581
+#: ../src/daemon/main.c:535
msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"संयोजना अंतरà¥à¤—त उचà¥à¤š-पà¥à¤°à¤¾à¤§à¤¾à¤¨à¥à¤¯à¤•à¥à¤°à¤® वेळपतà¥à¤°à¤• कारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ केले करार दà¥à¤µà¤¾à¤°à¥‡ सà¥à¤µà¥€à¤•ारà¥à¤¯ नाही."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "यशसà¥à¤µà¥€à¤°à¤¿à¤¤à¥à¤¯à¤¾ RLIMIT_RTPRIO वाढवले"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO अपयशी: %s"
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "CAP_NICE करीता पà¥à¤°à¤¯à¤¤à¥à¤¨ बंद केले"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"संयोजना अंतरà¥à¤—त रियल-टाईम वेळपतà¥à¤° कारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ करत आहे परंतॠकरार दà¥à¤µà¤¾à¤°à¥‡ सà¥à¤µà¥€à¤•ारà¥à¤¯ नाही."
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "डिमन कारà¥à¤¯à¤°à¤¤ नाही"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "डिमन PID %u नà¥à¤°à¥‚प कारà¥à¤¯à¤°à¤¤ आहे"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "डिमन नषà¥à¤Ÿ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr "हा कारà¥à¤¯à¤•à¥à¤°à¤® रूट नà¥à¤°à¥‚प चालविणà¥à¤¯à¤¾à¤•रीता नाही (जोपरà¥à¤¯à¤‚त --system निशà¥à¤šà¤¿à¤¤ नाही)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "रूट परवानगी आवशà¥à¤¯à¤•."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ घटनांकरीता --start समरà¥à¤¥à¥€à¤¤ नाही."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ पदà¥à¤§à¤¤à¥€ अंतरà¥à¤—त कारà¥à¤¯à¤°à¤¤, परंतॠ--disallow-exit निशà¥à¤šà¤¿à¤¤ केले नाही!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"पà¥à¤°à¤£à¤¾à¤²à¥€ पदà¥à¤§à¤¤à¥€ अंतरà¥à¤—त कारà¥à¤¯à¤°à¤¤, परंतॠ--disallow-module-loading निशà¥à¤šà¤¿à¤¤ केले नाही!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ पदà¥à¤§à¤¤à¥€ अंतरà¥à¤—त कारà¥à¤¯à¤°à¤¤, SHM पदà¥à¤§à¤¤ जबरनरितà¥à¤¯à¤¾ अकारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ करत आहे!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ पदà¥à¤§à¤¤à¥€ अंतरà¥à¤—त कारà¥à¤¯à¤°à¤¤, रिकामे वेळ जबरनरितà¥à¤¯à¤¾ अकारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ करत आहे!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "पाइप अपयशी: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() अपयशी: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() अपयशी: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "डिमन सà¥à¤Ÿà¤¾à¤°à¥à¤Ÿà¤…प अपयशी."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "डिमन सà¥à¤Ÿà¤¾à¤°à¥à¤Ÿà¤…प यशसà¥à¤µà¥€."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() अपयशी: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "हे PulseAudio %s आहे"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "कंपाइलेशन यजमान: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "कंपाइलेशन CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "यजमान वर कारà¥à¤¯à¤°à¤¤: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPUs आढळले."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "पान आकार %lu बाईटसॠआहे"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Valgrind समरà¥à¤¥à¤¨à¤¶à¥€ कंपाईल केले: होय"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Valgrind समरà¥à¤¥à¤¨à¤¶à¥€ कंपाईल केले: नाही"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind पदà¥à¤§à¤¤à¥€à¤¤ कारà¥à¤¯à¤°à¤¤: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "यजमान वर कारà¥à¤¯à¤°à¤¤: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "अनà¥à¤•ूल बिलà¥à¤¡: होय"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "अनà¥à¤•ूल बिलà¥à¤¡: नाही"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG वरà¥à¤£à¥€à¤•ृत, सरà¥à¤µ asserts अकारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH वरà¥à¤£à¥€à¤•ृत, फकà¥à¤¤ जलद मारà¥à¤—ीय asserts अकारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ केले."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "सरà¥à¤µ asserts कारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ केले."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "मशीन ID पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "मशीन ID %s आहे."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "मशीन ID %s आहे."
+msgstr "सतà¥à¤° ID %s आहे."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "रनटाईम डिरेकà¥à¤Ÿà¥à¤°à¥€ %s वापरत आहे."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "सà¥à¤¥à¤¿à¤¤à¥€ डिरेकà¥à¤Ÿà¥à¤°à¥€ %s वापरत आहे."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "घटक डिरेकà¥à¤Ÿà¥à¤°à¥€ %s वापरत आहे."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ पदà¥à¤§à¤¤à¥€à¤¤ कारà¥à¤¯à¤°à¤¤: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"ठिक आहे, तà¥à¤®à¥à¤¹à¥€ PA पà¥à¤°à¤£à¤¾à¤²à¥€ मोडमधà¥à¤¯à¥‡ चालवत आहात. कृपया लकà¥à¤·à¤¾à¤¤ ठेवा असे करणà¥à¤¯à¤¾à¤¸ फारशी "
+"आवशà¥à¤¯à¤•ता नाही.\n"
+"असे कारà¥à¤¯à¤¾à¤¨à¥à¤µà¥€à¤¤ केलà¥à¤¯à¤¾à¤¸, काहिक घटक योगà¥à¤¯à¤ªà¥à¤°à¤•ारे कारà¥à¤¯ नसेल करत असलà¥à¤¯à¤¾à¤¸ तà¥à¤¯à¤¾à¤²à¤¾ तà¥à¤®à¥à¤¹à¥€à¤š "
+"जबाबदार राहणार.\n"
+"पà¥à¤°à¤£à¤¾à¤²à¥€ मोड दोकादायक आहे यासाठी कृपया http://pulseaudio.org/wiki/"
+"WhatIsWrongWithSystemMode वाचा."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() अपयशी."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "नवीन उचà¥à¤š-बिंदूता टाइमर उपलबà¥à¤§! Bon appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -493,31 +406,31 @@ msgstr ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() अपयशी."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "डिमन पà¥à¤°à¤¾à¤°à¤‚भ करणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "विना विभाग दाखल केलà¥à¤¯à¤¾à¤¸ डिमन पà¥à¤°à¤¾à¤°à¤‚भ à¤à¤¾à¤²à¥‡, कारà¥à¤¯ करणà¥à¤¯à¤¾à¤¸ नकार."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "डिमन सà¥à¤Ÿà¤¾à¤°à¥à¤Ÿà¤…प पूरà¥à¤£ à¤à¤¾à¤²à¥‡."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "डिमन पूरà¥à¤£à¤ªà¤£à¥‡ बंद करणà¥à¤¯à¤¾à¤¸ पà¥à¤°à¤¾à¤°à¤‚भ केले."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "डिमन नषà¥à¤Ÿ केले."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -660,15 +573,15 @@ msgstr ""
"\n"
" -n Don't load default script file\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -676,52 +589,52 @@ msgstr ""
"--log-level यास लॉग सà¥à¤¤à¤°à¥€à¤¯ बाब अपेकà¥à¤·à¥€à¤¤ आहे (à¤à¤•तर कà¥à¤·à¥‡à¤¤à¥à¤° 0..4 अंतरà¥à¤—त संखà¥à¤¯à¤¾à¤¯à¥€ किंवा "
"debug, info, notice, warn, error पैकी à¤à¤•)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "अवैध लॉग लकà¥à¤·à¥à¤¯: 'syslog', 'stderr' किंवा 'auto' पैकी à¤à¤• वापरा."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "अवैध पà¥à¤¨à¥à¤¹ सॅमà¥à¤ªà¤² पदà¥à¤§à¤¤ '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm यास बूलीयन बाब अपेकà¥à¤·à¥€à¤¤ आहे"
@@ -760,77 +673,87 @@ msgstr "वापरणी: %s\n"
msgid "Load Once: %s\n"
msgstr "à¤à¤•दा दाखल करा: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "मारà¥à¤—: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] अवैध लॉग लकà¥à¤·à¥à¤¯ '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] अवैध लॉग सà¥à¤¤à¤° '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] अवैध पà¥à¤¨à¥à¤¹ सॅमà¥à¤ªà¤² पदà¥à¤§à¤¤ '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] अवैध rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit या पà¥à¤²à¥…टफॉरà¥à¤® वर समरà¥à¤¥à¥€à¤¤ नाही."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] अवैध सॅमà¥à¤ªà¤² सà¥à¤µà¤°à¥‚प '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] अवैध सॅमà¥à¤ªà¤² दर '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] अवैध सॅमà¥à¤ªà¤² मारà¥à¤— '%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] अवैध मारà¥à¤— मॅप '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] अवैध तà¥à¤•डे '%s' यांची à¤à¤•ूण संखà¥à¤¯à¤¾."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] अवैध तà¥à¤•डà¥à¤¯à¤¾à¤šà¥‡ आकार '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] अवैध nice सà¥à¤¤à¤° '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] अवैध सॅमà¥à¤ªà¤² दर '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "संयोजना फाइल उघडणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -838,18 +761,14 @@ msgstr ""
"निशà¥à¤šà¤¿à¤¤ मà¥à¤²à¤­à¥‚त वाहिनी मॅपकडे निशà¥à¤šà¤¿à¤¤ à¤à¤•ूण मà¥à¤²à¤­à¥‚त वाहिनी पेकà¥à¤·à¤¾ वेगळे वाहिनी संखà¥à¤¯à¤¾ "
"समाविषà¥à¤Ÿà¥€à¤¤ आहे."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### संयोजना फाइल: %s पासून वाचा ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "रà¥à¤Ÿ परवानगी वगळत आहे."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "कà¥à¤·à¤®à¤¤à¤¾ यशसà¥à¤µà¥€à¤°à¤¿à¤¤à¥à¤¯à¤¾ CAP_SYS_NICE करीता मरà¥à¤¯à¤¾à¤¦à¥€à¤¤ केले."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "परवानगी वगळत आहे."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -859,255 +778,237 @@ msgstr "PulseAudio आवाज पà¥à¤°à¤£à¤¾à¤²à¥€"
msgid "Start the PulseAudio Sound System"
msgstr "PulseAudio आवाज पà¥à¤°à¤£à¤¾à¤²à¥€ सà¥à¤°à¥‚ करा"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "PulseAudio डिमन करीता उचà¥à¤š-पà¥à¤°à¤¾à¤§à¤¾à¤¨à¥à¤¯à¤•à¥à¤°à¤® वेळपतà¥à¤°à¤• (नकारातà¥à¤®à¤• Unix nice सà¥à¤¤à¤°)"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio डिमन करीता रियल-टाइम वेळपतà¥à¤°à¤•"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ करार PulseAudio ला उचà¥à¤š-पà¥à¤°à¤¾à¤§à¤¾à¤¨à¥à¤¯à¤•à¥à¤°à¤® वेळपतà¥à¤°à¤• पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤ªà¤¾à¤¸à¥‚न रोखते."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr "पà¥à¤°à¤£à¤¾à¤²à¥€ करार PulseAudio ला रियल-टाइम वेळपतà¥à¤°à¤• पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤ªà¤¾à¤¸à¥‚न रोखते."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "मोनो"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "समोर मधà¥à¤¯à¤­à¤¾à¤—ी"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "समोर डावीकडे"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "समोर उजवीकडे"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "पाठीमागे भधà¥à¤¯à¤­à¤¾à¤—ी"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "पाठीमागे डावीकडे"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "पाठीमागे उजवीकडे"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "कमी कà¥à¤°à¤¿à¤•à¥à¤µà¥‡à¤¨à¥à¤¸à¥€ सà¥à¤¤à¥à¤°à¥‹à¤¤"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "समोर डावी-कडील-मधà¥à¤¯à¤­à¤¾à¤—ी"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "समोर उजवी-कडील-मधà¥à¤¯à¤­à¤¾à¤—ी"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "डावी बाजू"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "उजवी बाजू"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "ऑकà¥à¤œà¥€à¤²à¤°à¥€ 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "वरील मधà¥à¤¯"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "वरील समोरचे मधà¥à¤¯"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "वरील समोरचे डावे"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "वरील समोरचे उजवे"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "वरील पाठीमागचे मधà¥à¤¯"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "वरील पाठीमागचे डावे"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "वरील पाठीमागचे उजवे"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(अवैध)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "सà¥à¤Ÿà¤¿à¤°à¥€à¤“"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "सराऊनà¥à¤¡ 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "सराऊनà¥à¤¡ 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "सराऊनà¥à¤¡ 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "सराऊनà¥à¤¡ 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "सराऊनà¥à¤¡ 7.1"
@@ -1211,27 +1112,35 @@ msgstr "लागू केले आहे असे आढळले नाहà
msgid "Client forked"
msgstr "कà¥à¤²à¤¾à¤à¤‚ट विभाजीत केले"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "इंपà¥à¤Ÿ/आऊटपà¥à¤Ÿ तà¥à¤°à¥à¤Ÿà¥€"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "उपकरन किंव सà¥à¤°à¥‹à¤¤ वà¥à¤¯à¤¸à¥à¤¥"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1244,197 +1153,191 @@ msgstr "XOpenDisplay() अपयशी"
msgid "Failed to parse cookie data"
msgstr "कà¥à¤•ी डेटा वाचणà¥à¤¯à¤¾à¤¸ अपयशी"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "संयोजना फाइल '%s' उघडणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "कà¥à¤•ी दाखल केले नाही. जà¥à¤³à¤µà¤£à¥€à¤šà¤¾ पà¥à¤°à¤¯à¤¤à¥à¤¨ करत आहे."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "अपरिचीत वाढ '%s' करीता संदेश पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() अपयशी: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® रिकामे करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() अपयशी: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "पà¥à¤²à¥‡à¤¬à¥…क सà¥à¤Ÿà¥à¤°à¥€à¤® रिकामे à¤à¤¾à¤²à¥‡."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® यशसà¥à¤µà¥€à¤°à¤¿à¤¤à¥à¤¯à¤¾ बनवले.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "सरà¥à¤µà¥à¤¹à¤° करीता जà¥à¤³à¤µà¤£à¥€ डà¥à¤°à¥‡à¤¨ केली."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() अपयशी: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "बफर मेटà¥à¤°à¥€à¤•: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() अपयशी: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "बफर मेटà¥à¤°à¥€à¤•: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() अपयशी: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "उदाहरणतया spec '%s', वाहिनी नकाशा '%s' वापरत आहे.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() अपयशी: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "साधन %s शी जà¥à¤³à¤²à¥‡ (%u, %s ससà¥à¤ªà¥‡à¤‚ड केले).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® यशसà¥à¤µà¥€à¤°à¤¿à¤¤à¥à¤¯à¤¾ निरà¥à¤®à¤¾à¤£ केले."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® तà¥à¤°à¥à¤Ÿà¥€: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() अपयशी: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® साधन ससà¥à¤ªà¥‡à¤‚ड केले.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "बफर मेटà¥à¤°à¥€à¤•à¥à¤¸à¥: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® साधन पà¥à¤¨à¥à¤¹à¤¾ सà¥à¤°à¥‚ केले.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "बफर मेटà¥à¤°à¥€à¤•à¥à¤¸à¥: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® underrun.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "उदाहरणारà¥à¤¥ spec '%s', वाहिनी नकाशा '%s' वापरत आहे."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® overrun.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "साधन %s शी जà¥à¤³à¤²à¥‡ (%u, %s ससà¥à¤ªà¥‡à¤‚ड केले)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® सà¥à¤°à¥‚ केले.%s \n"
+msgid "Stream error: %s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® तà¥à¤°à¥à¤Ÿà¥€: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® साधन %s कडे सà¥à¤¥à¤¾à¤¨à¤¾à¤‚तरीत केले (%u, %ssuspended).%s \n"
+msgid "Stream device suspended.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® साधन ससà¥à¤ªà¥‡à¤‚ड केले.%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "नाही "
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® बफर गà¥à¤£à¤§à¤°à¥à¤® बदलले.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® साधन पà¥à¤¨à¤ƒ सà¥à¤°à¥‚ केले.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "जà¥à¤³à¤µà¤£à¥€ सà¥à¤¥à¤¾à¤ªà¥€à¤¤ केली.%s \n"
+msgid "Stream underrun.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® underrun.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() अपयशी: %s\n"
+msgid "Stream overrun.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® overrun.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() अपयशी: %s\n"
+msgid "Stream started.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® started.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() अपयशी: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® साधन %s कडे सà¥à¤¥à¤¾à¤¨à¤¾à¤‚तरीत केले (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "जà¥à¤³à¤µà¤£à¥€ अपयशी: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "नाही "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® रिकामे करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® बफर गà¥à¤£à¤§à¤°à¥à¤® बदलले.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "पà¥à¤²à¥‡à¤¬à¥…क सà¥à¤Ÿà¥à¤°à¥€à¤® रिकामे केले.\n"
+msgid "Connection established.%s"
+msgstr "जà¥à¤³à¤µà¤£à¥€ सà¥à¤¥à¤¾à¤ªà¥€à¤¤ केली.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "सरà¥à¤µà¤° करीता जà¥à¤³à¤µà¤£à¥€ डà¥à¤°à¥‡à¤¨ केली.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() अपयशी: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() अपयशी: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() अपयशी: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() अपयशी: %s\n"
+msgid "Connection failure: %s"
+msgstr "जà¥à¤³à¤µà¤£à¥€ अपयशी: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() अपयशी: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "संकेत पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡, बाहेर पडत आहे.\n"
+msgid "write() failed: %s"
+msgstr "write() अपयशी: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "विलंब पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "संकेत पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡, बाहेर पडत आहे."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "वेळ: %0.3f sec; विलंब: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "विलंब पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() अपयशी: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "वेळ: %0.3f sec; विलंब: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() अपयशी: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1460,8 +1363,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1484,6 +1389,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
@@ -1509,8 +1423,10 @@ msgstr ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1533,8 +1449,13 @@ msgstr ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1545,129 +1466,169 @@ msgstr ""
"libpulse %s शी कंपाई केले\n"
"libpulse %s शी लिंक केले\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "अवैध वाहिनी नकाशा '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "अवैध कà¥à¤²à¤¾à¤à¤‚टचे नाव '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "अवैध विलंब संयोजना '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "अवैध सà¥à¤Ÿà¥à¤°à¥€à¤®à¤šà¥‡ नाव '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "अवैध कारà¥à¤¯ वेळ संयोजना '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "अवैध वाहिनी नकाशा '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "अवैध सॅमà¥à¤ªà¤² संयोजना\n"
+msgid "Invalid latency specification '%s'"
+msgstr "अवैध विलंब संयोजना '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "वाहिनी नकाशा सॅमà¥à¤ªà¤² संयोजनाशी जà¥à¤³à¤¤ नाही\n"
+msgid "Invalid process time specification '%s'"
+msgstr "अवैध कारà¥à¤¯ वेळ संयोजना '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "%s सà¥à¤Ÿà¥à¤°à¥€à¤® सॅमà¥à¤ªà¤² संयोजना '%s' शी उघडत आहे.\n"
+msgid "Invalid property '%s'"
+msgstr "अवैध गà¥à¤£à¤§à¤°à¥à¤® '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "रेकॉरà¥à¤¡à¥€à¤‚ग"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "अपरिचीत फाइल रूपण %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "पà¥à¤²à¥‡à¤¬à¥…क"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "अवैध सॅमà¥à¤ªà¤² संयोजना"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "खूप जासà¥à¤¤ बाब.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "खूप जासà¥à¤¤ बाब."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() अपयशी.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "फाइलसाठी सॅमà¥à¤ªà¤² माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() अपयशी.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "आवाज फाइल उघडणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() अपयशी.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "सावधानता: निरà¥à¤¦à¥‡à¤¶à¥€à¤¤ चाचणी संयोजना फाइलमधील संयोजनाशी खोडून पà¥à¤¨à¤ƒ लिहीली जाईल."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() अपयशी: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "फाइलपासून चाचणी संयोजना माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "सावधानता: फाइलपासून वाहिनी नकाशा ओळखणà¥à¤¯à¤¾à¤¸ अपयशी."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "वाहिनी नकाशा चाचणी संयोजनाशी जà¥à¤³à¤¤ नाही"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "सावधानता: वाहिनी नकाशा फाइलमधà¥à¤¯à¥‡ लिहणà¥à¤¯à¤¾à¤¸ अपयशी."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() अपयशी.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "%s सà¥à¤Ÿà¥à¤°à¥€à¤® चाचणी संयोजना '%s' व वाहिनी नकाशा '%s' सह उघडत आहे."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "रेकॉरà¥à¤¡à¥€à¤‚ग"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "पà¥à¤²à¥‡à¤¬à¥…क"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() अपयशी."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() अपयशी."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() अपयशी."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() अपयशी.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() अपयशी: %s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rrttime_new() अपयशी."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() अपयशी."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "ससà¥à¤ªà¥‡à¤‚ड करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "पà¥à¤¨à¥à¤¹à¤¾ चालू करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "सावधानता: आवाज सरà¥à¤µà¤° सà¥à¤¥à¤¾à¤¨à¥€à¤¯ नाही, ससà¥à¤ªà¥‡à¤‚ड करत नाही.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "जà¥à¤³à¤µà¤£à¥€ अपयशी: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡, बाहेर पडत आहे.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "सावधानता: उप कारà¥à¤¯ संकेत %u दà¥à¤µà¤¾à¤°à¥‡ नषà¥à¤Ÿ करणà¥à¤¯à¤¾à¤¤ आले\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1686,7 +1647,7 @@ msgstr ""
"to\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1697,35 +1658,61 @@ msgstr ""
"libpulse %s शी कंपाई केले\n"
"libpulse %s शी लिंक केले\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() अपयशी.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() अपयशी.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() अपयशी.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "आकडेवारी पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "आकडेवारी पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "वरà¥à¤¤à¤®à¤¾à¤¨à¤•à¥à¤·à¤£à¥€ वापरणीत आहे: %2$s बाईटसॠसमाविषà¥à¤Ÿà¥€à¤¤ à¤à¤•ूण %1$u बà¥à¤²à¥‰à¤•à¥à¤¸à¥ .\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "संपूरà¥à¤£ कारà¥à¤¯à¤•ाळवेळी लागू केले: %2$s बाईटसॠसमाविषà¥à¤Ÿà¥€à¤¤ à¤à¤•ूण %1$u बà¥à¤²à¥‰à¤•à¥à¤¸à¥ .\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "सॅपल कॅशे आकार: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "सरà¥à¤µà¤° माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "सरà¥à¤µà¤° माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1733,7 +1720,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"वापरकरà¥à¤¤à¤¾ नाव: %s\n"
"आयोजक नाव: %s\n"
@@ -1741,16 +1728,16 @@ msgstr ""
"सरà¥à¤µà¤° आवृतà¥à¤¤à¥€: %s\n"
"मà¥à¤²à¤­à¥‚त सॅमà¥à¤ªà¤² संयोनजा: %s\n"
"मà¥à¤²à¤­à¥‚त वाहिनी नकाशा: %s\n"
-"मà¥à¤²à¤­à¥‚त सिंक: %s\n"
-"मà¥à¤²à¤­à¥‚त सà¥à¤¤à¥à¤°à¥‹à¤¤: %s\n"
+"मà¥à¤²à¤­à¥‚त सींक: %s\n"
+"मà¥à¤²à¤­à¥‚त सà¥à¤°à¥‹à¤¤: %s\n"
"कà¥à¤•ीज: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "sink माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "sink माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1789,12 +1776,22 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tपोरà¥à¤Ÿà¤¸à¥:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "सà¥à¤¤à¥à¤°à¥‹à¤¤ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tसकà¥à¤°à¥€à¤¯ पोरà¥à¤Ÿ: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "सà¥à¤°à¥‹à¤¤ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1833,20 +1830,20 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "विभाग माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "विभाग माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1863,12 +1860,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "कà¥à¤²à¤¾à¤à¤‚ट माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "कà¥à¤²à¤¾à¤à¤‚ट माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1883,12 +1880,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "कारà¥à¤¡ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "कारà¥à¤¡ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1905,22 +1902,22 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tसंकà¥à¤·à¤¿à¤ªà¥à¤¤ माहिती:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tसकà¥à¤°à¥€à¤¯ संकà¥à¤·à¤¿à¤ªà¥à¤¤ माहिती: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "सिंक इनपà¥à¤Ÿ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "सींक इंपà¥à¤Ÿ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1957,12 +1954,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "सà¥à¤¤à¥à¤°à¥‹à¤¤ आऊटपà¥à¤Ÿ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "सà¥à¤°à¥‹à¤¤ आऊटपà¥à¤Ÿ माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1991,12 +1988,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "सॅमà¥à¤ªà¤² माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "सॅमà¥à¤ªà¤² माहिती पà¥à¤°à¤¾à¤ªà¥à¤¤ करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2027,23 +2024,80 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "अपयशी: %s\n"
+msgid "Failure: %s"
+msgstr "अपयशी: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "सॅमà¥à¤ªà¤² अपलोड करणà¥à¤¯à¤¾à¤¸ अपयशी: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "सॅमà¥à¤ªà¤² अपलोड करणà¥à¤¯à¤¾à¤¸ अपयशी: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "फाइलची अयोगà¥à¤¯ समापà¥à¤¤à¥€\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "फाइलची अयोगà¥à¤¯ समापà¥à¤¤à¥€"
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "अवैध सरà¥à¤µà¤°"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT पà¥à¤°à¤¾à¤ªà¥à¤¤ à¤à¤¾à¤²à¥‡, बाहेर पडत आहे."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2051,13 +2105,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2073,13 +2136,21 @@ msgstr ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2089,7 +2160,7 @@ msgstr ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2100,78 +2171,108 @@ msgstr ""
"libpulse %s सह कंपाईल केले\n"
"libpulse %s सह जà¥à¤³à¤²à¥‡\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "कृपया दाखल करणà¥à¤¯à¤¾à¤œà¥‹à¤—ी तातà¥à¤ªà¥‚रà¥à¤¤à¥€ फाइल निशà¥à¤šà¤¿à¤¤ करा\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "कृपया दाखल करणà¥à¤¯à¤¾à¤œà¥‹à¤—ी तातà¥à¤ªà¥‚रà¥à¤¤à¥€ फाइल निरà¥à¤¦à¥‡à¤¶à¥€à¤¤ करा"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "आवाज फाइल उघडणà¥à¤¯à¤¾à¤¸ अपयशी.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "आवाज फाइल उघडणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "चालविणà¥à¤¯à¤¾à¤•रीता तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ तातà¥à¤ªà¥‚रà¥à¤¤à¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "सावधानता: फाइलपासून चाचणी संयोजना ओळखणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "काढूण टाकणà¥à¤¯à¤¾à¤•रीता तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ तातà¥à¤ªà¥‚रà¥à¤¤à¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "चालवणà¥à¤¯à¤¾à¤•रीता तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ तातà¥à¤ªà¥‚रà¥à¤¤à¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सिंक इनपà¥à¤Ÿ निरà¥à¤¦à¥‡à¤¶à¤¾à¤‚क व सिंक निशà¥à¤šà¤¿à¤¤ करावे लागेल\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "काढून टाकणà¥à¤¯à¤¾à¤•रीता तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ तातà¥à¤ªà¥‚रà¥à¤¤à¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ आऊट इनडेकà¥à¤¸ सà¥à¤¤à¥à¤°à¥‹à¤¤ व सà¥à¤¤à¥à¤°à¥‹à¤¤ निशà¥à¤šà¤¿à¤¤ करावे लागेल\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सींक इंपà¥à¤Ÿ निरà¥à¤¦à¥‡à¤¶à¤¾à¤‚क व सींक निशà¥à¤šà¤¿à¤¤ करावे लागेल"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ विभागाचे नाव व बाब निशà¥à¤šà¤¿à¤¤ करावे लागेल.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ आऊटपà¥à¤Ÿ इंडेकà¥à¤¸ सà¥à¤°à¥‹à¤¤ व सà¥à¤°à¥‹à¤¤ निशà¥à¤šà¤¿à¤¤ करावे लागेल"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ विभाग निरà¥à¤¦à¥‡à¤¶à¤¾à¤‚क निशà¥à¤šà¤¿à¤¤ करावे लागेल\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ विभागाचे नाव व बाब निशà¥à¤šà¤¿à¤¤ करावे लागेल."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ विभाग इंडेकà¥à¤¸à¥ निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"तà¥à¤®à¥à¤¹à¥€ à¤à¤•ापेकà¥à¤·à¤¾ जासà¥à¤¤ सिंक निशà¥à¤šà¤¿à¤¤ करू शकत नाही. तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ बूलीयन मूलà¥à¤¯ निशà¥à¤šà¤¿à¤¤ करावे "
-"लागेल.\n"
+"तà¥à¤®à¥à¤¹à¥€ à¤à¤•ापेकà¥à¤·à¤¾ जासà¥à¤¤ सींक निशà¥à¤šà¤¿à¤¤ करू शकत नाही. तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ बूलीयन मूलà¥à¤¯ निशà¥à¤šà¤¿à¤¤ करावे लागेल."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"तà¥à¤®à¥à¤¹à¥€ à¤à¤•ापेकà¥à¤·à¤¾ जासà¥à¤¤ सà¥à¤¤à¥à¤°à¥‹à¤¤ निशà¥à¤šà¤¿à¤¤ करू शकत नाही. तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ बूलीयन मूलà¥à¤¯ निशà¥à¤šà¤¿à¤¤ करावे "
-"लागेल.\n"
+"तà¥à¤®à¥à¤¹à¥€ à¤à¤•ापेकà¥à¤·à¤¾ जासà¥à¤¤ सà¥à¤°à¥‹à¤¤ निशà¥à¤šà¤¿à¤¤ करू शकत नाही. तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ बूलीयन मूलà¥à¤¯ निशà¥à¤šà¤¿à¤¤ करावे लागेल."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ कारà¥à¤¡ नाव/निरà¥à¤¦à¥‡à¤¶à¤¾à¤‚क व संकà¥à¤·à¤¿à¤ªà¥à¤¤ नाव निशà¥à¤šà¤¿à¤¤ करावे\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ कारà¥à¤¡à¤šà¥‡ नाव/इंडेकà¥à¤¸à¥ व पà¥à¤°à¥‹à¤«à¤¾à¤‡à¤² नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "वैध आदेश निशà¥à¤šà¤¿à¤¤ केले नाही.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सींक नाव/इंडेकà¥à¤¸à¥ व पोरà¥à¤Ÿà¤šà¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() अपयशी: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सà¥à¤°à¥‹à¤¤ नाव/इंडेकà¥à¤¸à¥ व पोरà¥à¤Ÿà¤šà¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सींक नाव/इंडेकà¥à¤¸à¥ व पोरà¥à¤Ÿà¤šà¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "अवैध खंडाची संयोजना"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सà¥à¤°à¥‹à¤¤ नाव/इंडेकà¥à¤¸à¥ व खंडाचे नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सींक इंपà¥à¤Ÿ इंडेकà¥à¤¸à¥ व सींक निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "अवैध सींक इंपà¥à¤Ÿ इंडेकà¥à¤¸à¥"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सींक नाव/इंडेकà¥à¤¸à¥ व पोरà¥à¤Ÿà¤šà¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सà¥à¤°à¥‹à¤¤ नाव/इंडेकà¥à¤¸à¥ व पोरà¥à¤Ÿà¤šà¥‡ नाव निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "तà¥à¤®à¥à¤¹à¤¾à¤²à¤¾ सींक इंपà¥à¤Ÿ निरà¥à¤¦à¥‡à¤¶à¤¾à¤‚क व सींक निशà¥à¤šà¤¿à¤¤ करावे लागेल"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "अवैध सींक इंपà¥à¤Ÿ इंडेकà¥à¤¸à¥ संयोजना"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "वैध आदेश निशà¥à¤šà¤¿à¤¤ केले नाही."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2205,12 +2306,12 @@ msgstr "सरà¥à¤µà¤°: %s\n"
#: ../src/utils/pax11publish.c:110
#, c-format
msgid "Source: %s\n"
-msgstr "सà¥à¤¤à¥à¤°à¥‹à¤¤: %s\n"
+msgstr "सà¥à¤°à¥‹à¤¤: %s\n"
#: ../src/utils/pax11publish.c:112
#, c-format
msgid "Sink: %s\n"
-msgstr "सिंक: %s\n"
+msgstr "सींक: %s\n"
#: ../src/utils/pax11publish.c:114
#, c-format
@@ -2252,129 +2353,48 @@ msgstr "कà¥à¤•ी डेटा दाखल करणà¥à¤¯à¤¾à¤¸ अपयà¤
msgid "Not yet implemented.\n"
msgstr "अजूनही लागू केले नाही.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "PulseAudio डिमन कारà¥à¤¯à¤°à¤¤ नाही, किंवा सतà¥à¤° डिमन नà¥à¤°à¥‚प कारà¥à¤¯à¤°à¤¤ नाही."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio डिमन पूरà¥à¤£à¤ªà¤£à¥‡ नषà¥à¤Ÿ करणà¥à¤¯à¤¾à¤¸ अपयशी."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "डिमन पà¥à¤°à¤¤à¤¿à¤¸à¤¾à¤¦ देत नाही."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® यशसà¥à¤µà¥€à¤°à¤¿à¤¤à¥à¤¯à¤¾ बनवले\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "सà¥à¤Ÿà¥à¤°à¥€à¤® तà¥à¤°à¥à¤Ÿà¥€: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "जà¥à¤³à¤µà¤£à¥€ सà¥à¤¥à¤¾à¤ªà¥€à¤¤.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"%s शी कंपाई केले\n"
-"libpulse %s शी जà¥à¤³à¤²à¥‡\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "अवैध वाहिनी नकाशा\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "फाइल '%s' उघडणà¥à¤¯à¤¾à¤¸ अपयशी\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "वाहिनी नकाशा फाइलशी जà¥à¤³à¤¤ नाही.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "तातà¥à¤ªà¥‚रà¥à¤¤à¥‡ spec '%s' वापरत आहे\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "autospawn कà¥à¤²à¥‚प करीता पà¥à¤°à¤µà¥‡à¤¶ पà¥à¤°à¤¾à¤ªà¥à¤¯ अशकà¥à¤¯."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2389,7 +2409,7 @@ msgstr ""
"POLLOUT दà¥à¤µà¤¾à¤°à¥‡ सजà¥à¤œ होणे शकà¥à¤¯ आहे -- तरी परसà¥à¤ªà¤° snd_pcm_avail() ने 0 पूरविले किंवा इतर "
"मूलà¥à¤¯ < min_avail असावे."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2404,34 +2424,259 @@ msgstr ""
"POLLIN दà¥à¤µà¤¾à¤°à¥‡ सजà¥à¤œ होणे शकà¥à¤¯ आहे -- तरी परसà¥à¤ªà¤° snd_pcm_avail() ने 0 पूरविले किंवा इतर "
"मूलà¥à¤¯ < min_avail असावे."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "आऊटपà¥à¤Ÿ %s + इनपà¥à¤Ÿ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "आऊटपà¥à¤Ÿ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "इनपà¥à¤Ÿ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "बंद करा"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr "High Fidelity Playback (A2DP)"
+msgstr "हाय फिडेलिटी पà¥à¤²à¥‡à¤¬à¥…क (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "हाय फिडीलीटी कॅपचर (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
-msgstr "Telephony Duplex (HSP/HFP)"
+msgstr "टेलिफोनी डà¥à¤¯à¥à¤ªà¥à¤²à¥‡à¤•à¥à¤¸à¥ (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio आवाज सरà¥à¤µà¤°"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "आऊट साधणे"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "इंपà¥à¤Ÿ साधणे"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ वरील ऑडिओ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "इंपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "डॉकिंग सà¥à¤Ÿà¥‡à¤¶à¤¨ इंपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "डॉकिंग सà¥à¤Ÿà¥‡à¤¶à¤¨ माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "लाइन-इन"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "बाहेरील माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "आंतरीक माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "रेडिओ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "विडिओ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "सà¥à¤µà¤¯à¤‚ गैन कंटà¥à¤°à¥‹à¤²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "सà¥à¤µà¤¯à¤‚ गैन कंटà¥à¤°à¥‹à¤² अशकà¥à¤¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "बूसà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "बूसà¥à¤Ÿ अशकà¥à¤¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "à¤à¤®à¤ªà¥à¤²à¤¿à¤«à¤¾à¤¯à¤°"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "à¤à¤®à¤ªà¥à¤²à¤¿à¤«à¤¾à¤¯à¤° अशकà¥à¤¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "बूसà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "बूसà¥à¤Ÿ अशकà¥à¤¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "à¤à¤¨à¤²à¥‰à¤— हेडफोनà¥à¤¸à¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "à¤à¤¨à¤²à¥‰à¤— इंपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "à¤à¤¨à¤²à¥‰à¤— माइकà¥à¤°à¥‹à¤«à¥‹à¤¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "à¤à¤¨à¤²à¥‰à¤— लाइन-इन"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "à¤à¤¨à¤²à¥‰à¤— रेडिओ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "à¤à¤¨à¤²à¥‰à¤— विडीओ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "à¤à¤¨à¤²à¥‰à¤— आऊटपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "à¤à¤¨à¤²à¥‰à¤— हेडफोनà¥à¤¸à¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "à¤à¤¨à¤²à¥‰à¤— आऊटपà¥à¤Ÿ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "à¤à¤¨à¤²à¥‰à¤— मोनो आऊटपà¥à¤Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सà¥à¤Ÿà¤¿à¤°à¥€à¤“"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "à¤à¤¨à¤²à¥‰à¤— मोनो"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सà¥à¤Ÿà¤¿à¤°à¥€à¤“"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सरà¥à¤°à¤¾à¤‰à¤‚ड 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "डिजीटल सà¥à¤Ÿà¤¿à¤°à¥€à¤“ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "डिजीटल सरà¥à¤°à¤¾à¤‰à¤‚ड 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "डिजीटल सरà¥à¤°à¤¾à¤‰à¤‚ड 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "डिजीटल सरà¥à¤°à¤¾à¤‰à¤‚ड 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "डिजीटल सà¥à¤Ÿà¤¿à¤°à¥€à¤“ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "à¤à¤¨à¤²à¥‰à¤— मोनो डà¥à¤¯à¥à¤ªà¥à¤²à¥‡à¤•à¥à¤¸à¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "à¤à¤¨à¤²à¥‰à¤— सà¥à¤Ÿà¤¿à¤°à¥€à¤“ डà¥à¤¯à¥à¤ªà¥à¤²à¥‡à¤•à¥à¤¸à¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "डिजीटल सà¥à¤Ÿà¤¿à¤°à¥€à¤“ डà¥à¤¯à¥à¤ªà¥à¤²à¥‡à¤•à¥à¤¸à¥ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "कमी कà¥à¤°à¤¿à¤•à¥à¤µà¥‡à¤¨à¥à¤¸à¥€ सà¥à¤°à¥‹à¤¤"
diff --git a/po/nl.po b/po/nl.po
index 4b086a1c..bb44e546 100644
--- a/po/nl.po
+++ b/po/nl.po
@@ -2,66 +2,27 @@
# Copyright (C) 2009 THE pulseaudio.master-tx'S COPYRIGHT HOLDER
# This file is distributed under the same license as the pulseaudio.master-tx package.
# Geert Warrink <geert.warrink@onsnet.nu>, 2009.
-# , fuzzy
+# Reinout van Schouwen <reinout@gmail.com>, 2009
#
#
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio.master-tx\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-15 21:04+0200\n"
-"Last-Translator: Geert Warrink <geert.warrink@onsnet.nu>\n"
-"Language-Team: Dutch <nl@li.org>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-14 11:00+0100\n"
+"Last-Translator: Reinout van Schouwen <reinout@gmail.com>\n"
+"Language-Team: Dutch <vertaling@vrijschrift.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
+"Content-Transfer-Encoding: \n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analoog mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analoog stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Digitaal stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Digitaal stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analoog surround 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digitaal surround 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analoog surround 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analoog surround 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analoog surround 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digitaal surround 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analoog surround 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -71,10 +32,10 @@ msgid ""
msgstr ""
"snd_pcm_avail() gaf een waarde terug die uitzonderlijk groot is: %lu bytes (%"
"lu ms).\n"
-"Waarschijnlijk is dit een bug in de ALSA driver '%s'. Rapporteer dit "
-"probleem a.u.b. aan de ALSA ontwikkelaars."
+"Waarschijnlijk is dit een fout in het ALSA-stuurprogramma ‘%s’. Meld dit "
+"probleem alstublieft aan de ALSA-ontwikkelaars."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -84,10 +45,10 @@ msgid ""
msgstr ""
"snd_pcm_delay() gaf een waarde terug die uitzonderlijk groot is: %li bytes (%"
"s%lu ms).\n"
-"Waarschijnlijk is dit een bug in de ALSA driver '%s'. Rapporteer dit "
-"probleem a.u.b. aan de ALSA ontwikkelaars."
+"Waarschijnlijk is dit een fout in het ALSA-stuurprogramma ‘%s’. Meld dit "
+"probleem alstublieft aan de ALSA-ontwikkelaars."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -97,14 +58,49 @@ msgid ""
msgstr ""
"snd_pcm_mmap_begin() gaf een waarde terug die uitzonderlijk groot is: %lu "
"bytes (%lu ms).\n"
-"Waarschijnlijk is dit een bug in de ALSA driver '%s'. Rapporteer dit "
-"probleem a.u.b aan de ALSA ontwikkelaars."
+"Waarschijnlijk is dit een fout in het ALSA-stuurprogramma ‘%s’. Meld dit "
+"probleem alstublieft aan de ALSA-ontwikkelaars."
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+"Houdt altijd ten minste een afvoer ingeladen zelfs als het de null-afvoer is."
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Dummy-uitvoer"
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Virtuele LADSPA afvoer"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<naam voor de afvoer> sink_properties=<eigenschappen van de "
+"afvoer> master=<naam van de te filteren afvoer> format=<sampleformaat> "
+"rate=<sample snelheid> channels=<aantal kanalen> channel_map=<kanaalkaart> "
+"plugin=<ladspa pluginnaam> label=<ladspa pluginlabel> "
+"control=<kommagescheiden lijst van invoercontrolewaarden>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Geklokte NULL afvoer"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null-uitvoer"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Intern geluid"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Modem"
@@ -120,220 +116,98 @@ msgstr "Kon die nieuwe dl lader niet toekennen."
msgid "Failed to add bind-now-loader."
msgstr "Kon bind-now-loader niet toevoegen."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Kan niet verbinden met systeem bus: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Kan geen bezoeker krijgen van PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Kan UID niet instellen op caller object."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Kon geen CK sessie krijgen."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Kan UID niet instellen op sessie object."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Kan PolKitAction niet toekennen."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Kan action_id niet instellen"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Kan PolKitContext niet toekennen."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Kan PolKitContext niet intialiseren: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Kon niet bepalen of bezoeker gemachtigd is: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Kan geen authorisatie krijgen: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit antwoordde met '%s'"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
-msgstr "Ontving signaal %s."
+msgstr "Signaal %s ontvangen."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Afsluiten."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Kon gebruiker '%s' niet vinden."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
-msgstr "Kon groep '%s' niet vinden."
+msgstr "Kon groep ‘%s’ niet vinden."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
-msgstr "Gebruiker '%s' (UID %lu) en groep '%s' (GID %lu) gevonden."
+msgstr "Gebruiker ‘%s’ (UID %lu) en groep ‘%s’ (GID %lu) gevonden."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
-msgstr "GID van gebruiker '%s' en van groep '%s' passen niet bij elkaar."
+msgstr "GID van gebruiker ‘%s’ en van groep ‘%s’ passen niet bij elkaar."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
-msgstr "Persoonlijke map van gebruiker '%s' is niet '%s', negeer het."
+msgstr "Persoonlijke map van gebruiker ‘%s’ is niet ‘%s’, negeer het."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
-msgstr "Aanmaken van '%s': %s mislukte"
+msgstr "Aanmaken van ‘%s’ mislukt: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
-msgstr "Veranderen van groeps lijst: '%s' mislukte"
+msgstr "Veranderen van groepslijst mislukt: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
-msgstr "Veranderen van GID: %s mislukte"
+msgstr "Veranderen van GID mislukt: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
-msgstr "Veranderen van UID: %s mislukte"
+msgstr "Veranderen van UID mislukt: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
-msgstr "Root rechten met succes laten vervallen."
+msgstr "Beheerdersrechten met succes laten vervallen."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
-msgstr "Systeem brede mode wordt op dit platform niet ondersteund."
+msgstr "Systeembrede modus wordt op dit platform niet ondersteund."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) mislukte: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
-msgstr "Analyseren van de commandoregel mislukte."
-
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "Wij zijn in de groep '%s', wat plannen met hoge prioriteit toestaat."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "Wij zijn in de groep '%s', war real-time planning toestaat."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit kent ons acquire-high-priority rechten toe."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit weigert ons acquire-high-priority rechten."
+msgstr "Analyseren van de opdrachtregel mislukte."
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit kent ons acquire-real-time rechten toe."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit weigert ons acquire-real-time rechten."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"Aangeroepen met SUID root en real-time en/of high-priority inplannen was "
-"verzocht in de configuratie. Echter de nodige rechten ontbreken:\n"
-"We zijn niet in groep '%s', PolicyKit weigert om ons de gevraagde rechten te "
-"geven en we hebben geen rect om de RLIMIT_NICE/RLIMIT_RTPRIO limieten te "
-"verhogen.\n"
-"Voor het aanzetten van real-time/high-priority inplannen mort je juiste "
-"PolicyKit privileges hebben, of lid van '%s\" worden, of de RLIMIT_NICE/"
-"RLIMIT_RTPRIO limieten voor deze gebruiker verhogen."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Hoge prioriteit inplannen is aangezet in de configuratie maar niet "
-"toegestaan door de richtlijnen."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO met succes verhoogd"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO mislukte: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Opgeven CAP_NICE"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"Real-time inplannen is aangezet in de configuratie maar niet toegestaan door "
-"de richtlijnen."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
-msgstr "Daemon draait niet"
+msgstr "Voorziening draait niet"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
-msgstr "Daemon draait met PID %u"
+msgstr "Voorziening draait met PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
-msgstr "Afschieten mislukt van daemon: '%s'"
+msgstr "Elimineren van voorziening mislukt: ‘%s’"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -341,159 +215,195 @@ msgstr ""
"Dit programma is niet bedoeld om als root gedraaid te worden (behalve als --"
"system is opgegeven)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
-msgstr "Root rechten vereisd"
+msgstr "Beheerdersrechten vereist."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
-msgstr "--start wordt niet ondersteund voor systeem instances"
+msgstr "--start wordt niet ondersteund voor systeeminstanties"
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
-msgstr "Draaiend in systeem mode, maar --disallow-exit is niet gezet!"
+msgstr "Draaiend in systeemmodus, maar --disallow-exit is niet ingesteld!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
-"Draaiend in systeem mode, maar --disallow-module-loading is niet gezet!"
+"Draaiend in systeemmodus, maar --disallow-module-loading is niet gezet!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
-msgstr "Draaiend in systeem mode, geforceerd uitzetten van SHM mode!"
+msgstr "Draaiend in systeemmodus, geforceerd uitzetten van SHM-modus!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
-msgstr "Draaiend in systeem mode, geforceerd uitzetten van exit idle time!"
+msgstr "Draaiend in systeemmodus, geforceerd uitzetten van exit idle time!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Verkrijgen van stdio mislukte."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "pipe mislukte: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() mislukte: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() mislukte: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
-msgstr "Daemon opstarten mislukte."
+msgstr "Voorziening opstarten mislukt."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
-msgstr "Daemon met succes opgestart."
+msgstr "Voorziening met succes opgestart."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() mislukte: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Dit is PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
-msgstr "Compilatie host: %s"
+msgstr "Compilatiehost: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
-msgstr "Compilatie CFLAGS: %s"
+msgstr "Compilatie-CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Draaiend op host: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPU's gevonden."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "Pagina grootte is %lu bytes"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Gecompileerd met Valgrind ondersteuning: ja"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Gecompileerd met Valgrind ondersteuning: nee"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
-msgstr "Draaiend in valgrind mode: %s"
+msgstr "Draaiend in valgrind-modus: %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Draaiend op host: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
-msgstr "Optimaal gebouwd: ja"
+msgstr "Geoptimaliseerd gebouwd: ja"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
-msgstr "Optimaak gebouwd: nee"
+msgstr "Geoptimaliseerd gebouwd: nee"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr "NDEBUG gedefinieerd, alle verklaringen uitgezet."
+msgstr "NDEBUG gedefinieerd, alle asserts uitgezet."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
-msgstr "FASTPATH gedefinieerd, alleen snel pad verklaringen uitgezet."
+msgstr "FASTPATH gedefinieerd, alleen fast path-asserts uitgezet."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr "Alle verklaringen aangezet."
+msgstr "Alle asserts aangezet."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
-msgstr "Machine ID verkrijgen mislukte"
+msgstr "Machine-ID verkrijgen mislukt"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
-msgstr "Machine ID is: %s."
+msgstr "Machine-ID is: %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "Machine ID is: %s."
+msgstr "Sessie-ID is: %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
-msgstr "Gebruik van runtime map %s."
+msgstr "Gebruik van runtime-map %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
-msgstr "Verbruik van state map %s."
+msgstr "Verbruik van state-map %s."
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Gebruik van module-map %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
-msgstr "Draaiend in systeem mode: %s"
+msgstr "Draaiend in systeemmodus: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"OK, dus u draait PA in systeemmodus. Merk op dat u dit waarschijnlijk beter "
+"niet kunt doen.\n"
+"Als u het toch doet dan is het uw eigen schuld als dingen niet werken zoals "
+"verwacht.\n"
+"Lees http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode voor een uitleg "
+"waarom systeemmodus gewoonlijk een slecht idee is."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() mislukte."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Verse high-resolution timers beschikbaar! Smakelijk eten!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -501,31 +411,31 @@ msgstr ""
"Kerel, je kernel stinkt! De aanbeveling van de chef is vandaag Linux met "
"aangezette high-resolution timers!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() mislukte."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
-msgstr "Initialiseren van de daemon mislukte."
+msgstr "Initialiseren van de voorziening mislukt."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
-msgstr "Daemon opgestart zonder geladen modules, dat werkt niet."
+msgstr "Voorziening opgestart zonder geladen modules, dat werkt niet."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
-msgstr "Daemon opstarten is klaar."
+msgstr "Voorziening opstarten is klaar."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
-msgstr "Daemon afsluiten is begonnen."
+msgstr "Voorziening afsluiten is begonnen."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
-msgstr "Daemon is afgesloten."
+msgstr "Voorziening is afgesloten."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -671,22 +581,22 @@ msgstr ""
"met\n"
" de opgegeven argumenten\n"
" -F, --file=FILENAME Draai het opgegeven script\n"
-" -C Open een commandoregel op de "
+" -C Open een opdrachtregel op de "
"draaiende TTY\n"
" na het opstarten\n"
"\n"
" -n Laad het standaard script bestand "
"niet\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -694,52 +604,52 @@ msgstr ""
"--log-level verwacht een log level argument (numeriek uit de reeks 0..4 of "
"een van type debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit verwacht een bolean argument"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "Ongeldig log doel: gebruik een van 'syslog', 'stderr', 'auto'."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Ongeldige resample methode '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit verwacht een boolean argument"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm verwacht een boolean argument"
@@ -778,352 +688,342 @@ msgstr "Gebruik: %s\n"
msgid "Load Once: %s\n"
msgstr "Laad eenmaal: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "ACHTERHAALDHEIDSWAARSCHUWING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Pad: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldig logdoel '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldig logniveau '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldige resample-methode ‘%s’."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldige rlimit ‘%s’."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
-msgstr ""
+msgstr "[%s:%u] rlimit wordt niet ondersteund op dit platform."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldig sampleformaat ‘%s’."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldige samlperate ‘%s’."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldige sample-kanalen ‘%s’."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldige kanalenkaart ‘%s’."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldig aantal fragmenten '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldige fragmentgrootte ‘%s’."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
-msgstr ""
+msgstr "[%s:%u] Ongeldig nice niveau ‘%s’."
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Ongeldige samlperate ‘%s’."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
-msgstr ""
+msgstr "Openen van configuratiebestand %s mislukt."
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr ""
+"De opgegeven standaard kanalenkaart heeft een ander aantal kanalen dan de "
+"opgegeven standaard aantal kanalen."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
-msgstr ""
-
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr ""
+msgstr "### Lees uit het configuratiebestand: %s ###\n"
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr ""
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Rechten opschonen."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
-msgstr ""
+msgstr "PulseAudio geluidssysteem"
#: ../src/daemon/pulseaudio.desktop.in.h:2
msgid "Start the PulseAudio Sound System"
-msgstr ""
+msgstr "Start het PulseAudio geluidssysteem"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Voor midden"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Voor links"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Voor rechts"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Achter midden"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Achter links"
-#: ../src/pulse/channelmap.c:111
-msgid "Rear Right"
-msgstr "Achter rechta"
-
#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Lage frequentie zender"
+msgid "Rear Right"
+msgstr "Achter rechts"
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Voor links-van-het-midden"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Voor rechts-van-het-midden"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Zijkant links"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Zijkant rechts"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Auxiliary 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Auxiliary 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Auxiliary 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Auxiliary 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Auxiliary 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Auxiliary 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Auxiliary 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Auxiliary 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Auxiliary 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Auxiliary 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Auxiliary 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Auxiliary 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Auxiliary 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Auxiliary 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Auxiliary 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Auxiliary· 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Auxiliary 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Auxiliary 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Auxiliary 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Auxiliary 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Auxiliary 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Auxiliary 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Auxiliary 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Auxiliary 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Auxiliary 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Auxiliary 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Auxiliary 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Auxiliary 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Auxiliary 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Auxiliary 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Auxiliary 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Auxiliary 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Boven midden"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Boven voor midden"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Boven voor links"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Boven voor rechts"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Boven achter midden"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "boven achter links"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "boven achter rechts"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(ongeldig)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Surround 7.1"
@@ -1149,15 +1049,15 @@ msgstr "Eenheid bestaat"
#: ../src/pulse/error.c:48
msgid "No such entity"
-msgstr "Eenheid onbekent"
+msgstr "Eenheid onbekend"
#: ../src/pulse/error.c:49
msgid "Connection refused"
-msgstr "Verbinding geweigert"
+msgstr "Verbinding geweigerd"
#: ../src/pulse/error.c:50
msgid "Protocol error"
-msgstr "Protocol fout"
+msgstr "Protocolfout"
#: ../src/pulse/error.c:51
msgid "Timeout"
@@ -1165,7 +1065,7 @@ msgstr "Tijd verstreken"
#: ../src/pulse/error.c:52
msgid "No authorization key"
-msgstr "Geen authorisatie sleutel"
+msgstr "Geen autorisatiesleutel"
#: ../src/pulse/error.c:53
msgid "Internal error"
@@ -1177,7 +1077,7 @@ msgstr "Verbinding verbroken"
#: ../src/pulse/error.c:55
msgid "Entity killed"
-msgstr "Eenheid afgeschoten"
+msgstr "Eenheid geëlimineerd"
#: ../src/pulse/error.c:56
msgid "Invalid server"
@@ -1185,7 +1085,7 @@ msgstr "Ongeldige server"
#: ../src/pulse/error.c:57
msgid "Module initalization failed"
-msgstr "Module initialisatie mislukte"
+msgstr "Module-initialisatie mislukt"
#: ../src/pulse/error.c:58
msgid "Bad state"
@@ -1227,230 +1127,232 @@ msgstr "Implementatie ontbreekt"
msgid "Client forked"
msgstr "Client afgesplitst"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Input/Output fout"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Apparaat of hulpbron is bezig"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
msgid "XOpenDisplay() failed"
-msgstr ""
+msgstr "XOpenDisplay() mislukte"
#: ../src/pulse/client-conf-x11.c:93
msgid "Failed to parse cookie data"
-msgstr ""
+msgstr "Analyseren van cookie-data mislukt"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
-msgstr ""
+msgstr "Open van configuratiebestand ‘%s’ mislukte: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
-msgstr ""
+msgstr "Geen cookie geladen. Probeer zonder cookie te verbinden."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
-msgstr ""
+msgstr "Ontving boodschap voor onbekende extensie ‘%s’"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr ""
+msgid "Failed to drain stream: %s"
+msgstr "Afvoeren stroom %s mislukte"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr ""
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Afspelen van afgevoerde stroom."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr ""
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Vervinding naar server afvoeren."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr ""
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr ""
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() mislukte: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr ""
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() mislukte: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr ""
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() mislukte: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr ""
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Stroom met succes aangemaakt."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr ""
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() mislukte: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr ""
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Buffermetriek: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr ""
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Buffermetriek: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr ""
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Gebruik sample-spec '%s', kanaal map '%s'."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr ""
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Verbonden met apparaat %s (%u, %sopgeschort)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr ""
+msgid "Stream error: %s"
+msgstr "Stroomfout: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr ""
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr ""
+msgid "Stream device suspended.%s"
+msgstr "Stroomapparaat opgeschort.%s"
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr ""
+msgid "Stream device resumed.%s"
+msgstr "Stroomapparaat hervat.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr ""
+msgid "Stream underrun.%s"
+msgstr "Te weinig data voor stroom.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr ""
+msgid "Stream overrun.%s"
+msgstr "Data-overschrijding voor stroom.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr ""
+msgid "Stream started.%s"
+msgstr "Stroom gestart.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr ""
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Stroom verplaatst naar apparaat %s (%u, %sopgeschort).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr ""
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "niet "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr ""
+msgid "Stream buffer attributes changed.%s"
+msgstr "Stroom buffer attributen veranderden.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr ""
+msgid "Connection established.%s"
+msgstr "Verbinding bereikt.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr ""
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() mislukte: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr ""
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() mislukte: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr ""
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() mislukte: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr ""
+msgid "Connection failure: %s"
+msgstr "Verbindingsfout: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr ""
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Kreeg EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr ""
+msgid "write() failed: %s"
+msgstr "write() mislukte: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr ""
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Ontving signaal, afsluiten."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr ""
+msgid "Failed to get latency: %s"
+msgstr "Latentie krijgen mislukte: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr ""
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Tijd: %0.3f sec; Latentie: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() mislukte: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1476,8 +1378,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1500,139 +1404,252 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
-
-#: ../src/utils/pacat.c:612
+"%s [opties]\n"
+"\n"
+" -h, --help Laat deze hulp zien\n"
+" --version Laat versie zien\n"
+"\n"
+" -r, --record Maak een verbinding voor opnemen\n"
+" -p, --playback Maak een verbinding voor afspelen\n"
+"\n"
+" -v, --verbose Zet breedsprakigheid aan\n"
+"\n"
+" -s, --server=SERVER De naam van de server waarmee "
+"verbonden moet worden\n"
+" -d, --device=DEVICE De naam van de afvoer/bron waarmee "
+"verbonden moet worden\n"
+" -n, --client-name=NAME Hoe wordt deze cliënt op de server "
+"genoemd\n"
+" --stream-name=NAME Hoe wordt deze stroom op de server "
+"genoemd\n"
+" --volume=VOLUME Geef het begins (lineare) volume in "
+"reeks 0...65536\n"
+" --rate=SAMPLERATE De samplerate in Hz (standaard "
+"44100)\n"
+" --format=SAMPLEFORMAT Het sampletype, een van s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (standaard "
+"s16ne)\n"
+" --channels=CHANNELS Het aantal kanalen, 1 voor mono, 2 "
+"voor stereo\n"
+" (standaard 2)\n"
+" --channel-map=CHANNELMAP Kanaalkaart te gebruiken in plaats "
+"van de standaard\n"
+" --fix-format Neem het sampleformaat over van de "
+"afvoer waar de stroom\n"
+" mee verbonden is.\n"
+" --fix-rate Neem de samplerate over van de "
+"afvoer waar de stroom\n"
+" mee verbonden is.\n"
+" --fix-channels Neem het aantal kanalen en de kanaal "
+"map over\n"
+" van de afvoer waar de stroom mee "
+"verbonden is.\n"
+" --no-remix Doe geen upmix of downmix van "
+"kanalen.\n"
+" --no-remap Map kanalen met index in plaats van "
+"met naam.\n"
+" --latency=BYTES Verzoek de opgegeven latentie in "
+"bytes.\n"
+" --process-time=BYTES Verzoek de opgegeven proces tijd per "
+"verzoek in bytes.\n"
+" --property=PROPERTY=VALUE Zet de opgegeven eigenschap op de "
+"opgegeven waarde.\n"
+" --raw Opnemen/afspelen van ruwe PCM data.\n"
+" --file-format=FFORMAT Opnemen/afspelen van geformateerde "
+"data.\n"
+" --list-file-formats Laat beschikbare bestandsformaten "
+"zien.\n"
+
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
msgstr ""
+"pacat %s\n"
+"Gecompileerd met libpulse %s\n"
+"Gelinkt met libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr ""
+msgid "Invalid client name '%s'"
+msgstr "Ongeldige clientnaam ‘%s’."
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr ""
+msgid "Invalid stream name '%s'"
+msgstr "Ongeldige stroomnaam ‘%s’."
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr ""
+msgid "Invalid channel map '%s'"
+msgstr "Ongeldige kanaalkaart ‘%s’."
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr ""
+msgid "Invalid latency specification '%s'"
+msgstr "Ongeldige latentie-specificatie ‘%s’."
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr ""
+msgid "Invalid process time specification '%s'"
+msgstr "Ongeldige procestijdspecificatie ‘%s’."
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr ""
+msgid "Invalid property '%s'"
+msgstr "Ongeldige eigenschap ‘%s’."
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr ""
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Ongeldig bestandsformaat %s"
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr ""
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Ongeldige samplespecificatie"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr ""
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr ""
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr ""
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Te veel argumenten."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr ""
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Aanmaken van samplespecificatie voor bestand mislukt."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr ""
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Openen van geluidsbestand mislukte."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
msgstr ""
+"Waarschuwing: opgegeven bemonster specificatie zal overschreven worden met "
+"de specificatie van het bestand."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_core_new() mislukte."
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Bepalen van samplespecificatie van het bestand mislukte."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Waarschuwing: Bepalen van kanaalkaart van bestand mislukte."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Kanaal map komt niet overeen met bemonster specificatie."
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Waarschuwing: schrijven van kanaalkaart naar bestand mislukte."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
msgstr ""
+"Openen van een %s stroom met samplespecificatie ‘%s’ en kanaalkaart ‘%s’."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "opnemen"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "afspelen"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() mislukte."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() mislukte."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_cotext_new() mislukte."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr ""
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() mislukte: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() mislukte."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() mislukte."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
-msgstr ""
+msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
-msgstr ""
+msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
-msgstr ""
+msgstr "Opschorten mislukte: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
-msgstr ""
+msgstr "Vervolgen mislukte: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
-msgstr ""
+msgstr "WAARSCHUWING: Geluidsserver is niet lokaal, geen opschorten.\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Verbonding mislukte: %s\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
-msgstr ""
+msgstr "Kreeg SIGINT, verlaten.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
-msgstr ""
+msgstr "WAARSCHUWING: kind proces afgesloten door signaal %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1643,44 +1660,82 @@ msgid ""
"to\n"
"\n"
msgstr ""
+"%s [opties] ... \n"
+"\n"
+" -h, --help Laat deze hulp zien\n"
+" --version Laat versie zien\n"
+" -s, --server=SERVER De naam van de server waarmee "
+"verbonden wordt\n"
+"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
msgstr ""
+"pasuspender %s\n"
+"Gecompileerd met libpulse %s\n"
+"Gelinkt met libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr ""
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() mislukte.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() mislukte.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() mislukte.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Verkrijgen van statistiek %s mislukte"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
-msgstr ""
+msgstr "Op dit moment in gebruik: %u blokken bevattende in totaal %s bytes.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
+"Toegewezen tijdens de gehele levensduur: %u blokken bevattende in totaal %s "
+"butes.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
-msgstr ""
+msgstr "Sample-buffergrootte: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr ""
+msgid "Failed to get server information: %s"
+msgstr "Server informatie verkrijgen mislukte: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1688,15 +1743,24 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+"Gebruikersnaam: %s\n"
+"Hostnaam: %s\n"
+"Servernaam: %s\n"
+"Serverversie: %s\n"
+"Standaard samplespecificatie: %s\n"
+"Standaard kanaal map: %s\n"
+"Standaard afvoer: %s\n"
+"Standaard bron: %s\n"
"Cookie: %08x\n"
-msgstr ""
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr ""
+msgid "Failed to get sink information: %s"
+msgstr "Verkrijgen afvoerinformatie mislukte: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1717,13 +1781,40 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Afvoer #%u\n"
+"\tToestand: %s\n"
+"\tNaam: %s\n"
+"\tBeschrijving: %s\n"
+"\tDriver: %s\n"
+"\tBemonsterings specificatie: %s\n"
+"\tKanaal map: %s\n"
+"\tModule eigenaar: %u\n"
+"\tDemping: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balans %0.2f\n"
+"\tBasis volume: %s%s%s\n"
+"\tMonitor bron: %s\n"
+"\tLatentie: %0.0f usec, ingesteld %0.0f usec\n"
+"\tVlaggen: %s%s%s%s%s%s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr ""
+msgid "\tPorts:\n"
+msgstr "\tPoorten:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tActieve poort: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Verkrijgen van broninformatie mislukt: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1744,21 +1835,38 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Bron #%u\n"
+"\tToestand: %s\n"
+"\tNaam: %s\n"
+"\tBeschrijving: %s\n"
+"\tDriver: %s\n"
+"\tSamplespecificatie: %s\n"
+"\tKanaal map: %s\n"
+"\tModule eigenaar: %u\n"
+"\tDemping: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balans %0.2f\n"
+"\tBasis volume: %s%s%s\n"
+"\tMonitorafvoer: %s\n"
+"\tLatentie: %0.0f usec, ingesteld %0.0f usec\n"
+"\tVlaggen: %s%s%s%s%s%s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
-msgstr ""
+msgstr "n.v.t."
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr ""
+msgid "Failed to get module information: %s"
+msgstr "Verkrijgen van module informatie mislukte: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1768,13 +1876,19 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Module #%u\n"
+"\tNaam: %s\n"
+"\tArgument: %s\n"
+"\tGebruiksteller: %s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr ""
+msgid "Failed to get client information: %s"
+msgstr "Verkrijgen van clientinformatie mislukt: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1783,13 +1897,18 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Client #%u\n"
+"\tStuurprogramma: %s\n"
+"\tModule-eigenaar: %s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr ""
+msgid "Failed to get card information: %s"
+msgstr "Verkrijgen van kaartinformatie mislukt: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1799,23 +1918,29 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Kaart #%u\n"
+"\tNaam: %s\n"
+"\tStuurprogramma: %s\n"
+"\tModule-eigenaar: %s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
-msgstr ""
+msgstr "\tProfielen:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
-msgstr ""
+msgstr "\tActieve profiel: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr ""
+msgid "Failed to get sink input information: %s"
+msgstr "Verkrijgen van afvoer-invoerinformatie mislukt: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1835,13 +1960,29 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Afvoer input #%u\n"
+"\tStuurprogramma: %s\n"
+"\tModule-eigenaar: %s\n"
+"\tClient: %s\n"
+"\tAfvoer: %u\n"
+"\tSamplespecificatie: %s\n"
+"\tKanaalkaart: %s\n"
+"\tDemping: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balans %0.2f\n"
+"\tBufferlatentie: %0.0f usec\n"
+"\tAfvoerlatentie: %0.0f usec\n"
+"\tResample-methode: %s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr ""
+msgid "Failed to get source output information: %s"
+msgstr "Verkrijgen van bron-uitvoerinformatie mislukt: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1857,13 +1998,25 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Bronuitvoer #%u\n"
+"\tDriver: %s\n"
+"\tModule-eigenaaar: %s\n"
+"\tClient: %s\n"
+"\tBron: %u\n"
+"\tSamplespecificatie: %s\n"
+"\tKanaalkaart: %s\n"
+"\tBufferlatentie: %0.0f usec\n"
+"\tBronlatentie: %0.0f usec\n"
+"\tResample-methode: %s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr ""
+msgid "Failed to get sample information: %s"
+msgstr "Verkrijgen van sample-informatie mislukt: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -1880,24 +2033,94 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Sample #%u\n"
+"\tNaam: %s\n"
+"\tSamplespecificatie: %s\n"
+"\tKanaal map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balans %0.2f\n"
+"\tDuur: %0.1fs\n"
+"\tGrootte: %s\n"
+"\tTraagheid: %s\n"
+"\tBestandsnaam: %s\n"
+"\tEigenschappen:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr ""
+msgid "Failure: %s"
+msgstr "Mislukt: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Uploaden van monster mislukte: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Voortijdig einde van bestand"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
msgstr ""
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Ongeldige server"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Ontving SIGINT, afsluiten."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -1905,13 +2128,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -1921,83 +2153,151 @@ msgid ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
msgstr ""
+"%s [opties] stat\n"
+"%s [opties] list\n"
+"%s [opties] exit\n"
+"%s [opties] upload-sample BESTANDNAAM [NAAM]\n"
+"%s [opties] play-sample NAAM [AFVOER]\n"
+"%s [opties] remove-sample NAAM\n"
+"%s [opties] move-sink-input AFVOERINPUT AFVOER\n"
+"%s [opties] move-source-output BRONOUTPUT BRON\n"
+"%s [opties] load-module NAAM [ARG ...]\n"
+"%s [opties] unload-module MODULE\n"
+"%s [opties] suspend-sink AFVOER 1|0\n"
+"%s [opties] suspend-source BRON 1|0\n"
+"%s [opties] set-card-profile KAART PROFIEL\n"
+"%s [opties] set-sink-port AFVOER POORT\n"
+"%s [opties] set-source-port BRON POORT\n"
+"%s [opties] set-sink-volume AFVOER VOLUME\n"
+"%s [opties] set-source-volume BRON VOLUME\n"
+"%s [opties] set-sink-input-volume AFVOERINPUT VOLUME\n"
+"%s [opties] set-sink-mute AFVOER 1|0\n"
+"%s [opties] set-source-mute BRON 1|0\n"
+"%s [opties] set-sink-input-mute AFVOERINPUT 1|0\n"
+"\n"
+" -h, --help Laat deze hulp zien\n"
+" --version Laat versie zien\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
msgstr ""
+"pactl %s\n"
+"Gecompileerd met libpulse %s\n"
+"Gelinkt met libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr ""
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Geef een te laden samplebestand op"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr ""
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Openen geluidsbestand mislukt."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr ""
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Waarschuwing: Bepalen van samplespecificatie van bestand mislukte."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr ""
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "U dient een samplenaam op te geven om af te spelen"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr ""
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "U dient een samplenaam op te geven om te verwijderen"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr ""
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "U dient een afvoer-invoerindex en een afvoer op te geven"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr ""
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "U dient een bron-uitvoerindex en een bron op te geven"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr ""
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "U dient een modulenaam en argumenten op te geven."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "U dient een module index op te geven"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
+"U kunt niet meer dan een afvoer opgeven. U dient een boolean waarde op te "
+"geven."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
+"U kunt niet meer dan één bron opgeven. u dient een boolean waarde op te "
+"geven."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr ""
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "U dient een kaartnaam/index en een profielnaam op te geven"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr ""
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "U dient een afvoernaam/index en een poortnaam op te geven"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr ""
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "U dient een bronnaam/index en een poortnaam op te geven"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "U dient een afvoernaam/index en een volume op te geven"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Ongeldige volume-opgave"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "U dient een bronnaam/index en een volume op te geven"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "U dient een afvoer-invoerindex en een volume op te geven"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ongeldige afvoer-invoerindex"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "U dient een afvoernaam/index en een dempingsboolean op te geven"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "U dient een bronnaam/index en een dempingsboolean op te geven"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "U dient een afvoer-invoerindex en een dempingsboolean op te geven"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Ongeldige afvoer-invoerindex opgave"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Geen geldige opdracht opgegeven."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2010,170 +2310,119 @@ msgid ""
"variables and cookie file.\n"
" -r Remove PulseAudio data from X11 display\n"
msgstr ""
+"%s [-D scherm] [-S server] [-O afvoer] [-I bron] [-c bestand] [-d|-e|-i|-"
+"r]\n"
+"\n"
+" -d Laat huidige PulseAudio data zien horende bij X11 scherm (standaard)\n"
+" -e Exporteer locale PulseAudio data naar X11 scherm\n"
+" -i Importeer PulseAudio data van X11 scherm naar locale omgevings "
+"variabelen en cookie bestand.\n"
+" -r Verwijder PulseAudio data van X11 scherm\n"
#: ../src/utils/pax11publish.c:94
#, c-format
msgid "Failed to parse command line.\n"
-msgstr ""
+msgstr "Opdrachtregel ontleden mislukt.\n"
#: ../src/utils/pax11publish.c:108
#, c-format
msgid "Server: %s\n"
-msgstr ""
+msgstr "Server: %s\n"
#: ../src/utils/pax11publish.c:110
#, c-format
msgid "Source: %s\n"
-msgstr ""
+msgstr "Bron: %s\n"
#: ../src/utils/pax11publish.c:112
#, c-format
msgid "Sink: %s\n"
-msgstr ""
+msgstr "Afvoer: %s\n"
#: ../src/utils/pax11publish.c:114
#, c-format
msgid "Cookie: %s\n"
-msgstr ""
+msgstr "Cookie: %s\n"
#: ../src/utils/pax11publish.c:132
#, c-format
msgid "Failed to parse cookie data\n"
-msgstr ""
+msgstr "Cookiedata ontleden mislukt\n"
#: ../src/utils/pax11publish.c:137
#, c-format
msgid "Failed to save cookie data\n"
-msgstr ""
+msgstr "Cookiedata opslaan mislukt\n"
#: ../src/utils/pax11publish.c:152
#, c-format
msgid "Failed to load client configuration file.\n"
-msgstr ""
+msgstr "Clientconfiguratiebestand laden mislukt.\n"
#: ../src/utils/pax11publish.c:157
#, c-format
msgid "Failed to read environment configuration data.\n"
-msgstr ""
+msgstr "Omgevingsconfiguratiedata lezen mislukt.\n"
#: ../src/utils/pax11publish.c:174
#, c-format
msgid "Failed to get FQDN.\n"
-msgstr ""
+msgstr "FQDN verkrijgen mislukte.\n"
#: ../src/utils/pax11publish.c:194
#, c-format
msgid "Failed to load cookie data\n"
-msgstr ""
+msgstr "Cookiedata laden mislukt\n"
#: ../src/utils/pax11publish.c:211
#, c-format
msgid "Not yet implemented.\n"
+msgstr "Nog niet geïmplementeerd.\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
msgstr ""
+"Er draait geen PulseAudio-voorziening, of het draait niet als "
+"sessievoorziening."
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-msgstr ""
+msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
-msgstr ""
+msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
-msgstr ""
+msgstr "PulseAudio-voorziening uitzetten mislukt."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
-msgstr ""
+msgstr "Voorziening reageert niet."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr ""
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
-msgstr ""
+msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
-msgstr ""
+msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr ""
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
-msgstr ""
+msgstr "Kan geen toegang krijgen tot autospawn blokkade."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2183,8 +2432,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA maakte ons wakker om nieuwe data naar het apparaat te schrijven, maar "
+"er was niets om weg te schrijven!\n"
+"Waarschijnlijk is dit een fout in het ALSA-stuurprogramma ‘%s’. Meld dit "
+"probleem alstublieft aan de ALSA-ontwikkelaars.\n"
+"We werden gewekt met POLLOUT ingesteld -- echter een opvolgende snd_pcm_avail"
+"() gaf 0 terug of een andere waarde < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2194,35 +2449,367 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA maakte ons wakker om nieuwe data van het apparaat te lezen, maar er was "
+"niets om te lezen!\n"
+"Waarschijnlijk is dit een fout in het ALSA-stuurprogramma ‘%s’. Meld dit "
+"probleem alstublieft aan de ALSA-ontwikkelaars.\n"
+"We werden gewekt met POLLIN ingesteld -- echter een opvolgende snd_pcm_avail"
+"() gaf 0 terug of een andere waarde < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
-msgstr ""
+msgstr "Uit"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr ""
+msgstr "High Fidelity Playback (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "High Fidelity afvangen (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Telefonie duplex (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
+msgstr "PulseAudio-geluidsserver"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Uitvoerapparaten"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Invoerapparaten"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Geluid op @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Invoer"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Docking station-invoer"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Docking station-microfoon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Lijn-in"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Microfoon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Externe microfoon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Interne microfoon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Automatische gain-controle"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Geen automatische gain-controle"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Boostversterking"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Geen boostversterking"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Versterker"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Geen versterker"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Boostversterking"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Geen boostversterking"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Analoge koptelefoon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Analoge invoer"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Analoge microfoon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Analoge lijn-in"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Analoge radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Analoge video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Analoge output"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Analoge koptelefoon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Analoge output (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analoge mono-uitvoer"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analoog stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s/%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analoog mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analoog stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analoog surround 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analoog surround 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analoog surround 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analoog surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analoog surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analoog surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analoog surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analoog surround 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analoog surround 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analoog surround 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analoog surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digitaal stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digitaal surround 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digitaal surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digitaal surround 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digitaal stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analoog mono duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analoog stereo duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Digitaal stereo duplex (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Lage-frequentiezender"
+
+#, fuzzy
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Ongeldige resample methode '%s'."
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "Kan niet verbinden met systeem bus: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "Kan geen bezoeker krijgen van PID: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "Kan UID niet instellen op caller object."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "Kon geen CK sessie krijgen."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "Kan UID niet instellen op sessie object."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "Kan PolKitAction niet toekennen."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "Kan action_id niet instellen"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "Kan PolKitContext niet toekennen."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "Kan PolKitContext niet intialiseren: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "Kon niet bepalen of bezoeker gemachtigd is: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "Kan geen authorisatie krijgen: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit antwoordde met '%s'"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr ""
+#~ "Wij zijn in de groep '%s', wat plannen met hoge prioriteit toestaat."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr "Wij zijn in de groep '%s', war real-time planning toestaat."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr "PolicyKit kent ons acquire-high-priority rechten toe."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "PolicyKit weigert ons acquire-high-priority rechten."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "PolicyKit kent ons acquire-real-time rechten toe."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "PolicyKit weigert ons acquire-real-time rechten."
+
+#~ msgid ""
+#~ "Called SUID root and real-time and/or high-priority scheduling was "
+#~ "requested in the configuration. However, we lack the necessary "
+#~ "privileges:\n"
+#~ "We are not in group '%s', PolicyKit refuse to grant us the requested "
+#~ "privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
+#~ "limits.\n"
+#~ "For enabling real-time/high-priority scheduling please acquire the "
+#~ "appropriate PolicyKit privileges, or become a member of '%s', or increase "
+#~ "the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+#~ msgstr ""
+#~ "Aangeroepen met SUID root en real-time en/of high-priority inplannen was "
+#~ "verzocht in de configuratie. Echter de nodige rechten ontbreken:\n"
+#~ "We zijn niet in groep '%s', PolicyKit weigert om ons de gevraagde rechten "
+#~ "te geven en we hebben geen rect om de RLIMIT_NICE/RLIMIT_RTPRIO limieten "
+#~ "te verhogen.\n"
+#~ "Voor het aanzetten van real-time/high-priority inplannen mort je juiste "
+#~ "PolicyKit privileges hebben, of lid van '%s\" worden, of de RLIMIT_NICE/"
+#~ "RLIMIT_RTPRIO limieten voor deze gebruiker verhogen."
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "Hoge prioriteit inplannen is aangezet in de configuratie maar niet "
+#~ "toegestaan door de richtlijnen."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "RLIMIT_RTPRIO met succes verhoogd"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO mislukte: %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "Opgeven CAP_NICE"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "Real-time inplannen is aangezet in de configuratie maar niet toegestaan "
+#~ "door de richtlijnen."
diff --git a/po/or.po b/po/or.po
index a42bb7ce..47337a03 100644
--- a/po/or.po
+++ b/po/or.po
@@ -1,14 +1,14 @@
-# translation of pulseaudio.master-tx.pulseaudio.po to Oriya
+# translation of pulseaudio.master-tx.or.po to Oriya
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Manoj Kumar Giri <mgiri@redhat.com>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio.master-tx.pulseaudio\n"
+"Project-Id-Version: pulseaudio.master-tx.or\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-09 13:16+0530\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-11-14 15:33+0530\n"
"Last-Translator: Manoj Kumar Giri <mgiri@redhat.com>\n"
"Language-Team: Oriya <oriya-it@googlegroups.com>\n"
"MIME-Version: 1.0\n"
@@ -22,52 +22,23 @@ msgstr ""
"\n"
"\n"
"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "ଅନà­à¬°à­‚ପ ମୋନୋ"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "ଅନà­à¬°à­‚ପ ଷà­à¬Ÿà­‡à¬°à¬¿à¬“"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "ସାଂଖିକ ଷà­à¬Ÿà­‡à¬°à¬¿à¬“ (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "ସାଂଖିକ ଷà­à¬Ÿà­‡à¬°à¬¿à¬“ (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "ଅନà­à¬°à­‚ପ ଚତà­à¬°à­à¬ªà¬¾à¬°à­à¬¶à­à­± 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "ସାଂଖିକ ଚତà­à¬°à­à¬ªà¬¾à¬°à­à¬¶à­à­± 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "ଅନà­à¬°à­‚ପ ଚତà­à¬°à­à¬ªà¬¾à¬°à­à¬¶à­à­± 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "ଅନà­à¬°à­‚ପ ଚତà­à¬°à­à¬ªà¬¾à¬°à­à¬¶à­à­± 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "ଅନà­à¬°à­‚ପ ଚତà­à¬°à­à¬ªà¬¾à¬°à­à¬¶à­à­± 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "ସାଂଖିକ ଚତà­à¬°à­à¬ªà¬¾à¬°à­à¬¶à­à­± 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "ଅନà­à¬°à­‚ପ ଚତà­à¬°à­à¬ªà¬¾à¬°à­à¬¶à­à­± 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -80,7 +51,7 @@ msgstr ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -93,7 +64,7 @@ msgstr ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -106,11 +77,44 @@ msgstr ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "ସରà­à¬¬à¬¦à¬¾ ଅତିକମରେ ଗୋଟିଠସିଙà­à¬•କୠଧାରଣ କରନà­à¬¤à­ ଯଦିଚ ତାହା ଗୋଟିଠଶୂନà­à­Ÿ ଅଟେ"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ପà­à¬°à¬¤à¬¿à¬°à­‚ପି ଫଳାଫଳ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "ଆଭାସୀ LADSPA ସିଙà­à¬•"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<ସିଙà­à¬•ର ନାମ> sink_properties=<ସିଙà­à¬•ର ଗà­à¬£à¬§à¬°à­à¬®> master=<ସିଙà­à¬• ଛାଣକର ନାମ> "
+"format=<ନମà­à¬¨à¬¾ ସଜà­à¬œà¬¿à¬•ରଣ ଶୈଳୀ> rate=<ନମà­à¬¨à¬¾ ହାର> channels=<ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ସଂଖà­à­Ÿà¬¾> "
+"channel_map=<ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª> plugin=<ladspa ପà­à¬²à¬—ଇନ ନାମ> label=<ladspa ପà­à¬²à¬—ଇନ "
+"ନାମପଟି> control=<କମା ଦà­à­±à¬¾à¬°à¬¾ ପୃଥକ ନିବେଶ ନିୟନà­à¬¤à­à¬°à¬£ ମୂଲà­à­Ÿ ତାଲିକା>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "ସମୟାନà­à¬¬à¬°à­à¬¤à­à¬¤à¬¿ ଶୂନà­à­Ÿ ସିଙà­à¬•"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "ଶୂନà­à­Ÿ ଫଳାଫଳ"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "ଆଭà­à­Ÿà¬¨à­à¬¤à¬°à­€à¬£ ଧà­à­±à¬¨à¬¿"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "ମଡେମ"
@@ -126,216 +130,98 @@ msgstr "ନୂତନ dl ଧାରକକୠବଣà­à¬Ÿà¬¨ କରିବାରେ
msgid "Failed to add bind-now-loader."
msgstr "bind-now-loaderକୠଯୋଗ କରିବାରେ ବିଫଳ।"
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "ତନà­à¬¤à­à¬° ପରିପଥ ସହିତ ସଂଯୋଗ କରିପାରିବେ ନାହିà¬: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PIDରୠକଲରକୠପାଇପାରିବେ ନାହିà¬: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "କଲର ବସà­à¬¤à­à¬°à­‡ UID କୠସେଟ କରିପାରିବେ ନାହିà¬à¥¤"
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK ଅଧିବେଶନକୠପାଇବାରେ ବିଫଳ।"
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "ଅଧିବେଶନ ବସà­à¬¤à­à¬°à­‡ UID ସେଟ କରିପାରିବେ ନାହିà¬à¥¤"
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitActionକୠବଣà­à¬Ÿà¬¨ କରିପାରିବେ ନାହିà¬à¥¤"
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "action_id ସେଟ କରିପାରିବେ ନାହିà¬"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext ବଣà­à¬Ÿà¬¨ କରିପାରିବେ ନାହିà¬à¥¤"
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContextକୠଆରମà­à¬­ କରିପାରିବେ ନାହିà¬: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "କଲର ଅଧିକାର ପà­à¬°à¬¾à¬ªà­à¬¤ କି ନà­à¬¹à¬ ତାହା ନିରà­à¬¦à­à¬§à¬¾à¬°à¬£ କରି ପାରିଲା ନାହିà¬: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "auth ପାଇଲା ନାହିà¬: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit '%s' ସହିତ ଉତà­à¬¤à¬° ଦେଇଥିଲା"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "ସଂକେତ %s ପାଇଲା।"
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "ଉତà­à¬¤à­‡à¬œà¬¿à¬¤ କରà­à¬…ଛି।"
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "ଚାଳକ '%s' କୠଖୋଜିବାରେ ବିଫଳ।"
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "ସମୂହ '%s' କୠଖୋଜି ପାଇବାରେ ବିଫଳ।"
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "ଚାଳକ '%s' (UID %lu) à¬à¬¬à¬‚ ସମୂହ '%s' (GID %lu) ମିଳିଲା।"
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "ଚାଳକ '%s' à¬à¬¬à¬‚ ସମୂହ '%s' ର GID ମେଳଖାà¬à¬¨à¬¾à¬¹à¬¿à¬à¥¤"
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "ଚାଳକ '%s' ର ମୂଖà­à­Ÿ ଡିରେକà­à¬Ÿà­‹à¬°à­€à¬Ÿà¬¿ '%s' ନà­à¬¹à¬, ଅଗà­à¬°à¬¾à¬¹à­à­Ÿ କରà­à¬…ଛି।"
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s' ନିରà­à¬®à¬¾à¬£ କରିବାରେ ବିଫଳ: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "ସମୂହ ତାଲିକାକୠପରିବରà­à¬¤à­à¬¤à¬¨ କରିବାରେ ବିଫଳ: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID କୠପରିବରà­à¬¤à­à¬¤à¬¨ କରିବାରେ ବିଫଳ ହୋଇଛି: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID କୠପରିବରà­à¬¤à­à¬¤à¬¨ କରିବାରେ ବିଫଳ ହୋଇଛି: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "ମୂଖà­à­Ÿ ଚାଳକ ଅଧିକାରକୠସଫଳତାର ସହିତ ପକାଯାଇଛି।"
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "ତନà­à¬¤à­à¬°à¬®à­Ÿ ଧାରା à¬à¬¹à¬¿ ପà­à¬²à¬¾à¬Ÿà¬«à¬°à­à¬®à¬°à­‡ ଅସମରà­à¬¥à¬¿à¬¤à¥¤"
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) ବିଫଳ ହୋଇଛି: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "ପାଠà­à­Ÿ ନିରà­à¬¦à­à¬¦à­‡à¬¶à¬•ୠବିଶà­à¬³à­‡à¬·à¬£ କରିବାରେ ବିଫଳ।"
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "ଆମେ ମାନେ ଶà­à¬°à­‡à¬£à­€ '%s'ରେ ଅଛà­, ଉଚà­à¬š-ପà­à¬°à¬¾à¬¥à¬®à¬¿à¬•ତା ଯୋଜନାକୠଅନà­à¬®à¬¤à¬¿ ଦେଇ।"
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "ଆମେ ମାନେ ଶà­à¬°à­‡à¬£à­€ '%s'ରେ ଅଛà­, ପà­à¬°à¬•ୃତ- ସମୟ ଯୋଜନାକୠଅନà­à¬®à¬¤à¬¿ ଦେଇ।"
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit ଆମକୠacquire-high-priority ଅଧିକାର ଦେଇଥାà¬à¥¤"
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit acquire-high-priority ଅଧିକାରକୠବାରଣ କରିଥାà¬à¥¤"
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit ଆମକୠacquire-real-time ଅଧିକାର ଦେଇଥାà¬à¥¤"
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit acquire-real-time ଅଧିକାରକୠବାରଣ କରିଥାà¬à¥¤"
-
-#: ../src/daemon/main.c:556
-#, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr "ଉଚà­à¬š-ପà­à¬°à¬¾à¬¥à¬®à¬¿à¬• ଯୋଜନା ବିନà­à­Ÿà¬¾à¬¸à¬°à­‡ ସକà­à¬°à¬¿à­Ÿ କିନà­à¬¤à­ ନୀତି ଦà­à­±à¬¾à¬°à¬¾ ଅନà­à¬®à­‹à¬¦à¬¿à¬¤ ନà­à¬¹à¬à¥¤"
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO କୠସଫଳତାର ସହିତ ବୃଦà­à¬§à¬¿à¬•ରିଥାà¬"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO ବିଫଳ ହୋଇଛି: %s"
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "CAP_NICE କୠତà­à­Ÿà¬¾à¬— କରିଥାà¬"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr "Real-time ଯୋଜନା ବିନà­à­Ÿà¬¾à¬¸ ଫାଇଲରେ ସକà­à¬°à¬¿à­Ÿ ହୋଇଥାଠକିନà­à¬¤à­ ନିତୀ ଦà­à­±à¬¾à¬°à¬¾ ଅନà­à¬®à­‹à¬¦à¬¿à¬¤ ନà­à¬¹à¬à¥¤"
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "ଡେମନ ଚାଲà­à¬¨à¬¾à¬¹à¬¿à¬"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "ଡେମନ PID %u ପରି ଚାଲà­à¬…ଛି"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "ଡେମନକୠବନà­à¬¦ କରିବାରେ ବିଫଳ: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -343,158 +229,193 @@ msgstr ""
"à¬à¬¹à¬¿ ପà­à¬°à¬—à­à¬°à¬¾à¬®à¬Ÿà¬¿ ମୂଖà­à­Ÿ ଚାଳକ ଭାବରେ ଚଲାଇବା ପାଇଠନିରà­à¬¦à­à¬¦à¬¿à¬·à­à¬Ÿ ହୋଇନାହିଠ(unless --system is "
"specified)।"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "ମୂଖà­à­Ÿ ଚାଳକ ଅଧିକାର ଆବଶà­à­Ÿà¬•।"
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start ତନà­à¬¤à­à¬° ସà­à¬¥à¬¿à¬¤à¬¿ ପାଇଠସମରà­à¬¥à¬¿à¬¤ ନà­à¬¹à¬à¥¤"
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "ତନà­à¬¤à­à¬° ଧାରାରେ ଚାଲà­à¬…ଛି, କିନà­à¬¤à­ --disallow-exit କୠସେଟ କରାଯାଇନାହିà¬!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "ତନà­à¬¤à­à¬° ଧାରାରେ ଚାଲà­à¬…ଛି, କିନà­à¬¤à­ --disallow-module-loading କୠସେଟ କରାଯାଇନାହିà¬!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "ତନà­à¬¤à­à¬° ଧାରାରେ ଚାଲà­à¬…ଛି, SHM ଧାରାକୠବାଧà­à¬¯à¬¤à¬¾à¬®à­à¬³à¬• ଭାବରେ ନିଷà­à¬•à­à¬°à¬¿à­Ÿ କରିଥାà¬!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr "ତନà­à¬¤à­à¬° ଧାରାରେ ଚାଲà­à¬…ଛି, ପà­à¬°à¬¸à­à¬¥à¬¾à¬¨ ସà­à¬¥à¬¿à¬° ସମୟକୠବାଧà­à¬¯à¬¤à¬¾à¬®à­à¬³à¬• ଭାବରେ ନିଷà­à¬•à­à¬°à¬¿à­Ÿ କରିଥାà¬!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio କୠଅଧିକାର କରିବାରେ ବିଫଳ।"
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "ପାଇପ ବିଫଳ ହୋଇଛି: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "ଡେମନ ଆରମà­à¬­ ବିଫଳ ହୋଇଛି।"
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "ଡେମନ ଆରମà­à¬­ ସଫଳ ହୋଇଛି।"
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() ବିଫଳ ହୋଇଛି: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "à¬à¬¹à¬¾ ହେଉଛି PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "ସଂକଳନ ଆଧାର: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "ସଂକଳନ CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "ଆଧାରରେ ଚାଲà­à¬…ଛି: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPUs ମିଳିଛି।"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "ପୃଷà­à¬ à¬¾ ଆକାରଟି ହେଉଛି %lu ବାଇଟ"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Valgrind ସମରà­à¬¥à¬¨ ସହିତ ସଂକଳନ ହୋଇଛି: yes"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Valgrind ସମରà­à¬¥à¬¨ ସହିତ ସଂକଳନ ହୋଇଛି: no"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind ଧାରାରେ ଚାଲà­à¬…ଛି: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "ଆଧାରରେ ଚାଲà­à¬…ଛି: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "ଉପଯà­à¬•à­à¬¤ ନିରà­à¬®à¬¾à¬£: yes"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "ଉପଯà­à¬•à­à¬¤ ନିରà­à¬®à¬¾à¬£: no"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG କୠବà­à­Ÿà¬¾à¬–à­à­Ÿà¬¾ କରାଯାଇଛି, ସମସà­à¬¤ ନିଶà­à¬šà­Ÿà¬•ୠନିଷà­à¬•à­à¬°à¬¿à­Ÿ କରାଯାଇଛି।"
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH କୠବà­à­Ÿà¬¾à¬–à­à­Ÿà¬¾ କରାଯାଇଛି, କେବଳ ତୀବà­à¬° ପଥ ନିଶà­à¬šà­Ÿà¬•ୠନିଷà­à¬•à­à¬°à¬¿à­Ÿ କରାଯାଇଛି।"
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "ସମସà­à¬¤ ନିଶà­à¬šà­Ÿà¬•ୠସକà­à¬°à¬¿à­Ÿ କରାଯାଇଛି।"
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "ଯନà­à¬¤à­à¬° ID ପାଇବାରେ ବିଫଳ"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "ଯନà­à¬¤à­à¬° ID ଟି ହେଉଛି %s।"
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "ଯନà­à¬¤à­à¬° ID ଟି ହେଉଛି %s।"
+msgstr "ଅଧିବେଶନ ID ଟି ହେଉଛି %s।"
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "ପà­à¬°à¬šà¬³à¬¿à¬¤ ଡିରେକà­à¬Ÿà­‹à¬°à­€ %s କୠବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରà­à¬…ଛି।"
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "ସà­à¬¥à¬¿à¬¤à¬¿ ଡିରେକà­à¬Ÿà­‹à¬°à­€ %s କୠବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରି।"
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "à¬à¬•କାଂଶ ଡିରେକà­à¬Ÿà­‹à¬°à­€ %s କୠବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରି।"
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "ତନà­à¬¤à­à¬° ଧାରାରେ ଚାଲà­à¬…ଛି: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"OK, ଆପଣ PA କୠତନà­à¬¤à­à¬° ଧାରାରେ ଚଲାଉଛନà­à¬¤à¬¿à¥¤ ଦୟାକରି ମନେ ରଖନà­à¬¤à­ ଯେ ଆପଣ ପà­à¬°à¬¾à­Ÿà¬¤à¬ƒ ତାହା "
+"କରà­à¬¨à¬¾à¬¹à¬¾à¬¨à­à¬¤à¬¿à¥¤\n"
+"ଯଦି ଆପଣ ତାହା କରନà­à¬¤à¬¿ à¬à¬¬à¬‚ ସବà­à¬•ିଛି ଠିକରେ ନଚାଲେ ତେବେ ତାହା ଆପଣଙà­à¬•ର ନିଜର ଦୋଷ।\n"
+"ତନà­à¬¤à­à¬° ଧାରାଟି ସାଧାରଣତଃ କାହିà¬à¬•ି ଖରାପ ତାହା ବିଷୟରେ ଜାଣିବା ପାଇଠଦୟାକରି http://pulseaudio."
+"org/wiki/WhatIsWrongWithSystemMode କୠପଢ଼ନà­à¬¤à­à¥¤"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() ବିଫଳ ହୋଇଛି।"
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "ସତେଜ ଉଚà­à¬š-ବିଭେଦନ ସମୟ ମାପକ ଉପଲବà­à¬§! Bon appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -502,31 +423,31 @@ msgstr ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() ବିଫଳ ହୋଇଛି।"
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "ଡେମନକୠଆରମà­à¬­ କରିବାରେ ବିଫଳ।"
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "ଧାରଣ ହୋଇଥିବା à¬à¬•କାଂଶଗà­à¬¡à¬¼à¬¿à¬• ବିନା ଡେମନ ଆରମà­à¬­ ହୋଇଛି, କାରà­à¬¯à­à­Ÿ କରିବାକୠବାରଣ କରà­à¬…ଛି।"
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "ଡେମନ ଆରମà­à¬­ ସମà­à¬ªà­‚ରà­à¬£à­à¬£ ହୋଇଛି।"
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "ଡେମନ ବନà­à¬¦à¬•ୠଆରମà­à¬­ କରାଯାଇଛି।"
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "ଡେମନକୠସମାପà­à¬¤ କରାଯାଇଛି।"
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -668,15 +589,15 @@ msgstr ""
"\n"
" -n Don't load default script file\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -684,52 +605,52 @@ msgstr ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "ଅବୈଧ ଲଗ ଲକà­à¬·à­à¬¯à¬¸à­à¬¥à¬³: 'syslog', 'stderr' କିମà­à¬¬à¬¾ 'auto' କୠବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରନà­à¬¤à­à¥¤"
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "ଅବୈଧ ପà­à¬¨à¬ƒ ପà­à¬°à¬¤à¬¿à¬¦à¬°à­à¬¶à¬¨ ଧାରା '%s'।"
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm ବà­à¬²à¬¿à¬†à¬¨ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬° ଆଶା କରà­à¬…ଛି"
@@ -768,77 +689,87 @@ msgstr "ବà­à­Ÿà¬¬à¬¹à¬¾à¬° ବିଧି: %s\n"
msgid "Load Once: %s\n"
msgstr "ଥରେ ଧାରଣ କରନà­à¬¤à­: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "ପଥ: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] ଅବୈଧ ଲଗ ଲକà­à¬·à­à¬¯à¬¸à­à¬¥à¬³ '%s'।"
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] ଅବୈଧ ଲଗ ସà­à¬¤à¬°%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] ଅବୈଧ ପà­à¬¨à¬ƒ ମିଶà­à¬°à¬£ ଧାରା '%s'।"
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] ଅବୈଧ rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit à¬à¬¹à¬¿ ପà­à¬²à¬¾à¬Ÿà¬«à¬°à­à¬®à¬°à­‡ ସମରà­à¬¥à¬¿à¬¤ ନà­à¬¹à¬à¥¤"
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] ଅବୈଧ ନମà­à¬¨à¬¾ ଶୈଳୀ '%s'।"
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] ଅବୈଧ ନମà­à¬¨à¬¾ ହାର '%s'।"
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] ଅବୈଧ ନମà­à¬¨à¬¾ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² '%s'।"
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] ଅବୈଧ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª '%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] ଅବୈଧ ସଂଖà­à­Ÿà¬• ଖଣà­à¬¡à¬—à­à¬¡à¬¼à¬¿à¬• '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] ଅବୈଧ ଖଣà­à¬¡ ଆକାର '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] ଅବୈଧ ସà­à¬¨à­à¬¦à¬° ସà­à¬¤à¬° '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] ଅବୈଧ ନମà­à¬¨à¬¾ ହାର '%s'।"
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "ବିନà­à­Ÿà¬¾à¬¸ ଫାଇଲ ଖୋଲିବାରେ ବିଫଳ: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -846,18 +777,14 @@ msgstr ""
"ନିରà­à¬¦à­à¬¦à¬¿à¬·à­à¬Ÿà¬¿à¬¤ ପୂରà­à¬¬à¬¨à¬¿à¬°à­à¬¦à­à¬§à¬¾à¬°à¬¿à¬¤ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ªà¬°à­‡ ପୂରà­à¬¬à¬¨à¬¿à¬°à­à¬¦à­à¬§à¬¾à¬°à¬¿à¬¤ ସଂଖà­à­Ÿà¬• ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ବà­à­Ÿà¬¤à¬¿à¬¤ ଭିନà­à¬¨ ସଂଖà­à­Ÿà¬• "
"ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ଉଲà­à¬²à­‡à¬– ଅଛି।"
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### ବିନà­à­Ÿà¬¾à¬¸ ଫାଇଲରୠପଢ଼ନà­à¬¤à­: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "ମୂଖà­à­Ÿ ଚାଳକ ଅଧିକାରଗà­à¬¡à¬¼à¬¿à¬•ୠବାତିଲ କରà­à¬…ଛି।"
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "CAP_SYS_NICE କୠସୀମିତ କà­à¬·à¬®à¬¤à¬¾ ସଫଳତାର ସହିତ ଦିଆହୋଇଛି।"
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "ଅଧିକାରଗà­à¬¡à¬¼à¬¿à¬•ୠବାତିଲ କରà­à¬…ଛି।"
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -867,255 +794,237 @@ msgstr "PulseAudio ଧà­à­±à¬¨à¬¿ ତନà­à¬¤à­à¬°"
msgid "Start the PulseAudio Sound System"
msgstr "PulseAudio ଧà­à­±à¬¨à¬¿ ତନà­à¬¤à­à¬°à¬•ୠଆରମà­à¬­ କରନà­à¬¤à­"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "PulseAudio ଡେମନ ପାଇଠଉଚà­à¬š-ପà­à¬°à¬¾à¬¥à¬®à¬¿à¬•ତା ଯୋଜନା (ଋଣାତà­à¬®à¬• Unix ସà­à¬¨à­à¬¦à¬° ସà­à¬¤à¬°)"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio ଡେମନ ପାଇଠପà­à¬°à¬•ୃତ-ସମୟ ଯୋଜନା"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr "ତନà­à¬¤à­à¬° ନୀତି PulseAudio କୠଉଚà­à¬š-ପà­à¬°à¬¾à¬¥à¬®à¬¿à¬• ଯୋଜନାକୠଗà­à¬°à¬¹à¬£ କରିବାରୠଅଟକାଇଥାà¬à¥¤"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr "ତନà­à¬¤à­à¬° ନୀତି PulseAudio କୠପà­à¬°à¬•ୃତ-ସମୟ ଯୋଜନାକୠଗà­à¬°à¬¹à¬£ କରିବାରୠଅଟକାଇଥାà¬à¥¤"
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "ମୋନୋ"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "ସାମà­à¬¨à¬¾ ପାଖ କେନà­à¬¦à­à¬°"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "ସାମà­à¬¨à¬¾ ବାମ ପାଖ"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "ସାମà­à¬¨à¬¾ ଡ଼ାହାଣ ପାଖ"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "ପଛ ପାଖ କେନà­à¬¦à­à¬°"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "ପଛ ବାମ ପାଖ"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "ପଛ ଡ଼ାହାଣ ପାଖ"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "ନିମà­à¬¨ ଆବୃତà­à¬¤à¬¿ ପରିତà­à­Ÿà¬¾à¬— କାରୀ"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "ସାମà­à¬¨à¬¾ କେନà­à¬¦à­à¬°-ର-ବାମ ପାଖ"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "ସାମà­à¬¨à¬¾ କେନà­à¬¦à­à¬°-ର-ଡ଼ାହାଣ ପାଖ"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "ବାମ ପାରà­à¬¶à­à­±"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "ଡ଼ାହାଣ ପାରà­à¬¶à­à­±"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "ସହାୟକ 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "ସହାୟକ 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "ସହାୟକ 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "ସହାୟକ 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "ସହାୟକ 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "ସହାୟକ 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "ସହାୟକ 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "ସହାୟକ 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "ସହାୟକ 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "ସହାୟକ 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "ସହାୟକ 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "ସହାୟକ 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "ସହାୟକ 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "ସହାୟକ 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "ସହାୟକ 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "ସହାୟକ 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "ସହାୟକ 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "ସହାୟକ 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "ସହାୟକ 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "ସହାୟକ 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "ସହାୟକ 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "ସହାୟକ 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "ସହାୟକ 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "ସହାୟକ 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "ସହାୟକ 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "ସହାୟକ 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "ସହାୟକ 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "ସହାୟକ 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "ସହାୟକ 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "ସହାୟକ 28"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "ସହାୟକ 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "ସହାୟକ 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "ଉପର କେନà­à¬¦à­à¬°"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "ଉପର ସମà­à¬¨à¬¾ ପାଖ କେନà­à¬¦à­à¬°"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "ଉପର ସାମà­à¬¨à¬¾ ବାମ ପାଖ"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "ଉପର ସାମà­à¬¨à¬¾ ଡ଼ାହାଣ ପାଖ"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "ଉପର ପଛ ପାଖ କେନà­à¬¦à­à¬°"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "ଉପର ପଛ ବାମ ପାଖ"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "ଉପର ପଛ ଡ଼ାହାଣ ପାଖ"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(ଅବୈଧ)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "ଷà­à¬Ÿà­‡à¬°à¬¿à¬“"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 7.1"
@@ -1219,27 +1128,35 @@ msgstr "ଅନà­à¬ªà¬¸à­à¬¥à¬¿à¬¤ ପà­à¬°à­Ÿà­‹à¬—"
msgid "Client forked"
msgstr "ଗà­à¬°à¬¾à¬¹à¬• ଶାଖାଯà­à¬•à­à¬¤ ହୋଇଛି"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "ନିବେଶ/ଫଳାଫଳ ତà­à¬°à­à¬Ÿà¬¿"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "ଉପକରଣ ଅଥବା ଉତà­à¬¸ ବà­à­Ÿà¬¸à­à¬¤ ଅଛି"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1252,197 +1169,191 @@ msgstr "XOpenDisplay() ବିଫଳ ହୋଇଛି"
msgid "Failed to parse cookie data"
msgstr "କà­à¬•ି ତଥà­à­Ÿà¬•ୠବିଶà­à¬³à­‡à¬·à¬£ କରିବାରେ ବିଫଳ"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "ବିନà­à­Ÿà¬¾à¬¸ ଫାଇଲ '%s' କୠଖୋଲିବାରେ ବିଫଳ: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "କୌଣସି କà­à¬•ି ଧାରଣ କରାଯାଇନାହିà¬à¥¤ ତାହା ବିନା ସଂଯୋଗ କରିବାକୠପà­à¬°à¬šà­‡à¬·à­à¬šà¬¾ କରà­à¬…ଛି।"
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "ଅଜଣା ଅନà­à¬²à¬—à­à¬¨ '%s' ପାଇଠସନà­à¬¦à­‡à¬¶ ଗà­à¬°à¬¹à¬£ କରିଅଛି"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() ବିଫଳ ହୋଇଛି: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "ଧାରାକୠବାହାର କରିବାରେ ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() ବିଫଳ ହୋଇଛି: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "ପଛଚଲା ଧାରାକୠବାହାର କରାଯାଇଛି।"
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "ଧାରା ସଫଳତାର ସହିତ ନିରà­à¬®à¬¾à¬£ ହୋଇଛି।\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "ସରà­à¬­à¬° ପà­à¬°à¬¤à¬¿ ଡà­à¬°à­‡à¬¨à¬¿à¬™à­à¬— ସଂଯୋଗ।"
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() ବିଫଳ ହୋଇଛି: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "ବଫର ମେଟà­à¬°à¬¿à¬•ସ: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "ବଫର ମେଟà­à¬°à¬¿à¬•ସ: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "ନମà­à¬¨à¬¾ spec '%s' ବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରି, ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª '%s'।\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "ଉପକରଣ %s ସହିତ ସଂଯà­à¬•à­à¬¤ ହୋଇଛି (%u, %ssuspended)।\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "ଧାରା ସଫଳତାର ସହିତ ନିରà­à¬®à¬¾à¬£ ହୋଇଛି।"
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "ଧାରା ତà­à¬°à­à¬Ÿà¬¿: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "ଧାରା ଉପକରଣ ନିଲମà­à¬¬à¬¿à¬¤ ହୋଇଛି।%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "ବଫର ମେଟà­à¬°à¬¿à¬•ସ: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "ଧାରା ଉପକରଣ ପà­à¬¨à¬ƒ ଚଳନ ହୋଇଛି।%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "ବଫର ମେଟà­à¬°à¬¿à¬•ସ: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "ଧାରା underrun.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "ନମà­à¬¨à¬¾ spec '%s' ବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରି, ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª '%s'।"
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "ଧାରା overrun.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "ଉପକରଣ %s ସହିତ ସଂଯà­à¬•à­à¬¤ ହୋଇଛି (%u, %ssuspended)।"
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "ଧାରା ଆରମà­à¬­ ହୋଇଛି।%s \n"
+msgid "Stream error: %s"
+msgstr "ଧାରା ତà­à¬°à­à¬Ÿà¬¿: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "ଧାରା ଉପକରଣ %sକୠଗତି କରିଛି (%u, %ssuspended).%s \n"
+msgid "Stream device suspended.%s"
+msgstr "ଧାରା ଉପକରଣ ନିଲମà­à¬¬à¬¿à¬¤ ହୋଇଛି।%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "not "
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "ଧାରା ବଫର ଗà­à¬£à¬—à­à¬¡à¬¼à¬¿à¬• ପରିବରà­à¬¤à­à¬¤à¬¨ ହୋଇଛି।%s\n"
+msgid "Stream device resumed.%s"
+msgstr "ଧାରା ଉପକରଣ ପà­à¬¨à¬ƒ ଚଳନ ହୋଇଛି।%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "ସଂଯୋଗ ସà­à¬¥à¬¾à¬ªà¬¿à¬¤ ହୋଇଛି।%s \n"
+msgid "Stream underrun.%s"
+msgstr "ଧାରା underrun.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() ବିଫଳ ହୋଇଛି: %s\n"
+msgid "Stream overrun.%s"
+msgstr "ଧାରା overrun.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() ବିଫଳ ହୋଇଛି: %s\n"
+msgid "Stream started.%s"
+msgstr "ଧାରା ଆରମà­à¬­ ହୋଇଛି।%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() ବିଫଳ ହୋଇଛି: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "ଧାରା ଉପକରଣ %sକୠଗତି କରିଛି (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "ସଂଯୋଗ ବିଫଳ ହୋଇଛି: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "not "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "ଧାରାକୠବାହାର କରିବାରେ ବିଫଳ ହୋଇଛି: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "ଧାରା ବଫର ଗà­à¬£à¬—à­à¬¡à¬¼à¬¿à¬• ପରିବରà­à¬¤à­à¬¤à¬¨ ହୋଇଛି।%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "ପଛଚଲା ଧାରାକୠବାହାର କରାଯାଇଛି।\n"
+msgid "Connection established.%s"
+msgstr "ସଂଯୋଗ ସà­à¬¥à¬¾à¬ªà¬¿à¬¤ ହୋଇଛି।%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "ସରà­à¬­à¬° ପà­à¬°à¬¤à¬¿ ଡà­à¬°à­‡à¬¨à¬¿à¬™à­à¬— ସଂଯୋଗ।\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF ପାଇଅଛି।\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() ବିଫଳ ହୋଇଛି: %s\n"
+msgid "Connection failure: %s"
+msgstr "ସଂଯୋଗ ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() ବିଫଳ ହୋଇଛି: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF ପାଇଅଛି।"
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "ସଂକେତ ପାଇଲା, ପà­à¬°à¬¸à­à¬¥à¬¾à¬¨ କରà­à¬…ଛି।\n"
+msgid "write() failed: %s"
+msgstr "write() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "ବିଳମà­à¬¬à¬¤à¬¾ ପାଇବାରେ ବିଫଳ: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "ସଂକେତ ପାଇଲା, ପà­à¬°à¬¸à­à¬¥à¬¾à¬¨ କରà­à¬…ଛି।"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "ସମୟ: %0.3f sec; ବିଳମà­à¬¬à¬¤à¬¾: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "ବିଳମà­à¬¬à¬¤à¬¾ ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() ବିଫଳ ହୋଇଛି: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "ସମୟ: %0.3f ସେକଣà­à¬¡; ବିଳମà­à¬¬à¬¤à¬¾: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() ବିଫଳ ହୋଇଛି: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1468,8 +1379,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1492,8 +1405,17 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
-"%s [options]\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•]\n"
"\n"
" -h, --help à¬à¬¹à¬¿ ସହାୟତା ଦରà­à¬¶à¬¾à¬¨à­à¬¤à­\n"
" --version ସଂସà­à¬•ରଣ ଦରà­à¬¶à¬¾à¬¨à­à¬¤à­\n"
@@ -1516,30 +1438,34 @@ msgstr ""
"s16be, u8, float32le,\n"
" float32be, ulaw, alaw, s32le, s32be "
"(defaults to s16ne)\n"
-" --channels=CHANNELS The number of channels, 1 for mono, "
-"2 for stereo\n"
-" (defaults to 2)\n"
-" --channel-map=CHANNELMAP Channel map to use instead of the "
-"default\n"
-" --fix-format Take the sample format from the sink "
-"the stream is\n"
-" being connected to.\n"
-" --fix-rate Take the sampling rate from the sink "
-"the stream is\n"
-" being connected to.\n"
-" --fix-channels Take the number of channels and the "
-"channel map\n"
-" from the sink the stream is being "
-"connected to.\n"
-" --no-remix Don't upmix or downmix channels.\n"
-" --no-remap Map channels by index instead of "
-"name.\n"
-" --latency=BYTES Request the specified latency in "
-"bytes.\n"
-" --process-time=BYTES Request the specified process time "
-"per request in bytes.\n"
-
-#: ../src/utils/pacat.c:612
+" --channels=CHANNELS ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ସଂଖà­à­Ÿà¬¾, ମୋନୋ ପାଇଠ1, ଷà­à¬Ÿà­‡à¬°à¬¿à¬“ ପାଇଠ"
+"2\n"
+" (2 ପାଇଠପୂରà­à¬¬à¬¨à¬¿à¬°à­à¬¦à­à¬§à¬¾à¬°à¬¿à¬¤)\n"
+" --channel-map=CHANNELMAP ପୂରà­à¬¬à¬¨à¬¿à¬°à­à¬¦à­à¬§à¬¾à¬°à¬¿à¬¤ ପରିବରà­à¬¤à­à¬¤à­‡ ବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରିବାକୠଥିବା "
+"ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª\n"
+" --fix-format ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ ସଜà­à¬œà¬¿à¬•ରଣ ଶୈଳୀକୠସିଙà­à¬•ରୠ"
+"ଗà­à¬°à¬¹à¬£ କରନà­à¬¤à­\n"
+" ଯାହା ସହିତ ଧାରାଟି ସଂଯà­à¬•à­à¬¤à¥¤\n"
+" --fix-rate ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ ସଜà­à¬œà¬¿à¬•ରଣ ଶୈଳୀକୠସିଙà­à¬•ରୠ"
+"ଗà­à¬°à¬¹à¬£ କରନà­à¬¤à­\n"
+" ଯାହା ସହିତ ଧାରାଟି ସଂଯà­à¬•à­à¬¤à¥¤\n"
+" --fix-channels ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ସଂଖà­à­Ÿà¬¾ à¬à¬¬à¬‚ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ªà¬•à­ "
+"ସିଙà­à¬•ରà­à¬—à­à¬°à¬¹à¬£ କରନà­à¬¤à­\n"
+" ଯାହା ସହିତ ଧାରାଟି ସଂଯà­à¬•à­à¬¤à¥¤\n"
+" --no-remix ଚà­à­Ÿà¬¾à¬¨à­‡à¬²à¬—à­à¬¡à¬¼à¬¿à¬•à­ upmix ଅଥବା downmix କରନà­à¬¤à­ "
+"ନାହିà¬à¥¤\n"
+" --no-remap ନାମ ପରିବରà­à¬¤à­à¬¤à­‡ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା ଅନà­à¬¸à¬¾à¬°à­‡ "
+"ଚà­à­Ÿà¬¾à¬¨à­‡à¬²à¬—à­à¬¡à¬¼à¬¿à¬•ୠମà­à­Ÿà¬¾à¬ª କରନà­à¬¤à­à¥¤\n"
+" --latency=BYTES ନିରà­à¬¦à­à¬¦à¬¿à¬·à­à¬Ÿà¬¿à¬¤ ବିଳମà­à¬¬à¬¤à¬¾à¬•ୠବାଇଟରେ ଆବେଦନ କରନà­à¬¤à­à¥¤\n"
+" --process-time=BYTES ଅନà­à¬°à­‹à¬§ ପà­à¬°à¬¤à¬¿ ନିରà­à¬¦à­à¬¦à¬¿à¬·à­à¬Ÿà¬¿à¬¤ ବିଳମà­à¬¬à¬¤à¬¾à¬•ୠବାଇଟରେ "
+"ଆବେଦନ କରନà­à¬¤à­à¥¤\n"
+" --property=PROPERTY=VALUE ନିରà­à¬¦à­à¬¦à¬¿à¬·à­à¬Ÿà¬¿à¬¤ ମୂଲà­à­Ÿ ପାଇଠଉଲà­à¬²à¬¿à¬–ିତ ଗà­à¬£à¬§à¬°à­à¬®à¬•ୠସେଟ "
+"କରନà­à¬¤à­à¥¤\n"
+" --raw ଅପରିପକà­à­± PCM ତଥà­à­Ÿà¬•ୠଲିପିବଦà­à¬§ କରନà­à¬¤à­/ଚଲାନà­à¬¤à­à¥¤\n"
+" --file-format=FFORMAT ସଜà­à¬œà¬¿à¬•ୃତ PCM ତଥà­à­Ÿà¬•ୠଲିପିବଦà­à¬§ କରନà­à¬¤à­/ଚଲାନà­à¬¤à­à¥¤\n"
+" --list-file-formats ତାଲିକା ଉପଲବà­à¬§ ଫାଇଲ ସଜà­à¬œà¬¿à¬•ରଣ ଶୈଳୀ।\n"
+
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1550,129 +1476,169 @@ msgstr ""
"libpulse %s ସହିତ ସଂକଳିତ\n"
"libpulse %s ସହିତ ସଂଯà­à¬•à­à¬¤\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "ଅବୈଧ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "ଅବୈଧ କà­à¬²à¬¾à¬à¬£à­à¬Ÿ ନାମ '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "ଅବୈଧ ବିଳମà­à¬¬à¬¤à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "ଅବୈଧ ଧାରା ନାମ '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "ଅବୈଧ ପଦà­à¬§à¬¤à¬¿ ସମୟ ବିଶେଷ ଲକà­à¬·à¬£ '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "ଅବୈଧ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "ଅବୈଧ ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£\n"
+msgid "Invalid latency specification '%s'"
+msgstr "ଅବୈଧ ବିଳମà­à¬¬à¬¤à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ ସହିତ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª ମେଳ ଖାଉନାହିà¬\n"
+msgid "Invalid process time specification '%s'"
+msgstr "ଅବୈଧ ପଦà­à¬§à¬¤à¬¿ ସମୟ ବିଶେଷ ଲକà­à¬·à¬£ '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ '%s' ସହିତ ଗୋଟିଠ%s ଧାରାକୠଖୋଲà­à¬…ଛି।\n"
+msgid "Invalid property '%s'"
+msgstr "ଅବୈଧ ଗà­à¬£à¬§à¬°à­à¬® '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "ଅନà­à¬²à¬¿à¬ªà¬¿ କରà­à¬…ଛି"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "ଅଜଣା ଫାଇଲ ସଜà­à¬œà¬¿à¬•ରଣ ଶୈଳୀ %s।"
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "ପଛଚଲା"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "ଅବୈଧ ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "ଅତà­à­Ÿà¬§à¬¿à¬• ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬°à¥¤\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "ଅତà­à­Ÿà¬§à¬¿à¬• ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬°à¥¤"
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() ବିଫଳ ହୋଇଛି।\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "ଫାଇଲ ପାଇଠନମà­à¬¨à¬¾ ସୂଚନା ସୃଷà­à¬Ÿà¬¿ କରିବାରେ ବିଫଳ।"
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() ବିଫଳ ହୋଇଛି।\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "ଧà­à­±à¬¨à¬¿ ଫାଇଲ ଖୋଲିବାରେ ବିଫଳ।"
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() ବିଫଳ ହୋଇଛି।\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "ଚେତାବନୀ: ଉଲà­à¬²à¬¿à¬–ିତ ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£à¬•ୠଫାଇଲରୠବିଶେଷ ଲକà­à¬·à¬£ ସହିତ ନବଲିଖନ କରାଯିବ।"
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() ବିଫଳ ହୋଇଛି: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ଫାଇଲରୠନମà­à¬¨à¬¾ ସୂଚନା ନିରà­à¬¦à­à¬§à¬¾à¬°à¬£ କରିବାରେ ବିଫଳ।"
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "ଚେତାବନୀ: ଫାଇଲରୠଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª ନିରà­à¬¦à­à¬§à¬¾à¬°à¬£ କରିବାରେ ବିଫଳ।"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ ସହିତ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª ମେଳ ଖାଉନାହିà¬"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "ଚେତାବନୀ: ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ªà¬•ୠଫାଇଲରେ ଲେଖିବାରେ ବିଫଳ।"
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() ବିଫଳ ହୋଇଛି।\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£ '%s' à¬à¬¬à¬‚ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª '%s' ସହିତ ଗୋଟିଠ%s ଧାରାକୠଖୋଲà­à¬…ଛି।"
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "ଅନà­à¬²à¬¿à¬ªà¬¿ କରà­à¬…ଛି"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "ପଛଚଲା"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() ବିଫଳ ହୋଇଛି।"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() ବିଫଳ ହୋଇଛି।"
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() ବିଫଳ ହୋଇଛି।"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() ବିଫଳ ହୋଇଛି।\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() ବିଫଳ ହୋଇଛି: %s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() ବିଫଳ ହୋଇଛି।"
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() ବିଫଳ ହୋଇଛି।"
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "ନିଲମà­à¬¬à¬¨ କରିବାରେ ବିଫଳ: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "ପà­à¬¨à¬ƒ ଚଳନ କରିବାରେ ବିଫଳ: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "WARNING: ଧà­à­±à¬¨à¬¿ ସରà­à¬­à¬°à¬Ÿà¬¿ ସà­à¬¥à¬¾à¬¨à­€à­Ÿ ନà­à¬¹à¬, ନିଲମà­à¬¬à¬¿à¬¤ କରà­à¬¨à¬¾à¬¹à¬¿à¬à¥¤\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "ସଂଯୋଗ ବିଫଳ ହୋଇଛି: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT ପାଇଛି, ଉତà­à¬¸à¬¾à¬¹à¬¿à¬¤ କରà­à¬…ଛି।\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "WARNING: ନିମà­à¬¨ ସà­à¬¤à¬°à¬° ପà­à¬°à¬•à­à¬°à¬¿à­Ÿà¬¾à¬Ÿà¬¿ ସଂକେତ %u ଦà­à­±à¬¾à¬°à¬¾ ସମାପà­à¬¤\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1690,7 +1656,7 @@ msgstr ""
" -s, --server=SERVER ସଂଯୋଗ କରିବା ପାଇଠସରà­à¬­à¬°à¬° ନାମ\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1701,35 +1667,61 @@ msgstr ""
"libpulse %s ସହିତ ସଂକଳିତ\n"
"libpulse %s ସହିତ ସଂଯà­à¬•à­à¬¤\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "ପରିସଂଖà­à­Ÿà¬¾à¬¨ ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() ବିଫଳ ହୋଇଛି।\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() ବିଫଳ ହୋଇଛି।\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() ବିଫଳ ହୋଇଛି।\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "ପରିସଂଖà­à­Ÿà¬¾à¬¨ ପାଇବାରେ ବିଫଳ: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "ବରà­à¬¤à­à¬¤à¬®à¬¾à¬¨ ବà­à­Ÿà¬¬à¬¹à¬¾à¬°à¬°à­‡ ଅଛି: %u ବà­à¬²à¬• ସମà­à¬¦à¬¾à­Ÿ %s ବାଇଟ ଧାରଣ କରିଥାà¬à¥¤\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "ସମଗà­à¬° ଜୀବନରେ ବଣà­à¬Ÿà¬¿à¬¤ ହୋଇଥାà¬: %u ବà­à¬²à¬• ସମà­à¬¦à¬¾à­Ÿ %s ବାଇଟ ଧାରଣ କରିଥାà¬à¥¤\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "ନମà­à¬¨à¬¾ କà­à­Ÿà¬¾à¬¶à­‡ ଆକାର: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "ସରà­à¬­à¬° ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "ସରà­à¬­à¬° ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1737,7 +1729,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"ଚାଳକ ନାମ: %s\n"
"ଆଧାର ନାମ: %s\n"
@@ -1749,12 +1741,12 @@ msgstr ""
"ପୂରà­à¬¬à¬¨à¬¿à¬°à­à¬¦à­à¬§à¬¾à¬°à¬¿à¬¤ ଉତà­à¬¸: %s\n"
"କà­à¬•ି: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "ସିଙà­à¬• ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "ସିଙà­à¬• ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1793,12 +1785,22 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tସଂଯୋଗିକୀଗà­à¬¡à¬¼à¬¿à¬•:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "ଉତà­à¬¸ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tସକà­à¬°à¬¿à­Ÿ ସଂଯୋଗିକୀ: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "ଉତà­à¬¸ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1837,20 +1839,20 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "à¬à¬•କାଂଶ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "à¬à¬•କାଂଶ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1867,12 +1869,12 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "ଗà­à¬°à¬¾à¬¹à¬• ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "ଗà­à¬°à¬¾à¬¹à¬• ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1887,12 +1889,12 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "କାରà­à¬¡ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "କାରà­à¬¡ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1909,22 +1911,22 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tରୂପରେଖଗà­à¬¡à¬¼à¬¿à¬•:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tସକà­à¬°à¬¿à­Ÿ ରୂପରେଖା: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "ସିଙà­à¬• ନିବେଶ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "ସିଙà­à¬• ନିବେଶ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1961,12 +1963,12 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "ଉତà­à¬¸ ଫଳାଫଳ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "ଉତà­à¬¸ ଫଳାଫଳ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1995,12 +1997,12 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "ନମà­à¬¨à¬¾ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "ନମà­à¬¨à¬¾ ସୂଚନା ପାଇବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2031,23 +2033,80 @@ msgstr ""
"\tଗà­à¬£à¬§à¬°à­à¬®:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "ବିଫଳତା: %s\n"
+msgid "Failure: %s"
+msgstr "ବିଫଳତା: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "ନମà­à¬¨à¬¾à¬•ୠଧାରଣ କରିବାରେ ବିଫଳ: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "ନମà­à¬¨à¬¾à¬•ୠଧାରଣ କରିବାରେ ବିଫଳ: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "ଫାଇଲର ସମୟ ପୂରà­à¬¬ ସମାପà­à¬¤à¬¿\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "ଫାଇଲର ସମୟ ପୂରà­à¬¬ ସମାପà­à¬¤à¬¿"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "ଅବୈଧ ସରà­à¬­à¬°"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT ପାଇଛି, ଉତà­à¬¸à¬¾à¬¹à¬¿à¬¤ କରà­à¬…ଛି।"
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2055,13 +2114,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2071,29 +2139,35 @@ msgid ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
msgstr ""
-"%s [options] stat\n"
-"%s [options] list\n"
-"%s [options] exit\n"
-"%s [options] upload-sample FILENAME [NAME]\n"
-"%s [options] play-sample NAME [SINK]\n"
-"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
-"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] stat\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] list\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] exit\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] upload-sample FILENAME [NAME]\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] play-sample NAME [SINK]\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] remove-sample NAME\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] move-sink-input ID SINK\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] move-source-output ID SOURCE\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] load-module NAME [ARGS ...]\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] unload-module ID\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] suspend-sink [SINK] 1|0\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] suspend-source [SOURCE] 1|0\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-card-profile [CARD] [PROFILE] \n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-sink-port [SINK] [PORT] \n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-source-port [SOURCE] [PORT] \n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-sink-volume SINK VOLUME\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-source-volume SOURCE VOLUME\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-sink-mute SINK 1|0\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-source-mute SOURCE 1|0\n"
+"%s [ବିକଳà­à¬ªà¬—à­à¬¡à¬¼à¬¿à¬•] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
+" -h, --help à¬à¬¹à¬¿ ସହାୟତାକୠଦରà­à¬¶à¬¾à¬¨à­à¬¤à­\n"
+" --version ସଂସà­à¬•ରଣ ଦରà­à¬¶à¬¾à¬¨à­à¬¤à­\n"
"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
+" -s, --server=SERVER ସଂଯୋଗ କରିବା ପାଇଠସରà­à¬­à¬°à¬° ନାମ\n"
+" -n, --client-name=NAME ସରà­à¬­à¬°à¬°à­‡ à¬à¬¹à¬¿ କà­à¬²à¬¾à¬à¬£à­à¬Ÿà¬•ୠକିପରି ଡାକିବେ\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2104,78 +2178,108 @@ msgstr ""
"libpulse %s ସହିତ ସଂକଳିତ\n"
"libpulse %s ସହିତ ସଂଯà­à¬•à­à¬¤\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "ଧାରଣ କରିବା ପାଇଠଗୋଟିଠନà­à¬®à¬¨à¬¾ ଫାଇଲ ଉଲà­à¬²à­‡à¬– କରନà­à¬¤à­\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "ଧାରଣ କରିବା ପାଇଠଗୋଟିଠନà­à¬®à¬¨à¬¾ ଫାଇଲ ଉଲà­à¬²à­‡à¬– କରନà­à¬¤à­"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "ଧà­à­±à¬¨à¬¿ ଫାଇଲ ଖୋଲିବାରେ ବିଫଳ।\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "ଧà­à­±à¬¨à¬¿ ଫାଇଲ ଖୋଲିବାରେ ବିଫଳ।"
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "ଚଲାଇବା ପାଇଠଆପଣଙà­à¬•ୠଗୋଟିଠନମà­à¬¨à¬¾ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "ଚେତାବନୀ: ଫାଇଲରୠନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£à¬•ୠନିରà­à¬¦à­à¬§à¬¾à¬°à¬£ କରିବାରେ ବିଫଳ।"
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "କାଢ଼ିବା ପାଇଠଆପଣଙà­à¬•ୠଗୋଟିଠନମà­à¬¨à¬¾ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "ଚଲାଇବା ପାଇଠଆପଣଙà­à¬•ୠଗୋଟିଠନମà­à¬¨à¬¾ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠସିଙà­à¬• ନିବେଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ଗୋଟିଠସିଙà­à¬• ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "କାଢ଼ିବା ପାଇଠଆପଣଙà­à¬•ୠଗୋଟିଠନମà­à¬¨à¬¾ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠଉତà­à¬¸ ନିରà­à¬—ମ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ଗୋଟିଠଉତà­à¬¸ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠସିଙà­à¬• ନିବେଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ଗୋଟିଠସିଙà­à¬• ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠà¬à¬•କାଂଶ ନାମ à¬à¬¬à¬‚ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬°à¬—à­à¬¡à¬¼à¬¿à¬•ୠଉଲà­à¬²à­‡à¬– କରିବା ଉଚିତ।\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠଉତà­à¬¸ ନିରà­à¬—ମ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ଗୋଟିଠଉତà­à¬¸ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠà¬à¬•କାଂଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ାକୠଉଲà­à¬²à­‡à¬– କରିବା ଉଚିତ ନà­à¬¹à¬\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠà¬à¬•କାଂଶ ନାମ à¬à¬¬à¬‚ ସà­à­±à¬¤à¬¨à­à¬¤à­à¬°à¬šà¬°à¬—à­à¬¡à¬¼à¬¿à¬•ୠଉଲà­à¬²à­‡à¬– କରିବା ଉଚିତ।"
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠà¬à¬•କାଂଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ାକୠଉଲà­à¬²à­‡à¬– କରିବା ଉଚିତ ନà­à¬¹à¬"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"ଆପଣଙà­à¬•ୠଗୋଟିà¬à¬°à­ ଅଧିକ ସିଙà­à¬• ଉଲà­à¬²à­‡à¬– କରିବାକୠପଡ଼ିନପାରେ। ଆପଣଙà­à¬•ୠଗୋଟିଠବà­à¬²à¬¿à¬†à¬¨ ମୂଲà­à­Ÿ ଉଲà­à¬²à­‡à¬– କରିବାକୠ"
-"ହେବ।\n"
+"ଆପଣଙà­à¬•ୠଗୋଟିà¬à¬°à­ ଅଧିକ ସିଙà­à¬• ଉଲà­à¬²à­‡à¬– କରିବାକୠପଡ଼ିନପାରେ। ଆପଣଙà­à¬•ୠଗୋଟିଠବà­à¬²à¬¿à¬†à¬¨ ମୂଲà­à­Ÿ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ।"
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"ଆପଣଙà­à¬•ୠଗୋଟିà¬à¬°à­ ଅଧିକ ଉତà­à¬¸ ଉଲà­à¬²à­‡à¬– କରିବାକୠପଡ଼ିନପାରେ। ଆପଣଙà­à¬•ୠଗୋଟିଠବà­à¬²à¬¿à¬†à¬¨ ମୂଲà­à­Ÿ ଉଲà­à¬²à­‡à¬– କରିବାକୠ"
-"ହେବ।\n"
+"ଆପଣଙà­à¬•ୠଗୋଟିà¬à¬°à­ ଅଧିକ ଉତà­à¬¸ ଉଲà­à¬²à­‡à¬– କରିବାକୠପଡ଼ିନପାରେ। ଆପଣଙà­à¬•ୠଗୋଟିଠବà­à¬²à¬¿à¬†à¬¨ ମୂଲà­à­Ÿ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ।"
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠକାରà­à¬¡ ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ରୂପରେଖା ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠକାରà­à¬¡ ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ରୂପରେଖା ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "କୌଣସି ବୈଧ ନିରà­à¬¦à­à¬¦à­‡à¬¶ ଉଲà­à¬²à­‡à¬– କରାଯାଇନାହିà¬à¥¤\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠସିଙà­à¬• ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ସଂଯୋଗିକୀ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() ବିଫଳ ହୋଇଛି: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠଉତà­à¬¸ ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ସଂଯୋଗିକୀ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠସିଙà­à¬• ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ସଂଯୋଗିକୀ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "ଅବୈଧ ନମà­à¬¨à¬¾ ବିଶେଷ ଲକà­à¬·à¬£"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠଉତà­à¬¸ ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ସଂଯୋଗିକୀ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠସିଙà­à¬• ନିବେଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ଗୋଟିଠସିଙà­à¬• ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "ଅବୈଧ ସିଙà­à¬• ନିବେଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠସିଙà­à¬• ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ସଂଯୋଗିକୀ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠଉତà­à¬¸ ନାମ/ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ସଂଯୋଗିକୀ ନାମ ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "ଆପଣଙà­à¬•ୠଗୋଟିଠସିଙà­à¬• ନିବେଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା à¬à¬¬à¬‚ ଗୋଟିଠସିଙà­à¬• ଉଲà­à¬²à­‡à¬– କରିବାକୠହେବ"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "ଅବୈଧ ସିଙà­à¬• ନିବେଶ ଅନà­à¬•à­à¬°à¬®à¬£à¬¿à¬•ା ବିଶେଷ ଲକà­à¬·à¬£"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "କୌଣସି ବୈଧ ନିରà­à¬¦à­à¬¦à­‡à¬¶ ଉଲà­à¬²à­‡à¬– କରାଯାଇନାହିà¬à¥¤"
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2255,126 +2359,48 @@ msgstr "କà­à¬•ି ତଥà­à­Ÿ ଧାରଣ କରିବାରେ ବିଫà¬
msgid "Not yet implemented.\n"
msgstr "ଅପରà­à¬¯à­à­Ÿà¬¨à­à¬¤ କାରà­à¬¯à­à­Ÿà¬•ାରୀ ହୋଇନାହିà¬à¥¤\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "କୌଣସି PulseAudio ଡେମନ ଚାଲà­à¬¨à¬¾à¬¹à¬¿à¬, କିମà­à¬¬à¬¾ ଅଧିବେଶନ ଡେମନ ପରି ଚାଲà­à¬¨à¬¾à¬¹à¬¿à¬à¥¤"
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "ସକେଟ(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "ସଂଯୋଗ କରନà­à¬¤à­(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio ଡେମନକୠବନà­à¬¦ କରିବାରେ ବିଫଳ।"
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "ଡେମନ ଉତà­à¬¤à¬° ଦେଉନାହିà¬à¥¤"
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "ବାଛନà­à¬¤à­(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "ପଢ଼ନà­à¬¤à­(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "ଲେଖନà­à¬¤à­(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "ଧାରା ସଫଳତାର ସହିତ ନିରà­à¬®à¬¿à¬¤ ହୋଇଛି\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "ଧାରା ତà­à¬°à­à¬Ÿà¬¿: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "ସଂଯୋଗ ସà­à¬¥à¬¾à¬ªà¬¿à¬¤ ହୋଇସାରିଛି।\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help à¬à¬¹à¬¿ ସହାୟତା ଦରà­à¬¶à¬¾à¬¨à­à¬¤à­\n"
-" --version ସଂସà­à¬•ରଣ ଦରà­à¬¶à¬¾à¬¨à­à¬¤à­\n"
-"\n"
-" -v, --verbose verbose ପà­à¬°à­Ÿà­‹à¬—କୠସକà­à¬°à¬¿à­Ÿ କରନà­à¬¤à­\n"
-"\n"
-" -s, --server=SERVER ସଂଯୋଗ କରିବା ପାଇଠସରà­à¬­à¬°à¬° ନାମ\n"
-" -d, --device=DEVICE ସଂଯୋଗ କରିବା ପାଇଠସିଙà­à¬•ର ନାମ\n"
-" -n, --client-name=NAME ସରà­à¬­à¬° ଉପରେ à¬à¬¹à¬¿ ଗà­à¬°à¬¾à¬¹à¬•ଙà­à¬•ୠକିପରି ଡ଼ାକିବେ\n"
-" --stream-name=NAME ସରà­à¬­à¬° ଉପରେ à¬à¬¹à¬¿ ଧାରାକୠକିପରି ଡ଼ାକିବେ\n"
-" --volume=VOLUME ପà­à¬°à¬¾à¬°à¬®à­à¬­à¬¿à¬• (ସିଧା) ଆକାରକୠସୀମା 0...65536 "
-"ମଧà­à¬¯à¬°à­‡ ଉଲà­à¬²à­‡à¬– କରନà­à¬¤à­\n"
-" --channel-map=CHANNELMAP ବà­à­Ÿà¬¬à¬¹à¬¾à¬° ପାଇଠଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ªà¬•ୠସେଟ କରନà­à¬¤à­\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"libpulse %s ସହିତ ସଂକଳିତ\n"
-"libpulse %s ସହିତ ସଂଯà­à¬•à­à¬¤\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "ଅବୈଧ ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "ଫାଇଲ '%s' କୠଖୋଲିବାରେ ବିଫଳ\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "ଚà­à­Ÿà¬¾à¬¨à­‡à¬² ମà­à­Ÿà¬¾à¬ª ଫାଇଲ ସହିତ ମେଳ ଖାଉନାହିà¬à¥¤\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "ନମà­à¬¨à¬¾ spec '%s' ବà­à­Ÿà¬¬à¬¹à¬¾à¬° କରି\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "autospawn ଅପରିବରà­à¬¤à­à¬¤à¬¨à­€à­Ÿà¬¤à¬¾à¬•ୠଅଭିଗମà­à­Ÿ କରିହେଉ ନାହିà¬"
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2391,7 +2417,7 @@ msgstr ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2408,34 +2434,259 @@ msgstr ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "ଫଳାଫଳ %s + ନିବେଶ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "ଫଳାଫଳ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "ନିବେଶ %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "ଅଫ"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "ଉଚà­à¬š ଫିଡିଲିଟି ପଛଚଲା (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "ଉଚà­à¬š ଫିଡିଲିଟି ପଛଚଲା (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "ଟେଲିଫୋନି ଡà­à­Ÿà­à¬ªà­à¬²à­‡à¬•à­à¬¸ (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio ଧà­à­±à¬¨à¬¿ ସରà­à¬­à¬°"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "ଫଳାଫଳ ଉପକରଣ"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ନିବେଶ ଉପକରଣ"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ ରେ ଧà­à­±à¬¨à¬¿"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "ନିବେଶ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ଡକିଙà­à¬— ଷà­à¬Ÿà­‡à¬¸à¬¨ ନିବେଶ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ଡକିଙà­à¬— ଷà­à¬Ÿà­‡à¬¸à¬¨ ମାଇକà­à¬°à­‹à¬«à­‹à¬¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "ଲାଇନ-ଇନ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "ମାଇକà­à¬°à­‹à¬«à­‹à¬¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "ବାହà­à­Ÿ ମାଇକà­à¬°à­‹à¬«à­‹à¬¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "ଆଭà­à­Ÿà¬¨à­à¬¤à¬°à­€à¬£ ମାଇକà­à¬°à­‹à¬«à­‹à¬¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "ରେଡିଓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "ଭିଡ଼ିଓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "ସà­à­±à­Ÿà¬‚ଚାଳିତ ଲାଭ ନିୟନà­à¬¤à­à¬°à¬£"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "କୌଣସି ସà­à­±à­Ÿà¬‚ଚାଳିତ ଲାଭ ନିୟନà­à¬¤à­à¬°à¬£ ନାହିà¬"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "ବୃଦà­à¬§à¬¿"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "ବୃଦà­à¬§à¬¿ ନାହିà¬"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "à¬à¬®à­à¬ªà­à¬²à¬¿à¬«à¬¾à­Ÿà¬°"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "à¬à¬®à­à¬ªà­à¬²à¬¿à¬«à¬¾à­Ÿà¬° ନାହିà¬"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "ବୃଦà­à¬§à¬¿"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "ବୃଦà­à¬§à¬¿ ନାହିà¬"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ହେଡ଼ଫୋନଗà­à¬¡à¬¼à¬¿à¬•"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ନିବେଶ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ମାଇକà­à¬°à­‹à¬«à­‹à¬¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଲାଇନ-ଇନ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ରେଡ଼ିଓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଭିଡ଼ିଓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଫଳାଫଳ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ହେଡ଼ଫୋନଗà­à¬¡à¬¼à¬¿à¬•"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଫଳାଫଳ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ମୋନୋ ଫଳାଫଳ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଷà­à¬Ÿà­‡à¬°à¬¿à¬“"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ମୋନୋ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଷà­à¬Ÿà­‡à¬°à¬¿à¬“"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "ଡିଜିଟାଲ ଷà­à¬Ÿà­‡à¬°à¬¿à¬“ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "ଡିଜିଟାଲ ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "ଡିଜିଟାଲ ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "ଡିଜିଟାଲ ଚତà­à¬ƒ ପାରà­à¬¶à­à­± 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "ଡିଜିଟାଲ ଷà­à¬Ÿà­‡à¬°à¬¿à¬“ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ମୋନୋ ଡ଼à­à¬ªà­à¬²à­‡à¬•à­à¬¸"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "à¬à¬¨à¬¾à¬²à­‹à¬— ଷà­à¬Ÿà­‡à¬°à¬¿à¬“ ଡ଼à­à¬ªà­à¬²à­‡à¬•à­à¬¸"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ଡିଜିଟାଲ ଷà­à¬Ÿà­‡à¬°à¬¿à¬“ ଡ଼à­à¬ªà­à¬²à­‡à¬•à­à¬¸ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "ନିମà­à¬¨ ଆବୃତà­à¬¤à¬¿ ପରିତà­à­Ÿà¬¾à¬— କାରୀ"
diff --git a/po/pa.po b/po/pa.po
index eabd2175..1cc19e7d 100644
--- a/po/pa.po
+++ b/po/pa.po
@@ -1,67 +1,30 @@
-# translation of pulseaudio.master-tx.po to Punjabi
+# translation of pulseaudio.master-tx.pa.po to Punjabi
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Amanpreet Singh Alam <aalam@users.sf.net>, 2008.
+# Jaswinder Singh <jsingh@redhat.com>, 2009.
+# A S Alam <aalam@users.sf.net>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio.master-tx\n"
+"Project-Id-Version: pulseaudio.master-tx.pa\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2008-12-24 09:37+0530\n"
-"Last-Translator: Amanpreet Singh Alam <aalam@users.sf.net>\n"
-"Language-Team: Punjabi <punjabi-l10n@users.sf.net>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-08 15:04+0530\n"
+"Last-Translator: Jaswinder Singh <jsingh@redhat.com>\n"
+"Language-Team: Punjabi/Panjabi <kde-i18n-doc@kde.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Generator: KBabel 1.11.4\n"
+"X-Generator: Lokalize 1.0\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr ""
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -69,8 +32,10 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_avail() ਤੋਂ ਇੱਕ ਮà©à©±à¨² ਮਿਲਿਆ ਹੈ, ਜੋ ਬਹà©à¨¤ ਵੱਡਾ ਹੈ: %lu ਬਾਈਟ (%lu ms)।\n"
+"ਇਹ ALSA ਡਰਾਈਵਰ '%s' ਵਿਚਲਾ ਬੱਗ ਲੱਗਦਾ ਹੈ। ਇਸ ਮà©à©±à¨¦à©‡ ਦੀ ALSA ਡਿਵੈਲਪਰਾਂ ਨੂੰ ਰਿਪੋਰਟ ਦਿਓ ਜੀ।"
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -78,8 +43,10 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_delay() ਤੋਂ ਇੱਕ ਮà©à©±à¨² ਮਿਲਿਆ ਹੈ, ਜੋ ਬਹà©à¨¤ ਵੱਡਾ ਹੈ: %li ਬਾਈਟ (%s%lu ms)।\n"
+"ਇਹ ALSA ਡਰਾਈਵਰ '%s' ਵਿਚਲਾ ਬੱਗ ਲੱਗਦਾ ਹੈ। ਇਸ ਮà©à©±à¨¦à©‡ ਦੀ ALSA ਡਿਵੈਲਪਰਾਂ ਨੂੰ ਰਿਪੋਰਟ ਦਿਓ ਜੀ।"
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -87,419 +54,378 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"snd_pcm_mmap_begin() ਤੋਂ ਇੱਕ ਮà©à©±à¨² ਮਿਲਿਆ ਹੈ, ਜੋ ਬਹà©à¨¤ ਵੱਡਾ ਹੈ: %lu ਬਾਈਟ (%lu ms)।\n"
+"ਇਹ ALSA ਡਰਾਈਵਰ '%s' ਵਿਚਲਾ ਬੱਗ ਲੱਗਦਾ ਹੈ। ਇਸ ਮà©à©±à¨¦à©‡ ਦੀ ALSA ਡਿਵੈਲਪਰਾਂ ਨੂੰ ਰਿਪੋਰਟ ਦਿਓ ਜੀ।"
-#: ../src/pulsecore/sink.c:2141
-#, fuzzy
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "ਹਮੇਸ਼ਾਂ ਘੱਟੋ-ਘੱਟ ਇੱਕ ਸਿੰਕ ਲੋਡ ਹੀ ਰੱਖੋ ਭਾਵੇਂ ਇਹ ਇੱਕ ਜ਼ੀਰੋ (null) ਹੇਵੋ"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ਡੰਮੀ ਆਊਟਪà©à©±à¨Ÿ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "ਵਰਚà©à¨…ਲ LADSPA ਸਿੰਕ"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "ਕਲਾਕਡ NULL ਸਿੰਕ"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "ਜ਼ੀਰੋ (Null) ਆਉਟਪà©à©±à¨Ÿ"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
-msgstr "ਅੰਦਰੂਨੀ ਗਲਤੀ"
+msgstr "ਅੰਦਰੂਨੀ ਆਡੀਓ"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
-msgstr ""
+msgstr "ਮਾਡਮ"
#: ../src/daemon/ltdl-bind-now.c:124
msgid "Failed to find original lt_dlopen loader."
-msgstr ""
+msgstr "ਅਸਲੀ lt_dlopen ਲੋਡਰ ਲੱਭਣ ਵਿੱਚ ਫੇਲà©à¨¹ ਹੋਇਆ।"
#: ../src/daemon/ltdl-bind-now.c:129
-#, fuzzy
msgid "Failed to allocate new dl loader."
-msgstr "ਸਾਊਂਡ ਫਾਇਲ ਖੋਲà©à¨¹à¨£ ਲਈ ਫੇਲà©à¨¹ ਹੈ।\n"
+msgstr "ਨਵਾਂ dl ਲੋਡਰ ਦੇਣ ਲਈ ਫੇਲà©à¨¹à¥¤"
#: ../src/daemon/ltdl-bind-now.c:142
msgid "Failed to add bind-now-loader."
-msgstr ""
+msgstr "ਬਾਈਂਡ-ਨਾਓ-ਲੋਡਰ ਜੋੜਨ ਵਿੱਚ ਫੇਲà©à¨¹ ਹੋਇਆ।"
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr ""
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr ""
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr ""
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr ""
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr ""
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr ""
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr ""
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
-msgstr ""
+msgstr "%s ਸਿਗਨਲ ਮਿਲਿਆ ਹੈ।"
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "ਬੰਦ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ।"
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
-msgstr ""
+msgstr "'%s' ਯੂਜ਼ਰ ਲੱਭਣ ਵਿੱਚ ਫੇਲà©à¨¹ ਹੋਇਆ ਹੈ।"
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
-msgstr ""
+msgstr "'%s' ਗਰà©à©±à¨ª ਲੱਭਣ ਵਿੱਚ ਫੇਲ ਹੋਇਆ ਹੈ।"
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
-msgstr ""
+msgstr "ਯੂਜ਼ਰ '%s' (UID %lu) ਅਤੇ ਗਰà©à©±à¨ª '%s' (GID %lu) ਲੱਭੇ ਹਨ।"
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
-msgstr ""
+msgstr "ਯੂਜ਼ੂ '%s' ਅਤੇ ਗਰà©à©±à¨ª '%s' ਦਾ GID ਮੇਲ ਨਹੀਂ ਖਾਂਦੇ।"
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
-msgstr ""
+msgstr "ਯੂਜ਼ੂ '%s' ਦੀ ਘਰ ਡਾਇਰੈਕਟਰੀ '%s' ਨਹੀਂ, ਅਣਡਿੱਠਾ ਕਰ ਰਿਹਾ।"
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
-msgstr ""
+msgstr "'%s' ਬਣਾਉਣ ਵਿੱਚ ਫੇਲà©à¨¹: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
-msgstr ""
+msgstr "ਗਰà©à©±à¨ª ਲਿਸਟ ਬਦਲਣ ਲਈ ਫੇਲà©à¨¹: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
-msgstr ""
+msgstr "GID ਬਦਲਣ ਲਈ ਫੇਲà©à¨¹: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
-msgstr ""
+msgstr "UID ਬਦਲਣ ਲਈ ਫੇਲà©à¨¹: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
-msgstr ""
+msgstr "ਰੂਟ ਅਧਿਕਾਰ ਸਫਲਤਾਪੂਰਕ ਹਟਾਠਗà¨à¥¤"
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
-msgstr ""
+msgstr "ਇਸ ਪਲੇਟਫਾਰਮ ਤੇ ਸਿਸਟਮ ਸੰਬੰਧੀ ਮੋਡ ਨੂੰ ਸਹਿਯੋਗ ਨਹੀਂ ਹੈ।"
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
-msgstr ""
+msgstr "setrlimit(%s, (%u, %u)) ਫੇਲà©à¨¹ ਹੋਇਆ: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
-msgstr ""
-
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr ""
+msgstr "ਕਮਾਂਡ ਲਾਈਨ ਪਾਰਸ ਕਰਨ ਵਿੱਚ ਫੇਲà©à¨¹à¥¤"
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:556
-#, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr ""
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO failed: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr ""
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
-msgstr ""
+msgstr "ਡੈਮਨ ਚੱਲ ਨਹੀਂ ਰਿਹਾ"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
-msgstr ""
+msgstr "ਡੈਮਨ PID %u ਤੌਰ ਤੇ ਚੱਲ ਰਿਹਾ ਹੈ"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
-msgstr ""
+msgstr "ਡੈਮਨ ਖਤਮ ਕਰਨ ਵਿੱਚ ਫੇਲà©à¨¹: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
-msgstr ""
+msgstr "ਇਹ ਪਰੋਗਰਾਮ ਰੂਟ ਦੇ ਤੌਰ ਤੇ ਚਲਾਉਣ ਲਈ ਨਹੀਂ ਹੈ (ਜਦੋਂ ਤੱਕ --system ਦਿੱਤਾ ਨਹੀਂ ਜਾਂਦਾ)।"
-#: ../src/daemon/main.c:720
-#, fuzzy
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "ਰੂਟ ਅਧਿਕਾਰਾਂ ਦੀ ਲੋੜ ਹੈ।"
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
+msgstr "--start ਨੂੰ ਸਿਸਟਮ ਮੌਕਿਆਂ ਲਈ ਸਹਿਯੋਗ ਨਹੀਂ ਹੈ।"
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
msgstr ""
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
-msgstr ""
+msgstr "ਸਿਸਟਮ ਮੋਡ ਵਿੱਚ ਚੱਲ ਰਿਹਾ ਹੈ, ਪਰ --disallow-exit ਸੈੱਟ ਨਹੀਂ ਕੀਤਾ!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
-msgstr ""
+msgstr "ਸਿਸਟਮ ਮੋਡ ਵਿੱਚ ਚੱਲ ਰਿਹਾ ਹੈ, ਪਰ --disallow-module-loading ਸੈੱਟ ਨਹੀਂ ਕੀਤਾ!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
-msgstr ""
+msgstr "ਸਿਸਟਮ ਮੋਡ ਵਿੱਚ ਚੱਲ ਰਿਹਾ ਹੈ, ਜ਼ਬਰਦਸਤੀ SHM ਮੋਡ ਨੂੰ ਅਯੋਗ ਕਰ ਰਿਹਾ ਹੈ!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
-msgstr ""
+msgstr "ਸਿਸਟਮ ਮੋਡ ਵਿੱਚ ਚੱਲ ਰਿਹਾ ਹੈ, ਜ਼ਬਰਦਸਤੀ idle ਟਾਈਲ ਬੰਦ ਨੂੰ ਅਯੋਗ ਕਰ ਰਿਹਾ ਹੈ!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
-msgstr ""
+msgstr "ਸਟੂਡੀਓ ਪà©à¨°à¨¾à¨ªà¨¤ ਕਰਨ ਵਿੱਚ ਫੇਲà©à¨¹à¥¤"
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
-msgstr "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "pipe ਫੇਲà©à¨¹: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
-msgstr ""
+msgstr "ਡੈਮਨ ਸ਼à©à¨°à©‚ਆਤੀ ਫੇਲà©à¨¹ ਹੋਈ।"
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
-msgstr ""
+msgstr "ਡੈਮਨ ਸ਼à©à¨°à©‚ਆਤੀ ਸਫ਼ਲ ਹੋਈ।"
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() ਫੇਲà©à¨¹ ਹੈ: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
-msgstr ""
+msgstr "ਇਹ ਪਲਸਆਡੀਓ %s ਹੈ"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
-msgstr ""
+msgstr "ਕੰਪਾਈਲੇਸ਼ਨ ਹੋਸਟ: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
-msgstr ""
+msgstr "ਕੰਪਾਈਲੇਸ਼ਨ CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
-msgstr ""
+msgstr "ਹੋਸਟ ਤੇ ਚੱਲ ਰਿਹਾ ਹੈ: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
-msgstr ""
+msgstr "%u CPUs ਲੱਭੇ।"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
-msgstr ""
+msgstr "ਪੇਜ਼ ਸਾਈਜ਼ %lu ਬਾਈਟ ਹੈ"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
-msgstr ""
+msgstr "Valgrind ਸਹਿਯੋਗ ਨਾਲ ਕੰਪਾਈਲ: ਹਾਂ"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
-msgstr ""
+msgstr "Valgrind ਸਹਿਯੋਗ ਨਾਲ ਕੰਪਾਈਲ: ਨਹੀਂ"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
-msgstr ""
+msgstr "Valgrind ਮੋਡ ਵਿੱਚ ਚੱਲ ਰਿਹਾ ਹੈ: %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "ਹੋਸਟ ਤੇ ਚੱਲ ਰਿਹਾ ਹੈ: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
-msgstr ""
+msgstr "ਓਪਟੀਮਾਈਜ਼ਡ ਬਿਲਡ: ਹਾਂ"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
-msgstr ""
+msgstr "ਓਪਟੀਮਾਈਜ਼ਡ ਬਿਲਡ: ਨਹੀਂ"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr ""
+msgstr "NDEBUG ਪਰਿਭਾਸ਼ਤ, ਸਭ asserts ਅਯੋਗ ਹਨ।"
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
-msgstr ""
+msgstr "FASTPATH ਪਰਿਭਾਸ਼ਤ, ਸਿਰਫ ਫਾਸਟ ਪਾਥ asserts ਅਯੋਗ ਹਨ।"
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr ""
+msgstr "ਸਭ asserts ਯੋਗ ਕੀਤੇ ਹਨ।"
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
-msgstr ""
+msgstr "ਮਸ਼ੀਨ ID ਪà©à¨°à¨¾à¨ªà¨¤ ਕਰਨ ਵਿੱਚ ਫੇਲà©à¨¹"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
-msgstr ""
+msgstr "ਮਸ਼ੀਨ ID %s ਹੈ।"
-#: ../src/daemon/main.c:913
+#: ../src/daemon/main.c:874
#, c-format
msgid "Session ID is %s."
-msgstr ""
+msgstr "ਸ਼ੈਸ਼ਨ ID %s ਹੈ।"
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
-msgstr ""
+msgstr "ਰਨਟਾਈਮ ਡਾਇਰੈਕਟਰੀ %s ਦੀ ਵਰਤੋਂ।"
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
-msgstr ""
+msgstr "ਸਟੇਟ ਡਾਇਰੈਕਟਰੀ %s ਦੀ ਵਰਤੋਂ।"
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "ਮੈਡਿਊਲ ਡਾਇਰੈਕਟਰੀ %s ਦੀ ਵਰਤੋਂ।"
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
-msgstr ""
+msgstr "ਸਿਸਟਮ ਮੋਡ ਵਿੱਚ ਚੱਲ ਰਿਹਾ ਹੈ: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"ਠੀਕ ਹੈ, ਤਾਂ ਤà©à¨¸à©€à¨‚ PA ਨੂੰ ਸਿਸਟਮ ਮੋਡ ਵਿੱਚ ਚਲਾ ਰਹੇ ਹੋ। ਕਿਰਪਾ ਕਰਕੇ ਧਿਆਨ ਰੱਖੋ ਕਿ ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇਹ ਕਰਨਾ "
+"ਨਹੀਂ ਚਾਹੀਦਾ।\n"
+"ਜੇ ਤà©à¨¸à©€à¨‚ ਅਜਿਹਾ ਕੀਤਾ ਹੈ ਤਾਂ ਇਹ ਤà©à¨¹à¨¾à¨¡à©€ ਗਲਤੀ ਹੈ ਜੇ ਲੋੜ-ਮà©à¨¤à¨¾à¨¬à¨• ਠੀਕ ਕੰਮ ਨਾ ਚੱਲਿਆ।\n"
+"ਕਿਰਪਾ ਕਰਕੇ ਸਿਸਟਮ ਮੋਡ ਦੇ ਗਲਤ ਹੋਣ ਬਾਰੇ ਵਧੇਰੇ ਜਾਣਕਾਰੀ ਲਈ http://pulseaudio.org/wiki/"
+"WhatIsWrongWithSystemMode ਵੇਖੋ।"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() ਫੇਲà©à¨¹ ਹੈ।"
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
-msgstr ""
+msgstr "ਤਾਜ਼ੀ ਹਾਈ-ਰੈਜ਼ੋਲੂਸ਼ਨ ਟਾਈਮਰ ਉਪਲੱਬਧ ਹੈ! Bon appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr ""
+"ਮਿੱਤਰਾ, ਤੇਰਾ ਕਰਨਲ ਪà©à¨°à¨¾à¨£à¨¾ ਹੈ! ਚੀਫ ਦੀ ਅੱਜ ਦੀ ਸਿਫਾਰਸ਼ ਹਾਈ-ਰੈਜ਼ੋਲੂਸ਼ਨ ਟਾਈਮਰ ਯੋਗ ਨਾਲ ਲੀਨਕਸ ਹੈ!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() ਫੇਲà©à¨¹ ਹੈ।"
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
-msgstr ""
+msgstr "ਡੈਮਨ ਸ਼à©à¨°à©‚ ਕਰਨ ਵਿੱਚ ਫੇਲà©à¨¹à¥¤"
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
-msgstr ""
+msgstr "ਡੈਮਨ ਸ਼à©à¨°à©‚ਆਤੀ ਬਿਨਾਂ ਕਿਸੇ ਲੋਡ ਕੀਤੇ ਮੈਡਿਊਲ, ਕੰਮ ਕਰਨ ਤੋਂ ਰੋਕ ਰਿਹਾ ਹੈ।"
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
-msgstr ""
+msgstr "ਡੈਮਨ ਸ਼à©à¨°à©‚ਆਤੀ ਮà©à¨•ੰਮਲ।"
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
-msgstr ""
+msgstr "ਡੈਮਨ ਬੰਦ ਕਰਨਾ ਸ਼à©à¨°à©‚ ਹੋ ਗਿਆ।"
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
-msgstr ""
+msgstr "ਡੈਮਨ ਬੰਦ ਹੋ ਗਿਆ।"
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -572,69 +498,140 @@ msgid ""
"\n"
" -n Don't load default script file\n"
msgstr ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
-msgstr ""
+msgstr "--daemonize ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
-msgstr ""
+msgstr "--fail ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
msgstr ""
+"--log-level ਨੂੰ ਲਾਗ ਲੈਵਲ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ (ਜਾਂ ਤਾਂ ਅੰਕੀ ਰੇਂਜ 0..4 ਜਾਂ debug, info, "
+"notice, warn, error ਵਿੱਚੋਂ ਇੱਕ)।"
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
-msgstr ""
+msgstr "--high-priority ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
-msgstr ""
+msgstr "--realtime ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
-msgstr ""
+msgstr "--disallow-module-loading ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr ""
+msgstr "--disallow-exit ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
-msgstr ""
+msgstr "--use-pid-file ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
-msgstr ""
+msgstr "ਗਲਤ ਲਾਗ ਟਾਰਗੇਟ: 'syslog', 'stderr' ਜਾਂ 'auto' ਵਰਤੋਂ।"
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr ""
+msgstr "--log-time ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr ""
+msgstr "--log-meta ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
-msgstr ""
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਰੀਸੈਂਪਲ ਢੰਗ '%s'।"
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
-msgstr ""
+msgstr "--system ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
-msgstr ""
+msgstr "--no-cpu-limit ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
-msgstr ""
+msgstr "--disable-shm ਨੂੰ ਬà©à¨²à©€à¨…ਨ ਆਰਗੂਮੈਂਟ ਦੀ ਲੋੜ ਹੈ"
#: ../src/daemon/dumpmodules.c:60
#, c-format
@@ -644,7 +641,7 @@ msgstr "ਨਾਂ: %s\n"
#: ../src/daemon/dumpmodules.c:63
#, c-format
msgid "No module information available\n"
-msgstr ""
+msgstr "ਕੋਈ ਮੋਡੀਊਲ ਜਾਣਕਾਰੀ ਉਪਲੱਬਧ ਨਹੀਂ\n"
#: ../src/daemon/dumpmodules.c:66
#, c-format
@@ -669,356 +666,344 @@ msgstr "ਵਰਤੋਂ: %s\n"
#: ../src/daemon/dumpmodules.c:73
#, c-format
msgid "Load Once: %s\n"
-msgstr ""
+msgstr "ਇੱਕ ਵਾਰ ਲੋਡ ਕਰੋ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "ਪਾਥ: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
-msgstr ""
+msgstr "[%s:%u] ਗਲਤ ਲਾਗ ਟਾਰਗੇਟ '%s'।"
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
-msgstr ""
+msgstr "[%s:%u] ਗਲਤੀ ਲਾਗ ਲੈਵਲ '%s'।"
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
-msgstr ""
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵੀਂ ਰੀਸੈਂਪਲ ਢੰਗ '%s'।"
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
-msgstr ""
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵੀਂ rlimit '%s'।"
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
-msgstr ""
+msgstr "[%s:%u] rlimit ਨੂੰ ਇਸ ਪਲੇਟਫਾਰਮ ਤੇ ਸਹਿਯੋਗ ਨਹੀਂ ਹੈ।"
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
-msgstr ""
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵਾਂ ਸੈਂਪਲ ਫਾਰਮੈਟ '%s'।"
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
-msgstr ""
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵਾਂ ਸੈਂਪਲ ਰੇਟ '%s'।"
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
-msgstr ""
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵਾਂ ਸੈਂਪਲ ਚੈਨਲ '%s'।"
-#: ../src/daemon/daemon-conf.c:353
-#, fuzzy, c-format
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
-msgstr "ਗਲਤ ਚੈਨਲ ਮੈਪ\n"
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵਾਂ ਚੈਨਲ ਮੈਪ '%s'।"
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
-msgstr ""
+msgstr "[%s:%u] ਫਰੈਗਮੈਂਟਾਂ ਦਾ ਅਢà©à©±à¨•ਵਾਂ ਨੰਬਰ '%s'।"
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
-msgstr ""
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵਾਂ ਫਰੈਗਮੈਂਟ ਅਕਾਰ '%s'।"
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
-msgstr ""
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵਾਂ nice ਲੈਵਲ '%s'।"
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] ਅਢà©à©±à¨•ਵਾਂ ਸੈਂਪਲ ਰੇਟ '%s'।"
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
-msgstr ""
+msgstr "ਸੰਰਚਨਾ ਫਾਇਲ ਖੋਲà©à¨¹à¨£ ਵਿੱਚ ਫੇਲà©à¨¹: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
-msgstr ""
+msgstr "ਦਿੱਤੇ ਡਿਫਾਲਟ ਚੈਨਲ ਮੈਪ ਦੀ ਦਿੱਤੇਤ ਚੈਨਲ ਗਿਣਤੀ ਨਾਲੋਂ ਇੱਕ ਵੱਖਰੀ ਚੈਨਲ ਗਿਣਤੀ ਹੈ।"
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
-msgstr ""
+msgstr "### ਸੰਰਚਨਾ ਫਾਇਲ ਵਿੱਚੋਂ ਪੜਿਆ: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr ""
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr ""
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "ਅਧਿਕਾਰ ਹਟਾ ਰਿਹਾ ਹੈ।"
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
-msgstr ""
+msgstr "ਪਲਸਆਡੀਓ ਸਾਊਂਡ ਸਿਸਟਮ"
#: ../src/daemon/pulseaudio.desktop.in.h:2
msgid "Start the PulseAudio Sound System"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
+msgstr "ਪਲਸਆਡੀਓ ਸਾਊਂਡ ਸਿਸਟਮ ਚਲਾਓ"
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "ਮੋਨੋ"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
-msgstr "ਫਰੰਟ ਸੈਂਟਰ"
+msgstr "ਅੱਗੇ ਸੈਂਟਰ"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
-msgstr ""
+msgstr "ਅੱਗੇ ਖੱਬੇ"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
-msgstr ""
+msgstr "ਅੱਗੇ ਸੱਜਾ"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
-msgstr ""
+msgstr "ਪਿੱਛੇ ਸੈਂਟਰ"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
-msgstr ""
+msgstr "ਪਿੱਛੇ ਖੱਬਾ"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
-msgstr ""
+msgstr "ਪਿੱਛੇ ਸੱਜਾ"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
msgstr ""
-#: ../src/pulse/channelmap.c:115
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
-msgstr ""
+msgstr "ਅੱਗੇ ਸੈਂਟਰ ਦਾ ਖੱਬੇ"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
-msgstr ""
+msgstr "ਅੱਗੇ ਸੈਂਟਰ ਦਾ ਸੱਜਾ"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
-msgstr ""
+msgstr "ਖੱਬੇ ਪਾਸੇ"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
-msgstr ""
+msgstr "ਸੱਜੇ ਪਾਸੇ"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "à¨à¨—ਜਿਲਰੀ 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "à¨à¨—ਜਿਲਰੀ 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "à¨à¨—ਜਿਲਰੀ 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "à¨à¨—ਜਿਲਰੀ 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "à¨à¨—ਜਿਲਰੀ 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "à¨à¨—ਜਿਲਰੀ 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "à¨à¨—ਜਿਲਰੀ 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "à¨à¨—ਜਿਲਰੀ 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "à¨à¨—ਜਿਲਰੀ 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "à¨à¨—ਜਿਲਰੀ 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "à¨à¨—ਜਿਲਰੀ 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "à¨à¨—ਜਿਲਰੀ 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "à¨à¨—ਜਿਲਰੀ 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "à¨à¨—ਜਿਲਰੀ 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "à¨à¨—ਜਿਲਰੀ 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "à¨à¨—ਜਿਲਰੀ 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "à¨à¨—ਜਿਲਰੀ 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "à¨à¨—ਜਿਲਰੀ 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "à¨à¨—ਜਿਲਰੀ 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "à¨à¨—ਜਿਲਰੀ 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "à¨à¨—ਜਿਲਰੀ 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "à¨à¨—ਜਿਲਰੀ 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "à¨à¨—ਜਿਲਰੀ 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "à¨à¨—ਜਿਲਰੀ 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "à¨à¨—ਜਿਲਰੀ 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "à¨à¨—ਜਿਲਰੀ 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "à¨à¨—ਜਿਲਰੀ 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "à¨à¨—ਜਿਲਰੀ 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "à¨à¨—ਜਿਲਰੀ 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "à¨à¨—ਜਿਲਰੀ 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "à¨à¨—ਜਿਲਰੀ 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "à¨à¨—ਜਿਲਰੀ 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "ਉੱਤੇ ਕੇਂਦਰੀ"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
-msgstr ""
+msgstr "ਉੱਤੇ ਅੱਗੇ ਸੈਂਟਰ"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
-msgstr ""
+msgstr "ਉੱਤੇ ਅੱਗੇ ਖੱਬੇ"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
-msgstr ""
+msgstr "ਉੱਤੇ ਅੱਗੇ ਸੱਜੇ"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
-msgstr ""
+msgstr "ਉੱਤੇ ਪਿੱਛੇ ਸੈਂਟਰ"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
-msgstr ""
+msgstr "ਉੱਤੇ ਪਿੱਛੇ ਖੱਬੇ"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
-msgstr ""
+msgstr "ਉੱਤੇ ਪਿੱਛੇ ਸੱਜੇ"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
-msgstr "(ਗਲਤ)"
+msgstr "(ਅਢà©à©±à¨•ਵਾਂ)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
-msgstr ""
+msgstr "ਸਟੀਰੀਓ"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
-msgstr ""
+msgstr "ਸਰਾਊਂਡਿੰਗ 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
-msgstr ""
+msgstr "ਸਰਾਊਂਡਿੰਗ 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
-msgstr ""
+msgstr "ਸਰਾਊਂਡਿੰਗ 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
-msgstr ""
+msgstr "ਸਰਾਊਂਡਿੰਗ 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
-msgstr ""
+msgstr "ਸਰਾਊਂਡਿੰਗ 7.1"
#: ../src/pulse/error.c:43
msgid "OK"
@@ -1034,15 +1019,15 @@ msgstr "ਅਣਜਾਣ ਕਮਾਂਡ"
#: ../src/pulse/error.c:46
msgid "Invalid argument"
-msgstr ""
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਆਰਗੂਮੈਂਟ"
#: ../src/pulse/error.c:47
msgid "Entity exists"
-msgstr ""
+msgstr "à¨à¨‚ਟਟੀ ਮੌਜੂਦ ਹੈ"
#: ../src/pulse/error.c:48
msgid "No such entity"
-msgstr ""
+msgstr "ਕੋਈ à¨à¨‚ਟਟੀ ਨਹੀਂ"
#: ../src/pulse/error.c:49
msgid "Connection refused"
@@ -1054,11 +1039,11 @@ msgstr "ਪਰੋਟੋਕਾਲ ਗਲਤੀ"
#: ../src/pulse/error.c:51
msgid "Timeout"
-msgstr "ਸਮਾਂ ਅੰਤਰਾਲ"
+msgstr "ਸਮਾਂ-ਸਮਾਪਤ"
#: ../src/pulse/error.c:52
msgid "No authorization key"
-msgstr ""
+msgstr "ਕੋਈ ਪà©à¨°à¨®à¨¾à¨£à¨¿à¨•ਤਾ ਕà©à©°à¨œà©€ ਨਹੀਂ"
#: ../src/pulse/error.c:53
msgid "Internal error"
@@ -1066,19 +1051,19 @@ msgstr "ਅੰਦਰੂਨੀ ਗਲਤੀ"
#: ../src/pulse/error.c:54
msgid "Connection terminated"
-msgstr ""
+msgstr "ਕà©à¨¨à©ˆà¨•ਸ਼ਨ ਖਤਮ ਕੀਤਾ"
#: ../src/pulse/error.c:55
msgid "Entity killed"
-msgstr ""
+msgstr "à¨à¨‚ਟਟੀ ਖਤਮ ਹੋ ਗਈ"
#: ../src/pulse/error.c:56
msgid "Invalid server"
-msgstr ""
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਸਰਵਰ"
#: ../src/pulse/error.c:57
msgid "Module initalization failed"
-msgstr ""
+msgstr "ਮੋਡੀਊਲ ਸ਼à©à¨°à©‚ ਕਰਨਾ ਫੇਲà©à¨¹"
#: ../src/pulse/error.c:58
msgid "Bad state"
@@ -1090,7 +1075,7 @@ msgstr "ਕੋਈ ਡਾਟਾ ਨਹੀਂ"
#: ../src/pulse/error.c:60
msgid "Incompatible protocol version"
-msgstr ""
+msgstr "ਨਾ-ਅਨà©à¨•ੂਲ ਪਰੋਟੋਕਾਲ ਵਰਜਨ"
#: ../src/pulse/error.c:61
msgid "Too large"
@@ -1106,44 +1091,52 @@ msgstr "ਅਣਜਾਣ ਗਲਤੀ ਕੋਡ"
#: ../src/pulse/error.c:64
msgid "No such extension"
-msgstr ""
+msgstr "ਕੋਈ ਅਜਿਹੀ ਇਕਸਟੈਂਸ਼ਨ ਨਹੀਂ"
#: ../src/pulse/error.c:65
msgid "Obsolete functionality"
-msgstr ""
+msgstr "ਛੱਡੀ ਗਈ ਫੰਕਸ਼ਨੈਲਿਟੀ"
#: ../src/pulse/error.c:66
msgid "Missing implementation"
-msgstr ""
+msgstr "ਗੈਰ-ਮੌਜੂਦ ਨਿਰਧਾਰਨ"
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr ""
+msgstr "ਕਲਾਇਟ ਅੱਡ ਕੀਤਾ"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "ਇੰਪà©à©±à¨Ÿ/ਆਊਟਪà©à©±à¨Ÿ ਗਲਤੀ"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "ਜਤੰਰ ਜਾਂ ਸਰੋਤ ਵਰਤੋਂ ਅਧੀਨ ਹੈ"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
-msgstr ""
+msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
-msgstr ""
+msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
-msgstr ""
+msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
-msgstr ""
+msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
-msgstr ""
+msgstr "%u B"
#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
msgid "XOpenDisplay() failed"
@@ -1151,199 +1144,193 @@ msgstr "XOpenDisplay() ਫੇਲà©à¨¹ ਹੈ"
#: ../src/pulse/client-conf-x11.c:93
msgid "Failed to parse cookie data"
-msgstr ""
+msgstr "ਕੂਕੀ ਡਾਟਾ ਪਾਰਸ ਕਰਨ ਵਿੱਚ ਫੇਲà©à¨¹"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
-msgstr ""
+msgstr "ਸੰਰਚਨਾ ਫਾਇਲ '%s' ਨੂੰ ਖੋਲà©à¨¹à¨£ ਵਿੱਚ ਫੇਲà©à¨¹: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
-msgstr ""
+msgstr "ਕੋਈ ਕੂਕੀ ਲੋਡ ਨਹੀਂ ਕੀਤੀ। ਇਸ ਤੋਂ ਬਿਨਾਂ ਕà©à¨¨à©ˆà¨•ਟ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ।"
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
-msgstr ""
+msgstr "ਅਣਜਾਣੀ ਇਕਸਟੈਂਸ਼ਨ '%s' ਲਈ ਸà©à¨¨à©‡à¨¹à¨¾ ਮਿਲਿਆ ਹੈ"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "ਸਟਰੀਮ ਡਰੇਨ ਫੇਲà©à¨¹ ਹੋਇਆ: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "ਪਲੇਬੈਕ ਸਟਰੀਮ ਡਰੇਨ ਕੀਤੀ।"
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr ""
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "ਸਰਵਰ ਨਾਲ ਕà©à¨¨à©ˆà¨•ਸ਼ਨ ਡਰੇਨ ਹੋ ਰਿਹਾ ਹੈ।"
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr ""
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr ""
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr ""
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr ""
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "ਸਟਰੀਮ ਸਫਲਤਾਪੂਰਕ ਬਣ ਗਈ ਹੈ।"
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "ਸਟਰੀਮ ਗਲਤੀ: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr ""
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr ""
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Buffer metrics: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr ""
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "ਸਧਾਰਨ spec '%s', ਚੈਨਲ ਮੈਪ '%s' ਦੀ ਵਰਤੋਂ।"
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr ""
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "%s ਜੰਤਰ ਨਾਲ ਕà©à¨¨à¨•ੈਟ ਕੀਤਾ (%u, %ssuspended)।"
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "ਸਟਰੀਮ ਸ਼à©à¨°à©‚। %s\n"
+msgid "Stream error: %s"
+msgstr "ਸਟਰੀਮ ਗਲਤੀ: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr ""
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "ਨਹੀਂ "
+msgid "Stream device suspended.%s"
+msgstr "ਸਟਰੀਮ ਜੰਤਰ ਸਸਪੈਂਡ ਕੀਤਾ ਹੈ।%s"
-#: ../src/utils/pacat.c:245
-#, fuzzy, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "ਸਟਰੀਮ ਸ਼à©à¨°à©‚। %s\n"
-
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Connection established.%s \n"
-msgstr ""
+msgid "Stream device resumed.%s"
+msgstr "ਸਟਰੀਮ ਜੰਤਰ ਮà©à©œ-ਪà©à¨°à¨¾à¨ªà¨¤ ਕੀਤਾ।%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "Stream underrun.%s"
+msgstr "ਸਟਰੀਮ ਅੰਡਰਰਨ।%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "Stream overrun.%s"
+msgstr "ਸਟਰੀਮ ਓਵਰਰਨ।%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "Stream started.%s"
+msgstr "ਸਟਰੀਮ ਸ਼à©à¨°à©‚ ਕੀਤੀ। %s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Connection failure: %s\n"
-msgstr ""
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "ਸਟਰੀਮ ਨੂੰ ਜੰਤਰ %s ਤੋਂ ਤਬਦੀਲ ਕੀਤਾ ਗਿਆ ਹੈ (%u, %ssuspended)।%s"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr ""
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "ਨਹੀਂ "
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Playback stream drained.\n"
-msgstr ""
+msgid "Stream buffer attributes changed.%s"
+msgstr "ਸਟਰੀਮ ਬਫਰ à¨à¨Ÿà¨°à©€à¨¬à¨¿à¨Šà¨Ÿ ਤਬਦੀਲ ਕੀਤੇ ਗà¨à¥¤%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Draining connection to server.\n"
-msgstr ""
+msgid "Connection established.%s"
+msgstr "ਕà©à¨¨à©ˆà¨•ਸ਼ਨ ਬਣ ਗਿਆ।%s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF ਮਿਲਿਆ।\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() ਫੇਲà©à¨¹ ਹੈ: %s"
-#: ../src/utils/pacat.c:438
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "Connection failure: %s"
+msgstr "ਕà©à¨¨à©ˆà¨•ਸ਼ਨ ਫੇਲ: %s"
-#: ../src/utils/pacat.c:459
-#, c-format
-msgid "Got signal, exiting.\n"
-msgstr ""
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF ਮਿਲਿਆ।"
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr ""
+msgid "write() failed: %s"
+msgstr "write() ਫੇਲà©à¨¹ ਹੈ: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "ਸਿਗਨਲ ਮਿਲਿਆ, ਬੰਦ ਹੋ ਰਿਹਾ ਹੈ।"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr ""
+msgid "Failed to get latency: %s"
+msgstr "ਵਕਫਾ ਪà©à¨°à¨¾à¨ªà¨¤à©€ ਫੇਲ ਹੋਈ: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "ਟਾਈਮ: %0.3f ਸਕਿੰਟ; ਵਕਫਾ: %0.0f usec।"
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() ਫੇਲà©à¨¹ ਹੈ: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1369,8 +1356,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1393,139 +1382,246 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
msgstr ""
+"pacat %s\n"
+"libpulse %s ਦੇ ਕੰਪਾਇਲ\n"
+"libpulse %s ਨਾਲ ਲਿੰਕ ਕੀਤਾ\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr ""
+msgid "Invalid client name '%s'"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਚੈਨਲ ਮੈਪ '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr ""
+msgid "Invalid stream name '%s'"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਰੀਸੈਂਪਲ ਢੰਗ '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr ""
+msgid "Invalid channel map '%s'"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਚੈਨਲ ਮੈਪ '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr ""
+msgid "Invalid latency specification '%s'"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਵਕਫਾ ਹਦਾਇਤ '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr ""
+msgid "Invalid process time specification '%s'"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਪਰੋਸੈੱਸ ਟਾਈਮ ਹਦਾਇਤ '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr ""
+msgid "Invalid property '%s'"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਰੀਸੈਂਪਲ ਢੰਗ '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "ਰਿਕਾਰਡਿੰਗ"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "ਅਣਜਾਣ ਫਾਇਲ ਫਾਰਮੈਟ %s"
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "ਪਲੇਅਬੈਕ"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਸੈਂਪਲ ਹਦਾਇਤ"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr ""
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "ਬਹà©à¨¤ ਵੱਧ ਆਰਗੂਮੈਂਟ।"
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() ਫੇਲà©à¨¹ ਹੈ।\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "ਸੈਂਪਲ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() ਫੇਲà©à¨¹ ਹੈ।\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "ਸਾਊਂਡ ਫਾਇਲ ਖੋਲà©à¨¹à¨£ ਲਈ ਫੇਲà©à¨¹ ਹੈ।"
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() ਫੇਲà©à¨¹ ਹੈ।\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "ਇੱਕ %s ਸਟਰੀਮ ਨੂੰ ਸੈਂਪਲ ਹਦਾਇਤ '%s' ਨਾਲ ਖੋਲà©à¨¹à¨¿à¨† ਜਾ ਰਿਹਾ ਹੈ।"
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() ਫੇਲà©à¨¹ ਹੈ: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ਸੈਂਪਲ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "ਇੱਕ %s ਸਟਰੀਮ ਨੂੰ ਸੈਂਪਲ ਹਦਾਇਤ '%s' ਨਾਲ ਖੋਲà©à¨¹à¨¿à¨† ਜਾ ਰਿਹਾ ਹੈ।"
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "ਚੈਨਲ ਮੈਪ ਸੈਂਪਲ ਹਦਾਇਤ ਨਾਲ ਨਹੀਂ ਮਿਲਦਾ"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "ਇੱਕ %s ਸਟਰੀਮ ਨੂੰ ਸੈਂਪਲ ਹਦਾਇਤ '%s' ਨਾਲ ਖੋਲà©à¨¹à¨¿à¨† ਜਾ ਰਿਹਾ ਹੈ।"
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() ਫੇਲà©à¨¹ ਹੈ।\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "ਇੱਕ %s ਸਟਰੀਮ ਨੂੰ ਸੈਂਪਲ ਹਦਾਇਤ '%s' ਅਤੇ ਚੈਨਲ ਮੈਪ '%s' ਨਾਲ ਖੋਲà©à¨¹à¨¿à¨† ਜਾ ਰਿਹਾ ਹੈ।"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "ਰਿਕਾਰਡਿੰਗ"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "ਪਲੇਅਬੈਕ"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() ਫੇਲà©à¨¹ ਹੈ।"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() ਫੇਲà©à¨¹ ਹੈ।"
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() ਫੇਲà©à¨¹ ਹੈ।"
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() ਫੇਲà©à¨¹ ਹੈ।\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() ਫੇਲà©à¨¹ ਹੈ: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_new() ਫੇਲà©à¨¹ ਹੈ।"
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() ਫੇਲà©à¨¹ ਹੈ।"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
-msgstr ""
+msgstr "ਸਸਪੈਂਡ ਕਰਨ ਵਿੱਚ ਫੇਲ: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
-msgstr ""
+msgstr "ਮà©à©œ-ਪà©à¨°à¨¾à¨ªà¨¤à©€ ਫੇਲ: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
-msgstr ""
+msgstr "ਚੇਤਾਵਨੀ: ਸਾਊਂਡ ਸਰਵਰ ਲੋਕਲ ਨਹੀਂ ਹੈ, ਸਸਪੈਂਡ ਨਹੀਂ ਹੋ ਰਿਹਾ।\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "ਕà©à¨¨à©ˆà¨•ਸ਼ਨ ਫੇਲ: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
-msgstr ""
+msgstr "SIGINT ਮਿਲਿਆ, ਬੰਦ ਹੋ ਰਿਹਾ ਹੈ।\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
-msgstr ""
+msgstr "ਚੇਤਾਵਨੀ: ਚਲਾਈਡ ਪਰੋਸੈੱਸ ਨੂੰ ਸਿਗਨਲ %u ਵਲੋਂ ਬੰਦ ਕੀਤਾ ਗਿਆ ਹੈ\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1536,43 +1632,89 @@ msgid ""
"to\n"
"\n"
msgstr ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
msgstr ""
+"pasuspender %s\n"
+"libpulse %s ਨਾਲ ਕੰਪਾਇਲ\n"
+"libpulse %s ਨਾਲ ਲਿੰਕ\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr ""
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() ਫੇਲà©à¨¹ ਹੈ।\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() ਫੇਲà©à¨¹ ਹੈ।\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() ਫੇਲà©à¨¹ ਹੈ।\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "ਅੰਕੜੇ ਪà©à¨°à¨¾à¨ªà¨¤à©€ ਫੇਲà©à¨¹: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
-msgstr ""
+msgstr "ਹà©à¨£ ਵਰਤੋਂ ਵਿੱਚ ਹੈ: %u ਬਲਾਕ ਵਿੱਚ ਕà©à©±à¨² %s ਬਾਈਟ ਹਨ।\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
-msgstr ""
+msgstr "ਪੂਰੇ ਲਾਈਫਟਾਈਮ ਵਿੱਚ ਜਾਰੀ ਕੀਤਾ ਗਿਆ: %u ਬਲਾਕ ਵਿੱਚ ਕà©à©±à¨² %s ਬਾਈਟ ਹਨ।\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "ਸੈਂਪਲ ਕੈਸ਼ ਸਾਈਜ਼: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr ""
+msgid "Failed to get server information: %s"
+msgstr "ਸਰਵਰ ਜਾਣਕਾਰੀ ਪà©à¨°à¨¾à¨ªà¨¤ ਕਰਨ ਵਿੱਚ ਫੇਲ ਹੋਇਆ: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
"User name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
@@ -1582,14 +1724,13 @@ msgid ""
"Default Sink: %s\n"
"Default Source: %s\n"
"Cookie: %08x\n"
-msgstr ""
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr ""
+msgid "Failed to get sink information: %s"
+msgstr "ਸਿੰਕ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲà©à¨¹: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1610,13 +1751,40 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr ""
+msgid "\tPorts:\n"
+msgstr "\tਪੋਰਟ:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tਸਰਗਰਮ ਪੋਰਟ: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "ਸਰੋਤ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1637,21 +1805,38 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
-msgstr "n/a"
+msgstr "ਉਪਲੱਬਧ ਨਹੀਂ"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr ""
+msgid "Failed to get module information: %s"
+msgstr "ਮੋਡੀਊਲ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1661,13 +1846,19 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr ""
+msgid "Failed to get client information: %s"
+msgstr "ਕਲਾਇਟ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1676,13 +1867,18 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr ""
+msgid "Failed to get card information: %s"
+msgstr "ਕਾਰਡ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1692,23 +1888,29 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
-msgstr ""
+msgstr "\tਪਰੋਫਾਈਲ:\n"
-#: ../src/utils/pactl.c:434
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:498
+#, c-format
msgid "\tActive Profile: %s\n"
-msgstr "pipe failed: %s"
+msgstr "\tਸਰਗਰਮ ਪਰੋਫਾਈਲ: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr ""
+msgid "Failed to get sink input information: %s"
+msgstr "ਇੰਪà©à©±à¨Ÿ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲà©à¨¹: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1728,13 +1930,29 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr ""
+msgid "Failed to get source output information: %s"
+msgstr "ਸਰੋਤ ਆਉਟਪà©à©±à¨Ÿ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1750,13 +1968,25 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr ""
+msgid "Failed to get sample information: %s"
+msgstr "ਸੈਂਪਲ ਜਾਣਕਾਰੀ ਲੈਣ ਵਿੱਚ ਫੇਲ: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -1773,24 +2003,94 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "ਫੇਲà©à¨¹: %s\n"
+msgid "Failure: %s"
+msgstr "ਫੇਲà©à¨¹: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "ਸੈਂਪਲ ਅੱਪਲੋਡ ਕਰਨ ਵਿੱਚ ਫੇਲ: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "ਫਾਇਲ ਦਾ ਸਮੇਂ ਤੋਂ ਪਹਿਲਾਂ ਅੰਤ"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
msgstr ""
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਸਰਵਰ"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT ਮਿਲਿਆ, ਬੰਦ ਹੋ ਰਿਹਾ ਹੈ।"
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -1798,13 +2098,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -1814,83 +2123,147 @@ msgid ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
msgstr ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
msgstr ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "ਲੋਡ ਕਰਨ ਲਈ ਸੈਂਪਲ ਫਾਇਲ ਦਿਓ\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "ਲੋਡ ਕਰਨ ਲਈ ਸੈਂਪਲ ਫਾਇਲ ਦਿਓ"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "ਸਾਊਂਡ ਫਾਇਲ ਖੋਲà©à¨¹à¨£ ਲਈ ਫੇਲà©à¨¹ ਹੈ।\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "ਸਾਊਂਡ ਫਾਇਲ ਖੋਲà©à¨¹à¨£ ਲਈ ਫੇਲà©à¨¹ ਹੈ।"
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr ""
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "ਇੱਕ %s ਸਟਰੀਮ ਨੂੰ ਸੈਂਪਲ ਹਦਾਇਤ '%s' ਨਾਲ ਖੋਲà©à¨¹à¨¿à¨† ਜਾ ਰਿਹਾ ਹੈ।"
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr ""
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "ਖੇਡਣ ਲਈ ਤà©à¨¹à¨¾à¨¨à©‚à©° ਸੈਂਪਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr ""
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "ਹਟਾਉਣ ਲਈ ਤà©à¨¹à¨¾à¨¨à©‚à©° ਸੈਂਪਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr ""
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੰਪà©à©±à¨Ÿ ਲਿਸਟ ਅਤੇ ਇੱਕ ਸਿੰਕ ਨੂੰ ਸਿੰਕ ਕਰਨਾ ਪਵੇਗਾ"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr ""
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਸਰੋਤ ਆਉਟਪà©à©±à¨Ÿ ਲਿਸਟ ਅਤੇ ਇੱਕ ਸਰੋਤ ਦੇਣਾ ਪਵੇਗਾ"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr ""
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਮੋਡੀਊਲ ਨਾਂ ਅਤੇ ਆਰਗੂਮੈਂਟ ਦੇਣਾ ਪਵੇਗਾ।"
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਮੈਡੀਊਲ ਲਿਸਟ ਦੇਣੀ ਪਵੇਗੀ"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr "ਤà©à¨¸à©€à¨‚ ਇੱਕ ਤੋਂ ਵੱਧ ਸਿੰਕ ਨਹੀਂ ਦੇ ਸਕਦੇ। ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਬà©à¨²à©€à¨…ਨ ਮà©à©±à¨² ਦੇਣਾ ਪਵੇਗਾ।"
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr ""
+"value."
+msgstr "ਤà©à¨¸à©€à¨‚ ਇੱਕ ਤੋਂ ਵੱਧ ਸਰੋਤ ਨਹੀਂ ਦੇ ਸਕਦੇ। ਤà©à¨¹à¨¾à¨¨à©‚à©° ਬà©à¨²à©€à¨…ਨ ਮà©à©±à¨² ਦੇਣਾ ਪਵੇਗਾ।"
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr ""
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਕਾਰਡ ਨਾਂ/ਲਿਸਟ ਅਤੇ ਪਰੋਫਾਈਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr ""
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਕਾਰਡ ਨਾਂ/ਲਿਸਟ ਅਤੇ ਪਰੋਫਾਈਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() ਫੇਲà©à¨¹ ਹੈ: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਕਾਰਡ ਨਾਂ/ਲਿਸਟ ਅਤੇ ਪਰੋਫਾਈਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਕਾਰਡ ਨਾਂ/ਲਿਸਟ ਅਤੇ ਪਰੋਫਾਈਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਸੈਂਪਲ ਹਦਾਇਤ"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਕਾਰਡ ਨਾਂ/ਲਿਸਟ ਅਤੇ ਪਰੋਫਾਈਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੰਪà©à©±à¨Ÿ ਲਿਸਟ ਅਤੇ ਇੱਕ ਸਿੰਕ ਨੂੰ ਸਿੰਕ ਕਰਨਾ ਪਵੇਗਾ"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "ਅਢà©à©±à¨•ਵੀਂ ਸਿੰਕ ਇੰਪà©à©±à¨Ÿ ਸੂਚੀ"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਕਾਰਡ ਨਾਂ/ਲਿਸਟ ਅਤੇ ਪਰੋਫਾਈਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੱਕ ਕਾਰਡ ਨਾਂ/ਲਿਸਟ ਅਤੇ ਪਰੋਫਾਈਲ ਨਾਂ ਦੇਣਾ ਪਵੇਗਾ"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "ਤà©à¨¹à¨¾à¨¨à©‚à©° ਇੰਪà©à©±à¨Ÿ ਲਿਸਟ ਅਤੇ ਇੱਕ ਸਿੰਕ ਨੂੰ ਸਿੰਕ ਕਰਨਾ ਪਵੇਗਾ"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "ਅਢà©à©±à¨•ਵਾਂ ਸੈਂਪਲ ਹਦਾਇਤ"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "ਕੋਈ ਯੋਗ ਕਮਾਂਡ ਨਹੀਂ ਦਿੱਤੀ।"
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -1903,11 +2276,18 @@ msgid ""
"variables and cookie file.\n"
" -r Remove PulseAudio data from X11 display\n"
msgstr ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
#: ../src/utils/pax11publish.c:94
#, c-format
msgid "Failed to parse command line.\n"
-msgstr ""
+msgstr "ਕਮਾਂਡ ਲਾਈਨ ਪਾਰਸ ਕਰਨ ਵਿੱਚ ਫੇਲà©à¨¹à¥¤\n"
#: ../src/utils/pax11publish.c:108
#, c-format
@@ -1922,7 +2302,7 @@ msgstr "ਸਰੋਤ: %s\n"
#: ../src/utils/pax11publish.c:112
#, c-format
msgid "Sink: %s\n"
-msgstr ""
+msgstr "ਸਿੰਕ: %s\n"
#: ../src/utils/pax11publish.c:114
#, c-format
@@ -1932,141 +2312,80 @@ msgstr "ਕੂਕੀਜ਼: %s\n"
#: ../src/utils/pax11publish.c:132
#, c-format
msgid "Failed to parse cookie data\n"
-msgstr ""
+msgstr "ਕੂਕੀ ਡਾਟਾ ਪਾਰਸ ਕਰਨ ਵਿੱਚ ਫੇਲ\n"
#: ../src/utils/pax11publish.c:137
#, c-format
msgid "Failed to save cookie data\n"
-msgstr ""
+msgstr "ਕੂਕੀ ਡਾਟਾ ਸੰਭਾਲਣ ਵਿੱਚ ਫੇਲ\n"
#: ../src/utils/pax11publish.c:152
#, c-format
msgid "Failed to load client configuration file.\n"
-msgstr ""
+msgstr "ਕਲਾਇਟ ਸੰਰਚਨਾ ਫਾਇਲ ਲੋਡ ਕਰਨ ਵਿੱਚ ਫੇਲ।\n"
#: ../src/utils/pax11publish.c:157
#, c-format
msgid "Failed to read environment configuration data.\n"
-msgstr ""
+msgstr "ਇੰਵਾਇਰਨਮੈਂਟ ਸੰਰਚਨਾ ਡਾਟਾ ਪੜà©à¨¹à¨¨ ਵਿੱਚ ਫੇਲà©à¨¹à¥¤\n"
#: ../src/utils/pax11publish.c:174
#, c-format
msgid "Failed to get FQDN.\n"
-msgstr ""
+msgstr "FQDN ਪà©à¨°à¨¾à¨ªà¨¤ ਕਰਨ ਵਿੱਚ ਫੇਲ।\n"
#: ../src/utils/pax11publish.c:194
#, c-format
msgid "Failed to load cookie data\n"
-msgstr ""
+msgstr "ਕੂਕੀ ਡਾਟਾ ਲੋਡ ਕਰਨ ਵਿੱਚ ਫੇਲ\n"
#: ../src/utils/pax11publish.c:211
#, c-format
msgid "Not yet implemented.\n"
msgstr "ਹਾਲੇ ਬਣਾਇਆ ਨਹੀਂ।\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "ਕੋਈ ਪਲਸ-ਆਡੀਓ ਡੈਮਨ ਨਹੀਂ ਚੱਲ ਰਿਹਾ, ਜਾਂ ਸ਼ੈਸ਼ਨ ਡੈਮਨ ਤੌਰ ਤੇ ਨਹੀਂ ਚੱਲ ਰਿਹਾ।"
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
-msgstr ""
+msgstr "ਪਲਸਆਡੀਓ ਡੈਮਨ ਬੰਦ ਕਰਨ ਵਿੱਚ ਫੇਲ।"
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "ਡੈਮਨ ਜਵਾਬ ਨਹੀਂ ਦੇ ਰਹੀ।"
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "ਸਟਰੀਮ ਠੀਕ ਤਰà©à¨¹à¨¾à¨‚ ਬਣਾਈ ਗਈ।\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "ਸਟਰੀਮ ਗਲਤੀ: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "ਕà©à¨¨à©ˆà¨•ਸ਼ਨ ਬਣਾਇਆ ਗਿਆ।\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "ਗਲਤ ਚੈਨਲ ਮੈਪ\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr ""
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr ""
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
-msgstr ""
+msgstr "autospawn ਲਾਕ ਵਰਤ ਨਹੀਂ ਸਕਦਾ।"
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2076,8 +2395,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2087,44 +2412,266 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
-msgstr ""
+msgstr "ਬੰਦ"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr ""
+msgstr "ਹਾਈ ਫਡੈਲਿਟੀ ਪਲੇਅਬੈਕ (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "ਹਾਈ ਫਡੈਲਿਟੀ ਪਲੇਅਬੈਕ (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
+msgstr "ਟੈਲੀਫੋਨੀ ਡà©à¨ªà¨²à©ˆà¨•ਸ (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
+msgstr "ਪਲਸਆਡੀਓ ਸਾਊਂਡ ਡਰਾਇਵਰ"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "ਆਊਟਪà©à©±à¨Ÿ ਜੰਤਰ"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ਇੰਪà©à©±à¨Ÿ ਜੰਤਰ"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ ਉੱਪਰ ਆਡੀਓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "ਇੰਪà©à©±à¨Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "ਡੌਕਿੰਗ ਸਟੇਸ਼ਨ ਇੰਪà©à©±à¨Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "ਡੌਕਿੰਗ ਸਟੇਸ਼ਨ ਮਾਈਕਰੋਫੋਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "ਲਾਈਨ-ਇਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "ਮਾਈਕਰੋਫੋਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "ਬਾਹਰੀ ਮਾਈਕਰੋਫੋਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "ਅੰਦਰੂਨੀ ਮਾਈਕਰੋਫੋਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "ਰੇਡੀਓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "ਵੀਡੀਓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "ਆਟੋਮੈਟਿਕ ਗੇਨ ਕੰਟਰੋਲ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "ਕੋਈ ਆਟੋਮੈਟਿਕ ਗੇਨ ਕੰਟਰੋਲ ਨਹੀਂ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "ਬੂਸਟ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "ਕੋਈ ਬੂਸਟ ਨਹੀਂ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "à¨à¨‚ਪਲੀਫਾਇਰ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "ਕੋਈ à¨à¨‚ਪਲੀਫਾਇਰ ਨਹੀਂ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "ਬੂਸਟ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "ਕੋਈ ਬੂਸਟ ਨਹੀਂ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
msgstr ""
-#~ msgid "pa_stream_drop() failed: %s\n"
-#~ msgstr "pa_stream_drop() ਫੇਲà©à¨¹ ਹੈ: %s\n"
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਹੈੱਡਫੋਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਇੰਪà©à©±à¨Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਮਾਈਕਰੋਫੋਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਲਾਈਨ-ਇਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਰੇਡੀਓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਵੀਡੀਓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਆਉਟਪà©à©±à¨Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਹੈੱਡਫੋਨ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਆਊਟਪà©à©±à¨Ÿ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਮੋਨੋ ਆਊਟਪà©à©±à¨Ÿ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਟੀਰੀਓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਮੋਨੋ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਟੀਰੀਓ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਰਾਊਂਡ 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "ਡਿਜ਼ੀਟਲ ਸਟੀਰੀਓ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "ਡਿਜ਼ੀਟਲ ਸਰਾਊਂਡ 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "ਡਿਜ਼ੀਟਲ ਸਰਾਊਂਡ 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "ਡਿਜ਼ੀਟਲ ਸਰਾਊਂਡ 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "ਡਿਜ਼ੀਟਲ ਸਟੀਰੀਓ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਮੋਨੋ ਡà©à¨ªà¨²à©ˆà¨•ਸ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "à¨à¨¨à¨¾à¨²à¨¾à¨— ਸਟੀਰੀਓ ਡà©à¨ªà¨²à©ˆà¨•ਸ"
-#~ msgid "muted"
-#~ msgstr "ਚà©à©±à¨ª"
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ਡਿਜ਼ੀਟਲ ਸਟੀਰੀਓ ਡà©à¨ªà¨²à©ˆà¨•ਸ (IEC958)"
-#~ msgid "source"
-#~ msgstr "ਸਰੋਤ"
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "ਘੱਟ ਫਰੀਕਿਊਂਸੀ ਇੱਮਟਰ"
diff --git a/po/pl.po b/po/pl.po
index 13516d24..b241a1cc 100644
--- a/po/pl.po
+++ b/po/pl.po
@@ -5,59 +5,20 @@ msgid ""
msgstr ""
"Project-Id-Version: pl\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-14 16:45+0200\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-09-30 17:04+0200\n"
"Last-Translator: Piotr DrÄ…g <piotrdrag@gmail.com>\n"
-"Language-Team: Polish <pl@li.org>\n"
+"Language-Team: Polish <fedora-trans-pl@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analogowe mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analogowe stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Cyfrowe stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Cyfrowe stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analogowe surround 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Cyfrowe surround 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analogowe surround 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analogowe surround 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analogowe surround 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Cyfrowe surround 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analogowe surround 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -69,7 +30,7 @@ msgstr ""
"Prawdopodobnie jest to błąd sterownika ALSA \"%s\". Proszę zgłosić ten "
"problem programistom ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -81,7 +42,7 @@ msgstr ""
"Prawdopodobnie jest to błąd sterownika ALSA \"%s\". Proszę zgłosić ten "
"problem programistom ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -93,11 +54,47 @@ msgstr ""
"Prawdopodobnie jest to błąd sterownika ALSA \"%s\". Proszę zgłosić ten "
"problem programistom ALSA."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+"Utrzymywanie zawsze co najmniej jednego wczytanego odpływu nawet, jeśli to "
+"pusty odpływ"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Głuche wyjście"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Wirtualny odpływ LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nazwa odpływu> sink_properties=<właściwości odpływu> "
+"master=<nazwa odpływu do filtrowania> format=<format próbki> "
+"rate=<częstotliwość próbki> channels=<liczba kanałów> channel_map=<mapa "
+"kanałów> plugin=<nazwa wtyczki ladspa> label=<etykieta wtyczki ladspa> "
+"control=<lista wartości kontroli wejścia oddzielona przecinkami>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Zegarowy PUSTY odpływ"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Puste wyjście"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Wewnętrzny dźwięk"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Modem"
@@ -114,222 +111,98 @@ msgstr "Przydzielenie nowego programu wczytującego dl nie powiodło się."
msgid "Failed to add bind-now-loader."
msgstr "Dodanie bind-now-loader nie powiodło się."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Nie można połączyć się z magistralą systemową: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Nie można uzyskać obiektu caller z PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Nie można ustawić UID obiektu caller."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Uzyskanie sesji CK nie powiodło się."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Nie można ustawić UID obiektowi sesji."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Nie można przydzielić PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Nie można ustawić action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Nie można przydzielić PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Nie można zainicjować PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Nie można ustalić, czy obiekt caller jest upoważniony: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Nie można uzyskać upoważnienia: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit zwróciło \"%s\""
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Otrzymano sygnał %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
-msgstr "Wyłączanie."
+msgstr "Kończenie pracy."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
-msgstr "Znalezienie użytkownika \"%s\" nie powiodło się."
+msgstr "Odnalezienie użytkownika \"%s\" nie powiodło się."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
-msgstr "Znalezienie grupy \"%s\" nie powiodło się."
+msgstr "Odnalezienie grupy \"%s\" nie powiodło się."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
-msgstr "Znaleziono użytkownika \"%s\" (UID %lu) i grupę \"%s\" (GID %lu)."
+msgstr "Odnaleziono użytkownika \"%s\" (UID %lu) i grupę \"%s\" (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID użytkownika \"%s\" i grupy \"%s\" nie zgadzają się."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
-msgstr "Folder domowy użytkownika \"%s\" nie jest \"%s\", ignorowanie."
+msgstr "Katalog domowy użytkownika \"%s\" nie jest \"%s\", ignorowanie."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Utworzenie \"%s\" nie powiodło się: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Zmiana listy grup nie powiodła się: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Zmiana GID nie powiodła się: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Zmiana UID nie powiodła się: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Pomyślnie porzucono uprawnienia roota."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "Tryb systemowy nie jest obsługiwany na tej platformie."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) nie powiodło się: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
-msgstr "Analiza wiersza poleceń nie powiodła się."
+msgstr "Przetworzenie wiersza poleceń nie powiodła się."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Jesteśmy w grupie \"%s\", co umożliwia szeregowanie o wysokim priorytecie."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Jesteśmy w grupie \"%s\", co umożliwia szeregowanie w czasie rzeczywistym."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit nadał uprawnienie \"acquire-high-priority\"."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit odmówił nadania uprawnienia \"acquire-high-priority\"."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit nadał uprawnienie \"acquire-real-time\"."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit odmówił nadania uprawnienia \"acquire-real-time\"."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"W konfiguracji zażądano SUID roota i szeregowanie w czasie rzeczywistym i/"
-"lub o wysokim priorytecie. Brak wymaganych uprawnień:\n"
-"Nie jesteśmy w grupie \"%s\", PolicyKit odmawia przyznania żądanych "
-"uprawnień i brak ograniczeń zwiększania zasobów RLIMIT_NICE/RLIMIT_RTPRIO.\n"
-"Aby włączyć szeregowanie w czasie rzeczywistym i/lub o wysokim priorytecie, "
-"należy uzyskać odpowiednie uprawnienia PolicyKit, zostać członkiem grupy \"%s"
-"\" lub zwiększyć ograniczenia zasobów RLIMIT_NICE/RLIMIT_RTPRIO dla tego "
-"użytkownika."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Szeregowanie o wysokim priorytecie jest włączone w konfiguracji, ale nie "
-"jest zezwolone przez politykÄ™."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "Pomyślnie zwiększono RLIMIT_RTPRIO"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO nie powiodło się: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Oddawanie CAP_NICE"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"Szeregowanie w czasie rzeczywistym jest włączone w konfiguracji, ale nie "
-"jest zezwolone przez politykÄ™."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Demon nie jest uruchomiony"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Demon jest uruchomiony jako PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Zniszczenie demona nie powiodło się: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -337,195 +210,231 @@ msgstr ""
"Ten program nie powinien być uruchomiany jako root (chyba, że podano --"
"system)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Wymagane sÄ… uprawnienia roota."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start nie jest obsługiwane przy uruchamianiu systemowym."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
-"Uruchamianie w trybie systemowym, ale --disallow-exit nie jest ustawione!"
+"Uruchamianie w trybie systemowym, ale --disallow-exit nie jest ustawione."
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"Uruchamianie w trybie systemowym, ale --disallow-module-loading nie jest "
-"ustawione!"
+"ustawione."
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
-msgstr "Uruchamianie w trybie systemowym, wymuszanie wyłączenia trybu SHM!"
+msgstr "Uruchamianie w trybie systemowym, wymuszanie wyłączenia trybu SHM."
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"Uruchamianie w trybie systemowym, wymuszanie wyłączenia czasu oczekiwania na "
-"zakończenie!"
+"zakończenie."
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Uzyskanie standardowego wejścia/wyjścia nie powiodło się."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "potok nie powiódł się: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() nie powiodło się: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() nie powiodło się: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Uruchomienie demona nie powiodło się."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Pomyślnie uruchomiono demona."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() nie powiodło się: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "To jest PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Komputer kompilacji: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "CFLAGS kompilacji: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Uruchamianie na komputerze: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
-msgstr "Znaleziono %u procesorów."
+msgstr "Odnaleziono %u procesorów."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "Rozmiar strony to %lu bajtów"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Skompilowano z obsługą Valgrind: tak"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Skompilowano z obsługą Valgrind: nie"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Uruchamianie w trybie Valgrind: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Uruchamianie na komputerze: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Budowanie optymalizowane: tak"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Budowanie optymalizowane: nie"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "Podano NDEBUG, wszystkie asercje zostały wyłączone."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "Podano FASTPATH, tylko szybkie asercje ścieżek zostały wyłączone."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Wszystkie asercje są włączone."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Uzyskanie identyfikatora komputera nie powiodło się"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "Identyfikator komputera to %s."
-#: ../src/daemon/main.c:913
+#: ../src/daemon/main.c:874
#, c-format
msgid "Session ID is %s."
msgstr "Identyfikator sesji to %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
-msgstr "Używanie folderu wykonywania %s."
+msgstr "Używanie katalogu wykonywania %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
-msgstr "Używanie folderu stanu %s."
+msgstr "Używanie katalogu stanu %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Używanie katalogu modułów %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Uruchamianie w trybie systemowym: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"OK, więc PA jest uruchomione w trybie systemowym. Proszę zauważyć, że "
+"prawdopodobnie tak nie powinno być.\n"
+"Jeśli mimo to tak jest, to wina użytkownika, jeśli coś nie działa tak jak "
+"powinno.\n"
+"Proszę przeczytać http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode, "
+"gdzie wyjaśniono, dlaczego tryb systemowy jest zwykle złym pomysłem."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() nie powiodło się."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Świeże zegary o wysokiej rozdzielczości! Smacznego!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr ""
-"Koleś, twoje jądro śmierdzi! Szef kuchni poleca dzisiaj Linuksa w włączonymi "
+"Koleś, twoje jądro śmierdzi! Szef kuchni poleca dzisiaj Linuksa z włączonymi "
"zegarami o wysokiej rozdzielczości!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() nie powiodło się."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Zainicjowanie demona nie powiodło się."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Uruchamianie demona bez żadnych wczytanych modułów, odmawianie pracy."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
-msgstr "Zakończono uruchamianie demona."
+msgstr "Ukończono uruchamianie demona."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Zainicjowano wyłączenie demona."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Demon został zniszczony."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -675,15 +584,15 @@ msgstr ""
" -n Nie wczytuje domyślnego pliku\n"
" skryptu\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
-msgstr "--daemonize oczekuje parametru w postaci zmiennej logicznej"
+msgstr "--daemonize oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
-msgstr "--fail oczekuje parametru w postaci zmiennej logicznej"
+msgstr "--fail oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -691,54 +600,54 @@ msgstr ""
"--log-level oczekuje parametru poziomu dziennika (numeryczny w zakresie 0..4 "
"lub jeden z debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"Nieprawidłowy dziennik docelowy: należy użyć \"syslog\", \"stderr\" lub "
"\"auto\"."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Nieprawidłowa metoda resamplingu \"%s\"."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit oczekuje parametru zmiennej logicznej"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm oczekuje parametru zmiennej logicznej"
@@ -777,77 +686,87 @@ msgstr "Użycie: %s\n"
msgid "Load Once: %s\n"
msgstr "Wczytanie jednorazowe: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "OSTRZEÅ»ENIE O PRZESTARZAÅOÅšCI: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Ścieżka: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Nieprawidłowy dziennik docelowy \"%s\"."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Nieprawidłowy poziom dziennika \"%s\"."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Nieprawidłowa metoda resamplingu \"%s\"."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Nieprawidłowy rlimit \"%s\"."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit nie jest obsługiwany na tej platformie."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Nieprawidłowy format próbki \"%s\"."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Nieprawidłowa częstotliwość próbki \"%s\"."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Nieprawidłowe kanały próbki \"%s\"."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Nieprawidłowa mapa kanałów \"%s\"."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Nieprawidłowa liczba fragmentów \"%s\"."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Nieprawidłowy rozmiar fragmentu \"%s\"."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Nieprawidłowy poziom nice \"%s\"."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Nieprawidłowa częstotliwość próbki \"%s\"."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Otwarcie pliku konfiguracji nie powiodło się: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -855,18 +774,14 @@ msgstr ""
"Podana domyślna mapa kanałów ma inną liczbę kanałów niż podana domyślna "
"liczba kanałów."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Odczytano z pliku konfiguracji: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Porzucanie uprawnień roota."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "Pomyślnie ograniczono możliwości do CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Czyszczenie uprawnień."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -876,261 +791,237 @@ msgstr "System dźwięku PulseAudio"
msgid "Start the PulseAudio Sound System"
msgstr "Uruchomienie systemu dźwięku PulseAudio"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"Szeregowanie o wysokim priorytecie (ujemny poziom nice Uniksa) dla demona "
-"PulseAudio"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Szeregowanie w czasie rzeczywistym dla demona PulseAudio"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Polityka systemu uniemożliwia PulseAudio uzyskanie szeregowania o wysokim "
-"priorytecie."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"Polityka systemu uniemożliwia PulseAudio uzyskanie szeregowania w czasie "
-"rzeczywistym."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Przedni środkowy"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Przedni lewy"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Przedni prawy"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Tylny środkowy"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Tylny lewy"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Tylny prawy"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Subwoofer"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Przedni lewy po środku"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Przedni prawy po środku"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Boczny lewy"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Boczny prawy"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Pomocnicze 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Pomocnicze 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Pomocnicze 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Pomocnicze 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Pomocnicze 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Pomocnicze 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Pomocnicze 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Pomocnicze 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Pomocnicze 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Pomocnicze 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Pomocnicze 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Pomocnicze 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Pomocnicze 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Pomocnicze 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Pomocnicze 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Pomocnicze 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Pomocnicze 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Pomocnicze 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Pomocnicze 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Pomocnicze 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Pomocnicze 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Pomocnicze 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Pomocnicze 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Pomocnicze 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Pomocnicze 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Pomocnicze 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Pomocnicze 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Pomocnicze 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Pomocnicze 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Pomocnicze 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Pomocnicze 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Pomocnicze 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Górny środkowy"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Górny przedni środkowy"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Górny przedni lewy"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Górny przedni prawy"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Górny tylny środkowy"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Górny tylny lewy"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Górny tylny prawy"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(nieprawidłowe)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Surround 7.1"
@@ -1234,27 +1125,35 @@ msgstr "Brak implementacji"
msgid "Client forked"
msgstr "Rozdzielono klienta"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Błąd wejścia/wyjścia"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Urządzenie lub zasób jest zajęty"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1265,199 +1164,193 @@ msgstr "XOpenDisplay() nie powiodło się"
#: ../src/pulse/client-conf-x11.c:93
msgid "Failed to parse cookie data"
-msgstr "Analiza danych ciasteczka nie powiodło się"
+msgstr "Przetworzenie danych ciasteczka nie powiodło się"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Otwarcie pliku konfiguracji \"%s\" nie powiodło się: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
-msgstr "Nie wczytano ciasteczka. Próbowanie połączenia się bez niego."
+msgstr "Nie wczytano ciasteczka. Próba połączenia się bez niego."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Otrzymano komunikat z nieznanego powodu \"%s\""
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() nie powiodło się: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Opróżnienie strumienia nie powiodło się: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() nie powiodło się: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Opróżniono strumień odtwarzania."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Pomyślnie utworzono strumień.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Opróżnianie połączenia z serwerem."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() nie powiodło się: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Metryka bufora: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() nie powiodło się: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Metryka bufora: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() nie powiodło się: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Używanie przykładowej specyfikacji \"%s\", mapa kanałów \"%s\".\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() nie powiodło się: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Połączono się z urządzeniem %s (%u, %swstrzymane).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Pomyślnie utworzono strumień."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Błąd strumienia: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() nie powiodło się: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Wstrzymano urzÄ…dzenie strumienia.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Metryka bufora: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Wznowiono urzÄ…dzenie strumienia.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Metryka bufora: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Niedopełniono strumień.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Używanie przykładowej specyfikacji \"%s\", mapa kanałów \"%s\"."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Przepełniono strumień.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Połączono się z urządzeniem %s (%u, %swstrzymane)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Utworzono strumień.%s \n"
+msgid "Stream error: %s"
+msgstr "Błąd strumienia: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Strumień został przeniesiony do urządzenia %s (%u, %swstrzymane).%s \n"
+msgid "Stream device suspended.%s"
+msgstr "Wstrzymano urzÄ…dzenie strumienia.%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "nie "
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Zmieniono atrybuty bufora strumienia.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "Wznowiono urzÄ…dzenie strumienia.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Ustanowiono połączenie.%s \n"
+msgid "Stream underrun.%s"
+msgstr "Niedopełniono strumień.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() nie powiodło się: %s\n"
+msgid "Stream overrun.%s"
+msgstr "Przepełniono strumień.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() nie powiodło się: %s\n"
+msgid "Stream started.%s"
+msgstr "Utworzono strumień.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() nie powiodło się: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Strumień został przeniesiony do urządzenia %s (%u, %swstrzymane).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Połączenie nie powiodło się: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "nie "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Opróżnienie strumienia nie powiodło się: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Zmieniono atrybuty bufora strumienia.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Opróżniono strumień odtwarzania.\n"
+msgid "Connection established.%s"
+msgstr "Ustanowiono połączenie.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Opróżnianie połączenia z serwerem.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() nie powiodło się: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "Otrzymano EOF.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() nie powiodło się: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() nie powiodło się: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() nie powiodło się: %s\n"
+msgid "Connection failure: %s"
+msgstr "Połączenie nie powiodło się: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() nie powiodło się: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Otrzymano EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Otrzymano sygnał, wyłączanie.\n"
+msgid "write() failed: %s"
+msgstr "write() nie powiodło się: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Uzyskanie opóźnienia nie powiodło się: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Otrzymano sygnał, kończenie pracy."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Czas: %0.3f sekundy; opóźnienie: %0.0f usekundy. \r"
+msgid "Failed to get latency: %s"
+msgstr "Uzyskanie opóźnienia nie powiodło się: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() nie powiodło się: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Czas: %0.3f sekundy; opóźnienie: %0.0f usekundy."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() nie powiodło się: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1483,8 +1376,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1507,6 +1402,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [opcje]\n"
"\n"
@@ -1516,47 +1420,55 @@ msgstr ""
" -r, --record Tworzy połączenie do nagrywania\n"
" -p, --playback Tworzy połączenie do odtwarzania\n"
"\n"
-" -v, --verbose Wyświetla więcej informacji o "
-"działaniu\n"
+" -v, --verbose Wyświetla więcej informacji o\n"
+" działaniu\n"
"\n"
" -s, --server=SERWER Nazwa serwera do połączenia się\n"
-" -d, --device=URZĄDZENIE Nazwa odpływu/źródła do połączenia "
-"siÄ™ z\n"
-" -n, --client-name=NAZWA Jak nazywać tego klienta na "
-"serwerze\n"
+" -d, --device=URZĄDZENIE Nazwa odpływu/źródła do połączenia\n"
+" siÄ™\n"
+" -n, --client-name=NAZWA Jak nazywać tego klienta na\n"
+" serwerze\n"
" --stream-name=NAZWA Jak nazwać ten strumień na serwerze\n"
-" --volume=POZIOMGÅOÅšNOÅšCI OkreÅ›la poczÄ…tkowy (liniowy) poziom "
-"głośności z zakresie 0...65536\n"
-" --rate=CZĘSTOTLIWOŚĆPRÓBKI Częstotliwość próbki w Hz (domyślnie "
-"44100)\n"
-" --format=FORMATPRÓBKI Typ próbki, jeden z s16le, s16be, "
-"u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(domyślnie s16ne)\n"
-" --channels=KANAÅY Liczba kanałów, 1 dla mono, 2 dla "
-"stereo\n"
+" --volume=POZIOMGÅOÅšNOÅšCI OkreÅ›la poczÄ…tkowy (liniowy)\n"
+" poziom głośności z zakresie\n"
+" 0...65536\n"
+" --rate=CZĘSTOTLIWOŚĆPRÓBKI Częstotliwość próbki w Hz\n"
+" (domyślnie 44100)\n"
+" --format=FORMATPRÓBKI Typ próbki, jeden z s16le, s16be,\n"
+" u8, float32le, float32be, ulaw,\n"
+" alaw, s32le, s32be, s24le, s24be,\n"
+" s24-32le, s24-32be (domyślnie\n"
+" s16ne)\n"
+" --channels=KANAÅY Liczba kanałów, 1 dla mono, 2 dla\n"
+" stereo\n"
" (domyślnie 2)\n"
-" --channel-map=MAPAKANAÅÓW Mapa kanałów używa zamiast "
-"domyślnej\n"
-" --fix-format Pobiera format próbki z odpływu, z "
-"jakim\n"
-" połączony jest strumień.\n"
-" --fix-rate Pobiera częstotliwość sampli z "
-"odpływu, z\n"
+" --channel-map=MAPAKANAÅÓW Mapa kanałów używa zamiast\n"
+" domyślnej\n"
+" --fix-format Pobiera format próbki z odpływu, z\n"
" jakim połączony jest strumień.\n"
-" --fix-channels Pobiera liczbę kanałów i mapę "
-"kanałów z odpływu,\n"
-" z jakim połączony jest strumień.\n"
-" --no-remix Nie miesza kanałów w górę lub w "
-"dół.\n"
-" --no-remap Mapuje kanały przez indeks zamiast "
-"przez nazwÄ™.\n"
-" --latency=BAJTY Żąda określonego opóźnienia w "
-"bajtach.\n"
-" --process-time=BAJTY Żąda określonego czasu procesu na "
-"żądanie w bajtach.\n"
-
-#: ../src/utils/pacat.c:612
+" --fix-rate Pobiera częstotliwość sampli z\n"
+" odpływu, z jakim połączony jest\n"
+" strumień.\n"
+" --fix-channels Pobiera liczbę kanałów i mapę\n"
+" kanałów z odpływu, z jakim\n"
+" połączony jest strumień.\n"
+" --no-remix Nie miesza kanałów w górę lub w\n"
+" dół.\n"
+" --no-remap Mapuje kanały przez indeks zamiast\n"
+" przez nazwÄ™.\n"
+" --latency=BAJTY Żąda określonego opóźnienia w\n"
+" bajtach.\n"
+" --process-time=BAJTY Żąda określonego czasu procesu na\n"
+" żądanie w bajtach.\n"
+" --property=WÅASNOŚĆ=WARTOŚĆ Ustawia podanÄ… wÅ‚asność na podanÄ…\n"
+" wartość.\n"
+" --raw Nagrywa/odtwarza surowe dane PCM.\n"
+" --file-format=FFORMAT Nagrywa/odtwarza sformatowane dane\n"
+" PCM.\n"
+" --list-file-formats Wyświetla listę dostępnych formatów\n"
+" plików.\n"
+
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1567,130 +1479,174 @@ msgstr ""
"Skompilowane za pomocÄ… libpulse %s\n"
"Skonsolidowane za pomocÄ… libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Nieprawidłowa mapa kanałów \"%s\"\n"
+msgid "Invalid client name '%s'"
+msgstr "Nieprawidłowa nazwa klienta \"%s\""
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Nieprawidłowe określenie opóźnienia \"%s\"\n"
+msgid "Invalid stream name '%s'"
+msgstr "Nieprawidłowa nazwa strumienia \"%s\""
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Nieprawidłowe określenie czasu procesu \"%s\"\n"
+msgid "Invalid channel map '%s'"
+msgstr "Nieprawidłowa mapa kanałów \"%s\""
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Nieprawidłowe określenie próbki\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Nieprawidłowe określenie opóźnienia \"%s\""
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Mapa kanałów nie zgadza się z określeniem próbki\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Nieprawidłowe określenie czasu procesu \"%s\""
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Otwieranie strumienia %s za pomocą określenie próbki \"%s\".\n"
+msgid "Invalid property '%s'"
+msgstr "Nieprawidłowa własność \"%s\""
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "nagrywanie"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Nieznany format pliku %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "odtwarzanie"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Nieprawidłowe określenie próbki"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Za dużo parametrów.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Za dużo parametrów."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() nie powiodło się.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Utworzenie określenia próbki dla pliku nie powiodło się."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() nie powiodło się.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Otwarcie pliku dźwiękowego nie powiodło się."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() nie powiodło się.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Ostrzeżenie: podane określenie próbki zostanie zastąpione przez określenie z "
+"pliku."
-#: ../src/utils/pacat.c:799
-#, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() nie powiodło się: %s\n"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Ustalenie określenia próbki z pliku nie powiodło się."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Ostrzeżenie: ustalenie mapy kanałów z pliku nie powiodło się."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Mapa kanałów nie zgadza się z określeniem próbki"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Ostrzeżenie: zapisanie mapy kanałów do pliku nie powiodło się."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() nie powiodło się.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Otwieranie strumienia %s za pomocą określenie próbki \"%s\" i mapy kanałów "
+"\"%s\"."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "nagrywanie"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "odtwarzanie"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() nie powiodło się."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() nie powiodło się."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() nie powiodło się."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() nie powiodło się.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() nie powiodło się: %s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() nie powiodło się."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() nie powiodło się."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Wstrzymanie nie powiodło się: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Wznowienie nie powiodło się: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr ""
"OSTRZEŻENIE: serwer dźwięku nie jest lokalny, nie zostanie wstrzymany.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Połączenie nie powiodło się: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
-msgstr "Otrzymano SIGINT, wyłączanie.\n"
+msgstr "Otrzymano SIGINT, kończenie pracy.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "OSTRZEŻENIE: proces potomny został zniszczony przez sygnał %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1708,7 +1664,7 @@ msgstr ""
" -s, --server=SERWER Nazwa serwera do połączenia się\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1719,37 +1675,63 @@ msgstr ""
"Skompilowane za pomocÄ… libpulse %s\n"
"Skonsolidowane za pomocÄ… libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() nie powiodło się.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() nie powiodło się.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() nie powiodło się.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Uzyskanie statystyk nie powiodło się: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "Uzyskanie statystyk nie powiodło się: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Obecnie używane: %u bloków zawierających razem %s bajtów.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"Przydzielono podczas całego czasu uruchomienia: %u bloków zawierających "
"razem %s bajtów.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Rozmiar pamięci podręcznej próbek: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Uzyskanie informacji o serwerze nie powiodło się: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Uzyskanie informacji o serwerze nie powiodło się: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1757,7 +1739,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"Nazwa użytkownika: %s\n"
"Nazwa komputera: %s\n"
@@ -1769,12 +1751,12 @@ msgstr ""
"Domyślne źródło: %s\n"
"Ciasteczko: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Uzyskanie informacji o odpływie nie powiodło się: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Uzyskanie informacji o odpływie nie powiodło się: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1813,12 +1795,22 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorty:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Uzyskanie informacji o źródle nie powiodło się: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tAktywny port: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Uzyskanie informacji o źródle nie powiodło się: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1857,20 +1849,20 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "nie dotyczy"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Uzyskanie informacji o module nie powiodło się: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Uzyskanie informacji o module nie powiodło się: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1887,12 +1879,12 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Uzyskanie informacji o kliencie nie powiodło się: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Uzyskanie informacji o kliencie nie powiodło się: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1907,12 +1899,12 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Uzyskanie informacji o karcie nie powiodło się: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Uzyskanie informacji o karcie nie powiodło się: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1929,22 +1921,22 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tProfile:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tAktywny profil: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Uzyskanie informacji o wejściu odpływu nie powiodło się: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Uzyskanie informacji o wejściu odpływu nie powiodło się: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1981,12 +1973,12 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Uzyskanie informacji o wyjściu źródła nie powiodło się: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "Uzyskanie informacji o wyjściu źródła nie powiodło się: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2015,12 +2007,12 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Uzyskanie informacji o przykładzie nie powiodło się: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Uzyskanie informacji o próbce nie powiodło się: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2051,23 +2043,80 @@ msgstr ""
"\tWłaściwości:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Niepowodzenie: %s\n"
+msgid "Failure: %s"
+msgstr "Niepowodzenie: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Usunięcie próbki nie powiodło się: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Wysłanie próbki nie powiodło się: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Przedwczesny koniec pliku\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Przedwczesny koniec pliku"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Nieprawidłowy serwer"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Otrzymano SIGINT, kończenie pracy."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2075,13 +2124,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2097,13 +2155,22 @@ msgstr ""
"%s [opcje] upload-sample NAZWAPLIKU [NAZWA]\n"
"%s [opcje] play-sample NAZWA [ODPÅYW]\n"
"%s [opcje] remove-sample NAZWA\n"
-"%s [opcje] move-sink-input IDENTYFIKATOR ODPÅYW\n"
-"%s [opcje] move-source-output IDENTYFIKATOR ŹRÓDÅO\n"
+"%s [opcje] move-sink-input WEJÅšCIE_ODPÅYWU ODPÅYW\n"
+"%s [opcje] move-source-output WYJÅšCIE_ODPÅYWU ŹRÓDÅO\n"
"%s [opcje] load-module NAZWA [PARAMETRY...]\n"
-"%s [opcje] unload-module IDENTYFIKATOR\n"
-"%s [opcje] suspend-sink [ODPÅYW] 1|0\n"
-"%s [opcje] suspend-source [ŹRÓDÅO] 1|0\n"
-"%s [opcje] set-card-profile [KARTA] [PROFIL] \n"
+"%s [opcje] unload-module MODUÅ\n"
+"%s [opcje] suspend-sink SINK 1|0\n"
+"%s [opcje] suspend-source SOURCE 1|0\n"
+"%s [opcje] set-card-profile KARTA PROFIL\n"
+"%s [opcje] set-sink-port ODPÅYW PORT\n"
+"%s [opcje] set-source-port ŹRÓDÅO PORT\n"
+"%s [opcje] set-sink-volume ODPÅYW GÅOÅšNOŚĆ\n"
+"%s [opcje] set-source-volume ŹRÓDÅO GÅOÅšNOŚĆ\n"
+"%s [opcje] set-sink-input-volume WYJÅšCIE_ODPÅYWU GÅOÅšNOŚĆ\n"
+"%s [opcje] set-sink-mute ODPÅYW 1|0\n"
+"%s [opcje] set-source-mute ŹRÓDÅO 1|0\n"
+"%s [opcje] set-sink-input-mute WEJÅšCIE_ODPÅYWU 1|0\n"
+"\n"
"\n"
" -h, --help Wyświetla tę pomoc\n"
" --version Wyświetla wersję\n"
@@ -2111,7 +2178,7 @@ msgstr ""
" -s, --server=SERWER Nazwa serwera do połączenia się\n"
" -n, --client-name=NAZWA Jak nazwać tego klienta na serwerze\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2122,76 +2189,108 @@ msgstr ""
"Skompilowane za pomocÄ… libpulse %s\n"
"Skonsolidowane za pomocÄ… libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Proszę podać plik próbki do wczytania\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Proszę podać plik próbki do wczytania"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Otwarcie pliku dźwiękowego nie powiodło się.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Otwarcie pliku dźwiękowego nie powiodło się."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Należy podać nazwę próbki do odtworzenia\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Ostrzeżenie: ustalenie określenia próbki z pliku nie powiodło się."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Należy podać nazwę próbki do usunięcia\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Należy podać nazwę próbki do odtworzenia"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Należy podać indeks odpływu wejścia i odpływ\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Należy podać nazwę próbki do usunięcia"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Należy podać indeks źródła wyjścia i źródło\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Należy podać indeks odpływu wejścia i odpływ"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Należy podać nazwę modułu i parametry.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Należy podać indeks źródła wyjścia i źródło"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Należy podać indeks modułu\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Należy podać nazwę modułu i parametry."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Należy podać indeks modułu"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"Nie można podać więcej niż jednego odpływu. Należy podać wartość logiczną.\n"
+"Nie można podać więcej niż jednego odpływu. Należy podać wartość logiczną."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"Nie można podać więcej niż jednego źródła. Należy podać wartość logiczną.\n"
+"Nie można podać więcej niż jednego źródła. Należy podać wartość logiczną."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Należy podać nazwę karty/indeks i nazwę profilu\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Należy podać nazwę karty/indeks i nazwę profilu"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Nie podano prawidłowego polecenia.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Należy podać nazwę odpływu/indeks i nazwę portu"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() nie powiodło się: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Należy podać nazwę źródła/indeks i nazwę portu"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Należy podać nazwę odpływu/indeks i głośność"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Nieprawidłowe określenie głośności"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Należy podać nazwę źródła/indeks i głośność"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Należy podać indeks odpływu wejścia i głośność"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Nieprawidłowy indeks wejścia odpływu"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Należy podać nazwę odpływu/indeks i zmienną logiczną wyciszenia"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Należy podać nazwę źródła/indeks i zmienną logiczną wyciszenia"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "Należy podać indeks odpływu wejścia i zmienną logiczną wyciszenia"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Nieprawidłowe określenie indeksu wejścia odpływu"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Nie podano prawidłowego polecenia."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2208,14 +2307,14 @@ msgstr ""
"\n"
" -d Wyświetla dane PulseAudio dołączone do ekranu X11 (domyślne)\n"
" -e Eksportuje lokalne dane PulseAudio na ekran X11\n"
-" -i Importuje dane PulseAudio z ekranu X11 do lokalnych zmiennych "
-"środowiskowych i pliku ciasteczka.\n"
+" -i Importuje dane PulseAudio z ekranu X11 do lokalnych zmiennych\n"
+" środowiskowych i pliku ciasteczka.\n"
" -r Usuwa dane PulseAudio z ekranu X11\n"
#: ../src/utils/pax11publish.c:94
#, c-format
msgid "Failed to parse command line.\n"
-msgstr "Analiza wiersza poleceń nie powiodła się.\n"
+msgstr "Przetworzenie wiersza poleceń nie powiodła się.\n"
#: ../src/utils/pax11publish.c:108
#, c-format
@@ -2240,7 +2339,7 @@ msgstr "Ciasteczko: %s\n"
#: ../src/utils/pax11publish.c:132
#, c-format
msgid "Failed to parse cookie data\n"
-msgstr "Analiza danych ciasteczka nie powiodła się\n"
+msgstr "Przetworzenie danych ciasteczka nie powiodła się\n"
#: ../src/utils/pax11publish.c:137
#, c-format
@@ -2272,127 +2371,50 @@ msgstr "Wczytanie danych ciasteczka nie powiodło się\n"
msgid "Not yet implemented.\n"
msgstr "Niezaimplementowane.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Demon PulseAudio nie jest uruchomiony, lub nie jest uruchomiony jako demon "
+"sesji."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "gniazdo(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Zniszczenie demona PulseAudio nie powiodło się."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Demon nie odpowiada."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Pomyślnie utworzono strumień\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Błąd strumienia: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Ustanowiono połączenie.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [opcje] [PLIK]\n"
-"\n"
-" -h, --help Wyświetla tę pomoc\n"
-" --version Wyświetla wersję\n"
-"\n"
-" -v, --verbose Wyświetla więcej informacji o "
-"działaniach\n"
-"\n"
-" -s, --server=SERWER Nazwa serwera do połączenia się\n"
-" -d, --device=URZĄDZENIE Nazwa odpływu do połączenia się\n"
-" -n, --client-name=NAZWA Jak nazwać tego klienta na serwerze\n"
-" --stream-name=NAZWA Jak nazwać ten strumień na serwerze\n"
-" --volume=POZIOMGÅOÅšNOÅšCI OkreÅ›la poczÄ…tkowy (liniowy) poziom "
-"głośności w zakresie 0...65536\n"
-" --channel-map=MAPAKANAÅÓW Ustawia używanÄ… mapÄ™ kanałów\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Skompilowane za pomocÄ… libpulse %s\n"
-"Skonsolidowane za pomocÄ… libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Nieprawidłowa mapa kanałów\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Otwarcie pliku \"%s\" nie powiodło się\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Mapa kanałów nie zgadza się z plikiem.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Używanie przykładowej specyfikacji \"%s\"\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Nie można uzyskać dostępu do blokady automatycznego wznawiania."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2403,13 +2425,13 @@ msgid ""
"returned 0 or another value < min_avail."
msgstr ""
"ALSA została wybudzona, aby zapisać nowe dane do urządzenia, ale nie było "
-"nic do zapisania!\n"
+"nic do zapisania.\n"
"Prawdopodobnie jest to błąd w sterowniku ALSA \"%s\". Proszę zgłosić ten "
"problem programistom ALSA.\n"
"Wybudzono za pomocą ustawienia POLLOUT - ale jednoczesne wywołanie "
"snd_pcm_avail() zwróciło zero lub inną wartość < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2420,40 +2442,265 @@ msgid ""
"returned 0 or another value < min_avail."
msgstr ""
"ALSA została wybudzona, aby odczytać nowe dane z urządzenia, ale nie było "
-"nic do odczytania!\n"
+"nic do odczytania.\n"
"Prawdopodobnie jest to błąd w sterowniku ALSA \"%s\". Proszę zgłosić ten "
"problem programistom ALSA.\n"
"Wybudzono za pomocą ustawienia POLLIN - ale jednoczesne wywołanie "
"snd_pcm_avail() zwróciło zero lub inną wartość < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Wyjście %s + wejście %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Wyjście %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Wejście %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "Wyłącz"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "Odtwarzanie o wysokiej dokładności (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Przechwytywanie o wysokiej dokładności (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "Duplex telefoniczny (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "Serwer dźwięku PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Urządzenia wyjściowe"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Urządzenia wejściowe"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Dźwięk na @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Wejście"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Wejście stacji dokującej"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Mikrofon stacji dokujÄ…cej"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Wejście liniowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Zewnętrzny mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Wewnętrzny mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Wideo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Automatyczna kontrola natężenia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Brak automatycznej kontroli natężenia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Podbicie"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Brak podbicia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Amplituner"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Brak amplitunera"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Podbicie"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Brak podbicia"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Słuchawki analogowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Wejście analogowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Mikrofon analogowy"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Analogowe wejście liniowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Radio analogowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Wideo analogowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Wyjście analogowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Słuchawki analogowe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Wyjście analogowe (subwoofer)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analogowe wyjście mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analogowe stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s/%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analogowe mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analogowe stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analogowe surround 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analogowe surround 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analogowe surround 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analogowe surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analogowe surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analogowe surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analogowe surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analogowe surround 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analogowe surround 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analogowe surround 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analogowe surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Cyfrowe stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Cyfrowe surround 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Cyfrowe surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Cyfrowe surround 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Cyfrowe stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analogowy dupleks mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analogowy dupleks stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Cyfrowy dupleks stereo (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Subwoofer"
diff --git a/po/pt.po b/po/pt.po
new file mode 100644
index 00000000..b24abfa8
--- /dev/null
+++ b/po/pt.po
@@ -0,0 +1,2884 @@
+msgid ""
+msgstr ""
+"Project-Id-Version: pulseaudio\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: \n"
+"Last-Translator: Rui Gouveia <rui.gouveia@globaltek.pt>\n"
+"Language-Team: pt <fedora-trans-pt@redhat.com>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-Language: Portuguese\n"
+"X-Poedit-Country: PORTUGAL\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_avail() retornou um valor excepcionalmente elevado: %lu bytes (%lu "
+"ms).\n"
+"Provavelmente isto é um erro no driver ALSA '%s'. Por favor, reporte este "
+"problema aos programadores do ALSA."
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_delay() retornou um valor excepcionalmente elevado: %li bytes (%s%lu "
+"ms).\n"
+"Provavelmente isto é um erro no driver ALSA '%s'. Por favor, reporte este "
+"problema aos programadores do ALSA."
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_mmap_begin() retornou um valor excepcionalmente elevado: %lu bytes (%"
+"lu ms).\n"
+"Provavelmente isto é um erro no driver ALSA '%s'. Por favor, reporte este "
+"problema aos programadores do ALSA."
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Mantém sempre pelo menos um depósito carregado mesmo que seja um nulo"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Saída Dummy"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Depósito virtual LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nome do depósito> sink_properties=<propriedades do depósito> "
+"master=<nome do depósito a filtrar> format=<formato exemplo> "
+"rate=<frequência de amostragem> channels=<número de canais> "
+"channel_map=<mapa de canais> plugin=<nome do plugin ladspa> label=<etiqueta "
+"do plugin ladspa> control=<Lista de valores de controlo de entrada separados "
+"por vírgulas>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr ""
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Saída nula"
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "Ãudio Interno"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "Modem"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr "Não foi possível encontrar o carregador \"lt_dlopen\"."
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr "Não foi possível alocar o novo carregador \"dl\"."
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr "Não foi possível adicionar \"bind-now-loader\"."
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr "Foi obtido o sinal %s."
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "A sair."
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr "Falha ao procurar o utilizador '%s'."
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr "Falha ao procurar o grupo '%s'."
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr "Foi encontrado utilizador '%s' (UID %lu) e grupo '%s' (GID %lu)."
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr "GID do utilizador '%s' e do grupo '%s' não coincidem."
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr "Directório pessoal do utilizador '%s' não é '%s'. A ignorar."
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr "Falha ao criar o '%s': %s"
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr "Falhou a alteração da lista de grupos: %s"
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr "Não foi possível mudar o GID: %s"
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr "Não foi possível mudar o UID: %s"
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr "Privilégios de root cedidos com sucesso."
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr "Modo de sistema não suportado nesta plataforma."
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr "setrlimit(%s, (%u, %u)) falhou: %s"
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr "Não foi possível processar linha de comando."
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr "Serviço não está a executar"
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr "Serviço a executar como PID %u"
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr "Tentativa de matar serviço falhou: %s"
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr ""
+"Este programa não pretende ser executado como root (a não ser que a opção --"
+"system seja especificada)."
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr "São necessários privilégios de root."
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr "--start não é suportado para instâncias do sistema."
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr "A executar em modo de sistema, mas --disallow-exit não está definido!"
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr ""
+"A executar em modo de sistema, mas --disallow-module-loading não está "
+"definido!"
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr "A executar em modo de sistema, a forçar a desactivação do modo SHM!"
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr ""
+"A executar em modo de sistema, a forçar a desactivação da saída por "
+"inactividade!"
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr "Não foi possível adquirir o stdio."
+
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "pipe falhou: %s"
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr "fork() falhou: %s"
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr "read() falhou: %s"
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr "Arranque do serviço falhou."
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr "Arranque do serviço sucedeu."
+
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() falhou: %s"
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr "Isto é PulseAudio %s"
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr "Máquina de compilação: %s"
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr "CFLAGS utilizadas na compilação: %s"
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr "A executar na máquina: %s"
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr "Foram encontrados %u CPUs."
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr "Tamanho da página é %lu bytes"
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr "Compilado com suporte para Valgrind: sim"
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr "Compilado com suporte para Valgrind: não"
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr "A executar em modo \"valgrind\": %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "A executar na máquina: %s"
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr "Optimizado: sim"
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr "Compilação optimizada: não"
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr "NDEBUG definido, todas as declarações desactivadas."
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr "FASTPATH definido, apenas as declarações \"fast path\" desactivadas."
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr "Todas as declarações desactivadas."
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr "A tentativa de ler o ID da máquina falhou"
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr "O ID da máquina é %s."
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr "O ID da sessão é %s."
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr "Execução a utilizar o directório %s"
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr "A manter o estado no directório %s."
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "A utilizar o directório de módulos %s"
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr "Execução em modo de sistema: %s"
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"Ok, então está a correr PA em modo de sistema. Por favor repare que não "
+"deveria estar a fazê-lo.\n"
+"Se, na mesma, o continuar a fazer e as coisas não correrem como esperado, a "
+"culpa será sua.\n"
+"Por favor leia http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode para uma "
+"explicação de como o modo de sistema é usualmente uma má ideia."
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr "pa_pid_file_create() falhou."
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr "Timer \"frescos\" de alta resolução disponíveis. Bom apetite!"
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr ""
+"Oh pá, o teu kernel não presta! O prato do dia recomendado é Linux com "
+"timers de alta resolução activos!"
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr "pa_core_new() falhou."
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr "Falha ao inicializar serviço."
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr "Serviço arrancou sem módulos carregados. A recusar trabalhar."
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr "Arranque do serviço completo."
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr "Encerramento do serviço iniciado."
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr "Serviço terminado."
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+"%s [opções]\n"
+"\n"
+"COMANDOS:\n"
+" -h, --help Mostra esta ajuda\n"
+" --version Mostra versão\n"
+" --dump-conf Despeja configuração por omissão\n"
+" --dump-modules Despeja lista de módulos "
+"disponíveis\n"
+" --dump-resample-methods Despeja métodos \"resample\" "
+"disponíveis\n"
+" --cleanup-shm Limpar segmentos de memória "
+"partilhados encravados\n"
+" --start Inicia o serviço, se ainda não "
+"estiver a executar\n"
+" -k --kill Termina o serviço, se estiver a "
+"executar \n"
+" --check Verifica se o serviço está a "
+"executar (apenas retorna um código de saída)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Executa em modo de sistema\n"
+" -D, --daemonize[=BOOL] Passa a serviço depois de executar\n"
+" --fail[=BOOL] Termina quando o arranque falha\n"
+" --high-priority[=BOOL] Tenta definir um alto nível de "
+"execução\n"
+" (apenas disponível como root, quando "
+"é SUID ou\n"
+" com níveis elevados de RLIMIT_NICE)\n"
+" --realtime[=BOOL] Tenta activar escalonamento em tempo "
+"real\n"
+" (apenas disponível como root, quando "
+"é SUID ou\n"
+" com níveis elevados de "
+"RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Desautoriza o carregamento/"
+"descarregamento\n"
+" de módulos, pelo utilizador, depois "
+"do arranque\n"
+" --disallow-exit[=BOOL] Desautoriza pedidos de saída do "
+"utilizador\n"
+" --exit-idle-time=SECS Termina o serviço quando inactivo e "
+"já passou\n"
+" este tempo\n"
+" --module-idle-time=SECS Descarregar módulos de carregamento "
+"automático quando inactivo e\n"
+" passou este tempo\n"
+" --scache-idle-time=SECS Descarregar amostras de carregamento "
+"automático quando inactivas e\n"
+" passou este tempo\n"
+" --log-level[=LEVEL] Aumenta ou define o nível de "
+"verbosidade\n"
+" -v Aumenta o nível de verbosidade\n"
+" --log-target={auto,syslog,stderr} Especifica o ficheiro de registo\n"
+" --log-meta[=BOOL] Inclui código de localização na "
+"mensagem de registo\n"
+" --log-time[=BOOL] Inclui tempo na mensagem de registo\n"
+" --log-backtrace=FRAMES Inclui informação de tracagem na "
+"mensagem de registo\n"
+" -p, --dl-search-path=PATH Define o caminho de procura para os "
+"plugins partilhados dinâmicos\n"
+" --resample-method=METHOD Utilizar o método de \"resampling\" "
+"especificado\n"
+" (Ver --dump-resample-methods para\n"
+" possíveis valores)\n"
+" --use-pid-file[=BOOL] Criar um ficheiro com o PID\n"
+" --no-cpu-limit[=BOOL] Não instala limitadores de load no "
+"CPU em\n"
+" plataformas que o suportam.\n"
+" --disable-shm[=BOOL] Desactivar suporte para memória "
+"partilhada.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Carrega o módulo especificado com\n"
+" o argumento especificado\n"
+" -F, --file=FILENAME Executa o script especificado\n"
+" -C Abre uma linha de comando no TTY "
+"(consola) em execução\n"
+" depois do arranque\n"
+"\n"
+" -n Não carrega o script por omissão\n"
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr "--daemonize espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr "--fail espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+"--log-level espera um argumento para o nível de log (numérico no intervalo "
+"0..4 ou um dos seguintes: debug, info, notice, warn, error)."
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr "--high-priority espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr "--realtime espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr "--disallow-module-loading espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr "--disallow-exit espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr "--use-pid-file espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr ""
+"Destino de ficheiro de registo inválido: utilize 'syslog', 'stderr' ou "
+"'auto'."
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr "--log-time espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr "--log-meta espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr "Método de resample inválido '%s'."
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr "--system espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr "--no-cpu-limit espera argumento booleano"
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr "--disable-shm espera argumento booleano"
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr "Nome: %s\n"
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr "Nenhuma informação de módulo disponível\n"
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr "Versão: %s\n"
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr "Descrição: %s\n"
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr "Autor: %s\n"
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr "Utilização: %s\n"
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr "Carregar Uma Vez: %s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "AVISO DE DESCONTINUIDADE: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr "Caminho: %s\n"
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr "[%s:%u] ficheiro registo de destino inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr "[%s:%u] Nível do ficheiro de registo inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr "[%s:%u] Método de reamostragem inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr "[%s:%u] rlimit inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr "[%s:%u] rlimit não é suportado nesta plataforma."
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr "[%s:%u] Formato da amostra inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr "[%s:%u] Taxa de amostragem '%s' inválida."
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr "[%s:%u] Canais de amostragem inválidos '%s'."
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr "[%s:%u] Mapa de canais inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr "[%s:%u] Número inválido de fragmentos '%s'."
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr "[%s:%u] Tamanho do fragmento inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr "[%s:%u] nível nice inválido '%s'."
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Taxa de amostragem '%s' inválida."
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr "Falha ao abrir ficheiro de configuração: %s"
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr ""
+"O mapa de canais especificado tem um número de canais diferente do número de "
+"canais definido por omissão."
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr "### Ler configuração a partir do ficheiro: %s ###\n"
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "A limpar privilégios."
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "Sistema de Som PulseAudio"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "Inciar o Sistema de Som PulseAudio"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "Mono"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "Frontal Central"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "Frontal Esquerda"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "Frontal Direita"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "Traseira Central"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "Traseira Esquerda"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "Traseira Direita"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr "Central Centro-Esquerda"
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr "Central Centro-Direita"
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "Lateral Esquerda"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "Lateral Direita"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr "Auxiliar 0"
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr "Auxiliar 1"
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr "Auxiliar 2"
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr "Auxiliar 3"
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr "Auxiliar 4"
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr "Auxiliar 5"
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr "Auxiliar 6"
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr "Auxiliar 7"
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr "Auxiliar 8"
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr "Auxiliar 9"
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr "Auxiliar 10"
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr "Auxiliar 11"
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr "Auxiliar 12"
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr "Auxiliar 13"
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr "Auxiliar 14"
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr "Auxiliar 15"
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr "Auxiliar 16"
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr "Auxiliar 17"
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr "Auxiliar 18"
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr "Auxiliar 19"
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr "Auxiliar 20"
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr "Auxiliar 21"
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr "Auxiliar 22"
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr "Auxiliar 23"
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr "Auxiliar 24"
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr "Auxiliar 25"
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr "Auxiliar 26"
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr "Auxiliar 27"
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr "Auxiliar 28"
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr "Auxiliar 29"
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr "Auxiliar 30"
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr "Auxiliar 31"
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "Topo Centro"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "Topo Central Centro"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "Topo Frontal Esquerda"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "Topo Frontal Direita"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "Topo Traseira Centro"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "Topo Traseira Esquerda"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "Topo Traseira Direita"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "(inválido)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "Estéreo"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "Surround 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "Surround 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "Surround 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "Surround 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "Surround 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "OK"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "Acesso negado"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr "Comando desconhecido"
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr "Argumento inválido"
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr "Entidade existe! "
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr "Entidade não existe"
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "Ligação recusada"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "Erro de protocolo"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr "Tempo expirou"
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr "Sem chave de autorização"
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "Erro interno"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr "Ligação terminou"
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr "Entidade terminada"
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr "Servidor Inválido"
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr "Inicialização do módulo falhou"
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr "Mau estado"
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr "Nenhuns dados"
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr "Versão de protocolo incompatível"
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "Demasiado Grande"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "Não suportado"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "Código de erro desconhecido"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr "Extensão não existe"
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr "Funcionalidade obsoleta"
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr "Implementação em falta"
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr "Cliente efectuou um fork"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Erro de entrada/saída"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Dispositivo ou recurso ocupado"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr "%s %uch %uHz"
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr "%.1f GiB"
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr "%.1f MiB"
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr "%.1f KiB"
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr "%u B"
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr "XOpenDisplay() falhou"
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr "Não foi possível processar dados da cookie"
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr "Falha ao abrir ficheiro de configuração '%s': %s"
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr "Nenhuma cookie carregada. A tentar ligar sem cookie."
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr "fork(): %s"
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr "waitpid(): %s"
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr "Recebida mensagem para extensão desconhecida '%s'"
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr "Falha ao esvaziar fluxo: %s"
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Fluxo de leitura drenado."
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "A drenar ligação ao servidor."
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() falhou: %s"
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() falhou: %s"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() falhou: %s"
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Fluxo criado com sucesso."
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() falhou: %s"
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Métricas do Buffer: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Métricas do Buffer: maxlength=%u, fragsize=%u"
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Utilizando especificação da amostra '%s', mapa de canal '%s'."
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Ligado ao dispositivo %s (%u, %ssuspended)."
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr "Erro de fluxo: %s"
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr "Dispositivo de fluxo suspenso.%s"
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr "Dispositivo de fluxo retomado.%s"
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr "Fluxo com falta de dados.%s"
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr "Fluxo com excesso de dados.%s"
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr "Fluxo iniciado.%s"
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Fluxo movido para o dispositivo %s (%u, %ssuspended).%s"
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "negação"
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr "Atributos do buffer de fluxo alterados.%s"
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr "Ligação estabelecida.%s"
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() falhou: %s"
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() falhou: %s"
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() falhou: %s"
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr "Ligação falhou: %s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Obtive EOF."
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr "write() falhou: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Recebido sinal, a sair."
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr "Falhou a obtenção da cadência: %s"
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Tempo: %0.3f sec; Cadência: %0.0f usec."
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() falhou: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+"%s [opções]\n"
+"\n"
+" -h, --help Mostra esta ajuda\n"
+" --version Mostra a versão\n"
+"\n"
+" -r, --record Cria uma ligação para gravar\n"
+" -p, --playback Cria uma ligação para lêr\n"
+"\n"
+" -v, --verbose Activa operações verbose\n"
+"\n"
+" -s, --server=SERVER Nome do servidor a qual ligar\n"
+" -d, --device=DEVICE Nome do depósito/fonte a qual ligar\n"
+" -n, --client-name=NAME Como chamar este cliente no "
+"servidor\n"
+" --stream-name=NAME Como chamar este fluxo no servidor\n"
+" --volume=VOLUME Especificar o volume (linear) "
+"inicial na gama 0...65536\n"
+" --rate=SAMPLERATE A mesma taxa em Hz (por omissão "
+"44100)\n"
+" --format=SAMPLEFORMAT Tipo de amostragem, uma de s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (por omissão "
+"s16ne)\n"
+" --channels=CHANNELS Número de canais, 1 para mono, 2 "
+"para estéreo\n"
+" (por omissão 2)\n"
+" --channel-map=CHANNELMAP Mapa de canais a usar em vez do mapa "
+"por omissão\n"
+" --fix-format Usa o formato de amostragem do "
+"depósito para\n"
+" onde o fluxo está a ligado.\n"
+" --fix-rate Usa a taxa de amostragem do depósito "
+"para\n"
+" onde o fluxo está ligado.\n"
+" --fix-channels Pega no número de canais e no mapa "
+"de canais\n"
+" do depósito para onde o fluxo está "
+"ligado.\n"
+" --no-remix Não misturar os canais em cima nem "
+"em baixo.\n"
+" --no-remap Mapeia os canais por índice em vez "
+"do nome.\n"
+" --latency=BYTES Pede a cadência especificada em "
+"bytes.\n"
+" --process-time=BYTES Pede o tempo de processo por pedido "
+"em bytes.\n"
+" --property=PROPERTY=VALUE Coloca a propriedade específica com "
+"o valor especificado.\n"
+" --raw Grava/Lê dados raw em PCM.\n"
+" --file-format=FFORMAT Grava/Lê dados formatados em PCM.\n"
+" --list-file-formats Lista o formato de ficheiros "
+"disponíveis.\n"
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pacat %s\n"
+"Compilado com libpulse %s\n"
+"Ligado com libpulse %s\n"
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr "Nome de cliente inválido '%s'"
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr "Nome de fluxo inválido '%s'"
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr "Mapa de canais inválido '%s'"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr "Especificação da cadência inválida '%s'"
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "Especificação de tempo de processamento inválido '%s'"
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr "Propriedade inválida '%s'"
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Formato de ficheiro desconhecido %s."
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Especificação de amostra inválida"
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr "open(): %s"
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Demasiados argumentos."
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Falha ao gerar especificação de amostra para o ficheiro."
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Falha ao abrir ficheiro de audio"
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Aviso: a especificação da amostra será sobrescrita com a especificação do "
+"ficheiro."
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Falha ao determinar a especificação da amostra a partir do ficheiro."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Aviso: Falha a determinar o mapa de canal do ficheiro."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Mapa de canais não corresponde à especificação da amostra"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Aviso: falha na escrita do mapa de canais no ficheiro."
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Abrindo um %s fluxo com especificação da amostra '%s' e mapa de canais '%s'."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "a gravar"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "reprodução"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() falhou."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() falhou."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() falhou."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() falhou: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() falhou."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() falhou."
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr "fork(): %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr "Falhou ao suspender: %s\n"
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr "Falhou ao restaurar: %s\n"
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr "Atenção: Servidor de Som não local, suspender ignorado.\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Ligação falhou: %s\n"
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr "Obtido SIGINT, a sair.\n"
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr "Atenção: Processo filho terminado por sinal %u\n"
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+"%s [opções] ... \n"
+"\n"
+" -h, --help Mostra esta ajuda\n"
+" --version Mostra a versão\n"
+" -s, --server=SERVER Nome do servidor ao qual ligar\n"
+"\n"
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pasuspender %s\n"
+"Compilado com libpulse %s\n"
+"Ligado com libpulse %s\n"
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() falhou.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() falhou.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() falhou.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Falhou a obtenção de estatísticas: %s"
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr "Correntemente em uso: %u blocos contendo %s bytes no total.\n"
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr ""
+"Alocado durante todo o tempo de vida: %u blocos contendo %s bytes no total.\n"
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr "Tamanho cache da amostra: %s\n"
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr "Falha ao obter informações do servidor: %s"
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+"Nome de utilizador: %s\n"
+"Nome da máquina: %s\n"
+"Nome do servidor: %s\n"
+"Versão do servidor: %s\n"
+"Especificação da amostra por omissão: %s\n"
+"Mapa de canais por omissão: %s\n"
+"Depósito por omissão: %s\n"
+"Fonte por omissão: %s\n"
+"Cookie: %08x\n"
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr "Falha ao obter informações do depósito: %s"
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Depósito #%u\n"
+"\tEstado: %s\n"
+"\tNome: %s\n"
+"\tDescrição: %s\n"
+"\tDriver: %s\n"
+"\tEspecificação da Amostra: %s\n"
+"\tMapa de Canais: %s\n"
+"\tMódulo Dono: %u\n"
+"\tMudo: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balanço %0.2f\n"
+"\tVolume Base: %s%s%s\n"
+"\tMonitor de Fonte: %s\n"
+"\tCadência: %0.0f usec, configurado %0.0f usec\n"
+"\tBandeiras: %s%s%s%s%s%s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorto:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tPorto Activo: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Falha ao obter informações da fonte: %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Fonte #%u\n"
+"\tEstado: %s\n"
+"\tNome: %s\n"
+"\tDescrição: %s\n"
+"\tDriver: %s\n"
+"\tEspecificação da Amostra: %s\n"
+"\tMapa de canais: %s\n"
+"\tMódulo Dono: %u\n"
+"\tMudo: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balanço %0.2f\n"
+"\tVolume Base: %s%s%s\n"
+"\tMonitor do Depósito: %s\n"
+"\tCadência: %0.0f usec, configurado %0.0f usec\n"
+"\tBandeiras: %s%s%s%s%s%s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "n/d"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr "Falha ao obter informações do módulo: %s"
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Módulo #%u\n"
+"\tNome: %s\n"
+"\tArgumento: %s\n"
+"\tContador de utilização: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr "Falha ao obter informações do cliente: %s"
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Cliente #%u\n"
+"\tDriver: %s\n"
+"\tMódulo dono: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "Falha ao obter informações da carta: %s"
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Placa #%u\n"
+"\tNome: %s\n"
+"\tDriver: %s\n"
+"\tMódulo dono: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\tPrefis:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr "\tPerfil Activo: %s\n"
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "Falha ao obter informação de entrada do depósito: %s"
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Entrada de Depósito #%u\n"
+"\tDriver: %s\n"
+"\tMódulo Dono: %s\n"
+"\tCliente: %s\n"
+"\tDepósito: %u\n"
+"\tEspecificação da amostra: %s\n"
+"\tMapa de canais: %s\n"
+"\tMudo: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balanço %0.2f\n"
+"\tCadência do Buffer: %0.0f usec\n"
+"\tCadência do Depósito: %0.0f usec\n"
+"\tMétodo de reamostragem: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "Falha ao obter informações da fonte: %s"
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Saída fonte #%u\n"
+"\tDriver: %s\n"
+"\tMódulo dono: %s\n"
+"\tCliente: %s\n"
+"\tFonte: %u\n"
+"\tEspecificação da amostra: %s\n"
+"\tMapa de Canais: %s\n"
+"\tCadência do Buffer: %0.0f usec\n"
+"\tCadência da Fonte: %0.0f usec\n"
+"\tMétodo de reamostragem: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "Falha ao obter informações da amostra: %s"
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Amostra #%u\n"
+"\tNome: %s\n"
+"\tEspecificação da Amostra: %s\n"
+"\tMapa de Canais: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balanço %0.2f\n"
+"\tDuração: %0.1fs\n"
+"\tTamanho: %s\n"
+"\tLento: %s\n"
+"\tNome do ficheiro: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "Falha: %s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "Falha ao enviar amostra: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Fim prematuro do ficheiro"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Servidor Inválido"
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Obtido SIGINT, a sair."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+"%s [opções] stat\n"
+"%s [opções] list\n"
+"%s [opções] exit\n"
+"%s [opções] upload-sample NOME_DO_FICHEIRO [NOME]\n"
+"%s [opções] play-sample NOME [DEPÓSITO]\n"
+"%s [opções] remove-sample NOME\n"
+"%s [opções] move-sink-input ENTRADA_DO_DEPÓSITO DEPÓSITO\n"
+"%s [opções] move-source-output SAÃDA_DA_FONTE FONTE\n"
+"%s [opções] load-module NOME [ARGTOS ...]\n"
+"%s [opções] unload-module MÓDULO\n"
+"%s [opções] suspend-sink DEPÓSITO 1|0\n"
+"%s [opções] suspend-source FONTE 1|0\n"
+"%s [opções] set-card-profile PLACA PERFIL\n"
+"%s [opções] set-sink-port DEPÓSITO PORTO\n"
+"%s [opções] set-source-port FONTE PORTO\n"
+"%s [opções] set-sink-volume DEPÓSITO VOLUME\n"
+"%s [opções] set-source-volume FONTE VOLUME\n"
+"%s [opções] set-sink-input-volume VOLUME_DE_ENTRADA DEPÓSITO\n"
+"%s [opções] set-sink-mute DEPÓSITO 1|0\n"
+"%s [opções] set-source-mute FONTE 1|0\n"
+"%s [opções] set-sink-input-mute ENTRADA_DA_FONTE 1|0\n"
+"\n"
+" -h, --help Mostra esta ajuda\n"
+" --version Mostra a versão\n"
+"\n"
+" -s, --server=SERVER O nome do servidor ao qual ligar\n"
+" -n, --client-name=NAME Como chamar este cliente no "
+"servidor\n"
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pactl %s\n"
+"Compilado com libpulse %s\n"
+"Linkado com libpulse %s\n"
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Por favor, especifique um ficheiro de amostra para carregar"
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Falha ao abrir ficheiro de som."
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Aviso: Falha ao determinar a especificação da amostra do ficheiro."
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Tem de especificar um nome de amostra para reproduzir"
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Tem de especificar um nome de amostra para remover"
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Tem de especificar um índice de entrada de depósito e um depósito"
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Tem de especificar um índice de saída de fonte e uma fonte"
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Tem de especificar um nome de módulo e argumentos."
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Tem de especificar um índice de módulo"
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+"Não pode especificar mais do que um depósito. Tem de especificar um valor "
+"booleano."
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr ""
+"Não pode especificar mais do que uma fonte. Tem de especificar um valor "
+"booleano."
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Tem de especificar um nome/índice de placa e um nome de perfil"
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Tem de especificar um nome/índice de depósito e nome de um porto"
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Tem de especificar um nome/índice de fonte e nome de um porto"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Tem de especificar um nome/índice de depósito e um volume"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Especificação de volume inválida"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Tem de especificar um nome/índice de fonte e um volume"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Tem de especificar um índice de entrada de depósito e um volume"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ãndice de depósito de entrada inválido"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Tem de especificar um nome/índice de depósito e um booleano mudo"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Tem de especificar um nome/índice de fonte e um booleano mudo"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "Tem de especificar um índice de entrada de depósito e um booleano mudo"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Ãndice de entrada de depósito inválida"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "O comando especificado é inválido."
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+"%s [-D ecrã] [-S servidor] [-O depósito] [-I fonte] [-c ficheiro] [-d|-e|-"
+"i|-r]\n"
+"\n"
+" -d Mostra os dados correntes do PulseAudio anexados ao ecrã X11 "
+"(default)\n"
+" -e Exporta dados locais do PulseAudio para o ecrã X11\n"
+" -i Importa dados do PulseAudio do ecrã X11 para variáveis de ambiente "
+"locais e ficheiro de cookies.\n"
+" -r Remove dados do PulseAudio do ecrã X11\n"
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr "Não foi possível processar a linha de comando.\n"
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr "Servidor: %s\n"
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr "Fonte: %s\n"
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr "Sink: %s\n"
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr "Cookie: %s\n"
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr "Não foi possível processar os dados da cookie\n"
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr "Não foi possível gravar os dados da cookie\n"
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr "Não foi possível carregar o ficheiro de configuração do cliente\n"
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr "Não foi possível ler os dados de configuração do ambiente\n"
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr "Falhou ao obter FQDN.\n"
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr "Não foi possível carregar os dados da cookie\n"
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr "Ainda não implementado.\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Não existe um daemon PulseAudio a correr, ou não corre como daemon de sessão."
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr "connect(): %s"
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr "Não foi possível terminar o serviço PulseAudio."
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr "Serviço não responde."
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr "poll(): %s"
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr "read(): %s"
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr "write(): %s"
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr "Impossível aceder ao lock \"autospawn\"."
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA acordou-nos para escrever novos dados para o dispositivo, mas não havia "
+"nada para escrever!\n"
+"Provavelmente isto é um erro no driver ALSA '%s'. Por favor, reporte este "
+"problema aos programadores do ALSA.\n"
+"Fomos acordados pelo conjunto POLLOUT -- contudo uma chamada a seguir de "
+"snd_pcm_avail() retornou 0 ou outro valor < min_avail."
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA acordou-nos para ler novos dados do dispositivo, mas não havia nada "
+"para ler!\n"
+"Provavelmente isto é um erro no driver ALSA '%s'. Por favor, reporte este "
+"problema aos programadores do ALSA.\n"
+"Fomos acordados pelo conjunto POLLIN -- contudo uma chamada a seguir de "
+"snd_pcm_avail() retornou 0 ou outro valor < min_avail."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "Desligado"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "Reprodução Alta Fidelidade (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Captação de Alta Fidelidade (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Telefonia Duplex (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "Servidor de Som PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr ""
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+#, fuzzy
+msgid "Input Devices"
+msgstr "Entrada %s"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+#, fuzzy
+msgid "Input"
+msgstr "Entrada %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+#, fuzzy
+msgid "Internal Microphone"
+msgstr "Ãudio Interno"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+msgid "Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+msgid "No Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+#, fuzzy
+msgid "Analog Input"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+#, fuzzy
+msgid "Analog Microphone"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+#, fuzzy
+msgid "Analog Line-In"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+#, fuzzy
+msgid "Analog Radio"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+#, fuzzy
+msgid "Analog Video"
+msgstr "Estéreo Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+#, fuzzy
+msgid "Analog Output"
+msgstr "Saída nula"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+#, fuzzy
+msgid "Analog Headphones"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+#, fuzzy
+msgid "Analog Mono Output"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Estéreo Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, fuzzy, c-format
+msgid "%s+%s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, fuzzy, c-format
+msgid "%s / %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Estéreo Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+#, fuzzy
+msgid "Analog Surround 2.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+#, fuzzy
+msgid "Analog Surround 3.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+#, fuzzy
+msgid "Analog Surround 3.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analog Surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analog Surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+#, fuzzy
+msgid "Analog Surround 6.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+#, fuzzy
+msgid "Analog Surround 6.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+#, fuzzy
+msgid "Analog Surround 7.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analog Surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Estéreo Digital (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+#, fuzzy
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Surround Digital 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Surround Digital 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Surround Digital 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Estéreo Digital (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+#, fuzzy
+msgid "Analog Mono Duplex"
+msgstr "Mono Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+#, fuzzy
+msgid "Analog Stereo Duplex"
+msgstr "Estéreo Analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+#, fuzzy
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Estéreo Digital (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Emissor de Baixa Frequência"
+
+#, fuzzy
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Nome de máquina inválido"
+
+#, fuzzy
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr "não foi possível obter informações da amostra: %s\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "Incapaz de se ligar ao bus de sistema: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "Não foi possível obter chamador a partir do PID: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "Não foi possível definir o UID no objecto chamador."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "Falha ao obter sessão CK."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "Não foi possível definir o UID no objecto da sessão."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "Não é possível alocar PolKitAction."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "impossível definir action_id"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "Não é possível alocar contexto PolKitContext."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "Incapaz de inicializar o PolKitContext: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "Não foi possível determinar se o chamador está autorizado: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "Não foi possível obter autenticação: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit respondeu com '%s'"
+
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Escalonamento de alta-prioridade (nível 'nice' negativo em Unix) para o "
+#~ "serviço PulseAudio"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Escalonamento em tempo-real para o serviço PulseAudio"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "Politica do sistema impede o PulseAudio de obter escalonamento de alta-"
+#~ "prioridade."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "Politica do sistema impede o PulseAudio de obter escalonamento de tempo-"
+#~ "real."
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "read() falhou: %s\n"
+
+#, fuzzy
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "Impossível ligar ao servidor."
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr "Estamos no grupo '%s', permitindo escalonamento de alta-prioridade."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr "Estamos no grupo '%s', permitindo escalonamento em tempo real."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr ""
+#~ "O PolicyKit permite-nos o privilégio \"acquire-high-priority\" (adquirir "
+#~ "alta prioridade)."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr ""
+#~ "O PolicyKit recusa-nos o privilégio \"acquire-high-priority\" (adquirir "
+#~ "alta prioridade)."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr ""
+#~ "O PolicyKit permite-nos o privilégio \"acquire-real-time\" (adquirir "
+#~ "tempo real)."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr ""
+#~ "O PolicyKit recusa-nos o privilégio \"acquire-real-time\" (adquirir tempo "
+#~ "real)."
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "Escalonamento de alta prioridade activo na configuração, mas não "
+#~ "permitido pela politica."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "RLIMIT_RTPRIO aumentado com sucesso"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO falhou: %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "A desistir de CAP_NICE"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "Escalonamento em tempo real activo na configuração, mas não permitido "
+#~ "pela politica."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "Capacidades limitadas com sucesso em CAP_SYS_NICE."
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "time_new() falhou.\n"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Fluxo criado com sucesso\n"
+
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "Erro de fluxo: %s\n"
+
+#~ msgid "Connection established.\n"
+#~ msgstr "Ligação Estabelecida.\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Compilado com libpulse %s\n"
+#~ "Linkado com libpulse %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Mapa de canais inválido\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Falha ao abrir o ficheiro '%s'\n"
+
+#~ msgid "Output %s + Input %s"
+#~ msgstr "Saída %s + Entrada %s"
diff --git a/po/pt_BR.po b/po/pt_BR.po
index c9249a68..d91484df 100644
--- a/po/pt_BR.po
+++ b/po/pt_BR.po
@@ -1,68 +1,30 @@
-# Brazilian Translation of PulseAudio
-# Copyright (C) 2008 pulseaudio
+# Brazilian Portuguese translation of PulseAudio
+# Copyright (C) 2008,2009 pulseaudio
# This file is distributed under the same license as the pulseaudio package.
# Fabian Affolter <fab@fedoraproject.org>, 2008.
+# Igor Pires Soares <igor@projetofedora.org>, 2009.
#
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2008-11-21 01:21-0300\n"
-"Last-Translator: Henrique (LonelySpooky) Junior <lspooky@fedoraproject.org>\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-23 14:42-0300\n"
+"Last-Translator: Igor Pires Soares <igor@projetofedora.org>\n"
"Language-Team: Brazilian-Portuguese <fedora-trans-pt_br@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-"X-Poedit-Language: Brazilian Portuguese\n"
+"X-Poedit-Language: Portuguese\n"
"X-Poedit-Country: Brazil\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr ""
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -70,8 +32,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"O snd_pcm_avail() retornou um valor que é excepcionalmente grande: %lu bytes "
+"(%lu ms).\n"
+"É mais provável que isso seja um erro no driver \"%s\" do ALSA. Por favor, "
+"relate esse problema aos desenvolvedores do ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -79,8 +45,12 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"O snd_pcm_delay() retornou um valor que é excepcionalmente grande: %li bytes "
+"(%s%lu ms).\n"
+"É mais provável que isso seja um erro no driver \"%s\" do ALSA. Por favor, "
+"relate esse problema aos desenvolvedores do ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -88,236 +58,157 @@ msgid ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
msgstr ""
+"O snd_pcm_mmap_begin() retornou um valor que é excepcionalmente grande: %lu "
+"bytes (%lu ms).\n"
+"É mais provável que isso seja um erro no driver \"%s\" do ALSA. Por favor, "
+"relate esse problema aos desenvolvedores do ALSA."
-#: ../src/pulsecore/sink.c:2141
-#, fuzzy
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Sempre manter pelo menos um destino carregado mesmo se for nulo"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Saída fictícia"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Destino Virtual LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<nome do destino> sink_properties=<propriedades do destino> "
+"master=<nome do destino a ser filtrado> format=<formato de amostragem> "
+"rate=<taxa da amostragem> channels=<número de canais> channel_map=<mapa dos "
+"canais> plugin=<nome do plugin ladspa> label=<rótulo do plugin ladspa> "
+"control=<lista separada por vírgulas dos valores de controle da entrada>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Destino nulo temporizado"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Saída nula"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
-msgstr "Erro interno"
+msgstr "Ãudio interno"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
-msgstr ""
+msgstr "Modem"
#: ../src/daemon/ltdl-bind-now.c:124
-#, fuzzy
msgid "Failed to find original lt_dlopen loader."
-msgstr "Falha em encontrar o carregador original dlopen"
+msgstr "Falha ao localizar o carregador original lt_dlopen."
#: ../src/daemon/ltdl-bind-now.c:129
-#, fuzzy
msgid "Failed to allocate new dl loader."
-msgstr "Falha em encontrar o carregador original dlopen"
+msgstr "Falha ao alocar o novo carregador dl."
#: ../src/daemon/ltdl-bind-now.c:142
msgid "Failed to add bind-now-loader."
msgstr "Falha em adicionar o bind-now-loader."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Não foi possível conectar com o barramento do sistema: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Não foi possível obter quem chamou pelo PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Não foi possível definir o UID sobre o objeto que chamou."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Falha em obter a sessão CK."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Não foi possível definir o UID do objeto da sessão."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Não foi possível alocar o PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Não foi possível definir a action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Não foi possível alocar o PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Não foi possível iniciar o PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Não foi possível determinar se o solicitante está autorizado: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Não foi possível obter auth: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit respondeu com '%s'"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Sinal %s recebido."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Saindo."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
-msgstr "Falha em encontrar o usuário '%s'."
+msgstr "Falha ao localizar o usuário \"%s\"."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
-msgstr "Falha em encontrar o grupo '%s'."
+msgstr "Falha ao localizar o grupo \"%s\"."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
-msgstr "Usuário '%s' (UID %lu) e grupo '%s' (GID %lu) encontrados."
+msgstr "Usuário \"%s\" (UID %lu) e grupo \"%s\" (GID %lu) localizados."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "O GID do usuário'%s' e do grupo '%s' não combinam."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
-msgstr "O diretório Home do usuário '%s' não é '%s', ignorando."
+msgstr "O diretório pessoal do usuário \"%s\" não é \"%s\", ignorando."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
-msgstr "Falha em criar '%s': %s"
+msgstr "Falha ao criar \"%s\": %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
-msgstr "Falha em alterar a lista de grupos: %s"
+msgstr "Falha ao alterar a lista de grupos: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
-msgstr "Falha em mudar o GID: %s"
+msgstr "Falha ao alterar o GID: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
-msgstr "Falha em mudar o UID: %s"
+msgstr "Falha ao alterar o UID: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Os privilégios do root foram retirados com sucesso."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "O modo ampliado do sistema não tem suporte nessa plataforma."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) falhou: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Falha em interpretar a linha de comando."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "Estamos no grupo '%s', permitindo escalonamento de alta prioridade."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "Estamos no grupo '%s', permitindo escalonamento em tempo real."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "O PolicyKit assegura-nos a aquisição de privilégio de alta prioridade."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "O PolicyKit recusa a aquisição de privilégios de alta prioridade."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "O PolicyKit assegura-nos a aquisição de privilégios de tempo-real."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "O PolicyKit recusa a aquisição de privilégios de tempo real."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"O escalonamento de alta prioridade foi habilitado para esta configuração, "
-"mas não é permitida pela política."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "RLIMIT_RTPRIO aumentado com sucesso"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO falhou: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Abandonando CAP_NICE"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"O escalonamento de tempo real foi habilitado pela configuração, mas não é "
-"permitido pela política."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "O daemon não está em execução"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Daemon executando como PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Falha em encerrar o daemon: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -325,161 +216,198 @@ msgstr ""
"Este programa não é para ser executado como root (a não ser que --system "
"seja especificado)."
-#: ../src/daemon/main.c:720
-#, fuzzy
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
-msgstr "Privilégios de rot são requeridos."
+msgstr "Privilégios de root requeridos."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start não tem suporte para instâncias de sistemas."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "Executando em no modo system, mas --disallow-exit não foi configurado!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"Executando no modo system, mas --disallow-module-loading não foi configurado!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "Executando no modo system, desabilitando forçadamente o modo SHM!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"Executando no modo system, desabilitando forçadamente o exit idle time!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Falha em adquirir o stdio."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "O pipe falhou: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "O fork() falhou: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "A operação read() falhou: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Falha na partida do daemon."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Os daemons foram iniciados com sucesso."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "A operação read() falhou: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Este é o PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Host de compilação: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "Compilação CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Executando no host: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
-msgstr ""
+msgstr "%u CPUs localizadas."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "O tamanho da página é %lu bytes"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Compilado com suporte do Valgrind: sim"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Compilado com suporte do Valgrind: não"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Executando em modo valgrind: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Executando no host: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Build otimizado: sim"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Build otimizado: não"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr ""
+msgstr "NDEBUG definido, todas as declarações desabilitadas."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr ""
+"FASTPATH definido, somente as declarações do \"fast path\" foram "
+"desabilitadas."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr ""
+msgstr "Todas as declarações habilitadas."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Falha em obter o ID da máquina"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "A ID da máquina é %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "A ID da máquina é %s."
+msgstr "O ID da sessão é %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Usando o diretório de runtime %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Usando o diretório de estado %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Usando o diretório de módulos %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Executando em modo do sistema: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"OK, então você está executando o PA no modo de sistema. Por favor, note que "
+"é mais provável que você não deveria estar fazendo isso.\n"
+"Todavia, se você o fizer, então a culpa será sua se as coisas não "
+"funcionarem como esperado.\n"
+"Por favor, leia o http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode para "
+"obter um explicação sobre porque o modo de sistema é uma má idéia."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() falhou."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Timers de alta resolução frequinhos disponíveis! Bon appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -487,33 +415,33 @@ msgstr ""
"Cara, teu kernel fede! A recomendação do chef hoje é Linux com timers de "
"alta resolução habilitados!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() falhou."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Falha em iniciar o daemon."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
"O Daemon iniciou sem qualquer módulo carregado, recusando-se a trabalhar."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "A partida dos Daemon está completa."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "O encerramento do Daemon foi iniciado."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Daemon terminado."
-#: ../src/daemon/cmdline.c:121
-#, fuzzy, c-format
+#: ../src/daemon/cmdline.c:115
+#, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -594,24 +522,24 @@ msgstr ""
" --dump-modules Descarrega a lista de módulos "
"disponíveis\n"
" --dump-resample-methods Descarrega os métodos de "
-"reamostragem (resample)\n"
+"reamostragem\n"
" --cleanup-shm Limpa os segmentos de memória "
"compartilhados\n"
" --start Inicia o daemon se ele não estiver "
"em execução\n"
" -k --kill Encerra um daemon em execução\n"
-" --check Verifica um daemon em execução\n"
+" --check Verifica se há um daemon em execução "
+"(somente retorna o código de saída)\n"
"\n"
"OPÇÕES:\n"
" --system[=BOOL] Executa como uma instância do "
-"sistema em escala ampla \n"
-" -D, --daemonize[=BOOL] Torna um daemom (daemonize) depois "
-"da partida\n"
+"sistema em escala ampla\n"
+" -D, --daemonize[=BOOL] Torna-se um daemom após o início\n"
" --fail[=BOOL] Sai quando a partida falha\n"
" --high-priority[=BOOL] Tenta definir um nível alto de nice\n"
" (disponível apenas, quando SUID ou\n"
" com RLIMIT_NICE) elevado\n"
-" --realtime[=BOOL] Tenta habilidar o escalonamento em "
+" --realtime[=BOOL] Tenta habilitar o escalonamento em "
"tempo real\n"
" (disponível apenas como root, quando "
"SUID ou\n"
@@ -624,35 +552,40 @@ msgstr ""
" --exit-idle-time=SECS Termina um daemon quando ocioso e "
"este\n"
" tempo foi decorrido\n"
-" --module-idle-time=SECS Descarrega os modulos "
+" --module-idle-time=SECS Descarrega os módulos "
"autocarregáveis quando ociosos e\n"
-" tempo foi decorrido\n"
+" este tempo foi decorrido\n"
" --scache-idle-time=SECS Descarrega amostras quando ociosas "
"e\n"
-" este tempo tenha passado\n"
+" este tempo foi decorrido\n"
" --log-level[=LEVEL] Aumenta ou define o grau de "
-"verbosidade\n"
-" -v Aumenta o nível de verbosidade\n"
-" --log-target={auto,syslog,stderr} Especifica o alvo do log\n"
-" -p, --dl-search-path=PATH Define o caminho de busca (search "
-"paht)para objetos (plugins)\n"
-" dinamicamente commpartilhados\n"
+"detalhamento\n"
+" -v Aumenta o nível de detalhamento\n"
+" --log-target={auto,syslog,stderr} Especifica o destino do log\n"
+" --log-meta[=BOOL] Inclui a localização do código na "
+"mensagem de log\n"
+" --log-time[=BOOL] Inclui carimbos de hora nas "
+"mensagens de log\n"
+" --log-backtrace=FRAMES Inclui um backtrace na mensagem de "
+"log\n"
+" -p, --dl-search-path=PATH Define o caminho de pesquisa para "
+"objetos (plugins)\n"
+" dinamicamente compartilhados\n"
" --resample-method=METHOD Usa o método de reamostragem "
"especificado\n"
" (Veja --dump-resample-methods para\n"
" valores possíveis)\n"
-" --use-pid-file[=BOOL] Cria um arquivo PID file\n"
+" --use-pid-file[=BOOL] Cria um arquivo PID\n"
" --no-cpu-limit[=BOOL] Não instala um limitador de carga de "
-"CPU load em\n"
+"CPU em\n"
" plataformas que o suportem.\n"
-" --disable-shm[=BOOL] Desabilita o suporte a memória "
+" --disable-shm[=BOOL] Desabilita o suporte à memória "
"compartilhada.\n"
"\n"
-"STARTUP SCRIPT:\n"
-" -L, --load=\"MODULE ARGUMENTS\" Carrega um plugin especificado "
-"com\n"
+"SCRIPT DE INÃCIO:\n"
+" -L, --load=\"ARGUMENTOS DO MÓDULO\" Carrega um plugin especificado com\n"
" o argumento especificado\n"
-" -F, --file=FILENAME Executa o script especificado\n"
+" -F, --file=NOME_DO_ARQUIVO Executa o script especificado\n"
" -C Abre uma linha de comando no TTY em "
"execução\n"
" depois da partida\n"
@@ -660,15 +593,15 @@ msgstr ""
" -n Não carrega o arquivo de script "
"padrão\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize espera argumento booleano"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail espera argumento booleano"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -676,55 +609,52 @@ msgstr ""
"--log-level espera um argumento em nível de log (seja numérico na faixa de "
"0..4 seja algum entre debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority espera um argumento booleano"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime espera um argumento booleano"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading espera um argumento booleano"
-#: ../src/daemon/cmdline.c:302
-#, fuzzy
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr "--disallow-exit argumento booleano"
+msgstr "--disallow-exit espera um argumento booleano"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file espera argumento booleano"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "Log target inválido: use 'syslog', 'stderr' ou 'auto'."
-#: ../src/daemon/cmdline.c:333
-#, fuzzy
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr "--realtime espera um argumento booleano"
+msgstr "--log-time espera um argumento booleano"
-#: ../src/daemon/cmdline.c:340
-#, fuzzy
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr "--disallow-exit argumento booleano"
+msgstr "--log-meta espera um argumento booleano"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Método de reamostragem inválido '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system espera argumento booleano"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit espera argumento booleano"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm espera argumento booleano"
@@ -763,357 +693,344 @@ msgstr "Uso: %s\n"
msgid "Load Once: %s\n"
msgstr "Carrega uma vez: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "AVISO DE OBSOLESCÊNCIA: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Caminho: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Alvo do log inválido '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Nível de log inválido '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Método de reamostragem inválido '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] rlimit inválido '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit não tem suporte nessa plataforma."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Formato de amostragem inválido '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Taxa de amostragem inválida '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Canais de amostragem inválidos'%s'."
-#: ../src/daemon/daemon-conf.c:353
-#, fuzzy, c-format
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
-msgstr "[%s:%u] Canais de amostragem inválidos'%s'."
+msgstr "[%s:%u] Mapa de canais \"%s\" inválido."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Números de fragmentos inválidos '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Tamanho de fragmentos inválido '%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Número de nice inválido'%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Taxa de amostragem inválida '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Falha em abrir o arquivo de configuração: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr ""
+"O mapa padrão dos canais especificado tem um número diferente de canais do "
+"que o número de canais padrão especificado."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Lido do arquivo de configuração: %s ###\n"
-#: ../src/daemon/caps.c:63
-#, fuzzy
-msgid "Dropping root privileges."
-msgstr "Descartando os privilégios de root."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "As capacidades foram limitadas com sucesso para CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "Limpando privilégios."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
-msgstr ""
+msgstr "Sistema de som PulseAudio"
#: ../src/daemon/pulseaudio.desktop.in.h:2
msgid "Start the PulseAudio Sound System"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-#, fuzzy
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Falha em cancelar o daemon do PulseAudio."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-#, fuzzy
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr "Estamos no grupo '%s', permitindo escalonamento de alta prioridade."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
+msgstr "Iniciar o sistema de som PulseAudio"
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
-msgstr "Fronto-cental"
+msgstr "Frontal central"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Frontal esquerdo"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Frontal direito"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Posterior central"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Posterior esquerdo"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Posterior direito"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Emissor de baixa freqüência"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Frontal Esquerdo do centro"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Frontal Direito do centro"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Lateral esquedo"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Lateral direito"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Auxiliar 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Auxiliar 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Auxiliar 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Auxiliar 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Auxiliar 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Auxiliar 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Auxiliar 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Auxiliar 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Auxiliar 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Auxiliar 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Auxiliar 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Auxiliar 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Auxiliar 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Auxiliar13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Auxiliar 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Auxiliar 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Auxiliar 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Auxiliar 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Auxiliar 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Auxiliar 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Auxiliar 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Auxiliar 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Auxiliar 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Auxiliar 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Auxiliar 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Auxiliar 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Auxiliar 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Auxiliar 26"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Auxiliar 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Auxiliar 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Auxiliar 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Auxiliar 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
-msgstr "Central Superior"
+msgstr "Central superior"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
-msgstr "Central Frontal Superior"
+msgstr "Central frontal superior"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
-msgstr "Frontal Superior Esquerdo"
+msgstr "Frontal superior esquerdo"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
-msgstr "Fontal Superior Direito"
+msgstr "Fontal superior direito"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
-msgstr "Central Superior Posterior"
+msgstr "Central superior posterior"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
-msgstr "Posterior Superior Esquerdo"
+msgstr "Posterior superior esquerdo"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
-msgstr "Posterior Superior Direito"
+msgstr "Posterior superior direito"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(Inválido)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
-msgstr ""
+msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
-msgstr ""
+msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
-msgstr ""
+msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
-msgstr ""
+msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
-msgstr ""
+msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
-msgstr ""
+msgstr "Surround 7.1"
#: ../src/pulse/error.c:43
msgid "OK"
@@ -1121,7 +1038,7 @@ msgstr "OK"
#: ../src/pulse/error.c:44
msgid "Access denied"
-msgstr "Acesso Negado"
+msgstr "Acesso negado"
#: ../src/pulse/error.c:45
msgid "Unknown command"
@@ -1205,40 +1122,48 @@ msgstr "Não existe tal extensão"
#: ../src/pulse/error.c:65
msgid "Obsolete functionality"
-msgstr ""
+msgstr "Funcionalidade obsoleta"
#: ../src/pulse/error.c:66
msgid "Missing implementation"
-msgstr ""
+msgstr "Implementação faltando"
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr ""
+msgstr "Cliente bifurcado"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Erro de entrada/saída"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Dispositivo ou recurso ocupado"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
-msgstr ""
+msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
-msgstr ""
+msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
-msgstr ""
+msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
-msgstr ""
+msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
-msgstr ""
+msgstr "%u B"
#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
msgid "XOpenDisplay() failed"
@@ -1248,197 +1173,191 @@ msgstr "XOpenDisplay() falhou"
msgid "Failed to parse cookie data"
msgstr "Falhou ao analisar os dados do cookie"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Falha em abrir o arquivo de configuração '%s': %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Nenhum cookie foi carregado. Tentativa de conexão sem eles."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Foi recebida uma mensagem para uma extensão desconhecida '%s'"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() falhou: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Falha ao drenar o fluxo: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() falhou: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Fluxo de reprodução drenado."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "O fluxo (stream) foi criado com sucesso.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Drenando conexão para o servidor."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() falhou: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Metrica do buffer: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() falhou: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Métrica do buffer: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() falhou: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Usando a espeficifação de amostragem '%s', mapa do canal '%s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() falhou: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Conectado ao dispositivo %s (%u, %ssuspended).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Fluxo criado com sucesso."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Erro de fluxo: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() falhou: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Dispositivo de fluxo suspenso.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Métricas do buffer: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Dispositivo de fluxo prosseguiu.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Métricas do buffer: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Extravazamento do fluxo. %s\n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Usando especificação de amostragem \"%s\", mapa de canais \"%s\"."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "O fluxo extravazou.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Conectado ao dispositivo %s (%u, %ssuspended)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "O fluxo iniciou: %s\n"
+msgid "Stream error: %s"
+msgstr "Erro de fluxo: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "O fluxo foi movido para o dispositivo %s (%u, %ssuspended).%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "não"
+msgid "Stream device suspended.%s"
+msgstr "Dispositivo de fluxo suspenso.%s"
-#: ../src/utils/pacat.c:245
-#, fuzzy, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Extravazamento do fluxo. %s\n"
-
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Conexão estabelecida.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "O dispositivo de fluxo continuou.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() falhou: %s\n"
+msgid "Stream underrun.%s"
+msgstr "Subestimação do fluxo.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() falhou: %s\n"
+msgid "Stream overrun.%s"
+msgstr "Superestimação do fluxo.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() falhou: %s\n"
+msgid "Stream started.%s"
+msgstr "Fluxo iniciado.%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Falha na conexão: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Fluxo movido para o dispositivo %s (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Falha em drenar o fluxo: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "não"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Drenado o fluxo de playback.\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Atributos do buffer de fluxo alterados.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Drenando a conexão par ao servidor.\n"
+msgid "Connection established.%s"
+msgstr "Conexão estabelecida.%s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Got EOF.\n"
-msgstr "Atingiu EOF.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() falhou: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() falhou: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() falhou: %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() falhou: %s"
-#: ../src/utils/pacat.c:438
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() falhou: %s\n"
+msgid "Connection failure: %s"
+msgstr "Falha na conexão: %s"
-#: ../src/utils/pacat.c:459
-#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Sinal recebido, saindo (exiting).\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Atingiu EOF."
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Falhou em obter a latência: %s\n"
+msgid "write() failed: %s"
+msgstr "write() falhou: %s"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Sinal recebido, saindo."
+
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Tempo: %0.3f s; Latência: %0.0f us. \r"
+msgid "Failed to get latency: %s"
+msgstr "Falha ao obter a latência: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "Falha em pa_stream_update_timing_info(): %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Tempo: %0.3f sec;; Latência: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() falhou: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1464,8 +1383,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1488,6 +1409,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [opções]\n"
"\n"
@@ -1495,46 +1425,60 @@ msgstr ""
" --version Mostra a versão\n"
"\n"
" -r, --record Cria uma conexão para gravação\n"
-" -p, --playback Cria uma conexão para playback\n"
+" -p, --playback Cria uma conexão para reprodução\n"
"\n"
-" -v, --verbose Habilita operações no modo verboso\n"
+" -v, --verbose Habilita operações no modo "
+"detalhado\n"
"\n"
-" -s, --server=SERVER Nome do servidor a ser conectado\n"
-" -d, --device=DEVICE O nome do destino/fonte a conectar\n"
-" -n, --client-name=NAME Como chamar o cliente no servidor\n"
-" --stream-name=NAME Como chamar este fluxo no "
-"servidorn --volume=VOLUME Especifica a faixa (linear) "
-"inicial de volume no intervalo 0...65536\n"
-" --rate=SAMPLERATE Taxa de amostragem em Hz (o padrão é "
-"44100)\n"
-" --format=SAMPLEFORMAT Tipo de amostragem, um de s16le, "
+" -s, --server=SERVIDOR Nome do servidor a conectar-se\n"
+" -d, --device=DISPOSITIVO O nome do destino/fonte a "
+"conectar-se\n"
+" -n, --client-name=NOME Como chamar este cliente no "
+"servidor\n"
+" --stream-name=NOME Como chamar este fluxo no servidor\n"
+" --volume=VOLUME Especifica a faixa (linear) inicial "
+"de volume no intervalo 0...65536\n"
+" --rate=TAXA_DE_AMOSTRAGEM Taxa de amostragem em Hz (o "
+"padrão é 44100)\n"
+" --format=FORMATO_DE_AMOSTRAGEM Tipo de amostragem, um de s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(o padrão é s16ne)\n"
-" --channels=CHANNELS O número de canais, 1 para mono, 2 "
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (o padrão é "
+"s16ne)\n"
+" --channels=CANAIS O número de canais, 1 para mono, 2 "
"para estéreo\n"
" (o padrão é 2)\n"
-" --channel-map=CHANNELMAP Mapeamento de canais a ser usando em "
-"lugar do padrão\n"
+" --channel-map=MAPA_DE_CANAIS Mapeamento de canais a ser usado "
+"no lugar do padrão\n"
" --fix-format Obtém o formato da amostragem do "
"destino onde o fluxo\n"
-" está sendo conectado.\n"
-" --fix-rate Obtém o taxa de amostragem do "
+" está sendo conectado.\n"
+" --fix-rate Obtém a taxa de amostragem do "
"destino onde o fluxo está\n"
" sendo conectado.\n"
" --fix-channels Obtém o número de canais e o mapa de "
"canais\n"
" do destino onde o fluxo está sendo "
"conectado.\n"
-" --no-remix Don't upmix or downmix channels.\n"
-" --no-remap Map channels by index instead of "
-"name.\n"
-" --latency=BYTES Request the specified latency in "
-"bytes.\n"
-" --process-time=BYTES Request the specified process time "
-"per request in bytes.\n"
-
-#: ../src/utils/pacat.c:612
+" --no-remix Não realizar upmix nem downmix dos "
+"canais.\n"
+" --no-remap Mapear os canais por índice em vez "
+"de nome.\n"
+" --latency=BYTES Requisitar a latência especificada "
+"em bytes.\n"
+" --process-time=BYTES Requisitar o tempo de processo "
+"especificado por requisições em bytes.\n"
+" --property=PROPRIEDADE=VALOR Define a propriedade especificada "
+"para o valor especificado.\n"
+" --raw Grava/reproduz dados PCM não "
+"tratados.\n"
+" --file-format=FORMATO_DO_ARQ. Grava/reproduz dados PCM "
+"formatados.\n"
+" --list-file-formats Lista os formatos de arquivo "
+"disponíveis.\n"
+
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1545,131 +1489,175 @@ msgstr ""
"Compilado com libpulse %s\n"
"Linkado com libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Mapa de canal inválido '%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "Nome do cliente \"%s\" inválido"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Especificação de latência inválida '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "Nome do fluxo \"%s\" inválido"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Especificação do tempo do processo inválida '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "Mapa de canais \"%s\" inválido"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Especificação de amostragem inválida\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Especificação de latência inválida \"%s\""
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "O mapeamento do canal não casa com a especificação da amostragem\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Especificação do tempo de processo \"%s\" inválida"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Abrindo um %s fluxo com a especificação de amostragem '%s'.\n"
+msgid "Invalid property '%s'"
+msgstr "Propriedade \"%s\" inválida"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "gravando"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Formato de arquivo %s desconhecido."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "playback"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Especificação de amostragem inválida"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Argumentos em excesso.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Argumentos em excesso."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() falhou.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Falha ao gerar a especificação de amostragem para o arquivo."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() falhou.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Falha ao abrir o arquivo de áudio."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() falhou.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Aviso: a especificação de amostragem especificada será sobrescrita pela "
+"especificação do arquivo."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_new() falhou: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Falha ao determinar a especificação de amostragem a partir do arquivo."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Aviso: falha ao determinar o mapa de canais a partir do arquivo."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "O mapa de canais não combina com a especificação da amostragem"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Aviso: falha ao gravar o mapa de canais no arquivo."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() falhou.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Abrindo um fluxo %s com a especificação de amostragem \"%s\" e mapeamento de "
+"canais \"%s\"."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "gravando"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "playback"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() falhou."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() falhou."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() falhou."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() falhou.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_new() falhou: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() falhou."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() falhou."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Falha em suspender: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Falha ao prosseguir: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr ""
"AVISO: O servidor de som não é local, Sound server is not local, não está em "
"suspenso.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Falha na conexão: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Recebido o SIGINT, saindo.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "AVISO: O processo filho terminou pelo sinal %u \n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1687,7 +1675,7 @@ msgstr ""
" -s, --server=SERVER Nome do servidor a ser conectado\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1698,35 +1686,61 @@ msgstr ""
"Compilado com libpulse %s\n"
"Linkado com libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() falhou.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() falhou.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() falhou.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Falha em obter as estatísticas: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "Falha ao obter estatísticas: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Em uso no momento: %u blocos contendo %s bytes no total.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "Alocado por todo o tempo: %u blocos contendo %s bytes no total.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Tamanho do cache para amostragem: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Falha em obter a informação do servidor: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Falha ao obter informações do servidor: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
#, fuzzy, c-format
msgid ""
-"User name: %s\n"
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1734,24 +1748,25 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
-"Nome do Usuário: %s\n"
-"Nome do Host: %s\n"
-"Nome do Servidor: %s\n"
-"Versão do Servidor: %s\n"
+"Nome do usuário: %s\n"
+"Nome da máquina: %s\n"
+"Nome do servidor: %s\n"
+"Versão do servidor: %s\n"
"Especificação padrão de amostragem: %s\n"
+"Mapa de canais padrão: %s\n"
"Destino padrão: %s\n"
"Fonte padrão %s\n"
"Cookie: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Falha em obter a informação do destino: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Falha ao obter informações do destino: %s"
-#: ../src/utils/pactl.c:194
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:234
+#, c-format
msgid ""
"Sink #%u\n"
"\tState: %s\n"
@@ -1771,26 +1786,41 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Destino #%u ***\n"
-"Nome: %s\n"
-"Driver: %s\n"
-"Especificação de amostragem: %s\n"
-"Mapa de canais: %s\n"
-"Propretário do módulo: %u\n"
-"Volume: %s\n"
-"Fonte do monitor: %s\n"
-"Latência: %0.0f us, configurado %0.0f us\n"
-"Flags: %s%s%s%s%s%s\n"
-"Propriedades:\n"
-"%s"
-
-#: ../src/utils/pactl.c:258
-#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Falha em obter a informação da fonte: %s\n"
-
-#: ../src/utils/pactl.c:274
-#, fuzzy, c-format
+"Destino #%u\n"
+"\tEstado: %s\n"
+"\tNome: %s\n"
+"\tDescrição: %s\n"
+"\tDriver: %s\n"
+"\tEspecificação da amostragem: %s\n"
+"\tMapa dos canais: %s\n"
+"\tMódulo proprietário: %u\n"
+"\tMudo: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balanço %0.2f\n"
+"\tVolume base: %s%s%s\n"
+"\tFonte de monitoração: %s\n"
+"\tLatência: %0.0f usec, %0.0f usec configurado\n"
+"\tSinalizadores: %s%s%s%s%s%s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPortas:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tPorta ativa: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Falha ao obter informações da fonte: %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
msgid ""
"Source #%u\n"
"\tState: %s\n"
@@ -1810,34 +1840,39 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Fonte #%u ***\n"
-"Nome: %s\n"
-"Driver: %s\n"
-"Especificação de amostragem: %s\n"
-"Mapa do canal: %s\n"
-"Proprietário do módulo: %u\n"
-"Volume: %s\n"
-"Monitor do destino: %s\n"
-"Latência: %0.0f us, configurado %0.0f us:\n"
-"Flags: %s%s%s%s%s%s\n"
-"Propriedades:\n"
-"%s"
-
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+"Fonte #%u\n"
+"\tEstado: %s\n"
+"\tNome: %s\n"
+"\tDescrição: %s\n"
+"\tDriver: %s\n"
+"\tEspecificação da amostragem: %s\n"
+"\tMapa dos canais: %s\n"
+"\tMódulo proprietário: %u\n"
+"\tMudo: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balanço %0.2f\n"
+"\tVolume base: %s%s%s\n"
+"\tMonitor do destino: %s\n"
+"\tLatência: %0.0f usec, %0.0f usec configurado\n"
+"\tSinalizadores: %s%s%s%s%s%s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Falha em obter a informação do módulo: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Falha ao obter informações do módulo: %s"
-#: ../src/utils/pactl.c:342
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:406
+#, c-format
msgid ""
"Module #%u\n"
"\tName: %s\n"
@@ -1846,19 +1881,20 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Módulo #%u ***\n"
-"Nome: %s\n"
-"Argumento: %s\n"
-"Contador de uso: %s\n"
-"Auto descarregar: %s\n"
+"Módulo #%u\n"
+"\tNome: %s\n"
+"\tArgumento: %s\n"
+"\tContador de uso: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Falhou ao obter a informação do cliente: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Falha ao obter informações do cliente: %s"
-#: ../src/utils/pactl.c:379
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:443
+#, c-format
msgid ""
"Client #%u\n"
"\tDriver: %s\n"
@@ -1866,19 +1902,19 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Cliente #%u ***\n"
-"Driver: %s\n"
-"Poprietário do módulo: %s\n"
-"Propriedades:\n"
-"%s"
+"Cliente #%u\n"
+"\tDriver: %s\n"
+"\tMódulo proprietário: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:396
-#, fuzzy, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Falha em obter a informação do autoload: %s\n"
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "Falha ao obter informações da placa: %s"
-#: ../src/utils/pactl.c:414
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:478
+#, c-format
msgid ""
"Card #%u\n"
"\tName: %s\n"
@@ -1887,29 +1923,30 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Cliente #%u ***\n"
-"Driver: %s\n"
-"Poprietário do módulo: %s\n"
-"Propriedades:\n"
-"%s"
+"Placa #%u\n"
+"\tNome: %s\n"
+"\tDriver: %s\n"
+"\tMódulo proprietário: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
-msgstr ""
+msgstr "\tPerfis:\n"
-#: ../src/utils/pactl.c:434
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:498
+#, c-format
msgid "\tActive Profile: %s\n"
-msgstr "O pipe falhou: %s"
+msgstr "\tPerfil ativo: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Falha na obtenção da informação de entrada do destino: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Falha ao obter informações da entrada do destino: %s"
-#: ../src/utils/pactl.c:464
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:528
+#, c-format
msgid ""
"Sink Input #%u\n"
"\tDriver: %s\n"
@@ -1928,27 +1965,30 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Entrada do destino #%u ***\n"
-"Driver: %s\n"
-"Proprietário do módulo: %s\n"
-"Cliente: %s\n"
-"Destino: %u\n"
-"Especificação da amostragem: %s\n"
-"Mapa de canais: %s\n"
-"Volume: %s\n"
-"Latência do buffer: %0.0f us\n"
-"Latência do destino %0.0f usec\n"
-"Método de reamostragem (resample): %s\n"
-"Propriedades:\n"
-"%s"
-
-#: ../src/utils/pactl.c:503
-#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Falha em obter informações sobre a saída da fonte: %s\n"
-
-#: ../src/utils/pactl.c:523
-#, fuzzy, c-format
+"Entrada do destino #%u\n"
+"\tDriver: %s\n"
+"\tMódulo proprietário: %s\n"
+"\tCliente: %s\n"
+"\tDestino: %u\n"
+"\tEspecificação da amostragem: %s\n"
+"\tMapa dos canais: %s\n"
+"\tMudo: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balanço %0.2f\n"
+"\tLatência do buffer: %0.0f usec\n"
+"\tLatência do destino: %0.0f usec\n"
+"\tMétodo de reamostragem: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "Falha ao obter informações da saída da fonte: %s"
+
+#: ../src/utils/pactl.c:587
+#, c-format
msgid ""
"Source Output #%u\n"
"\tDriver: %s\n"
@@ -1963,26 +2003,26 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Saída da Fonte #%u ***\n"
-"Driver: %s\n"
-"Proprietário do Módulo: %s\n"
-"Cliente: %s\n"
-"Fonte: %u\n"
-"Especificação de Amostragem: %s\n"
-"Mapa do Canal: %s\n"
-"Latência do Buffer: %0.0f usec\n"
-"Latência da Fonte: %0.0f usec\n"
-"Método de Reamostragem (resample): %s\n"
-"Propriedades:\n"
-"%s"
-
-#: ../src/utils/pactl.c:554
-#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Falha em obter informações sobre a amostragem: %s\n"
-
-#: ../src/utils/pactl.c:572
-#, fuzzy, c-format
+"Saída da fonte #%u\n"
+"\tDriver: %s\n"
+"\tMódulo proprietário: %s\n"
+"\tCliente: %s\n"
+"\tFonte: %u\n"
+"\tEspecificação da amostragem: %s\n"
+"\tMapa dos canais: %s\n"
+"\tLatência do buffer: %0.0f usec\n"
+"\tLatência da fonte: %0.0f usec\n"
+"\tMétodo de reamostragem: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "Falha ao obter informações sobre a amostragem: %s"
+
+#: ../src/utils/pactl.c:636
+#, c-format
msgid ""
"Sample #%u\n"
"\tName: %s\n"
@@ -1998,34 +2038,94 @@ msgid ""
"\tProperties:\n"
"\t\t%s\n"
msgstr ""
-"*** Amostragem #%u ***\n"
-"Nome: %s\n"
-"Volume: %s\n"
-"Especificação da Amostragem: %s\n"
-"Mapa de Canais: %s\n"
-"Duração: %0.1fs\n"
-"Tamanho: %s\n"
-"Lazy: %s\n"
-"Nome do Arquivo: %s\n"
-"Propriedades:\n"
-"%s"
-
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
-#, c-format
-msgid "Failure: %s\n"
-msgstr "Falha: %s\n"
+"Amostra #%u\n"
+"\tNome: %s\n"
+"\tEspecificação da amostragem: %s\n"
+"\tMapa dos canais: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balanço %0.2f\n"
+"\tDuração: %0.1fs\n"
+"\tTamanho: %s\n"
+"\tLazy: %s\n"
+"\tNome do arquivo: %s\n"
+"\tPropriedades:\n"
+"\t\t%s\n"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "Falha: %s"
+
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Falha em carregar a amostra: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Falha ao enviar a amostra: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Fim prematuro do arquivo"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr "destino"
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr "fonte"
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+#, fuzzy
+msgid "source-output"
+msgstr "fonte"
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Servidor inválido"
-#: ../src/utils/pactl.c:653
+#: ../src/utils/pactl.c:787
#, c-format
-msgid "Premature end of file\n"
-msgstr "Fim prematuro do arquivo\n"
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT recebido, saindo."
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:961
#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
@@ -2034,13 +2134,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2050,27 +2159,37 @@ msgid ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
msgstr ""
-"%s [options] stat\n"
-"%s [options] list\n"
-"%s [options] exit\n"
-"%s [options] upload-sample FILENAME [NAME]\n"
-"%s [options] play-sample NAME [SINK]\n"
-"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
-"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
+"%s [opções] stat\n"
+"%s [opções] list\n"
+"%s [opções] exit\n"
+"%s [opções] upload-sample NOME_DO_ARQUIVO [NOME]\n"
+"%s [opções] play-sample NOME [DESTINO]\n"
+"%s [opções] remove-sample NOME\n"
+"%s [opções] move-sink-input ENTRADA DESTINO\n"
+"%s [opções] move-source-output SAÃDA FONTE\n"
+"%s [opções] load-module NOME [ARGS ...]\n"
+"%s [opções] unload-module MÓDULO\n"
+"%s [opções] suspend-sink [DESTINO] 1|0\n"
+"%s [opções] suspend-source [FONTE] 1|0\n"
+"%s [opções] set-card-profile [PLACA] [PERFIL]\n"
+"%s [opções] set-sink-port [DESTINO] [PORTA]\n"
+"%s [opções] set-source-port [FONTE] [PORTA]\n"
+"%s [opções] set-sink-volume DESTINO VOLUME\n"
+"%s [opções] set-source-volume FONTE VOLUME\n"
+"%s [opções] set-sink-input-volume ENTRADA VOLUME\n"
+"%s [opções] set-sink-mute DESTINO 1|0\n"
+"%s [opções] set-source-mute FONTE 1|0\n"
+"%s [opções] set-sink-input-mute ENTRADA 1|0\n"
"\n"
" -h, --help Mostra essa ajuda\n"
" --version Mostra a versão\n"
"\n"
-" -s, --server=SERVER O nome do servidor a ser conectado\n"
-" -n, --client-name=NAME Como chamar este cliente no "
+" -s, --server=SERVIDOR O nome do servidor a ser "
+"conectado\n"
+" -n, --client-name=NOME Como chamar este cliente no "
"servidor \n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2081,80 +2200,113 @@ msgstr ""
"Compilado com libpulse %s\n"
"Linkado com libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Por favor, especifique o arquivo de amostra a ser carregado\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Por favor, especifique um arquivo de amostra a ser carregado"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Falha em abrir o arquivo de som.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Falha ao abrir o arquivo de som."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Você deve especificar um nome da amostra para ser executada\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+"Aviso: falha ao determinar a especificação da amostragem a partir do arquivo."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Você deve especificar um nome da amostra para ser removida\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Você deve especificar um nome para amostra a ser reproduzida"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr ""
-"Você tem que especificar a entrada para o destino (sink) e um destino(sink)\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Você deve especificar um nome para a amostra a ser removida"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Você tem que especificar um índice de saída da fonte e uma fonte\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Você deve especificar a entrada do destino e um destino"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Você deve especificar um nome do módulo e seus argumentos\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Você deve especificar um índice de saída da fonte e uma fonte"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Você deve especificar um índice de um módulo\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Você deve especificar um nome para o módulo e seus argumentos."
-#: ../src/utils/pactl.c:972
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Você deve especificar um índice do módulo"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"Você não pode especificar mais de um destino. Pelo menos um valor booleano "
-"deve ser especificado.\n"
+"Você não pode especificar mais de um destino. Você deve especificar um valor "
+"booleano."
-#: ../src/utils/pactl.c:985
-#, fuzzy, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"Você não pode especificar mais de uma fonte. Pelo menos um valor booleano "
-"deve ser especificado.\n"
+"Você não pode especificar mais de uma fonte. Você deve especificar um valor "
+"booleano."
-#: ../src/utils/pactl.c:997
-#, fuzzy, c-format
-msgid "You have to specify a card name/index and a profile name\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Você deve especificar um nome/índice para a placa e um nome de perfil"
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Você deve especificar um nome/índice do destino e o nome da porta"
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Você deve especificar um nome/índice da fonte e o nome da porta"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Você deve especificar um nome/índice do destino e um volume"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Especificação de volume inválida"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Você deve especificar um nome/índice da fonte e um volume"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Você deve especificar um índice de entrada para o destino e um volume"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ãndice de entrada de destino inválido"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Você deve especificar um nome/índice do destino e um booleano do mudo"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Você deve especificar um nome/índice da fonte e um booleano do mudo"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
msgstr ""
-"Você tem que especificar a entrada para o destino (sink) e um destino(sink)\n"
+"Você deve especificar um índice de entrada para o destino e um booleano do "
+"mudo"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Nenhum comando válido especificado.\n"
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Especificação do índice de entrada de destino inválida"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_new() falhou: %s"
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Nenhum comando válido especificado."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2236,127 +2388,50 @@ msgstr "Falha em carregar os dados do cookie\n"
msgid "Not yet implemented.\n"
msgstr "Ainda não implementado.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Nenhum daemon do PulseAudio em execução ou não está em execução como daemon "
+"de sessão."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
-msgstr "Falha em cancelar o daemon do PulseAudio."
+msgstr "Falha ao matar o daemon do PulseAudio."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
-msgstr "Daemon não responde."
+msgstr "O daemon não responde."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Fluxo criado com sucesso\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Erro de fluxo: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Conexão estabelecida.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Mostra essa ajuda\n"
-" --version Mostra a versão\n"
-"\n"
-" -v, --verbose Habilida a operação detalhada\n"
-"\n"
-" -s, --server=SERVER O nome do servidor a ser conectado\n"
-" -d, --device=DEVICE O nome do destino a ser conectado\n"
-" -n, --client-name=NAME Como chamar este cliente no "
-"servidor\n"
-" --stream-name=NAME Como chamar este fluxo no servidor\n"
-" --volume=VOLUME Especifica o volume inicial (linear) "
-"no intervalo 0...65536\n"
-" --channel-map=CHANNELMAP Define o mapa do canal para uso\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Compilado com libpulse %s\n"
-"Linkado com libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Mapa de canais inválido\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Falha ao abrir o arquivo '%s'\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "O mapa dos canais não coincide com o arquivo.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Usando a especificação da amostragem '%s'\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Não foi possível acessar a trava de autogeração."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2366,8 +2441,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"O ALSA nos acordou para gravar novos dados no dispositivo, mas não há nada a "
+"ser gravado!\n"
+"É mais provável que isso seja um erro no driver \"%s\" do ALSA. Por favor, "
+"relate esse problema para os desenvolvedores do ALSA.\n"
+"Nós fomos acordados com o conjunto POLLOUT -- entretanto, a snd_pcm_avail() "
+"subseqüente retornou 0 ou outro valor < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2377,39 +2458,460 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"O ALSA nos acordou para ler novos dados no dispositivo, mas não há nada a "
+"ser lido!\n"
+"É mais provável que isso seja um erro no driver \"%s\" do ALSA. Por favor, "
+"relate esse problema para os desenvolvedores do ALSA.\n"
+"Nós fomos acordados com o conjunto POLLIN -- entretanto, a snd_pcm_avail() "
+"subseqüente retornou 0 ou outro valor < min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr ""
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
-msgstr ""
+msgstr "Desligado"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
-msgstr ""
+msgstr "Reprodução de alta fidelidade (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Captura de alta fidelidade (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Duplex telefônico (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
+msgstr "Servidor de som PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Dispositivos de saída"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Dispositivos de entrada"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Ãudio em @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Entrada"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Entrada da base de encaixe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Microfone da base de encaixe"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Entrada de linha"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Microfone"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Microfone externo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Microfone interno"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Rádio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Vídeo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Ganho de controle automático"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Sem ganho de controle automático"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Impulso"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Sem impulso"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Amplificador"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Sem amplificador"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Impulso"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Sem impulso"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
msgstr ""
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Fones de ouvido analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Entrada analógica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Microfone analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Entrada de linha analógica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Rádio analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Vídeo analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Saída analógica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Fones de ouvido analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Saída analógica (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Saída analógica monofônica"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Estéreo analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Monofônico analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Estéreo analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Surround analógico 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Surround analógico 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Surround analógico 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Surround analógico 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Surround analógico 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Surround analógico 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Surround analógico 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Surround analógico 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Surround analógico 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Surround analógico 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Surround analógico 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Estéreo digital (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Surround 4.0 digital (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Surround digital 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Surround digital 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Estéreo digital (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Duplex monofônico analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Duplex estéreo analógico"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Duplex estéreo digital (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Emissor de baixa freqüência"
+
+#~ msgid "Invalid client name '%s'\n"
+#~ msgstr "Nome do cliente \"%s\" inválido\n"
+
+#~ msgid "Failed to determine sample specification from file.\n"
+#~ msgstr ""
+#~ "Falha ao determinar a especificação de amostragem a partir do arquivo.\n"
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "Cannot connect to system bus: %s"
+#~ msgstr "Não foi possível conectar com o barramento do sistema: %s"
+
+#~ msgid "Cannot get caller from PID: %s"
+#~ msgstr "Não foi possível obter quem chamou pelo PID: %s"
+
+#~ msgid "Cannot set UID on caller object."
+#~ msgstr "Não foi possível definir o UID sobre o objeto que chamou."
+
+#~ msgid "Failed to get CK session."
+#~ msgstr "Falha em obter a sessão CK."
+
+#~ msgid "Cannot set UID on session object."
+#~ msgstr "Não foi possível definir o UID do objeto da sessão."
+
+#~ msgid "Cannot allocate PolKitAction."
+#~ msgstr "Não foi possível alocar o PolKitAction."
+
+#~ msgid "Cannot set action_id"
+#~ msgstr "Não foi possível definir a action_id"
+
+#~ msgid "Cannot allocate PolKitContext."
+#~ msgstr "Não foi possível alocar o PolKitContext."
+
+#~ msgid "Cannot initialize PolKitContext: %s"
+#~ msgstr "Não foi possível iniciar o PolKitContext: %s"
+
+#~ msgid "Could not determine whether caller is authorized: %s"
+#~ msgstr "Não foi possível determinar se o solicitante está autorizado: %s"
+
+#~ msgid "Cannot obtain auth: %s"
+#~ msgstr "Não foi possível obter auth: %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit respondeu com '%s'"
+
+#~ msgid ""
+#~ "High-priority scheduling (negative Unix nice level) for the PulseAudio "
+#~ "daemon"
+#~ msgstr ""
+#~ "Escalonamento de alta prioridade (nível de nice Unix negativo) para o "
+#~ "daemon do PulseAudio"
+
+#~ msgid "Real-time scheduling for the PulseAudio daemon"
+#~ msgstr "Escalonamento em tempo real para o daemon do PulseAudio"
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring high-priority scheduling."
+#~ msgstr ""
+#~ "Uma política do sistema impede que o PulseAudio adquira escalonamento de "
+#~ "alta prioridade."
+
+#~ msgid ""
+#~ "System policy prevents PulseAudio from acquiring real-time scheduling."
+#~ msgstr ""
+#~ "Uma política do sistema impede que o PulseAudio adquira o escalonamento "
+#~ "em tempo real."
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "read() falhou: %s\n"
+
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "pa_context_connect() falhou: %s\n"
+
+#~ msgid "We're in the group '%s', allowing high-priority scheduling."
+#~ msgstr "Estamos no grupo '%s', permitindo escalonamento de alta prioridade."
+
+#~ msgid "We're in the group '%s', allowing real-time scheduling."
+#~ msgstr "Estamos no grupo '%s', permitindo escalonamento em tempo real."
+
+#~ msgid "PolicyKit grants us acquire-high-priority privilege."
+#~ msgstr ""
+#~ "O PolicyKit assegura-nos a aquisição de privilégio de alta prioridade."
+
+#~ msgid "PolicyKit refuses acquire-high-priority privilege."
+#~ msgstr "O PolicyKit recusa a aquisição de privilégios de alta prioridade."
+
+#~ msgid "PolicyKit grants us acquire-real-time privilege."
+#~ msgstr "O PolicyKit assegura-nos a aquisição de privilégios de tempo-real."
+
+#~ msgid "PolicyKit refuses acquire-real-time privilege."
+#~ msgstr "O PolicyKit recusa a aquisição de privilégios de tempo real."
+
+#~ msgid ""
+#~ "High-priority scheduling enabled in configuration but not allowed by "
+#~ "policy."
+#~ msgstr ""
+#~ "O escalonamento de alta prioridade foi habilitado para esta configuração, "
+#~ "mas não é permitida pela política."
+
+#~ msgid "Successfully increased RLIMIT_RTPRIO"
+#~ msgstr "RLIMIT_RTPRIO aumentado com sucesso"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO falhou: %s"
+
+#~ msgid "Giving up CAP_NICE"
+#~ msgstr "Abandonando CAP_NICE"
+
+#~ msgid ""
+#~ "Real-time scheduling enabled in configuration but not allowed by policy."
+#~ msgstr ""
+#~ "O escalonamento de tempo real foi habilitado pela configuração, mas não é "
+#~ "permitido pela política."
+
+#~ msgid "Limited capabilities successfully to CAP_SYS_NICE."
+#~ msgstr "As capacidades foram limitadas com sucesso para CAP_SYS_NICE."
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "time_new() falhou.\n"
+
+#~ msgid "Stream successfully created\n"
+#~ msgstr "Fluxo criado com sucesso\n"
+
+#~ msgid "Stream errror: %s\n"
+#~ msgstr "Erro de fluxo: %s\n"
+
+#~ msgid "Connection established.\n"
+#~ msgstr "Conexão estabelecida.\n"
+
+#~ msgid ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Show this help\n"
+#~ " --version Show version\n"
+#~ "\n"
+#~ " -v, --verbose Enable verbose operation\n"
+#~ "\n"
+#~ " -s, --server=SERVER The name of the server to connect "
+#~ "to\n"
+#~ " -d, --device=DEVICE The name of the sink to connect "
+#~ "to\n"
+#~ " -n, --client-name=NAME How to call this client on the "
+#~ "server\n"
+#~ " --stream-name=NAME How to call this stream on the "
+#~ "server\n"
+#~ " --volume=VOLUME Specify the initial (linear) "
+#~ "volume in range 0...65536\n"
+#~ " --channel-map=CHANNELMAP Set the channel map to the use\n"
+#~ msgstr ""
+#~ "%s [options] [FILE]\n"
+#~ "\n"
+#~ " -h, --help Mostra essa ajuda\n"
+#~ " --version Mostra a versão\n"
+#~ "\n"
+#~ " -v, --verbose Habilida a operação detalhada\n"
+#~ "\n"
+#~ " -s, --server=SERVER O nome do servidor a ser "
+#~ "conectado\n"
+#~ " -d, --device=DEVICE O nome do destino a ser "
+#~ "conectado\n"
+#~ " -n, --client-name=NAME Como chamar este cliente no "
+#~ "servidor\n"
+#~ " --stream-name=NAME Como chamar este fluxo no "
+#~ "servidor\n"
+#~ " --volume=VOLUME Especifica o volume inicial "
+#~ "(linear) no intervalo 0...65536\n"
+#~ " --channel-map=CHANNELMAP Define o mapa do canal para uso\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Compilado com libpulse %s\n"
+#~ "Linkado com libpulse %s\n"
+
+#~ msgid "Invalid channel map\n"
+#~ msgstr "Mapa de canais inválido\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Falha ao abrir o arquivo '%s'\n"
+
+#~ msgid "Channel map doesn't match file.\n"
+#~ msgstr "O mapa dos canais não coincide com o arquivo.\n"
+
+#~ msgid "Using sample spec '%s'\n"
+#~ msgstr "Usando a especificação da amostragem '%s'\n"
+
#, fuzzy
#~ msgid ""
#~ "Called SUID root and real-time and/or high-priority scheduling was "
@@ -2451,12 +2953,6 @@ msgstr ""
#~ "Módulo: %s\n"
#~ "Argumento: %s\n"
-#~ msgid "sink"
-#~ msgstr "destino"
-
-#~ msgid "source"
-#~ msgstr "fonte"
-
#~ msgid ""
#~ "' and PolicyKit refuse to grant us priviliges. Dropping SUID again.\n"
#~ "For enabling real-time scheduling please acquire the appropriate "
diff --git a/po/ru.po b/po/ru.po
new file mode 100644
index 00000000..810c26e9
--- /dev/null
+++ b/po/ru.po
@@ -0,0 +1,2700 @@
+# Russian translation of pulseaudio.
+# Copyright (C) 2010 pulseaudio
+# This file is distributed under the same license as the pulseaudio package.
+# Leonid Kurbatov <llenchikk@rambler.ru>, 2010.
+#
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: pulseaudio.master-tx\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2010-01-31 15:49+0300\n"
+"Last-Translator: Leonid Kurbatov <llenchikk@rambler.ru>\n"
+"Language-Team: Russian <->\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: -\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_avail() возвращает значение, которое ÑвлÑетÑÑ Ð¸Ñключительно большим: "
+"%lu байт (%lu мÑ).\n"
+"ВероÑтно, Ñто ошибка в драйвере ALSA '%s'. ПожалуйÑта, Ñообщите об Ñтой "
+"проблеме разработчикам ALSA."
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_delay() возвращает значение, которое ÑвлÑетÑÑ Ð¸Ñключительно большим: "
+"%li байт (%s%lu мÑ).\n"
+"ВероÑтно, Ñто ошибка в драйвере ALSA '%s'. ПожалуйÑта, Ñообщите об Ñтой "
+"проблеме разработчикам ALSA."
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+"snd_pcm_mmap_begin() возвращает значение, которое ÑвлÑетÑÑ Ð¸Ñключительно "
+"большим: %lu байт (%lu мÑ).\n"
+"ВероÑтно, Ñто ошибка в драйвере ALSA '%s'. ПожалуйÑта, Ñообщите об Ñтой "
+"проблеме разработчикам ALSA."
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+"Ð’Ñегда оÑтавлÑть Ñ…Ð¾Ñ‚Ñ Ð±Ñ‹ один аудиоприёмник загруженным, даже еÑли он "
+"неопределён."
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Фиктивный выход"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Виртуальный LADSPA аудиоприёмник"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<Ð¸Ð¼Ñ Ð°ÑƒÐ´Ð¸Ð¾Ð¿Ñ€Ð¸Ñ‘Ð¼Ð½Ð¸ÐºÐ°> sink_properties=<ÑвойÑтва аудиоприёмника> "
+"master=<Ð¸Ð¼Ñ Ð°ÑƒÐ´Ð¸Ð¾Ð¿Ñ€Ð¸Ñ‘Ð¼Ð½Ð¸ÐºÐ° Ð´Ð»Ñ Ñ„Ð¸Ð»ÑŒÑ‚Ñ€Ð°Ñ†Ð¸Ð¸> format=<формат> rate=<чаÑтота> "
+"channels=<чиÑло каналов> channel_map=<Ñхема каналов> plugin=<Ð¸Ð¼Ñ Ð¿Ð»Ð°Ð³Ð¸Ð½Ð° "
+"ladspa> label=<метка плагина ladspa> control=<ÑпиÑок входных значений, "
+"разделённый запÑтыми>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Синхронизированный NULL аудиоприёмник"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "ПуÑтой выход"
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "Ð’Ñтроенное аудио"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "Модем"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr "Ðе удалоÑÑŒ найти оригинальный lt_dlopen загрузчик."
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr "Ðе удалоÑÑŒ выделить новый dl загрузчик."
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr "Ðе удалоÑÑŒ добавить bind-now-загрузчик."
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr "Получен Ñигнал %s."
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "Выход."
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr "Ðе удалоÑÑŒ найти Ð¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ñ‚ÐµÐ»Ñ '%s'."
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr "Ðе удалоÑÑŒ найти группу '%s'."
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr "Ðайден пользователь '%s' (UID %lu) и группа '%s' (GID %lu)."
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr "Идентификаторы групп Ð¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ñ‚ÐµÐ»Ñ '%s' и группы '%s' не Ñовпадают."
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr "ДомашнÑÑ Ð¿Ð°Ð¿ÐºÐ° Ð¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ñ‚ÐµÐ»Ñ '%s' не ÑвлÑетÑÑ '%s', игнорирование."
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr "Ðе удалоÑÑŒ Ñоздать '%s': %s"
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr "Ошибка при изменении ÑпиÑка групп: %s"
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr "Ðе удалоÑÑŒ изменить идентификатор группы GID: %s"
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr "Ðе удалоÑÑŒ изменить идентификатор Ð¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ñ‚ÐµÐ»Ñ UID: %s"
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr "УÑпешное удаление привилегий админиÑтратора."
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr "РаÑширенный ÑиÑтемный режим не поддерживаетÑÑ Ð½Ð° Ñтой платформе."
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr "setrlimit(%s, (%u, %u)) не удалоÑÑŒ: %s"
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr "Ошибка разбора командной Ñтроки."
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr "Демон не запущен"
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr "Демон запущен как PID %u"
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr "Ðе удалоÑÑŒ убить демон: %s"
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr ""
+"Эта программа не предназначена Ð´Ð»Ñ Ð·Ð°Ð¿ÑƒÑка Ñ Ð¿Ñ€Ð°Ð²Ð°Ð¼Ð¸ админиÑтратора (еÑли не "
+"указано в ÑиÑтеме)."
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr "Ðеобходимы права админиÑтратора."
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr "--start не поддерживаетÑÑ Ð´Ð»Ñ ÑиÑтемных Ñлементов."
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr "Запущен в ÑиÑтемном режиме, но --disallow-exit не задан!"
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr "Запущен в ÑиÑтемном режиме, но --disallow-module-loading не задан!"
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr "Запущен в ÑиÑтемном режиме Ñ Ð¿Ñ€Ð¸Ð½ÑƒÐ´Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ñ‹Ð¼ отключением режима SHM!"
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr ""
+"Запущен в ÑиÑтемном режиме Ñ Ð¿Ñ€Ð¸Ð½ÑƒÐ´Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ñ‹Ð¼ отключением времени выхода поÑле "
+"проÑтоÑ!"
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr "Ðе удалоÑÑŒ запроÑить stdio."
+
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "Канал не удалÑÑ: %s"
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr "fork() ветвь не удалаÑÑŒ: %s"
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr "read() чтение не удалоÑÑŒ: %s"
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr "ЗапуÑк демона не удалÑÑ."
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr "УÑпешный запуÑк демона."
+
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() чтение не удалоÑÑŒ: %s"
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr "PulseAudio %s"
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr "ХоÑÑ‚ компилÑции: %s"
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr "КомпилÑÑ†Ð¸Ñ CFLAGS: %s"
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr "Запущен на хоÑте: %s"
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr "Ðайдено процеÑÑоров: %u."
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr "Размер Ñтраницы: %lu байт"
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr "Скомпилировано Ñ Ð¿Ð¾Ð´Ð´ÐµÑ€Ð¶ÐºÐ¾Ð¹ Valgrind: да"
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr "Скомпилировано Ñ Ð¿Ð¾Ð´Ð´ÐµÑ€Ð¶ÐºÐ¾Ð¹ Valgrind: нет"
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr "ЗапуÑк в режиме Valgrind: %s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Запущен на хоÑте: %s"
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr "ÐžÐ¿Ñ‚Ð¸Ð¼Ð¸Ð·Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð½Ð°Ñ Ñборка: да"
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr "ÐžÐ¿Ñ‚Ð¸Ð¼Ð¸Ð·Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð½Ð°Ñ Ñборка: нет"
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr "NDEBUG задан, вÑе аÑÑерты запрещены."
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr "FASTPATH задан, запрещены только fast path аÑÑерты."
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr "Ð’Ñе аÑÑерты разрешены."
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr "Ðе удалоÑÑŒ получить ID машины"
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr "ID машины %s."
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr "ID ÑеÑÑии %s."
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr "ИÑпользование каталога изолированного Ð¾ÐºÑ€ÑƒÐ¶ÐµÐ½Ð¸Ñ %s."
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr "ИÑпользование заданного каталога %s."
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "ИÑпользование каталога модулей %s."
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr "ЗапуÑк в ÑиÑтемном режиме: %s"
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"Итак, вы запуÑкаете PA в ÑиÑтемном режиме. Помните, что вам, Ñкорее вÑего, "
+"не Ñледует делать Ñтого.\n"
+"ЕÑли вы Ñто вÑÑ‘ равно делаете, то ваша вина, что вещи не работают как "
+"ожидалоÑÑŒ.\n"
+"ПожалуйÑта прочитайте http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode "
+"Ð´Ð»Ñ Ð¾Ð±ÑŠÑÑнениÑ, почему ÑиÑтемный режим обычно ÑвлÑетÑÑ Ð¿Ð»Ð¾Ñ…Ð¾Ð¹ идеей."
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr "pa_pid_file_create() не удалоÑÑŒ."
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr "ДоÑтупен Ñвежий таймер выÑокого разрешениÑ! ПриÑтного аппетита!"
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr ""
+"Братан, твоё Ñдро вонÑет! СегоднÑшнÑÑ Ñ€ÐµÐºÐ¾Ð¼ÐµÐ½Ð´Ð°Ñ†Ð¸Ñ ÑˆÐµÑ„Ð° - Ñдро Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð½Ñ‹Ð¼ "
+"таймером выÑокого разрешениÑ!"
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr "pa_core_new() не удалаÑÑŒ."
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr "Ошибка инициализации демона."
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr "ЗапуÑк демона без каких-либо загружаемых модулей, отказ от работы."
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr "ЗапуÑк демона завершён."
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr "Завершение демона инициализировано."
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr "Демон завершён."
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr "--daemonize ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr "--fail ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+"--log-level ожидает аргумент Ð¿Ñ€Ð¾Ñ‚Ð¾ÐºÐ¾Ð»Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ (или чиÑловой в диапазоне 0..4 "
+"или одному из debug, info, notice, warn, error)."
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr "--high-priority ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr "--realtime ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr "--disallow-module-loading ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr "--disallow-exit ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr "--use-pid-file ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr "ÐедопуÑтимый журнал: иÑпользуйте либо 'syslog', 'stderr' или 'auto'."
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr "--log-time ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr "--log-meta ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr "ÐедопуÑтимый метод реÑÑÐ¼Ð¿Ð»Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ '%s'."
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr "--system ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr "--no-cpu-limit ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr "--disable-shm ожидает логичеÑкий аргумент"
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr "ИмÑ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr "Ðет информации о модулÑÑ…\n"
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr "ВерÑиÑ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr "ОпиÑание: %s\n"
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr "Ðвтор: %s\n"
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr "ИÑпользование: %s\n"
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr "Загружен раз: %s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr "Путь: %s\n"
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr "[%s:%u] ÐедопуÑтимый журнал '%s'."
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr "[%s:%u] ÐедопуÑтимый аргумент Ð¿Ñ€Ð¾Ñ‚Ð¾ÐºÐ¾Ð»Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ '%s'."
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr "[%s:%u] ÐедопуÑтимый метод реÑÑÐ¼Ð¿Ð»Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ '%s'."
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr "[%s:%u] ÐедопуÑтимый rlimit '%s'."
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr "[%s:%u] rlimit не поддерживаетÑÑ Ð½Ð° Ñтой платформе."
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr "[%s:%u] ÐедопуÑтимый формат ÑÑмпла '%s'."
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr "[%s:%u] ÐÐµÐ²ÐµÑ€Ð½Ð°Ñ Ñ‡Ð°Ñтота диÑкретизации '%s'."
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr "[%s:%u] Ðеверные ÑÑмпл-каналы '%s'."
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr "[%s:%u] ÐÐµÐ²ÐµÑ€Ð½Ð°Ñ Ñхема каналов '%s'."
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr "[%s:%u] Ðеверное чиÑло фрагментов '%s'."
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr "[%s:%u] ÐедопуÑтимый размер фрагмента '%s'."
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr "[%s:%u] ÐедопуÑтимый точный уровень '%s'."
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] ÐÐµÐ²ÐµÑ€Ð½Ð°Ñ Ñ‡Ð°Ñтота диÑкретизации '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr "Ðе удалоÑÑŒ открыть файл конфигурации: %s"
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr ""
+"Ð’ указанной Ñхеме каналов чиÑло каналов отличаетÑÑ Ð¾Ñ‚ чиÑла каналов по "
+"умолчанию."
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr "### Прочитать из файла конфигурации: %s ###\n"
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "ОчиÑтка привилегий."
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "Ð—Ð²ÑƒÐºÐ¾Ð²Ð°Ñ ÑиÑтема PulseAudio"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "ЗапуÑк звуковой ÑиÑтемы PulseAudio"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "Моно"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "Фронт центр"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "Фронт лево"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "Фронт право"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "Сзади центр"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "Сзади лево"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "Сзади право"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr "Фронт левее центра"
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr "Фронт правее центра"
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "Ð›ÐµÐ²Ð°Ñ Ñторона"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "ÐŸÑ€Ð°Ð²Ð°Ñ Ñторона"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr "Дополнительный 0"
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr "Дополнительный 1"
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr "Дополнительный 2"
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr "Дополнительный 3"
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr "Дополнительный 4"
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr "Дополнительный 5"
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr "Дополнительный 6"
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr "Дополнительный 7"
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr "Дополнительный 8"
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr "Дополнительный 9"
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr "Дополнительный 10"
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr "Дополнительный 11"
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr "Дополнительный 12"
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr "Дополнительный 13"
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr "Дополнительный 14"
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr "Дополнительный 15"
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr "Дополнительный 16"
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr "Дополнительный 17"
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr "Дополнительный 18"
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr "Дополнительный 19"
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr "Дополнительный 20"
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr "Дополнительный 21"
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr "Дополнительный 22"
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr "Дополнительный 23"
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr "Дополнительный 24"
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr "Дополнительный 25"
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr "Дополнительный 26"
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr "Дополнительный 27"
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr "Дополнительный 28"
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr "Дополнительный 29"
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr "Дополнительный 30"
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr "Дополнительный 31"
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "Верх центр"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "Верх фронт центр"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "Верх фронт лево"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "Верх фронт право"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "Верх Ñзади центр"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "Верх Ñзади лево"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "Верх Ñзади право"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "(недейÑтвительно)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "Стерео"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "Объёмный 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "Объёмный 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "Объёмный 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "Объёмный 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "Объёмный 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "OK"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "Ðет доÑтупа"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr "ÐеизвеÑÑ‚Ð½Ð°Ñ ÐºÐ¾Ð¼Ð°Ð½Ð´Ð°"
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr "ÐедейÑтвительный аргумент"
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr "Объект ÑущеÑтвует"
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr "Ðет такого объекта"
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "Отказ в подключении"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "Ошибка протокола"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr "Тайм-аут"
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr "Ðет ключа авторизации"
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "ВнутреннÑÑ Ð¾ÑˆÐ¸Ð±ÐºÐ°"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr "Соединение завершено"
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr "Объект уничтожен"
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr "Ðеверный Ñервер"
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr "Ð˜Ð½Ð¸Ñ†Ð¸Ð°Ð»Ð¸Ð·Ð°Ñ†Ð¸Ñ Ð¼Ð¾Ð´ÑƒÐ»Ñ Ð½Ðµ удалаÑÑŒ"
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr "ÐеиÑправное ÑоÑтоÑние"
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr "Ðет данных"
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr "ÐеÑовмеÑÑ‚Ð¸Ð¼Ð°Ñ Ð²ÐµÑ€ÑÐ¸Ñ Ð¿Ñ€Ð¾Ñ‚Ð¾ÐºÐ¾Ð»Ð°"
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "Слишком большой"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "Ðе поддерживаетÑÑ"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "ÐеизвеÑтный код ошибки"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr "Ðет такого раÑширениÑ"
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr "УÑÑ‚Ð°Ñ€ÐµÐ²ÑˆÐ°Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ð¾Ð½Ð°Ð»ÑŒÐ½Ð¾Ñть"
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr "ОтÑутÑÑ‚Ð²ÑƒÑŽÑ‰Ð°Ñ Ñ€ÐµÐ°Ð»Ð¸Ð·Ð°Ñ†Ð¸Ñ"
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr "Клиент разветвлён"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Ошибка ввода/вывода"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "УÑтройÑтво или реÑÑƒÑ€Ñ Ð·Ð°Ð½Ñто"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr "%s %uch %uГц"
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr "%0.1f Гб"
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr "%0.1f Мб"
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr "%0.1f Кб"
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr "%u Б"
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr "XOpenDisplay() не удалоÑÑŒ"
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr "Ðе удалоÑÑŒ разобрать данные cookie"
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr "Ðе удалоÑÑŒ открыть файл конфигурации '%s': %s"
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr "Cookie не загружены. Попытка Ð¿Ð¾Ð´ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð±ÐµÐ· них."
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr "fork(): %s"
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr "waitpid(): %s"
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr "Получено Ñообщение Ð´Ð»Ñ Ð½ÐµÐ¸Ð·Ð²ÐµÑтного раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ '%s'"
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr "Ðе удалоÑÑŒ Ñоздать туннель Ð´Ð»Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÐ°: %s"
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Поток воÑÐ¿Ñ€Ð¾Ð¸Ð·Ð²ÐµÐ´ÐµÐ½Ð¸Ñ Ñ‚ÑƒÐ½Ð½ÐµÐ»Ð¸Ñ€Ð¾Ð²Ð°Ð½."
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Туннелирование ÑÐ¾ÐµÐ´Ð¸Ð½ÐµÐ½Ð¸Ñ Ñ Ñервером."
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Поток уÑпешно Ñоздан."
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Показатели буфера: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Показатели буфера: maxlength=%u, fragsize=%u"
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "ИÑпользование Ñемплов '%s', Ñхемы каналов '%s'."
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Соединён Ñ ÑƒÑтройÑтвом %s (%u, %sожидание)."
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr "Ошибка потока: %s"
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr "Поток приоÑтановлен.%s"
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr "Поток возобновлён.%s"
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr "Поток недогружен.%s"
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr "Поток переполнен.%s"
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr "Поток запущен.%s"
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Поток перемещён на уÑтройÑтво %s (%u, %sожидание).%s"
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "not "
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr "Ðтрибуты буфера потока изменены.%s"
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr "Соединение уÑтановлено.%s"
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr "Ошибка подключениÑ: %s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "ДоÑтигнут конец файла."
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr "write() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Сигнал получен, выход."
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr "Ðе удалоÑÑŒ получить задержку: %s"
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "ВремÑ: %0.3f Ñ; задержка: %0.0f мкÑ."
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pacat %s\n"
+"Скомпилировано Ñ libpulse %s\n"
+"СвÑзано Ñ libpulse %s\n"
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr "Ðеверное Ð¸Ð¼Ñ ÐºÐ»Ð¸ÐµÐ½Ñ‚Ð° '%s'"
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr "Ðеверное Ð¸Ð¼Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÐ° '%s'"
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr "ÐÐµÐ²ÐµÑ€Ð½Ð°Ñ Ñхема каналов '%s'"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr "Ðеверное значение задержки '%s'"
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "ÐÐµÐ²ÐµÑ€Ð½Ð°Ñ ÑÐ¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ Ð²Ñ€ÐµÐ¼ÐµÐ½Ð¸ процеÑÑа '%s'"
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr "Ðеверное ÑвойÑтво '%s'"
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "ÐеизвеÑтный формат файла %s."
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "ÐÐµÐ²ÐµÑ€Ð½Ð°Ñ ÑÐ¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмпла"
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr "open(): %s"
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Слишком много аргументов."
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Ошибка ÑÐ¾Ð·Ð´Ð°Ð½Ð¸Ñ Ñпецификации ÑÑмпла Ð´Ð»Ñ Ñ„Ð°Ð¹Ð»Ð°."
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Ðе удалоÑÑŒ открыть аудио файл."
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Предупреждение: Ð·Ð°Ð´Ð°Ð½Ð½Ð°Ñ ÑÐ¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмпла будет перезапиÑана "
+"Ñпецификацией из файла."
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Ðе удалоÑÑŒ определить Ñпецификацию ÑÑмпла из файла."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Предупреждение: не удалоÑÑŒ определить Ñхему каналов из файла."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Схема каналов не ÑоответÑтвует Ñпецификации ÑÑмпла"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Предупреждение: не удалоÑÑŒ запиÑать Ñхему каналов в файл."
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Открытие потока %s Ñо Ñпецификацией ÑÑмплов '%s' и Ñхемой каналов '%s'."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "запиÑÑŒ"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "воÑпроизведение"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() не удалоÑÑŒ."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() не удалоÑÑŒ."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() не удалоÑÑŒ."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() не удалоÑÑŒ: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() не удалоÑÑŒ."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() не удалоÑÑŒ."
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr "fork(): %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr "Ðе удаётÑÑ Ð¿Ñ€Ð¸Ð¾Ñтановить: %s\n"
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr "Ðе удаётÑÑ Ð²Ð¾Ð·Ð¾Ð±Ð½Ð¾Ð²Ð¸Ñ‚ÑŒ: %s\n"
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr ""
+"ПРЕДУПРЕЖДЕÐИЕ: Ðудио Ñервер не ÑвлÑетÑÑ Ð»Ð¾ÐºÐ°Ð»ÑŒÐ½Ñ‹Ð¼, не приоÑтанавливаетÑÑ.\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Ошибка ÑоединениÑ: %s\n"
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr "Получен Ñигнал Ð´Ð»Ñ Ð¾Ñтановки, выход.\n"
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr "ПРЕДУПРЕЖДЕÐИЕ: Дочерний процеÑÑ Ð¾Ñ‚Ð¼ÐµÐ½Ñ‘Ð½ по Ñигналу %u\n"
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pasuspender %s\n"
+"Скомпилировано Ñ libpulse %s\n"
+"СвÑзано Ñ libpulse %s\n"
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() не удалоÑÑŒ.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() не удалоÑÑŒ.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() не удалоÑÑŒ.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Ðе удалоÑÑŒ получить ÑтатиÑтику: %s"
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr "Ð¡ÐµÐ¹Ñ‡Ð°Ñ Ð¸ÑпользуетÑÑ: %u блоков Ñодержащих вÑего %s байт.\n"
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr "Выделено за вÑÑ‘ времÑ: %u блоков Ñодержащих вÑего %s байт.\n"
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr "Размер кÑша ÑÑмплов: %s\n"
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию о Ñервере: %s"
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+"Ð˜Ð¼Ñ Ð¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ñ‚ÐµÐ»Ñ: %s\n"
+"Ð˜Ð¼Ñ Ñ…Ð¾Ñта: %s\n"
+"Ð˜Ð¼Ñ Ñервера: %s\n"
+"ВерÑÐ¸Ñ Ñервера: %s\n"
+"Ð¡Ð¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмплов по умолчанию: %s\n"
+"Схема каналов по умолчанию: %s\n"
+"Ðудиоприёмник по умолчанию: %s\n"
+"ИÑточник по умолчанию: %s\n"
+"Cookie: %08x\n"
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию об аудиоприёмнике: %s"
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Ðудиоприёмник #%u\n"
+"\tСоÑтоÑние: %s\n"
+"\tИмÑ: %s\n"
+"\tОпиÑание: %s\n"
+"\tДрайвер: %s\n"
+"\tÐ¡Ð¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмплов: %s\n"
+"\tСхема каналов: %s\n"
+"\tРодительÑкий модуль: %u\n"
+"\tВыключить: %s\n"
+"\tГромкоÑть: %s%s%s\n"
+"\t Ð±Ð°Ð»Ð°Ð½Ñ %0.2f\n"
+"\tÐ‘Ð°Ð·Ð¾Ð²Ð°Ñ Ð³Ñ€Ð¾Ð¼ÐºÐ¾Ñть: %s%s%s\n"
+"\tМонитор иÑточника: %s\n"
+"\tЗадержка: %0.0f мкÑ, наÑтроить %0.0f мкÑ\n"
+"\tФлаги: %s%s%s%s%s%s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tПорты:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tÐктивный порт: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию об иÑточнике: %s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"ИÑточник #%u\n"
+"\tСоÑтоÑние: %s\n"
+"\tИмÑ: %s\n"
+"\tОпиÑание: %s\n"
+"\tДрайвер: %s\n"
+"\tÐ¡Ð¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмплов: %s\n"
+"\tСхема каналов: %s\n"
+"\tРодительÑкий модуль: %u\n"
+"\tВыключить: %s\n"
+"\tГромкоÑть: %s%s%s\n"
+"\t Ð±Ð°Ð»Ð°Ð½Ñ %0.2f\n"
+"\tÐ‘Ð°Ð·Ð¾Ð²Ð°Ñ Ð³Ñ€Ð¾Ð¼ÐºÐ¾Ñть: %s%s%s\n"
+"\tМонитор аудиоприёмника: %s\n"
+"\tЗадержка: %0.0f мкÑ, наÑтроить %0.0f мкÑ\n"
+"\tФлаги: %s%s%s%s%s%s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "н/д"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию о модуле: %s"
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Модуль #%u\n"
+"\tИмÑ: %s\n"
+"\tÐргумент: %s\n"
+"\tСчётчик иÑпользованиÑ: %s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию о клиенте: %s"
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Клиент #%u\n"
+"\tДрайвер: %s\n"
+"\tРодительÑкий модуль: %s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию о карте: %s"
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Карта #%u\n"
+"\tИмÑ: %s\n"
+"\tДрайвер: %s\n"
+"\tРодительÑкий модуль: %s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\tПрофили:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr "\tÐктивный профиль: %s\n"
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию о вводе аудиоприёмника: %s"
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Ввод аудиоприёмника #%u\n"
+"\tДрайвер: %s\n"
+"\tРодительÑкий модуль: %s\n"
+"\tКлиент: %s\n"
+"\tÐудиоприёмник: %u\n"
+"\tÐ¡Ð¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмплов: %s\n"
+"\tСхема каналов: %s\n"
+"\tВыключить: %s\n"
+"\tГромкоÑть: %s\n"
+"\t %s\n"
+"\t Ð±Ð°Ð»Ð°Ð½Ñ %0.2f\n"
+"\tЗадержка буфера: %0.0f мкÑ\n"
+"\tЗадержка аудиоприёмника: %0.0f usec\n"
+"\tМетод реÑÑмплированиÑ: %s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию о выходе иÑточника: %s"
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"Выход иÑточника #%u\n"
+"\tДрайвер: %s\n"
+"\tРодительÑкий модуль: %s\n"
+"\tКлиент: %s\n"
+"\tИÑточник: %u\n"
+"\tÐ¡Ð¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмплов: %s\n"
+"\tСхема каналов: %s\n"
+"\tЗадержка буфера: %0.0f мкÑ\n"
+"\tЗадержка иÑточника: %0.0f мкÑ\n"
+"\tМетод реÑÑмплированиÑ: %s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "Ðе удалоÑÑŒ получить информацию о ÑÑмпле: %s"
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+"СÑмпл #%u\n"
+"\tИмÑ: %s\n"
+"\tÐ¡Ð¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ ÑÑмпла: %s\n"
+"\tСхема каналов: %s\n"
+"\tГромкоÑть: %s\n"
+"\t %s\n"
+"\t Ð±Ð°Ð»Ð°Ð½Ñ %0.2f\n"
+"\tДлительноÑть: %0.1fs\n"
+"\tРазмер: %s\n"
+"\tОтложенный (lazy): %s\n"
+"\tÐ˜Ð¼Ñ Ñ„Ð°Ð¹Ð»Ð°: %s\n"
+"\tСвойÑтва:\n"
+"\t\t%s\n"
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "Ðе удалоÑÑŒ: %s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "Ðе удалоÑÑŒ загрузить ÑÑмпл: %s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Преждевременный конец файла"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Ðеверный Ñервер"
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Получен Ñигнал Ð´Ð»Ñ Ð¾Ñтановки, выход."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+"pactl %s\n"
+"Скомпилировано Ñ libpulse %s\n"
+"СвÑзано Ñ libpulse %s\n"
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "ПожалуйÑта укажите файл ÑÑмпла Ð´Ð»Ñ Ð·Ð°Ð³Ñ€ÑƒÐ·ÐºÐ¸"
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Ðе удалоÑÑŒ открыть звуковой файл."
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Предупреждение: не удалоÑÑŒ определить Ñпецификации ÑÑмплов из файла."
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð¼Ñ ÑÑмпла Ð´Ð»Ñ Ð²Ð¾ÑпроизведениÑ"
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð¼Ñ ÑÑмпла Ð´Ð»Ñ ÑƒÐ´Ð°Ð»ÐµÐ½Ð¸Ñ"
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð½Ð´ÐµÐºÑ Ð²Ð²Ð¾Ð´Ð° аудиоприёмника и аудиоприёмник"
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð½Ð´ÐµÐºÑ Ð²Ñ‹Ð²Ð¾Ð´Ð° иÑточника и иÑточник"
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð¼Ñ Ð¼Ð¾Ð´ÑƒÐ»Ñ Ð¸ аргументы"
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð½Ð´ÐµÐºÑ Ð¼Ð¾Ð´ÑƒÐ»Ñ"
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+"Вы не можете указать более одного аудиоприёмника. Вы должны указать "
+"логичеÑкое значение."
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr ""
+"Ð’Ñ‹ не можете указать более одного иÑточника. Ð’Ñ‹ должны указать логичеÑкое "
+"значение."
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Ð’Ñ‹ должны указать имÑ/Ð¸Ð½Ð´ÐµÐºÑ ÐºÐ°Ñ€Ñ‚Ñ‹ и Ð¸Ð¼Ñ Ð¿Ñ€Ð¾Ñ„Ð¸Ð»Ñ"
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Ð’Ñ‹ должны указать имÑ/Ð¸Ð½Ð´ÐµÐºÑ Ð°ÑƒÐ´Ð¸Ð¾Ð¿Ñ€Ð¸Ñ‘Ð¼Ð½Ð¸ÐºÐ° и Ð¸Ð¼Ñ Ð¿Ð¾Ñ€Ñ‚Ð°"
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Ð’Ñ‹ должны указать имÑ/Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ñточника и Ð¸Ð¼Ñ Ð¿Ð¾Ñ€Ñ‚Ð°"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Ð’Ñ‹ должны указать имÑ/Ð¸Ð½Ð´ÐµÐºÑ Ð°ÑƒÐ´Ð¸Ð¾Ð¿Ñ€Ð¸Ñ‘Ð¼Ð½Ð¸ÐºÐ° и громкоÑть"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Ðеверное значение громкоÑти"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Ð’Ñ‹ должны указать имÑ/Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ñточника и громкоÑть"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð½Ð´ÐµÐºÑ Ð²Ð²Ð¾Ð´Ð° аудиоприёмника и громкоÑть"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ðеверный Ð¸Ð½Ð´ÐµÐºÑ Ð²Ð²Ð¾Ð´Ð° аудиоприёмника"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Ð’Ñ‹ должны указать имÑ/Ð¸Ð½Ð´ÐµÐºÑ Ð°ÑƒÐ´Ð¸Ð¾Ð¿Ñ€Ð¸Ñ‘Ð¼Ð½Ð¸ÐºÐ° и выключить логичеÑкий"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Ð’Ñ‹ должны указать имÑ/Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ñточника и выключить логичеÑкий"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "Ð’Ñ‹ должны указать Ð¸Ð½Ð´ÐµÐºÑ Ð²Ð²Ð¾Ð´Ð° аудиоприёмника и выключить логичеÑкий"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "ÐÐµÐ²ÐµÑ€Ð½Ð°Ñ ÑÐ¿ÐµÑ†Ð¸Ñ„Ð¸ÐºÐ°Ñ†Ð¸Ñ Ð¸Ð½Ð´ÐµÐºÑа ввода аудиоприёмника"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Ðе указаны правильные команды."
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr "Ошибка разбора командной Ñтроки.\n"
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr "Сервер: %s\n"
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr "ИÑточник: %s\n"
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr "Ðудиоприёмник: %s\n"
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr "Cookie: %s\n"
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr "Ðе удалоÑÑŒ разобрать данные cookie\n"
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr "Ðе удалоÑÑŒ Ñохранить данные cookie\n"
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr "Ðе удалоÑÑŒ загрузить файл конфигурации клиента.\n"
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr "Ðе удалоÑÑŒ прочитать данные конфигурации окружениÑ.\n"
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr "Ðе удалоÑÑŒ получить Ð¸Ð¼Ñ Ð´Ð¾Ð¼ÐµÐ½Ð° (FQDN).\n"
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr "Ðе удалоÑÑŒ загрузить данные cookie\n"
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr "Ещё не выполнено.\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Ðет запущенного демона PulseAudio или не запущен в качеÑтве ÑеÑÑионного "
+"демона."
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr "connect(): %s"
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr "Ðе удалоÑÑŒ убить демон PulseAudio."
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr "Демон не отвечает."
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr "poll(): %s"
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr "read(): %s"
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr "write(): %s"
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr "Cannot access autospawn lock."
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA разбудила Ð½Ð°Ñ Ð´Ð»Ñ Ð·Ð°Ð¿Ð¸Ñи новых данных в уÑтройÑтво, но на Ñамом деле "
+"пиÑать было нечего!\n"
+"Скорее вÑего Ñто ошибка в драйвере ALSA '%s'. ПожалуйÑта Ñообщите об Ñтой "
+"проблеме разработчикам ALSA.\n"
+"Мы проÑнулиÑÑŒ Ñ POLLOUT set -- однако поÑледующее snd_pcm_avail() вернуло 0 "
+"или другое значение < min_avail."
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+"ALSA разбудила Ð½Ð°Ñ Ð´Ð»Ñ Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ð½Ð¾Ð²Ñ‹Ñ… данных из уÑтройÑтва, но на Ñамом деле "
+"читать было нечего!\n"
+"Скорее вÑего Ñто ошибка в драйвере ALSA '%s'. ПожалуйÑта Ñообщите об Ñтой "
+"проблеме разработчикам ALSA.\n"
+"Мы проÑнулиÑÑŒ Ñ POLLOUT set -- однако поÑледующее snd_pcm_avail() вернуло 0 "
+"или другое значение < min_avail."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "Выключено"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "ВоÑпроизведение выÑокого качеÑтва (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "ЗапиÑÑŒ выÑокого качеÑтва (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "ДуплекÑÐ½Ð°Ñ Ñ‚ÐµÐ»ÐµÑ„Ð¾Ð½Ð¸Ñ (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "Звуковой Ñервер PulseAudio"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "УÑтройÑтва вывода"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "УÑтройÑтва ввода"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Ðудио на @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Ввод"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Док-ÑÑ‚Ð°Ð½Ñ†Ð¸Ñ Ð²Ð²Ð¾Ð´Ð°"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Док-ÑÑ‚Ð°Ð½Ñ†Ð¸Ñ Ð¼Ð¸ÐºÑ€Ð¾Ñ„Ð¾Ð½"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Линейный вход"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Внешний микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Ð’Ñтроенный микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Радио"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Видео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "ÐвтоматичеÑÐºÐ°Ñ Ñ€ÐµÐ³ÑƒÐ»Ð¸Ñ€Ð¾Ð²ÐºÐ° уÑилениÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Ðет автоматичеÑкой регулировки уÑилениÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "УÑиление"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Ðет уÑилениÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "УÑилитель"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Ðет уÑилителÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "УÑиление"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Ðет уÑилениÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Ðналоговые наушники"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Ðналоговый ввод"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Ðналоговый микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Ðналоговый линейный вход"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Ðналоговое радио"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Ðналоговое видео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Ðналоговый вывод"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Ðналоговые наушники"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Ðналоговый вывод (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Ðналоговый вывод моно"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Ðналоговое Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Ðналоговое моно"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Ðналоговое Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Ðналоговый объёмный 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Ðналоговый объёмный 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Ðналоговый объёмный 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Ðналоговый объёмный 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Ðналоговый объёмный 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Ðналоговый объёмный 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Ðналоговый объёмный 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Ðналоговый объёмный 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Ðналоговый объёмный 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Ðналоговый объёмный 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Ðналоговый объёмный 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Цифровое Ñтерео (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Цифровой объёмный 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Цифровой объёмный 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Цифровой объёмный 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Цифровое Ñтерео (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Ðналоговый моно дуплекÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Ðналоговый Ñтерео дуплекÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Цифровой Ñтерео Ð´ÑƒÐ¿Ð»ÐµÐºÑ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Сабвуфер"
diff --git a/po/sr.po b/po/sr.po
index 3cf0977e..ed1b2b12 100644
--- a/po/sr.po
+++ b/po/sr.po
@@ -1,70 +1,29 @@
# Serbian translations for pulseaudio
# Copyright (C) 2006 Lennart Poettering
# This file is distributed under the same license as the pulseaudio package.
-#
# Igor Miletic (Игор Милетић) <grejigl-gnomeprevod@yahoo.ca>, 2009.
# MiloÅ¡ KomarÄević <kmilos@gmail.com>, 2009.
+#
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-07 23:02+0100\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-30 22:51+0100\n"
"Last-Translator: MiloÅ¡ KomarÄević <kmilos@gmail.com>\n"
-"Language-Team: Serbian <fedora-trans-sr@redhat.com>\n"
+"Language-Team: Serbian (sr) <fedora-trans-sr@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%"
"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
-"X-Generator: Lokalize 0.3\n"
-
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Ðналогни моно"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Ðналогни Ñтерео"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Дигитални Ñтерео (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Дигитални Ñтерео (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Ðналогни окружујући 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Дигитални окружујући 4.0 (IEC958/AC3)"
-
-# Surround можемо превеÑти амбијентални или окружни или можда чак и Ñараунд? -- Игор
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Ðналогни окружујући 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Ðналогни окружујући 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Ðналогни окружујући 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Дигитални окружујући 5.1 (IEC958/AC3)"
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Ðналогни окружујући 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -77,7 +36,7 @@ msgstr ""
"Ово је највероватније грешка у „%s“ ALSA управљачком програму. Пријавите "
"овај проблем ALSA програмерима."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -90,7 +49,7 @@ msgstr ""
"Ово је највероватније грешка у „%s“ ALSA управљачком програму. Пријавите "
"овај проблем ALSA програмерима."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -103,11 +62,45 @@ msgstr ""
"Ово је највероватније грешка у „%s“ ALSA управљачком програму. Пријавите "
"овај проблем ALSA програмерима."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Увек одржава барем један Ñливник оптерећеним чак и када је празан"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Лажан излаз"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Виртуелни LADSPA Ñливник"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<име Ñливника> sink_properties=<ÑвојÑтва Ñливника> master=<име "
+"Ñливника за филтрирање> format=<формат узорка> rate=<учеÑтаноÑÑ‚ "
+"диÑкретизације> channels=<број канала> channel_map=<мапа канала> plugin=<име "
+"ladspa додатка> label=<ознака ladspa додатка> control=<ÑпиÑак улазних "
+"контролних вредноÑти раздвојених зарезом>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Узорак NULL Ñливника"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Празан излаз"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Унутрашњи звук"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Модем"
@@ -123,222 +116,98 @@ msgstr "ÐеуÑпешно Ñмештање новог dl учитавача."
msgid "Failed to add bind-now-loader."
msgstr "ÐеуÑпешно додавање „повежи одмах“ учитавача."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Ðије Ñе могуће прикључити на ÑиÑтемÑку магиÑтралу: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Ðе могу добавити позивника из PID-а: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Ðе могу поÑтавити UID за позивнички објекат."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "ÐеуÑпешно добављање CK ÑеÑије."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Ðе могу поÑтавити UID за објекат ÑеÑије."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Ðе могу поÑтавити PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Ðе могу поÑтавити action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Ðе могу поÑтавити PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Ðе могу иницијализовати PolKitContex: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Ðије могуће одредити овлашћење позивника: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Ðе могу добити овлашћење: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit је одговорио Ñа „%s“"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Добих Ñигнал %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Ðапуштам."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Ðе могу наћи кориÑника „%s“."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Ðе могу наћи групу „%s“."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Ðађени Ñу кориÑник „%s“ (UID %lu) и група „%s“ (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID кориÑника „%s“ Ñе не поклапа Ñа групом „%s“."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Лични директоријум кориÑника „%s“ није „%s“, занемарујем."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "ÐеуÑпешно прављење „%s“: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "ÐеуÑпешна промена групног ÑпиÑка: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "ÐеуÑпешна промена GID-а: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "ÐеуÑпешна промена UID-а: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "УÑпешно одбачена root овлашћења."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "Режим за читав ÑиÑтем није подржан на овој платформи."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) није уÑпело: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "ÐеуÑпешно тумачење командне линије."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Ðалазимо Ñе у групи „%s“ која дозвољава виÑокоприоритетно раÑпоређивање."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Ðалазимо Ñе у групи „%s“ која дозвољава ÑтварновременÑко раÑпоређивање."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit нам је дао овлашћење за добијање виÑоког приоритета."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit одбија овлашћење за добијање виÑоког приоритета."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit нам је дао овлашћење за добијање рада у Ñтварном времену."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit одбија овлашћење за добијање рада у Ñтварном времену."
-
-#
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"SUID root и ÑтварновременÑко и/или виÑокоприоритетно раÑпоређивање је "
-"захтевано у подешавањима. Међутим, немамо потребна овлашћења:\n"
-"ниÑмо у групи „%s“, PolicyKit одбија да нам да̑ тражена овлашћења и немамо "
-"ÑредÑтава за повећање RLIMIT_NICE/RLIMIT_RTPRIO ограничења.\n"
-"Морате добити одговарајућа PolicyKit овлашћења, или поÑтати члан групе „%s“, "
-"или повећати ограничења за RLIMIT_NICE/RLIMIT_RTPRIO ÑредÑтва овог кориÑника "
-"како би омогућили ÑтварновременÑко или виÑокоприоритетно раÑпоређивање."
-
-#: ../src/daemon/main.c:581
+#: ../src/daemon/main.c:535
msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"ВиÑокоприоритетно раÑпоређивање је омогућено у подешавањима, али политика то "
-"не дозвољава."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "УÑпешно повећано RLIMIT_RTPRIO ограничење"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "ÐеуÑпешно поÑтављање RLIMIT_RTPRIO-а:%s"
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "ОдуÑтајем од CAP_NICE"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"СтварновременÑко раÑпоређивање је омогућено у подешавањима, али политика то "
-"не дозвољава."
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Демон није покренут"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Демон је покренут Ñа PID-ом %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "ÐеуÑпешно убијање демона: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -346,161 +215,197 @@ msgstr ""
"Ðије намеравано да Ñе овај програм покреће из root налога (оÑим у Ñлучају "
"када је --system наведено)"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Потребна Ñу root овлашћења."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start није подржано за ÑиÑтемÑке примерке."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "Покренуто у ÑиÑтемÑком режиму, али --disallow-exit није поÑтављено!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"Покренуто у ÑиÑтемÑком режиму, али --disallow-module-loading није поÑтављено!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "Покренуто у ÑиÑтемÑком режиму, приÑилно онемогућујем SHM режим!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"Покренуто у ÑиÑтемÑком режиму, приÑилно онемогућујем гашење поÑле одређеног "
"времена мировања!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "ÐеуÑпешно проналажење Ñтандардног улаза/излаза."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "ÐеуÑпешно пуштање података кроз цев: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "ÐеуÑпела функција fork(): %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "ÐеуÑпела функција read(): %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "ÐеуÑпешно покретање демона."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Демон уÑпешно покренут."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "ÐеуÑпела функција read(): %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Ово је PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Домаћин компајлирања: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "CFLAGS компајлирања: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Покренут на домаћину: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "Ðашао %u процеÑор(а)"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "Величина Ñтранице је %lu бајтова"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Компајлирано Ñа подршком за Valgrind: да"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Компајлирано Ñа подршком за Valgrind: не"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Покренут у Valgrind режиму: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Покренут на домаћину: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Оптимизована изградња: да"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Оптимизована изградња: не"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG дефиниÑан, Ñва обавештења иÑкључена."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH дефиниÑан, Ñамо обавештења брзе путање иÑкључена."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Сва обавештења омогућена."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "ÐеуÑпешно добављање ИБ машине"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "ИБ машине је %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "ИБ машине је %s."
+msgstr "ИБ ÑеÑије је %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "КориÑти Ñе %s извршни директоријум."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "КориÑти Ñе %s директоријум Ñтања."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "КориÑти Ñе %s директоријум модула."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Покренуто у ÑиÑтемÑком режиму: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"У реду, значи извршавате PA у ÑиÑтемÑком режиму. Примите к знању да то "
+"вероватно не би требало да радите.\n"
+"Ðко то Ñвеједно чините онда је ваша кривица ако Ñтвари не раде онако како Ñе "
+"очекује.\n"
+"Прочитајте http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode ради "
+"објашњења зашто је ÑиÑтемÑки режим обично лоша идеја."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "ÐеуÑпела функција pa_pid_file_create()."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "ДоÑтупни Ñу нови бројачи виÑоке резолуције! Пријатно!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -508,31 +413,31 @@ msgstr ""
"Ваше језгро није добро подешено за pulseaudio! Препоручује Вам Ñе да "
"кориÑтите Linux језгро Ñа омогућеним бројачима виÑоке резолуције."
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "ÐеуÑпела функција pa_core_new()."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "ÐеуÑпешно покретање демона."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Демон је покренут без иједног учитаног модула, одбија да ради."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "Покретање демона уÑпешно."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Покренуто гашење демона."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Рад демона је прекинут."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -605,14 +510,14 @@ msgid ""
"\n"
" -n Don't load default script file\n"
msgstr ""
-"%s [options]\n"
+"%s [опције]\n"
"\n"
"ÐÐРЕДБЕ:\n"
" -h, --help Прикажи ову помоћ\n"
" --version Прикажи верзију\n"
-" --dump-conf ИзлиÑтај подразумевана подешавања\n"
-" --dump-modules ИзлиÑтај ÑпиÑак доÑтупних модула\n"
-" --dump-resample-methods ИзлиÑтај доÑтупне вредноÑти "
+" --dump-conf ИÑпиши подразумевана подешавања\n"
+" --dump-modules ИÑпиши ÑпиÑак доÑтупних модула\n"
+" --dump-resample-methods ИÑпиши доÑтупне вредноÑти "
"диÑкретизације\n"
" --cleanup-shm ОчиÑти бајате делове дељене "
"меморије\n"
@@ -658,7 +563,7 @@ msgstr ""
" --log-backtrace=FRAMES Укључи трагове у порукама дневника\n"
" -p, --dl-search-path=ПУТÐЊРПоÑтави путању претраге за динамички "
"дељене\n"
-" објекте (додатци)\n"
+" објекте (додаци)\n"
" --resample-method=ÐÐЧИРКориÑти наведени начин "
"диÑкретизације\n"
" (Погледај --dump-resample-methods "
@@ -683,71 +588,71 @@ msgstr ""
" -n Ðе учитавај подразумевану датотеку "
"Ñкрипте.\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
-msgstr "--daemonize очекује логичку вредноÑÑ‚"
+msgstr "--daemonize очекује логички аргумент"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
-msgstr "--fail очекује логичку вредноÑÑ‚"
+msgstr "--fail очекује логички аргумент"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
msgstr ""
-"--log-level очекује параметар за ниво опширноÑти (нумеричка вредноÑÑ‚ између "
-"0 и 4 или једно од: debug, info, notice, warn, error)."
+"--log-level очекује аргумент за ниво запиÑа (или нумеричка вредноÑÑ‚ у опÑегу "
+"0..4 или једно од debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
-msgstr "--high-priority очекује логичку вредноÑÑ‚"
+msgstr "--high-priority очекује логички аргумент"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
-msgstr "--realtime очекује логичку вредноÑÑ‚"
+msgstr "--realtime очекује логички аргумент"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
-msgstr "--disallow-module-loading очекује логичку вредноÑÑ‚"
+msgstr "--disallow-module-loading очекује логички аргумент"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr "--disallow-exit очекује логичку вредноÑÑ‚"
+msgstr "--disallow-exit очекује логички аргумент"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
-msgstr "--use-pid-file очекује логичку вредноÑÑ‚"
+msgstr "--use-pid-file очекује логички аргумент"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"ÐеиÑправан циљни дневник: кориÑтите једно од „syslog“, „stderr“ или „auto“."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr "--log-time очекује логичку вредноÑÑ‚"
+msgstr "--log-time очекује логички аргумент"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr "--log-meta очекује логичку вредноÑÑ‚"
+msgstr "--log-meta очекује логички аргумент"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "ÐеиÑправан начин диÑкретизације „%s“."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
-msgstr "--system очекује логичку вредноÑÑ‚"
+msgstr "--system очекује логички аргумент"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
-msgstr "--no-cpu-limit очекује логичку вредноÑÑ‚"
+msgstr "--no-cpu-limit очекује логички аргумент"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
-msgstr "--disable-shm очекује логичку вредноÑÑ‚"
+msgstr "--disable-shm очекује логички аргумент"
#: ../src/daemon/dumpmodules.c:60
#, c-format
@@ -784,77 +689,87 @@ msgstr "Употреба: %s\n"
msgid "Load Once: %s\n"
msgstr "Учитај једном: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "УПОЗОРЕЊЕ О ПРЕВÐЗИЛÐЖЕЊУ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Путања: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] ÐеиÑправан циљни дневник „%s“."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] ÐеиÑправан ниво опширноÑти у дневнику „%s“."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] ÐеиÑправан начин диÑкретизације „%s“."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] ÐеиÑправан rlimit „%s“."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit није подржан на овој платформи."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] ÐеиÑправан формат узорка „%s“."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] ÐеиÑправна учеÑтаноÑÑ‚ диÑкретизације „%s“."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] ÐеиÑправни канали узорка „%s“."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] ÐеиÑправна мапа канала „%s“."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] ÐеиÑправан број одломака „%s“."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] ÐеиÑправна величина одломка „%s“."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] ÐеиÑправан ниво приоритета „%s“."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] ÐеиÑправна учеÑтаноÑÑ‚ диÑкретизације „%s“."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "ÐеуÑпело отварање датотеке подешавања: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -862,18 +777,14 @@ msgstr ""
"Ðаведена мапа канала има нема иÑти број канала као што је наведено у "
"подразумеваном броју канала."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Прочитај из датотеке подешавања: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Одбацујем root повлаÑтице."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "УÑпешно ограничио могућноÑти на CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "ЧиÑтим повлаÑтице."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -883,261 +794,237 @@ msgstr "PulseAudio звучни ÑиÑтем"
msgid "Start the PulseAudio Sound System"
msgstr "Покрени PulseAudio звучни ÑиÑтем"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"ВиÑокоприоритетно раÑпоређивање (негативни Unix нивои финоће, тј. nice "
-"нивои) за PulseAudio демона"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "СтварновременÑко раÑпоређивање за PulseAudio демона"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"СиÑтемÑка политика Ñпречава PulseAudio-у да добије виÑокоприоритетно "
-"раÑпоређивање."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"СиÑтемÑка политика Ñпречава PulseAudio-у да добије ÑтварновременÑко "
-"раÑпоређивање."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Моно"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Предњи централни"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Предњи леви"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Предњи деÑни"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "ПозадинÑки централни"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "ПозадинÑки леви"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "ПозадинÑки деÑни"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Звучник за ниÑке фреквенције"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Предњи лево од центра"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Предњи деÑно од центра"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Лева Ñтрана"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "ДеÑна Ñтрана"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Споредни 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Споредни 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Споредни 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Споредни 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Споредни 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Споредни 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Споредни 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Споредни 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Споредни 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Споредни 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Споредни 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Споредни 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Споредни 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Споредни 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Споредни 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Споредни 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Споредни 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Споредни 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Споредни 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Споредни 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Споредни 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Споредни 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Споредни 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Споредни 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Споредни 024"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Споредни 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Споредни 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Споредни 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Споредни 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Споредни 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Споредни 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Споредни 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Горњи централни"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Горњи предњи централни"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Горњи предњи леви"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Горњи предњи деÑни"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Горњи позадинÑки централни"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Горњи позадинÑки леви"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Горњи позадинÑки деÑни"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(неиÑправно)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Стерео"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Окружујући 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Окружујући 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Окружујући 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Окружујући 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Окружујући 7.1"
@@ -1155,7 +1042,7 @@ msgstr "Ðепозната наредба"
#: ../src/pulse/error.c:46
msgid "Invalid argument"
-msgstr "ÐеиÑправан параметар"
+msgstr "ÐеиÑправан аргумент"
#: ../src/pulse/error.c:47
msgid "Entity exists"
@@ -1179,7 +1066,7 @@ msgstr "Време иÑтекло"
#: ../src/pulse/error.c:52
msgid "No authorization key"
-msgstr "Ðема кључа за ауторизацију"
+msgstr "Ðема кључа за овлашћење"
#: ../src/pulse/error.c:53
msgid "Internal error"
@@ -1227,7 +1114,7 @@ msgstr "Ко̑д грешке је непознат"
#: ../src/pulse/error.c:64
msgid "No such extension"
-msgstr "Ðе поÑтоји таква екÑтензија"
+msgstr "Ðе поÑтоји такво проширење"
#: ../src/pulse/error.c:65
msgid "Obsolete functionality"
@@ -1237,32 +1124,39 @@ msgstr "Избачена функционалноÑÑ‚"
msgid "Missing implementation"
msgstr "Ðије одрађено"
-# ÐиÑам Ñигуран да имамо реч за форк. Можда да кориÑтимо форкирање? Ружно звучи, али гранање није најбоље. -- Игор
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr "Клијент израчван"
+msgstr "Клијент је израчван"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Улазна/излазна грешка"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Уређај или реÑÑƒÑ€Ñ Ñ˜Ðµ заузет"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1275,198 +1169,191 @@ msgstr "ÐеуÑпела функција XOpenDisplay()"
msgid "Failed to parse cookie data"
msgstr "ÐеуÑпешно тумачење података из колачића"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "ÐеуÑпешно отварање датотеке подешавања „%s“: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "Колачић није учитан. Покушавам Ñе повезати без колачића."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Примио поруку за непознати локал „%s“"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "ÐеуÑпела функција pa_stream_write(): %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "ÐеуÑпешно иÑушивање тока: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "ÐеуÑпела функција pa_stream_peek(): %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Репродукциони ток је иÑушен."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Ток уÑпешно направљен.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Веза до Ñервера Ñе иÑушује."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "ÐеуÑпешно pa_stream_get_buffer_attr(): %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Метрике бафера: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_write(): %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Метрике бафера: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_write(): %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "КориÑтим Ñледеће параметре узорка „%s“ и мапу канала „%s“.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_peek(): %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "Прикључен на уређај %s (%u, %s обуÑтављено).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Ток је уÑпешно направљен."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Грешка тока: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_get_buffer_attr(): %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Уређај тока обуÑтављен.%s\n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Мере бафера: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Уређај тока наÑтављен.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Мере бафера: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Ток није попуњен. %s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "КориÑтим Ñледеће параметре узорка „%s“ и мапу канала „%s“."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Ток Ñе прелива.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "Прикључен на уређај %s (%u, %s обуÑтављено)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Ток покренут. %s \n"
+msgid "Stream error: %s"
+msgstr "Грешка тока: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Ток пребачен на уређај %s (%u, %s обуÑтављено). %s \n"
+msgid "Stream device suspended.%s"
+msgstr "Уређај тока обуÑтављен.%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "није"
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Параметри бафера тока Ñу промењени. %s \n"
+msgid "Stream device resumed.%s"
+msgstr "Уређај тока наÑтављен.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Веза уÑпоÑтављена.%s \n"
+msgid "Stream underrun.%s"
+msgstr "Ток није попуњен.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "ÐеуÑпела функција pa_stream_new() : %s\n"
+msgid "Stream overrun.%s"
+msgstr "Ток Ñе прелива.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "ÐеуÑпела функција pa_stream_connect_playback(): %s\n"
+msgid "Stream started.%s"
+msgstr "Ток је покренут.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "ÐеуÑпела функција pa_stream_connect_record(): %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Ток пребачен на уређај %s (%u, %s обуÑтављено).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "ÐеуÑпешно повезивање: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "није"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "ÐеуÑпешно иÑушивање тока: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Параметри бафера тока Ñу промењени.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Репродукциони ток иÑушен.\n"
+msgid "Connection established.%s"
+msgstr "Веза уÑпоÑтављена.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Веза до Ñервера Ñе иÑушује.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_new(): %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "Дошао до краја датотеке.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_connect_playback(): %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_connect_record(): %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "ÐеуÑпела функција read(): %s\n"
+msgid "Connection failure: %s"
+msgstr "ÐеуÑпешно повезивање: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "ÐеуÑпела функција write(): %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Добих EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Добио Ñигнал, излазим.\n"
+msgid "write() failed: %s"
+msgstr "ÐеуÑпела функција write(): %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Ðемогу добити вредноÑÑ‚ кашњења: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Добих Ñигнал, излазим."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Време: %0.3f s. Кашњење: %0.0f μs. \r"
+msgid "Failed to get latency: %s"
+msgstr "Ðе могу добити вредноÑÑ‚ кашњења: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "ÐеуÑпела функција pa_stream_update_timing_info(): %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Време: %0.3f s; Кашњење: %0.0f us."
-# Шта да радимо Ñа downmix и upmix. ПреÑликај навише и преÑликај наниже? -- Игор
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "ÐеуÑпела функција pa_stream_update_timing_info(): %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1492,8 +1379,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1516,8 +1405,17 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
-"%s[опције]\n"
+"%s [опције]\n"
"\n"
" -h, --help Прикажи ову помоћ\n"
" --version Прикажи верзију\n"
@@ -1527,42 +1425,52 @@ msgstr ""
"\n"
" -v, --verbose Омогући опширан Ð¾Ð¿Ð¸Ñ Ñ€Ð°Ð´ÑšÐµ\n"
"\n"
-" -s, --server=СЕРВЕР Ðазив Ñервера Ñа којим ће Ñе "
-"повезати\n"
-" -d, --device=УРЕЂÐЈ Ðазив Ñливника/извора на који ће Ñе "
+" -s, --server=СЕРВЕР Име Ñервера на који Ñе треба "
"повезати\n"
+" -d, --device=УРЕЂÐЈ Ðазив Ñливника/извора на који Ñе "
+"треба повезати\n"
" -n, --client-name=ИМЕ Како назвати овог клијента на "
"Ñерверу\n"
" --stream-name=ИМЕ Како назвати овај ток на Ñерверу\n"
-" --volume=ГЛÐСÐОСТ Ðаведи почетну јачину звука између "
-"0...65536 (линеарна Ñкала)\n"
-" --rate=УЧЕСТÐÐОСТ УчеÑтаноÑÑ‚ диÑкретизације у херцима "
+" --volume=ЈÐЧИÐÐ Ðаведи почетну (линеарну) јачину "
+"звука у опÑегу 0...65536\n"
+" --rate=УЧЕСТÐÐОСТ УчеÑтаноÑÑ‚ диÑкретизације у Hz "
"(подразумевана 44100)\n"
-" --format=ФОРМÐТУЗОРКРФормат узорка, једно од s16le, s16be, "
+" --format=ФОРМÐТУЗОРКРВрÑта узорка, једна од s16le, s16be, "
"u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(подразумевано s16ne)\n"
-" --channels=БРОЈКÐÐÐЛРБрој канала, 1 за моно, 2 за Ñтерео\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (подразумевано "
+"s16ne)\n"
+" --channels=КÐÐÐЛИ Број канала, 1 за моно, 2 за Ñтерео\n"
" (подразумевано 2)\n"
" --channel-map=МÐПÐКÐÐÐЛРМапу канала коју треба кориÑтити "
"умеÑто подразумеване\n"
-" --fix-format Преузми формат узорка из Ñливника\n"
-" на који је ток прикључен.\n"
+" --fix-format Преузми формат узорка из Ñливника на "
+"који Ñе ток\n"
+" прикључује.\n"
" --fix-rate Преузми учеÑтаноÑÑ‚ диÑкретизације из "
-"одлива \n"
-" на који је ток прикључен.\n"
+"одлива на који\n"
+" Ñе ток прикључује.\n"
" --fix-channels Преузми број и мапу канала из "
-"Ñливника на\n"
-" који је ток прикључен.\n"
-" --no-remix Без Ñажимања или раширивања броја "
-"канала.\n"
-" --no-remap Ðазначи канале по индекÑу умеÑто по "
+"Ñливника на који Ñе\n"
+" ток прикључује.\n"
+" --no-remix Без Ñвођења или разлагања канала.\n"
+" --no-remap Мапирај канале по индекÑу умеÑто по "
"називу.\n"
" --latency=БÐЈТОВРТражи наведено кашњење у бајтовима.\n"
" --process-time=БÐЈТОВРТражи наведено време процеÑа по "
"захтеву у бајтовима.\n"
+" --property=СВОЈСТВО=ВРЕДÐОСТ ПоÑтави наведено ÑвојÑтво на "
+"наведену вредноÑÑ‚.\n"
+" --raw Снимај/репродукуј Ñирове PCM "
+"податке.\n"
+" --file-format=ФОРМÐТ Снимај/репродукуј форматиране PCM "
+"податке.\n"
+" --list-file-formats ИÑпиши Ñве доÑтупне формате "
+"података.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1573,129 +1481,171 @@ msgstr ""
"Компајлирано Ñа libpulse %s\n"
"Повезано Ñа libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "ÐеиÑправна мапа канала „%s“\n"
+msgid "Invalid client name '%s'"
+msgstr "ÐеиÑправно име клијента „%s“"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "ÐеиÑправан параметар кашњења „%s“\n"
+msgid "Invalid stream name '%s'"
+msgstr "ÐеиÑправно име тока „%s“"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "ÐеиÑправан параметар за време процеÑа „%s“\n"
+msgid "Invalid channel map '%s'"
+msgstr "ÐеиÑправна мапа канала „%s“"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "ÐеиÑправни параметри узорка\n"
+msgid "Invalid latency specification '%s'"
+msgstr "ÐеиÑправан параметар кашњења „%s“"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Мапа канала Ñе не поклапа Ñа параметрима узорка\n"
+msgid "Invalid process time specification '%s'"
+msgstr "ÐеиÑправан параметар за време процеÑа „%s“"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Отварам ток %s Ñа Ñледећим параметрима узорка „%s“.\n"
+msgid "Invalid property '%s'"
+msgstr "ÐеиÑправно ÑвојÑтво „%s“"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "Ñнима"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Ðепознат %s формат датотеке."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "пушта"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "ÐеиÑправан параметар узорка"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Превише параметара.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Превише аргумената."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "ÐеуÑпела функција pa_mainloop_new().\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Ðије уÑпело прављење параметара узорка за датотеку."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "ÐеуÑпела функција io_new() \n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Ðије уÑпело отварање звучне датотеке."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "ÐеуÑпела функција pa_context_new().\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Упозорење: наведени параметри узорка ће бити пребриÑани параметрима из "
+"датотеке."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "ÐеуÑпела функција pa_context_connect(): %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "ÐеуÑпешно утврђивање параметара узорка из датотеке."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Упозорење: ÐеуÑпешно утврђивање мапе канала из датотеке."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Мапа канала Ñе не поклапа Ñа параметрима узорка"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Упозорење: ÐеуÑпешно запиÑивање мапе канала у датотеку."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "ÐеуÑпела функција time_new() \n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "Отварам ток %s Ñа параметрима узорка „%s“ и мапом канала „%s“."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "Ñнима"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "пушта"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "ÐеуÑпела функција pa_mainloop_new()."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "ÐеуÑпела функција io_new()."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "ÐеуÑпела функција pa_context_new()."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "ÐеуÑпела функција pa_mainloop_run().\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "ÐеуÑпела функција pa_context_connect(): %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "ÐеуÑпела функција pa_context_new()."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "ÐеуÑпела функција pa_mainloop_run()."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "ÐеуÑпешно зауÑтављање: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "ÐеуÑпешно наÑтављање: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "УПОЗОРЕЊЕ: Звучни Ñервер није локални, не зауÑтављам.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "ÐеуÑпешно повезивање: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Добих SIGINT, излазим.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "УПОЗОРЕЊЕ: Потлачени Ð¿Ñ€Ð¾Ñ†ÐµÑ Ñ˜Ðµ прекинут Ñигналом %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1710,10 +1660,11 @@ msgstr ""
"\n"
" -h, --help Прикажи ову помоћ\n"
" --version Прикажи верзију\n"
-" -s, --server=СЕРВЕР Име Ñервера Ñа којим Ñе повезује\n"
+" -s, --server=СЕРВЕР Име Ñервера на који Ñе треба "
+"повезати\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1724,35 +1675,61 @@ msgstr ""
"Компајлирано Ñа libpulse %s\n"
"Повезано Ñа libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "ÐеуÑпела функција pa_mainloop_new().\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "ÐеуÑпела функција pa_context_new().\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "ÐеуÑпела функција pa_mainloop_run().\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "ÐеуÑпешно добављање ÑтатиÑтике: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "ÐеуÑпешно добављање ÑтатиÑтике: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Тренутно у употреби: %u блокова Ñадржи укупно %s бајтова.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "Смештено од покретања: %u блокова Ñадржи укупно %s бајтова.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Величина кеш меморије узорка: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "ÐеуÑпешно добијање података о Ñерверу: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "ÐеуÑпешно добављање података о Ñерверу: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1760,7 +1737,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"КориÑничко име: %s\n"
"Име домаћина: %s\n"
@@ -1772,12 +1749,12 @@ msgstr ""
"Подразумевани извор: %s\n"
"Колачић: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "ÐеуÑпешно добијање података о Ñливнику: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "ÐеуÑпешно добављање података о Ñливнику: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1816,12 +1793,22 @@ msgstr ""
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tПортови:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Ðије уÑпело добављање података о извору: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tÐктивни порт: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "ÐеуÑпешно добављање података о извору: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1860,20 +1847,20 @@ msgstr ""
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "непознато"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "ÐеуÑпешно добијање података о модулу: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "ÐеуÑпешно добављање података о модулу: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1885,17 +1872,17 @@ msgid ""
msgstr ""
"Модул #%u\n"
"\tИме: %s\n"
-"\tПараметар: %s\n"
+"\tÐргумент: %s\n"
"\tБројач коришћења: %s\n"
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "ÐеуÑпешно добијање података о клијенту: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "ÐеуÑпешно добављање података о клијенту: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1910,12 +1897,12 @@ msgstr ""
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "ÐеуÑпешно добијање података о картици: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "ÐеуÑпешно добављање података о картици: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1932,22 +1919,22 @@ msgstr ""
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tПрофили:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tÐктивни профил: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Ðије уÑпело добијање података о улазу Ñливника: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "ÐеуÑпешно добављање података о улазу Ñливника: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1984,12 +1971,12 @@ msgstr ""
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Ðије уÑпело добијање података о излазу извора: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "ÐеуÑпешно добављање података о излазу извора: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2018,12 +2005,12 @@ msgstr ""
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Ðије уÑпело добављање података о узорку: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "ÐеуÑпешно добављање података о узорку: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2054,23 +2041,80 @@ msgstr ""
"\tСвојÑтва:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "ÐеуÑпех: %s\n"
+msgid "Failure: %s"
+msgstr "ÐеуÑпех: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Ðије уÑпело учитавање узорка: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Ðије уÑпело поÑтављање узорка: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Прерани крај датотеке\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Прерани крај датотеке"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Сервер неиÑправан"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Добих SIGINT, излазим."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2078,13 +2122,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2100,23 +2153,31 @@ msgstr ""
"%s [опције] upload-sample ИМЕДÐТОТЕКЕ [ИМЕ]\n"
"%s [опције] play-sample ИМЕ [СЛИВÐИК]\n"
"%s [опције] remove-sample ИМЕ\n"
-"%s [опције] move-sink-input ИБ СЛИВÐИКÐ\n"
-"%s [опције] move-source-output ИБ ИЗВОРÐ\n"
-"%s [опције] load-module ИМЕ [ПÐРÐМ. ...]\n"
-"%s [опције] unload-module ИБ\n"
-"%s [опције] suspend-sink [СЛИВÐИК] 1|0\n"
-"%s [опције] suspend-source [ИЗВОР] 1|0\n"
-"%s [опције] set-card-profile [КÐРТИЦÐ] [ПРОФИЛ] \n"
+"%s [опције] move-sink-input УЛÐЗСЛИВÐИКРСЛИВÐИК\n"
+"%s [опције] move-source-output ИЗЛÐЗИЗВОРРИЗВОР\n"
+"%s [опције] load-module ИМЕ [ÐРГ ...]\n"
+"%s [опције] unload-module МОДУЛ\n"
+"%s [опције] suspend-sink СЛИВÐИК 1|0\n"
+"%s [опције] suspend-source ИЗВОР 1|0\n"
+"%s [опције] set-card-profile КÐРТИЦРПРОФИЛ\n"
+"%s [опције] set-sink-port СЛИВÐИК ПОРТ\n"
+"%s [опције] set-source-port ИЗВОР ПОРТ\n"
+"%s [опције] set-sink-volume СЛИВÐИК ЈÐЧИÐÐ\n"
+"%s [опције] set-source-volume ИЗВОР ЈÐЧИÐÐ\n"
+"%s [опције] set-sink-input-volume УЛÐЗСЛИВÐИКРЈÐЧИÐÐ\n"
+"%s [опције] set-sink-mute СЛИВÐИК 1|0\n"
+"%s [опције] set-source-mute ИЗВОР 1|0\n"
+"%s [опције] set-sink-input-mute УЛÐЗСЛИВÐИКР1|0\n"
"\n"
" -h, --help Прикажи ову помоћ\n"
" --version Прикажи верзију\n"
"\n"
" -s, --server=СЕРВЕР Име Ñервера на који Ñе треба "
-"прикључити\n"
+"повезати\n"
" -n, --client-name=ИМЕ Како назвати овог клијента на "
"Ñерверу\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2127,74 +2188,108 @@ msgstr ""
"Компајлирано Ñа libpulse %s\n"
"Повезано Ñа libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Ðаведите датотеку узорка коју треба учитати\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Ðаведите датотеку узорка коју треба учитати"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Ðије уÑпело отварање звучне датотеке.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Ðије уÑпело отварање звучне датотеке."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Морате навеÑти име узорка којег желите пуÑтити\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Упозорење: ÐеуÑпешно утврђивање параметара узорка из датотеке."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Морате навеÑти име узорка којег желите уклонити\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Морате навеÑти име узорка којег желите репродуковати"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ ÑƒÐ»Ð°Ð·Ð° у Ñливнику и Ñливник\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Морате навеÑти име узорка којег желите уклонити"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ð·Ð»Ð°Ð·Ð° у извору и извор\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ ÑƒÐ»Ð°Ð·Ð° Ñливника и Ñливник"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Морате навеÑти име и параметре модула.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ð·Ð»Ð°Ð·Ð° извора и извор"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ Ð¼Ð¾Ð´ÑƒÐ»Ð°\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Морате навеÑти име и аргументе модула."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ Ð¼Ð¾Ð´ÑƒÐ»Ð°"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr "Можете навеÑти Ñамо један Ñливник. Морате навеÑти логичку вредноÑÑ‚.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+"Ðе можете навеÑти више од једног Ñливника. Морате навеÑти логичку вредноÑÑ‚."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr "Можете навеÑти Ñамо један извор. Морате навеÑти логичку вредноÑÑ‚.\n"
+"value."
+msgstr ""
+"Ðе можете навеÑти више од једног извора. Морате навеÑти логичку вредноÑÑ‚."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ ÐºÐ°Ñ€Ñ‚Ð¸Ñ†Ðµ и име профила\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ ÐºÐ°Ñ€Ñ‚Ð¸Ñ†Ðµ и име профила"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Ðи једна иÑправна наредба није наведена.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ Ñливника и име порта"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "ÐеуÑпела функција pa_context_connect(): %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ð·Ð²Ð¾Ñ€Ð° и име порта"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ Ñливника и јачину"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "ÐеиÑправан параметар јачине"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ð·Ð²Ð¾Ñ€Ð° и јачину"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ ÑƒÐ»Ð°Ð·Ð° Ñливника и јачину"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "ÐеиÑправан Ð¸Ð½Ð´ÐµÐºÑ ÑƒÐ»Ð°Ð·Ð° Ñливника"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ Ñливника и логичку вредноÑÑ‚ за иÑкључивање"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Морате навеÑти име/Ð¸Ð½Ð´ÐµÐºÑ Ð¸Ð·Ð²Ð¾Ñ€Ð° и логичку вредноÑÑ‚ за иÑкључивање"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "Морате навеÑти Ð¸Ð½Ð´ÐµÐºÑ ÑƒÐ»Ð°Ð·Ð° Ñливника и логичку вредноÑÑ‚ за иÑкључивање"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "ÐеиÑправан параметар индекÑа улаза Ñливника"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Ðије наведена иÑправна наредба."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2277,129 +2372,49 @@ msgstr "ÐеуÑпешно учитавање датотека колачића\
msgid "Not yet implemented.\n"
msgstr "Ðије још имплементирано.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Ðема покренутог PulseAudio демона, или Ñе не извршава као демон ÑеÑије."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Ðије уÑпело убијање PulseAudio демона."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Демон Ñе не одазива."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Ток уÑпешно направљен\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Грешка тока: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Веза уÑтановљена.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [опције] [ДÐТОТЕКÐ]\n"
-"\n"
-" -h, --help Прикажи ову помоћ\n"
-" --version Прикажи верзију\n"
-"\n"
-" -v, --verbose Омогући опширни Ð¾Ð¿Ð¸Ñ Ñ€Ð°Ð´ÑšÐ¸\n"
-"\n"
-" -s, --server=СЕРВЕР Име Ñервера на који Ñе повезује\n"
-" -d, --device=УРЕЂÐЈ Име Ñливника на које Ñе повезује\n"
-" -n, --client-name=ИМЕ Како назвати овог клијента на "
-"Ñерверу\n"
-" --stream-name=ИМЕ Како назвати овај ток на Ñерверу\n"
-" --volume=ГЛÐСÐОСТ Ðаведи почетну (линеарну) јачину "
-"звука из опÑега 0...65536\n"
-" --channel-map=МÐПÐКÐÐÐЛРПоÑтави мапу канала која ће Ñе "
-"кориÑтити\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Компајлирано Ñа libpulse %s\n"
-"Повезано Ñа libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "ÐеиÑправна мапа канала\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "ÐеуÑпело отварање датотеке „%s“\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Мапа канала Ñе не поклапа Ñа датотеком.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "КориÑте Ñе Ñледећи параметри узорка „%s“\n"
-
-# Како превеÑти autospawn (могућноÑÑ‚ прављења или покретања процеÑа из иÑтог) -- Игор
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Ðије могуће приÑтупити датотеци закључавања за Ñамоумножавање."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2416,7 +2431,7 @@ msgstr ""
"Пробуђени Ñмо Ñа поÑтављеним POLLOUT-ом -- али Ñледећи snd_pcm_avail() је "
"вратио 0 или неку другу вредноÑÑ‚ мању од min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2433,34 +2448,259 @@ msgstr ""
"Пробуђени Ñмо Ñа поÑтављеним POLLIN-ом -- али Ñледећи snd_pcm_avail() је "
"вратио 0 или неку другу вредноÑÑ‚ мању од min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Излаз %s + улаз %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Излаз %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Улаз %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "ИÑкључено"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "Репродукција виÑоке тачноÑти (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Снимање виÑоке тачноÑти (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
-msgstr "ДвоÑтрано телефонирање (HSP/HFP)"
+msgstr "ДвоÑмерно телефонирање (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio звучни ÑиÑтем"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Излазни уређаји"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Улазни уређаји"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Ðудио на @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Улаз"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Улаз прикључне Ñтанице"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Микрофон прикључне Ñтанице"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Линија у"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Спољни микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Унутрашњи микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Радио"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Видео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "СамоÑтална контрола појачања"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Без ÑамоÑталне контроле појачања"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Подизање"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Без подизања"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "Појачало"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Без појачала"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Подизање"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Без подизања"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Ðналогне Ñлушалице"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Ðналогни улаз"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Ðналогни микрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Ðналогна линија у"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Ðналогни радио"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Ðналогни видео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Ðналогни излаз"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Ðналогне Ñлушалице"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Ðналогни излаз (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Ðналогни моно излаз"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Ðналогни Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Ðналогни моно"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Ðналогни Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Ðналогни окружујући 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Ðналогни окружујући 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Ðналогни окружујући 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Ðналогни окружујући 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Ðналогни окружујући 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Ðналогни окружујући 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Ðналогни окружујући 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Ðналогни окружујући 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Ðналогни окружујући 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Ðналогни окружујући 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Ðналогни окружујући 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Дигитални Ñтерео (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Дигитални окружујући 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Дигитални окружујући 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Дигитални окружујући 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Дигитални Ñтерео (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "ДвоÑмерни аналогни моно"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "ДвоÑмерни аналогни Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "ДвоÑмерни дигитални Ñтерео (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Звучник за ниÑке фреквенције"
diff --git a/po/sr@latin.po b/po/sr@latin.po
index 4ffaad20..c42db983 100644
--- a/po/sr@latin.po
+++ b/po/sr@latin.po
@@ -1,70 +1,29 @@
# Serbian(Latin) translations for pulseaudio
# Copyright (C) 2006 Lennart Poettering
# This file is distributed under the same license as the pulseaudio package.
-#
# Igor Miletic (Igor Miletić) <grejigl-gnomeprevod@yahoo.ca>, 2009.
# MiloÅ¡ KomarÄević <kmilos@gmail.com>, 2009.
+#
msgid ""
msgstr ""
"Project-Id-Version: pulseaudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-07 23:02+0100\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-30 22:51+0100\n"
"Last-Translator: MiloÅ¡ KomarÄević <kmilos@gmail.com>\n"
-"Language-Team: Serbian <fedora-trans-sr@redhat.com>\n"
+"Language-Team: Serbian (sr) <fedora-trans-sr@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%"
"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
-"X-Generator: Lokalize 0.3\n"
-
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analogni mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analogni stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Digitalni stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Digitalni stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analogni okružujući 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digitalni okružujući 4.0 (IEC958/AC3)"
-
-# Surround možemo prevesti ambijentalni ili okružni ili možda Äak i saraund? -- Igor
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analogni okružujući 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analogni okružujući 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analogni okružujući 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digitalni okružujući 5.1 (IEC958/AC3)"
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analogni okružujući 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -77,7 +36,7 @@ msgstr ""
"Ovo je najverovatnije greÅ¡ka u „%s“ ALSA upravljaÄkom programu. Prijavite "
"ovaj problem ALSA programerima."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -90,7 +49,7 @@ msgstr ""
"Ovo je najverovatnije greÅ¡ka u „%s“ ALSA upravljaÄkom programu. Prijavite "
"ovaj problem ALSA programerima."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -103,11 +62,45 @@ msgstr ""
"Ovo je najverovatnije greÅ¡ka u „%s“ ALSA upravljaÄkom programu. Prijavite "
"ovaj problem ALSA programerima."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "Uvek održava barem jedan slivnik opterećenim Äak i kada je prazan"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Lažan izlaz"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Virtuelni LADSPA slivnik"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<ime slivnika> sink_properties=<svojstva slivnika> master=<ime "
+"slivnika za filtriranje> format=<format uzorka> rate=<uÄestanost "
+"diskretizacije> channels=<broj kanala> channel_map=<mapa kanala> plugin=<ime "
+"ladspa dodatka> label=<oznaka ladspa dodatka> control=<spisak ulaznih "
+"kontrolnih vrednosti razdvojenih zarezom>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Uzorak NULL slivnika"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Prazan izlaz"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Unutrašnji zvuk"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Modem"
@@ -123,223 +116,98 @@ msgstr "NeuspeÅ¡no smeÅ¡tanje novog dl uÄitavaÄa."
msgid "Failed to add bind-now-loader."
msgstr "NeuspeÅ¡no dodavanje „poveži odmah“ uÄitavaÄa."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Nije se moguće prikljuÄiti na sistemsku magistralu: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Ne mogu dobaviti pozivnika iz PID-a: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Ne mogu postaviti UID za pozivniÄki objekat."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Neuspešno dobavljanje CK sesije."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Ne mogu postaviti UID za objekat sesije."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Ne mogu postaviti PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Ne mogu postaviti action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Ne mogu postaviti PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Ne mogu inicijalizovati PolKitContex: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Nije moguće odrediti ovlašćenje pozivnika: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Ne mogu dobiti ovlašćenje: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit je odgovorio sa „%s“"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Dobih signal %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Napuštam."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Ne mogu naći korisnika „%s“."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Ne mogu naći grupu „%s“."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Nađeni su korisnik „%s“ (UID %lu) i grupa „%s“ (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID korisnika „%s“ se ne poklapa sa grupom „%s“."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "LiÄni direktorijum korisnika „%s“ nije „%s“, zanemarujem."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Neuspešno pravljenje „%s“: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Neuspešna promena grupnog spiska: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Neuspešna promena GID-a: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Neuspešna promena UID-a: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "UspeÅ¡no odbaÄena root ovlašćenja."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "Režim za Äitav sistem nije podržan na ovoj platformi."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) nije uspelo: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "NeuspeÅ¡no tumaÄenje komandne linije."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Nalazimo se u grupi „%s“ koja dozvoljava visokoprioritetno raspoređivanje."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Nalazimo se u grupi „%s“ koja dozvoljava stvarnovremensko raspoređivanje."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit nam je dao ovlašćenje za dobijanje visokog prioriteta."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit odbija ovlašćenje za dobijanje visokog prioriteta."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit nam je dao ovlašćenje za dobijanje rada u stvarnom vremenu."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit odbija ovlašćenje za dobijanje rada u stvarnom vremenu."
-
-#
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"SUID root i stvarnovremensko i/ili visokoprioritetno raspoređivanje je "
-"zahtevano u podešavanjima. Međutim, nemamo potrebna ovlašćenja:\n"
-"nismo u grupi „%s“, PolicyKit odbija da nam dȃ tražena ovlašćenja i nemamo "
-"sredstava za povećanje RLIMIT_NICE/RLIMIT_RTPRIO ograniÄenja.\n"
-"Morate dobiti odgovarajuća PolicyKit ovlašćenja, ili postati Älan grupe „%"
-"s“, ili povećati ograniÄenja za RLIMIT_NICE/RLIMIT_RTPRIO sredstva ovog "
-"korisnika kako bi omogućili stvarnovremensko ili visokoprioritetno "
-"raspoređivanje."
-
-#: ../src/daemon/main.c:581
+#: ../src/daemon/main.c:535
msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"Visokoprioritetno raspoređivanje je omogućeno u podešavanjima, ali politika "
-"to ne dozvoljava."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "UspeÅ¡no povećano RLIMIT_RTPRIO ograniÄenje"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "Neuspešno postavljanje RLIMIT_RTPRIO-a:%s"
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "Odustajem od CAP_NICE"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"Stvarnovremensko raspoređivanje je omogućeno u podešavanjima, ali politika "
-"to ne dozvoljava."
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Demon nije pokrenut"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Demon je pokrenut sa PID-om %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Neuspešno ubijanje demona: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -347,162 +215,198 @@ msgstr ""
"Nije nameravano da se ovaj program pokreće iz root naloga (osim u sluÄaju "
"kada je --system navedeno)"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Potrebna su root ovlašćenja."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start nije podržano za sistemske primerke."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "Pokrenuto u sistemskom režimu, ali --disallow-exit nije postavljeno!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"Pokrenuto u sistemskom režimu, ali --disallow-module-loading nije "
"postavljeno!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "Pokrenuto u sistemskom režimu, prisilno onemogućujem SHM režim!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"Pokrenuto u sistemskom režimu, prisilno onemogućujem gašenje posle određenog "
"vremena mirovanja!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Neuspešno pronalaženje standardnog ulaza/izlaza."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "Neuspešno puštanje podataka kroz cev: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "Neuspela funkcija fork(): %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "Neuspela funkcija read(): %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Neuspešno pokretanje demona."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Demon uspešno pokrenut."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "Neuspela funkcija read(): %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Ovo je PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Domaćin kompajliranja: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "CFLAGS kompajliranja: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Pokrenut na domaćinu: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "Našao %u procesor(a)"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "VeliÄina stranice je %lu bajtova"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Kompajlirano sa podrškom za Valgrind: da"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Kompajlirano sa podrškom za Valgrind: ne"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "Pokrenut u Valgrind režimu: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Pokrenut na domaćinu: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Optimizovana izgradnja: da"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Optimizovana izgradnja: ne"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG definisan, sva obaveÅ¡tenja iskljuÄena."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH definisan, samo obaveÅ¡tenja brze putanje iskljuÄena."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "Sva obaveštenja omogućena."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Neuspešno dobavljanje IB mašine"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "IB mašine je %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "IB mašine je %s."
+msgstr "IB sesije je %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Koristi se %s izvršni direktorijum."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Koristi se %s direktorijum stanja."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Koristi se %s direktorijum modula."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "Pokrenuto u sistemskom režimu: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"U redu, znaÄi izvrÅ¡avate PA u sistemskom režimu. Primite k znanju da to "
+"verovatno ne bi trebalo da radite.\n"
+"Ako to svejedno Äinite onda je vaÅ¡a krivica ako stvari ne rade onako kako se "
+"oÄekuje.\n"
+"ProÄitajte http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode radi "
+"objaÅ¡njenja zaÅ¡to je sistemski režim obiÄno loÅ¡a ideja."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "Neuspela funkcija pa_pid_file_create()."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "Dostupni su novi brojaÄi visoke rezolucije! Prijatno!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -510,31 +414,31 @@ msgstr ""
"VaÅ¡e jezgro nije dobro podeÅ¡eno za pulseaudio! PreporuÄuje Vam se da "
"koristite Linux jezgro sa omogućenim brojaÄima visoke rezolucije."
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "Neuspela funkcija pa_core_new()."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Neuspešno pokretanje demona."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "Demon je pokrenut bez ijednog uÄitanog modula, odbija da radi."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "Pokretanje demona uspešno."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Pokrenuto gašenje demona."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Rad demona je prekinut."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -607,14 +511,14 @@ msgid ""
"\n"
" -n Don't load default script file\n"
msgstr ""
-"%s [options]\n"
+"%s [opcije]\n"
"\n"
"NAREDBE:\n"
" -h, --help Prikaži ovu pomoć\n"
" --version Prikaži verziju\n"
-" --dump-conf Izlistaj podrazumevana podešavanja\n"
-" --dump-modules Izlistaj spisak dostupnih modula\n"
-" --dump-resample-methods Izlistaj dostupne vrednosti "
+" --dump-conf Ispiši podrazumevana podešavanja\n"
+" --dump-modules Ispiši spisak dostupnih modula\n"
+" --dump-resample-methods Ispiši dostupne vrednosti "
"diskretizacije\n"
" --cleanup-shm OÄisti bajate delove deljene "
"memorije\n"
@@ -660,7 +564,7 @@ msgstr ""
" --log-backtrace=FRAMES UkljuÄi tragove u porukama dnevnika\n"
" -p, --dl-search-path=PUTANJA Postavi putanju pretrage za "
"dinamiÄki deljene\n"
-" objekte (dodatci)\n"
+" objekte (dodaci)\n"
" --resample-method=NAÄŒIN Koristi navedeni naÄin "
"diskretizacije\n"
" (Pogledaj --dump-resample-methods "
@@ -685,71 +589,71 @@ msgstr ""
" -n Ne uÄitavaj podrazumevanu datoteku "
"skripte.\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
-msgstr "--daemonize oÄekuje logiÄku vrednost"
+msgstr "--daemonize oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
-msgstr "--fail oÄekuje logiÄku vrednost"
+msgstr "--fail oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
msgstr ""
-"--log-level oÄekuje parametar za nivo opÅ¡irnosti (numeriÄka vrednost izmeÄ‘u "
-"0 i 4 ili jedno od: debug, info, notice, warn, error)."
+"--log-level oÄekuje argument za nivo zapisa (ili numeriÄka vrednost u opsegu "
+"0..4 ili jedno od debug, info, notice, warn, error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
-msgstr "--high-priority oÄekuje logiÄku vrednost"
+msgstr "--high-priority oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
-msgstr "--realtime oÄekuje logiÄku vrednost"
+msgstr "--realtime oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
-msgstr "--disallow-module-loading oÄekuje logiÄku vrednost"
+msgstr "--disallow-module-loading oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
-msgstr "--disallow-exit oÄekuje logiÄku vrednost"
+msgstr "--disallow-exit oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
-msgstr "--use-pid-file oÄekuje logiÄku vrednost"
+msgstr "--use-pid-file oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
"Neispravan ciljni dnevnik: koristite jedno od „syslog“, „stderr“ ili „auto“."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
-msgstr "--log-time oÄekuje logiÄku vrednost"
+msgstr "--log-time oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
-msgstr "--log-meta oÄekuje logiÄku vrednost"
+msgstr "--log-meta oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Neispravan naÄin diskretizacije „%s“."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
-msgstr "--system oÄekuje logiÄku vrednost"
+msgstr "--system oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
-msgstr "--no-cpu-limit oÄekuje logiÄku vrednost"
+msgstr "--no-cpu-limit oÄekuje logiÄki argument"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
-msgstr "--disable-shm oÄekuje logiÄku vrednost"
+msgstr "--disable-shm oÄekuje logiÄki argument"
#: ../src/daemon/dumpmodules.c:60
#, c-format
@@ -786,77 +690,87 @@ msgstr "Upotreba: %s\n"
msgid "Load Once: %s\n"
msgstr "UÄitaj jednom: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "UPOZORENJE O PREVAZILAŽENJU: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Putanja: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Neispravan ciljni dnevnik „%s“."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Neispravan nivo opširnosti u dnevniku „%s“."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Neispravan naÄin diskretizacije „%s“."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Neispravan rlimit „%s“."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit nije podržan na ovoj platformi."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Neispravan format uzorka „%s“."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Neispravna uÄestanost diskretizacije „%s“."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Neispravni kanali uzorka „%s“."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Neispravna mapa kanala „%s“."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Neispravan broj odlomaka „%s“."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Neispravna veliÄina odlomka „%s“."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Neispravan nivo prioriteta „%s“."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Neispravna uÄestanost diskretizacije „%s“."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Neuspelo otvaranje datoteke podešavanja: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -864,18 +778,14 @@ msgstr ""
"Navedena mapa kanala ima nema isti broj kanala kao što je navedeno u "
"podrazumevanom broju kanala."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### ProÄitaj iz datoteke podeÅ¡avanja: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "Odbacujem root povlastice."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "UspeÅ¡no ograniÄio mogućnosti na CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "ÄŒistim povlastice."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -885,261 +795,237 @@ msgstr "PulseAudio zvuÄni sistem"
msgid "Start the PulseAudio Sound System"
msgstr "Pokreni PulseAudio zvuÄni sistem"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"Visokoprioritetno raspoređivanje (negativni Unix nivoi finoće, tj. nice "
-"nivoi) za PulseAudio demona"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "Stvarnovremensko raspoređivanje za PulseAudio demona"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Sistemska politika spreÄava PulseAudiu da dobije visokoprioritetno "
-"raspoređivanje."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-"Sistemska politika spreÄava PulseAudiu da dobije stvarnovremensko "
-"raspoređivanje."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Prednji centralni"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Prednji levi"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Prednji desni"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Pozadinski centralni"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Pozadinski levi"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Pozadinski desni"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "ZvuÄnik za niske frekvencije"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Prednji levo od centra"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Prednji desno od centra"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Leva strana"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Desna strana"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Sporedni 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Sporedni 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Sporedni 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Sporedni 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Sporedni 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Sporedni 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Sporedni 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Sporedni 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Sporedni 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Sporedni 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Sporedni 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Sporedni 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Sporedni 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Sporedni 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Sporedni 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Sporedni 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Sporedni 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Sporedni 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Sporedni 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Sporedni 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Sporedni 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Sporedni 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Sporedni 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Sporedni 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Sporedni 024"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Sporedni 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Sporedni 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Sporedni 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Sporedni 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Sporedni 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Sporedni 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Sporedni 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Gornji centralni"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Gornji prednji centralni"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Gornji prednji levi"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Gornji prednji desni"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Gornji pozadinski centralni"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Gornji pozadinski levi"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Gornji pozadinski desni"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(neispravno)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Stereo"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Okružujući 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Okružujući 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Okružujući 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Okružujući 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Okružujući 7.1"
@@ -1157,7 +1043,7 @@ msgstr "Nepoznata naredba"
#: ../src/pulse/error.c:46
msgid "Invalid argument"
-msgstr "Neispravan parametar"
+msgstr "Neispravan argument"
#: ../src/pulse/error.c:47
msgid "Entity exists"
@@ -1181,7 +1067,7 @@ msgstr "Vreme isteklo"
#: ../src/pulse/error.c:52
msgid "No authorization key"
-msgstr "Nema kljuÄa za autorizaciju"
+msgstr "Nema kljuÄa za ovlašćenje"
#: ../src/pulse/error.c:53
msgid "Internal error"
@@ -1229,7 +1115,7 @@ msgstr "Kȏd greške je nepoznat"
#: ../src/pulse/error.c:64
msgid "No such extension"
-msgstr "Ne postoji takva ekstenzija"
+msgstr "Ne postoji takvo proširenje"
#: ../src/pulse/error.c:65
msgid "Obsolete functionality"
@@ -1239,32 +1125,39 @@ msgstr "IzbaÄena funkcionalnost"
msgid "Missing implementation"
msgstr "Nije odrađeno"
-# Nisam siguran da imamo reÄ za fork. Možda da koristimo forkiranje? Ružno zvuÄi, ali grananje nije najbolje. -- Igor
#: ../src/pulse/error.c:67
msgid "Client forked"
-msgstr "Klijent izraÄvan"
+msgstr "Klijent je izraÄvan"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Ulazna/izlazna greška"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "Uređaj ili resurs je zauzet"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1277,198 +1170,191 @@ msgstr "Neuspela funkcija XOpenDisplay()"
msgid "Failed to parse cookie data"
msgstr "NeuspeÅ¡no tumaÄenje podataka iz kolaÄića"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Neuspešno otvaranje datoteke podešavanja „%s“: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "KolaÄić nije uÄitan. PokuÅ¡avam se povezati bez kolaÄića."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Primio poruku za nepoznati lokal „%s“"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "Neuspela funkcija pa_stream_write(): %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Neuspešno isušivanje toka: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "Neuspela funkcija pa_stream_peek(): %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Reprodukcioni tok je isušen."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Tok uspešno napravljen.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Veza do servera se isušuje."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "Neuspešno pa_stream_get_buffer_attr(): %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Metrike bafera: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "Neuspela funkcija pa_stream_write(): %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Metrike bafera: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "Neuspela funkcija pa_stream_write(): %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "Koristim sledeće parametre uzorka „%s“ i mapu kanala „%s“.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "Neuspela funkcija pa_stream_peek(): %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "PrikljuÄen na ureÄ‘aj %s (%u, %s obustavljeno).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Tok je uspešno napravljen."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Greška toka: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "Neuspela funkcija pa_stream_get_buffer_attr(): %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Uređaj toka obustavljen.%s\n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Mere bafera: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Uređaj toka nastavljen.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Mere bafera: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "Tok nije popunjen. %s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "Koristim sledeće parametre uzorka „%s“ i mapu kanala „%s“."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "Tok se preliva.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "PrikljuÄen na ureÄ‘aj %s (%u, %s obustavljeno)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Tok pokrenut. %s \n"
+msgid "Stream error: %s"
+msgstr "Greška toka: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Tok prebaÄen na ureÄ‘aj %s (%u, %s obustavljeno). %s \n"
+msgid "Stream device suspended.%s"
+msgstr "Uređaj toka obustavljen.%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "nije"
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "Parametri bafera toka su promenjeni. %s \n"
+msgid "Stream device resumed.%s"
+msgstr "Uređaj toka nastavljen.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Veza uspostavljena.%s \n"
+msgid "Stream underrun.%s"
+msgstr "Tok nije popunjen.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "Neuspela funkcija pa_stream_new() : %s\n"
+msgid "Stream overrun.%s"
+msgstr "Tok se preliva.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "Neuspela funkcija pa_stream_connect_playback(): %s\n"
+msgid "Stream started.%s"
+msgstr "Tok je pokrenut.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "Neuspela funkcija pa_stream_connect_record(): %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Tok prebaÄen na ureÄ‘aj %s (%u, %s obustavljeno).%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Neuspešno povezivanje: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "nije"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Neuspešno isušivanje toka: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "Parametri bafera toka su promenjeni.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Reprodukcioni tok isušen.\n"
+msgid "Connection established.%s"
+msgstr "Veza uspostavljena.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Veza do servera se isušuje.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "Neuspela funkcija pa_stream_new(): %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "Došao do kraja datoteke.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "Neuspela funkcija pa_stream_connect_playback(): %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "Neuspela funkcija pa_stream_connect_record(): %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "Neuspela funkcija read(): %s\n"
+msgid "Connection failure: %s"
+msgstr "Neuspešno povezivanje: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "Neuspela funkcija write(): %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Dobih EOF."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Dobio signal, izlazim.\n"
+msgid "write() failed: %s"
+msgstr "Neuspela funkcija write(): %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Nemogu dobiti vrednost kašnjenja: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Dobih signal, izlazim."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Vreme: %0.3f s. Kašnjenje: %0.0f μs. \r"
+msgid "Failed to get latency: %s"
+msgstr "Ne mogu dobiti vrednost kašnjenja: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "Neuspela funkcija pa_stream_update_timing_info(): %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Vreme: %0.3f s; Kašnjenje: %0.0f us."
-# Šta da radimo sa downmix i upmix. Preslikaj naviše i preslikaj naniže? -- Igor
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "Neuspela funkcija pa_stream_update_timing_info(): %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1494,8 +1380,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1518,8 +1406,17 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
-"%s[opcije]\n"
+"%s [opcije]\n"
"\n"
" -h, --help Prikaži ovu pomoć\n"
" --version Prikaži verziju\n"
@@ -1529,43 +1426,53 @@ msgstr ""
"\n"
" -v, --verbose Omogući opširan opis radnje\n"
"\n"
-" -s, --server=SERVER Naziv servera sa kojim će se "
-"povezati\n"
-" -d, --device=UREÄAJ Naziv slivnika/izvora na koji će se "
+" -s, --server=SERVER Ime servera na koji se treba "
"povezati\n"
+" -d, --device=UREÄAJ Naziv slivnika/izvora na koji se "
+"treba povezati\n"
" -n, --client-name=IME Kako nazvati ovog klijenta na "
"serveru\n"
" --stream-name=IME Kako nazvati ovaj tok na serveru\n"
-" --volume=GLASNOST Navedi poÄetnu jaÄinu zvuka izmeÄ‘u "
-"0...65536 (linearna skala)\n"
-" --rate=UÄŒESTANOST UÄestanost diskretizacije u hercima "
+" --volume=JAÄŒINA Navedi poÄetnu (linearnu) jaÄinu "
+"zvuka u opsegu 0...65536\n"
+" --rate=UÄŒESTANOST UÄestanost diskretizacije u Hz "
"(podrazumevana 44100)\n"
-" --format=FORMATUZORKA Format uzorka, jedno od s16le, s16be, "
+" --format=FORMATUZORKA Vrsta uzorka, jedna od s16le, s16be, "
"u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(podrazumevano s16ne)\n"
-" --channels=BROJKANALA Broj kanala, 1 za mono, 2 za stereo\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (podrazumevano "
+"s16ne)\n"
+" --channels=KANALI Broj kanala, 1 za mono, 2 za stereo\n"
" (podrazumevano 2)\n"
" --channel-map=MAPAKANALA Mapu kanala koju treba koristiti "
"umesto podrazumevane\n"
-" --fix-format Preuzmi format uzorka iz slivnika\n"
-" na koji je tok prikljuÄen.\n"
+" --fix-format Preuzmi format uzorka iz slivnika na "
+"koji se tok\n"
+" prikljuÄuje.\n"
" --fix-rate Preuzmi uÄestanost diskretizacije iz "
-"odliva \n"
-" na koji je tok prikljuÄen.\n"
+"odliva na koji\n"
+" se tok prikljuÄuje.\n"
" --fix-channels Preuzmi broj i mapu kanala iz "
-"slivnika na\n"
-" koji je tok prikljuÄen.\n"
-" --no-remix Bez sažimanja ili raširivanja broja "
-"kanala.\n"
-" --no-remap NaznaÄi kanale po indeksu umesto po "
+"slivnika na koji se\n"
+" tok prikljuÄuje.\n"
+" --no-remix Bez svođenja ili razlaganja kanala.\n"
+" --no-remap Mapiraj kanale po indeksu umesto po "
"nazivu.\n"
" --latency=BAJTOVA Traži navedeno kašnjenje u "
"bajtovima.\n"
" --process-time=BAJTOVA Traži navedeno vreme procesa po "
"zahtevu u bajtovima.\n"
+" --property=SVOJSTVO=VREDNOST Postavi navedeno svojstvo na "
+"navedenu vrednost.\n"
+" --raw Snimaj/reprodukuj sirove PCM "
+"podatke.\n"
+" --file-format=FORMAT Snimaj/reprodukuj formatirane PCM "
+"podatke.\n"
+" --list-file-formats Ispiši sve dostupne formate "
+"podataka.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1576,129 +1483,171 @@ msgstr ""
"Kompajlirano sa libpulse %s\n"
"Povezano sa libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Neispravna mapa kanala „%s“\n"
+msgid "Invalid client name '%s'"
+msgstr "Neispravno ime klijenta „%s“"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Neispravan parametar kašnjenja „%s“\n"
+msgid "Invalid stream name '%s'"
+msgstr "Neispravno ime toka „%s“"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Neispravan parametar za vreme procesa „%s“\n"
+msgid "Invalid channel map '%s'"
+msgstr "Neispravna mapa kanala „%s“"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Neispravni parametri uzorka\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Neispravan parametar kašnjenja „%s“"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Mapa kanala se ne poklapa sa parametrima uzorka\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Neispravan parametar za vreme procesa „%s“"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Otvaram tok %s sa sledećim parametrima uzorka „%s“.\n"
+msgid "Invalid property '%s'"
+msgstr "Neispravno svojstvo „%s“"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "snima"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Nepoznat %s format datoteke."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "pušta"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Neispravan parametar uzorka"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Previše parametara.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Previše argumenata."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "Neuspela funkcija pa_mainloop_new().\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Nije uspelo pravljenje parametara uzorka za datoteku."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "Neuspela funkcija io_new() \n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Nije uspelo otvaranje zvuÄne datoteke."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "Neuspela funkcija pa_context_new().\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"Upozorenje: navedeni parametri uzorka će biti prebrisani parametrima iz "
+"datoteke."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "Neuspela funkcija pa_context_connect(): %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Neuspešno utvrđivanje parametara uzorka iz datoteke."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "Upozorenje: Neuspešno utvrđivanje mape kanala iz datoteke."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Mapa kanala se ne poklapa sa parametrima uzorka"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "Upozorenje: Neuspešno zapisivanje mape kanala u datoteku."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "Neuspela funkcija time_new() \n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "Otvaram tok %s sa parametrima uzorka „%s“ i mapom kanala „%s“."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "snima"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "pušta"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "Neuspela funkcija pa_mainloop_new()."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "Neuspela funkcija io_new()."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "Neuspela funkcija pa_context_new()."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "Neuspela funkcija pa_mainloop_run().\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "Neuspela funkcija pa_context_connect(): %s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "Neuspela funkcija pa_context_new()."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "Neuspela funkcija pa_mainloop_run()."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Neuspešno zaustavljanje: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Neuspešno nastavljanje: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "UPOZORENJE: ZvuÄni server nije lokalni, ne zaustavljam.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Neuspešno povezivanje: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Dobih SIGINT, izlazim.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "UPOZORENJE: PotlaÄeni proces je prekinut signalom %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1713,10 +1662,11 @@ msgstr ""
"\n"
" -h, --help Prikaži ovu pomoć\n"
" --version Prikaži verziju\n"
-" -s, --server=SERVER Ime servera sa kojim se povezuje\n"
+" -s, --server=SERVER Ime servera na koji se treba "
+"povezati\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1727,35 +1677,61 @@ msgstr ""
"Kompajlirano sa libpulse %s\n"
"Povezano sa libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "Neuspela funkcija pa_mainloop_new().\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "Neuspela funkcija pa_context_new().\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "Neuspela funkcija pa_mainloop_run().\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Neuspešno dobavljanje statistike: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "Neuspešno dobavljanje statistike: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Trenutno u upotrebi: %u blokova sadrži ukupno %s bajtova.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "Smešteno od pokretanja: %u blokova sadrži ukupno %s bajtova.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "VeliÄina keÅ¡ memorije uzorka: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Neuspešno dobijanje podataka o serveru: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Neuspešno dobavljanje podataka o serveru: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1763,7 +1739,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"KorisniÄko ime: %s\n"
"Ime domaćina: %s\n"
@@ -1775,12 +1751,12 @@ msgstr ""
"Podrazumevani izvor: %s\n"
"KolaÄić: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Neuspešno dobijanje podataka o slivniku: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Neuspešno dobavljanje podataka o slivniku: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1819,12 +1795,22 @@ msgstr ""
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPortovi:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tAktivni port: %s\n"
+
+#: ../src/utils/pactl.c:310
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Nije uspelo dobavljanje podataka o izvoru: %s\n"
+msgid "Failed to get source information: %s"
+msgstr "Neuspešno dobavljanje podataka o izvoru: %s"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1863,20 +1849,20 @@ msgstr ""
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "nepoznato"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Neuspešno dobijanje podataka o modulu: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Neuspešno dobavljanje podataka o modulu: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1888,17 +1874,17 @@ msgid ""
msgstr ""
"Modul #%u\n"
"\tIme: %s\n"
-"\tParametar: %s\n"
+"\tArgument: %s\n"
"\tBrojaÄ korišćenja: %s\n"
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Neuspešno dobijanje podataka o klijentu: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Neuspešno dobavljanje podataka o klijentu: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1913,12 +1899,12 @@ msgstr ""
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Neuspešno dobijanje podataka o kartici: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Neuspešno dobavljanje podataka o kartici: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1935,22 +1921,22 @@ msgstr ""
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tProfili:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tAktivni profil: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Nije uspelo dobijanje podataka o ulazu slivnika: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Neuspešno dobavljanje podataka o ulazu slivnika: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1987,12 +1973,12 @@ msgstr ""
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Nije uspelo dobijanje podataka o izlazu izvora: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "Neuspešno dobavljanje podataka o izlazu izvora: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2021,12 +2007,12 @@ msgstr ""
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Nije uspelo dobavljanje podataka o uzorku: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Neuspešno dobavljanje podataka o uzorku: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2057,23 +2043,80 @@ msgstr ""
"\tSvojstva:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Neuspeh: %s\n"
+msgid "Failure: %s"
+msgstr "Neuspeh: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Nije uspelo uÄitavanje uzorka: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Nije uspelo postavljanje uzorka: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "Prerani kraj datoteke\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "Prerani kraj datoteke"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Server neispravan"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Dobih SIGINT, izlazim."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2081,13 +2124,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2103,23 +2155,31 @@ msgstr ""
"%s [opcije] upload-sample IMEDATOTEKE [IME]\n"
"%s [opcije] play-sample IME [SLIVNIK]\n"
"%s [opcije] remove-sample IME\n"
-"%s [opcije] move-sink-input IB SLIVNIKA\n"
-"%s [opcije] move-source-output IB IZVORA\n"
-"%s [opcije] load-module IME [PARAM. ...]\n"
-"%s [opcije] unload-module IB\n"
-"%s [opcije] suspend-sink [SLIVNIK] 1|0\n"
-"%s [opcije] suspend-source [IZVOR] 1|0\n"
-"%s [opcije] set-card-profile [KARTICA] [PROFIL] \n"
+"%s [opcije] move-sink-input ULAZSLIVNIKA SLIVNIK\n"
+"%s [opcije] move-source-output IZLAZIZVORA IZVOR\n"
+"%s [opcije] load-module IME [ARG ...]\n"
+"%s [opcije] unload-module MODUL\n"
+"%s [opcije] suspend-sink SLIVNIK 1|0\n"
+"%s [opcije] suspend-source IZVOR 1|0\n"
+"%s [opcije] set-card-profile KARTICA PROFIL\n"
+"%s [opcije] set-sink-port SLIVNIK PORT\n"
+"%s [opcije] set-source-port IZVOR PORT\n"
+"%s [opcije] set-sink-volume SLIVNIK JAÄŒINA\n"
+"%s [opcije] set-source-volume IZVOR JAÄŒINA\n"
+"%s [opcije] set-sink-input-volume ULAZSLIVNIKA JAÄŒINA\n"
+"%s [opcije] set-sink-mute SLIVNIK 1|0\n"
+"%s [opcije] set-source-mute IZVOR 1|0\n"
+"%s [opcije] set-sink-input-mute ULAZSLIVNIKA 1|0\n"
"\n"
" -h, --help Prikaži ovu pomoć\n"
" --version Prikaži verziju\n"
"\n"
" -s, --server=SERVER Ime servera na koji se treba "
-"prikljuÄiti\n"
+"povezati\n"
" -n, --client-name=IME Kako nazvati ovog klijenta na "
"serveru\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2130,74 +2190,109 @@ msgstr ""
"Kompajlirano sa libpulse %s\n"
"Povezano sa libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Navedite datoteku uzorka koju treba uÄitati\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Navedite datoteku uzorka koju treba uÄitati"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Nije uspelo otvaranje zvuÄne datoteke.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Nije uspelo otvaranje zvuÄne datoteke."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Morate navesti ime uzorka kojeg želite pustiti\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Upozorenje: Neuspešno utvrđivanje parametara uzorka iz datoteke."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Morate navesti ime uzorka kojeg želite ukloniti\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Morate navesti ime uzorka kojeg želite reprodukovati"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Morate navesti indeks ulaza u slivniku i slivnik\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Morate navesti ime uzorka kojeg želite ukloniti"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Morate navesti indeks izlaza u izvoru i izvor\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Morate navesti indeks ulaza slivnika i slivnik"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Morate navesti ime i parametre modula.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Morate navesti indeks izlaza izvora i izvor"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Morate navesti indeks modula\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Morate navesti ime i argumente modula."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Morate navesti indeks modula"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr "Možete navesti samo jedan slivnik. Morate navesti logiÄku vrednost.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+"Ne možete navesti viÅ¡e od jednog slivnika. Morate navesti logiÄku vrednost."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr "Možete navesti samo jedan izvor. Morate navesti logiÄku vrednost.\n"
+"value."
+msgstr ""
+"Ne možete navesti viÅ¡e od jednog izvora. Morate navesti logiÄku vrednost."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Morate navesti ime/indeks kartice i ime profila\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Morate navesti ime/indeks kartice i ime profila"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Ni jedna ispravna naredba nije navedena.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Morate navesti ime/indeks slivnika i ime porta"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "Neuspela funkcija pa_context_connect(): %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Morate navesti ime/indeks izvora i ime porta"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Morate navesti ime/indeks slivnika i jaÄinu"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Neispravan parametar jaÄine"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Morate navesti ime/indeks izvora i jaÄinu"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Morate navesti indeks ulaza slivnika i jaÄinu"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Neispravan indeks ulaza slivnika"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "Morate navesti ime/indeks slivnika i logiÄku vrednost za iskljuÄivanje"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "Morate navesti ime/indeks izvora i logiÄku vrednost za iskljuÄivanje"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+"Morate navesti indeks ulaza slivnika i logiÄku vrednost za iskljuÄivanje"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Neispravan parametar indeksa ulaza slivnika"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Nije navedena ispravna naredba."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2280,129 +2375,49 @@ msgstr "NeuspeÅ¡no uÄitavanje datoteka kolaÄića\n"
msgid "Not yet implemented.\n"
msgstr "Nije još implementirano.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Nema pokrenutog PulseAudio demona, ili se ne izvršava kao demon sesije."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "Nije uspelo ubijanje PulseAudio demona."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Demon se ne odaziva."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Tok uspešno napravljen\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Greška toka: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Veza ustanovljena.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [opcije] [DATOTEKA]\n"
-"\n"
-" -h, --help Prikaži ovu pomoć\n"
-" --version Prikaži verziju\n"
-"\n"
-" -v, --verbose Omogući opširni opis radnji\n"
-"\n"
-" -s, --server=SERVER Ime servera na koji se povezuje\n"
-" -d, --device=UREÄAJ Ime slivnika na koje se povezuje\n"
-" -n, --client-name=IME Kako nazvati ovog klijenta na "
-"serveru\n"
-" --stream-name=IME Kako nazvati ovaj tok na serveru\n"
-" --volume=GLASNOST Navedi poÄetnu (linearnu) jaÄinu "
-"zvuka iz opsega 0...65536\n"
-" --channel-map=MAPAKANALA Postavi mapu kanala koja će se "
-"koristiti\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Kompajlirano sa libpulse %s\n"
-"Povezano sa libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Neispravna mapa kanala\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Neuspelo otvaranje datoteke „%s“\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Mapa kanala se ne poklapa sa datotekom.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "Koriste se sledeći parametri uzorka „%s“\n"
-
-# Kako prevesti autospawn (mogućnost pravljenja ili pokretanja procesa iz istog) -- Igor
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Nije moguće pristupiti datoteci zakljuÄavanja za samoumnožavanje."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2419,7 +2434,7 @@ msgstr ""
"Probuđeni smo sa postavljenim POLLOUT-om -- ali sledeći snd_pcm_avail() je "
"vratio 0 ili neku drugu vrednost manju od min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2436,34 +2451,259 @@ msgstr ""
"Probuđeni smo sa postavljenim POLLIN-om -- ali sledeći snd_pcm_avail() je "
"vratio 0 ili neku drugu vrednost manju od min_avail."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "Izlaz %s + ulaz %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "Izlaz %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "Ulaz %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "IskljuÄeno"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "Reprodukcija visoke taÄnosti (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "Snimanje visoke taÄnosti (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
-msgstr "Dvostrano telefoniranje (HSP/HFP)"
+msgstr "Dvosmerno telefoniranje (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio zvuÄni sistem"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "Izlazni uređaji"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "Ulazni uređaji"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Audio na @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Ulaz"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Ulaz prikljuÄne stanice"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Mikrofon prikljuÄne stanice"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Linija u"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Spoljni mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Unutrašnji mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Samostalna kontrola pojaÄanja"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Bez samostalne kontrole pojaÄanja"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "Podizanje"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Bez podizanja"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "PojaÄalo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Bez pojaÄala"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "Podizanje"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Bez podizanja"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "Analogne slušalice"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Analogni ulaz"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Analogni mikrofon"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Analogna linija u"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Analogni radio"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Analogni video"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Analogni izlaz"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Analogne slušalice"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Analogni izlaz (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Analogni mono izlaz"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Analogni stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Analogni mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Analogni stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analogni okružujući 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analogni okružujući 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analogni okružujući 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analogni okružujući 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analogni okružujući 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analogni okružujući 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analogni okružujući 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analogni okružujući 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analogni okružujući 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analogni okružujući 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analogni okružujući 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digitalni stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digitalni okružujući 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digitalni okružujući 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digitalni okružujući 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digitalni stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Dvosmerni analogni mono"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Dvosmerni analogni stereo"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Dvosmerni digitalni stereo (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "ZvuÄnik za niske frekvencije"
diff --git a/po/sv.po b/po/sv.po
index 4eb1c2db..eee75852 100644
--- a/po/sv.po
+++ b/po/sv.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: pulseaudio\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
"PO-Revision-Date: 2008-09-05 18:24+0100\n"
"Last-Translator: Daniel Nylander <po@danielnylander.se>\n"
"Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n"
@@ -15,51 +15,12 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr ""
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
msgstr ""
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -68,7 +29,7 @@ msgid ""
"to the ALSA developers."
msgstr ""
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -77,7 +38,7 @@ msgid ""
"to the ALSA developers."
msgstr ""
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -86,230 +47,149 @@ msgid ""
"to the ALSA developers."
msgstr ""
-#: ../src/pulsecore/sink.c:2141
-#, fuzzy
-msgid "Internal Audio"
-msgstr "Internt fel"
-
-#: ../src/pulsecore/sink.c:2147
-msgid "Modem"
-msgstr ""
-
-#: ../src/daemon/ltdl-bind-now.c:124
-msgid "Failed to find original lt_dlopen loader."
-msgstr ""
-
-#: ../src/daemon/ltdl-bind-now.c:129
-#, fuzzy
-msgid "Failed to allocate new dl loader."
-msgstr "Misslyckades med att öppna ljudfil.\n"
-
-#: ../src/daemon/ltdl-bind-now.c:142
-msgid "Failed to add bind-now-loader."
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
msgstr ""
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr ""
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
msgstr ""
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
msgstr ""
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
msgstr ""
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
msgstr ""
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
msgstr ""
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr ""
+#: ../src/pulsecore/sink.c:2615
+#, fuzzy
+msgid "Internal Audio"
+msgstr "Internt fel"
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
msgstr ""
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
msgstr ""
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr ""
+#: ../src/daemon/ltdl-bind-now.c:129
+#, fuzzy
+msgid "Failed to allocate new dl loader."
+msgstr "Misslyckades med att öppna ljudfil.\n"
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
msgstr ""
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit svarade med \"%s\""
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Fick signal %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Avslutar."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Misslyckades med att hitta användaren \"%s\"."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Misslyckades med att hitta gruppen \"%s\"."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr ""
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr ""
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Hemkatalogen för användaren \"%s\" är inte \"%s\", ignorerar."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Misslyckades med att skapa \"%s\": %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr ""
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr ""
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr ""
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr ""
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr ""
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) misslyckades: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr ""
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr ""
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr ""
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO misslyckades: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr ""
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr ""
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr ""
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr ""
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -317,189 +197,219 @@ msgstr ""
"Detta program är inte tänkt att köras som root (såvida inte --system har "
"angivits)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
#, fuzzy
msgid "Root privileges required."
msgstr "Root-behörighet krävs."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start stöds inte för systeminstanser."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr ""
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr ""
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "pipe misslyckades: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() misslyckades: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() misslyckades: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr ""
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr ""
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() misslyckades: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Detta är PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr ""
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr ""
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr ""
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr ""
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr ""
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr ""
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr ""
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr ""
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, c-format
+msgid "Running in VM: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr ""
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr ""
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr ""
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr ""
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr ""
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr ""
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr ""
-#: ../src/daemon/main.c:913
+#: ../src/daemon/main.c:874
#, c-format
msgid "Session ID is %s."
msgstr ""
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr ""
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr ""
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr ""
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr ""
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() misslyckades."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr ""
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr ""
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() misslyckades."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr ""
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr ""
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr ""
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr ""
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -573,69 +483,69 @@ msgid ""
" -n Don't load default script file\n"
msgstr ""
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
msgstr ""
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
#, fuzzy
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit booleskt argument"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr ""
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
#, fuzzy
msgid "--log-time expects boolean argument"
msgstr "--realtime förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
#, fuzzy
msgid "--log-meta expects boolean argument"
msgstr "--disallow-exit booleskt argument"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr ""
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit förväntar sig ett booleskt argument"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm förväntar sig ett booleskt argument"
@@ -674,96 +584,102 @@ msgstr "Användning: %s\n"
msgid "Load Once: %s\n"
msgstr ""
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "Sökväg: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr ""
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr ""
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "Ogiltig server"
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Misslyckades med att öppna konfigurationsfil: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr ""
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr ""
-#: ../src/daemon/caps.c:63
+#: ../src/daemon/caps.c:62
#, fuzzy
-msgid "Dropping root privileges."
+msgid "Cleaning up privileges."
msgstr "Släpper root-behörighet."
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr ""
-
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
msgstr ""
@@ -772,256 +688,238 @@ msgstr ""
msgid "Start the PulseAudio Sound System"
msgstr ""
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Mono"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Center fram"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Vänster fram"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Höger fram"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Center bak"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Vänster bak"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Höger bak"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
msgstr ""
-#: ../src/pulse/channelmap.c:115
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Vänster-om-center fram"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Höger-om-center fram"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Vänster sida"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Höger sida"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr ""
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr ""
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr ""
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr ""
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr ""
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr ""
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr ""
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr ""
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr ""
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr ""
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr ""
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr ""
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr ""
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr ""
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr ""
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr ""
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr ""
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr ""
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr ""
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr ""
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr ""
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr ""
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr ""
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr ""
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr ""
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr ""
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr ""
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr ""
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr ""
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr ""
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr ""
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr ""
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr ""
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr ""
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr ""
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr ""
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr ""
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr ""
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr ""
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
#, fuzzy
msgid "(invalid)"
msgstr "Ogiltig"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr ""
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr ""
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr ""
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr ""
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr ""
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr ""
@@ -1125,27 +1023,35 @@ msgstr ""
msgid "Client forked"
msgstr ""
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr ""
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr ""
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr ""
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr ""
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr ""
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr ""
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr ""
@@ -1158,196 +1064,192 @@ msgstr "XOpenDisplay() misslyckades"
msgid "Failed to parse cookie data"
msgstr ""
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Misslyckades med att öppna konfigurationsfilen \"%s\": %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr ""
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr ""
-#: ../src/utils/pacat.c:94
-#, c-format
-msgid "pa_stream_write() failed: %s\n"
+#: ../src/utils/pacat.c:110
+#, fuzzy, c-format
+msgid "Failed to drain stream: %s"
+msgstr "Misslyckades med att hitta användaren \"%s\"."
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr ""
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr ""
+
+#: ../src/utils/pacat.c:138
+#, fuzzy, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s\n"
+
+#: ../src/utils/pacat.c:161
+#, fuzzy, c-format
+msgid "pa_stream_write() failed: %s"
msgstr "pa_stream_write() misslyckades: %s\n"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
+#: ../src/utils/pacat.c:202
+#, fuzzy, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() misslyckades: %s\n"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, fuzzy, c-format
+msgid "pa_stream_peek() failed: %s"
msgstr "pa_stream_peek() misslyckades: %s\n"
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
msgstr ""
-#: ../src/utils/pacat.c:172
-#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
+#: ../src/utils/pacat.c:325
+#, fuzzy, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
msgstr "pa_stream_get_buffer_attr() misslyckades: %s\n"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
msgstr ""
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
msgstr ""
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
+msgid "Using sample spec '%s', channel map '%s'."
msgstr ""
-#: ../src/utils/pacat.c:187
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
+msgid "Connected to device %s (%u, %ssuspended)."
msgstr ""
-#: ../src/utils/pacat.c:197
-#, c-format
-msgid "Stream error: %s\n"
+#: ../src/utils/pacat.c:350
+#, fuzzy, c-format
+msgid "Stream error: %s"
msgstr "Strömfel: %s\n"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream device suspended.%s \n"
+msgid "Stream device suspended.%s"
msgstr ""
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream device resumed.%s \n"
+msgid "Stream device resumed.%s"
msgstr ""
-#: ../src/utils/pacat.c:217
-#, c-format
-msgid "Stream underrun.%s \n"
-msgstr ""
+#: ../src/utils/pacat.c:370
+#, fuzzy, c-format
+msgid "Stream underrun.%s"
+msgstr "Strömfel: %s\n"
-#: ../src/utils/pacat.c:224
-#, c-format
-msgid "Stream overrun.%s \n"
-msgstr ""
+#: ../src/utils/pacat.c:377
+#, fuzzy, c-format
+msgid "Stream overrun.%s"
+msgstr "Strömfel: %s\n"
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "Stream started.%s \n"
+msgid "Stream started.%s"
msgstr ""
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
msgstr ""
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:391
msgid "not "
msgstr "inte "
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
+msgid "Stream buffer attributes changed.%s"
msgstr ""
-#: ../src/utils/pacat.c:278
-#, c-format
-msgid "Connection established.%s \n"
-msgstr ""
+#: ../src/utils/pacat.c:430
+#, fuzzy, c-format
+msgid "Connection established.%s"
+msgstr "Anslutning etablerad.\n"
-#: ../src/utils/pacat.c:281
-#, c-format
-msgid "pa_stream_new() failed: %s\n"
+#: ../src/utils/pacat.c:433
+#, fuzzy, c-format
+msgid "pa_stream_new() failed: %s"
msgstr "pa_stream_new() misslyckades: %s\n"
-#: ../src/utils/pacat.c:309
-#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
+#: ../src/utils/pacat.c:471
+#, fuzzy, c-format
+msgid "pa_stream_connect_playback() failed: %s"
msgstr "pa_stream_connect_playback() misslyckades: %s\n"
-#: ../src/utils/pacat.c:315
-#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
+#: ../src/utils/pacat.c:477
+#, fuzzy, c-format
+msgid "pa_stream_connect_record() failed: %s"
msgstr "pa_stream_connect_record() misslyckades: %s\n"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, fuzzy, c-format
+msgid "Connection failure: %s"
msgstr "Anslutningsfel: %s\n"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr ""
-
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
-#, c-format
-msgid "Playback stream drained.\n"
-msgstr ""
-
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
-#, c-format
-msgid "Draining connection to server.\n"
-msgstr ""
-
-#: ../src/utils/pacat.c:390
-#, c-format
-msgid "Got EOF.\n"
+#: ../src/utils/pacat.c:524
+#, fuzzy
+msgid "Got EOF."
msgstr "Fick filslut.\n"
-#: ../src/utils/pacat.c:396
-#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
-
-#: ../src/utils/pacat.c:406
-#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() misslyckades: %s\n"
-
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
+#: ../src/utils/pacat.c:561
+#, fuzzy, c-format
+msgid "write() failed: %s"
msgstr "write() misslyckades: %s\n"
-#: ../src/utils/pacat.c:459
-#, c-format
-msgid "Got signal, exiting.\n"
-msgstr ""
+#: ../src/utils/pacat.c:582
+#, fuzzy
+msgid "Got signal, exiting."
+msgstr "Fick signal %s."
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr ""
+#: ../src/utils/pacat.c:596
+#, fuzzy, c-format
+msgid "Failed to get latency: %s"
+msgstr "Misslyckades med att få statistik: %s\n"
-#: ../src/utils/pacat.c:478
-#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
+#: ../src/utils/pacat.c:601
+#, fuzzy, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
msgstr "Tid: %0.3f sec; Latens: %0.0f ms \r"
-#: ../src/utils/pacat.c:498
-#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
+#: ../src/utils/pacat.c:620
+#, fuzzy, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
msgstr "pa_stream_update_timing_info() misslyckades: %s\n"
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:630
#, c-format
msgid ""
"%s [options]\n"
@@ -1374,8 +1276,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1398,9 +1302,18 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1408,129 +1321,180 @@ msgid ""
"Linked with libpulse %s\n"
msgstr ""
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, fuzzy, c-format
+msgid "Invalid client name '%s'"
+msgstr "Ogiltig server"
+
+#: ../src/utils/pacat.c:806
+#, fuzzy, c-format
+msgid "Invalid stream name '%s'"
+msgstr "Ogiltig server"
+
+#: ../src/utils/pacat.c:843
+#, fuzzy, c-format
+msgid "Invalid channel map '%s'"
+msgstr "Ogiltig server"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid channel map '%s'\n"
+msgid "Invalid latency specification '%s'"
msgstr ""
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, fuzzy, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "Ogiltig server"
+
+#: ../src/utils/pacat.c:905
+#, fuzzy, c-format
+msgid "Invalid property '%s'"
+msgstr "Ogiltig server"
+
+#: ../src/utils/pacat.c:922
#, c-format
-msgid "Invalid latency specification '%s'\n"
+msgid "Unknown file format %s."
msgstr ""
-#: ../src/utils/pacat.c:705
-#, c-format
-msgid "Invalid process time specification '%s'\n"
+#: ../src/utils/pacat.c:941
+#, fuzzy
+msgid "Invalid sample specification"
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pacat.c:951
+#, fuzzy, c-format
+msgid "open(): %s"
+msgstr "open(): %s\n"
+
+#: ../src/utils/pacat.c:956
+#, fuzzy, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s\n"
+
+#: ../src/utils/pacat.c:963
+#, fuzzy
+msgid "Too many arguments."
+msgstr "För många argument.\n"
+
+#: ../src/utils/pacat.c:974
+#, fuzzy
+msgid "Failed to generate sample specification for file."
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pacat.c:994
+#, fuzzy
+msgid "Failed to open audio file."
+msgstr "Misslyckades med att öppna ljudfil.\n"
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
msgstr ""
-#: ../src/utils/pacat.c:716
-#, c-format
-msgid "Invalid sample specification\n"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+#, fuzzy
+msgid "Failed to determine sample specification from file."
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
msgstr ""
-#: ../src/utils/pacat.c:721
-#, c-format
-msgid "Channel map doesn't match sample specification\n"
+#: ../src/utils/pacat.c:1023
+#, fuzzy
+msgid "Channel map doesn't match sample specification"
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
msgstr ""
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
msgstr ""
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:1050
msgid "recording"
msgstr ""
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:1050
msgid "playback"
msgstr ""
-#: ../src/utils/pacat.c:736
-#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
-
-#: ../src/utils/pacat.c:741
-#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
-
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "För många argument.\n"
-
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+#, fuzzy
+msgid "pa_mainloop_new() failed."
msgstr "pa_mainloop_new() misslyckades.\n"
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
+#: ../src/utils/pacat.c:1095
+#, fuzzy
+msgid "io_new() failed."
msgstr "io_new() misslyckades.\n"
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+#, fuzzy
+msgid "pa_context_new() failed."
msgstr "pa_context_new() misslyckades.\n"
-#: ../src/utils/pacat.c:799
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
+msgid "pa_context_connect() failed: %s"
msgstr "pa_context_new() misslyckades.\n"
-#: ../src/utils/pacat.c:810
-#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() misslyckades.\n"
+#: ../src/utils/pacat.c:1116
+#, fuzzy
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_new() misslyckades.\n"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
-#, c-format
-msgid "pa_mainloop_run() failed.\n"
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+#, fuzzy
+msgid "pa_mainloop_run() failed."
msgstr "pa_mainloop_run() misslyckades.\n"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr ""
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr ""
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr ""
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Anslutningsfel: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr ""
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr ""
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1542,7 +1506,7 @@ msgid ""
"\n"
msgstr ""
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1553,35 +1517,61 @@ msgstr ""
"Kompilerad med libpulse %s\n"
"Länkad med libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() misslyckades.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() misslyckades.\n"
+
+#: ../src/utils/pasuspender.c:296
#, c-format
-msgid "Failed to get statistics: %s\n"
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() misslyckades.\n"
+
+#: ../src/utils/pactl.c:134
+#, fuzzy, c-format
+msgid "Failed to get statistics: %s"
msgstr "Misslyckades med att få statistik: %s\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr ""
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr ""
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
+#, fuzzy, c-format
+msgid "Failed to get server information: %s"
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pactl.c:160
#, c-format
-msgid "Failed to get server information: %s\n"
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
msgstr ""
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:176
#, c-format
msgid ""
-"User name: %s\n"
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1589,15 +1579,15 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
-#: ../src/utils/pactl.c:178
-#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:218
+#, fuzzy, c-format
+msgid "Failed to get sink information: %s"
+msgstr "Misslyckades med att få klientinformation: %s\n"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1619,12 +1609,22 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
#, c-format
-msgid "Failed to get source information: %s\n"
+msgid "\tPorts:\n"
msgstr ""
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, fuzzy, c-format
+msgid "\tActive Port: %s\n"
+msgstr "pipe misslyckades: %s"
+
+#: ../src/utils/pactl.c:310
+#, fuzzy, c-format
+msgid "Failed to get source information: %s"
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1646,20 +1646,20 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr ""
-#: ../src/utils/pactl.c:324
-#, c-format
-msgid "Failed to get module information: %s\n"
+#: ../src/utils/pactl.c:388
+#, fuzzy, c-format
+msgid "Failed to get module information: %s"
msgstr "Misslyckades med att få modulinformation: %s\n"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1670,12 +1670,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:361
-#, c-format
-msgid "Failed to get client information: %s\n"
+#: ../src/utils/pactl.c:425
+#, fuzzy, c-format
+msgid "Failed to get client information: %s"
msgstr "Misslyckades med att få klientinformation: %s\n"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1685,12 +1685,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, fuzzy, c-format
-msgid "Failed to get card information: %s\n"
+msgid "Failed to get card information: %s"
msgstr "Misslyckades med att få modulinformation: %s\n"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1701,22 +1701,22 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr ""
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, fuzzy, c-format
msgid "\tActive Profile: %s\n"
msgstr "pipe misslyckades: %s"
-#: ../src/utils/pactl.c:445
-#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:509
+#, fuzzy, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "Misslyckades med att få klientinformation: %s\n"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1737,12 +1737,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:503
-#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:567
+#, fuzzy, c-format
+msgid "Failed to get source output information: %s"
+msgstr "Misslyckades med att få modulinformation: %s\n"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1759,12 +1759,12 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:554
-#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr ""
+#: ../src/utils/pactl.c:618
+#, fuzzy, c-format
+msgid "Failed to get sample information: %s"
+msgstr "Misslyckades med att få modulinformation: %s\n"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -1782,22 +1782,81 @@ msgid ""
"\t\t%s\n"
msgstr ""
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
-#, c-format
-msgid "Failure: %s\n"
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, fuzzy, c-format
+msgid "Failure: %s"
msgstr "Fel: %s\n"
-#: ../src/utils/pactl.c:636
-#, c-format
-msgid "Failed to upload sample: %s\n"
+#: ../src/utils/pactl.c:700
+#, fuzzy, c-format
+msgid "Failed to upload sample: %s"
+msgstr "Misslyckades med att hitta användaren \"%s\"."
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
msgstr ""
-#: ../src/utils/pactl.c:653
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr "sink"
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr "källa"
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+#, fuzzy
+msgid "source-output"
+msgstr "källa"
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Ogiltig server"
+
+#: ../src/utils/pactl.c:787
#, c-format
-msgid "Premature end of file\n"
+msgid "Event '%s' on %s #%u\n"
msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:955
+#, fuzzy
+msgid "Got SIGINT, exiting."
+msgstr "Fick signal %s."
+
+#: ../src/utils/pactl.c:961
#, c-format
msgid ""
"%s [options] stat\n"
@@ -1806,13 +1865,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -1823,7 +1891,7 @@ msgid ""
"server\n"
msgstr ""
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -1834,74 +1902,110 @@ msgstr ""
"Kompilerad med libpulse %s\n"
"Länkad med libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
msgstr ""
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
+#: ../src/utils/pactl.c:1085
+#, fuzzy
+msgid "Failed to open sound file."
msgstr "Misslyckades med att öppna ljudfil.\n"
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
+#: ../src/utils/pactl.c:1097
+#, fuzzy
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
msgstr ""
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
msgstr ""
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
msgstr ""
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
msgstr ""
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
msgstr ""
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
msgstr ""
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
msgstr ""
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
msgstr ""
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_new() misslyckades.\n"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+#, fuzzy
+msgid "Invalid volume specification"
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr ""
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1336
+#, fuzzy
+msgid "Invalid sink input index specification"
+msgstr "Misslyckades med att få modulinformation: %s\n"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr ""
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -1975,165 +2079,351 @@ msgstr ""
msgid "Not yet implemented.\n"
msgstr "Ännu inte implementerad.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr ""
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr ""
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr ""
-#: ../src/utils/pacmd.c:144
-#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+#: ../src/utils/pacmd.c:178
+#, fuzzy, c-format
+msgid "poll(): %s"
+msgstr "fork(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
msgstr ""
-#: ../src/utils/paplay.c:144
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
-msgid "Stream errror: %s\n"
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
msgstr ""
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Anslutning etablerad.\n"
-
-#: ../src/utils/paplay.c:198
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
msgstr ""
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
msgstr ""
-"paplay %s\n"
-"Kompilerad med libpulse %s\n"
-"Länkad med libpulse %s\n"
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
msgstr ""
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Misslyckades med att öppna filen \"%s\"\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr ""
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
msgstr ""
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
-msgid "Cannot access autospawn lock."
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
msgstr ""
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
-#, c-format
-msgid ""
-"ALSA woke us up to write new data to the device, but there was actually "
-"nothing to write!\n"
-"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
-"to the ALSA developers.\n"
-"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
-"returned 0 or another value < min_avail."
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
msgstr ""
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
-#, c-format
-msgid ""
-"ALSA woke us up to read new data from the device, but there was actually "
-"nothing to read!\n"
-"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
-"to the ALSA developers.\n"
-"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
-"returned 0 or another value < min_avail."
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+#, fuzzy
+msgid "Internal Microphone"
+msgstr "Internt fel"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+msgid "Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+msgid "No Bass Boost"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+msgid "Headphones"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:117
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+msgid "Analog Speakers"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
#, c-format
-msgid "Output %s"
+msgid "%s+%s"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:121
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
#, c-format
-msgid "Input %s"
+msgid "%s / %s"
msgstr ""
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
-msgid "Off"
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
-msgid "High Fidelity Playback (A2DP)"
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
-msgid "Telephony Duplex (HSP/HFP)"
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
-msgid "PulseAudio Sound Server"
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
msgstr ""
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr ""
+
+#~ msgid "select(): %s"
+#~ msgstr "select(): %s"
+
+#~ msgid "PolicyKit responded with '%s'"
+#~ msgstr "PolicyKit svarade med \"%s\""
+
+#~ msgid "read() failed: %s\n"
+#~ msgstr "read() misslyckades: %s\n"
+
+#, fuzzy
+#~ msgid "pa_context_connect() failed: %s\n"
+#~ msgstr "pa_context_new() misslyckades.\n"
+
+#~ msgid "RLIMIT_RTPRIO failed: %s"
+#~ msgstr "RLIMIT_RTPRIO misslyckades: %s"
+
+#~ msgid "time_new() failed.\n"
+#~ msgstr "time_new() misslyckades.\n"
+
+#~ msgid ""
+#~ "paplay %s\n"
+#~ "Compiled with libpulse %s\n"
+#~ "Linked with libpulse %s\n"
+#~ msgstr ""
+#~ "paplay %s\n"
+#~ "Kompilerad med libpulse %s\n"
+#~ "Länkad med libpulse %s\n"
+
+#~ msgid "Failed to open file '%s'\n"
+#~ msgstr "Misslyckades med att öppna filen \"%s\"\n"
+
#, fuzzy
#~ msgid "--log-time boolean argument"
#~ msgstr "--disallow-exit booleskt argument"
@@ -2144,11 +2434,5 @@ msgstr ""
#~ msgid "muted"
#~ msgstr "tystad"
-#~ msgid "sink"
-#~ msgstr "sink"
-
-#~ msgid "source"
-#~ msgstr "källa"
-
#~ msgid "socketpair(): %s"
#~ msgstr "socketpair(): %s"
diff --git a/po/ta.po b/po/ta.po
index b47fd63c..1fe6bc32 100644
--- a/po/ta.po
+++ b/po/ta.po
@@ -1,14 +1,14 @@
-# translation of pulseaudio.master-tx.pulseaudio.po to Tamil
+# translation of pulseaudio.master-tx.ta.po to Tamil
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# I. Felix <ifelix@redhat.com>, 2009.
msgid ""
msgstr ""
-"Project-Id-Version: pulseaudio.master-tx.pulseaudio\n"
+"Project-Id-Version: pulseaudio.master-tx.ta\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-12 05:02+0530\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-11-13 16:54+0530\n"
"Last-Translator: I. Felix <ifelix@redhat.com>\n"
"Language-Team: Tamil <fedora-trans-ta@redhat.com>\n"
"MIME-Version: 1.0\n"
@@ -33,52 +33,18 @@ msgstr ""
"\n"
"\n"
"\n"
+"\n"
+"\n"
+"\n"
+"\n"
+"\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Analog Mono"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Analog Stereo"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Digital Stereo (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Digital Stereo (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Analog Surround 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Digital Surround 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Analog Surround 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Analog Surround 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Analog Surround 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Digital Surround 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Analog Surround 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -91,7 +57,7 @@ msgstr ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -104,7 +70,7 @@ msgstr ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -117,11 +83,45 @@ msgstr ""
"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
"to the ALSA developers."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "ஒர௠பூஜà¯à®œà®¿à®¯à®®à¯ இரà¯à®¨à¯à®¤à®¾à®²à¯à®®à¯ கà¯à®±à¯ˆà®¨à¯à®¤à®¤à¯ ஒனà¯à®±à¯ˆ மடà¯à®Ÿà¯à®®à¯ வைதà¯à®¤à®¿à®°à¯à®•à¯à®•வà¯à®®à¯"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "டமà¯à®®à®¿ வெளிபà¯à®ªà®¾à®Ÿà¯"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "மெயà¯à®¨à®¿à®•ர௠LADSPA சினà¯à®•à¯"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "கடிகார பூஜà¯à®œà®¿à®¯ சிஙà¯"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "பூஜà¯à®œà®¿à®¯ வெளிபà¯à®ªà®¾à®Ÿà¯"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "உடà¯à®ªà¯à®± ஆடியோ"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "மாதிரி"
@@ -137,381 +137,292 @@ msgstr "பà¯à®¤à®¿à®¯ dl à®à®±à¯à®±à¯à®ªà®µà®°à¯ˆ ஒதà¯à®•à¯à®•ிரà
msgid "Failed to add bind-now-loader."
msgstr "இபà¯à®ªà¯‹à®¤à¯ பிணைகà¯à®•à¯à®®à¯ à®à®±à¯à®ªà®¿à®¯à¯ˆ சேரà¯à®ªà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "கணினி பஸà¯à®¸à¯ˆ இணைகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PID லிரà¯à®¨à¯à®¤à¯ அழைபà¯à®ªà®¾à®³à®°à¯ˆ பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "UID கà¯à®•௠அழைபà¯à®ªà®¾à®³à®°à¯ பொரà¯à®³à¯ˆ அமைகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK அமரà¯à®µà¯ˆ பெறà¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "அமரà¯à®µà¯ பொரà¯à®³à®¿à®²à¯ UID஠அமைகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitAction஠ஒதà¯à®•à¯à®• இயலவிலà¯à®²à¯ˆ."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "செயலை அமைகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ (_i)"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext஠ஒஉகà¯à®•ிட à®®à¯à®Ÿà®¿à®¯à®šà®µà®¿à®²à¯à®²à¯ˆ."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContext஠தà¯à®µà®•à¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "அழைபà¯à®ªà®¾à®³à®°à¯ à®…à®™à¯à®•ீகரிகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®µà®°à®¾ எனà¯à®ªà®¯à¯ˆ நிசà¯à®šà®¯à®¿à®•à¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "auth஠பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "'%s'உடன௠பாலிஸிகிட௠ஒதà¯à®¤à¯à®ªà¯‹à®•ிறதà¯"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "%sகà¯à®•௠சிகà¯à®©à®²à¯ கிடைதà¯à®¤à¯à®µà®¿à®Ÿà¯à®Ÿà®¤à¯."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "வெளியேறà¯à®¤à®²à¯."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "'%s' பயனரை கணà¯à®Ÿà¯à®ªà®¿à®Ÿà®¿à®ªà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "'%s' கà¯à®´à¯à®µà¯ˆ கணà¯à®Ÿà¯à®ªà®¿à®Ÿà®¿à®ªà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "'%s'பயனர௠கணà¯à®Ÿà¯à®ªà®¿à®Ÿà®¿à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¾à®°à¯ (UID %lu) மறà¯à®±à¯à®®à¯ கà¯à®´à¯ '%s' (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID ன௠பயனர௠'%s' மறà¯à®±à¯à®®à¯ '%s' கà¯à®´à¯à®µà¯à®Ÿà®©à¯ ஒதà¯à®¤à¯ போகவிலà¯à®²à¯ˆ."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "à®®à¯à®•பà¯à®ªà¯ அடைவ௠பயனரான'%s' '%s'ஆலà¯, பà¯à®±à®•à¯à®•ணிகà¯à®•பà¯à®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s'஠உரà¯à®µà®¾à®•à¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "கà¯à®´à¯à®ªà¯ படà¯à®Ÿà®¿à®¯à®²à¯ˆ மாறà¯à®± à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GIDகà¯à®•௠மாறà¯à®±à¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UIDகà¯à®•௠மாறà¯à®±à¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "ரூட௠மà¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®•ள௠வெறà¯à®±à®¿à®•ரமாக விடபà¯à®ªà®Ÿà¯à®Ÿà®¤à¯."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "இநà¯à®¤ தளதà¯à®¤à®¿à®²à¯ கணினியின௠திறநà¯à®¤ à®®à¯à®±à¯ˆà®®à¯ˆ தà¯à®£à¯ˆà®ªà¯à®°à®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "கடà¯à®Ÿà®³à¯ˆ வரியை மாறà¯à®±à¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"நாம௠கà¯à®´à¯ '%s'ல௠இரà¯à®¨à¯à®¤ போத௠, உயரà¯à®¨à¯à®¤ à®®à¯à®¤à®©à¯à®®à¯ˆ அடà¯à®Ÿà®µà®£à¯ˆà®ªà¯à®ªà®Ÿà¯à®¤à¯à®¤ அனà¯à®®à®¤à®¿ "
-"அளிகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¿à®°à¯à®¨à¯à®¤à®¤à¯."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "கà¯à®´à¯ '%s'இல௠இரà¯à®•à¯à®•ிறோமà¯, நிகழà¯à®¨à¯‡à®° திடà¯à®Ÿà®®à®¿à®Ÿà¯à®¤à®²à¯ˆ அனà¯à®®à®¤à®¿à®•à¯à®•ிறதà¯."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "நமகà¯à®•ாக PolicyKit உயரà¯à®¨à¯à®¤ à®®à¯à®•à¯à®•ிய à®®à¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®¯à¯ˆ வழஙà¯à®•à¯à®•ிறதà¯."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit உயரà¯à®¨à¯à®¤ à®®à¯à®•à¯à®•ிய à®®à¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®¯à¯ˆ மறà¯à®•à¯à®•ிறதà¯."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit acquire-real-time à®®à¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®•ளை கொடà¯à®•à¯à®•ிறதà¯."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit acquire-real-time à®®à¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®•ளை நிராகரிகà¯à®•ிறதà¯."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-
-#: ../src/daemon/main.c:581
+#: ../src/daemon/main.c:535
msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"உயரà¯à®¨à¯à®¤ சலà¯à®•ைகளின௠அடà¯à®Ÿà®µà®£à¯ˆà®¯à¯ˆ கடà¯à®Ÿà®®à¯ˆà®ªà¯à®ªà®¿à®²à¯ செயலà¯à®ªà®Ÿà¯à®¤à¯à®¤à®ªà¯à®ªà®Ÿà¯à®Ÿà®¤à¯ ஆனால௠பாலிசியால௠"
-"அனà¯à®®à®¤à®¿à®•à¯à®•பà¯à®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "வெறà¯à®±à®¿à®•ரமாக அதிகரிகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯ RLIMIT_RTPRIO"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"CAP_NICE஠மேலே கொடà¯à®•à¯à®•ிறத௠(_N\n"
-")"
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"நிகழà¯à®¨à¯‡à®° திடà¯à®Ÿà®®à®¿à®Ÿà¯à®¤à®²à¯ கடà¯à®Ÿà®®à¯ˆà®ªà¯à®ªà®¿à®²à¯ செயலà¯à®ªà®Ÿà¯à®¤à¯à®¤à®ªà¯à®ªà®Ÿà¯à®Ÿà®¤à¯ ஆனால௠கொளà¯à®•ையால௠அனà¯à®®à®¤à®¿à®•à¯à®•பà¯à®ªà®Ÿà¯à®µà®¤à®¿à®²à¯à®²à¯ˆ"
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "டோமோன௠இயஙà¯à®•விலà¯à®²à¯ˆ"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "PID %uவாக டோமோன௠இயஙà¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "டோமோனà¯à®•à¯à®•௠மà¯à®Ÿà®¿à®µà¯ கடà¯à®Ÿà¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr "இநà¯à®¤ நிரல௠ரூடà¯à®Ÿà®¾à®• இயஙà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ (--system கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®¾à®¤ வரை)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "ரூட௠மà¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®•ள௠தேவைபà¯à®ªà®Ÿà¯à®•ிறதà¯."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start கணினி நிகழà¯à®µà®¿à®²à¯ தà¯à®£à¯ˆà®ªà¯à®°à®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "கணினி à®®à¯à®±à¯ˆà®®à¯ˆà®¯à®¿à®²à¯ இயஙà¯à®•à¯à®•ிறதà¯, ஆனால௠--disallow-exit அமைகà¯à®•பà¯à®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"கணினி à®®à¯à®±à¯ˆà®®à¯ˆà®¯à®¿à®²à¯ இயஙà¯à®•à¯à®•ிறதà¯, ஆனால௠--disallow-module-loading அமைகà¯à®•பà¯à®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "கணினி à®®à¯à®±à¯ˆà®®à¯ˆà®¯à®¿à®²à¯ இயஙà¯à®•à¯à®•ிறதà¯, SHM à®®à¯à®±à¯ˆà®®à¯ˆ செயலà¯à®¨à¯€à®•à¯à®•à¯à®¤à®²à¯ கடà¯à®Ÿà®¾à®¯à®ªà¯à®ªà®Ÿà¯à®¤à¯à®¤à¯à®•ிறதà¯!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr "கணினி à®®à¯à®±à¯ˆà®®à¯ˆà®¯à®¿à®²à¯ இயஙà¯à®•à¯à®•ிறதà¯, வெறà¯à®®à¯ˆ நேரதà¯à®¤à¯ˆ செயலà¯à®¨à¯€à®•à¯à®• கடà¯à®Ÿà®¾à®¯à®ªà¯à®ªà®Ÿà¯à®¤à¯à®¤à¯à®•ிறதà¯!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio஠பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "பைப௠தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "வாசிபà¯à®ªà®¤à®¿à®²à¯() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "டோமோனை தà¯à®µà®•à¯à®•à¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "டோமோனை வெறà¯à®±à®¿à®•ரமாக தà¯à®µà®•à¯à®•கபà¯à®ªà®Ÿà¯à®Ÿà®¤à¯."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "வாசிபà¯à®ªà®¤à®¿à®²à¯() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "இத௠தான௠பளà¯à®¸à¯ ஆடியோ %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "தொகà¯à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿ பà¯à®°à®µà®²à®©à¯: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "தொகà¯à®ªà¯à®ªà¯ CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "பà¯à®°à®µà®²à®©à®¾à®• இயஙà¯à®•à¯à®•ிறத: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "CPUs %uவில௠காணபà¯à®ªà®Ÿà¯à®•ிறத௠."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "பகà¯à®• அளவà¯à®•ள௠%lu பைடà¯à®¸à¯"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Compiled with Valgrind support: yes"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Compiled with Valgrind support: no"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind à®®à¯à®±à¯ˆà®®à¯ˆà®¯à®¿à®²à¯ இயஙà¯à®•à¯à®•ிறதà¯: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "பà¯à®°à®µà®²à®©à®¾à®• இயஙà¯à®•à¯à®•ிறத: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Optimized build: yes"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "சà¯à®°à¯à®•à¯à®•மான உரà¯à®µà®¾à®•à¯à®•à®®à¯: இலà¯à®²à¯ˆ"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr ""
+msgstr "NDEBUG வரையறà¯à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯, அனைதà¯à®¤à¯à®®à¯ உறà¯à®¤à®¿à®¯à®¾à®• செயலà¯à®¨à¯€à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
-msgstr ""
+msgstr "FASTPATH வரையறà¯à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯, விரைவ௠பாதை மடà¯à®Ÿà¯à®®à¯ உறà¯à®¤à®¿à®¯à®¾à®• செயலà¯à®¨à¯€à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr ""
+msgstr "அனைதà¯à®¤à¯ உறà¯à®¤à®¿à®¯à®¾à®• செயலà¯à®ªà®Ÿà¯à®•ிறதà¯."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "கணினி கà¯à®±à®¿à®¯à¯€à®Ÿà¯ˆ பெறà¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "கணினி கà¯à®±à®¿à®¯à¯€à®Ÿà¯ %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "கணினி கà¯à®±à®¿à®¯à¯€à®Ÿà¯ %s."
+msgstr "அமரà¯à®µà¯ கà¯à®±à®¿à®¯à¯€à®Ÿà¯ %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "ஓடà¯à®®à¯à®¨à¯‡à®°à®®à¯ %s அடைவை பயனà¯à®ªà®Ÿà¯à®¤à¯à®¤à¯à®•ிறதà¯."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "%s நிலை அடைவினை பயனà¯à®ªà®Ÿà¯à®¤à¯à®¤à¯à®•ிறதà¯."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "தொகà¯à®¤à®¿ %s அடைவை பயனà¯à®ªà®Ÿà¯à®¤à¯à®¤à¯à®•ிறதà¯."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "கணினியின௠மà¯à®±à¯ˆà®®à¯ˆà®¯à®¿à®²à¯ இயஙà¯à®•à¯à®•ிறதà¯: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "உயரà¯à®¨à¯à®¤ திரைதà¯à®¤à®¿à®±à®©à¯ நேரமà¯à®•ாடà¯à®Ÿà®¿ கிடைகà¯à®•ிளதà¯! Bon appetit!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -519,31 +430,31 @@ msgstr ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "டோமோனை ஆரமà¯à®ªà®¿à®ªà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "டீமான௠தà¯à®µà®•à¯à®•ம௠எநà¯à®¤ தொகà¯à®¤à®¿à®•ளà¯à®®à¯ à®à®±à¯à®±à®ªà¯à®ªà®Ÿà®¾à®®à®²à¯, வேலையை நிராகரிகà¯à®•ிறதà¯."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "டோமோன௠தà¯à®µà®•à¯à®•à¯à®µà®¤à¯ à®®à¯à®Ÿà®¿à®µà®Ÿà¯ˆà®¨à¯à®¤à®¤à¯."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "டோமோன௠பணிநிறà¯à®¤à¯à®¤à®®à¯ à®®à¯à®©à¯ˆà®•ிறதà¯."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "டோமோன௠நீகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà¯à®¤à¯."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -686,15 +597,15 @@ msgstr ""
"\n"
" -n Don't load default script file\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -702,52 +613,52 @@ msgstr ""
"--log-level பதிவ௠நிலை அளவà¯à®°à¯à®µà¯ˆ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறத௠(எண௠0..4 அலà¯à®²à®¤à¯ debug, info, "
"notice, warn, errorஇல௠ஒனà¯à®±à¯)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "தவறான பதிவ௠இலகà¯à®•à¯: 'syslog', 'stderr' அலà¯à®²à®¤à¯ 'auto'஠பயனà¯à®ªà®Ÿà¯à®¤à¯à®¤à®µà¯à®®à¯."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "தவறான மறà¯à®®à®¾à®¤à®¿à®°à®¿ à®®à¯à®±à¯ˆ '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm பூலியன௠அளவà¯à®°à¯ எதிரà¯à®ªà®¾à®°à¯à®•à¯à®•ிறதà¯"
@@ -786,77 +697,87 @@ msgstr "பயனà¯à®ªà®¾à®Ÿà¯: %s\n"
msgid "Load Once: %s\n"
msgstr "à®’à®°à¯à®®à¯à®±à¯ˆ à®à®±à¯à®±à®ªà¯à®ªà®Ÿà¯à®Ÿà®¤à¯: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "DEPRECATION WARNING: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "பாதை: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] தவறான பதிவ௠இலகà¯à®•௠'%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] தவறான பதிவ௠இலகà¯à®•௠'%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] தவறான மறà¯à®®à®¾à®¤à®¿à®°à®¿ à®®à¯à®±à¯ˆ '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] தவறான rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit இநà¯à®¤ தளதà¯à®¤à®¿à®²à¯ தà¯à®£à¯ˆà®ªà¯à®°à®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] தவறான மாதிரி à®®à¯à®±à¯ˆ '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] தவறான மாதிரி விலை '%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] தவறான மாதிரி சேனலà¯à®•ள௠'%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] தவறான சேனல௠படம௠'%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] பகà¯à®ªà¯à®ªà¯ '%s'கà¯à®•௠தவறான எணà¯"
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] தவறான பகà¯à®ªà¯à®ªà¯ அளவ௠'%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] தவறான நலà¯à®² நிலை '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] தவறான மாதிரி விலை '%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "கடà¯à®Ÿà®®à¯ˆà®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿ கோபà¯à®ªà®¿à®©à¯ˆ திறபà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -864,18 +785,14 @@ msgstr ""
"கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà¯à®Ÿ à®®à¯à®©à¯à®©à®¿à®°à¯à®ªà¯à®ªà¯ சேனல௠மேப௠வேறà¯à®ªà®Ÿà¯à®Ÿ சேனலà¯à®•ளின௠எணà¯à®£à®¿à®•à¯à®•ையை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà¯à®Ÿ "
"à®®à¯à®©à¯à®©à®¿à®°à¯à®ªà¯à®ªà¯ சேனலà¯à®•ளின௠எணà¯à®£à®¿à®•à¯à®•ையை விட கொணà¯à®Ÿà¯à®³à¯à®³à®¤à¯"
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### கடà¯à®Ÿà®®à¯ˆà®ªà¯à®ªà¯ கோபà¯à®ªà®¿à®²à®¿à®°à¯à®¨à¯à®¤à¯ வாசிகà¯à®•வà¯à®®à¯: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "ரூட௠மà¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®•ள௠விடà¯à®ªà®Ÿà¯à®•ிறதà¯."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà¯à®Ÿ திறனà¯à®•ள௠CAP_SYS_NICEகà¯à®•௠அமைகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "à®®à¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®•ளை தà¯à®Ÿà¯ˆà®•à¯à®•ிறதà¯."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -885,257 +802,237 @@ msgstr "பளà¯à®¸à¯ ஆடியோ ஒலி கணினி"
msgid "Start the PulseAudio Sound System"
msgstr "பளà¯à®¸à¯ ஆடியோ ஒலி கணினியை தà¯à®µà®•à¯à®•வà¯à®®"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-"அதிக à®®à¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆà®¯à¯à®³à¯à®³ திடà¯à®Ÿà®®à®¿à®Ÿà¯à®¤à®²à¯ (negative Unix nice level) PulseAudio daemonகà¯à®•à¯"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio daemonகà¯à®•ான நிகழà¯à®¨à¯‡à®° திடà¯à®Ÿà®®à®¿à®Ÿà¯à®¤à®²à¯"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"கணினி கொளà¯à®•ை PulseAudio஠அதிக à®®à¯à®©à¯à®©à¯à®°à®¿à®®à¯ˆ திடà¯à®Ÿà®®à®¿à®Ÿà¯à®¤à®²à¯ˆ பெறà¯à®µà®¤à®¿à®²à®¿à®°à¯à®¨à¯à®¤à¯ தடà¯à®•à¯à®•ிறதà¯."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr "கணினி கொளà¯à®•ை PulseAudio ஠நிகழà¯à®¨à¯‡à®° திடà¯à®Ÿà®®à®¿à®Ÿà¯à®¤à®²à¯ˆ எடà¯à®•à¯à®•ிறதà¯."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "மோனோ"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "à®®à¯à®©à¯ நடà¯à®µà®¿à®²à¯"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "à®®à¯à®©à¯ இடதà¯"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "à®®à¯à®©à¯ வலதà¯"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "பின௠நடà¯à®µà®¿à®²à¯"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "பின௠இடதà¯"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "பின௠வலதà¯"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "கà¯à®±à¯ˆà®¨à¯à®¤ அலைவரிசை எமà¯à®®à®¿à®Ÿà¯à®Ÿà®°à¯"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "à®®à¯à®©à¯ இடத௠பகà¯à®•தà¯à®¤à®¿à®©à¯ நடà¯à®µà®¿à®²à¯"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "à®®à¯à®©à¯ வலத௠பகà¯à®•தà¯à®¤à®¿à®©à¯ நடà¯à®µà®¿à®²à¯"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "இடத௠பகà¯à®•à®®à¯"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "வலத௠பகà¯à®•à®®à¯"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Auxiliary 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Auxiliary 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Auxiliary 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Auxiliary 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Auxiliary 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Auxiliary 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Auxiliary 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Auxiliary 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Auxiliary 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Auxiliary 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Auxiliary 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Auxiliary 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Auxiliary 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Auxiliary 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Auxiliary 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Auxiliary 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Auxiliary 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Auxiliary 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Auxiliary 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Auxiliary 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Auxiliary 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Auxiliary 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Auxiliary 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Auxiliary 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Auxiliary 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Auxiliary 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Auxiliary 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Auxiliary 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Auxiliary 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Auxiliary 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Auxiliary 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Auxiliary 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "மேல௠நடà¯à®µà®¿à®²"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "மேலை à®®à¯à®©à¯ நடà¯à®µà®¿à®²à¯"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "மேலே à®®à¯à®©à¯ இடதà¯"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "மேலே à®®à¯à®©à¯ வலதà¯"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "மேலே பின௠நடà¯à®µà®¿à®²à¯"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "மேலே பின௠இடதà¯"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "மேலே பின௠வலதà¯"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(தவறான)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "ஸà¯à®Ÿà®¿à®°à®¿à®¯à¯‹"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Surround 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Surround 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Surround 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Surround 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Surround 7.1"
@@ -1239,27 +1136,35 @@ msgstr "விடà¯à®ªà®Ÿà¯à®Ÿ செயலà¯à®ªà®¾à®Ÿà¯"
msgid "Client forked"
msgstr "கிளையன௠நீகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "உளà¯à®³à¯€à®Ÿà¯/வெளிபà¯à®ªà®¾à®Ÿà¯ பிழை"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "சாதனம௠அலà¯à®²à®¤à¯ மூலம௠பணிமிகà¯à®¤à®¿à®¯à®¿à®²à¯"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1272,197 +1177,191 @@ msgstr "XOpenகாடà¯à®šà®¿() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯"
msgid "Failed to parse cookie data"
msgstr "கà¯à®•à¯à®•ீ தரவை மாறà¯à®±à¯à®µà®¤à®¿à®²à¯ தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "'%s'கடà¯à®Ÿà®®à¯ˆà®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿ கோபà¯à®ªà®¿à®©à¯ˆ திறகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "கà¯à®•à¯à®•ி à®à®±à¯à®±à®ªà¯à®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ. இணைபà¯à®ªà®¿à®²à¯à®²à®¾à®®à®²à¯ à®®à¯à®¯à®±à¯à®šà®¿à®•à¯à®•ிறதà¯."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "தெரியாத தொடரிசà¯à®šà®¿à®¯à®¿à®²à®¿à®°à¯à®¨à¯à®¤à¯ '%s'கà¯à®•௠செயà¯à®¤à®¿à®•ள௠பெறபà¯à®ªà®Ÿà¯à®Ÿà®©"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ˆ இழகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "பினà¯à®©à®£à®¿ ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ இழகà¯à®•பà¯à®ªà®Ÿà¯à®•ிறதà¯."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ வெறà¯à®±à®¿à®•ரமாக உரà¯à®µà®¾à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "சேவையகதà¯à®¤à®¿à®±à¯à®•௠இணைபà¯à®ªà¯ இழகà¯à®•பà¯à®ªà®Ÿà¯à®•ிறதà¯."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Buffer metrics: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_write() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà¯à®Ÿ கà¯à®±à®¿à®ªà¯à®ªà¯ '%s', சேனல௠மேப௠'%s'஠பயனà¯à®ªà®Ÿà¯à®¤à¯à®¤à®¿.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "%s சாதனதà¯à®¤à¯à®Ÿà®©à¯ இணைகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯ (%u, %ssuspended).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ வெறà¯à®±à®¿à®•ரமாக உரà¯à®µà®¾à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ பிழை: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ சாதனம௠இடைநீகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ சாதனம௠தொடரà¯à®•ிறதà¯.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Buffer metrics: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ இயஙà¯à®•à¯à®•ிறதà¯.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà¯à®Ÿ கà¯à®±à®¿à®ªà¯à®ªà¯ '%s', சேனல௠வரைபடதà¯à®¤à¯ˆ '%s'஠பயனà¯à®ªà®Ÿà¯à®¤à¯à®¤à¯à®•ிறதà¯."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ அதிகளவ௠இயஙà¯à®•ியதà¯.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "%s சாதனதà¯à®¤à¯à®Ÿà®©à¯ இணைகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯ (%u, %ssuspended)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ %s தà¯à®µà®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯ \n"
+msgid "Stream error: %s"
+msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ பிழை: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ %s இயகà¯à®•ிகà¯à®•௠நகரà¯à®¨à¯à®¤à®¤à¯ (%u, %ssuspended).%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "இலà¯à®²à¯ˆ"
+msgid "Stream device suspended.%s"
+msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ சாதனம௠இடைநீகà¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯.%s"
-#: ../src/utils/pacat.c:245
-#, fuzzy, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ இயஙà¯à®•à¯à®•ிறதà¯.%s \n"
-
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Connection established.%s \n"
-msgstr "இணைபà¯à®ªà¯ தà¯à®µà®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ சாதனம௠தொடரà¯à®•ிறதà¯.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+msgid "Stream underrun.%s"
+msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ இயஙà¯à®•à¯à®•ிறதà¯.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+msgid "Stream overrun.%s"
+msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ அதிகளவ௠இயஙà¯à®•ியதà¯.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+msgid "Stream started.%s"
+msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ %s தà¯à®µà®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Connection failure: %s\n"
-msgstr "இணைபà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ %s சாதனதà¯à®¤à®¿à®±à¯à®•௠நகரà¯à®¨à¯à®¤à®¤à¯ (%u, %ssuspended).%s"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ˆ டà¯à®°à¯ˆà®©à¯ செயà¯à®¯ à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "இலà¯à®²à¯ˆ"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "டà¯à®°à¯ˆà®©à¯ செயà¯à®¯à®ªà¯à®ªà®Ÿà¯à®Ÿ ஸà¯à®Ÿà¯€à®°à®¿à®®à¯.\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "ஸà¯à®Ÿà¯€à®°à®¿à®®à¯ ஃபபà¯à®ªà®°à¯ பணà¯à®ªà¯à®•ளை மாறà¯à®±à®ªà¯à®ªà®Ÿà¯à®Ÿà®¤à¯.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "டà¯à®°à¯ˆà®©à¯ செயà¯à®¯à¯à®®à¯ இணைபà¯à®ªà¯ சேவையகதà¯à®¤à®¿à®±à¯à®•à¯.\n"
+msgid "Connection established.%s"
+msgstr "இணைபà¯à®ªà¯ தà¯à®µà®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯.%s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF கிடைகà¯à®•ப௠பெறà¯à®±à®¤à¯\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "read() failed: %s\n"
-msgstr "வாசிபà¯à®ªà®¤à®¿à®²à¯ () தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:438
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "write() failed: %s\n"
-msgstr "எழà¯à®¤à¯à®µà®¤à®¿à®²à¯ () தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s\n"
+msgid "Connection failure: %s"
+msgstr "இணைபà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿: %s"
-#: ../src/utils/pacat.c:459
-#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "சிகà¯à®©à®²à¯ கிடைதà¯à®¤à®¤à¯, வெளியேறà¯à®•ிறதà¯.\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF கிடைகà¯à®•ப௠பெறà¯à®±à®¤à¯"
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "லடனà¯à®šà®¿à®¯à¯ˆ பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "write() failed: %s"
+msgstr "எழà¯à®¤à¯à®µà®¤à®¿à®²à¯ () தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯: %s"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "சிகà¯à®©à®²à¯ கிடைதà¯à®¤à®¤à¯, வெளியேறà¯à®•ிறதà¯."
+
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "Time: %0.3f sec; Latency: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "லடனà¯à®šà®¿à®¯à¯ˆ பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() தோலà¯à®µà®¿: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "Time: %0.3f sec; Latency: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() தோலà¯à®µà®¿: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1488,8 +1387,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1512,6 +1413,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
@@ -1537,8 +1447,10 @@ msgstr ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1561,8 +1473,13 @@ msgstr ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1573,129 +1490,171 @@ msgstr ""
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "தவறான சேனல௠வரைபடம௠'%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "தவறான கிளையன௠பெயர௠'%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "தவறான லேடனà¯à®šà®¿ கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯ '%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "தவறான ஸà¯à®Ÿà¯€à®°à¯€à®®à¯ பெயர௠'%s'."
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "தவறான செயல௠நேர கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯ '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "தவறான சேனல௠வரைபடம௠'%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "தவறான மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯\n"
+msgid "Invalid latency specification '%s'"
+msgstr "தவறான லேடனà¯à®šà®¿ கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯ '%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "சேனல௠மேப௠மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯à®Ÿà¯à®Ÿà®©à¯ பொரà¯à®¨à¯à®¤à®µà®¿à®²à¯à®²à¯ˆ\n"
+msgid "Invalid process time specification '%s'"
+msgstr "தவறான செயல௠நேர கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯ '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "ஒர௠%s ஸà¯à®Ÿà¯€à®°à®®à¯ˆ மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯ '%s'உடன௠திறகà¯à®•ிறதà¯.\n"
+msgid "Invalid property '%s'"
+msgstr "தவறான தனà¯à®®à¯ˆ '%s'."
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "ஒலிபà¯à®ªà®¤à®¿à®µà¯"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "தெரியாத கோபà¯à®ªà¯ வடிவம௠%s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "பிணà¯à®£à®©à®¿"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "தவறான மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "நிறைய விவாதஙà¯à®•ளà¯.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "நிறைய விவாதஙà¯à®•ளà¯."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() தோலà¯à®µà®¿.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "மாதிரி தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ.: %s"
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_பà¯à®¤à®¿à®¯() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯.(_n) \n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "ஒலி கோபà¯à®ªà®¿à®©à¯ˆ திறகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() தோலà¯à®µà®¿.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"எசà¯à®šà®°à®¿à®•à¯à®•ை: கோபà¯à®ªà®¿à®²à®¿à®°à¯à®¨à¯à®¤à¯ கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯à®Ÿà¯à®Ÿà®©à¯ கà¯à®±à®¿à®•à¯à®•ிடà¯à®Ÿ மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯ மேலெழà¯à®¤à®ªà¯à®ªà®Ÿà®²à®¾à®®à¯."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() தோலà¯à®µà®¿: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "கோபà¯à®ªà®¿à®²à®¿à®°à¯à®¨à¯à®¤à¯ மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯à®Ÿà¯ˆ வரையறà¯à®•à¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "எசà¯à®šà®°à®¿à®•à¯à®•ை: கோபà¯à®ªà®¿à®²à®¿à®°à¯à®¨à¯à®¤à¯ சேனல௠வரைபடதà¯à®¤à¯ˆ வரையறà¯à®•à¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "சேனல௠வரைபடம௠மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯à®Ÿà¯à®Ÿà®©à¯ பொரà¯à®¨à¯à®¤à®µà®¿à®²à¯à®²à¯ˆ"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "எசà¯à®šà®°à®¿à®•à¯à®•ை: கோபà¯à®ªà¯à®•à¯à®•௠சேனல௠வரைபடதà¯à®¤à¯ˆ எழà¯à®¤ à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() தோலà¯à®µà®¿.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"ஒர௠%s ஸà¯à®Ÿà¯€à®°à®®à¯ மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯à®Ÿà¯ˆ '%s' மறà¯à®±à¯à®®à¯ சேனல௠வரைபடà¯à®Ÿà®®à¯ '%s' உடன௠திறகà¯à®•ிறதà¯."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "ஒலிபà¯à®ªà®¤à®¿à®µà¯"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "பிணà¯à®£à®©à®¿"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() தோலà¯à®µà®¿."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() தோலà¯à®µà®¿."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() தோலà¯à®µà®¿.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() தோலà¯à®µà®¿: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() தோலà¯à®µà®¿à®¯à¯à®±à¯à®±à®¤à¯."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() தோலà¯à®µà®¿."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "நீகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "தொடர à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "எசà¯à®šà®°à®¿à®•à¯à®•ை: ஒலி சேவையம௠உளà¯à®³à®®à¯ˆà®µà®¾à®• இலà¯à®²à¯ˆ, இடைநிறà¯à®¤à¯à®¤à®ªà¯à®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "இணைபà¯à®ªà®¤à®¿à®²à¯ தோலà¯à®µà®¿: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT பெறபà¯à®ªà®Ÿà¯à®Ÿà®¤à¯, வெளியேறà¯à®•ிறதà¯.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "எசà¯à®šà®°à®¿à®•à¯à®•ை: சேய௠செயல௠சிகà¯à®©à®²à¯ %uஆல௠மà¯à®Ÿà®¿à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1713,7 +1672,7 @@ msgstr ""
" -s, --சேவையகமà¯=SERVER பெயரிடபà¯à®ªà®Ÿà¯à®Ÿ சேவையகம௠இணைகà¯à®•பà¯à®ªà®Ÿ வேணà¯à®Ÿà¯à®®à¯\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1724,36 +1683,62 @@ msgstr ""
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() தோலà¯à®µà®¿.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() தோலà¯à®µà®¿.\n"
+
+#: ../src/utils/pasuspender.c:296
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "பà¯à®³à¯à®³à®¿à®µà®¿à®µà®°à®¤à¯à®¤à¯ˆ பெற இயலாதà¯: %s\n"
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() தோலà¯à®µà®¿.\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "பà¯à®³à¯à®³à®¿à®µà®¿à®µà®°à®¤à¯à®¤à¯ˆ பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "தறà¯à®ªà¯‹à®¤à¯ பயனிலà¯à®³à¯à®³à®¤à¯: %u தொகà¯à®¤à®¿à®•ள௠%s பைடà¯à®•ளை மொதà¯à®¤à®®à®¾à®• கொணà¯à®Ÿà¯à®³à¯à®³à®¤à¯.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"வாழà¯à®•à¯à®•ை à®®à¯à®´à¯à®µà®¤à¯à®®à¯ ஒதà¯à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯: %u தொகà¯à®¤à®¿à®•ள௠%s பைடà¯à®•ளை மொதà¯à®¤à®®à®¾à®• கொணà¯à®Ÿà¯à®³à¯à®³à®¤à¯.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "மாதிரி இடையக அளவà¯: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "சேவையகதà¯à®¤à®¿à®©à¯ தகவலை பெற இயலவிலà¯à®²à¯ˆ: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "சேவையகதà¯à®¤à®¿à®©à¯ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1761,7 +1746,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"பயனர௠பெயரà¯: %s\n"
"பà¯à®°à®µà®²à®©à¯ பெயரà¯: %s\n"
@@ -1773,12 +1758,12 @@ msgstr ""
"à®®à¯à®©à¯à®©à®¿à®°à¯à®ªà¯à®ªà¯ மூலஙà¯à®•ளà¯: %s\n"
"கூகà¯à®•ி: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "சà¯à®°à¯à®•à¯à®•மான தகவலை பெற௠மà¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "சà¯à®°à¯à®•à¯à®•மான தகவலை பெற௠மà¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1817,12 +1802,22 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tPorts:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tசெயலà¯à®ªà®¾à®Ÿà¯à®Ÿà®¿à®²à¯à®³à¯à®³ விவரகà¯à®•à¯à®±à®¿à®ªà¯à®ªà¯à®•ளà¯: %s\n"
+
+#: ../src/utils/pactl.c:310
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "மூலதà¯à®¤à®¿à®©à¯ தகவலை பெற இயலவிலà¯à®²à¯ˆ: %s\n"
+msgid "Failed to get source information: %s"
+msgstr "மூலதà¯à®¤à®¿à®©à¯ தகவலை பெற இயலவிலà¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1861,20 +1856,20 @@ msgstr ""
"\tபணà¯à®ªà¯à®•ளà¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "தொகà¯à®¤à®¿ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "தொகà¯à®¤à®¿ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1891,12 +1886,12 @@ msgstr ""
"\tபணà¯à®ªà¯à®•ளà¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "கிளையனà¯à®Ÿà¯ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "கிளையனà¯à®Ÿà¯ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1911,12 +1906,12 @@ msgstr ""
"\tபணà¯à®ªà¯à®•ளà¯:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "அடà¯à®Ÿà¯ˆ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "அடà¯à®Ÿà¯ˆ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1933,22 +1928,22 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tவிவரகà¯à®•à¯à®±à®¿à®ªà¯à®ªà¯à®•ளà¯:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tசெயலà¯à®ªà®¾à®Ÿà¯à®Ÿà®¿à®²à¯à®³à¯à®³ விவரகà¯à®•à¯à®±à®¿à®ªà¯à®ªà¯à®•ளà¯: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "சிஙà¯à®•௠தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "சிஙà¯à®•௠தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1985,12 +1980,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "மூல வெளிபà¯à®ªà®¾à®Ÿà¯ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "மூல வெளிபà¯à®ªà®¾à®Ÿà¯ தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2019,12 +2014,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "மாதிரி தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ.: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "மாதிரி தகவலை பெற à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ.: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2055,23 +2050,80 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "தோலà¯à®µà®¿: %s\n"
+msgid "Failure: %s"
+msgstr "தோலà¯à®µà®¿: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "மாதிரியை மேமà¯à®ªà®Ÿà¯à®¤à¯à®¤ à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "மாதிரியை மேமà¯à®ªà®Ÿà¯à®¤à¯à®¤ à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "à®®à¯à®©à¯à®©à®¾à®• கோபà¯à®ªà¯ à®®à¯à®Ÿà®¿à®¤à¯à®¤à®²à¯\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "à®®à¯à®©à¯à®©à®¾à®• கோபà¯à®ªà¯ à®®à¯à®Ÿà®¿à®¤à¯à®¤à®²à¯"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "தவறான பà¯à®°à®µà®²à®©à¯"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT பெறபà¯à®ªà®Ÿà¯à®Ÿà®¤à¯, வெளியேறà¯à®•ிறதà¯."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2079,13 +2131,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2101,13 +2162,21 @@ msgstr ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2117,7 +2186,7 @@ msgstr ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2128,78 +2197,108 @@ msgstr ""
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "à®à®±à¯à®±à¯à®µà®¤à®±à¯à®•௠ஒர௠மாதிரி கோபà¯à®ªà®¿à®©à¯ˆ கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®µà¯à®®à¯\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "à®à®±à¯à®±à¯à®µà®¤à®±à¯à®•௠ஒர௠மாதிரி கோபà¯à®ªà®¿à®©à¯ˆ கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®µà¯à®®à¯"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "ஒலி கோபà¯à®ªà®¿à®©à¯ˆ திறகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "ஒலி கோபà¯à®ªà®¿à®©à¯ˆ திறகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "இயகà¯à®•ிவதறà¯à®•௠நீஙà¯à®•ள௠ஒர௠மாதிரி பெயர௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "எசà¯à®šà®°à®¿à®•à¯à®•ை: கோபà¯à®ªà®¿à®²à®¿à®°à¯à®¨à¯à®¤à¯ மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯à®Ÿà¯ˆ வரையறà¯à®•à¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "நீகà¯à®•à¯à®µà®¤à®±à¯à®•௠நீஙà¯à®•ள௠ஒர௠மாதிரி பெயர௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "இயகà¯à®•ிவதறà¯à®•௠நீஙà¯à®•ள௠ஒர௠மாதிரி பெயர௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "நீஙà¯à®•ள௠ஒர௠சிஙà¯à®•௠உளà¯à®³à¯€à®Ÿà¯ சà¯à®Ÿà¯à®Ÿà®¿ மறà¯à®±à¯à®®à¯ ஒர௠சிஙà¯à®•ை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "நீகà¯à®•à¯à®µà®¤à®±à¯à®•௠நீஙà¯à®•ள௠ஒர௠மாதிரி பெயர௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "நீஙà¯à®•ள௠ஒர௠மூல வெளிபà¯à®ªà®¾à®Ÿà¯ சà¯à®Ÿà¯à®Ÿà®¿ மறà¯à®±à¯à®®à¯ ஒர௠மூலதà¯à®¤à¯ˆ கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "நீஙà¯à®•ள௠ஒர௠சிஙà¯à®•௠உளà¯à®³à¯€à®Ÿà¯ சà¯à®Ÿà¯à®Ÿà®¿ மறà¯à®±à¯à®®à¯ ஒர௠சிஙà¯à®•ை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "தொகà¯à®¤à®¿ பெயர௠மறà¯à®±à¯à®®à¯ விவாதஙà¯à®•ளை நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯. \n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "நீஙà¯à®•ள௠ஒர௠மூல வெளிபà¯à®ªà®¾à®Ÿà¯ சà¯à®Ÿà¯à®Ÿà®¿ மறà¯à®±à¯à®®à¯ ஒர௠மூலதà¯à®¤à¯ˆ கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "தொகà¯à®¤à®¿ அடà¯à®Ÿà®µà®£à¯ˆà®¯à¯ˆ நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "தொகà¯à®¤à®¿ பெயர௠மறà¯à®±à¯à®®à¯ விவாதஙà¯à®•ளை நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "தொகà¯à®¤à®¿ அடà¯à®Ÿà®µà®£à¯ˆà®¯à¯ˆ நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"ஒர௠சிஙà¯à®•ிறà¯à®•௠மேல௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®•௠கூடாதà¯. பூலியன௠மதிபà¯à®ªà¯ˆ நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯.\n"
+"ஒர௠சிஙà¯à®•ிறà¯à®•௠மேல௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®•௠கூடாதà¯. பூலியன௠மதிபà¯à®ªà¯ˆ நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"ஒர௠மூலதà¯à®¤à®¿à®±à¯à®•௠மேல௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®•௠கூடாதà¯. பூலியன௠மதிபà¯à®ªà¯ˆ நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ "
-"வேணà¯à®Ÿà¯à®®à¯.\n"
+"ஒர௠மூலதà¯à®¤à®¿à®±à¯à®•௠மேல௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®•௠கூடாதà¯. பூலியன௠மதிபà¯à®ªà¯ˆ நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr ""
-"ஒர௠அடà¯à®Ÿà¯ˆ பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠விவரசà¯à®šà¯€à®Ÿà¯à®Ÿà¯ பெயர௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯ \n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "ஒர௠அடà¯à®Ÿà¯ˆ பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠விவரசà¯à®šà¯€à®Ÿà¯à®Ÿà¯ பெயர௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "சரியான கடà¯à®Ÿà®³à¯ˆ கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ \n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "நீஙà¯à®•ள௠ஒர௠சிஙà¯à®•௠பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠தà¯à®±à¯ˆà®ªà¯ பெயரை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() தோலà¯à®µà®¿: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "ஒர௠மூலப௠பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠தà¯à®±à¯ˆà®ªà¯ பெயர௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "நீஙà¯à®•ள௠ஒர௠சிஙà¯à®•௠பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠தà¯à®±à¯ˆà®ªà¯ பெயரை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "தவறான தொகà¯à®¤à®¿ கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "ஒர௠மூலப௠பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠தà¯à®±à¯ˆà®ªà¯ பெயர௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "நீஙà¯à®•ள௠ஒர௠சிஙà¯à®•௠உளà¯à®³à¯€à®Ÿà¯ சà¯à®Ÿà¯à®Ÿà®¿ மறà¯à®±à¯à®®à¯ ஒர௠சிஙà¯à®•ை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "தவறான சà¯à®°à¯à®•à¯à®• உளà¯à®³à¯€à®Ÿà¯ அடà¯à®Ÿà®µà®£à¯ˆ"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "நீஙà¯à®•ள௠ஒர௠சிஙà¯à®•௠பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠தà¯à®±à¯ˆà®ªà¯ பெயரை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "ஒர௠மூலப௠பெயரà¯/ à®®à¯à®©à¯à®ªà®•à¯à®•ம௠மறà¯à®±à¯à®®à¯ ஒர௠தà¯à®±à¯ˆà®ªà¯ பெயர௠நீஙà¯à®•ள௠கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "நீஙà¯à®•ள௠ஒர௠சிஙà¯à®•௠உளà¯à®³à¯€à®Ÿà¯ சà¯à®Ÿà¯à®Ÿà®¿ மறà¯à®±à¯à®®à¯ ஒர௠சிஙà¯à®•ை கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿ வேணà¯à®Ÿà¯à®®à¯"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "தவறான சà¯à®°à¯à®•à¯à®• உளà¯à®³à¯€à®Ÿà¯ அடà¯à®Ÿà®µà®£à¯ˆ கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "சரியான கடà¯à®Ÿà®³à¯ˆ கà¯à®±à®¿à®ªà¯à®ªà®¿à®Ÿà®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ"
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2280,129 +2379,48 @@ msgstr "கà¯à®•à¯à®•ீ தரவை à®à®±à¯à®± à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯
msgid "Not yet implemented.\n"
msgstr "இனà¯à®©à¯à®®à¯ செயலà¯à®ªà®Ÿà¯à®¤à¯à®¤à®ªà®Ÿà®µà®¿à®²à¯à®²à¯ˆ.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "PulseAudio டீமான௠இயஙà¯à®•விலà¯à®²à¯ˆ, அலà¯à®²à®¤à¯ அமரà¯à®µà¯ டீமானாக இயஙà¯à®•விலà¯à®²à¯ˆ."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio daemon஠நிறà¯à®¤à¯à®¤ à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "டோமோன௠பதிலளிகà¯à®• மறà¯à®•à¯à®•ிறதà¯."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ வெறà¯à®±à®¿à®•ரமாக உரà¯à®µà®¾à®•à¯à®•பà¯à®ªà®Ÿà¯à®Ÿà®¤à¯\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "ஸà¯à®Ÿà®¿à®°à¯€à®®à¯ பிழை: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "இணைபà¯à®ªà®¿à®©à¯ˆ à®à®±à¯à®ªà®Ÿà¯à®¤à¯à®¤à¯à®•ிறதà¯.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "தவறான சேனல௠வரைபடம௠\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "கோபà¯à®ªà¯ '%s'஠திறகà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "சேனல௠வரைபடம௠கோபà¯à®ªà¯à®Ÿà®©à¯ ஒதà¯à®¤à¯à®ªà¯ பொகவிலà¯à®²à¯ˆ.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "மாதிரி கà¯à®±à®¿à®ªà¯à®ªà¯€à®Ÿà¯ '%s'஠பயனà¯à®ªà®Ÿà¯à®¤à¯à®¤à®¿\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "autospawn பூடà¯à®Ÿà¯ˆ அணà¯à®• à®®à¯à®Ÿà®¿à®¯à®µà®¿à®²à¯à®²à¯ˆ."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2412,8 +2430,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA சாதனதà¯à®¤à®¿à®±à¯à®•௠பà¯à®¤à®¿à®¯ தரவை எழà¯à®¤à¯à®µà®¤à®±à¯à®•௠எஙà¯à®•ளை எழà¯à®ªà¯à®ªà®¿ இரà¯à®•à¯à®•வாமà¯, ஆனால௠இஙà¯à®•ே "
+"சரியாக எழà¯à®¤à¯à®µà®¤à®±à¯à®•௠எதà¯à®µà¯à®®à¯ இலà¯à®²à¯ˆ!\n"
+"இநà¯à®¤ ஒர௠பிழையானத௠ALSA இயகà¯à®•ி '%s'. இநà¯à®¤ வெளிபà¯à®ªà®¾à®Ÿà¯à®Ÿà¯ˆ ALSA வலà¯à®²à¯à®¨à®°à¯à®•ளà¯à®•à¯à®•௠"
+"அறிகà¯à®•ையிடவà¯à®®à¯.\n"
+"POLLOUT அமைவà¯à®Ÿà®©à¯ நாஙà¯à®•ள௠எழà¯à®¨à¯à®¤à®¿à®°à¯à®¨à¯à®¤à¯‹à®®à¯-- எபà¯à®ªà®Ÿà®¿à®¯à®¿à®°à¯à®¨à¯à®¤à¯à®®à¯ அடà¯à®¤à¯à®¤à®Ÿà¯à®¤à¯à®¤à¯ snd_pcm_avail"
+"() r0 அலà¯à®²à®¤à¯ வேறொர௠மதிபà¯à®ªà¯ < min_avail திரà¯à®®à¯à®ªà®¿à®¯à®¤à¯."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2423,36 +2447,266 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA சாதனதà¯à®¤à®¿à®±à¯à®•௠பà¯à®¤à®¿à®¯ தரவை எழà¯à®¤à¯à®µà®¤à®±à¯à®•௠எஙà¯à®•ளை எழà¯à®ªà¯à®ªà®¿ இரà¯à®•à¯à®•வாமà¯, ஆனால௠இஙà¯à®•ே "
+"சரியாக எழà¯à®¤à¯à®µà®¤à®±à¯à®•௠எதà¯à®µà¯à®®à¯ இலà¯à®²à¯ˆ!\n"
+"இநà¯à®¤ ஒர௠பிழையானத௠ALSA இயகà¯à®•ி '%s'. இநà¯à®¤ வெளிபà¯à®ªà®¾à®Ÿà¯à®Ÿà¯ˆ ALSA வலà¯à®²à¯à®¨à®°à¯à®•ளà¯à®•à¯à®•௠"
+"அறிகà¯à®•ையிடவà¯à®®à¯.\n"
+"POLLOUT அமைவà¯à®Ÿà®©à¯ நாஙà¯à®•ள௠எழà¯à®¨à¯à®¤à®¿à®°à¯à®¨à¯à®¤à¯‹à®®à¯-- எபà¯à®ªà®Ÿà®¿à®¯à®¿à®°à¯à®¨à¯à®¤à¯à®®à¯ அடà¯à®¤à¯à®¤à®Ÿà¯à®¤à¯à®¤à¯ snd_pcm_avail"
+"() 0 அலà¯à®²à®¤à¯ வேறொர௠மதிபà¯à®ªà¯ < min_avail திரà¯à®®à¯à®ªà®¿à®¯à®¤à¯."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "ஆஃபà¯"
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr ""
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "High Fidelity Playback (A2DP)"
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr ""
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "High Fidelity Capture (A2DP)"
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr ""
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Telephony Duplex (HSP/HFP)"
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
-msgid "Off"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
-msgid "High Fidelity Playback (A2DP)"
-msgstr ""
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "PulseAudio ஒலி சேவையகமà¯"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
-msgid "Telephony Duplex (HSP/HFP)"
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "வெளிபà¯à®ªà®¾à®Ÿà¯ சாதனஙà¯à®•ளà¯"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "உளà¯à®³à¯€à®Ÿà¯ சாதனஙà¯à®•ளà¯"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@இல௠ஆடியோ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "உளà¯à®³à¯€à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "டாகà¯à®•ிங௠ஸà¯à®Ÿà¯‡à®·à®©à¯ உளà¯à®³à¯€à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "டாகà¯à®•ிங௠ஸà¯à®Ÿà¯‡à®·à®©à¯ மைகà¯à®°à¯‹à®ƒà®ªà¯‹à®©à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "லைனà¯à®‡à®©à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "மைகà¯à®°à¯‹à®ƒà®ªà¯‹à®©à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "வெளியாரà¯à®¨à¯à®¤ மைகà¯à®°à¯‹à®ƒà®ªà¯‹à®©à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "உடà¯à®ªà¯à®± மைகà¯à®°à¯‹à®ƒà®ªà¯‹à®©à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "ரேடியோ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "வீடியோ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "தானியகà¯à®• லாப கடà¯à®Ÿà¯à®ªà¯à®ªà®¾à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "தானியகà¯à®• லாப கடà¯à®Ÿà¯à®ªà¯à®ªà®¾à®Ÿà¯ எதà¯à®µà¯à®®à®¿à®²à¯à®²à¯ˆ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "பூஸà¯à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "பூஸà¯à®Ÿà¯ இலà¯à®²à¯ˆ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "ஆமà¯à®ªà®¿à®³à®¿à®ƒà®ªà¯ˆà®¯à®°à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "ஆமà¯à®ªà¯à®³à®¿à®ƒà®ªà¯ˆà®¯à®°à¯ இலà¯à®²à¯ˆ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "பூஸà¯à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "பூஸà¯à®Ÿà¯ இலà¯à®²à¯ˆ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/alsa/alsa-mixer.c:1719
#, fuzzy
-msgid "PulseAudio Sound Server"
-msgstr "பளà¯à®¸à¯ ஆடியோ ஒலி கணினி"
+msgid "Headphones"
+msgstr "அனலாக௠ஹெடà¯à®ƒà®ªà¯‹à®©à¯à®•ளà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "அனலாக௠உளà¯à®³à®¿à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "அனலாக௠மைகà¯à®°à¯‹à®ƒà®ªà¯‹à®©à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "அனலாக௠லைனà¯à®‡à®©à¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "அனலாக௠ரேடியோ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "அனலாக௠வீடியோ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "அனலாக௠வெளிபà¯à®ªà®¾à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "அனலாக௠ஹெடà¯à®ƒà®ªà¯‹à®©à¯à®•ளà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "அனலாக௠வெளிபà¯à®ªà®¾à®Ÿà¯ (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "அனலாக௠மோனோ வெளிபà¯à®ªà®¾à®Ÿà¯"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "அனலாக௠ஸà¯à®Ÿà®¿à®°à®¿à®¯à¯‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "அனலாக௠மோனோ"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "அனலாக௠ஸà¯à®Ÿà®¿à®°à®¿à®¯à¯‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Analog Surround 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Analog Surround 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Analog Surround 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Analog Surround 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Analog Surround 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Analog Surround 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Analog Surround 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Analog Surround 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Analog Surround 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Analog Surround 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Analog Surround 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Digital Stereo (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Digital Surround 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Digital Surround 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Digital Surround 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Digital Stereo (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Analog Mono Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Analog Stereo Duplex"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Digital Stereo Duplex (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "கà¯à®±à¯ˆà®¨à¯à®¤ அலைவரிசை எமà¯à®®à®¿à®Ÿà¯à®Ÿà®°à¯"
diff --git a/po/te.po b/po/te.po
index b91c6b83..a861ddaf 100644
--- a/po/te.po
+++ b/po/te.po
@@ -7,8 +7,8 @@ msgid ""
msgstr ""
"Project-Id-Version: pulseaudio.master-tx.te\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-08 18:21+0530\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-11-12 13:10+0530\n"
"Last-Translator: Krishna Babu K <kkrothap@redhat.com>\n"
"Language-Team: Telugu <en@li.org>\n"
"MIME-Version: 1.0\n"
@@ -20,52 +20,17 @@ msgstr ""
"\n"
"\n"
"\n"
+"\n"
+"\n"
+"\n"
+"\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "ఎనలాగౠమోనో"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "ఎనలాగౠసà±à°Ÿà±€à°°à°¿à°¯à±‹"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "డిజటలౠసà±à°Ÿà±€à°°à°¿à°¯à±‹ (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "డిజిటలౠసà±à°Ÿà±€à°°à°¿à°¯à±‹ (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "ఎనలాగౠసరౌండౠ4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "డిజిటలౠసరౌండౠ4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "ఎనలాగౠసరౌండౠ4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "ఎనలాగౠసరౌండౠ5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "ఎనలాగౠసరౌండౠ5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "డిజిటలౠసరౌండౠ5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "ఎనలాగౠసరౌండౠ7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -77,7 +42,7 @@ msgstr ""
"సాదారణంగా యిది ALSA à°¡à±à°°à±ˆà°µà°°à± '%s' నందలి బగౠకావచà±à°šà±à°¨à±. దయచేసి దీనిని ALSA అభివృదà±à°¦à°¿ కారà±à°²à°•à± "
"నివేదించà±à°®à±."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -89,7 +54,7 @@ msgstr ""
"సాదారణంగా యిది ALSA à°¡à±à°°à±ˆà°µà°°à± '%s' నందౠబగౠకావచà±à°šà±à°¨à± . దయచేసి దీనిని ALSA అభివృదà±à°¦à°¿à°•ారà±à°²à°• "
"నివేదించà±à°®à±."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -100,11 +65,44 @@ msgstr ""
"snd_pcm_mmap_begin() à°…à°¨à±à°¨à°¦à°¿ పెదà±à°¦ విలà±à°µà°¨à± యిచà±à°šà°¿à°¨à°¦à°¿: %lu bytes (%lu ms).\n"
"సాదారణంగా యిది ALSA à°¡à±à°°à±ˆà°µà°°à± '%s'నందలి బగౠకావచà±à°šà±à°¨à±. దయచేసి దీనిని ALSA అభివృదà±à°¦à°¿à°•ారà±à°²à°¨à± నివేదించండి."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "ఒకవేళ అది null అయినా కూడా యెలà±à°²à°ªà±à°ªà±à°¡à±‚ కనీసం వొక సింకౠలోడైనటà±à°²à± à°µà±à°‚à°šà±à°¤à±à°‚ది"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "à°¡à°®à±à°®à±€ à°…à°µà±à°Ÿà±à°ªà±à°Ÿà±"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "వరà±à°šà±à°¯à±à°µà°²à± LADSPA సింకà±"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<సింకౠనామమà±> sink_properties=<సింకౠలకà±à°·à°£à°®à±à°²à±> master=<à°«à°¿à°²à±à°Ÿà°°à±â€Œà°•ౠసింకౠ"
+"నామమà±> format=<మాదిరి ఫారà±à°®à°¾à°Ÿà±> rate=<మాదిరి రేటà±> channels=<చానలà±à°¸à± సంఖà±à°¯> "
+"channel_map=<చానలౠమాపà±> plugin=<ladspa à°ªà±à°²à°—ినౠనామమà±> label=<ladspa à°ªà±à°²à°—ినౠలేబà±à°²à±> "
+"control=<ఇనà±à°ªà±à°Ÿà± నియంతà±à°°à°£ విలà±à°µà°²à°¯à±Šà°•à±à°• జాబితా>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "NULL సింకౠకà±à°²à°¾à°•à±â€Œà°šà±‡à°¯à°¬à°¡à°¿à°‚ది"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null à°…à°µà±à°Ÿà±à°ªà±à°Ÿà±"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "అంతరà±à°—à°¤ ఆడియో"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "మోడెమà±"
@@ -120,402 +118,319 @@ msgstr "కొతà±à°¤ dl లోడరౠకేటాయించà±à°Ÿà°²à±‹
msgid "Failed to add bind-now-loader."
msgstr "bind-now-loader జతచేయà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "సిసà±à°Ÿà°®à± బసà±â€Œà°¨à°•à± à°…à°¨à±à°¸à°‚ధానమౠకాలేకపోయింది: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "PID à°¨à±à°‚à°¡à°¿ కాలరà±â€Œà°¨à± పొందలేక పోయింది: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "కాలరౠఆబà±à°œà°•à±à°Ÿà±à°¨à°‚దౠUIDనౠఅమరà±à°šà°²à±‡à°• పోయింది."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "CK సెషనౠపొందà±à°Ÿà°•ౠవిఫలమైంది."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "సెషనౠఆబà±à°œà°•à±à°Ÿà±à°¨à°‚దౠUIDనౠఅమరà±à°š లేకపోయింది."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "PolKitAction à°šà°¿à°°à±à°¨à°¾à°®à°¾à°¨à± కేటాయించలేక పోయింది."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "action_id అమరà±à°šà°²à±‡à°• పోయింది"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "PolKitContext కేటాయించలేక పోయింది."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "PolKitContext సిదà±à°¦à°®à± చేయలేక పోయింది: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "కాలరౠఅధికారమౠకలదో లేదో నిరà±à°£à°¯à°¿à°‚చలేక పోయింది: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "దృవీకరణ పొందలేక పోయింది: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit à°¸à±à°ªà°‚దిచినది దీనితో '%s'"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "సంకేతమౠ%s పొందినది."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "నిషà±à°•à±à°°à°®à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "వినియోగదారి '%s'నౠకనà±à°—ొనà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "సమూహం '%s' à°•à°¨à±à°—ొనà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "వినియోగదారి '%s' (UID %lu) మరియౠసమూహమౠ'%s' (GID %lu) కనబడినవి."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "వినియోగదారి '%s' మరియౠసమూహమౠ'%s' యొకà±à°• GID సరితూగలేదà±."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "వినియోగదారి '%s' యొకà±à°• నివాస డైరెకà±à°Ÿà°°à±€ '%s' కాదà±, వదిలివేయà±à°šà±à°¨à±à°¨à°¦à°¿."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "'%s' సృషà±à°Ÿà°¿à°‚à°šà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "సమూహ జాబితా మారà±à°šà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "GID మారà±à°šà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "UID మారà±à°šà°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "root à°…à°¨à±à°®à°¤à±à°²à± విజయవంతంగా తిసివేయబడినాయి."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "à°ˆ à°ªà±à°²à°¾à°Ÿà±â€Œà°«à°¾à°‚ నందౠసిసà±à°Ÿà°®à± తరహా రీతి మదà±à°¦à°¤à±€à°¯à°¬à°¡à°¦à±."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) విఫలమైంది: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "ఆదేశ వరà±à°¸à°¨à± పారà±à°¶à± చేయà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "మనమౠసమూహమౠ'%s' నందౠవà±à°¨à±à°¨à°¾à°®à±, అదిక-à°ªà±à°°à°¾à°®à±à°–à±à°¯à°¤à°¾ పణాళికనౠఅనà±à°®à°¤à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "మనమౠసమూహమౠ'%s' నందౠవà±à°¨à±à°¨à°¾à°®à±, వాసà±à°¤à°µ-సమయ à°ªà±à°°à°£à°¾à°³à°¿à°•నౠఅనà±à°®à°¤à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit మనకౠacquire-high-priority à°…à°¨à±à°®à°¤à°¿à°¨à°¿ యిచà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit à°…à°¨à±à°¨à°¦à°¿ acquire-high-priority à°…à°¨à±à°®à°¤à°¿à°¨à°¿ తిరసà±à°•à°°à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit మనకౠacquire-real-time à°…à°¨à±à°®à°¤à°¿à°¨à°¿ యిచà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit acquire-real-time à°…à°¨à±à°®à°¤à°¿à°¨à°¿ తిరసà±à°•à°°à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/main.c:556
-#, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"SUID root కాలౠచేసింది మరియౠవాసà±à°¤à°µ-సమయ మరియà±/లేదా అదిక-à°ªà±à°°à°¾à°®à±à°–à±à°¯à°¤ à°ªà±à°°à°£à°¾à°³à°¿à°• à°…à°­à±à°¯à°°à±à°§à°¿à°‚బడింది "
-"ఆకృతీకరణనందà±. à°à°®à±ˆà°¨à°ªà±à°ªà±à°Ÿà°¿à°•à°¿, మనకౠఅవసరమైన à°…à°¨à±à°®à°¤à°²à± లోపించినవి:\n"
-"మనమౠసమూహం '%s' నందౠలేమà±, PolicyKit à°…à°¨à±à°¨à°¦à°¿ మనకౠఅభà±à°¯à°°à±à°¦à°¿à°‚à°šà°¿à°¨ à°…à°¨à±à°®à°¤à±à°²à°¨à± యిచà±à°šà±à°Ÿà°•à± "
-"నిరాకరించినది మరియౠమనమౠవృదà±à°¦à°¿ RLIMIT_NICE/RLIMIT_RTPRIO వనరౠపరిమితà±à°²à°¨à± కలిగిలేమà±.\n"
-"వాసà±à°¤à°µ-సమయ/à°…à°§à°¿à°•-à°ªà±à°°à°¾à°®à±à°–à±à°¯ à°ªà±à°°à°£à°¾à°³à°¿à°•నౠచేతనపరచà±à°Ÿà°•ౠదయచేసి సరైన PolicyKit à°…à°¨à±à°®à°¤à±à°²à°¨à± పొందà±à°®à±, "
-"లేదా '%s' యొకà±à°• సభà±à°¯à±à°¨à°¿à°µà°¿ à°•à°®à±à°®à±, లేదా à°ˆ వినియోగదారికి RLIMIT_NICE/RLIMIT_RTPRIO వనరౠ"
-"పరిమితà±à°²à°¨à± పెంచà±à°®à±."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr "à°…à°§à°¿à°•-à°ªà±à°°à°¾à°®à±à°–à±à°¯à°¤à°¾ à°ªà±à°°à°£à°¾à°³à°¿à°• ఆకృతీకరణనందౠచేతనమà±à°šà±‡à°¯à°¬à°¡à°¿à°‚ది కాని విధానమౠదà±à°µà°¾à°°à°¾ à°…à°¨à±à°®à°¤à°¿à°‚చబడింది."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "సమరà±à°§à°µà°‚తంగా RLIMIT_RTPRIOనౠపెంచినది"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO విఫలమైంది: %s"
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "CAP_NICE యిసà±à°¤à±‹à°‚ది"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr "వాసà±à°¤à°µ-సమయ à°ªà±à°°à°£à°¾à°³à°¿à°• ఆకృతీకరణనందౠచేతనంచేయబడింది కాని విధానమౠదà±à°µà°¾à°°à°¾ à°…à°¨à±à°®à°¤à°¿à°‚చబడలేదà±."
-
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "డెమోనౠనడà±à°šà±à°Ÿ లేదà±"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "డెమోనౠPID %u వలె నడà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "డెమోనౠచంపà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr "à°ˆ à°ªà±à°°à±‹à°—à±à°°à°¾à°®à± root లా నడà±à°ªà°µà°²à°¸à°¿à°‚ది కాదౠ(--system తెలిపితే తపà±à°ª)"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Root à°…à°¨à±à°®à°¤à±à°²à± అవసరమà±."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "--start సిసà±à°Ÿà°®à± సంభవాల à°¦à±à°µà°¾à°°à°¾ మదà±à°¦à°¤à±€à°¯à°¬à°¡à°¦à±."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "సిసà±à°Ÿà°®à± మోడౠనందౠనడà±à°ªà±à°¤à±‹à°‚ది, అయితే --disallow-exit అమరà±à°šà°²à±‡à°¦à±!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "సిసà±à°Ÿà°®à± రీతినందౠనడà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿, అయితే --disallow-module-loading అమరà±à°šà°²à±‡à°¦à±!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "సిసà±à°Ÿà°®à± రీతినందౠనడà±à°ªà±à°šà±à°¨à±à°¨à°¦à°¿, బలవంతంగా SHM రీతిని అచేతనమౠచేసà±à°¤à±‹à°‚ది!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr "సిసà±à°Ÿà°®à± రీతినందౠనడà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿, బలవంతంగా నిషà±à°•à±à°°à°®à°£ వృధా సమయానà±à°¨à°¿ అచేతనమౠచేయà±à°šà±à°¨à±à°¨à°¦à°¿!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "stdio పొందà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "పైరౠవిఫలమైంది: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork() విఫలమైంది: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read() విఫలమైంది: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "డెమోనౠపà±à°°à°¾à°°à°‚à°­à°‚ విఫలమైంది."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "డెమోనౠపà±à°°à°¾à°°à°‚భమౠసఫలమైంది."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() విఫలమైంది: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "ఇది PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "నిరà±à°µà°°à±à°¤à°¨ హోసà±à°Ÿà±: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "నిరà±à°µà°°à±à°¤à°¨ CFLAGS: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "హోసà±à°Ÿà±à°¨à± నడà±à°ªà±à°šà±à°¨à±à°¨à°¦à°¿: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "%u CPUలనౠకనà±à°—ొనà±à°¨à°¦à°¿."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "పేజీ పరిమాణమౠ%lu బైటà±à°²à±"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Valgrind మదà±à°¦à°¤à±à°¤à±‹ నిరà±à°µà°°à±à°¤à°¿à°‚చబడింది: à°…à°µà±à°¨à±"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Valgrind మదà±à°¦à°¤à±à°¤à±‹ నిరà±à°µà°°à±à°¤à°¿à°‚చబడింది: లేదà±"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "valgrind రీతినందౠనడà±à°ªà±à°šà±à°¨à±à°¨à°¦à°¿: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "హోసà±à°Ÿà±à°¨à± నడà±à°ªà±à°šà±à°¨à±à°¨à°¦à°¿: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "ఆపà±à°Ÿà°¿à°®à±ˆà°œà±à°¡à± à°¬à±à°²à±à°¡à±: à°…à°µà±à°¨à±"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "ఆపà±à°Ÿà°¿à°®à±ˆà°œà±à°¡à± à°¬à±à°²à±à°¡à±: కాదà±"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "NDEBUG నిరà±à°µà°šà°¿à°‚చబడింది, à°…à°¨à±à°¨à°¿ à°¸à±à°¥à°¿à°°à°°à°¾à°¶à±à°²à± అచేతనమైనవి."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "FASTPATH నిరà±à°µà°šà°¿à°‚చబడింది, ఫాసà±à°Ÿà± పాతౠసà±à°¥à°¿à°°à°°à°¾à°¶à±à°²à± మాతà±à°°à°®à±‡ అచేతనమైనవి."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "à°…à°¨à±à°¨à°¿ à°¸à±à°¥à°¿à°°à°°à°¾à°¶à±à°²à± చేతనమైనవి."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "మిషనౠID పొందà±à°Ÿà°•ౠవిఫలమైంది"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "మిషనౠID %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "మిషనౠID %s."
+msgstr "సెషనౠID %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "à°°à°¨à±â€Œà°Ÿà±ˆà°®à± డైరెకà±à°Ÿà°°à±€à°¨à± à°µà±à°ªà°¯à±‹à°—à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿ %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "à°¸à±à°¥à°¿à°¤à°¿ డైరెకà±à°Ÿà°°à±€à°¨à± à°µà±à°ªà°¯à±‹à°—à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿ %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "మాడà±à°¯à±‚à°³à±à°³ డైరెకà±à°Ÿà°°à±€ %s à°µà±à°ªà°¯à±‹à°—à°¿à°¸à±à°¤à±‹à°‚ది."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "సిసà±à°Ÿà°®à± రీతినందౠవà±à°ªà°¯à±‹à°—à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"సరే, అయితే మీరౠPAనౠసిసà±à°Ÿà°®à± రీతినందౠనడà±à°ªà±à°¤à±à°¨à±à°¨à°¾à°°à±. మీరౠఅలా చేయకూడదని దయచేసి గమనించండి.\n"
+"ఒకవేళ మీరౠఅలా చేసà±à°¤à±‡ తరà±à°µà°¾à°¤ మీరౠఅనà±à°•ొనà±à°¨à°Ÿà±à°²à± పనిచేయకపోతే అది యిక మీ తపà±à°ªà±‡.\n"
+"సిసà±à°Ÿà°®à± రీతి à°…à°¨à±à°¨à°¦à°¿ సరైనటà±à°µà°‚టిది యెందà±à°•ౠకాదో వివరణ కొరకౠదయచేసి యికà±à°•à°¡ చదవండి http://"
+"pulseaudio.org/wiki/WhatIsWrongWithSystemMode"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create() విఫలమైంది."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "తాజా à°…à°§à°¿à°•-తీవà±à°°à°¤ కాలసూచికలౠఅందà±à°¬à°¾à°Ÿà±à°²à±‹ à°µà±à°¨à±à°¨à°¾à°¯à°¿! బానౠఎపటైటà±!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
msgstr "మితà±à°°à°®à°¾, నీ కెరà±à°¨à°²à± చెడిపోయింది! à°…à°§à°¿à°•-తీవà±à°°à°¤ కాలసూచకిలనౠచేతనమౠచేయమని సూచించడమైనది!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new() విఫలమైంది."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "డెమోనౠసిదà±à°¦à°®à±à°šà±‡à°¯à±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "à°à°µà°¿à°§à°®à±ˆà°¨ మాడà±à°¯à±‚à°³à±à°³à± లోడవకà±à°‚à°¡à°¾ డెమోనౠపà±à°°à°¾à°°à°‚à°­à°®à±, పనిచేయà±à°Ÿà°•ౠతిరసà±à°•రించబడింది."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "డెమోనౠపà±à°°à°¾à°°à°‚భమౠపూరà±à°¤à±ˆà°¨à°¦à°¿."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "డెమోనౠమూసివేత సిదà±à°¦à°®à±à°šà±‡à°¯à°¬à°¡à°¿à°‚ది."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "డెమోనౠఅంతమà±à°šà±‡à°¯à°¬à°¡à°¿à°‚ది."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -658,15 +573,15 @@ msgstr ""
"\n"
" -n Don't load default script file\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -674,52 +589,52 @@ msgstr ""
"--log-level లాగౠసà±à°¥à°¾à°¯à°¿ ఆరà±à°—à±à°®à±†à°‚à°Ÿà±â€Œà°¨à± కోరà±à°•à±à°‚టోంది (సహజసంఖà±à°¯à°¨à± 0..4 విసà±à°¤à±ƒà°¤à°¿à°²à±‹ కాని లేదా డీబగà±â€Œ, "
"సమాచారమà±, నోటీసà±, హెచà±à°šà°°à°¿à°•, దోషమౠవీటిలో వొకటికాని)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "చెలà±à°²à°¨à°¿ లాగౠటారà±à°—ెటà±: 'syslog', 'stderr' లేదా 'auto' à°µà±à°ªà°¯à±‹à°—à°¿à°‚à°šà±à°®à±."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "చెలà±à°²à°¨à°¿ à°ªà±à°¨à°ƒà°µà±à°¦à°¾à°¹à°°à°£ పదà±à°¦à°¤à°¿ '%s'."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm బూలియనౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°¨à± కోరà±à°•à±à°‚à°Ÿà±à°‚ది"
@@ -758,77 +673,87 @@ msgstr "వాడà±à°•: %s\n"
msgid "Load Once: %s\n"
msgstr "ఒకసారి లోడà±à°šà±‡à°¯à±à°®à±: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "తీసివేత హెచà±à°šà°°à°¿à°•: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "పాతà±: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ లాగౠలకà±à°·à±à°¯à°®à± '%s'."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ లాగౠసà±à°¥à°¾à°¯à°¿ '%s'."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ à°ªà±à°¨à°ƒà°µà±à°¦à°¾à°¹à°°à°£ పదà±à°¦à°¤à°¿ '%s'."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ rlimit '%s'."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit à°…à°¨à±à°¨à°¦à°¿ à°ˆ à°ªà±à°²à°¾à°Ÿà±â€Œà°«à°¾à°‚ నందౠమదà±à°¦à°¤à°¿à°µà±à°µà°¬à°¡à°¦à±."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ మాదిరి ఫారà±à°®à°¾à°Ÿà± '%s'."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ మాదిరి రేటౠ'%s'."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ మాదిరి చానళà±à°³à± '%s'."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ ఛానలౠమాపౠ'%s'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ à°®à±à°•à±à°•లౠసంఖà±à°¯ '%s'."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ à°®à±à°•à±à°• పరిమాణమౠ'%s'."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] చెలà±à°²à°¨à°¿ సాదా à°¸à±à°¥à°¾à°¯à°¿ '%s'."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] చెలà±à°²à°¨à°¿ మాదిరి రేటౠ'%s'."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "ఆకృతీకరణ దసà±à°¤à±à°°à°®à±à°¨à± తెరà±à°šà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -836,18 +761,14 @@ msgstr ""
"తెలà±à°ªà°¬à°¡à°¿à°¨ à°…à°ªà±à°°à°®à±‡à°¯ à°ªà±à°°à°¾à°¸à°¾à°°à°®à°¾à°°à±à°—à°‚ మాపౠతెలà±à°ªà°¬à°¡à°¿à°¨ à°…à°ªà±à°°à°®à±‡à°¯ à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°—à°®à±à°² à°•à°¨à±à°¨à°¾ విభినà±à°¨ à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°—à°®à±à°² "
"సంఖà±à°¯à°¨à± కలిగివà±à°‚ది."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### ఆకృతీకరణ దసà±à°¤à±à°°à°®à±à°¨à±à°‚à°¡à°¿ à°šà°¦à±à°µà±à°®à±: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "root à°…à°¨à±à°®à°¤à±à°²à°¨à± తీసివేయà±à°šà±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "సామరà±à°§à±à°¯à°¾à°²à°¨à± CAP_SYS_NICE కౠసమరà±à°¦à°µà°‚తంగా పరిమితం చేయబడినవి."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "à°…à°¨à±à°®à°¤à±à°²à°¨à± à°¶à±à°­à±à°°à°ªà°°à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -857,255 +778,237 @@ msgstr "PulseAudio à°¶à°¬à±à°¦à°ªà± సిసà±à°Ÿà°®à±"
msgid "Start the PulseAudio Sound System"
msgstr "PulseAudio à°¶à°¬à±à°¦à°ªà± సిసà±à°Ÿà°®à±â€Œà°¨à± à°ªà±à°°à°¾à°°à°‚à°­à°¿à°‚à°šà±à°®à±"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "à°…à°§à°¿à°•-à°ªà±à°°à°¾à°®à±à°–à±à°¯à°¤à°¾ à°ªà±à°°à°£à°¾à°³à°¿à°• (à°‹à°£ à°¯à±à°¨à°¿à°•à±à°¸à± సాదా à°¸à±à°¥à°¾à°¯à°¿) PulseAudio డెమోనà±â€Œà°•à±"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio డెమోనà±â€Œ కొరకౠవాసà±à°¤à°µ-సమయ à°ªà±à°°à°£à°¾à°³à°¿à°•"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr "సిసà±à°Ÿà°®à± విధానమౠPulseAudio à°…à°§à°¿à°•-à°ªà±à°°à°¾à°®à±à°–à±à°¯à°¤à°¾ à°ªà±à°°à°£à°¾à°³à°¿à°•నౠపొందకà±à°‚à°¡à°¾ నిరోధిసà±à°¤à±à°¨à±à°¨à°¦à°¿."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr "సిసà±à°Ÿà°®à± విధానమౠPulseAudio వాసà±à°¤à°µ-సమయ à°ªà±à°°à°£à°¾à°³à°¿à°•నౠపొందకà±à°‚à°¡à°¾ నిరోధిసà±à°¤à±‹à°‚ది."
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "మోనో"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "à°®à±à°‚దౠమధà±à°¯à°¨"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "à°®à±à°‚దౠఎడమవైపà±"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "à°®à±à°‚దౠకà±à°¡à°¿à°µà±ˆà°ªà±"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "వెనà±à°• మధà±à°¯à°¨"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "వెనà±à°• ఎడమవైపà±"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "వెనà±à°• à°•à±à°¡à°¿à°µà±ˆà°ªà±"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "తకà±à°•à±à°µ తరచà±à°¦à°¨à°‚ వెలà±à°µà°°à°¿à°‚à°šà±à°¨à°¦à°¿"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "à°®à±à°‚దౠఎడమ-మధà±à°¯"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "à°®à±à°‚దౠకà±à°¡à°¿-మధà±à°¯"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "à°Žà°¡à°® à°ªà±à°°à°•à±à°•"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "à°•à±à°¡à°¿ à°ªà±à°°à°•à±à°•"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "ఆకà±à°¸à°¿à°²à°°à°¿ 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "పై మధà±à°¯à°¨"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "పైన à°®à±à°‚దౠమధà±à°¯à°¨"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "పైన à°®à±à°‚దౠఎడమవైపà±"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "పైన à°®à±à°‚దౠకà±à°¡à°¿à°µà±ˆà°ªà±"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "పైన వెనà±à°• మధà±à°¯à°¨"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "పైన వెనà±à°• ఎడమవైపà±"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "పైన వెనà±à°• à°•à±à°¡à°¿à°µà±ˆà°ªà±à°¨"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(చెలà±à°²à°¨à°¿)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "à°¸à±à°Ÿà±€à°°à°¿à°¯à±‹"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "సరౌండౠ4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "సరౌండౠ4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "సరౌండౠ5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "సరౌండౠ5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "సరౌండౠ7.1"
@@ -1209,27 +1112,35 @@ msgstr "తపà±à°ªà°¿à°ªà±‹à°¯à°¿à°¨ యింపà±à°²à°¿à°®à±†à°‚టేషà°
msgid "Client forked"
msgstr "à°•à°•à±à°·à°¿à°¦à°¾à°°à°¿ పోరà±à°•ౠచేసిన"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "ఇనà±à°ªà±à°Ÿà±/à°…à°µà±à°Ÿà±à°ªà±à°Ÿà± దోషమà±"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "పరికరమౠలేదా వనరౠరదà±à°¦à±€à°—ావà±à°‚ది"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1242,197 +1153,191 @@ msgstr "XOpenDisplay() విఫలమైంది"
msgid "Failed to parse cookie data"
msgstr "à°•à±à°•à±€ డాటా పారà±à°¶à± చేయà±à°Ÿà°•ౠవిఫలమైంది"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "ఆకృతీకరణ దసà±à°¤à±à°°à°®à± '%s' తెరà±à°µà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "à° à°•à±à°•à±€ లోడవలేదà±. లేకà±à°‚à°¡à°¾ à°…à°¨à±à°¸à°‚ధానమగà±à°Ÿà°•à± à°ªà±à°°à°¯à°¤à±à°¨à°¿à°¸à±à°¤à±‹à°‚ది."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "తెలియని పొడిగింపౠకొరకౠసందేశమౠసà±à°µà±€à°•రించింది '%s'"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write() విఫలమైంది: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à±â€Œà°¨à± à°¡à±à°°à±ˆà°¯à°¿à°¨à± చేయà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek() విఫలమైంది: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "à°ªà±à°²à±‡à°¬à±à°¯à°¾à°•à± à°¸à±à°Ÿà±à°°à±€à°®à± à°¡à±à°°à±†à°¯à°¿à°¨à± అయినది."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± సమరà±à°§à°µà°‚తంగా సృషà±à°Ÿà°¿à°‚చబడింది.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "సేవికకౠఅనà±à°¸à°‚ధానమà±à°¨à± à°Žà°‚à°¡à°—à°Ÿà±à°Ÿà±à°šà±à°¨à±à°¨à°¦à°¿."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr() విఫలమైంది: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Buffer metrics: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "సాదారణ విశదీకరణ(à°¸à±à°ªà±†à°•à±) '%s' à°µà±à°ªà°¯à±‹à°—à°¿à°¸à±à°¤à±‹à°‚ది, à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°—à°‚ మాపౠ'%s'.\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "పరికరమౠ%s (%u, %ssuspended) à°•à± à°…à°¨à±à°¸à°‚ధానించబడింది.\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± సమరà±à°§à°µà°‚తంగా సృషà±à°Ÿà°¿à°‚చబడింది."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± దోషమà±: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± పరికరమౠఅరà±à°¦à°¾à°‚తరమà±à°—à°¾ నిలిపివేయి.%s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "బఫరౠపà±à°°à°®à°¾à°£à°¾à°²à±: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± పరికరమౠతిరిగికొనసాగించబడింది.%s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "బఫరౠపà±à°°à°®à°¾à°£à°¾à°²à±: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± తకà±à°•à±à°µà°—ానడà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿.%s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "సాదారణ విశదీకరణ(à°¸à±à°ªà±†à°•à±) '%s' à°µà±à°ªà°¯à±‹à°—à°¿à°¸à±à°¤à±‹à°‚ది, à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°—à°‚ మాపౠ'%s'."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± మించినడà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿.%s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "పరికరమౠ%s (%u, %ssuspended) à°•à± à°…à°¨à±à°¸à°‚ధానించబడింది."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± à°ªà±à°°à°¾à°°à°‚భమైంది.%s \n"
+msgid "Stream error: %s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± దోషమà±: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± పరికరమౠ%s (%u, %ssuspended) à°•à± à°•à°¦à±à°ªà°¬à°¡à°¿à°‚ది.%s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "కాదౠ"
+msgid "Stream device suspended.%s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± పరికరమౠఅరà±à°¦à°¾à°‚తరమà±à°—à°¾ నిలిపివేయబడింది.%s"
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± బఫరౠయాటà±à°°à°¿à°¬à±à°¯à±‚à°Ÿà±à°²à± మారà±à°šà°¬à°¡à°¿à°¨à°µà°¿.%s \n"
+msgid "Stream device resumed.%s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± పరికరమౠతిరిగికొనసాగించబడింది.%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "à°…à°¨à±à°¸à°‚ధానమౠà°à°°à±à°ªà°¡à°¿à°¨à°¦à°¿.%s \n"
+msgid "Stream underrun.%s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± తకà±à°•à±à°µà°—ానడà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿.%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new() విఫలమైంది: %s\n"
+msgid "Stream overrun.%s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± మించినడà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿.%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback() విఫలమైంది: %s\n"
+msgid "Stream started.%s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± à°ªà±à°°à°¾à°°à°‚భమైంది.%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_record() విఫలమైంది: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± పరికరమౠ%s (%u, %ssuspended) à°•à± à°•à°¦à±à°ªà°¬à°¡à°¿à°‚ది.%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "à°…à°¨à±à°¸à°‚ధానమౠవైఫలà±à°¯à°®à±: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "కాదౠ"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± à°Žà°‚à°¡à°—à°Ÿà±à°Ÿà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± బఫరౠయాటà±à°°à°¿à°¬à±à°¯à±‚à°Ÿà±à°²à± మారà±à°šà°¬à°¡à°¿à°¨à°µà°¿.%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "à°ªà±à°²à±‡à°¬à±à°¯à°¾à°•à± à°¸à±à°Ÿà±à°°à±€à°®à± à°Žà°‚à°¡à°—à°Ÿà±à°Ÿà°¿à°¨à°¦à°¿.\n"
+msgid "Connection established.%s"
+msgstr "à°…à°¨à±à°¸à°‚ధానమౠà°à°°à±à°ªà°¡à°¿à°¨à°¦à°¿.%s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "సేవికకౠఅనà±à°¸à°‚ధానమà±à°¨à± నశింపచేసà±à°¤à±‹à°‚ది.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "EOF పొందింది.\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read() విఫలమైంది: %s\n"
+msgid "Connection failure: %s"
+msgstr "à°…à°¨à±à°¸à°‚ధానమౠవైఫలà±à°¯à°®à±: %s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write() విఫలమైంది: %s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "EOF పొందింది."
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "సంకేతమౠపొందినది, నిషà±à°•à±à°°à°®à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿.\n"
+msgid "write() failed: %s"
+msgstr "write() విఫలమైంది: %s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "à°•à±à°°à°¿à°¯à°¾à°¹à±€à°¨à°¤à°¨à± పొందà±à°Ÿà°²à±‹ విఫలమైంది: %s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "సంకేతమౠపొందినది, నిషà±à°•à±à°°à°®à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "సమయం: %0.3f sec; à°•à±à°°à°¿à°¯à°¾à°¹à±€à°¨à°¤: %0.0f usec. \r"
+msgid "Failed to get latency: %s"
+msgstr "లేటెనà±à°¸à±€à°¨à°¿ పొందà±à°Ÿà°²à±‹ విఫలమైంది: %s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info() విఫలమైంది: %s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "సమయం: %0.3f సెకనà±; లెటెనà±à°¸à±€: %0.0f usec."
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() విఫలమైంది: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1458,8 +1363,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1482,6 +1389,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
@@ -1507,8 +1423,10 @@ msgstr ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1531,8 +1449,13 @@ msgstr ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format=FFORMAT Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1543,129 +1466,169 @@ msgstr ""
"libpulse తో నిరà±à°µà°°à±à°¤à°¿à°‚చబడింది %s\n"
"libpulse లింకైనది %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "చెలà±à°²à°¨à°¿ à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°— మాపౠ'%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "చెలà±à°²à°¨à°¿ à°•à°•à±à°·à°¿à°¦à°¾à°°à°¿ నామమౠ'%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "చెలà±à°²à°¨à°¿ à°•à±à°°à°¿à°¯à°¾à°¹à±€à°¨ విశదీకరణమౠ'%s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "చెలà±à°²à°¨à°¿ à°¸à±à°Ÿà±à°°à±€à°®à± నామమౠ'%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "చెలà±à°²à°¨à°¿ కారà±à°¯à°•à±à°°à°®à°®à± సమయ విశదీకరణ '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "చెలà±à°²à°¨à°¿ à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°— మాపౠ'%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "చెలà±à°²à°¨à°Ÿà±à°µà°‚à°Ÿà°¿ మాదిరి విశదీకరణ\n"
+msgid "Invalid latency specification '%s'"
+msgstr "చెలà±à°²à°¨à°¿ లేటెనà±à°¸à±€ విశదీకరణమౠ'%s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°— మాపౠమాదిరి విశదీకరణితో సరిపోలà±à°Ÿà°²à±‡à°¦à±\n"
+msgid "Invalid process time specification '%s'"
+msgstr "చెలà±à°²à°¨à°¿ కారà±à°¯à°•à±à°°à°®à°®à± సమయ విశదీకరణ '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "%s à°¸à±à°Ÿà±à°°à±€à°®à±â€Œà°¨à± మాదిరి విశదీకరణి '%s'తో తెరà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿.\n"
+msgid "Invalid property '%s'"
+msgstr "చెలà±à°²à°¨à°¿ లకà±à°·à°£à°®à± '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "రికారà±à°¡à°¿à°‚à°—à±"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "తెలియని ఫైలౠఫారà±à°®à°¾à°Ÿà± %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "à°ªà±à°²à±‡à°¬à°¾à°•à±"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "చెలà±à°²à°¨à°Ÿà±à°µà°‚à°Ÿà°¿ మాదిరి విశదీకరణ"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "చాలా యెకà±à°•à±à°µ ఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°²à±.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "చాలా యెకà±à°•à±à°µ ఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°²à±."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new() విఫలమైంది.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "దసà±à°¤à±à°°à°®à± కొరకౠమాదిరి సమాచారమౠజనియింపచేయà±à°Ÿà°²à±‹ విఫలమైంది."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new() విఫలమైంది.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "ఆడియో ఫైలà±à°¨à± తెరà±à°µà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new() విఫలమైంది.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "హెచà±à°šà°°à°¿à°•: తెలà±à°ªà°¬à°¡à°¿à°¨ మాదిరి విశదీకరణ దసà±à°¤à±à°°à°®à±à°¨à±à°‚à°¡à°¿ వచà±à°šà± విశదీకరణతో తిరిగివà±à°°à°¾à°¯à°¬à°¡à±à°¤à±à°‚ది."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect() విఫలమైంది: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "దసà±à°¤à±à°°à°®à±à°¨à±à°‚à°¡à°¿ మాదిరి విశదీకరణనౠనిరà±à°§à°¾à°°à°¿à°‚à°šà±à°Ÿà°²à±‹ విఫలమైంది."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "హెచà±à°šà°°à°¿à°•: దసà±à°¤à±à°°à°®à±à°¨à±à°‚à°¡à°¿ à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°— మాపౠనిరà±à°§à°¾à°°à°¿à°‚à°šà±à°Ÿà°²à±‹ విఫలమైంది."
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°— మాపౠమాదిరి విశదీకరణితో సరిపోలà±à°Ÿà°²à±‡à°¦à±"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "హెచà±à°šà°°à°¿à°•: à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°— మాపà±â€Œà°¨à± దసà±à°¤à±à°°à°®à±à°•à± à°µà±à°°à°¾à°¯à±à°Ÿà°²à±‹ విఫలమైంది."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new() విఫలమైంది.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "%s à°¸à±à°Ÿà±à°°à±€à°®à±â€Œà°¨à± మాదిరి విశదీకరణ '%s' మరియౠపà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°— మాపౠ'%s'తో తెరà±à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "రికారà±à°¡à°¿à°‚à°—à±"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "à°ªà±à°²à±‡à°¬à°¾à°•à±"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() విఫలమైంది."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() విఫలమైంది."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() విఫలమైంది."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run() విఫలమైంది.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() విఫలమైంది: %s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() విఫలమైంది."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() విఫలమైంది."
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "à°…à°°à±à°§à°¾à°‚తరనిలà±à°ªà±à°¦à°² వైఫలà±à°¯à°‚: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "తిరిగికొనసాగింపౠవైఫలà±à°¯à°®à±: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "హెచà±à°šà°°à°¿à°•: à°¶à°¬à±à°§à°ªà± సేవిక à°¸à±à°¥à°¾à°¨à°¿à°•à°‚ కాదà±, à°…à°°à±à°§à°¾à°‚తరనిలà±à°ªà±à°¦à°² కావడంలేదà±.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "à°…à°¨à±à°¸à°‚ధానమౠవైఫలà±à°¯à°®à±: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "SIGINT పొందింది, నిషà±à°•à±à°°à°®à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "హెచà±à°šà°°à°¿à°•: చైలà±à°¡à± కారà±à°¯à°•à±à°°à°®à°®à± సంకేతమౠ%u à°¦à±à°µà°¾à°°à°¾ అంతమà±à°šà±‡à°¯à°¬à°¡à°¿à°‚ది\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1684,7 +1647,7 @@ msgstr ""
"to\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1695,35 +1658,61 @@ msgstr ""
"libpulse తో నిరà±à°µà°°à±à°¤à°¿à°‚చబడింది %s\n"
"libpulse తో నిరà±à°µà°°à±à°¤à°¿à°‚చబడింది %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() విఫలమైంది.\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() విఫలమైంది.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() విఫలమైంది.\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "గణాంకాలనౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get statistics: %s"
+msgstr "గణాంకాలనౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "à°ªà±à°°à°¸à±à°¤à±à°¤à°‚ à°µà±à°ªà°¯à±‹à°—ంలోవà±à°‚ది: %u à°¬à±à°²à°¾à°•à±â€Œà°²à± %s బైటà±à°²à°¨à± మొతà±à°¤à°‚à°—à°¾ కలిగి à°µà±à°¨à±à°¨à°¾à°¯à°¿.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "మొతà±à°¤à°‚ లైఫà±â€Œà°Ÿà±ˆà°®à±à°²à±‹ కేటాయించబడింది: %u à°¬à±à°²à°¾à°•à±à°²à± %s బైటà±à°²à°¨à± మొతà±à°¤à°‚à°—à°¾ కలిగివà±à°¨à±à°¨à°¾à°¯à°¿.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "మాదిరి à°•à±à°¯à°¾à°šà°¿ పరిమాణమà±: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "సేవిక సమాచారమà±à°¨à± పొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "సేవిక సమాచారమà±à°¨à± పొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1731,7 +1720,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"వినియోగదారి నామమà±: %s\n"
"హోసà±à°Ÿà± నామమà±: %s\n"
@@ -1743,12 +1732,12 @@ msgstr ""
"à°…à°ªà±à°°à°®à±‡à°¯ మూలమà±: %s\n"
"à°•à±à°•à±€: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "సింకౠసమాచారమà±à°¨à± పొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "సింకౠసమాచారమà±à°¨à± పొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1787,12 +1776,22 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr "\tపోరà±à°Ÿà±à°²à±:\n"
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "మూలమౠసమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "\tActive Port: %s\n"
+msgstr "\tà°•à±à°°à°¿à°¯à°¾à°¶à±€à°² పోరà±à°Ÿà±: %s\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "మూలమౠసమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1831,20 +1830,20 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "వరà±à°¤à°¿à°‚à°šà°¦à±"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "మాడà±à°¯à±‚లౠసమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "మాడà±à°¯à±‚లౠసమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1861,12 +1860,12 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "à°•à°•à±à°·à°¿à°¦à°¾à°°à°¿ సమాచారమౠపొందà±à°Ÿà°²à±‹ విఫలమైంది: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "à°•à°•à±à°·à°¿à°¦à°¾à°°à°¿ సమాచారమౠపొందà±à°Ÿà°²à±‹ విఫలమైంది: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1881,12 +1880,12 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "కారà±à°¡à± సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "కారà±à°¡à± సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1903,22 +1902,22 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tà°ªà±à°°à±‹à°«à±ˆà°²à±à°¸à±:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tà°•à±à°°à°¿à°¯à°¾à°¶à±€à°² à°ªà±à°°à±Šà°«à±ˆà°²à±: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "సింకౠఇనà±à°ªà±à°Ÿà± సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "సింకౠఇనà±à°ªà±à°Ÿà± సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1955,12 +1954,12 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "మూలపౠఅవà±à°Ÿà±à°ªà±à°Ÿà± సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "మూలపౠఅవà±à°Ÿà±à°ªà±à°Ÿà± సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1989,12 +1988,12 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "మాదిరి సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "మాదిరి సమాచారమౠపొందà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2025,23 +2024,80 @@ msgstr ""
"\tలకà±à°·à°£à°¾à°²à±:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "విఫైలà±à°¯à°®à±: %s\n"
+msgid "Failure: %s"
+msgstr "వైఫైలà±à°¯à°®à±: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "మాదిరి à°…à°ªà±â€Œà°²à±‹à°¡à± చేయà±à°Ÿà°•ౠవిఫలమైంది: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "మాదిరి à°…à°ªà±â€Œà°²à±‹à°¡à± చేయà±à°Ÿà°•ౠవిఫలమైంది: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "దసà±à°¤à±à°°à°®à± యొకà±à°• అపరిపకà±à°µ à°®à±à°—à°¿à°‚à°ªà±\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "దసà±à°¤à±à°°à°®à± యొకà±à°• అపరిపకà±à°µ à°®à±à°—à°¿à°‚à°ªà±"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "చెలà±à°²à°¨à°¿ సేవిక"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "SIGINT పొందింది, నిషà±à°•à±à°°à°®à°¿à°‚à°šà±à°šà±à°¨à±à°¨à°¦à°¿."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2049,13 +2105,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2071,13 +2136,21 @@ msgstr ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2087,7 +2160,7 @@ msgstr ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2098,76 +2171,108 @@ msgstr ""
"libpulse తో నిరà±à°µà°°à±à°¤à°¿à°‚చబడింది%s\n"
"libpulse తో లింకà±à°šà±‡à°¯à°¬à°¡à°¿à°‚ది %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "లోడà±à°µà±à°µà±à°Ÿà°•ౠదయచేసి మాదిరి దసà±à°¤à±à°°à°®à±à°¨à± తెలà±à°ªà±à°®à±\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "లోడà±à°µà±à°µà±à°Ÿà°•ౠదయచేసి మాదిరి దసà±à°¤à±à°°à°®à±à°¨à± తెలà±à°ªà±à°®à±"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "à°¶à°¬à±à°¦à°ªà± దసà±à°¤à±à°°à°®à±à°¨à± తెరà±à°µà±à°Ÿà°•ౠవిఫలమైంది.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "à°¶à°¬à±à°¦à°ªà± దసà±à°¤à±à°°à°®à±à°¨à± తెరà±à°µà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "à°ªà±à°²à±‡ చేయà±à°Ÿà°•ౠమీరౠమాదిరి నామమà±à°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "హెచà±à°šà°°à°¿à°•: దసà±à°¤à±à°°à°®à±à°¨à±à°‚à°¡à°¿ మాదిరి విశదీకరణనౠనిరà±à°£à°¯à°¿à°‚à°šà±à°Ÿà°•ౠవిఫలమైంది."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "తొలగించà±à°Ÿà°•ౠమీరౠమాదిరి నామమà±à°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "à°ªà±à°²à±‡ చేయà±à°Ÿà°•ౠమీరౠమాదిరి నామమà±à°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "మీరౠసింకౠఇనà±à°ªà±à°Ÿà± విషయసూచిక మరియౠసింకౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "తొలగించà±à°Ÿà°•ౠమీరౠమాదిరి నామమà±à°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "మీరౠమూలమౠఅవà±à°Ÿà±à°ªà±à°Ÿà± విషయసూచిక మరియౠమూలమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "మీరౠసింకౠఇనà±à°ªà±à°Ÿà± విషయసూచిక మరియౠసింకౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "మీరౠమాడà±à°¯à±‚లౠనామమౠమరియౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°²à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "మీరౠమూలమౠఅవà±à°Ÿà±à°ªà±à°Ÿà± విషయసూచిక మరియౠమూలమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "మీరౠమాడà±à°¯à±‚లౠవిషయసూచిక తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "మీరౠమాడà±à°¯à±‚లౠనామమౠమరియౠఆరà±à°—à±à°®à±†à°‚à°Ÿà±à°²à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "మీరౠమాడà±à°¯à±‚లౠవిషయసూచిక తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
-"మీరౠవొక సింకౠకనà±à°¨à°¾ యెకà±à°•à±à°µ తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚డకపోవచà±à°šà±. మీరౠబూలియనౠవిలà±à°µà°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది.\n"
+"మీరౠవొక సింకౠకనà±à°¨à°¾ యెకà±à°•à±à°µ తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚డకపోవచà±à°šà±. మీరౠబూలియనౠవిలà±à°µà°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
-"మీరౠవొక మూలమౠకనà±à°¨à°¾ యెకà±à°•à±à°µ తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚డకపోవచà±à°šà±. మీరౠబూలియనౠవిలà±à°µà°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది.\n"
+"మీరౠవొక మూలమౠకనà±à°¨à°¾ యెకà±à°•à±à°µ తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚డకపోవచà±à°šà±. మీరౠబూలియనౠవిలà±à°µà°¨à± తెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "మీరౠకారà±à°¡à± నామమà±/విషయసూచిక మరియౠపà±à°°à±Šà°«à±ˆà°²à± నామమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "మీరౠకారà±à°¡à± నామమà±/విషయసూచిక మరియౠపà±à°°à±Šà°«à±ˆà°²à± నామమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "à°Žà°Ÿà±à°µà°‚à°Ÿà°¿ విలà±à°µà±ˆà°¨ ఆదేశమౠతెలà±à°ªà°²à±‡à°¦à±.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "మీరౠసింకà±â€Œ నామమà±/విషయసూచిక మరియౠపà±à°°à±Šà°«à±ˆà°²à± నామమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect() విఫలమైంది: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "మీరౠమూలమౠనామమà±/విషయసూచిక మరియౠపà±à°°à±Šà°«à±ˆà°²à± నామమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "మీరౠసింకౠనామమà±/విషయసూచిక మరియౠపà±à°°à±Šà°«à±ˆà°²à± నామమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "చెలà±à°²à°¨à°Ÿà±à°µà°‚à°Ÿà°¿ వాలà±à°¯à±‚మౠవిశదీకరణ"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "మీరౠమూలమౠనామమà±/విషయసూచిక మరియౠపà±à°°à±Šà°«à±ˆà°²à± నామమౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "మీరౠసింకౠఇనà±à°ªà±à°Ÿà± విషయసూచిక మరియౠవాలà±à°¯à±‚మౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "చెలà±à°²à°¨à°¿ సింకౠయినà±à°ªà±à°Ÿà± విషయసూచిక"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "మీరౠసింకà±â€Œ నామమà±/విషయసూచిక మరియౠమà±à°¯à±‚టౠబూలియనౠతెలà±à°ªà°µà°²à°¸à°¿ à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "మీరౠమూలపౠనామమà±/విషయసూచిక మరియౠమà±à°¯à±‚టౠబూలియనౠతెలà±à°ªà°µà°²à°¸à°¿à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "మీరౠసింకౠఇనà±à°ªà±à°Ÿà± విషయసూచిక మరియౠమà±à°¯à±‚టౠబూలియనౠతెలà±à°ªà°µà°²à°¸à°¿à°µà±à°‚ది"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "చెలà±à°²à°¨à°Ÿà±à°µà°‚à°Ÿà°¿ సింకౠయినà±à°ªà±à°Ÿà± విషయసూచిక విశదీకరణ"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "à°Žà°Ÿà±à°µà°‚à°Ÿà°¿ విలà±à°µà±ˆà°¨ ఆదేశమౠతెలà±à°ªà°¬à°¡à°²à±‡à°¦à±."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2248,129 +2353,48 @@ msgstr "à°•à±à°•à±€ డాటా లోడౠచేయà±à°Ÿà°•ౠవిఫà°
msgid "Not yet implemented.\n"
msgstr "ఇంకా యింపà±à°²à°¿à°®à±†à°‚టౠచేయలేదà±\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "PulseAudio డెమోనౠనడà±à°šà±à°Ÿà°²à±‡à°¦à±, లేదా సెషనౠడెమోనౠవలె నడà±à°šà±à°Ÿà°²à±‡à°¦à±."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "PulseAudio డెమోనౠనాశనం చేయà±à°Ÿà°²à±‹ విఫలమైంది."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "డెమోనౠసà±à°ªà°‚దించà±à°Ÿà°²à±‡à°¦à±."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± సమరà±à°¦à°µà°‚తంగా సృషà±à°Ÿà°¿à°‚చబడింది\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "à°¸à±à°Ÿà±à°°à±€à°®à± దోషమà±: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "à°…à°¨à±à°¸à°‚ధానమౠà°à°°à±à°ªà°¡à°²à±‡à°¦à±.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"libpulse తో నిరà±à°µà°°à±à°¤à°¿à°‚చబడింది%s\n"
-"libpulse తో లింకైనది %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "చెలà±à°²à°¨à°¿ à°ªà±à°°à°¸à°¾à°° మారà±à°—à°®à±\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "దసà±à°¤à±à°°à°®à± '%s' తెరà±à°šà±à°Ÿà°•ౠవిఫలమైంది\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "à°ªà±à°°à°¸à°¾à°°à°®à°¾à°°à±à°—à°‚ మాపౠఅనà±à°¨à°¦à°¿ దసà±à°¤à±à°°à°®à±à°¤à±‹ సరిపోలà±à°šà°¡à°‚లేదà±.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "మాదిరి విశదీకరణనౠవà±à°ªà°¯à±‹à°—à°¿à°¸à±à°¤à±‹à°‚ది '%s'\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "ఆటోసà±à°ªà°¾à°¨à± తాళంనౠయాకà±à°¸à°¿à°¸à± చేయలేదà±."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2386,7 +2410,7 @@ msgstr ""
"మనమౠPOLLOUT అమరà±à°ªà± à°¦à±à°µà°¾à°°à°¾ జాగరూక పరచబడినామౠ-- à°à°®à±ˆà°¨à°ªà±à°ªà°Ÿà°¿à°•à°¿ snd_pcm_avail() à°…à°¨à±à°¨à°¦à°¿ 0 నౠ"
"యిసà±à°¤à±à°‚ది లేదా వేరొక విలà±à°µ < min_avail యిసà±à°¤à±à°‚ది."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2402,34 +2426,259 @@ msgstr ""
"మనమౠPOLLOUT అమరà±à°ªà± à°¦à±à°µà°¾à°°à°¾ జాగరూక పరచబడినామౠ-- à°à°®à±ˆà°¨à°ªà±à°ªà°Ÿà°¿à°•à°¿ snd_pcm_avail() à°…à°¨à±à°¨à°¦à°¿ 0 నౠ"
"యిసà±à°¤à±à°‚ది లేదా వేరొక విలà±à°µ < min_avail యిసà±à°¤à±à°‚ది."
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "à°…à°µà±à°Ÿà±à°ªà±à°Ÿà± %s + ఇనà±à°ªà±à°Ÿà± %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "à°…à°µà±à°Ÿà±à°ªà±à°Ÿà± %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "ఇనà±à°ªà±à°Ÿà± %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "ఆఫà±"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "హై ఫెడిలిటి à°ªà±à°²à±‡à°¬à±à°¯à°¾à°•à± (A2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "హై ఫెడిలిటి కాపà±à°šà°°à± (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "టెలిఫోనీ డూపà±à°²à±†à°•à±à°¸à± (HSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "పలà±à°¸à± ఆడియో సౌండౠసేవిక"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "à°…à°µà±à°Ÿà±à°ªà±à°Ÿà± పరికరమà±à°²à±"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ఇనà±à°ªà±à°Ÿà± పరికరమà±à°²à±"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ పై ఆడియో"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "ఇనà±à°ªà±à°Ÿà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "డాకింగౠసà±à°Ÿà±‡à°·à°¨à± ఇనà±à°ªà±à°Ÿà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "డాకింగౠసà±à°Ÿà±‡à°·à°¨à± మైకà±à°°à±‹à°«à±‹à°¨à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "లైనà±-యినà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "మైకà±à°°à±‹à°«à±‹à°¨à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "బహిరà±à°—à°¤ మైకà±à°°à±‹à°«à±‹à°¨à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "అంతరà±à°—à°¤ మైకà±à°°à±‹à°«à±‹à°¨à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "రేడియో"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "వీడియో"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "à°¸à±à°µà°¯à°‚చాలకంగా పొందౠనియంతà±à°°à°£"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "à°¸à±à°µà°¯à°‚చాలకంగా పొందౠఠనియంతà±à°°à°£ లేదà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "బూసà±à°Ÿà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "బూసà±à°Ÿà± లేదà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "à°Žà°‚à°ªà±à°²à°¿à°«à±ˆà°°à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "à°Žà°‚à°ªà±à°²à°¿à°«à±ˆà°°à± లేదà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "బూసà±à°Ÿà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "బూసà±à°Ÿà± లేదà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "ఎనలాగౠహెడà±â€Œà°«à±‹à°¨à±à°¸à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "ఎనలాగౠయినà±à°ªà±à°Ÿà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "ఎనలాగౠమైకà±à°°à±‹à°«à±‹à°¨à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "ఎనలాగౠలైనà±-యినà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "ఎనలాగౠరేడియో"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "ఎనలాగౠవీడియో"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "ఎనలాగౠఅవà±à°Ÿà±à°ªà±à°Ÿà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "ఎనలాగౠహెడà±â€Œà°«à±‹à°¨à±à°¸à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "ఎనలాగౠఅవà±à°Ÿà±à°ªà±à°Ÿà± (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "ఎనలాగౠమోనో à°…à°µà±à°Ÿà±à°ªà±à°Ÿà±"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "ఎనలాగౠసà±à°Ÿà±€à°°à°¿à°¯à±‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "ఎనలాగౠమోనో"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "ఎనలాగౠసà±à°Ÿà±€à°°à°¿à°¯à±‹"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "ఎనలాగౠసరౌండౠ2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "ఎనలాగౠసరౌండౠ3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "ఎనలాగౠసరౌండౠ3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "ఎనలాగౠసరౌండౠ4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "ఎనలాగౠసరౌండౠ4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "ఎనలాగౠసరౌండౠ5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "ఎనలాగౠసరౌండౠ5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "ఎనలాగౠసరౌండౠ6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "ఎనలాగౠసరౌండౠ6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "ఎనలాగౠసరౌండౠ7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "ఎనలాగౠసరౌండౠ7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "డిజిటలౠసà±à°Ÿà±€à°°à°¿à°¯à±‹ (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "డిజిటలౠసరౌండౠ4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "డిజిటలౠసరౌండౠ4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "డిజిటలౠసరౌండౠ5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "డిజిటలౠసà±à°Ÿà±€à°°à°¿à°¯à±‹ (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "ఎనలాగౠమోనో à°¡à±à°ªà±à°²à±†à°•à±à°¸à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "ఎనలాగౠసà±à°Ÿà±€à°°à°¿à°¯à±‹ à°¡à±à°ªà±à°²à±†à°•à±à°¸à±"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "డిజిటలౠసà±à°Ÿà±€à°°à°¿à°¯à±‹ à°¡à±à°ªà±à°²à±†à°•à±à°¸à± (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "తకà±à°•à±à°µ తరచà±à°¦à°¨à°‚ వెలà±à°µà°°à°¿à°‚à°šà±à°¨à°¦à°¿"
diff --git a/po/uk.po b/po/uk.po
index 0da3ff2c..528a6e59 100644
--- a/po/uk.po
+++ b/po/uk.po
@@ -6,8 +6,8 @@ msgid ""
msgstr ""
"Project-Id-Version: pulseaudio.master-tx\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-18 11:13+0300\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-10-03 19:28+0300\n"
"Last-Translator: Yuri Chornoivan <yurchor@ukr.net>\n"
"Language-Team: Ukrainian <translation@linux.org.ua>\n"
"MIME-Version: 1.0\n"
@@ -17,51 +17,12 @@ msgstr ""
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%"
"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "Ðналоговий моно"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "Ðналоговий Ñтерео"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "Цифровий Ñтерео (IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "Цифровий Ñтерео (HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "Ðналоговий об’ємний 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "Цифровий об’ємний 4.0 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "Ðналоговий об’ємний 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "Ðналоговий об’ємний 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "Ðналоговий об’ємний 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "Цифровий об’ємний 5.1 (IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "Ðналоговий об’ємний 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -74,7 +35,7 @@ msgstr ""
"Ймовірно, ви натрапили на ваду у драйвері ALSA «%s». Будь лаÑка, повідомте "
"про цю ваду розробникам ALSA."
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -87,7 +48,7 @@ msgstr ""
"Ймовірно, ви натрапили на ваду у драйвері ALSA «%s». Будь лаÑка, повідомте "
"про цю ваду розробникам ALSA."
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -100,11 +61,47 @@ msgstr ""
"Ймовірно, ви натрапили на ваду у драйвері ALSA «%s». Будь лаÑка, повідомте "
"про цю ваду розробникам ALSA."
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+"Завжди підтримувати принаймні один завантажений приймач, навіть Ñкщо він "
+"буде нульовим"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "ТеÑтове відтвореннÑ"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "Віртуальний приймач LADSPA"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<назва приймача> sink_properties=<влаÑтивоÑті приймача> "
+"master=<назва приймача Ð´Ð»Ñ Ñ„Ñ–Ð»ÑŒÑ‚Ñ€ÑƒÐ²Ð°Ð½Ð½Ñ> format=<формат Ñемплу> "
+"rate=<чаÑтота вибірки> channels=<кількіÑть каналів> channel_map=<карта "
+"каналів> plugin=<назва додатка ladspa> label=<мітка додатка ladspa> "
+"control=<розділений комами ÑпиÑок значень вхідних параметрів>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "NULL-приймач з годинником"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Ðуль-відтвореннÑ"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "Вбудоване аудіо"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "Модем"
@@ -123,225 +120,98 @@ msgstr ""
msgid "Failed to add bind-now-loader."
msgstr "Ðе вдалоÑÑ Ð´Ð¾Ð´Ð°Ñ‚Ð¸ bind-now-loader."
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "Ðе вдалоÑÑ Ð·â€™Ñ”Ð´Ð½Ð°Ñ‚Ð¸ÑÑ Ð· шиною ÑиÑтеми: %s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ джерело виклику від PID: %s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "Ðе вдалоÑÑ Ð²Ñтановити UID Ð´Ð»Ñ Ð¾Ð±â€™Ñ”ÐºÑ‚Ð° джерела виклику."
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ CK ÑеанÑу."
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "Ðе вдалоÑÑ Ð²Ñтановити UID Ð´Ð»Ñ Ð¾Ð±â€™Ñ”ÐºÑ‚Ð° ÑеанÑу."
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "Ðе вдалоÑÑ Ñ€Ð¾Ð·Ð¼Ñ–Ñтити PolKitAction."
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "Ðе вдалоÑÑ Ð²Ñтановити action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "Ðе вдалоÑÑ Ñ€Ð¾Ð·Ð¼Ñ–Ñтити PolKitContext."
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "Ðе вдалоÑÑ Ñ–Ð½Ñ–Ñ†Ñ–Ð°Ð»Ñ–Ð·ÑƒÐ²Ð°Ñ‚Ð¸ PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "Ðе вдалоÑÑ Ð²Ð¸Ð·Ð½Ð°Ñ‡Ð¸Ñ‚Ð¸ чи уповноважено джерело виклику: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ уповноваженнÑ: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit надіÑлала відповідь: «%s»"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "Отримано Ñигнал %s."
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "Ð—Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸."
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "Ðе вдалоÑÑ Ð·Ð½Ð°Ð¹Ñ‚Ð¸ кориÑтувача «%s»."
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "Ðе вдалоÑÑ Ð·Ð½Ð°Ð¹Ñ‚Ð¸ групу «%s»."
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "Знайдено кориÑтувача «%s» (UID %lu) Ñ– групу «%s» (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "GID кориÑтувача «%s» Ñ– групи «%s» не збігаютьÑÑ."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "Домашнім каталогом кориÑтувача «%s» не Ñ” «%s», дані проігноровано."
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "Ðе вдалоÑÑ Ñтворити «%s»: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "Ðе вдалоÑÑ Ð·Ð¼Ñ–Ð½Ð¸Ñ‚Ð¸ ÑпиÑок груп: %s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "Ðе вдалоÑÑ Ð·Ð¼Ñ–Ð½Ð¸Ñ‚Ð¸ GID: %s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "Ðе вдалоÑÑ Ð·Ð¼Ñ–Ð½Ð¸Ñ‚Ð¸ UID: %s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "Програма уÑпішно позбулаÑÑ Ð¿Ñ€Ð°Ð² доÑтупу кориÑтувача root."
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "ЗагальноÑиÑтемний режим не підтримуєтьÑÑ Ð½Ð° цій платформі."
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "Спроба виконати setrlimit(%s, (%u, %u)) була невдалою: %s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "Ðе вдалоÑÑ Ð¾Ð±Ñ€Ð¾Ð±Ð¸Ñ‚Ð¸ Ñ€Ñдок команди."
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr ""
-"Ми перебуваємо у групі «%s», що надає змогу Ð¿Ð»Ð°Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ð· виÑоким пріоритетом."
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr ""
-"Ми перебуваємо у групі «%s», що надає змогу Ð¿Ð»Ð°Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ñƒ режимі реального "
-"чаÑу."
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit надала нам права доÑтупу acquire-high-priority."
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKit відмовила у наданні прав доÑтупу acquire-high-priority."
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit надала нам права доÑтупу acquire-real-time."
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKit відмовила у наданні прав доÑтупу acquire-real-time."
-
-#: ../src/daemon/main.c:556
-#, c-format
-msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
-msgstr ""
-"У налаштуваннÑÑ… було вказано виклик SUID root Ñ– Ð¿Ð»Ð°Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ñ€ÐµÐ¶Ð¸Ð¼Ñƒ реального "
-"чаÑу Ñ–/або режиму виÑокого пріоритету. Ðле у Ð½Ð°Ñ Ð½ÐµÐ¼Ð°Ñ” потрібних прав "
-"доÑтупу:\n"
-"Ваш кориÑтувач не Ñ” учаÑником групи «%s», PolicyKit відмовила у наданні нам "
-"потрібних прав доÑтупу, тому знÑÑ‚Ñ‚Ñ Ð¾Ð±Ð¼ÐµÐ¶ÐµÐ½ÑŒ реÑурÑу RLIMIT_NICE/"
-"RLIMIT_RTPRIO не можливе.\n"
-"Щоб увімкнути Ð¿Ð»Ð°Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ñ€ÐµÐ¶Ð¸Ð¼Ñƒ реального чаÑу Ñ–/або режиму виÑокого "
-"пріоритету, будь лаÑка, отримайте відповідні права доÑтупу у PolicyKit або "
-"Ñтаньте учаÑником групи «%s» або збільшіть діапазон реÑурÑу RLIMIT_NICE/"
-"RLIMIT_RTPRIO Ð´Ð»Ñ Ñ†ÑŒÐ¾Ð³Ð¾ кориÑтувача."
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr ""
-"ÐŸÐ»Ð°Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ð· виÑоким пріоритетом увімкнено у налаштуваннÑÑ…, але не дозволене "
-"правилами безпеки."
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "УÑпішно підвищено RLIMIT_RTPRIO"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "Помилка під Ñ‡Ð°Ñ Ñпроби підвищити RLIMIT_RTPRIO: %s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "ПозбуваємоÑÑ CAP_NICE"
-
-#: ../src/daemon/main.c:627
+#: ../src/daemon/main.c:535
msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"ÐŸÐ»Ð°Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ñƒ режимі реального чаÑу увімкнено у налаштуваннÑÑ…, але не "
-"дозволене правилами безпеки."
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "Фонову Ñлужбу не запущено"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "Фонову Ñлужбу запущено Ñк PID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "Ðе вдалоÑÑ Ð·Ð°Ð²ÐµÑ€ÑˆÐ¸Ñ‚Ð¸ роботу фонової Ñлужби: %s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
@@ -349,164 +219,201 @@ msgstr ""
"Цю програму не призначено Ð´Ð»Ñ Ð·Ð°Ð¿ÑƒÑку від імені кориÑтувача root (Ñкщо не "
"вказано параметра --system)."
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "Потрібні права доÑтупу кориÑтувача root."
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr ""
"Параметр --start не підтримуєтьÑÑ Ð´Ð»Ñ Ð·Ð°Ð³Ð°Ð»ÑŒÐ½Ð¾ÑиÑтемних екземплÑрів програми."
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr ""
"ЗапуÑк у загальноÑиÑтемному режимі, але не вÑтановлено --disallow-exit!"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr ""
"ЗапуÑк у загальноÑиÑтемному режимі, але не вÑтановлено --disallow-module-"
"loading!"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "ЗапуÑк у загальноÑиÑтемному режимі, примуÑове Ð²Ð¸Ð¼Ð¸ÐºÐ°Ð½Ð½Ñ Ñ€ÐµÐ¶Ð¸Ð¼Ñƒ SHM!"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr ""
"ЗапуÑк у загальноÑиÑтемному режимі, примуÑове Ð²Ð¸Ð¼Ð¸ÐºÐ°Ð½Ð½Ñ Ñ€ÐµÐ¶Ð¸Ð¼Ñƒ параметрів "
"чаÑу виходу за відÑутноÑті активноÑті!"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ stdio."
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "Спроба ÑÑ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ ÐºÐ°Ð½Ð°Ð»Ñƒ завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ fork() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ read() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "Спроба запуÑку фонової Ñлужби завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "Фонову Ñлужбу уÑпішно запущено."
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ read() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "Це PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "Вузол збираннÑ: %s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "CFLAGS збираннÑ: %s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "Запущено на вузлі: %s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "Знайдено %u процеÑорів."
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "Розмір Ñторінки дорівнює %lu байтам"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "Зібрано з підтримкою Valgrind: так"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "Зібрано з підтримкою Valgrind: ні"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "ЗапуÑк у режимі valgrind: %s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "Запущено на вузлі: %s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "Зібрано з оптимізацією: так"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "Зібрано з оптимізацією: ні"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
-msgstr ""
+msgstr "Визначено NDEBUG, вÑÑ– Ð´Ð¾Ð´Ð°Ð²Ð°Ð½Ð½Ñ Ð²Ð¸Ð¼ÐºÐ½ÐµÐ½Ð¾."
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
-msgstr ""
+msgstr "Визначено FASTPATH, вимкнено лише Ð´Ð¾Ð´Ð°Ð²Ð°Ð½Ð½Ñ ÑˆÐ²Ð¸Ð´ÐºÐ¸Ñ… шлÑхів."
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
-msgstr ""
+msgstr "Увімкнено вÑÑ– додаваннÑ."
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "Спроба отримати ідентифікатор ÑиÑтеми завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "Ідентифікатор ÑиÑтеми %s."
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "Ідентифікатор ÑиÑтеми %s."
+msgstr "Ідентифікатор ÑеанÑу — %s."
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "Каталог запуÑку: %s."
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "Каталог Ñтану: %s."
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "Каталог модулів: %s."
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "ЗапуÑку у загальноÑиÑтемному режимі: %s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"Гаразд, ви запуÑтили PA у ÑиÑтемному режимі. Будь лаÑка, зауважте, що "
+"здебільшого у цьому немає потреби.\n"
+"Якщо ви вÑе ж це зробили, відповідальніÑть за вÑÑ– негаразди лÑгає Ñаме на "
+"ваÑ.\n"
+"Будь лаÑка, ознайомтеÑÑ Ð·Ñ– Ñтаттею http://pulseaudio.org/wiki/"
+"WhatIsWrongWithSystemMode, щоб дізнатиÑÑ Ð¿Ñ€Ð¾ те, чому не варто "
+"викориÑтовувати ÑиÑтемний режим."
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_pid_file_create() зазнала невдачі."
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "ДоÑтупні Ñвіжі виÑокоточні таймери! Смачного!"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
@@ -514,33 +421,33 @@ msgstr ""
"Чувак, твоє Ñдро — лайно! Круті пацани рекомендують Linux з увімкненими "
"виÑокоточними таймерами!"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_core_new() зазнала невдачі."
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "Ðе вдалоÑÑ Ñ–Ð½Ñ–Ñ†Ñ–Ð°Ð»Ñ–Ð·ÑƒÐ²Ð°Ñ‚Ð¸ фонову Ñлужбу."
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr ""
"ЗапуÑк фонової Ñлужби без жодного завантаженого модулÑ, Ñлужба не буде "
"працездатною."
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "ЗапуÑк фонової Ñлужби завершено."
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "Ініційовано Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸ фонової Ñлужби."
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "Ð’Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ Ñ„Ð¾Ð½Ð¾Ð²Ð¾Ñ— Ñлужби перервано."
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -698,15 +605,15 @@ msgstr ""
" -n Ðе завантажувати типовий файл "
"Ñкрипту\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --daemonize Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --fail Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -715,53 +622,53 @@ msgstr ""
"(чиÑлове у діапазоні 0..4 або одне зі значень debug, info, notice, warn, "
"error)."
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --high-priority Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --realtime Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr ""
"Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --disallow-module-loading Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --disallow-exit Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --use-pid-file Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "Журнал вказано неправильно: можливі варіанти «syslog», «stderr» і «auto»."
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --log-time Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --log-meta Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "Ðекоректний метод зміни чаÑтотних характериÑтик «%s»."
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --system Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --no-cpu-limit Ñлід вказувати булівÑький аргумент"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "Ð”Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° --disable-shm Ñлід вказувати булівÑький аргумент"
@@ -800,77 +707,87 @@ msgstr "ВикориÑтаннÑ: %s\n"
msgid "Load Once: %s\n"
msgstr "Ð—Ð°Ð²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ Ð¿Ñ€Ð¸: %s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "ПОПЕРЕДЖЕÐÐЯ ПРО ЗÐСТÐРІЛІСТЬ: %s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "ШлÑÑ…: %s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] Ðекоректний журнал «%s»."
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] Ðекоректний рівень Ð¶ÑƒÑ€Ð½Ð°Ð»ÑŽÐ²Ð°Ð½Ð½Ñ Â«%s»."
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] Ðекоректний метод зміни чаÑтотних характериÑтик «%s»."
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] Ðекоректне Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ rlimit «%s»."
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] rlimit не підтримуєтьÑÑ Ð½Ð° цій платформі."
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] Ðекоректний формат фрагмента «%s»."
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] Ðекоректна чаÑтота вибірки «%s»."
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] Ðекоректні канали фрагмента «%s»."
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] Ðекоректна карта каналів «%s»'."
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] Ðекоректна кількіÑть фрагментів «%s»."
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] Ðекоректний розмір фрагмента «%s»."
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] Ðекоректний рівень nice «%s»."
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] Ðекоректна чаÑтота вибірки «%s»."
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "Ðе вдалоÑÑ Ð²Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ð¸ файл налаштувань: %s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
@@ -878,18 +795,14 @@ msgstr ""
"У вказаній типовій карті каналів визначаєтьÑÑ Ñ–Ð½ÑˆÐ° кількіÑть каналів, ніж "
"типова кількіÑть каналів."
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### Прочитано з файла налаштувань: %s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "ПозбуваємоÑÑ Ð¿Ñ€Ð°Ð² доÑтупу root."
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "УÑпішно обмежено можливоÑті до CAP_SYS_NICE."
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "ПозбуваємоÑÑ Ð¿Ñ€Ð°Ð² доÑтупу."
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -899,259 +812,237 @@ msgstr "Звукова ÑиÑтема PulseAudio"
msgid "Start the PulseAudio Sound System"
msgstr "ЗапуÑтити звукову ÑиÑтему PulseAudio"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr ""
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-#, fuzzy
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr ""
-"Спроба Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸ фонової Ñлужби PulseAudio завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-#, fuzzy
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr ""
-"Ми перебуваємо у групі «%s», що надає змогу Ð¿Ð»Ð°Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ð· виÑоким пріоритетом."
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr ""
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "Моно"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "Передній центральний"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "Передній лівий"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "Передній правий"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "Задній центральний"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "Задній лівий"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "Задній правий"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "Джерело низьких чаÑтот"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "Передній лівоцентральний"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "Передній правоцентральний"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "Боковий лівий"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "Боковий правий"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "Допоміжний 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "Допоміжний 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "Допоміжний 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "Допоміжний 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "Допоміжний 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "Допоміжний 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "Допоміжний 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "Допоміжний 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "Допоміжний 8"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "Допоміжний 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "Допоміжний 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "Допоміжний 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "Допоміжний 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "Допоміжний 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "Допоміжний 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "Допоміжний 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "Допоміжний 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "Допоміжний 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "Допоміжний 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "Допоміжний 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "Допоміжний 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "Допоміжний 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "Допоміжний 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "Допоміжний 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "Допоміжний 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "Допоміжний 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "Допоміжний 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "Допоміжний 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "Допоміжний 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "Допоміжний 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "Допоміжний 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "Допоміжний 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "Верхній центральний"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "Верхній передній центральний"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "Верхній передній лівий"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "Верхній передній правий"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "Верхній задній центральний"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "Верхній задній лівий"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "Верхній задній правий"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(некоректний)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "Стерео"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "Об'ємний 4.0"
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "Об'ємний 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "Об'ємний 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "Об'ємний 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "Об'ємний 7.1"
@@ -1255,27 +1146,35 @@ msgstr "ВідÑÑƒÑ‚Ð½Ñ Ñ€ÐµÐ°Ð»Ñ–Ð·Ð°Ñ†Ñ–Ñ"
msgid "Client forked"
msgstr "Клієнт розгалужено"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "Помилка вводу/виводу"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "ПриÑтрій або реÑÑƒÑ€Ñ Ð·Ð°Ð¹Ð½Ñто"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uкан. %uГц"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f ГБ"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f МБ"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f кБ"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u Б"
@@ -1288,199 +1187,193 @@ msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ XOpenDisplay() завершилаÑÑ Ð½
msgid "Failed to parse cookie data"
msgstr "Ðе вдалоÑÑ Ð¾Ð±Ñ€Ð¾Ð±Ð¸Ñ‚Ð¸ дані куки"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "Ðе вдалоÑÑ Ð²Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ð¸ файл Ð½Ð°Ð»Ð°ÑˆÑ‚ÑƒÐ²Ð°Ð½Ð½Ñ Â«%s»: %s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr ""
"Куків не завантажено. Буде виконано Ñпробу Ð·â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ð·Ð° Ñ—Ñ… відÑутноÑті."
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork(): %s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid(): %s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "Отримано Ð¿Ð¾Ð²Ñ–Ð´Ð¾Ð¼Ð»ÐµÐ½Ð½Ñ Ð¿Ñ€Ð¾ невідомий додаток «%s»"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_write() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s\n"
+msgid "Failed to drain stream: %s"
+msgstr "Ðе вдалоÑÑ Ñтворити тунель Ð´Ð»Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ: %s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_peek() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "Потік Ð²Ñ–Ð´Ñ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ñ‚ÑƒÐ½ÐµÐ»ÑŒÐ¾Ð²Ð°Ð½Ð¾."
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "Потік було уÑпішно Ñтворено.\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "Тунельне Ð·â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ð· Ñервером."
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_get_buffer_attr() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "Метрика буфера: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_write() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "Метрика буфера: maxlength=%u, fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_write() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "ВикориÑÑ‚Ð°Ð½Ð½Ñ Ñ‡Ð°Ñтотної Ñпецифікації «%s», карта каналів «%s».\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_peek() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "З’єднано з приÑтроєм %s (%u, %s призупинено).\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "Потік було уÑпішно Ñтворено."
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "Помилка потоку: %s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_get_buffer_attr() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "Призупинено приÑтрій потоку. %s \n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Метрика буфера: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "Відновлено приÑтрій потоку. %s \n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Метрика буфера: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "ÐÐµÐ´Ð¾Ð²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ. %s \n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "ВикориÑÑ‚Ð°Ð½Ð½Ñ Ñ‡Ð°Ñтотної Ñпецифікації «%s», карта каналів «%s»."
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "ÐŸÐµÑ€ÐµÐ²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ. %s \n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "З’єднано з приÑтроєм %s (%u, %s призупинено)."
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "Потік запущено. %s \n"
+msgid "Stream error: %s"
+msgstr "Помилка потоку: %s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "Потік переÑунуто на приÑтрій %s (%u, %s призупинено). %s \n"
-
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "не "
-
-#: ../src/utils/pacat.c:245
-#, fuzzy, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "ÐÐµÐ´Ð¾Ð²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ. %s \n"
+msgid "Stream device suspended.%s"
+msgstr "Призупинено приÑтрій потоку. %s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Connection established.%s \n"
-msgstr "Ð’Ñтановлено з’єднаннÑ. %s \n"
+msgid "Stream device resumed.%s"
+msgstr "Відновлено приÑтрій потоку. %s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_new() зазнала невдачі: %s\n"
+msgid "Stream underrun.%s"
+msgstr "ÐÐµÐ´Ð¾Ð²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ. %s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_connect_playback() зазнала невдачі: %s\n"
+msgid "Stream overrun.%s"
+msgstr "ÐŸÐµÑ€ÐµÐ²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ. %s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_connect_record() зазнала невдачі: %s\n"
+msgid "Stream started.%s"
+msgstr "Потік запущено. %s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "Connection failure: %s\n"
-msgstr "Спроба вÑÑ‚Ð°Ð½Ð¾Ð²Ð»ÐµÐ½Ð½Ñ Ð·â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ð·Ð°Ð·Ð½Ð°Ð»Ð° невдачі: %s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "Потік переÑунуто на приÑтрій %s (%u, %s призупинено). %s"
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
-#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "Ðе вдалоÑÑ Ñтворити тунель Ð´Ð»Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ: %s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "не "
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "Потік Ð²Ñ–Ð´Ñ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ñ‚ÑƒÐ½ÐµÐ»ÑŒÐ¾Ð²Ð°Ð½Ð¾.\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "ÐÐµÐ´Ð¾Ð²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ. %s"
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Тунельне Ð·â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ð· Ñервером.\n"
+msgid "Connection established.%s"
+msgstr "Ð’Ñтановлено з’єднаннÑ. %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Got EOF.\n"
-msgstr "Отримано EOF.\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_new() зазнала невдачі: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain(): %s\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_connect_playback() зазнала невдачі: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "read() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ read() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_connect_record() зазнала невдачі: %s"
-#: ../src/utils/pacat.c:438
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "write() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ write() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s\n"
+msgid "Connection failure: %s"
+msgstr "Спроба вÑÑ‚Ð°Ð½Ð¾Ð²Ð»ÐµÐ½Ð½Ñ Ð·â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ð·Ð°Ð·Ð½Ð°Ð»Ð° невдачі: %s"
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "Отримано EOF."
+
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "Отримано Ñигнал, Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸.\n"
+msgid "write() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ write() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "Отримано Ñигнал, Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸."
-#: ../src/utils/pacat.c:473
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ латентніÑть: %s\n"
+msgid "Failed to get latency: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ латентніÑть: %s"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "ЧаÑ: %0.3f Ñек.; ЛатентніÑть: %0.0f мкÑ. \r"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "ЧаÑ: %0.3f Ñек.; ЛатентніÑть: %0.0f мкÑ."
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:620
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
+msgid "pa_stream_update_timing_info() failed: %s"
msgstr ""
-"Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_update_timing_info() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s\n"
+"Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_stream_update_timing_info() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/utils/pacat.c:511
-#, c-format
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1506,8 +1399,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1530,6 +1425,15 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [параметри]\n"
"\n"
@@ -1577,8 +1481,16 @@ msgstr ""
"латентніÑть у байтах.\n"
" --process-time=БÐЙТИ ÐадіÑлати запит щодо вказаного чаÑу "
"обробки на запит у байтах.\n"
+" --property=ВЛÐСТИВІСТЬ=ЗÐÐЧЕÐÐЯ Ð’Ñтановити Ð´Ð»Ñ Ð²ÐºÐ°Ð·Ð°Ð½Ð¾Ñ— влаÑтивоÑті "
+"вказане значеннÑ.\n"
+" --raw ЗапиÑати/Відтворити не оброблені "
+"дані PCM.\n"
+" --file-format=ФОРМÐТ ЗапиÑати/Відтворити форматовані дані "
+"PCM.\n"
+" --list-file-formats Показати ÑпиÑок можливих форматів "
+"файлів.\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1589,131 +1501,174 @@ msgstr ""
"Зібрано з libpulse %s\n"
"З’єднано з libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "Ðекоректна карта каналів «%s»\n"
+msgid "Invalid client name '%s'"
+msgstr "Ðекоректна назва клієнта «%s»"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "Ðекоректна ÑÐ¿ÐµÑ†Ð¸Ñ„Ñ–ÐºÐ°Ñ†Ñ–Ñ Ð»Ð°Ñ‚ÐµÐ½Ñ‚Ð½Ð¾Ñті «%s»\n"
+msgid "Invalid stream name '%s'"
+msgstr "Ðекоректна назва потоку «%s»"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "Ðекоректна чаÑова ÑÐ¿ÐµÑ†Ð¸Ñ„Ñ–ÐºÐ°Ñ†Ñ–Ñ Â«%s»\n"
+msgid "Invalid channel map '%s'"
+msgstr "Ðекоректна карта каналів «%s»"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "Ðекоректна чаÑтотна ÑпецифікаціÑ\n"
+msgid "Invalid latency specification '%s'"
+msgstr "Ðекоректна ÑÐ¿ÐµÑ†Ð¸Ñ„Ñ–ÐºÐ°Ñ†Ñ–Ñ Ð»Ð°Ñ‚ÐµÐ½Ñ‚Ð½Ð¾Ñті «%s»"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "Карта каналі не відповідає чаÑтотній Ñпецифікації\n"
+msgid "Invalid process time specification '%s'"
+msgstr "Ðекоректна чаÑова ÑÐ¿ÐµÑ†Ð¸Ñ„Ñ–ÐºÐ°Ñ†Ñ–Ñ Â«%s»"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "Ð’Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ñ‚Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ %s з чаÑтотною Ñпецифікацією «%s».\n"
+msgid "Invalid property '%s'"
+msgstr "Ðекоректна влаÑтивіÑть «%s»"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "запиÑ"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "Ðевідомий формат файлів %s."
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "відтвореннÑ"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "Ðекоректна чаÑтотна ÑпецифікаціÑ"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open(): %s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2(): %s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "Забагато аргументів.\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "Забагато аргументів."
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_mainloop_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "Ðе вдалоÑÑ Ñтворити чаÑтотну Ñпецифікацію Ð´Ð»Ñ Ñ„Ð°Ð¹Ð»Ð°."
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ io_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "Ðе вдалоÑÑ Ð²Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ð¸ звуковий файл."
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_context_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr ""
+"ПопередженнÑ: вказану чаÑтотну Ñпецифікацію буде перезапиÑано Ñпецифікацією "
+"з файла."
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_context_connect() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо чаÑтотної Ñпецифікації з файла."
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "ПопередженнÑ: не вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо карти каналів з файла."
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "Карта каналів не відповідає чаÑтотній Ñпецифікації"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "ПопередженнÑ: не вдалоÑÑ Ð·Ð°Ð¿Ð¸Ñати карту каналів до файла."
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ time_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr ""
+"Ð’Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ñ‚Ñ Ð¿Ð¾Ñ‚Ð¾ÐºÑƒ %s з чаÑтотною Ñпецифікацією «%s» Ñ– картою каналів «%s»."
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "запиÑ"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "відтвореннÑ"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_mainloop_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ io_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_context_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_mainloop_run() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_context_connect() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_context_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_mainloop_run() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork(): %s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp(): %s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "Ðевдала Ñпроба призупинки: %s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "Ðевдала Ñпроба відновленнÑ: %s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr ""
"ПОПЕРЕДЖЕÐÐЯ: звуковий Ñервер не Ñ” локальним, його не можна призупинити.\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "Спроба вÑÑ‚Ð°Ð½Ð¾Ð²Ð»ÐµÐ½Ð½Ñ Ð·â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ð·Ð°Ð·Ð½Ð°Ð»Ð° невдачі: %s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "Отримано Ñигнал SIGINT, Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸.\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr ""
"ПОПЕРЕДЖЕÐÐЯ: Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ Ð´Ð¾Ñ‡Ñ–Ñ€Ð½ÑŒÐ¾Ð³Ð¾ процеÑу було перервано з Ñигналом %u\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1732,7 +1687,7 @@ msgstr ""
"з’єднатиÑÑ\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1743,36 +1698,62 @@ msgstr ""
"Зібрано з libpulse %s\n"
"З’єднано з libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ ÑтатиÑтичні дані: %s\n"
+msgid "pa_mainloop_new() failed.\n"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_mainloop_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_context_new() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_mainloop_run() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾.\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ ÑтатиÑтичні дані: %s"
+
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "Зараз викориÑтано: %u блоків, що міÑÑ‚Ñть загалом %s байтів.\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr ""
"Виділено протÑгом Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ Ð·Ð°Ð³Ð°Ð»Ð¾Ð¼: %u блоків, що міÑÑ‚Ñть %s байтів.\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "Розмір кешу фрагментів: %s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо Ñервера: %s\n"
+msgid "Failed to get server information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо Ñервера: %s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1780,7 +1761,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"КориÑтувач: %s\n"
"Ðазва вузла: %s\n"
@@ -1792,12 +1773,12 @@ msgstr ""
"Типове джерело: %s\n"
"Кука: %08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо приймача: %s\n"
+msgid "Failed to get sink information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо приймача: %s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1836,12 +1817,22 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо джерела: %s\n"
+msgid "\tPorts:\n"
+msgstr "\tПорти:\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tÐктивний порт: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо джерела: %s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1880,20 +1871,20 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "н/д"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо модулÑ: %s\n"
+msgid "Failed to get module information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо модулÑ: %s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1910,12 +1901,12 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо клієнта: %s\n"
+msgid "Failed to get client information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо клієнта: %s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1930,12 +1921,12 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо карти: %s\n"
+msgid "Failed to get card information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо карти: %s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1952,22 +1943,22 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tПрофілі:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tÐктивний профіль: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ відомоÑтей щодо приймача: %s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ відомоÑтей щодо приймача: %s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -2004,12 +1995,12 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо Ð²Ñ–Ð´Ñ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ð´Ð¶ÐµÑ€ÐµÐ»Ð°: %s\n"
+msgid "Failed to get source output information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо Ð²Ñ–Ð´Ñ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ð´Ð¶ÐµÑ€ÐµÐ»Ð°: %s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -2038,12 +2029,12 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо фрагмента: %s\n"
+msgid "Failed to get sample information: %s"
+msgstr "Ðе вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо фрагмента: %s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -2074,23 +2065,80 @@ msgstr ""
"\tВлаÑтивоÑті:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "Помилка: %s\n"
+msgid "Failure: %s"
+msgstr "Помилка: %s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "Ðе вдалоÑÑ Ð²Ð¸Ð²Ð°Ð½Ñ‚Ð°Ð¶Ð¸Ñ‚Ð¸ зразок: %s\n"
+msgid "Failed to upload sample: %s"
+msgstr "Ðе вдалоÑÑ Ð²Ð¸Ð²Ð°Ð½Ñ‚Ð°Ð¶Ð¸Ñ‚Ð¸ зразок: %s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "ПередчаÑне Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ„Ð°Ð¹Ð»Ð°\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "ПередчаÑне Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ„Ð°Ð¹Ð»Ð°"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "Ðекоректний Ñервер"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "Отримано Ñигнал SIGINT, Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸."
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2098,13 +2146,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2124,9 +2181,17 @@ msgstr ""
"%s [параметри] move-source-output ІДЕÐТИФІКÐТОР ДЖЕРЕЛО\n"
"%s [параметри] load-module ÐÐЗВР[ÐРГУМЕÐТИ ...]\n"
"%s [параметри] unload-module ІДЕÐТИФІКÐТОР\n"
-"%s [параметри] suspend-sink [ПРИЙМÐЧ] 1|0\n"
-"%s [параметри] suspend-source [ДЖЕРЕЛО] 1|0\n"
-"%s [параметри] set-card-profile [КÐРТÐ] [ПРОФІЛЬ] \n"
+"%s [параметри] suspend-sink ПРИЙМÐЧ 1|0\n"
+"%s [параметри] suspend-source ДЖЕРЕЛО 1|0\n"
+"%s [параметри] set-card-profile КÐРТРПРОФІЛЬ \n"
+"%s [параметри] set-sink-port ПРИЙМÐЧ ПОРТ \n"
+"%s [параметри] set-source-port ДЖЕРЕЛО ПОРТ\n"
+"%s [параметри] set-sink-volume ПРИЙМÐЧ ГУЧÐІСТЬ\n"
+"%s [параметри] set-source-volume ДЖЕРЕЛО ГУЧÐІСТЬ\n"
+"%s [параметри] set-sink-input-volume ВХІДПРИЙМÐЧРГУЧÐІСТЬ\n"
+"%s [параметри] set-sink-mute ПРИЙМÐЧ 1|0\n"
+"%s [параметри] set-source-mute ДЖЕРЕЛО 1|0\n"
+"%s [параметри] set-sink-input-mute ВХІДПРИЙМÐЧР1|0\n"
"\n"
" -h, --help Показати цю довідку\n"
" --version Показати дані щодо верÑÑ–Ñ—\n"
@@ -2135,7 +2200,7 @@ msgstr ""
"з’єднатиÑÑ\n"
" -n, --client-name=ÐÐЗВРСпоÑіб виклику клієнта на Ñервері\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2146,78 +2211,114 @@ msgstr ""
"Зібрано з libpulse %s\n"
"З’єднано з libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "Будь лаÑка, вкажіть зразковий файл Ð´Ð»Ñ Ð·Ð°Ð²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "Будь лаÑка, вкажіть зразковий файл Ð´Ð»Ñ Ð·Ð°Ð²Ð°Ð½Ñ‚Ð°Ð¶ÐµÐ½Ð½Ñ"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "Ðе вдалоÑÑ Ð²Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ð¸ звуковий файл.\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "Ðе вдалоÑÑ Ð²Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ð¸ звуковий файл."
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "Вам Ñлід вказати назву зразкового файла, Ñкий Ñлід відтворити\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr ""
+"ПопередженнÑ: не вдалоÑÑ Ð¾Ñ‚Ñ€Ð¸Ð¼Ð°Ñ‚Ð¸ дані щодо чаÑтотної Ñпецифікації з файла."
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "Вам Ñлід вказати назву зразкового файла, Ñкий Ñлід вилучити\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "Вам Ñлід вказати назву зразкового файла, Ñкий Ñлід відтворити"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð¿Ñ€Ð¸Ð¹Ð¼Ð°Ñ‡Ð° даних Ñ– приймач\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "Вам Ñлід вказати назву зразкового файла, Ñкий Ñлід вилучити"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð´Ð¶ÐµÑ€ÐµÐ»Ð° Ð²Ñ–Ð´Ñ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ñ– джерело\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð¿Ñ€Ð¸Ð¹Ð¼Ð°Ñ‡Ð° даних Ñ– приймач"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "Вам Ñлід вказати назву Ð¼Ð¾Ð´ÑƒÐ»Ñ Ñ– аргументи.\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð´Ð¶ÐµÑ€ÐµÐ»Ð° Ð²Ñ–Ð´Ñ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ñ– джерело"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð¼Ð¾Ð´ÑƒÐ»Ñ\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "Вам Ñлід вказати назву Ð¼Ð¾Ð´ÑƒÐ»Ñ Ñ– аргументи."
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð¼Ð¾Ð´ÑƒÐ»Ñ"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
+"You may not specify more than one sink. You have to specify a boolean value."
msgstr ""
"Ðе можна вказувати більше одного приймача. Вам Ñлід вказати булівÑьке "
-"значеннÑ.\n"
+"значеннÑ."
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
+"value."
msgstr ""
"Ðе можна вказувати більше одного джерела. Вам Ñлід вказати булівÑьке "
-"значеннÑ.\n"
+"значеннÑ."
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ ÐºÐ°Ñ€Ñ‚Ð¸ Ñ– назву профілю\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ ÐºÐ°Ñ€Ñ‚Ð¸ Ñ– назву профілю"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "Ðе вказано коректної команди.\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ Ð¿Ñ€Ð¸Ð¹Ð¼Ð°Ñ‡Ð° Ñ– назву порту"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "Спроба Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ pa_context_connect() завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾: %s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ Ð´Ð¶ÐµÑ€ÐµÐ»Ð° Ñ– назву порту"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ Ð¿Ñ€Ð¸Ð¹Ð¼Ð°Ñ‡Ð° Ñ– гучніÑть"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "Ðекоректна ÑÐ¿ÐµÑ†Ð¸Ñ„Ñ–ÐºÐ°Ñ†Ñ–Ñ Ð³ÑƒÑ‡Ð½Ð¾Ñті"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ Ð´Ð¶ÐµÑ€ÐµÐ»Ð° Ñ– гучніÑть"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð¿Ñ€Ð¸Ð¹Ð¼Ð°Ñ‡Ð° даних Ñ– гучніÑть"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "Ðекоректний Ñ–Ð½Ð´ÐµÐºÑ Ð²Ñ…Ñ–Ð´Ð½Ð¸Ñ… даних приймача"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+"Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ Ð¿Ñ€Ð¸Ð¹Ð¼Ð°Ñ‡Ð° Ñ– булеве Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ Ð²Ð¸Ð¼Ð¸ÐºÐ°Ð½Ð½Ñ Ð·Ð²ÑƒÐºÑƒ"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr ""
+"Вам Ñлід вказати назву/Ñ–Ð½Ð´ÐµÐºÑ Ð´Ð¶ÐµÑ€ÐµÐ»Ð° Ñ– булеве Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ Ð²Ð¸Ð¼Ð¸ÐºÐ°Ð½Ð½Ñ Ð·Ð²ÑƒÐºÑƒ"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+"Вам Ñлід вказати Ñ–Ð½Ð´ÐµÐºÑ Ð¿Ñ€Ð¸Ð¹Ð¼Ð°Ñ‡Ð° даних Ñ– булеве Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ Ð²Ð¸Ð¼Ð¸ÐºÐ°Ð½Ð½Ñ Ð·Ð²ÑƒÐºÑƒ"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "Ðекоректна ÑÐ¿ÐµÑ†Ð¸Ñ„Ñ–ÐºÐ°Ñ†Ñ–Ñ Ñ–Ð½Ð´ÐµÐºÑу приймача даних"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "Ðе вказано коректної команди."
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2300,130 +2401,51 @@ msgstr "Ðе вдалоÑÑ Ð·Ð°Ð²Ð°Ð½Ñ‚Ð°Ð¶Ð¸Ñ‚Ð¸ дані куки\n"
msgid "Not yet implemented.\n"
msgstr "Ще не реалізовано.\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+"Фонову Ñлужбу PulseAudio не запущено, або цю Ñлужбу не запущено Ñк фонову "
+"Ñлужбу ÑеанÑу."
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0): %s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect(): %s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr ""
"Спроба Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð½Ñ Ñ€Ð¾Ð±Ð¾Ñ‚Ð¸ фонової Ñлужби PulseAudio завершилаÑÑ Ð½ÐµÐ²Ð´Ð°Ð»Ð¾."
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "Фонова Ñлужба не відповідає."
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select(): %s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read(): %s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write(): %s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "Потік було уÑпішно Ñтворено\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "Помилка потоку: %s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "Ð—â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ð²Ñтановлено.\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [параметри] [ФÐЙЛ]\n"
-"\n"
-" -h, --help Показати цю довідку\n"
-" --version Показати дані щодо верÑÑ–Ñ—\n"
-"\n"
-" -v, --verbose Увімкнути докладний режим дій\n"
-"\n"
-" -s, --server=СЕРВЕР Ðазва Ñервера, з Ñким Ñлід "
-"вÑтановити Ð·â€™Ñ”Ð´Ð½Ð°Ð½Ð½Ñ to\n"
-" -d, --device=ПРИСТРІЙ Ðазва приймача, з Ñким Ñлід "
-"з’єднатиÑÑ\n"
-" -n, --client-name=ÐÐЗВРСпоÑіб виклику клієнта на Ñервері\n"
-" --stream-name=ÐÐЗВРСпоÑіб виклику потоку на Ñервері\n"
-" --volume=ГУЧÐІСТЬ Ð—Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ Ð¿Ð¾Ñ‡Ð°Ñ‚ÐºÐ¾Ð²Ð¾Ñ— (лінійної) "
-"гучноÑті у діапазоні 0..65536\n"
-" --channel-map=КÐРТÐ_КÐÐÐЛІВ Ð’Ð¸Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ ÐºÐ°Ñ€Ñ‚Ð¸ каналів, Ñкою Ñлід "
-"ÑкориÑтатиÑÑ\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Зібрано з libpulse %s\n"
-"З’єднано з libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "Ðекоректна карта каналів\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "Ðе вдалоÑÑ Ð²Ñ–Ð´ÐºÑ€Ð¸Ñ‚Ð¸ файл «%s»\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "Карта каналів не відповідає файлові.\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "ВикориÑÑ‚Ð°Ð½Ð½Ñ Ñ‡Ð°Ñтотної Ñпецифікації «%s»\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "Ðе вдалоÑÑ Ð·Ð½Ñти Ð±Ð»Ð¾ÐºÑƒÐ²Ð°Ð½Ð½Ñ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡Ð½Ð¾Ð³Ð¾ розгалуженнÑ."
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2433,8 +2455,14 @@ msgid ""
"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA викликала Ñлужбу запиÑу нових даних на приÑтрій, але наÑправді ніÑких "
+"даних Ð´Ð»Ñ Ð·Ð°Ð¿Ð¸Ñу не виÑвлено!\n"
+"Ймовірно, це пов’Ñзано з вадою у драйвері ALSA «%s». Будь лаÑка, повідомте "
+"про цю ваду розробникам ALSA.\n"
+"Службу було викликано зі вÑтановленим POLLOUT, але наÑтупний виклик "
+"snd_pcm_avail() повернув 0 або інше Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ < min_avail."
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2444,36 +2472,266 @@ msgid ""
"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
"returned 0 or another value < min_avail."
msgstr ""
+"ALSA викликала Ñлужбу Ñ‡Ð¸Ñ‚Ð°Ð½Ð½Ñ Ð½Ð¾Ð²Ð¸Ñ… даних з приÑтрою, але наÑправді ніÑких "
+"даних Ð´Ð»Ñ Ñ‡Ð¸Ñ‚Ð°Ð½Ð½Ñ Ð½Ðµ виÑвлено!\n"
+"Ймовірно, це пов’Ñзано з вадою у драйвері ALSA «%s». Будь лаÑка, повідомте "
+"про цю ваду розробникам ALSA.\n"
+"Службу було викликано зі вÑтановленим POLLIN, але наÑтупний виклик "
+"snd_pcm_avail() повернув 0 або інше Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ < min_avail."
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "Вимкнено"
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr ""
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "ВиÑокоточне Ð²Ñ–Ð´Ñ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ (A2DP)"
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr ""
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "ВиÑокоточне Ð·Ð°Ñ…Ð¾Ð¿Ð»ÐµÐ½Ð½Ñ (A2DP)"
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr ""
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "Телефонний Ð´ÑƒÐ¿Ð»ÐµÐºÑ (HSP/HFP)"
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
-msgid "Off"
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
msgstr ""
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
-msgid "High Fidelity Playback (A2DP)"
-msgstr ""
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "Звуковий Ñервер PulseAudio"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
-msgid "Telephony Duplex (HSP/HFP)"
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "ПриÑтрої відтвореннÑ"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "ПриÑтрої отриманнÑ"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "Звук на @ÐÐЗВÐВУЗЛÐ@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "Вхід"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "Вхідний канал Ñтикувальної Ñтанції"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "Мікрофон Ñтикувальної Ñтанції"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Лінійний вхід"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "Мікрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "Зовнішній мікрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "Вбудований мікрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "Радіо"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "Відео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "Ðвтоматичне ÐºÐµÑ€ÑƒÐ²Ð°Ð½Ð½Ñ Ð¿Ñ–Ð´ÑиленнÑм"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "Без автоматичного ÐºÐµÑ€ÑƒÐ²Ð°Ð½Ð½Ñ Ð¿Ñ–Ð´ÑиленнÑм"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "ПідÑиленнÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "Без піÑиленнÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "ПідÑилювач"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "Без підÑилювача"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "ПідÑиленнÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "Без піÑиленнÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
msgstr ""
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/alsa/alsa-mixer.c:1719
#, fuzzy
-msgid "PulseAudio Sound Server"
-msgstr "Звукова ÑиÑтема PulseAudio"
+msgid "Headphones"
+msgstr "Ðналогові навушники"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "Ðналогових вхід"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "Ðналоговий мікрофон"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "Ðналоговий лінійний вхід"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "Ðналогове радіо"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "Ðналогове відео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "Ðналогове відтвореннÑ"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "Ðналогові навушники"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "Ðналоговий вихід (Ñабвуфер)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "Ðналоговий моно-вихід"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "Ðналогове Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "Ðналогове моно"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "Ðналогове Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "Ðналоговий об'ємний 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "Ðналоговий об'ємний 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "Ðналоговий об'ємний 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "Ðналоговий об'ємний 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "Ðналоговий об'ємний 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "Ðналоговий об'ємний 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "Ðналоговий об'ємний 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "Ðналоговий об'ємний 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "Ðналоговий об'ємний 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "Ðналоговий об'ємний 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "Ðналоговий об'ємний 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "Цифрове Ñтерео (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "Цифровий об’ємний 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "Цифровий об’ємний 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "Цифровий об’ємний 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "Цифровий Ñтерео (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "Ðналогове двобічне моно"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "Ðналогове двобічне Ñтерео"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "Цифрове двобічне Ñтерео (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "Джерело низьких чаÑтот"
diff --git a/po/zh_CN.po b/po/zh_CN.po
index 03becccf..337f2b5d 100644
--- a/po/zh_CN.po
+++ b/po/zh_CN.po
@@ -11,8 +11,8 @@ msgid ""
msgstr ""
"Project-Id-Version: pulseaudio.master-tx\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-04-21 23:02+0200\n"
-"PO-Revision-Date: 2009-04-06 10:26+1000\n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2009-12-09 12:54+1000\n"
"Last-Translator: Leah Liu <lliu@redhat.com>\n"
"Language-Team: Simplified Chinese <zh@li.org>\n"
"MIME-Version: 1.0\n"
@@ -20,51 +20,12 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: KBabel 1.11.4\n"
-#: ../src/modules/alsa/alsa-util.c:532
-msgid "Analog Mono"
-msgstr "模拟å•声é“"
-
-#: ../src/modules/alsa/alsa-util.c:540
-msgid "Analog Stereo"
-msgstr "模拟立体声"
-
-#: ../src/modules/alsa/alsa-util.c:548
-msgid "Digital Stereo (IEC958)"
-msgstr "数字立体声(IEC958)"
-
-#: ../src/modules/alsa/alsa-util.c:556
-msgid "Digital Stereo (HDMI)"
-msgstr "数字立体声(HDMI)"
-
-#: ../src/modules/alsa/alsa-util.c:565
-msgid "Analog Surround 4.0"
-msgstr "模拟环绕 4.0"
-
-#: ../src/modules/alsa/alsa-util.c:574
-msgid "Digital Surround 4.0 (IEC958/AC3)"
-msgstr "数字环绕 4.0(IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:584
-msgid "Analog Surround 4.1"
-msgstr "模拟环绕 4.1"
-
-#: ../src/modules/alsa/alsa-util.c:594
-msgid "Analog Surround 5.0"
-msgstr "模拟环绕 5.0"
-
-#: ../src/modules/alsa/alsa-util.c:604
-msgid "Analog Surround 5.1"
-msgstr "模拟环绕 5.1"
-
-#: ../src/modules/alsa/alsa-util.c:614
-msgid "Digital Surround 5.1 (IEC958/AC3)"
-msgstr "数字环绕 5.1(IEC958/AC3)"
-
-#: ../src/modules/alsa/alsa-util.c:625
-msgid "Analog Surround 7.1"
-msgstr "模拟环绕 7.1"
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
-#: ../src/modules/alsa/alsa-util.c:1646
+#: ../src/modules/alsa/alsa-util.c:1109
#, c-format
msgid ""
"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
@@ -75,7 +36,7 @@ msgstr ""
"snd_pcm_avail() 返回的值éžå¸¸å¤§ï¼š%lu 字节(%lu ms)。\n"
"很å¯èƒ½æ˜¯ ALSA é©±åŠ¨ç¨‹åº '%s' 中的 bugã€‚è¯·å‘ ALSA å¼€å‘者举报这个问题。"
-#: ../src/modules/alsa/alsa-util.c:1687
+#: ../src/modules/alsa/alsa-util.c:1150
#, c-format
msgid ""
"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
@@ -86,7 +47,7 @@ msgstr ""
"snd_pcm_delay() 返回的值éžå¸¸å¤§ï¼š%li 字节(%s%lu ms)。\n"
"很å¯èƒ½æ˜¯ ALSA é©±åŠ¨ç¨‹åº '%s' 中的 bugã€‚è¯·å‘ ALSA å¼€å‘者举报这个问题。"
-#: ../src/modules/alsa/alsa-util.c:1734
+#: ../src/modules/alsa/alsa-util.c:1197
#, c-format
msgid ""
"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
@@ -97,11 +58,45 @@ msgstr ""
"snd_pcm_mmap_begin() 返回的值éžå¸¸å¤§ï¼š%lu 字节(%lu ms)。\n"
"很å¯èƒ½æ˜¯ ALSA é©±åŠ¨ç¨‹åº '%s' 中的 bugã€‚è¯·å‘ ALSA å¼€å‘者举报这个问题。"
-#: ../src/pulsecore/sink.c:2141
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr "æ€»æ˜¯ä¿æŒè‡³å°‘载入一个æ¼ï¼Œå³ä½¿å®ƒæ˜¯ç©ºçš„"
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "å‡è¾“出"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr "虚拟 LDASPA æ¼"
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "定时的空æ¼"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "空输出"
+
+#: ../src/pulsecore/sink.c:2615
msgid "Internal Audio"
msgstr "内部音频"
-#: ../src/pulsecore/sink.c:2147
+#: ../src/pulsecore/sink.c:2620
msgid "Modem"
msgstr "调制解调器"
@@ -117,400 +112,319 @@ msgstr "åˆ†é…æ–°çš„ dl 加载器失败。"
msgid "Failed to add bind-now-loader."
msgstr "添加 bind-now-loader 失败。"
-#: ../src/daemon/polkit.c:55
-#, c-format
-msgid "Cannot connect to system bus: %s"
-msgstr "无法连接到系统总线:%s"
-
-#: ../src/daemon/polkit.c:65
-#, c-format
-msgid "Cannot get caller from PID: %s"
-msgstr "无法从PID获å–调用者:%s"
-
-#: ../src/daemon/polkit.c:77
-msgid "Cannot set UID on caller object."
-msgstr "无法为调用者设定UID。"
-
-#: ../src/daemon/polkit.c:82
-msgid "Failed to get CK session."
-msgstr "获å–CK会è¯å¤±è´¥ã€‚"
-
-#: ../src/daemon/polkit.c:90
-msgid "Cannot set UID on session object."
-msgstr "无法为会è¯å¯¹è±¡è®¾å®šUID。"
-
-#: ../src/daemon/polkit.c:95
-msgid "Cannot allocate PolKitAction."
-msgstr "ä¸èƒ½åˆ†é…PolKitAction。"
-
-#: ../src/daemon/polkit.c:100
-msgid "Cannot set action_id"
-msgstr "无法设定action_id"
-
-#: ../src/daemon/polkit.c:105
-msgid "Cannot allocate PolKitContext."
-msgstr "无法分é…PolKitContext。"
-
-#: ../src/daemon/polkit.c:110
-#, c-format
-msgid "Cannot initialize PolKitContext: %s"
-msgstr "无法åˆä½¿åŒ–PolKitContext: %s"
-
-#: ../src/daemon/polkit.c:119
-#, c-format
-msgid "Could not determine whether caller is authorized: %s"
-msgstr "无法判断调用者是å¦å·²èŽ·å¾—æŽˆæƒ: %s"
-
-#: ../src/daemon/polkit.c:139
-#, c-format
-msgid "Cannot obtain auth: %s"
-msgstr "æ— æ³•èŽ·å–æŽˆæƒ: %s"
-
-#: ../src/daemon/polkit.c:148
-#, c-format
-msgid "PolicyKit responded with '%s'"
-msgstr "PolicyKit回å¤'%s'"
-
-#: ../src/daemon/main.c:138
+#: ../src/daemon/main.c:146
#, c-format
msgid "Got signal %s."
msgstr "获得信å·%s"
-#: ../src/daemon/main.c:165
+#: ../src/daemon/main.c:173
msgid "Exiting."
msgstr "退出"
-#: ../src/daemon/main.c:183
+#: ../src/daemon/main.c:191
#, c-format
msgid "Failed to find user '%s'."
msgstr "找ä¸åˆ°ç”¨æˆ· `%s' "
-#: ../src/daemon/main.c:188
+#: ../src/daemon/main.c:196
#, c-format
msgid "Failed to find group '%s'."
msgstr "找ä¸åˆ°ç”¨æˆ·ç»„ `%s'"
-#: ../src/daemon/main.c:192
+#: ../src/daemon/main.c:200
#, c-format
msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
msgstr "å‘现用户'%s' (UID %lu)和组'%s' (GID %lu)."
-#: ../src/daemon/main.c:197
+#: ../src/daemon/main.c:205
#, c-format
msgid "GID of user '%s' and of group '%s' don't match."
msgstr "用户'%s'与组'%s'çš„GIDä¸åŒ¹é…."
-#: ../src/daemon/main.c:202
+#: ../src/daemon/main.c:210
#, c-format
msgid "Home directory of user '%s' is not '%s', ignoring."
msgstr "用户'%s'çš„ä¸»æ–‡ä»¶å¤¹ä¸æ˜¯'%s',忽略。"
-#: ../src/daemon/main.c:205 ../src/daemon/main.c:210
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
#, c-format
msgid "Failed to create '%s': %s"
msgstr "创建'%s'失败: %s"
-#: ../src/daemon/main.c:217
+#: ../src/daemon/main.c:225
#, c-format
msgid "Failed to change group list: %s"
msgstr "更改组列表失败:%s"
-#: ../src/daemon/main.c:233
+#: ../src/daemon/main.c:241
#, c-format
msgid "Failed to change GID: %s"
msgstr "更改GID失败:%s"
-#: ../src/daemon/main.c:249
+#: ../src/daemon/main.c:257
#, c-format
msgid "Failed to change UID: %s"
msgstr "更改UID失败:%s"
-#: ../src/daemon/main.c:263
+#: ../src/daemon/main.c:276
msgid "Successfully dropped root privileges."
msgstr "æˆåŠŸæ”¾å¼ƒrootæƒé™ã€‚"
-#: ../src/daemon/main.c:271
+#: ../src/daemon/main.c:284
msgid "System wide mode unsupported on this platform."
msgstr "此平å°ä¸æ”¯æŒsystem-wide模å¼ã€‚"
-#: ../src/daemon/main.c:289
+#: ../src/daemon/main.c:302
#, c-format
msgid "setrlimit(%s, (%u, %u)) failed: %s"
msgstr "setrlimit(%s, (%u, %u)) 失败:%s"
-#: ../src/daemon/main.c:477
+#: ../src/daemon/main.c:502
msgid "Failed to parse command line."
msgstr "分æžå‘½ä»¤è¡Œå¤±è´¥ã€‚"
-#: ../src/daemon/main.c:501
-#, c-format
-msgid "We're in the group '%s', allowing high-priority scheduling."
-msgstr "我们在'%s'组中,å…许高优先级调度。"
-
-#: ../src/daemon/main.c:508
-#, c-format
-msgid "We're in the group '%s', allowing real-time scheduling."
-msgstr "我们在'%s'组中,å…许实时调度。"
-
-#: ../src/daemon/main.c:516
-msgid "PolicyKit grants us acquire-high-priority privilege."
-msgstr "PolicyKit授予我们“获å–é«˜ä¼˜å…ˆçº§â€æƒé™ã€‚"
-
-#: ../src/daemon/main.c:519
-msgid "PolicyKit refuses acquire-high-priority privilege."
-msgstr "PolicyKitæ‹’ç»â€œèŽ·å–é«˜ä¼˜å…ˆçº§â€æƒé™ã€‚"
-
-#: ../src/daemon/main.c:524
-msgid "PolicyKit grants us acquire-real-time privilege."
-msgstr "PolicyKit授予我们“获å–å®žæ—¶â€æƒé™ã€‚"
-
-#: ../src/daemon/main.c:527
-msgid "PolicyKit refuses acquire-real-time privilege."
-msgstr "PolicyKitæ‹’ç»æˆ‘们“获å–å®žæ—¶â€æƒé™ã€‚"
-
-#: ../src/daemon/main.c:556
-#, c-format
+#: ../src/daemon/main.c:535
msgid ""
-"Called SUID root and real-time and/or high-priority scheduling was requested "
-"in the configuration. However, we lack the necessary privileges:\n"
-"We are not in group '%s', PolicyKit refuse to grant us the requested "
-"privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource "
-"limits.\n"
-"For enabling real-time/high-priority scheduling please acquire the "
-"appropriate PolicyKit privileges, or become a member of '%s', or increase "
-"the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
msgstr ""
-"é…置中需è¦è°ƒç”¨ SUID rootã€å®žæ—¶å’Œ/或者高优先调度。但是我们缺少必è¦çš„特æƒï¼š\n"
-"我们ä¸å±žäºŽç»„群 '%s',PolicyKit æ‹’ç»èµ‹äºˆæˆ‘ä»¬è¦æ±‚的特æƒï¼Œè€Œæˆ‘们无法增加 "
-"RLIMIT_NICE/RLIMIT_RTPRIO 资æºé™åˆ¶ã€‚\n"
-"è¦å¯ç”¨å®žæ—¶/高优先调度,请获得适当的 PolicyKit 特æƒï¼Œæˆ–者æˆä¸º '%s' æˆå‘˜ï¼Œä¹Ÿå¯"
-"以为这个用户增加 RLIMIT_NICE/RLIMIT_RTPRIO 资æºé™åˆ¶ã€‚"
-
-#: ../src/daemon/main.c:581
-msgid ""
-"High-priority scheduling enabled in configuration but not allowed by policy."
-msgstr "é…置中已å¯ç”¨é«˜ä¼˜å…ˆçº§è°ƒåº¦ï¼Œä½†ç­–略未å…许。"
-
-#: ../src/daemon/main.c:610
-msgid "Successfully increased RLIMIT_RTPRIO"
-msgstr "æé«˜RLIMIT_RTPRIOæˆåŠŸã€‚"
-
-#: ../src/daemon/main.c:613
-#, c-format
-msgid "RLIMIT_RTPRIO failed: %s"
-msgstr "RLIMIT_RTPRIO失败:%s"
-
-#: ../src/daemon/main.c:620
-msgid "Giving up CAP_NICE"
-msgstr "正在放弃CAP_NICE"
-
-#: ../src/daemon/main.c:627
-msgid ""
-"Real-time scheduling enabled in configuration but not allowed by policy."
-msgstr "é…置中已å¯ç”¨å®žæ—¶è°ƒåº¦ï¼Œä½†ç­–略未å…许。"
-#: ../src/daemon/main.c:688
+#: ../src/daemon/main.c:617
msgid "Daemon not running"
msgstr "åŽå°ç¨‹åºæ²¡æœ‰è¿è¡Œ"
-#: ../src/daemon/main.c:690
+#: ../src/daemon/main.c:619
#, c-format
msgid "Daemon running as PID %u"
msgstr "åŽå°ç¨‹åºæ­£åœ¨è¿è¡Œï¼ŒPID %u"
-#: ../src/daemon/main.c:700
+#: ../src/daemon/main.c:634
#, c-format
msgid "Failed to kill daemon: %s"
msgstr "æ€æ­»åŽå°ç¨‹åºå¤±è´¥ï¼š%s"
-#: ../src/daemon/main.c:718
+#: ../src/daemon/main.c:662
msgid ""
"This program is not intended to be run as root (unless --system is "
"specified)."
msgstr "ä¸åº”以root身份è¿è¡Œæœ¬ç¨‹åºï¼ˆé™¤éžæŒ‡å®š --system)。"
-#: ../src/daemon/main.c:720
+#: ../src/daemon/main.c:665
msgid "Root privileges required."
msgstr "éœ€è¦ root æƒé™ã€‚"
-#: ../src/daemon/main.c:725
+#: ../src/daemon/main.c:671
msgid "--start not supported for system instances."
msgstr "ç³»ç»Ÿå®žä¾‹ä¸æ”¯æŒ --start。"
-#: ../src/daemon/main.c:730
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
msgid "Running in system mode, but --disallow-exit not set!"
msgstr "正在以系统模å¼è¿è¡Œï¼Œä½†æ˜¯ --disallow-exit 未设定ï¼"
-#: ../src/daemon/main.c:733
+#: ../src/daemon/main.c:686
msgid "Running in system mode, but --disallow-module-loading not set!"
msgstr "正在以系统模å¼è¿è¡Œï¼Œä½†æ˜¯ --disallow-module-loading 未设定ï¼"
-#: ../src/daemon/main.c:736
+#: ../src/daemon/main.c:689
msgid "Running in system mode, forcibly disabling SHM mode!"
msgstr "正在以系统模å¼è¿è¡Œï¼Œå¼ºåˆ¶ç¦ç”¨SHM模å¼ï¼"
-#: ../src/daemon/main.c:741
+#: ../src/daemon/main.c:694
msgid "Running in system mode, forcibly disabling exit idle time!"
msgstr "正在以系统模å¼è¿è¡Œï¼Œå¼ºåˆ¶ç¦ç”¨é€€å‡ºç©ºé—²æ—¶é—´ï¼"
-#: ../src/daemon/main.c:768
+#: ../src/daemon/main.c:720
msgid "Failed to acquire stdio."
msgstr "获å–stdio失败。"
-#: ../src/daemon/main.c:774
-#, c-format
-msgid "pipe failed: %s"
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
msgstr "管é“失败:%s"
-#: ../src/daemon/main.c:779
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
#, c-format
msgid "fork() failed: %s"
msgstr "fork()失败:%s"
-#: ../src/daemon/main.c:793
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
#, c-format
msgid "read() failed: %s"
msgstr "read()失败:%s"
-#: ../src/daemon/main.c:799
+#: ../src/daemon/main.c:751
msgid "Daemon startup failed."
msgstr "åŽå°ç¨‹åºå¯åŠ¨å¤±è´¥ã€‚"
-#: ../src/daemon/main.c:801
+#: ../src/daemon/main.c:753
msgid "Daemon startup successful."
msgstr "åŽå°ç¨‹åºå¯åЍæˆåŠŸã€‚"
-#: ../src/daemon/main.c:871
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read()失败:%s"
+
+#: ../src/daemon/main.c:830
#, c-format
msgid "This is PulseAudio %s"
msgstr "这是 PulseAudio %s"
-#: ../src/daemon/main.c:872
+#: ../src/daemon/main.c:831
#, c-format
msgid "Compilation host: %s"
msgstr "编译主机:%s"
-#: ../src/daemon/main.c:873
+#: ../src/daemon/main.c:832
#, c-format
msgid "Compilation CFLAGS: %s"
msgstr "编译CFLAGS:%s"
-#: ../src/daemon/main.c:876
+#: ../src/daemon/main.c:835
#, c-format
msgid "Running on host: %s"
msgstr "正在主机上è¿è¡Œï¼š%s"
-#: ../src/daemon/main.c:879
+#: ../src/daemon/main.c:838
#, c-format
msgid "Found %u CPUs."
msgstr "找到 %u CPU。"
-#: ../src/daemon/main.c:881
+#: ../src/daemon/main.c:840
#, c-format
msgid "Page size is %lu bytes"
msgstr "页é¢å¤§å°ä¸º%lu字节"
-#: ../src/daemon/main.c:884
+#: ../src/daemon/main.c:843
msgid "Compiled with Valgrind support: yes"
msgstr "编译å¯ç”¨Valgrind支æŒï¼šæ˜¯"
-#: ../src/daemon/main.c:886
+#: ../src/daemon/main.c:845
msgid "Compiled with Valgrind support: no"
msgstr "编译å¯ç”¨Valgrind支æŒï¼šå¦"
-#: ../src/daemon/main.c:889
+#: ../src/daemon/main.c:848
#, c-format
msgid "Running in valgrind mode: %s"
msgstr "正在以valgrind模å¼è¿è¡Œï¼š%s"
-#: ../src/daemon/main.c:892
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "正在主机上è¿è¡Œï¼š%s"
+
+#: ../src/daemon/main.c:853
msgid "Optimized build: yes"
msgstr "优化生æˆï¼šæ˜¯"
-#: ../src/daemon/main.c:894
+#: ../src/daemon/main.c:855
msgid "Optimized build: no"
msgstr "优化生æˆï¼šå¦"
-#: ../src/daemon/main.c:898
+#: ../src/daemon/main.c:859
msgid "NDEBUG defined, all asserts disabled."
msgstr "æ‹’ç» NDEBUG,ç¦ç”¨æ‰€æœ‰ assert"
-#: ../src/daemon/main.c:900
+#: ../src/daemon/main.c:861
msgid "FASTPATH defined, only fast path asserts disabled."
msgstr "æ‹’ç» FASTPATH,åªç¦ç”¨å¿«é€Ÿè·¯å¾„ assert。"
-#: ../src/daemon/main.c:902
+#: ../src/daemon/main.c:863
msgid "All asserts enabled."
msgstr "å¯ç”¨æ‰€æœ‰ assert。"
-#: ../src/daemon/main.c:906
+#: ../src/daemon/main.c:867
msgid "Failed to get machine ID"
msgstr "获å–machine ID失败"
-#: ../src/daemon/main.c:909
+#: ../src/daemon/main.c:870
#, c-format
msgid "Machine ID is %s."
msgstr "machine ID是%s。"
-#: ../src/daemon/main.c:913
-#, fuzzy, c-format
+#: ../src/daemon/main.c:874
+#, c-format
msgid "Session ID is %s."
-msgstr "machine ID是%s。"
+msgstr "ä¼šè¯ ID %s。"
-#: ../src/daemon/main.c:919
+#: ../src/daemon/main.c:880
#, c-format
msgid "Using runtime directory %s."
msgstr "正在使用è¿è¡Œæ—¶æ–‡ä»¶å¤¹%s。"
-#: ../src/daemon/main.c:924
+#: ../src/daemon/main.c:885
#, c-format
msgid "Using state directory %s."
msgstr "æ­£åœ¨ä½¿ç”¨çŠ¶æ€æ–‡ä»¶å¤¹%s。"
-#: ../src/daemon/main.c:927
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "正在使用模å—目录 %s。"
+
+#: ../src/daemon/main.c:890
#, c-format
msgid "Running in system mode: %s"
msgstr "正在以系统模å¼è¿è¡Œï¼š%s"
-#: ../src/daemon/main.c:942
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+"确定,那么您正在系统模å¼ä¸­è¿è¡Œ PA。请注æ„:您很å¯èƒ½ä¸åº”该这样åšã€‚\n"
+"如果您无论如何都这样åšäº†ï¼Œé‚£ä¹ˆå‡ºçްæ„外情况就是您的问题。\n"
+"在文章 http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode 中解释了为什么系"
+"统模å¼é€šå¸¸ä¸æ˜¯ä¸ªå¥½ä¸»æ„。"
+
+#: ../src/daemon/main.c:910
msgid "pa_pid_file_create() failed."
msgstr "pa_pid_file_create()失败。"
-#: ../src/daemon/main.c:954
+#: ../src/daemon/main.c:920
msgid "Fresh high-resolution timers available! Bon appetit!"
msgstr "新鲜的高分辨率计时器开锅了ï¼åƒä¸ªé¥±ï¼"
-#: ../src/daemon/main.c:956
+#: ../src/daemon/main.c:922
msgid ""
"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
"resolution timers enabled!"
-msgstr "è€å…„,你的内核真臭ï¼çŽ°åœ¨æµè¡Œçš„æ˜¯å¯ç”¨äº†é«˜åˆ†è¾©çŽ‡è®¡åˆ†å™¨çš„Linuxï¼"
+msgstr "è€å…„,您的内核真臭ï¼çŽ°åœ¨æµè¡Œçš„æ˜¯å¯ç”¨äº†é«˜åˆ†è¾©çŽ‡è®¡åˆ†å™¨çš„Linuxï¼"
-#: ../src/daemon/main.c:970
+#: ../src/daemon/main.c:945
msgid "pa_core_new() failed."
msgstr "pa_core_new()失败。"
-#: ../src/daemon/main.c:1032
+#: ../src/daemon/main.c:1008
msgid "Failed to initialize daemon."
msgstr "åŽå°ç¨‹åºåˆå§‹åŒ–失败。"
-#: ../src/daemon/main.c:1037
+#: ../src/daemon/main.c:1013
msgid "Daemon startup without any loaded modules, refusing to work."
msgstr "åŽå°ç¨‹åºå¯åŠ¨æœªåŠ è½½ä»»ä½•æ¨¡å—,拒ç»å·¥ä½œã€‚"
-#: ../src/daemon/main.c:1054
+#: ../src/daemon/main.c:1051
msgid "Daemon startup complete."
msgstr "åŽå°ç¨‹åºå¯åŠ¨å®Œæˆã€‚"
-#: ../src/daemon/main.c:1060
+#: ../src/daemon/main.c:1057
msgid "Daemon shutdown initiated."
msgstr "开始关闭åŽå°ç¨‹åºã€‚"
-#: ../src/daemon/main.c:1082
+#: ../src/daemon/main.c:1083
msgid "Daemon terminated."
msgstr "åŽå°ç¨‹åºå·²ç»ˆæ­¢ã€‚"
-#: ../src/daemon/cmdline.c:121
+#: ../src/daemon/cmdline.c:115
#, c-format
msgid ""
"%s [options]\n"
@@ -637,15 +551,15 @@ msgstr ""
"\n"
" -n ä¸åŠ è½½é»˜è®¤çš„è„šæœ¬æ–‡ä»¶\n"
-#: ../src/daemon/cmdline.c:252
+#: ../src/daemon/cmdline.c:247
msgid "--daemonize expects boolean argument"
msgstr "--daemonize æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:259
+#: ../src/daemon/cmdline.c:254
msgid "--fail expects boolean argument"
msgstr "--fail æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:269
+#: ../src/daemon/cmdline.c:264
msgid ""
"--log-level expects log level argument (either numeric in range 0..4 or one "
"of debug, info, notice, warn, error)."
@@ -653,52 +567,52 @@ msgstr ""
"--log-level æœŸå¾…æ—¥å¿—çº§åˆ«å‚æ•°ï¼ˆå¯ä»¥æ˜¯æ•°å­—0~4或者debug,info,notice,warn,"
"error中的一个)"
-#: ../src/daemon/cmdline.c:281
+#: ../src/daemon/cmdline.c:276
msgid "--high-priority expects boolean argument"
msgstr "--high-priority æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:288
+#: ../src/daemon/cmdline.c:283
msgid "--realtime expects boolean argument"
msgstr "--realtime æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:295
+#: ../src/daemon/cmdline.c:290
msgid "--disallow-module-loading expects boolean argument"
msgstr "--disallow-module-loading æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:302
+#: ../src/daemon/cmdline.c:297
msgid "--disallow-exit expects boolean argument"
msgstr "--disallow-exit 需è¦å¸ƒå°”值傿•°"
-#: ../src/daemon/cmdline.c:309
+#: ../src/daemon/cmdline.c:304
msgid "--use-pid-file expects boolean argument"
msgstr "--use-pid-file æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:326
+#: ../src/daemon/cmdline.c:321
msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
msgstr "无效的日志目标:从syslog,stderrå’Œauto中选å–一个"
-#: ../src/daemon/cmdline.c:333
+#: ../src/daemon/cmdline.c:328
msgid "--log-time expects boolean argument"
msgstr "--log-time 需è¦å¸ƒå°”值傿•°"
-#: ../src/daemon/cmdline.c:340
+#: ../src/daemon/cmdline.c:335
msgid "--log-meta expects boolean argument"
msgstr "--log-meta 需è¦å¸ƒå°”值傿•°"
-#: ../src/daemon/cmdline.c:359
+#: ../src/daemon/cmdline.c:354
#, c-format
msgid "Invalid resample method '%s'."
msgstr "无效的é‡é‡‡æ ·æ–¹æ³•'%s'。"
-#: ../src/daemon/cmdline.c:366
+#: ../src/daemon/cmdline.c:361
msgid "--system expects boolean argument"
msgstr "--system æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:373
+#: ../src/daemon/cmdline.c:368
msgid "--no-cpu-limit expects boolean argument"
msgstr "--no-cpu-limit æœŸå¾…å¸ƒå°”å‚æ•°"
-#: ../src/daemon/cmdline.c:380
+#: ../src/daemon/cmdline.c:375
msgid "--disable-shm expects boolean argument"
msgstr "--disable-shm æœŸå¾…å¸ƒå°”å‚æ•°"
@@ -737,94 +651,100 @@ msgstr "用法:%s\n"
msgid "Load Once: %s\n"
msgstr "加载一次:%s\n"
-#: ../src/daemon/dumpmodules.c:77
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "å对警告:%s\n"
+
+#: ../src/daemon/dumpmodules.c:79
#, c-format
msgid "Path: %s\n"
msgstr "路径:%s\n"
-#: ../src/daemon/daemon-conf.c:215
+#: ../src/daemon/daemon-conf.c:251
#, c-format
msgid "[%s:%u] Invalid log target '%s'."
msgstr "[%s:%u] 无效的日志目标'%s'。"
-#: ../src/daemon/daemon-conf.c:231
+#: ../src/daemon/daemon-conf.c:267
#, c-format
msgid "[%s:%u] Invalid log level '%s'."
msgstr "[%s:%u] 无效的日志级别'%s'。"
-#: ../src/daemon/daemon-conf.c:247
+#: ../src/daemon/daemon-conf.c:283
#, c-format
msgid "[%s:%u] Invalid resample method '%s'."
msgstr "[%s:%u] 无效的é‡é‡‡æ ·æ–¹æ³•'%s'。"
-#: ../src/daemon/daemon-conf.c:270
+#: ../src/daemon/daemon-conf.c:306
#, c-format
msgid "[%s:%u] Invalid rlimit '%s'."
msgstr "[%s:%u] 无效的rlimit '%s'。"
-#: ../src/daemon/daemon-conf.c:277
+#: ../src/daemon/daemon-conf.c:313
#, c-format
msgid "[%s:%u] rlimit not supported on this platform."
msgstr "[%s:%u] 此平å°ä¸æ”¯æŒrlimit。"
-#: ../src/daemon/daemon-conf.c:293
+#: ../src/daemon/daemon-conf.c:329
#, c-format
msgid "[%s:%u] Invalid sample format '%s'."
msgstr "[%s:%u] æ— æ•ˆçš„æ ·å“æ ¼å¼'%s'。"
-#: ../src/daemon/daemon-conf.c:311
+#: ../src/daemon/daemon-conf.c:347
#, c-format
msgid "[%s:%u] Invalid sample rate '%s'."
msgstr "[%s:%u] 无效的样å“率'%s'。"
-#: ../src/daemon/daemon-conf.c:335
+#: ../src/daemon/daemon-conf.c:371
#, c-format
msgid "[%s:%u] Invalid sample channels '%s'."
msgstr "[%s:%u] 无效的样å“通é“'%s'。"
-#: ../src/daemon/daemon-conf.c:353
+#: ../src/daemon/daemon-conf.c:389
#, c-format
msgid "[%s:%u] Invalid channel map '%s'."
msgstr "[%s:%u] 无效频é“地图 '%s'。"
-#: ../src/daemon/daemon-conf.c:371
+#: ../src/daemon/daemon-conf.c:407
#, c-format
msgid "[%s:%u] Invalid number of fragments '%s'."
msgstr "[%s:%u] 无效的分段数'%s'。"
-#: ../src/daemon/daemon-conf.c:389
+#: ../src/daemon/daemon-conf.c:425
#, c-format
msgid "[%s:%u] Invalid fragment size '%s'."
msgstr "[%s:%u] 无效的分段大å°'%s'。"
-#: ../src/daemon/daemon-conf.c:407
+#: ../src/daemon/daemon-conf.c:443
#, c-format
msgid "[%s:%u] Invalid nice level '%s'."
msgstr "[%s:%u] 无效的nice level '%s'。"
-#: ../src/daemon/daemon-conf.c:522
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] 无效的样å“率'%s'。"
+
+#: ../src/daemon/daemon-conf.c:586
#, c-format
msgid "Failed to open configuration file: %s"
msgstr "打开é…置文件失败:%s"
-#: ../src/daemon/daemon-conf.c:538
+#: ../src/daemon/daemon-conf.c:602
msgid ""
"The specified default channel map has a different number of channels than "
"the specified default number of channels."
msgstr "指定的默认频é“åœ°å›¾çš„é¢‘é“æ•°ä¸ŽæŒ‡å®šçš„é»˜è®¤é¢‘é“æ•°ä¸åŒã€‚"
-#: ../src/daemon/daemon-conf.c:616
+#: ../src/daemon/daemon-conf.c:688
#, c-format
msgid "### Read from configuration file: %s ###\n"
msgstr "### 从é…置文件读å–:%s ###\n"
-#: ../src/daemon/caps.c:63
-msgid "Dropping root privileges."
-msgstr "æ­£åœ¨å–æ¶ˆ root 特æƒã€‚"
-
-#: ../src/daemon/caps.c:103
-msgid "Limited capabilities successfully to CAP_SYS_NICE."
-msgstr "性能æˆåŠŸé™åˆ¶åˆ°CAP_SYS_NICE。"
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "å–æ¶ˆç‰¹æƒã€‚"
#: ../src/daemon/pulseaudio.desktop.in.h:1
msgid "PulseAudio Sound System"
@@ -834,255 +754,237 @@ msgstr "PulseAudio 声音系统"
msgid "Start the PulseAudio Sound System"
msgstr "å¯åЍ PulseAudio 声音系统"
-#: ../src/daemon/org.pulseaudio.policy.in.h:1
-msgid ""
-"High-priority scheduling (negative Unix nice level) for the PulseAudio daemon"
-msgstr "PulseAudio 守护进程的高优先调度(负的 Unix nic 等级)"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:2
-msgid "Real-time scheduling for the PulseAudio daemon"
-msgstr "PulseAudio 守护进程的实时调度。"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:3
-msgid ""
-"System policy prevents PulseAudio from acquiring high-priority scheduling."
-msgstr "系统策略防止 PulseAudio 获得高优先调度。"
-
-#: ../src/daemon/org.pulseaudio.policy.in.h:4
-msgid "System policy prevents PulseAudio from acquiring real-time scheduling."
-msgstr "系统策略防止 PulseAudio 获得实时调度。"
-
-#: ../src/pulse/channelmap.c:103 ../src/pulse/channelmap.c:804
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
msgid "Mono"
msgstr "å•声é“"
-#: ../src/pulse/channelmap.c:105
+#: ../src/pulse/channelmap.c:107
msgid "Front Center"
msgstr "中å‰"
-#: ../src/pulse/channelmap.c:106
+#: ../src/pulse/channelmap.c:108
msgid "Front Left"
msgstr "å·¦å‰"
-#: ../src/pulse/channelmap.c:107
+#: ../src/pulse/channelmap.c:109
msgid "Front Right"
msgstr "å³å‰"
-#: ../src/pulse/channelmap.c:109
+#: ../src/pulse/channelmap.c:111
msgid "Rear Center"
msgstr "中åŽ"
-#: ../src/pulse/channelmap.c:110
+#: ../src/pulse/channelmap.c:112
msgid "Rear Left"
msgstr "å·¦åŽ"
-#: ../src/pulse/channelmap.c:111
+#: ../src/pulse/channelmap.c:113
msgid "Rear Right"
msgstr "å³åŽ"
-#: ../src/pulse/channelmap.c:113
-msgid "Low Frequency Emmiter"
-msgstr "低频脉冲"
-
#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
msgid "Front Left-of-center"
msgstr "å‰å·¦ä¸­å¤®"
-#: ../src/pulse/channelmap.c:116
+#: ../src/pulse/channelmap.c:118
msgid "Front Right-of-center"
msgstr "å‰å³ä¸­å¤®"
-#: ../src/pulse/channelmap.c:118
+#: ../src/pulse/channelmap.c:120
msgid "Side Left"
msgstr "左侧"
-#: ../src/pulse/channelmap.c:119
+#: ../src/pulse/channelmap.c:121
msgid "Side Right"
msgstr "å³ä¾§"
-#: ../src/pulse/channelmap.c:121
+#: ../src/pulse/channelmap.c:123
msgid "Auxiliary 0"
msgstr "辅助 0"
-#: ../src/pulse/channelmap.c:122
+#: ../src/pulse/channelmap.c:124
msgid "Auxiliary 1"
msgstr "辅助 1"
-#: ../src/pulse/channelmap.c:123
+#: ../src/pulse/channelmap.c:125
msgid "Auxiliary 2"
msgstr "辅助 2"
-#: ../src/pulse/channelmap.c:124
+#: ../src/pulse/channelmap.c:126
msgid "Auxiliary 3"
msgstr "辅助 3"
-#: ../src/pulse/channelmap.c:125
+#: ../src/pulse/channelmap.c:127
msgid "Auxiliary 4"
msgstr "辅助 4"
-#: ../src/pulse/channelmap.c:126
+#: ../src/pulse/channelmap.c:128
msgid "Auxiliary 5"
msgstr "辅助 5"
-#: ../src/pulse/channelmap.c:127
+#: ../src/pulse/channelmap.c:129
msgid "Auxiliary 6"
msgstr "辅助 6"
-#: ../src/pulse/channelmap.c:128
+#: ../src/pulse/channelmap.c:130
msgid "Auxiliary 7"
msgstr "辅助 7"
-#: ../src/pulse/channelmap.c:129
+#: ../src/pulse/channelmap.c:131
msgid "Auxiliary 8"
msgstr "辅助 7"
-#: ../src/pulse/channelmap.c:130
+#: ../src/pulse/channelmap.c:132
msgid "Auxiliary 9"
msgstr "辅助 9"
-#: ../src/pulse/channelmap.c:131
+#: ../src/pulse/channelmap.c:133
msgid "Auxiliary 10"
msgstr "辅助 10"
-#: ../src/pulse/channelmap.c:132
+#: ../src/pulse/channelmap.c:134
msgid "Auxiliary 11"
msgstr "辅助 11"
-#: ../src/pulse/channelmap.c:133
+#: ../src/pulse/channelmap.c:135
msgid "Auxiliary 12"
msgstr "辅助 12"
-#: ../src/pulse/channelmap.c:134
+#: ../src/pulse/channelmap.c:136
msgid "Auxiliary 13"
msgstr "辅助 13"
-#: ../src/pulse/channelmap.c:135
+#: ../src/pulse/channelmap.c:137
msgid "Auxiliary 14"
msgstr "辅助 14"
-#: ../src/pulse/channelmap.c:136
+#: ../src/pulse/channelmap.c:138
msgid "Auxiliary 15"
msgstr "辅助 15"
-#: ../src/pulse/channelmap.c:137
+#: ../src/pulse/channelmap.c:139
msgid "Auxiliary 16"
msgstr "辅助 16"
-#: ../src/pulse/channelmap.c:138
+#: ../src/pulse/channelmap.c:140
msgid "Auxiliary 17"
msgstr "辅助 17"
-#: ../src/pulse/channelmap.c:139
+#: ../src/pulse/channelmap.c:141
msgid "Auxiliary 18"
msgstr "辅助 18"
-#: ../src/pulse/channelmap.c:140
+#: ../src/pulse/channelmap.c:142
msgid "Auxiliary 19"
msgstr "辅助 19"
-#: ../src/pulse/channelmap.c:141
+#: ../src/pulse/channelmap.c:143
msgid "Auxiliary 20"
msgstr "辅助 20"
-#: ../src/pulse/channelmap.c:142
+#: ../src/pulse/channelmap.c:144
msgid "Auxiliary 21"
msgstr "辅助 21"
-#: ../src/pulse/channelmap.c:143
+#: ../src/pulse/channelmap.c:145
msgid "Auxiliary 22"
msgstr "辅助 22"
-#: ../src/pulse/channelmap.c:144
+#: ../src/pulse/channelmap.c:146
msgid "Auxiliary 23"
msgstr "辅助 23"
-#: ../src/pulse/channelmap.c:145
+#: ../src/pulse/channelmap.c:147
msgid "Auxiliary 24"
msgstr "辅助 24"
-#: ../src/pulse/channelmap.c:146
+#: ../src/pulse/channelmap.c:148
msgid "Auxiliary 25"
msgstr "辅助 25"
-#: ../src/pulse/channelmap.c:147
+#: ../src/pulse/channelmap.c:149
msgid "Auxiliary 26"
msgstr "辅助 26"
-#: ../src/pulse/channelmap.c:148
+#: ../src/pulse/channelmap.c:150
msgid "Auxiliary 27"
msgstr "辅助 27"
-#: ../src/pulse/channelmap.c:149
+#: ../src/pulse/channelmap.c:151
msgid "Auxiliary 28"
msgstr "辅助 28"
-#: ../src/pulse/channelmap.c:150
+#: ../src/pulse/channelmap.c:152
msgid "Auxiliary 29"
msgstr "辅助 29"
-#: ../src/pulse/channelmap.c:151
+#: ../src/pulse/channelmap.c:153
msgid "Auxiliary 30"
msgstr "辅助 30"
-#: ../src/pulse/channelmap.c:152
+#: ../src/pulse/channelmap.c:154
msgid "Auxiliary 31"
msgstr "辅助 31"
-#: ../src/pulse/channelmap.c:154
+#: ../src/pulse/channelmap.c:156
msgid "Top Center"
msgstr "上中"
-#: ../src/pulse/channelmap.c:156
+#: ../src/pulse/channelmap.c:158
msgid "Top Front Center"
msgstr "上中å‰"
-#: ../src/pulse/channelmap.c:157
+#: ../src/pulse/channelmap.c:159
msgid "Top Front Left"
msgstr "上左å‰"
-#: ../src/pulse/channelmap.c:158
+#: ../src/pulse/channelmap.c:160
msgid "Top Front Right"
msgstr "上å³å‰"
-#: ../src/pulse/channelmap.c:160
+#: ../src/pulse/channelmap.c:162
msgid "Top Rear Center"
msgstr "上中åŽ"
-#: ../src/pulse/channelmap.c:161
+#: ../src/pulse/channelmap.c:163
msgid "Top Rear Left"
msgstr "上左åŽ"
-#: ../src/pulse/channelmap.c:162
+#: ../src/pulse/channelmap.c:164
msgid "Top Rear Right"
msgstr "上å³åŽ"
-#: ../src/pulse/channelmap.c:476 ../src/pulse/sample.c:167
-#: ../src/pulse/volume.c:170 ../src/pulse/volume.c:196
-#: ../src/pulse/volume.c:216 ../src/pulse/volume.c:246
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
msgid "(invalid)"
msgstr "(无效)"
-#: ../src/pulse/channelmap.c:808
+#: ../src/pulse/channelmap.c:761
msgid "Stereo"
msgstr "立体声"
-#: ../src/pulse/channelmap.c:813
+#: ../src/pulse/channelmap.c:766
msgid "Surround 4.0"
msgstr "环绕 4.0 "
-#: ../src/pulse/channelmap.c:819
+#: ../src/pulse/channelmap.c:772
msgid "Surround 4.1"
msgstr "环绕 4.1"
-#: ../src/pulse/channelmap.c:825
+#: ../src/pulse/channelmap.c:778
msgid "Surround 5.0"
msgstr "环绕 5.0"
-#: ../src/pulse/channelmap.c:831
+#: ../src/pulse/channelmap.c:784
msgid "Surround 5.1"
msgstr "环绕 5.1"
-#: ../src/pulse/channelmap.c:838
+#: ../src/pulse/channelmap.c:791
msgid "Surround 7.1"
msgstr "环绕 7.1"
@@ -1186,27 +1088,35 @@ msgstr "缺少部署"
msgid "Client forked"
msgstr "客户端分支"
-#: ../src/pulse/sample.c:169
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "输入/输出错误"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "设备或者资æºå¿™"
+
+#: ../src/pulse/sample.c:172
#, c-format
msgid "%s %uch %uHz"
msgstr "%s %uch %uHz"
-#: ../src/pulse/sample.c:181
+#: ../src/pulse/sample.c:184
#, c-format
msgid "%0.1f GiB"
msgstr "%0.1f GiB"
-#: ../src/pulse/sample.c:183
+#: ../src/pulse/sample.c:186
#, c-format
msgid "%0.1f MiB"
msgstr "%0.1f MiB"
-#: ../src/pulse/sample.c:185
+#: ../src/pulse/sample.c:188
#, c-format
msgid "%0.1f KiB"
msgstr "%0.1f KiB"
-#: ../src/pulse/sample.c:187
+#: ../src/pulse/sample.c:190
#, c-format
msgid "%u B"
msgstr "%u B"
@@ -1219,197 +1129,191 @@ msgstr "XOpenDisplay()失败"
msgid "Failed to parse cookie data"
msgstr "cookieæ•°æ®åˆ†æžå¤±è´¥"
-#: ../src/pulse/client-conf.c:110
+#: ../src/pulse/client-conf.c:118
#, c-format
msgid "Failed to open configuration file '%s': %s"
msgstr "打开é…置文件'%s'失败:%s"
-#: ../src/pulse/context.c:546
+#: ../src/pulse/context.c:539
msgid "No cookie loaded. Attempting to connect without."
msgstr "没有加载cookie。å°è¯•ä¸åŠ è½½cookie进行连接。"
-#: ../src/pulse/context.c:676
+#: ../src/pulse/context.c:682
#, c-format
msgid "fork(): %s"
msgstr "fork():%s"
-#: ../src/pulse/context.c:729
+#: ../src/pulse/context.c:737
#, c-format
msgid "waitpid(): %s"
msgstr "waitpid():%s"
-#: ../src/pulse/context.c:1403
+#: ../src/pulse/context.c:1434
#, c-format
msgid "Received message for unknown extension '%s'"
msgstr "收到未知扩展'%s'的信æ¯"
-#: ../src/utils/pacat.c:94
+#: ../src/utils/pacat.c:110
#, c-format
-msgid "pa_stream_write() failed: %s\n"
-msgstr "pa_stream_write()失败:%s\n"
+msgid "Failed to drain stream: %s"
+msgstr "排出æµå¤±è´¥ï¼š%s"
-#: ../src/utils/pacat.c:133
-#, c-format
-msgid "pa_stream_peek() failed: %s\n"
-msgstr "pa_stream_peek()失败:%s\n"
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "å›žæ”¾æµæž¯ç«­ã€‚"
-#: ../src/utils/pacat.c:169
-#, c-format
-msgid "Stream successfully created.\n"
-msgstr "æµåˆ›å»ºæˆåŠŸã€‚\n"
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "到æœåŠ¡å™¨çš„ Draining 连接。"
-#: ../src/utils/pacat.c:172
+#: ../src/utils/pacat.c:138
#, c-format
-msgid "pa_stream_get_buffer_attr() failed: %s\n"
-msgstr "pa_stream_get_buffer_attr()失败:%s\n"
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
-#: ../src/utils/pacat.c:176
+#: ../src/utils/pacat.c:161
#, c-format
-msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u\n"
-msgstr "缓冲计é‡ï¼šmaxlength=%u,tlength=%u,prebuf=%u,minreq=%u\n"
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() failed: %s"
-#: ../src/utils/pacat.c:179
+#: ../src/utils/pacat.c:202
#, c-format
-msgid "Buffer metrics: maxlength=%u, fragsize=%u\n"
-msgstr "缓冲计é‡ï¼šmaxlength=%u,fragsize=%u\n"
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() failed: %s"
-#: ../src/utils/pacat.c:183
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
#, c-format
-msgid "Using sample spec '%s', channel map '%s'.\n"
-msgstr "正在使用样å“è§„æ ¼'%s'ï¼Œé€šé“æ˜ å°„'%s'。\n"
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() failed: %s"
-#: ../src/utils/pacat.c:187
-#, c-format
-msgid "Connected to device %s (%u, %ssuspended).\n"
-msgstr "已连接至设备%s (%u,%s挂起)。\n"
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "æµåˆ›å»ºæˆåŠŸã€‚"
-#: ../src/utils/pacat.c:197
+#: ../src/utils/pacat.c:325
#, c-format
-msgid "Stream error: %s\n"
-msgstr "æµé”™è¯¯ï¼š%s\n"
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() failed: %s"
-#: ../src/utils/pacat.c:207
+#: ../src/utils/pacat.c:329
#, c-format
-msgid "Stream device suspended.%s \n"
-msgstr "æµè®¾å¤‡æŒ‚起。%s\n"
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
-#: ../src/utils/pacat.c:209
+#: ../src/utils/pacat.c:332
#, c-format
-msgid "Stream device resumed.%s \n"
-msgstr "æµè®¾å¤‡æ¢å¤ã€‚%s\n"
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr "Buffer metrics: maxlength=%u, fragsize=%u"
-#: ../src/utils/pacat.c:217
+#: ../src/utils/pacat.c:336
#, c-format
-msgid "Stream underrun.%s \n"
-msgstr "æµæ¬ è½½è¿è¡Œã€‚%s\n"
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "正在使用样å“è§„æ ¼ '%s'ï¼Œé€šé“æ˜ å°„ '%s'。"
-#: ../src/utils/pacat.c:224
+#: ../src/utils/pacat.c:340
#, c-format
-msgid "Stream overrun.%s \n"
-msgstr "æµè¶…é™è¿è¡Œã€‚%s\n"
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "已连接至设备 %s (%u,%s 挂起)。"
-#: ../src/utils/pacat.c:231
+#: ../src/utils/pacat.c:350
#, c-format
-msgid "Stream started.%s \n"
-msgstr "æµå·²å¯åŠ¨ã€‚%s\n"
+msgid "Stream error: %s"
+msgstr "æµé”™è¯¯ï¼š%s"
-#: ../src/utils/pacat.c:238
+#: ../src/utils/pacat.c:360
#, c-format
-msgid "Stream moved to device %s (%u, %ssuspended).%s \n"
-msgstr "æµç§»è‡³è®¾å¤‡%s (%u,%s挂起)。%s\n"
+msgid "Stream device suspended.%s"
+msgstr "æµè®¾å¤‡æŒ‚起。%s"
-#: ../src/utils/pacat.c:238
-msgid "not "
-msgstr "not "
-
-#: ../src/utils/pacat.c:245
+#: ../src/utils/pacat.c:362
#, c-format
-msgid "Stream buffer attributes changed.%s \n"
-msgstr "æ›´æ”¹æµæ¢å‡ºå±žæ€§ã€‚%s\n"
+msgid "Stream device resumed.%s"
+msgstr "æµè®¾å¤‡æ¢å¤ã€‚%s"
-#: ../src/utils/pacat.c:278
+#: ../src/utils/pacat.c:370
#, c-format
-msgid "Connection established.%s \n"
-msgstr "连接已建立。%s \n"
+msgid "Stream underrun.%s"
+msgstr "æµæ¬ è½½è¿è¡Œã€‚%s"
-#: ../src/utils/pacat.c:281
+#: ../src/utils/pacat.c:377
#, c-format
-msgid "pa_stream_new() failed: %s\n"
-msgstr "pa_stream_new()失败:%s\n"
+msgid "Stream overrun.%s"
+msgstr "æµè¶…é™è¿è¡Œã€‚%s"
-#: ../src/utils/pacat.c:309
+#: ../src/utils/pacat.c:384
#, c-format
-msgid "pa_stream_connect_playback() failed: %s\n"
-msgstr "pa_stream_connect_playback()失败:%s\n"
+msgid "Stream started.%s"
+msgstr "æµå·²å¯åŠ¨ã€‚%s"
-#: ../src/utils/pacat.c:315
+#: ../src/utils/pacat.c:391
#, c-format
-msgid "pa_stream_connect_record() failed: %s\n"
-msgstr "pa_stream_connect_playback()失败:%s\n"
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "æµç§»è‡³è®¾å¤‡ %s (%u,%s 挂起)。%s"
-#: ../src/utils/pacat.c:329 ../src/utils/pasuspender.c:159
-#: ../src/utils/pactl.c:762 ../src/utils/paplay.c:183
-#, c-format
-msgid "Connection failure: %s\n"
-msgstr "连接失败:%s\n"
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "not "
-#: ../src/utils/pacat.c:349 ../src/utils/paplay.c:75
+#: ../src/utils/pacat.c:398
#, c-format
-msgid "Failed to drain stream: %s\n"
-msgstr "排出æµå¤±è´¥ï¼š%s\n"
+msgid "Stream buffer attributes changed.%s"
+msgstr "更改æµç¼“冲属性。%s"
-#: ../src/utils/pacat.c:354 ../src/utils/paplay.c:80
+#: ../src/utils/pacat.c:430
#, c-format
-msgid "Playback stream drained.\n"
-msgstr "æµæ’­æ”¾å®Œæ¯•。\n"
+msgid "Connection established.%s"
+msgstr "连接已建立。%s "
-#: ../src/utils/pacat.c:364 ../src/utils/paplay.c:92
+#: ../src/utils/pacat.c:433
#, c-format
-msgid "Draining connection to server.\n"
-msgstr "Draining 连接到æœåŠ¡å™¨ã€‚\n"
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() failed: %s"
-#: ../src/utils/pacat.c:390
+#: ../src/utils/pacat.c:471
#, c-format
-msgid "Got EOF.\n"
-msgstr "收到EOF。\n"
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() failed: %s"
-#: ../src/utils/pacat.c:396
+#: ../src/utils/pacat.c:477
#, c-format
-msgid "pa_stream_drain(): %s\n"
-msgstr "pa_stream_drain():%s\n"
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() failed: %s"
-#: ../src/utils/pacat.c:406
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
#, c-format
-msgid "read() failed: %s\n"
-msgstr "read()失败:%s\n"
+msgid "Connection failure: %s"
+msgstr "连接失败:%s"
-#: ../src/utils/pacat.c:438
-#, c-format
-msgid "write() failed: %s\n"
-msgstr "write()失败:%s\n"
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "获得 EOF。"
-#: ../src/utils/pacat.c:459
+#: ../src/utils/pacat.c:561
#, c-format
-msgid "Got signal, exiting.\n"
-msgstr "收到信å·ï¼Œæ­£åœ¨é€€å‡ºã€‚\n"
+msgid "write() failed: %s"
+msgstr "写入()失败:%s"
-#: ../src/utils/pacat.c:473
-#, c-format
-msgid "Failed to get latency: %s\n"
-msgstr "获å–传输延迟失败:%s\n"
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "收到信å·ï¼Œæ­£åœ¨é€€å‡ºã€‚"
-#: ../src/utils/pacat.c:478
+#: ../src/utils/pacat.c:596
#, c-format
-msgid "Time: %0.3f sec; Latency: %0.0f usec. \r"
-msgstr "时间:%0.3f秒;延迟:%0.0f 微秒。 \r"
+msgid "Failed to get latency: %s"
+msgstr "获å–传输延迟失败:%s"
-#: ../src/utils/pacat.c:498
+#: ../src/utils/pacat.c:601
#, c-format
-msgid "pa_stream_update_timing_info() failed: %s\n"
-msgstr "pa_stream_update_timing_info()失败:%s\n"
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "时间:%0.3f 秒;延迟:%0.0f 微秒。"
-#: ../src/utils/pacat.c:511
+#: ../src/utils/pacat.c:620
#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() failed: %s"
+
+#: ../src/utils/pacat.c:630
+#, fuzzy, c-format
msgid ""
"%s [options]\n"
"\n"
@@ -1435,8 +1339,10 @@ msgid ""
"44100)\n"
" --format=SAMPLEFORMAT The sample type, one of s16le, "
"s16be, u8, float32le,\n"
-" float32be, ulaw, alaw, s32le, s32be "
-"(defaults to s16ne)\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
" --channels=CHANNELS The number of channels, 1 for mono, "
"2 for stereo\n"
" (defaults to 2)\n"
@@ -1459,11 +1365,20 @@ msgid ""
"bytes.\n"
" --process-time=BYTES Request the specified process time "
"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
msgstr ""
"%s [options]\n"
"\n"
" -h, --help 显示此帮助\n"
-" --version 显示版本å·\n"
+" --version 显示版本\n"
"\n"
" -r, --record 为录制创建连接\n"
" -p, --playback 为回放创建连接\n"
@@ -1471,29 +1386,30 @@ msgstr ""
" -v, --verbose å¯ç”¨è¯¦è¿°æ“作\n"
"\n"
" -s, --server=SERVER è¦è¿žæŽ¥çš„æœåŠ¡å™¨å\n"
-" -d, --device=DEVICE è¦è¿žæŽ¥çš„sink/sourceå\n"
-" -n, --client-name=NAME 指定客户端在æœåŠ¡å™¨ä¸Šçš„åç§°\n"
-" --stream-name=NAME 指定æµåœ¨æœåŠ¡å™¨ä¸Šçš„åç§°\n"
+" -d, --device=DEVICE è¦è¿žæŽ¥çš„æ¼/æºåç§°\n"
+" -n, --client-name=NAME 如何在æœåŠ¡å™¨ä¸­è°ƒç”¨æ­¤å®¢æˆ·ç«¯\n"
+" --stream-name=NAME 如何在æœåŠ¡å™¨ä¸­è°ƒç”¨è¿™ä¸ªæµ\n"
" --volume=VOLUME 指定åˆå§‹ï¼ˆçº¿æ€§ï¼‰éŸ³é‡ï¼Œå–值在0...65536"
"之间\n"
-" --rate=SAMPLERATE 采样频率(å•ä½Hz,默认为44100)\n"
-" --format=SAMPLEFORMAT 采样类型,从s16le,s16be,u8,"
-"float32le,\n"
-" float32be,ulaw,alaw,s32le,s32be中"
-"å–(默认为s16ne)\n"
+" --rate=SAMPLERATE 采样频率(å•ä½ Hz,默认为44100)\n"
+" --format=SAMPLEFORMAT 采样类型,s16leã€s16beã€u8ã€"
+"float32le 之一\n"
+" float32beã€ulawã€alawã€s32leã€s32be "
+"中å–(默认为 s16ne)\n"
" --channels=CHANNELS é€šé“æ•°ï¼Œ1为å•声é“,2为立体声(默认为"
"2)\n"
" --channel-map=CHANNELMAP å–ä»£é»˜è®¤å€¼çš„é€šé“æ˜ å°„表\n"
-" --fix-format 从æµè¿žæŽ¥çš„音频出å£å¤„å–采样格å¼ã€‚\n"
-" --fix-rate 从æµè¿žæŽ¥çš„音频出å£å¤„å–采样率。\n"
-" --fix-channels 从æµè¿žæŽ¥çš„音频出å£å¤„å–é€šé“æ•°å’Œé€šé“映"
-"射表。\n"
-" --no-remix Don't upmix or downmix channels.\n"
+" --fix-format 从æµè¿žæŽ¥çš„æ¼ä¸­æå–采样格å¼ã€‚\n"
+" --fix-rate 从æµè¿žæŽ¥çš„æ¼ä¸­æå–采样率。\n"
+" --fix-channels 从æµè¿žæŽ¥çš„æ¼ä¸­æå–é€šé“æ•°å’Œé€šé“映射"
+"表。\n"
+" --no-remix ä¸è¦å¯¹é€šé“进行 upmix 或者 downmix æ“"
+"作。\n"
" --no-remap æ ¹æ®ä¸‹æ ‡è€Œéžåç§°æ¥æ˜ å°„通é“。\n"
" --latency=BYTES 请求指定字节数的延迟。\n"
" --process-time=BYTES æ¯æ¬¡è¯·æ±‚æŒ‡å®šå­—èŠ‚æ•°çš„å¤„ç†æ—¶é—´ã€‚\n"
-#: ../src/utils/pacat.c:612
+#: ../src/utils/pacat.c:758
#, c-format
msgid ""
"pacat %s\n"
@@ -1504,129 +1420,169 @@ msgstr ""
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
-#: ../src/utils/pacat.c:669
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
#, c-format
-msgid "Invalid channel map '%s'\n"
-msgstr "æ— æ•ˆçš„é€šé“æ˜ å°„æè¿°'%s'\n"
+msgid "Invalid client name '%s'"
+msgstr "无效客户端åç§° '%s'"
-#: ../src/utils/pacat.c:698
+#: ../src/utils/pacat.c:806
#, c-format
-msgid "Invalid latency specification '%s'\n"
-msgstr "无效的延迟规格æè¿° %s'\n"
+msgid "Invalid stream name '%s'"
+msgstr "无效æµåç§° '%s'"
-#: ../src/utils/pacat.c:705
+#: ../src/utils/pacat.c:843
#, c-format
-msgid "Invalid process time specification '%s'\n"
-msgstr "æ— æ•ˆçš„å¤„ç†æ—¶é—´æè¿° '%s'\n"
+msgid "Invalid channel map '%s'"
+msgstr "æ— æ•ˆé€šé“æ˜ å°„ '%s'"
-#: ../src/utils/pacat.c:716
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
#, c-format
-msgid "Invalid sample specification\n"
-msgstr "无效的采样æè¿°\n"
+msgid "Invalid latency specification '%s'"
+msgstr "无效延迟说明 %s'"
-#: ../src/utils/pacat.c:721
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
#, c-format
-msgid "Channel map doesn't match sample specification\n"
-msgstr "é€šé“æ˜ å°„与采样æè¿°ä¸åŒ¹é…\n"
+msgid "Invalid process time specification '%s'"
+msgstr "æ— æ•ˆå¤„ç†æ—¶é—´è¯´æ˜Ž '%s'"
-#: ../src/utils/pacat.c:728
+#: ../src/utils/pacat.c:905
#, c-format
-msgid "Opening a %s stream with sample specification '%s'.\n"
-msgstr "以采样规格'%s'打开%sæµã€‚\n"
+msgid "Invalid property '%s'"
+msgstr "无效性能 '%s'"
-#: ../src/utils/pacat.c:728
-msgid "recording"
-msgstr "正在录制"
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "æœªçŸ¥æ–‡ä»¶æ ¼å¼ %s。"
-#: ../src/utils/pacat.c:728
-msgid "playback"
-msgstr "回放"
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "无效采样说明"
-#: ../src/utils/pacat.c:736
+#: ../src/utils/pacat.c:951
#, c-format
-msgid "open(): %s\n"
-msgstr "open():%s\n"
+msgid "open(): %s"
+msgstr "open(): %s"
-#: ../src/utils/pacat.c:741
+#: ../src/utils/pacat.c:956
#, c-format
-msgid "dup2(): %s\n"
-msgstr "dup2():%s\n"
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
-#: ../src/utils/pacat.c:751
-#, c-format
-msgid "Too many arguments.\n"
-msgstr "傿•°è¿‡å¤šã€‚\n"
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "傿•°è¿‡å¤šã€‚"
-#: ../src/utils/pacat.c:764 ../src/utils/pasuspender.c:280
-#: ../src/utils/pactl.c:1017 ../src/utils/paplay.c:381
-#, c-format
-msgid "pa_mainloop_new() failed.\n"
-msgstr "pa_mainloop_new()失败。\n"
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "为文件获å–采样说明失败。"
-#: ../src/utils/pacat.c:785
-#, c-format
-msgid "io_new() failed.\n"
-msgstr "io_new()失败。\n"
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "打开声音文件失败。"
-#: ../src/utils/pacat.c:791 ../src/utils/pasuspender.c:293
-#: ../src/utils/pactl.c:1031 ../src/utils/paplay.c:396
-#, c-format
-msgid "pa_context_new() failed.\n"
-msgstr "pa_context_new()失败。\n"
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "警告:指定的采样说明将覆盖文件中的说明。"
-#: ../src/utils/pacat.c:799
-#, fuzzy, c-format
-msgid "pa_context_connect() failed: %s\n"
-msgstr "pa_context_connect()失败:%s"
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "从文件中确定采样说明失败。"
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "è­¦å‘Šï¼šä»Žæ–‡ä»¶ä¸­ç¡®å®šé€šé“æ˜ å°„失败。"
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "é€šé“æ˜ å°„与采样说明ä¸åŒ¹é…"
-#: ../src/utils/pacat.c:810
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "è­¦å‘Šï¼šåœ¨æ–‡ä»¶ä¸­å†™å…¥é€šé“æ˜ å°„失败。"
+
+#: ../src/utils/pacat.c:1049
#, c-format
-msgid "time_new() failed.\n"
-msgstr "time_new()失败。\n"
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "使用采样说明 '%s' å’Œé€šé“æ˜ å°„ '%s' 打开 %s æµã€‚"
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "正在录制"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "回放"
-#: ../src/utils/pacat.c:817 ../src/utils/pasuspender.c:301
-#: ../src/utils/pactl.c:1042 ../src/utils/paplay.c:410
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() failed."
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() failed."
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() failed."
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
#, c-format
-msgid "pa_mainloop_run() failed.\n"
-msgstr "pa_mainloop_run()失败。\n"
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect()失败:%s"
-#: ../src/utils/pasuspender.c:81
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() failed."
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() failed."
+
+#: ../src/utils/pasuspender.c:79
#, c-format
msgid "fork(): %s\n"
msgstr "fork():%s\n"
-#: ../src/utils/pasuspender.c:92
+#: ../src/utils/pasuspender.c:90
#, c-format
msgid "execvp(): %s\n"
msgstr "execvp():%s\n"
-#: ../src/utils/pasuspender.c:109
+#: ../src/utils/pasuspender.c:107
#, c-format
msgid "Failure to suspend: %s\n"
msgstr "挂起失败:%s\n"
-#: ../src/utils/pasuspender.c:124
+#: ../src/utils/pasuspender.c:122
#, c-format
msgid "Failure to resume: %s\n"
msgstr "æ¢å¤å¤±è´¥ï¼š%s\n"
-#: ../src/utils/pasuspender.c:147
+#: ../src/utils/pasuspender.c:145
#, c-format
msgid "WARNING: Sound server is not local, not suspending.\n"
msgstr "è­¦å‘Šï¼šéžæœ¬åœ°å£°éŸ³æœåŠ¡å™¨ï¼Œä¸ä¼šæŒ‚起。\n"
-#: ../src/utils/pasuspender.c:176 ../src/utils/pactl.c:768
-#: ../src/utils/paplay.c:191
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "连接失败:%s\n"
+
+#: ../src/utils/pasuspender.c:174
#, c-format
msgid "Got SIGINT, exiting.\n"
msgstr "收到SIGINT,正在退出。\n"
-#: ../src/utils/pasuspender.c:194
+#: ../src/utils/pasuspender.c:192
#, c-format
msgid "WARNING: Child process terminated by signal %u\n"
msgstr "警告:å­è¿›ç¨‹è¢«ä¿¡å·%u终止\n"
-#: ../src/utils/pasuspender.c:212
+#: ../src/utils/pasuspender.c:210
#, c-format
msgid ""
"%s [options] ... \n"
@@ -1644,7 +1600,7 @@ msgstr ""
" -s, --server=SERVER è¦è¿žæŽ¥çš„æœåŠ¡å™¨å\n"
"\n"
-#: ../src/utils/pasuspender.c:251
+#: ../src/utils/pasuspender.c:246
#, c-format
msgid ""
"pasuspender %s\n"
@@ -1655,35 +1611,61 @@ msgstr ""
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
-#: ../src/utils/pactl.c:108
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new()失败。\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new()失败。\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run()失败。\n"
+
+#: ../src/utils/pactl.c:134
#, c-format
-msgid "Failed to get statistics: %s\n"
-msgstr "获å–统计数æ®å¤±è´¥ï¼š%s\n"
+msgid "Failed to get statistics: %s"
+msgstr "获å–统计数æ®å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:114
+#: ../src/utils/pactl.c:140
#, c-format
msgid "Currently in use: %u blocks containing %s bytes total.\n"
msgstr "当å‰ä½¿ç”¨ï¼š%uå—,总共%s字节。\n"
-#: ../src/utils/pactl.c:117
+#: ../src/utils/pactl.c:143
#, c-format
msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
msgstr "整个生命周期所得分é…:%uå—,总共%s字节。\n"
-#: ../src/utils/pactl.c:120
+#: ../src/utils/pactl.c:146
#, c-format
msgid "Sample cache size: %s\n"
msgstr "采样缓存大å°ï¼š%s\n"
-#: ../src/utils/pactl.c:129
+#: ../src/utils/pactl.c:155
#, c-format
-msgid "Failed to get server information: %s\n"
-msgstr "èŽ·å–æœåŠ¡å™¨ä¿¡æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get server information: %s"
+msgstr "èŽ·å–æœåŠ¡å™¨ä¿¡æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:137
+#: ../src/utils/pactl.c:160
#, c-format
msgid ""
-"User name: %s\n"
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, fuzzy, c-format
+msgid ""
+"User Name: %s\n"
"Host Name: %s\n"
"Server Name: %s\n"
"Server Version: %s\n"
@@ -1691,7 +1673,7 @@ msgid ""
"Default Channel Map: %s\n"
"Default Sink: %s\n"
"Default Source: %s\n"
-"Cookie: %08x\n"
+"Cookie: %04x:%04x\n"
msgstr ""
"用户å:%s\n"
"主机å:%s\n"
@@ -1703,12 +1685,12 @@ msgstr ""
"默认æºï¼š %s\n"
"Cookie:%08x\n"
-#: ../src/utils/pactl.c:178
+#: ../src/utils/pactl.c:218
#, c-format
-msgid "Failed to get sink information: %s\n"
-msgstr "获å–音频出å£ä¿¡æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get sink information: %s"
+msgstr "获å–音频出å£ä¿¡æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:194
+#: ../src/utils/pactl.c:234
#, c-format
msgid ""
"Sink #%u\n"
@@ -1747,12 +1729,22 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:258
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
#, c-format
-msgid "Failed to get source information: %s\n"
-msgstr "获å–音频入å£ä¿¡æ¯å¤±è´¥ï¼š%s\n"
+msgid "\tPorts:\n"
+msgstr "\tPorts:\n"
-#: ../src/utils/pactl.c:274
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr "\tActive Port: %s\n"
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "获å–音频入å£ä¿¡æ¯å¤±è´¥ï¼š%s"
+
+#: ../src/utils/pactl.c:326
#, c-format
msgid ""
"Source #%u\n"
@@ -1791,20 +1783,20 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:306 ../src/utils/pactl.c:350 ../src/utils/pactl.c:385
-#: ../src/utils/pactl.c:422 ../src/utils/pactl.c:481 ../src/utils/pactl.c:482
-#: ../src/utils/pactl.c:492 ../src/utils/pactl.c:536 ../src/utils/pactl.c:537
-#: ../src/utils/pactl.c:543 ../src/utils/pactl.c:586 ../src/utils/pactl.c:587
-#: ../src/utils/pactl.c:594
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
msgid "n/a"
msgstr "n/a"
-#: ../src/utils/pactl.c:324
+#: ../src/utils/pactl.c:388
#, c-format
-msgid "Failed to get module information: %s\n"
-msgstr "èŽ·å–æ¨¡å—ä¿¡æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get module information: %s"
+msgstr "èŽ·å–æ¨¡å—ä¿¡æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:342
+#: ../src/utils/pactl.c:406
#, c-format
msgid ""
"Module #%u\n"
@@ -1821,12 +1813,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:361
+#: ../src/utils/pactl.c:425
#, c-format
-msgid "Failed to get client information: %s\n"
-msgstr "获å–客户端信æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get client information: %s"
+msgstr "获å–客户端信æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:379
+#: ../src/utils/pactl.c:443
#, c-format
msgid ""
"Client #%u\n"
@@ -1841,12 +1833,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:396
+#: ../src/utils/pactl.c:460
#, c-format
-msgid "Failed to get card information: %s\n"
-msgstr "获å–声å¡ä¿¡æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get card information: %s"
+msgstr "获å–声å¡ä¿¡æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:414
+#: ../src/utils/pactl.c:478
#, c-format
msgid ""
"Card #%u\n"
@@ -1863,22 +1855,22 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:428
+#: ../src/utils/pactl.c:492
#, c-format
msgid "\tProfiles:\n"
msgstr "\tProfiles:\n"
-#: ../src/utils/pactl.c:434
+#: ../src/utils/pactl.c:498
#, c-format
msgid "\tActive Profile: %s\n"
msgstr "\tActive Profile: %s\n"
-#: ../src/utils/pactl.c:445
+#: ../src/utils/pactl.c:509
#, c-format
-msgid "Failed to get sink input information: %s\n"
-msgstr "获å–音频出å£è¾“入信æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get sink input information: %s"
+msgstr "获å–音频出å£è¾“入信æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:464
+#: ../src/utils/pactl.c:528
#, c-format
msgid ""
"Sink Input #%u\n"
@@ -1915,12 +1907,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:503
+#: ../src/utils/pactl.c:567
#, c-format
-msgid "Failed to get source output information: %s\n"
-msgstr "获å–音频入å£è¾“出信æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get source output information: %s"
+msgstr "获å–音频入å£è¾“出信æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:523
+#: ../src/utils/pactl.c:587
#, c-format
msgid ""
"Source Output #%u\n"
@@ -1949,12 +1941,12 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:554
+#: ../src/utils/pactl.c:618
#, c-format
-msgid "Failed to get sample information: %s\n"
-msgstr "获å–采样信æ¯å¤±è´¥ï¼š%s\n"
+msgid "Failed to get sample information: %s"
+msgstr "获å–采样信æ¯å¤±è´¥ï¼š%s"
-#: ../src/utils/pactl.c:572
+#: ../src/utils/pactl.c:636
#, c-format
msgid ""
"Sample #%u\n"
@@ -1985,23 +1977,80 @@ msgstr ""
"\tProperties:\n"
"\t\t%s\n"
-#: ../src/utils/pactl.c:602 ../src/utils/pactl.c:612
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
#, c-format
-msgid "Failure: %s\n"
-msgstr "失败:%s\n"
+msgid "Failure: %s"
+msgstr "失败:%s"
-#: ../src/utils/pactl.c:636
+#: ../src/utils/pactl.c:700
#, c-format
-msgid "Failed to upload sample: %s\n"
-msgstr "上传采样失败:%s\n"
+msgid "Failed to upload sample: %s"
+msgstr "上传采样失败:%s"
-#: ../src/utils/pactl.c:653
-#, c-format
-msgid "Premature end of file\n"
-msgstr "文件过早结æŸ\n"
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "文件过早结æŸ"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
-#: ../src/utils/pactl.c:774
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "无效æœåС噍"
+
+#: ../src/utils/pactl.c:787
#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "收到 SIGINT,正在退出。"
+
+#: ../src/utils/pactl.c:961
+#, fuzzy, c-format
msgid ""
"%s [options] stat\n"
"%s [options] list\n"
@@ -2009,13 +2058,22 @@ msgid ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2031,13 +2089,21 @@ msgstr ""
"%s [options] upload-sample FILENAME [NAME]\n"
"%s [options] play-sample NAME [SINK]\n"
"%s [options] remove-sample NAME\n"
-"%s [options] move-sink-input ID SINK\n"
-"%s [options] move-source-output ID SOURCE\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
"%s [options] load-module NAME [ARGS ...]\n"
-"%s [options] unload-module ID\n"
-"%s [options] suspend-sink [SINK] 1|0\n"
-"%s [options] suspend-source [SOURCE] 1|0\n"
-"%s [options] set-card-profile [CARD] [PROFILE] \n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
"\n"
" -h, --help Show this help\n"
" --version Show version\n"
@@ -2047,7 +2113,7 @@ msgstr ""
" -n, --client-name=NAME How to call this client on the "
"server\n"
-#: ../src/utils/pactl.c:826
+#: ../src/utils/pactl.c:1026
#, c-format
msgid ""
"pactl %s\n"
@@ -2058,74 +2124,106 @@ msgstr ""
"Compiled with libpulse %s\n"
"Linked with libpulse %s\n"
-#: ../src/utils/pactl.c:865
-#, c-format
-msgid "Please specify a sample file to load\n"
-msgstr "请指定è¦åŠ è½½çš„é‡‡æ ·æ–‡ä»¶\n"
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "请指定è¦åŠ è½½çš„é‡‡æ ·æ–‡ä»¶"
-#: ../src/utils/pactl.c:887
-#, c-format
-msgid "Failed to open sound file.\n"
-msgstr "打开声音文件失败。\n"
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "打开声音文件失败。"
-#: ../src/utils/pactl.c:899
-#, c-format
-msgid "You have to specify a sample name to play\n"
-msgstr "ä½ å¿…é¡»æŒ‡å®šè¦æ’­æ”¾çš„采样å\n"
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "警告:从文件中确定采样说明失败。"
-#: ../src/utils/pactl.c:911
-#, c-format
-msgid "You have to specify a sample name to remove\n"
-msgstr "你必须指定è¦åˆ é™¤çš„采样å\n"
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr "æ‚¨å¿…é¡»æŒ‡å®šè¦æ’­æ”¾çš„采样å"
-#: ../src/utils/pactl.c:919
-#, c-format
-msgid "You have to specify a sink input index and a sink\n"
-msgstr "你必须指定音频出å£ç´¢å¼•和音频出å£\n"
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr "您必须指定è¦åˆ é™¤çš„采样å"
-#: ../src/utils/pactl.c:928
-#, c-format
-msgid "You have to specify a source output index and a source\n"
-msgstr "你必须指定音频入å£è¾“出索引和音频入å£\n"
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr "您必须指定æ¼è¾“入索引和æ¼"
-#: ../src/utils/pactl.c:942
-#, c-format
-msgid "You have to specify a module name and arguments.\n"
-msgstr "必须指定模å—åå’Œå‚æ•°ã€‚\n"
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr "您必须指定æºè¾“出索引和æº"
-#: ../src/utils/pactl.c:962
-#, c-format
-msgid "You have to specify a module index\n"
-msgstr "必须指定模å—索引\n"
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr "必须指定模å—åå’Œå‚æ•°ã€‚"
-#: ../src/utils/pactl.c:972
-#, c-format
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr "必须指定模å—索引"
+
+#: ../src/utils/pactl.c:1183
msgid ""
-"You may not specify more than one sink. You have to specify a boolean "
-"value.\n"
-msgstr "ä¸å¯æŒ‡å®šå¤šä¸ªéŸ³é¢‘出å£ã€‚必须指定一个布尔值。\n"
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr "ä¸å¯æŒ‡å®šå¤šä¸ªæ¼ã€‚必须指定一个布尔值。"
-#: ../src/utils/pactl.c:985
-#, c-format
+#: ../src/utils/pactl.c:1196
msgid ""
"You may not specify more than one source. You have to specify a boolean "
-"value.\n"
-msgstr "ä¸å¯æŒ‡å®šå¤šä¸ªæºã€‚必须指定一个布尔值。\n"
+"value."
+msgstr "ä¸å¯æŒ‡å®šå¤šä¸ªæºã€‚必须指定一个布尔值。"
-#: ../src/utils/pactl.c:997
-#, c-format
-msgid "You have to specify a card name/index and a profile name\n"
-msgstr "你必须指定声å¡åç§°/索引和侧写åç§°\n"
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr "您必须指定声å¡åç§°/索引和侧写åç§°"
-#: ../src/utils/pactl.c:1012
-#, c-format
-msgid "No valid command specified.\n"
-msgstr "未指定有效的命令。\n"
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr "您必须指定æ¼åç§°/索引和端å£åç§°"
-#: ../src/utils/pactl.c:1037 ../src/utils/paplay.c:404
-#, c-format
-msgid "pa_context_connect() failed: %s"
-msgstr "pa_context_connect()失败:%s"
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr "您必须指定æºåç§°/索引和端å£åç§°"
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr "您必须指定æ¼åç§°/索引和å·"
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr "无效采样说明"
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr "您必须指定æºåç§°/索引和å·"
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr "您必须指定æ¼è¾“入索引和å·"
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr "无效露输入索引"
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr "您必须指定æ¼åç§°/索引和é™éŸ³å¸ƒå°”值"
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr "您必须指定æºåç§°/索引和é™éŸ³å¸ƒå°”值"
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr "您必须指定露输入索引和é™éŸ³å¸ƒå°”值"
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr "无效æ¼è¾“入索引说明"
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "未指定有效的命令。"
#: ../src/utils/pax11publish.c:61
#, c-format
@@ -2205,126 +2303,48 @@ msgstr "加载cookieæ•°æ®å¤±è´¥\n"
msgid "Not yet implemented.\n"
msgstr "尚未实现。\n"
-#: ../src/utils/pacmd.c:64
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr "没有 PulseAudio 守护进程在è¿è¡Œï¼Œæˆ–者没有作为会è¯å®ˆæŠ¤è¿›ç¨‹è¿è¡Œã€‚"
+
+#: ../src/utils/pacmd.c:70
#, c-format
msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
msgstr "socket(PF_UNIX, SOCK_STREAM, 0):%s"
-#: ../src/utils/pacmd.c:81
+#: ../src/utils/pacmd.c:87
#, c-format
msgid "connect(): %s"
msgstr "connect():%s"
-#: ../src/utils/pacmd.c:89
+#: ../src/utils/pacmd.c:95
msgid "Failed to kill PulseAudio daemon."
msgstr "æ€æ­»PulseAudioåŽå°ç¨‹åºå¤±è´¥ã€‚"
-#: ../src/utils/pacmd.c:97
+#: ../src/utils/pacmd.c:103
msgid "Daemon not responding."
msgstr "åŽå°ç¨‹åºæœªå“应。"
-#: ../src/utils/pacmd.c:144
+#: ../src/utils/pacmd.c:178
#, c-format
-msgid "select(): %s"
-msgstr "select():%s"
+msgid "poll(): %s"
+msgstr "poll(): %s"
-#: ../src/utils/pacmd.c:154 ../src/utils/pacmd.c:171
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
#, c-format
msgid "read(): %s"
msgstr "read():%s"
-#: ../src/utils/pacmd.c:187 ../src/utils/pacmd.c:201
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
#, c-format
msgid "write(): %s"
msgstr "write():%s"
-#: ../src/utils/paplay.c:139
-#, c-format
-msgid "Stream successfully created\n"
-msgstr "æˆåŠŸåˆ›å»ºæµ\n"
-
-#: ../src/utils/paplay.c:144
-#, c-format
-msgid "Stream errror: %s\n"
-msgstr "æµé”™è¯¯ï¼š%s\n"
-
-#: ../src/utils/paplay.c:165
-#, c-format
-msgid "Connection established.\n"
-msgstr "连接已建立。\n"
-
-#: ../src/utils/paplay.c:198
-#, c-format
-msgid ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help Show this help\n"
-" --version Show version\n"
-"\n"
-" -v, --verbose Enable verbose operation\n"
-"\n"
-" -s, --server=SERVER The name of the server to connect "
-"to\n"
-" -d, --device=DEVICE The name of the sink to connect to\n"
-" -n, --client-name=NAME How to call this client on the "
-"server\n"
-" --stream-name=NAME How to call this stream on the "
-"server\n"
-" --volume=VOLUME Specify the initial (linear) volume "
-"in range 0...65536\n"
-" --channel-map=CHANNELMAP Set the channel map to the use\n"
-msgstr ""
-"%s [options] [FILE]\n"
-"\n"
-" -h, --help 显示此帮助\n"
-" --version 显示版本\n"
-"\n"
-" -v, --verbose å¯ç”¨è¯¦è¿°æ“作\n"
-"\n"
-" -s, --server=SERVER è¦è¿žæŽ¥çš„æœåŠ¡å™¨å\n"
-" -d, --device=DEVICE è¦è¿žæŽ¥çš„音频出å£å\n"
-" -n, --client-name=NAME 此客户端在æœåŠ¡å™¨ä¸Šçš„åç§°\n"
-" --stream-name=NAME æ­¤æµåœ¨æœåŠ¡å™¨ä¸Šçš„åç§°\n"
-" --volume=VOLUME 指定åˆå§‹ï¼ˆçº¿æ€§ï¼‰éŸ³é‡ï¼Œå–值在0...65536"
-"之间\n"
-" --channel-map=CHANNELMAP è®¾å®šä½¿ç”¨çš„é€šé“æ˜ å°„表\n"
-
-#: ../src/utils/paplay.c:255
-#, c-format
-msgid ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-msgstr ""
-"paplay %s\n"
-"Compiled with libpulse %s\n"
-"Linked with libpulse %s\n"
-
-#: ../src/utils/paplay.c:292
-#, c-format
-msgid "Invalid channel map\n"
-msgstr "æ— æ•ˆçš„é€šé“æ˜ å°„表\n"
-
-#: ../src/utils/paplay.c:314
-#, c-format
-msgid "Failed to open file '%s'\n"
-msgstr "打开文件'%s'失败\n"
-
-#: ../src/utils/paplay.c:350
-#, c-format
-msgid "Channel map doesn't match file.\n"
-msgstr "é€šé“æ˜ å°„表与文件ä¸åŒ¹é…。\n"
-
-#: ../src/utils/paplay.c:376
-#, c-format
-msgid "Using sample spec '%s'\n"
-msgstr "正在使用采样规格'%s'\n"
-
-#: ../src/pulsecore/lock-autospawn.c:126 ../src/pulsecore/lock-autospawn.c:207
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
msgid "Cannot access autospawn lock."
msgstr "ä¸èƒ½è®¿é—®autospawné”。"
-#: ../src/modules/alsa/alsa-sink.c:393 ../src/modules/alsa/alsa-sink.c:541
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
#, c-format
msgid ""
"ALSA woke us up to write new data to the device, but there was actually "
@@ -2340,7 +2360,7 @@ msgstr ""
"æé†’我们设置 POLLOUT -- 但结果是 snd_pcm_avail() 返回 0 或者å¦ä¸€ä¸ªå°äºŽæœ€å°å¯"
"用值的数值。"
-#: ../src/modules/alsa/alsa-source.c:377 ../src/modules/alsa/alsa-source.c:516
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
#, c-format
msgid ""
"ALSA woke us up to read new data from the device, but there was actually "
@@ -2356,34 +2376,259 @@ msgstr ""
"æé†’我们设置 POLLOUT -- 但结果是 snd_pcm_avail() 返回 0 或者å¦ä¸€ä¸ªå°äºŽæœ€å°å¯"
"用值的数值。"
-#: ../src/modules/alsa/module-alsa-card.c:114
-#, c-format
-msgid "Output %s + Input %s"
-msgstr "输出 %s + 输入 %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:117
-#, c-format
-msgid "Output %s"
-msgstr "输出 %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:121
-#, c-format
-msgid "Input %s"
-msgstr "输入 %s"
-
-#: ../src/modules/alsa/module-alsa-card.c:170
-#: ../src/modules/bluetooth/module-bluetooth-device.c:2006
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
msgid "Off"
msgstr "关闭"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1976
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
msgid "High Fidelity Playback (A2DP)"
msgstr "高ä¿çœŸå›žæ”¾ï¼ˆA2DP)"
-#: ../src/modules/bluetooth/module-bluetooth-device.c:1991
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "高ä¿çœŸé‡‡é›†ï¼ˆA2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
msgid "Telephony Duplex (HSP/HFP)"
msgstr "åŒå·¥ç”µè¯ï¼ˆHSP/HFP)"
-#: ../src/modules/reserve-wrap.c:139
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
msgid "PulseAudio Sound Server"
msgstr "PulseAudio 声音æœåС噍"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "输出设备"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "输入设备"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "@HOSTNAME@ 中的音频"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "输入"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr "扩展åžè¾“å…¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr "扩展åžéº¦å…‹é£Ž"
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "Line-In"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "麦克风"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "外部麦克风"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "内部麦克风"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "无线电"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "视频"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "自动增益控制"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "无自动增益控制"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "无加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "å‡è¡¡å™¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "æ— å‡è¡¡å™¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "无加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "模拟耳机"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "模拟输入"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "模拟麦克风"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "模拟 Line-In"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "模拟无线电"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "模拟视频"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "模拟输出 "
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "模拟耳机"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "模拟输出(LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "模拟å•声é“输出"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "模拟立体声"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "模拟å•声é“"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "模拟立体声"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "模拟环绕 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "模拟环绕 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "模拟环绕 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "模拟环绕 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "模拟环绕 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "模拟环绕 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "模拟环绕 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "模拟环绕 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "模拟环绕 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "模拟环绕 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "模拟环绕 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "数字立体声(IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "数字环绕 4.0(IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "数字环绕 4.0(IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "数字环绕 5.1(IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "数字立体声(HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "模拟å•声é“åŒå·¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "模拟立体声åŒå·¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "数字立体声åŒå·¥ï¼ˆIEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "低频脉冲"
diff --git a/po/zh_TW.po b/po/zh_TW.po
new file mode 100644
index 00000000..50b049b3
--- /dev/null
+++ b/po/zh_TW.po
@@ -0,0 +1,2367 @@
+# Chinese (Taiwan) translation for pulseaudio.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# Cheng-Chia Tseng <pswo10680@gmail.com>, 2010
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PulseAudio Volume Control\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-02-21 21:15+0100\n"
+"PO-Revision-Date: 2010-02-20 12:55+0800\n"
+"Last-Translator: Cheng-Chia Tseng <pswo10680@gmail.com>\n"
+"Language-Team: zh_TW\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-Language: Chinese\n"
+"X-Poedit-Country: TAIWAN\n"
+
+#: ../src/modules/alsa/alsa-util.c:861 ../src/pulsecore/sink.c:2631
+#, c-format
+msgid "%s %s"
+msgstr "%s %s"
+
+#: ../src/modules/alsa/alsa-util.c:1109
+#, c-format
+msgid ""
+"snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu "
+"ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-util.c:1150
+#, c-format
+msgid ""
+"snd_pcm_delay() returned a value that is exceptionally large: %li bytes (%s%"
+"lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-util.c:1197
+#, c-format
+msgid ""
+"snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes "
+"(%lu ms).\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers."
+msgstr ""
+
+#: ../src/modules/module-always-sink.c:39
+msgid "Always keeps at least one sink loaded even if it's a null one"
+msgstr ""
+
+#: ../src/modules/module-always-sink.c:83
+msgid "Dummy Output"
+msgstr "Dummy Output"
+
+#: ../src/modules/module-ladspa-sink.c:49
+msgid "Virtual LADSPA sink"
+msgstr ""
+
+#: ../src/modules/module-ladspa-sink.c:53
+msgid ""
+"sink_name=<name for the sink> sink_properties=<properties for the sink> "
+"master=<name of sink to filter> format=<sample format> rate=<sample rate> "
+"channels=<number of channels> channel_map=<channel map> plugin=<ladspa "
+"plugin name> label=<ladspa plugin label> control=<comma seperated list of "
+"input control values>"
+msgstr ""
+
+#: ../src/modules/module-null-sink.c:55
+msgid "Clocked NULL sink"
+msgstr "Clocked Null sink"
+
+#: ../src/modules/module-null-sink.c:291
+msgid "Null Output"
+msgstr "Null Output"
+
+#: ../src/pulsecore/sink.c:2615
+msgid "Internal Audio"
+msgstr "內部音效"
+
+#: ../src/pulsecore/sink.c:2620
+msgid "Modem"
+msgstr "數據機"
+
+#: ../src/daemon/ltdl-bind-now.c:124
+msgid "Failed to find original lt_dlopen loader."
+msgstr "找ä¸åˆ° original lt_dlopen loader。"
+
+#: ../src/daemon/ltdl-bind-now.c:129
+msgid "Failed to allocate new dl loader."
+msgstr "æœªèƒ½åˆ†é…æ–°çš„ dl loader。"
+
+#: ../src/daemon/ltdl-bind-now.c:142
+msgid "Failed to add bind-now-loader."
+msgstr "未能加入 bind-now-loader。"
+
+#: ../src/daemon/main.c:146
+#, c-format
+msgid "Got signal %s."
+msgstr "å–得信號 %s。"
+
+#: ../src/daemon/main.c:173
+msgid "Exiting."
+msgstr "正在退出。"
+
+#: ../src/daemon/main.c:191
+#, c-format
+msgid "Failed to find user '%s'."
+msgstr "找ä¸åˆ°ä½¿ç”¨è€…「%sã€ã€‚"
+
+#: ../src/daemon/main.c:196
+#, c-format
+msgid "Failed to find group '%s'."
+msgstr "找ä¸åˆ°ç¾¤çµ„「%sã€ã€‚"
+
+#: ../src/daemon/main.c:200
+#, c-format
+msgid "Found user '%s' (UID %lu) and group '%s' (GID %lu)."
+msgstr "找到使用者「%sã€(UID %lu) 與群組「%sã€(GID %lu)。"
+
+#: ../src/daemon/main.c:205
+#, c-format
+msgid "GID of user '%s' and of group '%s' don't match."
+msgstr "使用者「%sã€çš„ GID 與群組「%sã€çš„ GID ä¸ç›¸ç¬¦ã€‚"
+
+#: ../src/daemon/main.c:210
+#, c-format
+msgid "Home directory of user '%s' is not '%s', ignoring."
+msgstr "使用者「%sã€çš„å®¶ç›®éŒ„ä¸æ˜¯ã€Œ%sã€ï¼Œå¿½ç•¥ä¸­ã€‚"
+
+#: ../src/daemon/main.c:213 ../src/daemon/main.c:218
+#, c-format
+msgid "Failed to create '%s': %s"
+msgstr "未能建立「%sã€ï¼š%s"
+
+#: ../src/daemon/main.c:225
+#, c-format
+msgid "Failed to change group list: %s"
+msgstr "未能變更群組清單:%s"
+
+#: ../src/daemon/main.c:241
+#, c-format
+msgid "Failed to change GID: %s"
+msgstr "未能變更 GIC:%s"
+
+#: ../src/daemon/main.c:257
+#, c-format
+msgid "Failed to change UID: %s"
+msgstr "未能變更 UID:%s"
+
+#: ../src/daemon/main.c:276
+msgid "Successfully dropped root privileges."
+msgstr "æˆåŠŸåœ°æ”¾ä¸‹ root 特權。"
+
+#: ../src/daemon/main.c:284
+msgid "System wide mode unsupported on this platform."
+msgstr "本平å°ä¸æ”¯æ´ system wide 模å¼ã€‚"
+
+#: ../src/daemon/main.c:302
+#, c-format
+msgid "setrlimit(%s, (%u, %u)) failed: %s"
+msgstr "setrlimit(%s, (%u, %u)) 失敗:%s"
+
+#: ../src/daemon/main.c:502
+msgid "Failed to parse command line."
+msgstr "未能解æžå‘½ä»¤åˆ—。"
+
+#: ../src/daemon/main.c:535
+msgid ""
+"System mode refused for non-root user. Only starting the D-Bus server lookup "
+"service."
+msgstr ""
+
+#: ../src/daemon/main.c:617
+msgid "Daemon not running"
+msgstr "å¹•å¾Œç¨‹å¼æ²’有在執行中"
+
+#: ../src/daemon/main.c:619
+#, c-format
+msgid "Daemon running as PID %u"
+msgstr "å¹•å¾Œç¨‹å¼æ­£åœ¨åŸ·è¡Œä¸­ï¼ŒPID 為 %u "
+
+#: ../src/daemon/main.c:634
+#, c-format
+msgid "Failed to kill daemon: %s"
+msgstr "æœªèƒ½çµæŸå¹•後程å¼ï¼š%s"
+
+#: ../src/daemon/main.c:662
+msgid ""
+"This program is not intended to be run as root (unless --system is "
+"specified)."
+msgstr "本程å¼ä¸é æœŸä»¥ root èº«ä»½åŸ·è¡Œï¼ˆé™¤éžæœ‰æŒ‡å®š --system)。"
+
+#: ../src/daemon/main.c:665
+msgid "Root privileges required."
+msgstr "éœ€è¦ root 特權。"
+
+#: ../src/daemon/main.c:671
+msgid "--start not supported for system instances."
+msgstr ""
+
+#: ../src/daemon/main.c:676
+#, c-format
+msgid "User-configured server at %s, not autospawning."
+msgstr ""
+
+#: ../src/daemon/main.c:683
+msgid "Running in system mode, but --disallow-exit not set!"
+msgstr ""
+
+#: ../src/daemon/main.c:686
+msgid "Running in system mode, but --disallow-module-loading not set!"
+msgstr ""
+
+#: ../src/daemon/main.c:689
+msgid "Running in system mode, forcibly disabling SHM mode!"
+msgstr ""
+
+#: ../src/daemon/main.c:694
+msgid "Running in system mode, forcibly disabling exit idle time!"
+msgstr ""
+
+#: ../src/daemon/main.c:720
+msgid "Failed to acquire stdio."
+msgstr "未能ç²å– stdio。"
+
+#: ../src/daemon/main.c:726
+#, fuzzy, c-format
+msgid "pipe() failed: %s"
+msgstr "pipe 失敗: %s"
+
+#: ../src/daemon/main.c:731 ../src/daemon/main.c:790
+#, c-format
+msgid "fork() failed: %s"
+msgstr "fork() 失敗: %s"
+
+#: ../src/daemon/main.c:745 ../src/utils/pacat.c:529
+#, c-format
+msgid "read() failed: %s"
+msgstr "read() 失敗: %s"
+
+#: ../src/daemon/main.c:751
+msgid "Daemon startup failed."
+msgstr "幕後程å¼å•Ÿå‹•失敗。"
+
+#: ../src/daemon/main.c:753
+msgid "Daemon startup successful."
+msgstr "幕後程å¼å•Ÿå‹•æˆåŠŸã€‚"
+
+#: ../src/daemon/main.c:778
+#, fuzzy, c-format
+msgid "setsid() failed: %s"
+msgstr "read() 失敗: %s"
+
+#: ../src/daemon/main.c:830
+#, c-format
+msgid "This is PulseAudio %s"
+msgstr "這是 PulseAudio %s"
+
+#: ../src/daemon/main.c:831
+#, c-format
+msgid "Compilation host: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:832
+#, c-format
+msgid "Compilation CFLAGS: %s"
+msgstr ""
+
+#: ../src/daemon/main.c:835
+#, c-format
+msgid "Running on host: %s"
+msgstr "正在執行於此主機上:%s"
+
+#: ../src/daemon/main.c:838
+#, c-format
+msgid "Found %u CPUs."
+msgstr "找到 %u 個 CPU。"
+
+#: ../src/daemon/main.c:840
+#, c-format
+msgid "Page size is %lu bytes"
+msgstr "分é å¤§å°ç‚º %lu bytes"
+
+#: ../src/daemon/main.c:843
+msgid "Compiled with Valgrind support: yes"
+msgstr "以 Valgrind 支æ´é€²è¡Œç·¨è­¯ï¼šæ˜¯"
+
+#: ../src/daemon/main.c:845
+msgid "Compiled with Valgrind support: no"
+msgstr "以 Valgrind 支æ´é€²è¡Œç·¨è­¯ï¼šå¦"
+
+#: ../src/daemon/main.c:848
+#, c-format
+msgid "Running in valgrind mode: %s"
+msgstr "正在以 valgrind 模å¼åŸ·è¡Œä¸­ï¼š%s"
+
+#: ../src/daemon/main.c:850
+#, fuzzy, c-format
+msgid "Running in VM: %s"
+msgstr "正在執行於此主機上:%s"
+
+#: ../src/daemon/main.c:853
+msgid "Optimized build: yes"
+msgstr "最佳化的建構版本:是"
+
+#: ../src/daemon/main.c:855
+msgid "Optimized build: no"
+msgstr "最佳化的建構版本:å¦"
+
+#: ../src/daemon/main.c:859
+msgid "NDEBUG defined, all asserts disabled."
+msgstr ""
+
+#: ../src/daemon/main.c:861
+msgid "FASTPATH defined, only fast path asserts disabled."
+msgstr ""
+
+#: ../src/daemon/main.c:863
+msgid "All asserts enabled."
+msgstr ""
+
+#: ../src/daemon/main.c:867
+msgid "Failed to get machine ID"
+msgstr "未能å–得機器 ID"
+
+#: ../src/daemon/main.c:870
+#, c-format
+msgid "Machine ID is %s."
+msgstr "機器 ID 為 %s。"
+
+#: ../src/daemon/main.c:874
+#, c-format
+msgid "Session ID is %s."
+msgstr "工作階段 ID 為 %s。"
+
+#: ../src/daemon/main.c:880
+#, c-format
+msgid "Using runtime directory %s."
+msgstr ""
+
+#: ../src/daemon/main.c:885
+#, c-format
+msgid "Using state directory %s."
+msgstr ""
+
+#: ../src/daemon/main.c:888
+#, c-format
+msgid "Using modules directory %s."
+msgstr "使用模組目錄 %s。"
+
+#: ../src/daemon/main.c:890
+#, c-format
+msgid "Running in system mode: %s"
+msgstr "以系統模å¼åŸ·è¡Œä¸­ï¼š%s"
+
+#: ../src/daemon/main.c:893
+msgid ""
+"OK, so you are running PA in system mode. Please note that you most likely "
+"shouldn't be doing that.\n"
+"If you do it nonetheless then it's your own fault if things don't work as "
+"expected.\n"
+"Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an "
+"explanation why system mode is usually a bad idea."
+msgstr ""
+
+#: ../src/daemon/main.c:910
+msgid "pa_pid_file_create() failed."
+msgstr "pa_pid_file_create() 失敗。"
+
+#: ../src/daemon/main.c:920
+msgid "Fresh high-resolution timers available! Bon appetit!"
+msgstr "有新鮮的高解æžåº¦è¨ˆæ™‚器å¯ç”¨ï¼æœŸæœ›æ‚¨æœ‰å€‹å¥½é£Ÿæ…¾ï¼"
+
+#: ../src/daemon/main.c:922
+msgid ""
+"Dude, your kernel stinks! The chef's recommendation today is Linux with high-"
+"resolution timers enabled!"
+msgstr "先生,您的核心糟é€äº†ï¼ä»Šæ—¥ä¸»å»šæŽ¨è–¦æ˜¯å•Ÿç”¨é«˜è§£æžåº¦è¨ˆæ™‚器的 Linuxï¼"
+
+#: ../src/daemon/main.c:945
+msgid "pa_core_new() failed."
+msgstr "pa_core_new() 失敗。"
+
+#: ../src/daemon/main.c:1008
+msgid "Failed to initialize daemon."
+msgstr "未能åˆå§‹åŒ–幕後程å¼ã€‚"
+
+#: ../src/daemon/main.c:1013
+msgid "Daemon startup without any loaded modules, refusing to work."
+msgstr "幕後程å¼å•Ÿå‹•而沒有任何載入的模組,拒絕é‹ä½œã€‚"
+
+#: ../src/daemon/main.c:1051
+msgid "Daemon startup complete."
+msgstr "幕後程å¼å•Ÿå‹•完æˆã€‚"
+
+#: ../src/daemon/main.c:1057
+msgid "Daemon shutdown initiated."
+msgstr "幕後程å¼å·²é–‹å§‹é—œé–‰ã€‚"
+
+#: ../src/daemon/main.c:1083
+msgid "Daemon terminated."
+msgstr "幕後程å¼å·²çµ‚止。"
+
+#: ../src/daemon/cmdline.c:115
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+"COMMANDS:\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" --dump-conf Dump default configuration\n"
+" --dump-modules Dump list of available modules\n"
+" --dump-resample-methods Dump available resample methods\n"
+" --cleanup-shm Cleanup stale shared memory "
+"segments\n"
+" --start Start the daemon if it is not "
+"running\n"
+" -k --kill Kill a running daemon\n"
+" --check Check for a running daemon (only "
+"returns exit code)\n"
+"\n"
+"OPTIONS:\n"
+" --system[=BOOL] Run as system-wide instance\n"
+" -D, --daemonize[=BOOL] Daemonize after startup\n"
+" --fail[=BOOL] Quit when startup fails\n"
+" --high-priority[=BOOL] Try to set high nice level\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_NICE)\n"
+" --realtime[=BOOL] Try to enable realtime scheduling\n"
+" (only available as root, when SUID "
+"or\n"
+" with elevated RLIMIT_RTPRIO)\n"
+" --disallow-module-loading[=BOOL] Disallow module user requested "
+"module\n"
+" loading/unloading after startup\n"
+" --disallow-exit[=BOOL] Disallow user requested exit\n"
+" --exit-idle-time=SECS Terminate the daemon when idle and "
+"this\n"
+" time passed\n"
+" --module-idle-time=SECS Unload autoloaded modules when idle "
+"and\n"
+" this time passed\n"
+" --scache-idle-time=SECS Unload autoloaded samples when idle "
+"and\n"
+" this time passed\n"
+" --log-level[=LEVEL] Increase or set verbosity level\n"
+" -v Increase the verbosity level\n"
+" --log-target={auto,syslog,stderr} Specify the log target\n"
+" --log-meta[=BOOL] Include code location in log "
+"messages\n"
+" --log-time[=BOOL] Include timestamps in log messages\n"
+" --log-backtrace=FRAMES Include a backtrace in log messages\n"
+" -p, --dl-search-path=PATH Set the search path for dynamic "
+"shared\n"
+" objects (plugins)\n"
+" --resample-method=METHOD Use the specified resampling method\n"
+" (See --dump-resample-methods for\n"
+" possible values)\n"
+" --use-pid-file[=BOOL] Create a PID file\n"
+" --no-cpu-limit[=BOOL] Do not install CPU load limiter on\n"
+" platforms that support it.\n"
+" --disable-shm[=BOOL] Disable shared memory support.\n"
+"\n"
+"STARTUP SCRIPT:\n"
+" -L, --load=\"MODULE ARGUMENTS\" Load the specified plugin module "
+"with\n"
+" the specified argument\n"
+" -F, --file=FILENAME Run the specified script\n"
+" -C Open a command line on the running "
+"TTY\n"
+" after startup\n"
+"\n"
+" -n Don't load default script file\n"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:247
+msgid "--daemonize expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:254
+msgid "--fail expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:264
+msgid ""
+"--log-level expects log level argument (either numeric in range 0..4 or one "
+"of debug, info, notice, warn, error)."
+msgstr ""
+
+#: ../src/daemon/cmdline.c:276
+msgid "--high-priority expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:283
+msgid "--realtime expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:290
+msgid "--disallow-module-loading expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:297
+msgid "--disallow-exit expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:304
+msgid "--use-pid-file expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:321
+msgid "Invalid log target: use either 'syslog', 'stderr' or 'auto'."
+msgstr ""
+
+#: ../src/daemon/cmdline.c:328
+msgid "--log-time expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:335
+msgid "--log-meta expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:354
+#, c-format
+msgid "Invalid resample method '%s'."
+msgstr "ç„¡æ•ˆçš„é‡æ–°å–樣方法「%sã€"
+
+#: ../src/daemon/cmdline.c:361
+msgid "--system expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:368
+msgid "--no-cpu-limit expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/cmdline.c:375
+msgid "--disable-shm expects boolean argument"
+msgstr ""
+
+#: ../src/daemon/dumpmodules.c:60
+#, c-format
+msgid "Name: %s\n"
+msgstr "å稱:%s\n"
+
+#: ../src/daemon/dumpmodules.c:63
+#, c-format
+msgid "No module information available\n"
+msgstr "沒有å¯ç”¨çš„æ¨¡çµ„資訊\n"
+
+#: ../src/daemon/dumpmodules.c:66
+#, c-format
+msgid "Version: %s\n"
+msgstr "版本:%s\n"
+
+#: ../src/daemon/dumpmodules.c:68
+#, c-format
+msgid "Description: %s\n"
+msgstr "æè¿°ï¼š%s\n"
+
+#: ../src/daemon/dumpmodules.c:70
+#, c-format
+msgid "Author: %s\n"
+msgstr "作者:%s\n"
+
+#: ../src/daemon/dumpmodules.c:72
+#, c-format
+msgid "Usage: %s\n"
+msgstr "用法:%s\n"
+
+#: ../src/daemon/dumpmodules.c:73
+#, c-format
+msgid "Load Once: %s\n"
+msgstr "載入一次:%s\n"
+
+#: ../src/daemon/dumpmodules.c:75
+#, c-format
+msgid "DEPRECATION WARNING: %s\n"
+msgstr "åå°è­¦å‘Šï¼š%s\n"
+
+#: ../src/daemon/dumpmodules.c:79
+#, c-format
+msgid "Path: %s\n"
+msgstr "路徑:%s\n"
+
+#: ../src/daemon/daemon-conf.c:251
+#, c-format
+msgid "[%s:%u] Invalid log target '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:267
+#, c-format
+msgid "[%s:%u] Invalid log level '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:283
+#, c-format
+msgid "[%s:%u] Invalid resample method '%s'."
+msgstr "[%s:%u] ç„¡æ•ˆçš„é‡æ–°å–樣方法「%sã€ã€‚"
+
+#: ../src/daemon/daemon-conf.c:306
+#, c-format
+msgid "[%s:%u] Invalid rlimit '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:313
+#, c-format
+msgid "[%s:%u] rlimit not supported on this platform."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:329
+#, c-format
+msgid "[%s:%u] Invalid sample format '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:347
+#, c-format
+msgid "[%s:%u] Invalid sample rate '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:371
+#, c-format
+msgid "[%s:%u] Invalid sample channels '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:389
+#, c-format
+msgid "[%s:%u] Invalid channel map '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:407
+#, c-format
+msgid "[%s:%u] Invalid number of fragments '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:425
+#, c-format
+msgid "[%s:%u] Invalid fragment size '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:443
+#, c-format
+msgid "[%s:%u] Invalid nice level '%s'."
+msgstr ""
+
+#: ../src/daemon/daemon-conf.c:479
+#, fuzzy, c-format
+msgid "[%s:%u] Invalid server type '%s'."
+msgstr "[%s:%u] ç„¡æ•ˆçš„é‡æ–°å–樣方法「%sã€ã€‚"
+
+#: ../src/daemon/daemon-conf.c:586
+#, c-format
+msgid "Failed to open configuration file: %s"
+msgstr "未能開啟é…置檔:%s"
+
+#: ../src/daemon/daemon-conf.c:602
+msgid ""
+"The specified default channel map has a different number of channels than "
+"the specified default number of channels."
+msgstr "指定的é è¨­è²é“å°æ‡‰è¡¨çš„è²é“數與指定的é è¨­è²é“數ä¸åŒã€‚"
+
+#: ../src/daemon/daemon-conf.c:688
+#, c-format
+msgid "### Read from configuration file: %s ###\n"
+msgstr "### 從此é…置檔讀å–:%s ###\n"
+
+#: ../src/daemon/caps.c:62
+msgid "Cleaning up privileges."
+msgstr "正在清除特權。"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:1
+msgid "PulseAudio Sound System"
+msgstr "PulseAudio 音效系統"
+
+#: ../src/daemon/pulseaudio.desktop.in.h:2
+msgid "Start the PulseAudio Sound System"
+msgstr "啟動 PulseAudio 音效系統"
+
+#: ../src/pulse/channelmap.c:105 ../src/pulse/channelmap.c:757
+msgid "Mono"
+msgstr "å–®è²é“"
+
+#: ../src/pulse/channelmap.c:107
+msgid "Front Center"
+msgstr "æ­£å‰æ–¹"
+
+#: ../src/pulse/channelmap.c:108
+msgid "Front Left"
+msgstr "左剿–¹"
+
+#: ../src/pulse/channelmap.c:109
+msgid "Front Right"
+msgstr "å³å‰æ–¹"
+
+#: ../src/pulse/channelmap.c:111
+msgid "Rear Center"
+msgstr "正後方"
+
+#: ../src/pulse/channelmap.c:112
+msgid "Rear Left"
+msgstr "左後方"
+
+#: ../src/pulse/channelmap.c:113
+msgid "Rear Right"
+msgstr "å³å¾Œæ–¹"
+
+#: ../src/pulse/channelmap.c:115
+msgid "Subwoofer"
+msgstr ""
+
+#: ../src/pulse/channelmap.c:117
+msgid "Front Left-of-center"
+msgstr "剿–¹ä¸­å¤®åå·¦"
+
+#: ../src/pulse/channelmap.c:118
+msgid "Front Right-of-center"
+msgstr "剿–¹ä¸­å¤®åå³"
+
+#: ../src/pulse/channelmap.c:120
+msgid "Side Left"
+msgstr "å·¦å´"
+
+#: ../src/pulse/channelmap.c:121
+msgid "Side Right"
+msgstr "å³å´"
+
+#: ../src/pulse/channelmap.c:123
+msgid "Auxiliary 0"
+msgstr "輔助 0"
+
+#: ../src/pulse/channelmap.c:124
+msgid "Auxiliary 1"
+msgstr "輔助 1"
+
+#: ../src/pulse/channelmap.c:125
+msgid "Auxiliary 2"
+msgstr "輔助 2"
+
+#: ../src/pulse/channelmap.c:126
+msgid "Auxiliary 3"
+msgstr "輔助 3"
+
+#: ../src/pulse/channelmap.c:127
+msgid "Auxiliary 4"
+msgstr "輔助 4"
+
+#: ../src/pulse/channelmap.c:128
+msgid "Auxiliary 5"
+msgstr "輔助 5"
+
+#: ../src/pulse/channelmap.c:129
+msgid "Auxiliary 6"
+msgstr "輔助 6"
+
+#: ../src/pulse/channelmap.c:130
+msgid "Auxiliary 7"
+msgstr "輔助 7"
+
+#: ../src/pulse/channelmap.c:131
+msgid "Auxiliary 8"
+msgstr "輔助 8"
+
+#: ../src/pulse/channelmap.c:132
+msgid "Auxiliary 9"
+msgstr "輔助 9"
+
+#: ../src/pulse/channelmap.c:133
+msgid "Auxiliary 10"
+msgstr "輔助 10"
+
+#: ../src/pulse/channelmap.c:134
+msgid "Auxiliary 11"
+msgstr "輔助 11"
+
+#: ../src/pulse/channelmap.c:135
+msgid "Auxiliary 12"
+msgstr "輔助 12"
+
+#: ../src/pulse/channelmap.c:136
+msgid "Auxiliary 13"
+msgstr "輔助 13"
+
+#: ../src/pulse/channelmap.c:137
+msgid "Auxiliary 14"
+msgstr "輔助 14"
+
+#: ../src/pulse/channelmap.c:138
+msgid "Auxiliary 15"
+msgstr "輔助 15"
+
+#: ../src/pulse/channelmap.c:139
+msgid "Auxiliary 16"
+msgstr "輔助 16"
+
+#: ../src/pulse/channelmap.c:140
+msgid "Auxiliary 17"
+msgstr "輔助 17"
+
+#: ../src/pulse/channelmap.c:141
+msgid "Auxiliary 18"
+msgstr "輔助 18"
+
+#: ../src/pulse/channelmap.c:142
+msgid "Auxiliary 19"
+msgstr "輔助 19"
+
+#: ../src/pulse/channelmap.c:143
+msgid "Auxiliary 20"
+msgstr "輔助 20"
+
+#: ../src/pulse/channelmap.c:144
+msgid "Auxiliary 21"
+msgstr "輔助 21"
+
+#: ../src/pulse/channelmap.c:145
+msgid "Auxiliary 22"
+msgstr "輔助 22"
+
+#: ../src/pulse/channelmap.c:146
+msgid "Auxiliary 23"
+msgstr "輔助 23"
+
+#: ../src/pulse/channelmap.c:147
+msgid "Auxiliary 24"
+msgstr "輔助 24"
+
+#: ../src/pulse/channelmap.c:148
+msgid "Auxiliary 25"
+msgstr "輔助 25"
+
+#: ../src/pulse/channelmap.c:149
+msgid "Auxiliary 26"
+msgstr "輔助 26"
+
+#: ../src/pulse/channelmap.c:150
+msgid "Auxiliary 27"
+msgstr "輔助 27"
+
+#: ../src/pulse/channelmap.c:151
+msgid "Auxiliary 28"
+msgstr "輔助 28"
+
+#: ../src/pulse/channelmap.c:152
+msgid "Auxiliary 29"
+msgstr "輔助 29"
+
+#: ../src/pulse/channelmap.c:153
+msgid "Auxiliary 30"
+msgstr "輔助 30"
+
+#: ../src/pulse/channelmap.c:154
+msgid "Auxiliary 31"
+msgstr "輔助 31"
+
+#: ../src/pulse/channelmap.c:156
+msgid "Top Center"
+msgstr "正上方"
+
+#: ../src/pulse/channelmap.c:158
+msgid "Top Front Center"
+msgstr "頂端正上方"
+
+#: ../src/pulse/channelmap.c:159
+msgid "Top Front Left"
+msgstr "é ‚ç«¯å·¦å‰æ–¹"
+
+#: ../src/pulse/channelmap.c:160
+msgid "Top Front Right"
+msgstr "頂端å³å‰æ–¹"
+
+#: ../src/pulse/channelmap.c:162
+msgid "Top Rear Center"
+msgstr "頂端正後方"
+
+#: ../src/pulse/channelmap.c:163
+msgid "Top Rear Left"
+msgstr "頂端左後方"
+
+#: ../src/pulse/channelmap.c:164
+msgid "Top Rear Right"
+msgstr "頂端å³å¾Œæ–¹"
+
+#: ../src/pulse/channelmap.c:484 ../src/pulse/sample.c:170
+#: ../src/pulse/volume.c:295 ../src/pulse/volume.c:321
+#: ../src/pulse/volume.c:341 ../src/pulse/volume.c:371
+msgid "(invalid)"
+msgstr "(無效)"
+
+#: ../src/pulse/channelmap.c:761
+msgid "Stereo"
+msgstr "ç«‹é«”è²"
+
+#: ../src/pulse/channelmap.c:766
+msgid "Surround 4.0"
+msgstr "ç’°ç¹žè² 4.0"
+
+#: ../src/pulse/channelmap.c:772
+msgid "Surround 4.1"
+msgstr "ç’°ç¹žè² 4.1"
+
+#: ../src/pulse/channelmap.c:778
+msgid "Surround 5.0"
+msgstr "ç’°ç¹žè² 5.0"
+
+#: ../src/pulse/channelmap.c:784
+msgid "Surround 5.1"
+msgstr "ç’°ç¹žè² 5.1"
+
+#: ../src/pulse/channelmap.c:791
+msgid "Surround 7.1"
+msgstr "ç’°ç¹žè² 7.1"
+
+#: ../src/pulse/error.c:43
+msgid "OK"
+msgstr "確定"
+
+#: ../src/pulse/error.c:44
+msgid "Access denied"
+msgstr "拒絕存å–"
+
+#: ../src/pulse/error.c:45
+msgid "Unknown command"
+msgstr "未知指令"
+
+#: ../src/pulse/error.c:46
+msgid "Invalid argument"
+msgstr "ç„¡æ•ˆçš„åƒæ•¸"
+
+#: ../src/pulse/error.c:47
+msgid "Entity exists"
+msgstr "實體存在"
+
+#: ../src/pulse/error.c:48
+msgid "No such entity"
+msgstr "無此實體"
+
+#: ../src/pulse/error.c:49
+msgid "Connection refused"
+msgstr "拒絕連線"
+
+#: ../src/pulse/error.c:50
+msgid "Protocol error"
+msgstr "å”定錯誤"
+
+#: ../src/pulse/error.c:51
+msgid "Timeout"
+msgstr "逾時"
+
+#: ../src/pulse/error.c:52
+msgid "No authorization key"
+msgstr "沒有èªè­‰é‡‘é‘°"
+
+#: ../src/pulse/error.c:53
+msgid "Internal error"
+msgstr "內部錯誤"
+
+#: ../src/pulse/error.c:54
+msgid "Connection terminated"
+msgstr "連線已終止"
+
+#: ../src/pulse/error.c:55
+msgid "Entity killed"
+msgstr "å¯¦é«”å·²çµæŸ"
+
+#: ../src/pulse/error.c:56
+msgid "Invalid server"
+msgstr "無效的伺æœå™¨"
+
+#: ../src/pulse/error.c:57
+msgid "Module initalization failed"
+msgstr "模組åˆå§‹åŒ–失敗"
+
+#: ../src/pulse/error.c:58
+msgid "Bad state"
+msgstr "ä¸è‰¯ç‹€æ…‹"
+
+#: ../src/pulse/error.c:59
+msgid "No data"
+msgstr "無資料"
+
+#: ../src/pulse/error.c:60
+msgid "Incompatible protocol version"
+msgstr "ä¸ç›¸å®¹çš„å”定版本"
+
+#: ../src/pulse/error.c:61
+msgid "Too large"
+msgstr "éŽå¤§"
+
+#: ../src/pulse/error.c:62
+msgid "Not supported"
+msgstr "䏿”¯æ´"
+
+#: ../src/pulse/error.c:63
+msgid "Unknown error code"
+msgstr "未知的錯誤碼"
+
+#: ../src/pulse/error.c:64
+msgid "No such extension"
+msgstr "無此擴展功能"
+
+#: ../src/pulse/error.c:65
+msgid "Obsolete functionality"
+msgstr "淘汰的功能"
+
+#: ../src/pulse/error.c:66
+msgid "Missing implementation"
+msgstr "éºå¤±çš„實作"
+
+#: ../src/pulse/error.c:67
+msgid "Client forked"
+msgstr "客戶端已分支"
+
+#: ../src/pulse/error.c:68
+msgid "Input/Output error"
+msgstr "輸入/輸出 錯誤"
+
+#: ../src/pulse/error.c:69
+msgid "Device or resource busy"
+msgstr "è£ç½®æˆ–資æºå¿™ç¢Œ"
+
+#: ../src/pulse/sample.c:172
+#, c-format
+msgid "%s %uch %uHz"
+msgstr "%s %uch %uHz"
+
+#: ../src/pulse/sample.c:184
+#, c-format
+msgid "%0.1f GiB"
+msgstr "%0.1f GiB"
+
+#: ../src/pulse/sample.c:186
+#, c-format
+msgid "%0.1f MiB"
+msgstr "%0.1f MiB"
+
+#: ../src/pulse/sample.c:188
+#, c-format
+msgid "%0.1f KiB"
+msgstr "%0.1f KiB"
+
+#: ../src/pulse/sample.c:190
+#, c-format
+msgid "%u B"
+msgstr "%u B"
+
+#: ../src/pulse/client-conf-x11.c:55 ../src/utils/pax11publish.c:100
+msgid "XOpenDisplay() failed"
+msgstr "XOpenDisplay() 失敗"
+
+#: ../src/pulse/client-conf-x11.c:93
+msgid "Failed to parse cookie data"
+msgstr "æœªèƒ½è§£æž cookie 資料"
+
+#: ../src/pulse/client-conf.c:118
+#, c-format
+msgid "Failed to open configuration file '%s': %s"
+msgstr "未能開啟é…置檔「%sã€ï¼š%s"
+
+#: ../src/pulse/context.c:539
+msgid "No cookie loaded. Attempting to connect without."
+msgstr "沒有載入 cookie。試圖連接而ä¸ç”¨ cookie。"
+
+#: ../src/pulse/context.c:682
+#, c-format
+msgid "fork(): %s"
+msgstr "fork(): %s"
+
+#: ../src/pulse/context.c:737
+#, c-format
+msgid "waitpid(): %s"
+msgstr "waitpid(): %s"
+
+#: ../src/pulse/context.c:1434
+#, c-format
+msgid "Received message for unknown extension '%s'"
+msgstr "已接收到未知擴展功能的訊æ¯ã€Œ%sã€"
+
+#: ../src/utils/pacat.c:110
+#, c-format
+msgid "Failed to drain stream: %s"
+msgstr "未能排出串æµï¼š%s"
+
+#: ../src/utils/pacat.c:115
+msgid "Playback stream drained."
+msgstr "播放控制串æµå·²æŽ’出。"
+
+#: ../src/utils/pacat.c:125
+msgid "Draining connection to server."
+msgstr "正在排出連線到伺æœå™¨ã€‚"
+
+#: ../src/utils/pacat.c:138
+#, c-format
+msgid "pa_stream_drain(): %s"
+msgstr "pa_stream_drain(): %s"
+
+#: ../src/utils/pacat.c:161
+#, c-format
+msgid "pa_stream_write() failed: %s"
+msgstr "pa_stream_write() failed: %s"
+
+#: ../src/utils/pacat.c:202
+#, c-format
+msgid "pa_stream_begin_write() failed: %s"
+msgstr "pa_stream_begin_write() 失敗: %s"
+
+#: ../src/utils/pacat.c:252 ../src/utils/pacat.c:282
+#, c-format
+msgid "pa_stream_peek() failed: %s"
+msgstr "pa_stream_peek() 失敗: %s"
+
+#: ../src/utils/pacat.c:322
+msgid "Stream successfully created."
+msgstr "å·²æˆåŠŸå»ºç«‹ä¸²æµã€‚"
+
+#: ../src/utils/pacat.c:325
+#, c-format
+msgid "pa_stream_get_buffer_attr() failed: %s"
+msgstr "pa_stream_get_buffer_attr() 失敗: %s"
+
+#: ../src/utils/pacat.c:329
+#, c-format
+msgid "Buffer metrics: maxlength=%u, tlength=%u, prebuf=%u, minreq=%u"
+msgstr ""
+
+#: ../src/utils/pacat.c:332
+#, c-format
+msgid "Buffer metrics: maxlength=%u, fragsize=%u"
+msgstr ""
+
+#: ../src/utils/pacat.c:336
+#, c-format
+msgid "Using sample spec '%s', channel map '%s'."
+msgstr "ä½¿ç”¨å–æ¨£è¦æ ¼ã€Œ%sã€ï¼Œè²é“å°æ‡‰è¡¨ã€Œ%sã€"
+
+#: ../src/utils/pacat.c:340
+#, c-format
+msgid "Connected to device %s (%u, %ssuspended)."
+msgstr "正在連接到è£ç½® %s (%u, %ssuspended)。"
+
+#: ../src/utils/pacat.c:350
+#, c-format
+msgid "Stream error: %s"
+msgstr "串æµéŒ¯èª¤ï¼š%s"
+
+#: ../src/utils/pacat.c:360
+#, c-format
+msgid "Stream device suspended.%s"
+msgstr "串æµè£ç½®å·²æš«åœã€‚%s"
+
+#: ../src/utils/pacat.c:362
+#, c-format
+msgid "Stream device resumed.%s"
+msgstr "串æµè£ç½®å·²æ¢å¾©ï¼š%s"
+
+#: ../src/utils/pacat.c:370
+#, c-format
+msgid "Stream underrun.%s"
+msgstr "ä¸²æµæ¬ è¼‰é‹è¡Œã€‚%s"
+
+#: ../src/utils/pacat.c:377
+#, c-format
+msgid "Stream overrun.%s"
+msgstr "串æµè¶…載é‹è¡Œã€‚%s"
+
+#: ../src/utils/pacat.c:384
+#, c-format
+msgid "Stream started.%s"
+msgstr "串æµå·²é–‹å§‹ã€‚%s"
+
+#: ../src/utils/pacat.c:391
+#, c-format
+msgid "Stream moved to device %s (%u, %ssuspended).%s"
+msgstr "串æµç§»è‡³è£ç½® %s (%u, %ssuspended)。%s"
+
+#: ../src/utils/pacat.c:391
+msgid "not "
+msgstr "䏿˜¯"
+
+#: ../src/utils/pacat.c:398
+#, c-format
+msgid "Stream buffer attributes changed.%s"
+msgstr "串æµç·©è¡ç‰¹å¾µå·²è®Šæ›´ã€‚%s"
+
+#: ../src/utils/pacat.c:430
+#, c-format
+msgid "Connection established.%s"
+msgstr "連線已建立。%s"
+
+#: ../src/utils/pacat.c:433
+#, c-format
+msgid "pa_stream_new() failed: %s"
+msgstr "pa_stream_new() 失敗:%s"
+
+#: ../src/utils/pacat.c:471
+#, c-format
+msgid "pa_stream_connect_playback() failed: %s"
+msgstr "pa_stream_connect_playback() 失敗:%s"
+
+#: ../src/utils/pacat.c:477
+#, c-format
+msgid "pa_stream_connect_record() failed: %s"
+msgstr "pa_stream_connect_record() 失敗:%s"
+
+#: ../src/utils/pacat.c:491 ../src/utils/pactl.c:949
+#, c-format
+msgid "Connection failure: %s"
+msgstr "連線失敗:%s"
+
+#: ../src/utils/pacat.c:524
+msgid "Got EOF."
+msgstr "å–得檔案çµå°¾ (EOF)。"
+
+#: ../src/utils/pacat.c:561
+#, c-format
+msgid "write() failed: %s"
+msgstr "write() 失敗:%s"
+
+#: ../src/utils/pacat.c:582
+msgid "Got signal, exiting."
+msgstr "å–得訊號,正在退出。"
+
+#: ../src/utils/pacat.c:596
+#, c-format
+msgid "Failed to get latency: %s"
+msgstr "未能å–得傳輸延é²ï¼š%s"
+
+#: ../src/utils/pacat.c:601
+#, c-format
+msgid "Time: %0.3f sec; Latency: %0.0f usec."
+msgstr "時間:%0.3f 秒;延é²ï¼š%0.0f 微秒。"
+
+#: ../src/utils/pacat.c:620
+#, c-format
+msgid "pa_stream_update_timing_info() failed: %s"
+msgstr "pa_stream_update_timing_info() 失敗:%s"
+
+#: ../src/utils/pacat.c:630
+#, c-format
+msgid ""
+"%s [options]\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -r, --record Create a connection for recording\n"
+" -p, --playback Create a connection for playback\n"
+"\n"
+" -v, --verbose Enable verbose operations\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -d, --device=DEVICE The name of the sink/source to "
+"connect to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+" --stream-name=NAME How to call this stream on the "
+"server\n"
+" --volume=VOLUME Specify the initial (linear) volume "
+"in range 0...65536\n"
+" --rate=SAMPLERATE The sample rate in Hz (defaults to "
+"44100)\n"
+" --format=SAMPLEFORMAT The sample type, one of s16le, "
+"s16be, u8, float32le,\n"
+" float32be, ulaw, alaw, s32le, s32be, "
+"s24le, s24be,\n"
+" s24-32le, s24-32be (defaults to "
+"s16ne)\n"
+" --channels=CHANNELS The number of channels, 1 for mono, "
+"2 for stereo\n"
+" (defaults to 2)\n"
+" --channel-map=CHANNELMAP Channel map to use instead of the "
+"default\n"
+" --fix-format Take the sample format from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-rate Take the sampling rate from the sink "
+"the stream is\n"
+" being connected to.\n"
+" --fix-channels Take the number of channels and the "
+"channel map\n"
+" from the sink the stream is being "
+"connected to.\n"
+" --no-remix Don't upmix or downmix channels.\n"
+" --no-remap Map channels by index instead of "
+"name.\n"
+" --latency=BYTES Request the specified latency in "
+"bytes.\n"
+" --process-time=BYTES Request the specified process time "
+"per request in bytes.\n"
+" --latency-msec=MSEC Request the specified latency in "
+"msec.\n"
+" --process-time-msec=MSEC Request the specified process time "
+"per request in msec.\n"
+" --property=PROPERTY=VALUE Set the specified property to the "
+"specified value.\n"
+" --raw Record/play raw PCM data.\n"
+" --file-format[=FFORMAT] Record/play formatted PCM data.\n"
+" --list-file-formats List available file formats.\n"
+msgstr ""
+
+#: ../src/utils/pacat.c:758
+#, c-format
+msgid ""
+"pacat %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+
+#: ../src/utils/pacat.c:791 ../src/utils/pactl.c:1046
+#, c-format
+msgid "Invalid client name '%s'"
+msgstr "無效的客戶端å稱「%sã€"
+
+#: ../src/utils/pacat.c:806
+#, c-format
+msgid "Invalid stream name '%s'"
+msgstr "無效的串æµå稱「%sã€"
+
+#: ../src/utils/pacat.c:843
+#, c-format
+msgid "Invalid channel map '%s'"
+msgstr "無效的è²é“å°æ‡‰è¡¨ã€Œ%sã€"
+
+#: ../src/utils/pacat.c:872 ../src/utils/pacat.c:886
+#, c-format
+msgid "Invalid latency specification '%s'"
+msgstr "無效的延é²è¦æ ¼ã€Œ%sã€"
+
+#: ../src/utils/pacat.c:879 ../src/utils/pacat.c:893
+#, c-format
+msgid "Invalid process time specification '%s'"
+msgstr "ç„¡æ•ˆçš„ç¨‹åºæ™‚é–“è¦æ ¼ã€Œ%sã€"
+
+#: ../src/utils/pacat.c:905
+#, c-format
+msgid "Invalid property '%s'"
+msgstr "無效的屬性「%sã€"
+
+#: ../src/utils/pacat.c:922
+#, c-format
+msgid "Unknown file format %s."
+msgstr "æœªçŸ¥æª”æ¡ˆæ ¼å¼ %s。"
+
+#: ../src/utils/pacat.c:941
+msgid "Invalid sample specification"
+msgstr "ç„¡æ•ˆçš„å–æ¨£è¦æ ¼"
+
+#: ../src/utils/pacat.c:951
+#, c-format
+msgid "open(): %s"
+msgstr "open(): %s"
+
+#: ../src/utils/pacat.c:956
+#, c-format
+msgid "dup2(): %s"
+msgstr "dup2(): %s"
+
+#: ../src/utils/pacat.c:963
+msgid "Too many arguments."
+msgstr "å¤ªå¤šåƒæ•¸ã€‚"
+
+#: ../src/utils/pacat.c:974
+msgid "Failed to generate sample specification for file."
+msgstr "æœªèƒ½æ›¿æª”æ¡ˆç”¢ç”Ÿå–æ¨£è¦æ ¼ã€‚"
+
+#: ../src/utils/pacat.c:994
+msgid "Failed to open audio file."
+msgstr "未能開啟音效檔。"
+
+#: ../src/utils/pacat.c:1000
+msgid ""
+"Warning: specified sample specification will be overwritten with "
+"specification from file."
+msgstr "è­¦å‘Šï¼šæŒ‡å®šçš„å–æ¨£è¦æ ¼å°‡æœƒè¦†å¯«å¾žæª”æ¡ˆå¾—åˆ°çš„è¦æ ¼ã€‚"
+
+#: ../src/utils/pacat.c:1003 ../src/utils/pactl.c:1090
+msgid "Failed to determine sample specification from file."
+msgstr "æœªèƒ½å¾žæª”æ¡ˆå¾—çŸ¥å–æ¨£è¦æ ¼ã€‚"
+
+#: ../src/utils/pacat.c:1012
+msgid "Warning: Failed to determine channel map from file."
+msgstr "警告:未能從檔案å–å¾—è²é“å°æ‡‰è¡¨ã€‚"
+
+#: ../src/utils/pacat.c:1023
+msgid "Channel map doesn't match sample specification"
+msgstr "è²é“å°æ‡‰è¡¨èˆ‡å–æ¨£è¦æ ¼ä¸ç¬¦"
+
+#: ../src/utils/pacat.c:1034
+msgid "Warning: failed to write channel map to file."
+msgstr "警告:未能將è²é“å°æ‡‰è¡¨å¯«å…¥æª”案。"
+
+#: ../src/utils/pacat.c:1049
+#, c-format
+msgid ""
+"Opening a %s stream with sample specification '%s' and channel map '%s'."
+msgstr "æ­£åœ¨é–‹å•Ÿä¸€é“ %s 串æµï¼Œå–æ¨£è¦æ ¼ç‚ºã€Œ%sã€ï¼Œè²é“å°æ‡‰è¡¨ç‚ºã€Œ%sã€ã€‚"
+
+#: ../src/utils/pacat.c:1050
+msgid "recording"
+msgstr "錄製"
+
+#: ../src/utils/pacat.c:1050
+msgid "playback"
+msgstr "播放控制"
+
+#: ../src/utils/pacat.c:1076 ../src/utils/pactl.c:1364
+msgid "pa_mainloop_new() failed."
+msgstr "pa_mainloop_new() 失敗。"
+
+#: ../src/utils/pacat.c:1095
+msgid "io_new() failed."
+msgstr "io_new() 失敗。"
+
+#: ../src/utils/pacat.c:1102 ../src/utils/pactl.c:1376
+msgid "pa_context_new() failed."
+msgstr "pa_context_new() 失敗。"
+
+#: ../src/utils/pacat.c:1110 ../src/utils/pactl.c:1382
+#, c-format
+msgid "pa_context_connect() failed: %s"
+msgstr "pa_context_connect() 失敗:%s"
+
+#: ../src/utils/pacat.c:1116
+msgid "pa_context_rttime_new() failed."
+msgstr "pa_context_rttime_new() 失敗。"
+
+#: ../src/utils/pacat.c:1123 ../src/utils/pactl.c:1387
+msgid "pa_mainloop_run() failed."
+msgstr "pa_mainloop_run() 失敗。"
+
+#: ../src/utils/pasuspender.c:79
+#, c-format
+msgid "fork(): %s\n"
+msgstr "fork(): %s\n"
+
+#: ../src/utils/pasuspender.c:90
+#, c-format
+msgid "execvp(): %s\n"
+msgstr "execvp(): %s\n"
+
+#: ../src/utils/pasuspender.c:107
+#, c-format
+msgid "Failure to suspend: %s\n"
+msgstr "未能暫åœï¼š%s\n"
+
+#: ../src/utils/pasuspender.c:122
+#, c-format
+msgid "Failure to resume: %s\n"
+msgstr "未能æ¢å¾©ï¼š%s\n"
+
+#: ../src/utils/pasuspender.c:145
+#, c-format
+msgid "WARNING: Sound server is not local, not suspending.\n"
+msgstr "警告:音效伺æœå™¨ä¸¦éžæœ¬æ©Ÿï¼Œä¸æœƒæš«åœã€‚\n"
+
+#: ../src/utils/pasuspender.c:157
+#, c-format
+msgid "Connection failure: %s\n"
+msgstr "連線失敗:%s\n"
+
+#: ../src/utils/pasuspender.c:174
+#, c-format
+msgid "Got SIGINT, exiting.\n"
+msgstr "å–å¾— SIGINT,正在退出。\n"
+
+#: ../src/utils/pasuspender.c:192
+#, c-format
+msgid "WARNING: Child process terminated by signal %u\n"
+msgstr "警告:å­ç¨‹åºå·²è¢«è¨Šè™Ÿ %u 所終止\n"
+
+#: ../src/utils/pasuspender.c:210
+#, c-format
+msgid ""
+"%s [options] ... \n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+"\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:246
+#, c-format
+msgid ""
+"pasuspender %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+
+#: ../src/utils/pasuspender.c:275
+#, c-format
+msgid "pa_mainloop_new() failed.\n"
+msgstr "pa_mainloop_new() 失敗。\n"
+
+#: ../src/utils/pasuspender.c:288
+#, c-format
+msgid "pa_context_new() failed.\n"
+msgstr "pa_context_new() 失敗。\n"
+
+#: ../src/utils/pasuspender.c:296
+#, c-format
+msgid "pa_mainloop_run() failed.\n"
+msgstr "pa_mainloop_run() 失敗。\n"
+
+#: ../src/utils/pactl.c:134
+#, c-format
+msgid "Failed to get statistics: %s"
+msgstr "未能å–得統計:%s"
+
+#: ../src/utils/pactl.c:140
+#, c-format
+msgid "Currently in use: %u blocks containing %s bytes total.\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:143
+#, c-format
+msgid "Allocated during whole lifetime: %u blocks containing %s bytes total.\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:146
+#, c-format
+msgid "Sample cache size: %s\n"
+msgstr "å–æ¨£å¿«å–大å°ï¼š%s\n"
+
+#: ../src/utils/pactl.c:155
+#, c-format
+msgid "Failed to get server information: %s"
+msgstr "未能å–得伺æœå™¨è³‡è¨Šï¼š%s"
+
+#: ../src/utils/pactl.c:160
+#, c-format
+msgid ""
+"Server String: %s\n"
+"Library Protocol Version: %u\n"
+"Server Protocol Version: %u\n"
+"Is Local: %s\n"
+"Client Index: %u\n"
+"Tile Size: %zu\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:176
+#, c-format
+msgid ""
+"User Name: %s\n"
+"Host Name: %s\n"
+"Server Name: %s\n"
+"Server Version: %s\n"
+"Default Sample Specification: %s\n"
+"Default Channel Map: %s\n"
+"Default Sink: %s\n"
+"Default Source: %s\n"
+"Cookie: %04x:%04x\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:218
+#, c-format
+msgid "Failed to get sink information: %s"
+msgstr "未能å–å¾— sink 資訊:%s"
+
+#: ../src/utils/pactl.c:234
+#, c-format
+msgid ""
+"Sink #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor Source: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:281 ../src/utils/pactl.c:373
+#, c-format
+msgid "\tPorts:\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:287 ../src/utils/pactl.c:379
+#, c-format
+msgid "\tActive Port: %s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:310
+#, c-format
+msgid "Failed to get source information: %s"
+msgstr "未能å–得來æºè³‡è¨Šï¼š%s"
+
+#: ../src/utils/pactl.c:326
+#, c-format
+msgid ""
+"Source #%u\n"
+"\tState: %s\n"
+"\tName: %s\n"
+"\tDescription: %s\n"
+"\tDriver: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tOwner Module: %u\n"
+"\tMute: %s\n"
+"\tVolume: %s%s%s\n"
+"\t balance %0.2f\n"
+"\tBase Volume: %s%s%s\n"
+"\tMonitor of Sink: %s\n"
+"\tLatency: %0.0f usec, configured %0.0f usec\n"
+"\tFlags: %s%s%s%s%s%s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:358 ../src/utils/pactl.c:414 ../src/utils/pactl.c:449
+#: ../src/utils/pactl.c:486 ../src/utils/pactl.c:545 ../src/utils/pactl.c:546
+#: ../src/utils/pactl.c:556 ../src/utils/pactl.c:600 ../src/utils/pactl.c:601
+#: ../src/utils/pactl.c:607 ../src/utils/pactl.c:650 ../src/utils/pactl.c:651
+#: ../src/utils/pactl.c:658
+msgid "n/a"
+msgstr "n/a"
+
+#: ../src/utils/pactl.c:388
+#, c-format
+msgid "Failed to get module information: %s"
+msgstr "未能å–得模組資訊:%s"
+
+#: ../src/utils/pactl.c:406
+#, c-format
+msgid ""
+"Module #%u\n"
+"\tName: %s\n"
+"\tArgument: %s\n"
+"\tUsage counter: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:425
+#, c-format
+msgid "Failed to get client information: %s"
+msgstr "未能å–得客戶端資訊:%s"
+
+#: ../src/utils/pactl.c:443
+#, c-format
+msgid ""
+"Client #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:460
+#, c-format
+msgid "Failed to get card information: %s"
+msgstr "未能å–得音效å¡è³‡è¨Šï¼š%s"
+
+#: ../src/utils/pactl.c:478
+#, c-format
+msgid ""
+"Card #%u\n"
+"\tName: %s\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:492
+#, c-format
+msgid "\tProfiles:\n"
+msgstr "\t個人設定檔:\n"
+
+#: ../src/utils/pactl.c:498
+#, c-format
+msgid "\tActive Profile: %s\n"
+msgstr "\t啟用的個人設定檔:%s\n"
+
+#: ../src/utils/pactl.c:509
+#, c-format
+msgid "Failed to get sink input information: %s"
+msgstr "未能å–å¾— sink 輸入資訊:%s"
+
+#: ../src/utils/pactl.c:528
+#, c-format
+msgid ""
+"Sink Input #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSink: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tMute: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSink Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:567
+#, c-format
+msgid "Failed to get source output information: %s"
+msgstr "未能å–得來æºè¼¸å‡ºè³‡è¨Šï¼š%s"
+
+#: ../src/utils/pactl.c:587
+#, c-format
+msgid ""
+"Source Output #%u\n"
+"\tDriver: %s\n"
+"\tOwner Module: %s\n"
+"\tClient: %s\n"
+"\tSource: %u\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tBuffer Latency: %0.0f usec\n"
+"\tSource Latency: %0.0f usec\n"
+"\tResample method: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:618
+#, c-format
+msgid "Failed to get sample information: %s"
+msgstr "未能å–å¾—å–æ¨£è³‡è¨Šï¼š%s"
+
+#: ../src/utils/pactl.c:636
+#, c-format
+msgid ""
+"Sample #%u\n"
+"\tName: %s\n"
+"\tSample Specification: %s\n"
+"\tChannel Map: %s\n"
+"\tVolume: %s\n"
+"\t %s\n"
+"\t balance %0.2f\n"
+"\tDuration: %0.1fs\n"
+"\tSize: %s\n"
+"\tLazy: %s\n"
+"\tFilename: %s\n"
+"\tProperties:\n"
+"\t\t%s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:666 ../src/utils/pactl.c:676
+#, c-format
+msgid "Failure: %s"
+msgstr "失敗:%s"
+
+#: ../src/utils/pactl.c:700
+#, c-format
+msgid "Failed to upload sample: %s"
+msgstr "未能上傳樣本:%s"
+
+#: ../src/utils/pactl.c:717
+msgid "Premature end of file"
+msgstr "未完æˆçš„æª”案çµå°¾"
+
+#: ../src/utils/pactl.c:737
+msgid "new"
+msgstr ""
+
+#: ../src/utils/pactl.c:740
+msgid "change"
+msgstr ""
+
+#: ../src/utils/pactl.c:743
+msgid "remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:746 ../src/utils/pactl.c:781
+msgid "unknown"
+msgstr ""
+
+#: ../src/utils/pactl.c:754
+msgid "sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:757
+msgid "source"
+msgstr ""
+
+#: ../src/utils/pactl.c:760
+msgid "sink-input"
+msgstr ""
+
+#: ../src/utils/pactl.c:763
+msgid "source-output"
+msgstr ""
+
+#: ../src/utils/pactl.c:766
+msgid "module"
+msgstr ""
+
+#: ../src/utils/pactl.c:769
+msgid "client"
+msgstr ""
+
+#: ../src/utils/pactl.c:772
+msgid "sample-cache"
+msgstr ""
+
+#: ../src/utils/pactl.c:775 ../src/utils/pactl.c:778
+#, fuzzy
+msgid "server"
+msgstr "無效的伺æœå™¨"
+
+#: ../src/utils/pactl.c:787
+#, c-format
+msgid "Event '%s' on %s #%u\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:955
+msgid "Got SIGINT, exiting."
+msgstr "å–å¾— SIGINT,正在退出。"
+
+#: ../src/utils/pactl.c:961
+#, c-format
+msgid ""
+"%s [options] stat\n"
+"%s [options] list\n"
+"%s [options] exit\n"
+"%s [options] upload-sample FILENAME [NAME]\n"
+"%s [options] play-sample NAME [SINK]\n"
+"%s [options] remove-sample NAME\n"
+"%s [options] move-sink-input SINKINPUT SINK\n"
+"%s [options] move-source-output SOURCEOUTPUT SOURCE\n"
+"%s [options] load-module NAME [ARGS ...]\n"
+"%s [options] unload-module MODULE\n"
+"%s [options] suspend-sink SINK 1|0\n"
+"%s [options] suspend-source SOURCE 1|0\n"
+"%s [options] set-card-profile CARD PROFILE\n"
+"%s [options] set-sink-port SINK PORT\n"
+"%s [options] set-source-port SOURCE PORT\n"
+"%s [options] set-sink-volume SINK VOLUME\n"
+"%s [options] set-source-volume SOURCE VOLUME\n"
+"%s [options] set-sink-input-volume SINKINPUT VOLUME\n"
+"%s [options] set-sink-mute SINK 1|0\n"
+"%s [options] set-source-mute SOURCE 1|0\n"
+"%s [options] set-sink-input-mute SINKINPUT 1|0\n"
+"%s [options] subscribe\n"
+"\n"
+" -h, --help Show this help\n"
+" --version Show version\n"
+"\n"
+" -s, --server=SERVER The name of the server to connect "
+"to\n"
+" -n, --client-name=NAME How to call this client on the "
+"server\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:1026
+#, c-format
+msgid ""
+"pactl %s\n"
+"Compiled with libpulse %s\n"
+"Linked with libpulse %s\n"
+msgstr ""
+
+#: ../src/utils/pactl.c:1072
+msgid "Please specify a sample file to load"
+msgstr "請旨定è¦è¼‰å…¥çš„å–æ¨£æª”"
+
+#: ../src/utils/pactl.c:1085
+msgid "Failed to open sound file."
+msgstr "未能開啟音效檔。"
+
+#: ../src/utils/pactl.c:1097
+msgid "Warning: Failed to determine sample specification from file."
+msgstr "è­¦å‘Šï¼šæœªèƒ½å¾žæª”æ¡ˆå¾—çŸ¥å–æ¨£è¦æ ¼ã€‚"
+
+#: ../src/utils/pactl.c:1107
+msgid "You have to specify a sample name to play"
+msgstr ""
+
+#: ../src/utils/pactl.c:1119
+msgid "You have to specify a sample name to remove"
+msgstr ""
+
+#: ../src/utils/pactl.c:1128
+msgid "You have to specify a sink input index and a sink"
+msgstr ""
+
+#: ../src/utils/pactl.c:1138
+msgid "You have to specify a source output index and a source"
+msgstr ""
+
+#: ../src/utils/pactl.c:1153
+msgid "You have to specify a module name and arguments."
+msgstr ""
+
+#: ../src/utils/pactl.c:1173
+msgid "You have to specify a module index"
+msgstr ""
+
+#: ../src/utils/pactl.c:1183
+msgid ""
+"You may not specify more than one sink. You have to specify a boolean value."
+msgstr ""
+
+#: ../src/utils/pactl.c:1196
+msgid ""
+"You may not specify more than one source. You have to specify a boolean "
+"value."
+msgstr ""
+
+#: ../src/utils/pactl.c:1208
+msgid "You have to specify a card name/index and a profile name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1219
+msgid "You have to specify a sink name/index and a port name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1230
+msgid "You have to specify a source name/index and a port name"
+msgstr ""
+
+#: ../src/utils/pactl.c:1242
+msgid "You have to specify a sink name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1247 ../src/utils/pactl.c:1264
+#: ../src/utils/pactl.c:1286 ../src/utils/pactl.c:1302
+#: ../src/utils/pactl.c:1319 ../src/utils/pactl.c:1341
+msgid "Invalid volume specification"
+msgstr ""
+
+#: ../src/utils/pactl.c:1259
+msgid "You have to specify a source name/index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1276
+msgid "You have to specify a sink input index and a volume"
+msgstr ""
+
+#: ../src/utils/pactl.c:1281
+msgid "Invalid sink input index"
+msgstr ""
+
+#: ../src/utils/pactl.c:1297
+msgid "You have to specify a sink name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1314
+msgid "You have to specify a source name/index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1331
+msgid "You have to specify a sink input index and a mute boolean"
+msgstr ""
+
+#: ../src/utils/pactl.c:1336
+msgid "Invalid sink input index specification"
+msgstr ""
+
+#: ../src/utils/pactl.c:1359
+msgid "No valid command specified."
+msgstr "沒有指定有效的命令。"
+
+#: ../src/utils/pax11publish.c:61
+#, c-format
+msgid ""
+"%s [-D display] [-S server] [-O sink] [-I source] [-c file] [-d|-e|-i|-r]\n"
+"\n"
+" -d Show current PulseAudio data attached to X11 display (default)\n"
+" -e Export local PulseAudio data to X11 display\n"
+" -i Import PulseAudio data from X11 display to local environment "
+"variables and cookie file.\n"
+" -r Remove PulseAudio data from X11 display\n"
+msgstr ""
+
+#: ../src/utils/pax11publish.c:94
+#, c-format
+msgid "Failed to parse command line.\n"
+msgstr "未能解æžå‘½ä»¤åˆ—。\n"
+
+#: ../src/utils/pax11publish.c:108
+#, c-format
+msgid "Server: %s\n"
+msgstr "伺æœå™¨ï¼š%s\n"
+
+#: ../src/utils/pax11publish.c:110
+#, c-format
+msgid "Source: %s\n"
+msgstr "來æºï¼š%s\n"
+
+#: ../src/utils/pax11publish.c:112
+#, c-format
+msgid "Sink: %s\n"
+msgstr "Sink: %s\n"
+
+#: ../src/utils/pax11publish.c:114
+#, c-format
+msgid "Cookie: %s\n"
+msgstr "Cookie: %s\n"
+
+#: ../src/utils/pax11publish.c:132
+#, c-format
+msgid "Failed to parse cookie data\n"
+msgstr "æœªèƒ½è§£æž cookie 資料\n"
+
+#: ../src/utils/pax11publish.c:137
+#, c-format
+msgid "Failed to save cookie data\n"
+msgstr "未能儲存 cookie 資料\n"
+
+#: ../src/utils/pax11publish.c:152
+#, c-format
+msgid "Failed to load client configuration file.\n"
+msgstr "未能載入客戶端é…置檔。\n"
+
+#: ../src/utils/pax11publish.c:157
+#, c-format
+msgid "Failed to read environment configuration data.\n"
+msgstr "未能讀å–環境é…置資料。\n"
+
+#: ../src/utils/pax11publish.c:174
+#, c-format
+msgid "Failed to get FQDN.\n"
+msgstr "未能å–å¾— FQDN。\n"
+
+#: ../src/utils/pax11publish.c:194
+#, c-format
+msgid "Failed to load cookie data\n"
+msgstr "未能載入 cookie 資料\n"
+
+#: ../src/utils/pax11publish.c:211
+#, c-format
+msgid "Not yet implemented.\n"
+msgstr "尚未實作。\n"
+
+#: ../src/utils/pacmd.c:65
+msgid "No PulseAudio daemon running, or not running as session daemon."
+msgstr ""
+
+#: ../src/utils/pacmd.c:70
+#, c-format
+msgid "socket(PF_UNIX, SOCK_STREAM, 0): %s"
+msgstr ""
+
+#: ../src/utils/pacmd.c:87
+#, c-format
+msgid "connect(): %s"
+msgstr "connect(): %s"
+
+#: ../src/utils/pacmd.c:95
+msgid "Failed to kill PulseAudio daemon."
+msgstr "æœªèƒ½çµæŸ PulseAudio 幕後程å¼ã€‚"
+
+#: ../src/utils/pacmd.c:103
+msgid "Daemon not responding."
+msgstr "å¹•å¾Œç¨‹å¼æ²’有回應。"
+
+#: ../src/utils/pacmd.c:178
+#, c-format
+msgid "poll(): %s"
+msgstr "poll(): %s"
+
+#: ../src/utils/pacmd.c:189 ../src/utils/pacmd.c:209
+#, c-format
+msgid "read(): %s"
+msgstr "read(): %s"
+
+#: ../src/utils/pacmd.c:231 ../src/utils/pacmd.c:249
+#, c-format
+msgid "write(): %s"
+msgstr "write(): %s"
+
+#: ../src/pulsecore/lock-autospawn.c:134 ../src/pulsecore/lock-autospawn.c:217
+msgid "Cannot access autospawn lock."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-sink.c:530 ../src/modules/alsa/alsa-sink.c:689
+#, c-format
+msgid ""
+"ALSA woke us up to write new data to the device, but there was actually "
+"nothing to write!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLOUT set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+
+#: ../src/modules/alsa/alsa-source.c:506 ../src/modules/alsa/alsa-source.c:656
+#, c-format
+msgid ""
+"ALSA woke us up to read new data from the device, but there was actually "
+"nothing to read!\n"
+"Most likely this is a bug in the ALSA driver '%s'. Please report this issue "
+"to the ALSA developers.\n"
+"We were woken up with POLLIN set -- however a subsequent snd_pcm_avail() "
+"returned 0 or another value < min_avail."
+msgstr ""
+
+#: ../src/modules/alsa/module-alsa-card.c:152
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2262
+#: ../src/modules/alsa/alsa-mixer.c:2936
+msgid "Off"
+msgstr "關閉"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2204
+msgid "High Fidelity Playback (A2DP)"
+msgstr "高傳真播放è£ç½® (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2218
+msgid "High Fidelity Capture (A2DP)"
+msgstr "高傳真擷å–è£ç½® (A2DP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2233
+msgid "Telephony Duplex (HSP/HFP)"
+msgstr "電話雙工 (HSP/HFP)"
+
+#: ../src/modules/bluetooth/module-bluetooth-device.c:2247
+msgid "Handsfree Gateway"
+msgstr ""
+
+#: ../src/modules/reserve-wrap.c:151
+msgid "PulseAudio Sound Server"
+msgstr "PulseAudio 音效伺æœå™¨"
+
+#: ../src/modules/module-rygel-media-server.c:592
+#: ../src/modules/module-rygel-media-server.c:606
+msgid "Output Devices"
+msgstr "輸出è£ç½®"
+
+#: ../src/modules/module-rygel-media-server.c:593
+#: ../src/modules/module-rygel-media-server.c:607
+msgid "Input Devices"
+msgstr "輸入è£ç½®"
+
+#: ../src/modules/module-rygel-media-server.c:797
+msgid "Audio on @HOSTNAME@"
+msgstr "éŸ³æ•ˆä½æ–¼ @HOSTNAME@"
+
+#: ../src/modules/alsa/alsa-mixer.c:1701
+msgid "Input"
+msgstr "輸入"
+
+#: ../src/modules/alsa/alsa-mixer.c:1702
+msgid "Docking Station Input"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1703
+msgid "Docking Station Microphone"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1704
+msgid "Line-In"
+msgstr "線路輸入"
+
+#: ../src/modules/alsa/alsa-mixer.c:1705
+msgid "Microphone"
+msgstr "麥克風"
+
+#: ../src/modules/alsa/alsa-mixer.c:1706
+msgid "External Microphone"
+msgstr "外接麥克風"
+
+#: ../src/modules/alsa/alsa-mixer.c:1707
+msgid "Internal Microphone"
+msgstr "內建麥克風"
+
+#: ../src/modules/alsa/alsa-mixer.c:1708
+msgid "Radio"
+msgstr "ç„¡ç·šé›»"
+
+#: ../src/modules/alsa/alsa-mixer.c:1709
+msgid "Video"
+msgstr "視訊"
+
+#: ../src/modules/alsa/alsa-mixer.c:1710
+msgid "Automatic Gain Control"
+msgstr "自動增益控制"
+
+#: ../src/modules/alsa/alsa-mixer.c:1711
+msgid "No Automatic Gain Control"
+msgstr "無自動增益控制"
+
+#: ../src/modules/alsa/alsa-mixer.c:1712
+msgid "Boost"
+msgstr "加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1713
+msgid "No Boost"
+msgstr "無加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1714
+msgid "Amplifier"
+msgstr "æšè²å™¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1715
+msgid "No Amplifier"
+msgstr "ç„¡æšè²å™¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1716
+#, fuzzy
+msgid "Bass Boost"
+msgstr "加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1717
+#, fuzzy
+msgid "No Bass Boost"
+msgstr "無加速器"
+
+#: ../src/modules/alsa/alsa-mixer.c:1718
+msgid "Speaker"
+msgstr ""
+
+#: ../src/modules/alsa/alsa-mixer.c:1719
+#, fuzzy
+msgid "Headphones"
+msgstr "類比頭戴å¼éº¥å…‹é¢¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1777
+msgid "Analog Input"
+msgstr "類比輸入"
+
+#: ../src/modules/alsa/alsa-mixer.c:1778
+msgid "Analog Microphone"
+msgstr "類比麥克風"
+
+#: ../src/modules/alsa/alsa-mixer.c:1779
+msgid "Analog Line-In"
+msgstr "類比線路輸入"
+
+#: ../src/modules/alsa/alsa-mixer.c:1780
+msgid "Analog Radio"
+msgstr "類比無線電"
+
+#: ../src/modules/alsa/alsa-mixer.c:1781
+msgid "Analog Video"
+msgstr "類比視訊"
+
+#: ../src/modules/alsa/alsa-mixer.c:1782
+msgid "Analog Output"
+msgstr "類比輸出"
+
+#: ../src/modules/alsa/alsa-mixer.c:1783
+msgid "Analog Headphones"
+msgstr "類比頭戴å¼éº¥å…‹é¢¨"
+
+#: ../src/modules/alsa/alsa-mixer.c:1784
+msgid "Analog Output (LFE)"
+msgstr "類比輸出 (LFE)"
+
+#: ../src/modules/alsa/alsa-mixer.c:1785
+msgid "Analog Mono Output"
+msgstr "類比單è²é“輸出"
+
+#: ../src/modules/alsa/alsa-mixer.c:1786
+#, fuzzy
+msgid "Analog Speakers"
+msgstr "類比立體è²"
+
+#: ../src/modules/alsa/alsa-mixer.c:1986
+#, c-format
+msgid "%s+%s"
+msgstr "%s+%s"
+
+#: ../src/modules/alsa/alsa-mixer.c:1989 ../src/modules/alsa/alsa-mixer.c:3409
+#, c-format
+msgid "%s / %s"
+msgstr "%s / %s"
+
+#: ../src/modules/alsa/alsa-mixer.c:2795
+msgid "Analog Mono"
+msgstr "類比單è²é“"
+
+#: ../src/modules/alsa/alsa-mixer.c:2796
+msgid "Analog Stereo"
+msgstr "類比立體è²"
+
+#: ../src/modules/alsa/alsa-mixer.c:2797
+msgid "Analog Surround 2.1"
+msgstr "é¡žæ¯”ç’°ç¹žè² 2.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2798
+msgid "Analog Surround 3.0"
+msgstr "é¡žæ¯”ç’°ç¹žè² 3.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2799
+msgid "Analog Surround 3.1"
+msgstr "é¡žæ¯”ç’°ç¹žè² 3.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2800
+msgid "Analog Surround 4.0"
+msgstr "é¡žæ¯”ç’°ç¹žè² 4.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2801
+msgid "Analog Surround 4.1"
+msgstr "é¡žæ¯”ç’°ç¹žè² 4.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2802
+msgid "Analog Surround 5.0"
+msgstr "é¡žæ¯”ç’°ç¹žè² 5.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2803
+msgid "Analog Surround 5.1"
+msgstr "é¡žæ¯”ç’°ç¹žè² 5.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2804
+msgid "Analog Surround 6.0"
+msgstr "é¡žæ¯”ç’°ç¹žè² 6.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2805
+msgid "Analog Surround 6.1"
+msgstr "é¡žæ¯”ç’°ç¹žè² 6.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2806
+msgid "Analog Surround 7.0"
+msgstr "é¡žæ¯”ç’°ç¹žè² 7.0"
+
+#: ../src/modules/alsa/alsa-mixer.c:2807
+msgid "Analog Surround 7.1"
+msgstr "é¡žæ¯”ç’°ç¹žè² 7.1"
+
+#: ../src/modules/alsa/alsa-mixer.c:2808
+msgid "Digital Stereo (IEC958)"
+msgstr "數ä½ç«‹é«”è² (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2809
+msgid "Digital Surround 4.0 (IEC958)"
+msgstr "數ä½ç’°ç¹žè² 4.0 (IEC958)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2810
+msgid "Digital Surround 4.0 (IEC958/AC3)"
+msgstr "數ä½ç’°ç¹žè² 4.0 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2811
+msgid "Digital Surround 5.1 (IEC958/AC3)"
+msgstr "數ä½ç’°ç¹žè² 5.1 (IEC958/AC3)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2812
+msgid "Digital Stereo (HDMI)"
+msgstr "數ä½ç«‹é«”è² (HDMI)"
+
+#: ../src/modules/alsa/alsa-mixer.c:2933
+msgid "Analog Mono Duplex"
+msgstr "類比單è²é“雙工"
+
+#: ../src/modules/alsa/alsa-mixer.c:2934
+msgid "Analog Stereo Duplex"
+msgstr "類比立體è²é›™å·¥"
+
+#: ../src/modules/alsa/alsa-mixer.c:2935
+msgid "Digital Stereo Duplex (IEC958)"
+msgstr "數ä½ç«‹é«”è²é›™å·¥ (IEC958)"
+
+#~ msgid "Low Frequency Emmiter"
+#~ msgstr "低頻率æšè²å™¨"
diff --git a/shave-libtool.in b/shave-libtool.in
deleted file mode 100644
index 1f3a720c..00000000
--- a/shave-libtool.in
+++ /dev/null
@@ -1,69 +0,0 @@
-#!/bin/sh
-
-# we need sed
-SED=@SED@
-if test -z "$SED" ; then
-SED=sed
-fi
-
-lt_unmangle ()
-{
- last_result=`echo $1 | $SED -e 's#.libs/##' -e 's#[0-9a-zA-Z_\-\.]*_la-##'`
-}
-
-# the real libtool to use
-LIBTOOL="$1"
-shift
-
-# if 1, don't print anything, the underlaying wrapper will do it
-pass_though=0
-
-# scan the arguments, keep the right ones for libtool, and discover the mode
-preserved_args=
-while test "$#" -gt 0; do
- opt="$1"
- shift
-
- case $opt in
- --mode=*)
- mode=`echo $opt | $SED -e 's/[-_a-zA-Z0-9]*=//'`
- preserved_args="$preserved_args $opt"
- ;;
- -o)
- lt_output="$1"
- preserved_args="$preserved_args $opt"
- ;;
- *)
- preserved_args="$preserved_args $opt"
- ;;
- esac
-done
-
-case "$mode" in
-compile)
- # shave will be called and print the actual CC/CXX/LINK line
- preserved_args="$preserved_args --shave-mode=$mode"
- pass_though=1
- ;;
-link)
- preserved_args="$preserved_args --shave-mode=$mode"
- Q=" LINK "
- ;;
-*)
- # let's u
- # echo "*** libtool: Unimplemented mode: $mode, fill a bug report"
- ;;
-esac
-
-lt_unmangle "$lt_output"
-output=$last_result
-
-if test -z $V; then
- if test $pass_though -eq 0; then
- echo "$Q$output"
- fi
- $LIBTOOL --silent $preserved_args
-else
- echo $LIBTOOL $preserved_args
- $LIBTOOL $preserved_args
-fi
diff --git a/shave.in b/shave.in
deleted file mode 100644
index 5c16f27a..00000000
--- a/shave.in
+++ /dev/null
@@ -1,79 +0,0 @@
-#!/bin/sh
-
-# we need sed
-SED=@SED@
-if test -z "$SED" ; then
-SED=sed
-fi
-
-lt_unmangle ()
-{
- last_result=`echo $1 | $SED -e 's#.libs/##' -e 's#[0-9a-zA-Z_\-\.]*_la-##'`
-}
-
-# the tool to wrap (cc, cxx, ar, ranlib, ..)
-tool="$1"
-shift
-
-# the reel tool (to call)
-REEL_TOOL="$1"
-shift
-
-pass_through=0
-preserved_args=
-while test "$#" -gt 0; do
- opt="$1"
- shift
-
- case $opt in
- --shave-mode=*)
- mode=`echo $opt | $SED -e 's/[-_a-zA-Z0-9]*=//'`
- ;;
- -o)
- lt_output="$1"
- preserved_args="$preserved_args $opt"
- ;;
- *)
- preserved_args="$preserved_args $opt"
- ;;
- esac
-done
-
-# mode=link is handled in the libtool wrapper
-case "$mode,$tool" in
-link,*)
- pass_through=1
- ;;
-*,cxx)
- Q=" CXX "
- ;;
-*,cc)
- Q=" CC "
- ;;
-*,fc)
- Q=" FC "
- ;;
-*,f77)
- Q=" F77 "
- ;;
-*,objc)
- Q=" OBJC "
- ;;
-*,*)
- # should not happen
- Q=" CC "
- ;;
-esac
-
-lt_unmangle "$lt_output"
-output=$last_result
-
-if test -z $V; then
- if test $pass_through -eq 0; then
- echo "$Q$output"
- fi
- $REEL_TOOL $preserved_args
-else
- echo $REEL_TOOL $preserved_args
- $REEL_TOOL $preserved_args
-fi
diff --git a/src/.gitignore b/src/.gitignore
index 82331524..072a75c5 100644
--- a/src/.gitignore
+++ b/src/.gitignore
@@ -1,3 +1,5 @@
+once-test
+usergroup-test
sigbus-test
TAGS
alsa-time-test
@@ -22,7 +24,6 @@ cpulimit-test2
daemon.conf
default.pa
system.pa
-envelope-test
esdcompat
flist-test
gconf-helper
@@ -36,7 +37,6 @@ mcalign-test
memblock-test
memblockq-test
mix-test
-pabrowse
pacat
pacat-simple
pacmd
@@ -62,4 +62,9 @@ thread-test
utf8-test
voltest
start-pulseaudio-x11
+start-pulseaudio-kde
vector-test
+*-symdef.h
+connect-stress
+extended-test
+format-test
diff --git a/src/Makefile.am b/src/Makefile.am
index 70b16be3..9117004a 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -19,26 +19,22 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
# USA.
-
###################################
# Extra directories #
###################################
pulseincludedir=$(includedir)/pulse
pulsecoreincludedir=$(includedir)/pulsecore
-pulseconfdir=$(sysconfdir)/pulse
pulselibexecdir=$(libexecdir)/pulse
+if HAVE_X11
xdgautostartdir=$(sysconfdir)/xdg/autostart
-
-###################################
-# Defines #
-###################################
-
-PA_BINARY=$(bindir)/pulseaudio$(EXEEXT)
-if OS_IS_WIN32
-PA_DEFAULT_CONFIG_DIR=%PULSE_ROOT%
-else
-PA_DEFAULT_CONFIG_DIR=$(pulseconfdir)
+endif
+if HAVE_ALSA
+alsaprofilesetsdir=$(datadir)/pulseaudio/alsa-mixer/profile-sets
+alsapathsdir=$(datadir)/pulseaudio/alsa-mixer/paths
+endif
+if HAVE_DBUS
+dbuspolicydir=$(sysconfdir)/dbus-1/system.d
endif
###################################
@@ -47,49 +43,33 @@ endif
AM_CFLAGS = \
-I$(top_srcdir)/src \
- -I$(top_builddir)/src \
-I$(top_srcdir)/src/modules \
-I$(top_builddir)/src/modules \
- -I$(top_srcdir)/src/modules/rtp \
- -I$(top_builddir)/src/modules/rtp \
- -I$(top_srcdir)/src/modules/gconf \
- -I$(top_builddir)/src/modules/gconf \
- -I$(top_srcdir)/src/modules/bluetooth \
- -I$(top_builddir)/src/modules/bluetooth \
- -I$(top_srcdir)/src/modules/oss \
- -I$(top_builddir)/src/modules/oss \
- -I$(top_srcdir)/src/modules/alsa \
- -I$(top_builddir)/src/modules/alsa \
- -I$(top_srcdir)/src/modules/raop \
- $(PTHREAD_CFLAGS) -D_POSIX_PTHREAD_SEMANTICS \
- $(LIBSAMPLERATE_CFLAGS) \
- $(LIBSNDFILE_CFLAGS) \
- $(LIBSPEEX_CFLAGS) \
- -DPA_DLSEARCHPATH=\"$(modlibexecdir)\" \
- -DPA_DEFAULT_CONFIG_DIR=\"$(PA_DEFAULT_CONFIG_DIR)\" \
- -DPA_BINARY=\"$(PA_BINARY)\" \
- -DPA_SYSTEM_RUNTIME_PATH=\"$(PA_SYSTEM_RUNTIME_PATH)\" \
- -DPA_SYSTEM_CONFIG_PATH=\"$(PA_SYSTEM_CONFIG_PATH)\" \
- -DPA_SYSTEM_STATE_PATH=\"$(PA_SYSTEM_STATE_PATH)\" \
- -DAO_REQUIRE_CAS \
- -DPULSE_LOCALEDIR=\"$(pulselocaledir)\" \
- -DPA_MACHINE_ID=\"$(localstatedir)/lib/dbus/machine-id\"
+ $(PTHREAD_CFLAGS) \
+ -DPA_ALSA_PATHS_DIR=\"$(alsapathsdir)\" \
+ -DPA_ALSA_PROFILE_SETS_DIR=\"$(alsaprofilesetsdir)\"
AM_LIBADD = $(PTHREAD_LIBS) $(INTLLIBS)
AM_LDADD = $(PTHREAD_LIBS) $(INTLLIBS)
-AM_LDFLAGS = -Wl,-z,nodelete
+AM_LDFLAGS = $(NODELETE_LDFLAGS)
if STATIC_BINS
BINLDFLAGS = -static
endif
if OS_IS_WIN32
-AM_LDFLAGS+=-Wl,--export-all-symbols
+AM_LDFLAGS+=-Wl,--export-all-symbols,--enable-auto-import -no-undefined
WINSOCK_LIBS=-lwsock32 -lws2_32 -lwininet
endif
+if OS_IS_DARWIN
+AM_LDFLAGS+=-Wl,-headerpad_max_install_names -headerpad_max_install_names
+endif
+
FOREIGN_CFLAGS = -w
-MODULE_LDFLAGS = -module -disable-static -avoid-version
+
+MODULE_LDFLAGS = $(AM_LDFLAGS) -module -disable-static -avoid-version $(NOUNDEFINED_LDFLAGS)
+MODULE_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
###################################
# Extra files #
@@ -101,15 +81,18 @@ EXTRA_DIST = \
daemon/daemon.conf.in \
daemon/default.pa.in \
daemon/system.pa.in \
- daemon/default.pa.win32 \
depmod.py \
daemon/esdcompat.in \
daemon/start-pulseaudio-x11.in \
+ daemon/start-pulseaudio-kde.in \
utils/padsp \
+ utils/qpaeq \
modules/module-defs.h.m4 \
daemon/pulseaudio.desktop.in \
+ daemon/pulseaudio-kde.desktop.in \
map-file \
- daemon/org.pulseaudio.policy.in
+ daemon/pulseaudio-system.conf \
+ modules/echo-cancel/adrian-license.txt
pulseconf_DATA = \
default.pa \
@@ -117,16 +100,28 @@ pulseconf_DATA = \
daemon.conf \
client.conf
+if HAVE_DBUS
+dbuspolicy_DATA = \
+ daemon/pulseaudio-system.conf
+endif
+
if HAVE_X11
xdgautostart_in_files = \
- daemon/pulseaudio.desktop.in
-endif
+ daemon/pulseaudio.desktop.in \
+ daemon/pulseaudio-kde.desktop.in
xdgautostart_DATA = $(xdgautostart_in_files:.desktop.in=.desktop)
@INTLTOOL_DESKTOP_RULE@
+endif
-BUILT_SOURCES = \
- pulse/version.h
+###################################
+# Includes #
+###################################
+
+BUILT_SOURCES =
+CLEANFILES =
+include $(top_srcdir)/orc.mak
+ORC_SOURCE =
###################################
# Main daemon #
@@ -135,7 +130,7 @@ BUILT_SOURCES = \
bin_PROGRAMS = pulseaudio
pulseaudio_SOURCES = \
- daemon/caps.h daemon/caps.c \
+ daemon/caps.c daemon/caps.h \
daemon/cmdline.c daemon/cmdline.h \
daemon/cpulimit.c daemon/cpulimit.h \
daemon/daemon-conf.c daemon/daemon-conf.h \
@@ -143,10 +138,16 @@ pulseaudio_SOURCES = \
daemon/ltdl-bind-now.c daemon/ltdl-bind-now.h \
daemon/main.c
-pulseaudio_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS) $(LIBSAMPLERATE_CFLAGS) $(LIBSPEEX_CFLAGS) $(LIBSNDFILE_CFLAGS) $(CAP_CFLAGS) $(LIBOIL_CFLAGS) $(DBUS_CFLAGS)
-pulseaudio_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la $(LIBLTDL) $(LIBSAMPLERATE_LIBS) $(LIBSPEEX_LIBS) $(LIBSNDFILE_LIBS) $(CAP_LIBS) $(LIBOIL_LIBS) $(DBUS_LIBS)
+pulseaudio_CFLAGS = $(AM_CFLAGS) $(CAP_CFLAGS)
+pulseaudio_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la $(LIBLTDL) $(CAP_LIBS)
# This is needed because automake doesn't properly expand the foreach below
-pulseaudio_DEPENDENCIES = libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la $(PREOPEN_LIBS)
+pulseaudio_DEPENDENCIES = libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la $(PREOPEN_LIBS)
+
+if HAVE_DBUS
+pulseaudio_CFLAGS += $(DBUS_CFLAGS)
+pulseaudio_SOURCES += daemon/server-lookup.c daemon/server-lookup.h
+pulseaudio_LDADD += $(DBUS_LIBS)
+endif
if PREOPEN_MODS
PREOPEN_LIBS = $(PREOPEN_MODS)
@@ -155,29 +156,24 @@ PREOPEN_LIBS = $(modlibexec_LTLIBRARIES)
endif
if FORCE_PREOPEN
-pulseaudio_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) -dlpreopen force $(foreach f,$(PREOPEN_LIBS),-dlpreopen $(f))
+pulseaudio_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(IMMEDIATE_LDFLAGS) -dlpreopen force $(foreach f,$(PREOPEN_LIBS),-dlpreopen $(f))
else
-pulseaudio_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) -dlopen force $(foreach f,$(PREOPEN_LIBS),-dlopen $(f))
-endif
-
-if HAVE_POLKIT
-policy_in_files = daemon/org.pulseaudio.policy.in
-policy_DATA = $(policy_in_files:.policy.in=.policy)
-@INTLTOOL_POLICY_RULE@
-
-pulseaudio_SOURCES += daemon/polkit.c daemon/polkit.h
-pulseaudio_CFLAGS += $(POLKIT_CFLAGS)
-pulseaudio_LDADD += $(POLKIT_LIBS)
+pulseaudio_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(IMMEDIATE_LDFLAGS) -dlopen force $(foreach f,$(PREOPEN_LIBS),-dlopen $(f))
endif
###################################
# Utility programs #
###################################
+bin_SCRIPTS = esdcompat
+
bin_PROGRAMS += \
pacat \
- pactl \
- pasuspender
+ pactl
+
+if !OS_IS_WIN32
+bin_PROGRAMS += pasuspender
+endif
if HAVE_AF_UNIX
bin_PROGRAMS += pacmd
@@ -185,50 +181,38 @@ endif
if HAVE_X11
bin_PROGRAMS += pax11publish
+bin_SCRIPTS += start-pulseaudio-x11 start-pulseaudio-kde
endif
-if HAVE_AVAHI
-bin_PROGRAMS += pabrowse
-endif
-
-bin_SCRIPTS = esdcompat start-pulseaudio-x11
-
pacat_SOURCES = utils/pacat.c
-pacat_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la $(LIBSNDFILE_LIBS)
+pacat_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la $(LIBSNDFILE_LIBS)
pacat_CFLAGS = $(AM_CFLAGS) $(LIBSNDFILE_CFLAGS)
pacat_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
pactl_SOURCES = utils/pactl.c
-pactl_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la $(LIBSNDFILE_LIBS)
+pactl_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la $(LIBSNDFILE_LIBS)
pactl_CFLAGS = $(AM_CFLAGS) $(LIBSNDFILE_CFLAGS)
pactl_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
pasuspender_SOURCES = utils/pasuspender.c
-pasuspender_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+pasuspender_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
pasuspender_CFLAGS = $(AM_CFLAGS)
pasuspender_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
pacmd_SOURCES = utils/pacmd.c
pacmd_CFLAGS = $(AM_CFLAGS)
-pacmd_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+pacmd_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
pacmd_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
pax11publish_SOURCES = utils/pax11publish.c
pax11publish_CFLAGS = $(AM_CFLAGS) $(X11_CFLAGS)
-pax11publish_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la $(X11_LIBS)
+pax11publish_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la $(X11_LIBS)
pax11publish_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
-pabrowse_SOURCES = utils/pabrowse.c
-pabrowse_LDADD = $(AM_LDADD) libpulse.la libpulse-browse.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-pabrowse_CFLAGS = $(AM_CFLAGS)
-pabrowse_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
-
###################################
# Test programs #
###################################
-# missing: mcalign-test flist-test pacat-simple parec-simple sync-playback rtstutter stripnul interpol-test thread-test
-
TESTS = \
mainloop-test \
strlist-test \
@@ -239,6 +223,7 @@ TESTS = \
channelmap-test \
thread-mainloop-test \
utf8-test \
+ format-test \
get-binary-name-test \
ipacl-test \
hook-list-test \
@@ -252,55 +237,32 @@ TESTS = \
smoother-test \
mix-test \
remix-test \
- envelope-test \
proplist-test \
lock-autospawn-test \
- prioq-test \
- sigbus-test
+ prioq-test
-TESTS_BINARIES = \
- mainloop-test \
+TESTS_norun = \
mcalign-test \
+ once-test \
pacat-simple \
parec-simple \
- strlist-test \
- close-test \
- voltest \
- vector-test \
- memblockq-test \
+ extended-test \
sync-playback \
interpol-test \
- channelmap-test \
- thread-mainloop-test \
- utf8-test \
- get-binary-name-test \
- ipacl-test \
- hook-list-test \
- memblock-test \
thread-test \
flist-test \
- asyncq-test \
- asyncmsgq-test \
- queue-test \
- rtpoll-test \
- sig2str-test \
- resampler-test \
- smoother-test \
- mix-test \
- remix-test \
- envelope-test \
- proplist-test \
rtstutter \
stripnul \
- lock-autospawn-test \
- prioq-test \
- sigbus-test
+ connect-stress
+
+if !OS_IS_WIN32
+TESTS += \
+ sigbus-test \
+ usergroup-test
+endif
if HAVE_SIGXCPU
-#TESTS += \
-# cpulimit-test \
-# cpulimit-test2
-TESTS_BINARIES += \
+TESTS_norun += \
cpulimit-test \
cpulimit-test2
endif
@@ -308,139 +270,152 @@ endif
if HAVE_GLIB20
TESTS += \
mainloop-test-glib
-TESTS_BINARIES += \
- mainloop-test-glib
endif
if HAVE_GTK20
-TESTS_BINARIES += \
+TESTS_norun += \
gtk-test
endif
if HAVE_ALSA
-TESTS_BINARIES += \
+TESTS_norun += \
alsa-time-test
endif
if BUILD_TESTS_DEFAULT
-noinst_PROGRAMS = $(TESTS_BINARIES)
+noinst_PROGRAMS = $(TESTS) $(TESTS_norun)
else
-check_PROGRAMS = $(TESTS_BINARIES)
+check_PROGRAMS = $(TESTS) $(TESTS_norun)
endif
mainloop_test_SOURCES = tests/mainloop-test.c
mainloop_test_CFLAGS = $(AM_CFLAGS)
-mainloop_test_LDADD = $(AM_LDADD) libpulse.la
+mainloop_test_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
mainloop_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
thread_mainloop_test_SOURCES = tests/thread-mainloop-test.c
thread_mainloop_test_CFLAGS = $(AM_CFLAGS)
-thread_mainloop_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+thread_mainloop_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
thread_mainloop_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
utf8_test_SOURCES = tests/utf8-test.c
utf8_test_CFLAGS = $(AM_CFLAGS)
-utf8_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+utf8_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
utf8_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+format_test_SOURCES = tests/format-test.c
+format_test_CFLAGS = $(AM_CFLAGS)
+format_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+format_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+
get_binary_name_test_SOURCES = tests/get-binary-name-test.c
get_binary_name_test_CFLAGS = $(AM_CFLAGS)
-get_binary_name_test_LDADD = $(AM_LDADD) libpulse.la
+get_binary_name_test_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
get_binary_name_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
ipacl_test_SOURCES = tests/ipacl-test.c
ipacl_test_CFLAGS = $(AM_CFLAGS)
-ipacl_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+ipacl_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
ipacl_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
hook_list_test_SOURCES = tests/hook-list-test.c
hook_list_test_CFLAGS = $(AM_CFLAGS)
-hook_list_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+hook_list_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
hook_list_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
memblock_test_SOURCES = tests/memblock-test.c
memblock_test_CFLAGS = $(AM_CFLAGS)
-memblock_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+memblock_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
memblock_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
thread_test_SOURCES = tests/thread-test.c
thread_test_CFLAGS = $(AM_CFLAGS)
-thread_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+thread_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
thread_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+once_test_SOURCES = tests/once-test.c
+once_test_CFLAGS = $(AM_CFLAGS)
+once_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+once_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+
flist_test_SOURCES = tests/flist-test.c
flist_test_CFLAGS = $(AM_CFLAGS)
-flist_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+flist_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
flist_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
asyncq_test_SOURCES = tests/asyncq-test.c
asyncq_test_CFLAGS = $(AM_CFLAGS)
-asyncq_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+asyncq_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
asyncq_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
asyncmsgq_test_SOURCES = tests/asyncmsgq-test.c
asyncmsgq_test_CFLAGS = $(AM_CFLAGS)
-asyncmsgq_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+asyncmsgq_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
asyncmsgq_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
queue_test_SOURCES = tests/queue-test.c
queue_test_CFLAGS = $(AM_CFLAGS)
-queue_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+queue_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
queue_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
rtpoll_test_SOURCES = tests/rtpoll-test.c
rtpoll_test_CFLAGS = $(AM_CFLAGS)
-rtpoll_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+rtpoll_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
rtpoll_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
mcalign_test_SOURCES = tests/mcalign-test.c
mcalign_test_CFLAGS = $(AM_CFLAGS)
-mcalign_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+mcalign_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
mcalign_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
pacat_simple_SOURCES = tests/pacat-simple.c
-pacat_simple_LDADD = $(AM_LDADD) libpulse.la libpulse-simple.la
+pacat_simple_LDADD = $(AM_LDADD) libpulse.la libpulse-simple.la libpulsecommon-@PA_MAJORMINOR@.la
pacat_simple_CFLAGS = $(AM_CFLAGS)
pacat_simple_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
parec_simple_SOURCES = tests/parec-simple.c
-parec_simple_LDADD = $(AM_LDADD) libpulse.la libpulse-simple.la
+parec_simple_LDADD = $(AM_LDADD) libpulse.la libpulse-simple.la libpulsecommon-@PA_MAJORMINOR@.la
parec_simple_CFLAGS = $(AM_CFLAGS)
parec_simple_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+extended_test_SOURCES = tests/extended-test.c
+extended_test_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+extended_test_CFLAGS = $(AM_CFLAGS)
+extended_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+
strlist_test_SOURCES = tests/strlist-test.c
strlist_test_CFLAGS = $(AM_CFLAGS)
-strlist_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+strlist_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
strlist_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
close_test_SOURCES = tests/close-test.c
close_test_CFLAGS = $(AM_CFLAGS)
-close_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+close_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
close_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
voltest_SOURCES = tests/voltest.c
voltest_CFLAGS = $(AM_CFLAGS)
-voltest_LDADD = $(AM_LDADD) libpulse.la
+voltest_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
voltest_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
vector_test_SOURCES = tests/vector-test.c
vector_test_CFLAGS = $(AM_CFLAGS)
-vector_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+vector_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
vector_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
channelmap_test_SOURCES = tests/channelmap-test.c
channelmap_test_CFLAGS = $(AM_CFLAGS)
-channelmap_test_LDADD = $(AM_LDADD) libpulse.la
+channelmap_test_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
channelmap_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
cpulimit_test_SOURCES = tests/cpulimit-test.c daemon/cpulimit.c daemon/cpulimit.h
cpulimit_test_CFLAGS = $(AM_CFLAGS)
-cpulimit_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+cpulimit_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
cpulimit_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
cpulimit_test2_SOURCES = tests/cpulimit-test.c daemon/cpulimit.c daemon/cpulimit.h
cpulimit_test2_CFLAGS = $(AM_CFLAGS) -DTEST2
-cpulimit_test2_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+cpulimit_test2_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
cpulimit_test2_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
mainloop_test_glib_SOURCES = $(mainloop_test_SOURCES)
@@ -450,81 +425,76 @@ mainloop_test_glib_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
memblockq_test_SOURCES = tests/memblockq-test.c
memblockq_test_CFLAGS = $(AM_CFLAGS)
-memblockq_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+memblockq_test_LDADD = $(AM_LDADD) $(WINSOCK_LIBS) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
memblockq_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
sync_playback_SOURCES = tests/sync-playback.c
-sync_playback_LDADD = $(AM_LDADD) libpulse.la
+sync_playback_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
sync_playback_CFLAGS = $(AM_CFLAGS)
sync_playback_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
interpol_test_SOURCES = tests/interpol-test.c
-interpol_test_LDADD = $(AM_LDADD) libpulse.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+interpol_test_LDADD = $(AM_LDADD) libpulse.la libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
interpol_test_CFLAGS = $(AM_CFLAGS)
interpol_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
sig2str_test_SOURCES = tests/sig2str-test.c
-sig2str_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+sig2str_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
sig2str_test_CFLAGS = $(AM_CFLAGS)
sig2str_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
resampler_test_SOURCES = tests/resampler-test.c
-resampler_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-resampler_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-resampler_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+resampler_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+resampler_test_CFLAGS = $(AM_CFLAGS)
+resampler_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
mix_test_SOURCES = tests/mix-test.c
-mix_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-mix_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-mix_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+mix_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+mix_test_CFLAGS = $(AM_CFLAGS)
+mix_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
remix_test_SOURCES = tests/remix-test.c
-remix_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-remix_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-remix_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+remix_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+remix_test_CFLAGS = $(AM_CFLAGS)
+remix_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
smoother_test_SOURCES = tests/smoother-test.c
-smoother_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+smoother_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
smoother_test_CFLAGS = $(AM_CFLAGS)
smoother_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
-envelope_test_SOURCES = tests/envelope-test.c
-envelope_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-envelope_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-envelope_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
-
proplist_test_SOURCES = tests/proplist-test.c
-proplist_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-proplist_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-proplist_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+proplist_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+proplist_test_CFLAGS = $(AM_CFLAGS)
+proplist_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
rtstutter_SOURCES = tests/rtstutter.c
-rtstutter_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-rtstutter_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-rtstutter_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+rtstutter_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+rtstutter_CFLAGS = $(AM_CFLAGS)
+rtstutter_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
stripnul_SOURCES = tests/stripnul.c
-stripnul_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-stripnul_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-stripnul_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+stripnul_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+stripnul_CFLAGS = $(AM_CFLAGS)
+stripnul_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
lock_autospawn_test_SOURCES = tests/lock-autospawn-test.c
-lock_autospawn_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-lock_autospawn_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-lock_autospawn_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+lock_autospawn_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+lock_autospawn_test_CFLAGS = $(AM_CFLAGS)
+lock_autospawn_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
prioq_test_SOURCES = tests/prioq-test.c
-prioq_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-prioq_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-prioq_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+prioq_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+prioq_test_CFLAGS = $(AM_CFLAGS)
+prioq_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
sigbus_test_SOURCES = tests/sigbus-test.c
-sigbus_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la
-sigbus_test_CFLAGS = $(AM_CFLAGS) $(LIBOIL_CFLAGS)
-sigbus_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(LIBOIL_LIBS)
+sigbus_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+sigbus_test_CFLAGS = $(AM_CFLAGS)
+sigbus_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
gtk_test_SOURCES = tests/gtk-test.c
-gtk_test_LDADD = $(AM_LDADD) libpulse.la libpulse-mainloop-glib.la
+gtk_test_LDADD = $(AM_LDADD) libpulse.la libpulse-mainloop-glib.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
gtk_test_CFLAGS = $(AM_CFLAGS) $(GTK20_CFLAGS)
gtk_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(GTK20_LIBS)
@@ -533,21 +503,42 @@ alsa_time_test_LDADD = $(AM_LDADD)
alsa_time_test_CFLAGS = $(AM_CFLAGS) $(ASOUNDLIB_CFLAGS)
alsa_time_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS) $(ASOUNDLIB_LIBS)
+usergroup_test_SOURCES = tests/usergroup-test.c
+usergroup_test_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+usergroup_test_CFLAGS = $(AM_CFLAGS)
+usergroup_test_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+
+connect_stress_SOURCES = tests/connect-stress.c
+connect_stress_LDADD = $(AM_LDADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
+connect_stress_CFLAGS = $(AM_CFLAGS)
+connect_stress_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
+
+
###################################
# Common library #
###################################
lib_LTLIBRARIES = \
- libpulsecommon-@PA_MAJORMINORMICRO@.la
+ libpulsecommon-@PA_MAJORMINOR@.la
-libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES = \
+libpulsecommon_@PA_MAJORMINOR@_la_SOURCES = \
pulse/client-conf.c pulse/client-conf.h \
pulse/i18n.c pulse/i18n.h \
pulse/fork-detect.c pulse/fork-detect.h \
+ pulse/xmalloc.c pulse/xmalloc.h \
+ pulse/proplist.c pulse/proplist.h \
+ pulse/utf8.c pulse/utf8.h \
+ pulse/channelmap.c pulse/channelmap.h \
+ pulse/sample.c pulse/sample.h \
+ pulse/util.c pulse/util.h \
+ pulse/timeval.c pulse/timeval.h \
+ pulse/rtclock.c pulse/rtclock.h \
+ pulse/format.c pulse/format.h \
pulsecore/atomic.h \
pulsecore/authkey.c pulsecore/authkey.h \
pulsecore/conf-parser.c pulsecore/conf-parser.h \
pulsecore/core-error.c pulsecore/core-error.h \
+ pulsecore/core-rtclock.c pulsecore/core-rtclock.h \
pulsecore/core-util.c pulsecore/core-util.h \
pulsecore/creds.h \
pulsecore/dynarray.c pulsecore/dynarray.h \
@@ -555,8 +546,7 @@ libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES = \
pulsecore/flist.c pulsecore/flist.h \
pulsecore/hashmap.c pulsecore/hashmap.h \
pulsecore/idxset.c pulsecore/idxset.h \
- pulsecore/inet_ntop.c pulsecore/inet_ntop.h \
- pulsecore/inet_pton.c pulsecore/inet_pton.h \
+ pulsecore/arpa-inet.c pulsecore/arpa-inet.h \
pulsecore/iochannel.c pulsecore/iochannel.h \
pulsecore/ioline.c pulsecore/ioline.h \
pulsecore/ipacl.h pulsecore/ipacl.c \
@@ -586,7 +576,6 @@ libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES = \
pulsecore/queue.c pulsecore/queue.h \
pulsecore/random.c pulsecore/random.h \
pulsecore/refcnt.h \
- pulsecore/rtclock.c pulsecore/rtclock.h \
pulsecore/shm.c pulsecore/shm.h \
pulsecore/bitset.c pulsecore/bitset.h \
pulsecore/socket-client.c pulsecore/socket-client.h \
@@ -597,15 +586,24 @@ libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES = \
pulsecore/tagstruct.c pulsecore/tagstruct.h \
pulsecore/time-smoother.c pulsecore/time-smoother.h \
pulsecore/tokenizer.c pulsecore/tokenizer.h \
+ pulsecore/usergroup.c pulsecore/usergroup.h \
pulsecore/sndfile-util.c pulsecore/sndfile-util.h \
- pulsecore/winsock.h
+ pulsecore/socket.h
+
+libpulsecommon_@PA_MAJORMINOR@_la_CFLAGS = $(AM_CFLAGS) $(LIBSAMPLERATE_CFLAGS) $(LIBSNDFILE_CFLAGS) $(LIBJSON_CFLAGS)
+libpulsecommon_@PA_MAJORMINOR@_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libpulsecommon_@PA_MAJORMINOR@_la_LIBADD = $(AM_LIBADD) $(LIBWRAP_LIBS) $(WINSOCK_LIBS) $(LTLIBICONV) $(LIBSAMPLERATE_LIBS) $(LIBSNDFILE_LIBS) $(LIBJSON_LIBS)
-libpulsecommon_@PA_MAJORMINORMICRO@_la_CFLAGS = $(AM_CFLAGS)
-libpulsecommon_@PA_MAJORMINORMICRO@_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
-libpulsecommon_@PA_MAJORMINORMICRO@_la_LIBADD = $(AM_LIBADD) $(LIBWRAP_LIBS) $(WINSOCK_LIBS) $(LTLIBICONV) $(LIBSNDFILE_LIBS)
+if HAVE_X11
+libpulsecommon_@PA_MAJORMINOR@_la_SOURCES += \
+ pulse/client-conf-x11.c pulse/client-conf-x11.h \
+ pulsecore/x11prop.c pulsecore/x11prop.h
+libpulsecommon_@PA_MAJORMINOR@_la_CFLAGS += $(X11_CFLAGS)
+libpulsecommon_@PA_MAJORMINOR@_la_LDFLAGS += $(X11_LIBS)
+endif
# proplist-util.h uses these header files, but not the library itself!
-libpulsecommon_@PA_MAJORMINORMICRO@_la_CFLAGS += $(GLIB20_CFLAGS) $(GTK20_CFLAGS)
+libpulsecommon_@PA_MAJORMINOR@_la_CFLAGS += $(GLIB20_CFLAGS) $(GTK20_CFLAGS)
## Please note that libpulsecommon implicitly also depends on<
## libpulse! i.e. we have a cyclic dependancy here. Which is intended
@@ -613,36 +611,41 @@ libpulsecommon_@PA_MAJORMINORMICRO@_la_CFLAGS += $(GLIB20_CFLAGS) $(GTK20_CFLAGS
## libpulsecommon only includes unofficial APIs.
if OS_IS_WIN32
-libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES += \
+libpulsecommon_@PA_MAJORMINOR@_la_SOURCES += \
pulsecore/mutex-win32.c pulsecore/mutex.h \
pulsecore/thread-win32.c pulsecore/thread.h \
pulsecore/semaphore-win32.c pulsecore/semaphore.h
-else
-libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES += \
+else !OS_IS_WIN32
+if OS_IS_DARWIN
+libpulsecommon_@PA_MAJORMINOR@_la_SOURCES += \
+ pulsecore/mutex-posix.c pulsecore/mutex.h \
+ pulsecore/thread-posix.c pulsecore/thread.h \
+ pulsecore/semaphore-osx.c pulsecore/semaphore.h
+libpulsecommon_@PA_MAJORMINOR@_la_CFLAGS += "-I/Developer/Headers/FlatCarbon/"
+#libpulsecommon_@PA_MAJORMINOR@_la_LDFLAGS += "-framework CoreServices"
+else !OS_IS_DARWIN
+libpulsecommon_@PA_MAJORMINOR@_la_SOURCES += \
pulsecore/mutex-posix.c pulsecore/mutex.h \
pulsecore/thread-posix.c pulsecore/thread.h \
pulsecore/semaphore-posix.c pulsecore/semaphore.h
-endif
-
-if HAVE_X11
-libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES += pulsecore/x11prop.c pulsecore/x11prop.h
-libpulsecommon_@PA_MAJORMINORMICRO@_la_CFLAGS += $(X11_CFLAGS)
-libpulsecommon_@PA_MAJORMINORMICRO@_la_LDFLAGS += $(X11_LIBS)
-endif
+endif !OS_IS_DARWIN
+endif !OS_IS_WIN32
if HAVE_LIBASYNCNS
-libpulsecommon_@PA_MAJORMINORMICRO@_la_CFLAGS += $(LIBASYNCNS_CFLAGS)
-libpulsecommon_@PA_MAJORMINORMICRO@_la_LIBADD += $(LIBASYNCNS_LIBS)
+libpulsecommon_@PA_MAJORMINOR@_la_CFLAGS += $(LIBASYNCNS_CFLAGS)
+libpulsecommon_@PA_MAJORMINOR@_la_LIBADD += $(LIBASYNCNS_LIBS)
endif
if OS_IS_WIN32
-libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES += pulsecore/dllmain.c
+libpulsecommon_@PA_MAJORMINOR@_la_SOURCES += pulsecore/dllmain.c
endif
if HAVE_DBUS
-libpulsecommon_@PA_MAJORMINORMICRO@_la_SOURCES += pulsecore/dbus-util.c pulsecore/dbus-util.h
-libpulsecommon_@PA_MAJORMINORMICRO@_la_CFLAGS += $(DBUS_CFLAGS)
-libpulsecommon_@PA_MAJORMINORMICRO@_la_LIBADD += $(DBUS_LIBS)
+libpulsecommon_@PA_MAJORMINOR@_la_SOURCES += \
+ pulsecore/dbus-util.c pulsecore/dbus-util.h \
+ pulsecore/rtkit.c pulsecore/rtkit.h
+libpulsecommon_@PA_MAJORMINOR@_la_CFLAGS += $(DBUS_CFLAGS)
+libpulsecommon_@PA_MAJORMINOR@_la_LIBADD += $(DBUS_LIBS)
endif
###################################
@@ -655,7 +658,10 @@ pulseinclude_HEADERS = \
pulse/context.h \
pulse/def.h \
pulse/error.h \
+ pulse/ext-device-manager.h \
+ pulse/ext-device-restore.h \
pulse/ext-stream-restore.h \
+ pulse/format.h \
pulse/gccmacro.h \
pulse/introspect.h \
pulse/mainloop-api.h \
@@ -664,6 +670,7 @@ pulseinclude_HEADERS = \
pulse/operation.h \
pulse/proplist.h \
pulse/pulseaudio.h \
+ pulse/rtclock.h \
pulse/sample.h \
pulse/scache.h \
pulse/simple.h \
@@ -681,14 +688,6 @@ lib_LTLIBRARIES += \
libpulse.la \
libpulse-simple.la
-if HAVE_AVAHI
-pulseinclude_HEADERS += \
- pulse/browser.h
-
-lib_LTLIBRARIES += \
- libpulse-browse.la
-endif
-
if HAVE_GLIB20
pulseinclude_HEADERS += \
pulse/glib-mainloop.h
@@ -704,6 +703,8 @@ libpulse_la_SOURCES = \
pulse/context.c pulse/context.h \
pulse/def.h \
pulse/error.c pulse/error.h \
+ pulse/ext-device-manager.c pulse/ext-device-manager.h \
+ pulse/ext-device-restore.c pulse/ext-device-restore.h \
pulse/ext-stream-restore.c pulse/ext-stream-restore.h \
pulse/gccmacro.h \
pulse/internal.h \
@@ -714,6 +715,7 @@ libpulse_la_SOURCES = \
pulse/operation.c pulse/operation.h \
pulse/proplist.c pulse/proplist.h \
pulse/pulseaudio.h \
+ pulse/rtclock.c pulse/rtclock.h \
pulse/sample.c pulse/sample.h \
pulse/scache.c pulse/scache.h \
pulse/stream.c pulse/stream.h \
@@ -725,53 +727,47 @@ libpulse_la_SOURCES = \
pulse/volume.c pulse/volume.h \
pulse/xmalloc.c pulse/xmalloc.h
-libpulse_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
-libpulse_la_LIBADD = $(AM_LIBADD) $(WINSOCK_LIBS) $(LTLIBICONV) libpulsecommon-@PA_MAJORMINORMICRO@.la
+libpulse_la_CFLAGS = $(AM_CFLAGS)
+libpulse_la_LIBADD = $(AM_LIBADD) $(WINSOCK_LIBS) $(LTLIBICONV) libpulsecommon-@PA_MAJORMINOR@.la
libpulse_la_LDFLAGS = $(AM_LDFLAGS) $(VERSIONING_LDFLAGS) -version-info $(LIBPULSE_VERSION_INFO)
-if HAVE_X11
-libpulse_la_SOURCES += pulse/client-conf-x11.c pulse/client-conf-x11.h
-libpulse_la_CFLAGS += $(X11_CFLAGS)
-libpulse_la_LDFLAGS += $(X11_LIBS)
+if HAVE_DBUS
+libpulse_la_CFLAGS += $(DBUS_CFLAGS)
+libpulse_la_LIBADD += $(DBUS_LIBS)
endif
libpulse_simple_la_SOURCES = pulse/simple.c pulse/simple.h
libpulse_simple_la_CFLAGS = $(AM_CFLAGS)
-libpulse_simple_la_LIBADD = $(AM_LIBADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+libpulse_simple_la_LIBADD = $(AM_LIBADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
libpulse_simple_la_LDFLAGS = $(AM_LDFLAGS) $(VERSIONING_LDFLAGS) -version-info $(LIBPULSE_SIMPLE_VERSION_INFO)
-libpulse_browse_la_SOURCES = pulse/browser.c pulse/browser.h pulsecore/avahi-wrap.c pulsecore/avahi-wrap.h
-libpulse_browse_la_CFLAGS = $(AM_CFLAGS) $(AVAHI_CFLAGS)
-libpulse_browse_la_LIBADD = $(AM_LIBADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la $(AVAHI_LIBS)
-libpulse_browse_la_LDFLAGS = $(AM_LDFLAGS) $(VERSIONING_LDFLAGS) -version-info $(LIBPULSE_BROWSE_VERSION_INFO)
-
libpulse_mainloop_glib_la_SOURCES = pulse/glib-mainloop.h pulse/glib-mainloop.c
libpulse_mainloop_glib_la_CFLAGS = $(AM_CFLAGS) $(GLIB20_CFLAGS)
-libpulse_mainloop_glib_la_LIBADD = $(AM_LIBADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la $(GLIB20_LIBS)
+libpulse_mainloop_glib_la_LIBADD = $(AM_LIBADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la $(GLIB20_LIBS)
libpulse_mainloop_glib_la_LDFLAGS = $(AM_LDFLAGS) $(VERSIONING_LDFLAGS) -version-info $(LIBPULSE_MAINLOOP_GLIB_VERSION_INFO)
###################################
# OSS emulation #
###################################
-if HAVE_OSS
+if HAVE_OSS_WRAPPER
lib_LTLIBRARIES += libpulsedsp.la
bin_SCRIPTS += utils/padsp
endif
libpulsedsp_la_SOURCES = utils/padsp.c
libpulsedsp_la_CFLAGS = $(AM_CFLAGS)
-libpulsedsp_la_LIBADD = $(AM_LIBADD) libpulse.la libpulsecommon-@PA_MAJORMINORMICRO@.la
+libpulsedsp_la_LIBADD = $(AM_LIBADD) libpulse.la libpulsecommon-@PA_MAJORMINOR@.la
libpulsedsp_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version -disable-static
###################################
# Daemon core library #
###################################
-lib_LTLIBRARIES += libpulsecore-@PA_MAJORMINORMICRO@.la
+lib_LTLIBRARIES += libpulsecore-@PA_MAJORMINOR@.la
# Pure core stuff
-libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES = \
+libpulsecore_@PA_MAJORMINOR@_la_SOURCES = \
pulsecore/asyncmsgq.c pulsecore/asyncmsgq.h \
pulsecore/asyncq.c pulsecore/asyncq.h \
pulsecore/auth-cookie.c pulsecore/auth-cookie.h \
@@ -782,7 +778,6 @@ libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES = \
pulsecore/core-scache.c pulsecore/core-scache.h \
pulsecore/core-subscribe.c pulsecore/core-subscribe.h \
pulsecore/core.c pulsecore/core.h \
- pulsecore/envelope.c pulsecore/envelope.h \
pulsecore/fdsem.c pulsecore/fdsem.h \
pulsecore/g711.c pulsecore/g711.h \
pulsecore/hook-list.c pulsecore/hook-list.h \
@@ -795,12 +790,20 @@ libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES = \
pulsecore/object.c pulsecore/object.h \
pulsecore/play-memblockq.c pulsecore/play-memblockq.h \
pulsecore/play-memchunk.c pulsecore/play-memchunk.h \
+ pulsecore/remap.c pulsecore/remap.h \
+ pulsecore/remap_mmx.c pulsecore/remap_sse.c \
pulsecore/resampler.c pulsecore/resampler.h \
pulsecore/rtpoll.c pulsecore/rtpoll.h \
- pulsecore/rtsig.c pulsecore/rtsig.h \
pulsecore/sample-util.c pulsecore/sample-util.h \
+ pulsecore/cpu.h \
+ pulsecore/cpu-arm.c pulsecore/cpu-arm.h \
+ pulsecore/cpu-x86.c pulsecore/cpu-x86.h \
+ pulsecore/cpu-orc.c pulsecore/cpu-orc.h \
+ pulsecore/svolume_c.c pulsecore/svolume_arm.c \
+ pulsecore/svolume_mmx.c pulsecore/svolume_sse.c \
pulsecore/sconv-s16be.c pulsecore/sconv-s16be.h \
pulsecore/sconv-s16le.c pulsecore/sconv-s16le.h \
+ pulsecore/sconv_sse.c \
pulsecore/sconv.c pulsecore/sconv.h \
pulsecore/shared.c pulsecore/shared.h \
pulsecore/shm.c pulsecore/shm.h \
@@ -816,34 +819,47 @@ libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES = \
pulsecore/time-smoother.c pulsecore/time-smoother.h \
pulsecore/database.h
-libpulsecore_@PA_MAJORMINORMICRO@_la_CFLAGS = $(AM_CFLAGS) $(LIBSAMPLERATE_CFLAGS) $(LIBSPEEX_CFLAGS) $(WINSOCK_CFLAGS) $(LIBOIL_CFLAGS)
-libpulsecore_@PA_MAJORMINORMICRO@_la_LDFLAGS = -avoid-version
-libpulsecore_@PA_MAJORMINORMICRO@_la_LIBADD = $(AM_LIBADD) $(LIBLTDL) $(LIBSAMPLERATE_LIBS) $(LIBSPEEX_LIBS) $(WINSOCK_LIBS) $(LIBOIL_LIBS) $(LTLIBICONV) libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la libpulsecore-foreign.la
+libpulsecore_@PA_MAJORMINOR@_la_CFLAGS = $(AM_CFLAGS) $(LIBSAMPLERATE_CFLAGS) $(LIBSPEEX_CFLAGS) $(LIBSNDFILE_CFLAGS) $(WINSOCK_CFLAGS)
+libpulsecore_@PA_MAJORMINOR@_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libpulsecore_@PA_MAJORMINOR@_la_LIBADD = $(AM_LIBADD) $(LIBLTDL) $(LIBSAMPLERATE_LIBS) $(LIBSPEEX_LIBS) $(LIBSNDFILE_LIBS) $(WINSOCK_LIBS) $(LTLIBICONV) libpulsecommon-@PA_MAJORMINOR@.la libpulse.la libpulsecore-foreign.la
+
+if HAVE_ORC
+ORC_SOURCE += pulsecore/svolume
+libpulsecore_@PA_MAJORMINOR@_la_SOURCES += pulsecore/svolume_orc.c
+nodist_libpulsecore_@PA_MAJORMINOR@_la_SOURCES = pulsecore/svolume-orc-gen.c pulsecore/svolume-orc-gen.h
+libpulsecore_@PA_MAJORMINOR@_la_CFLAGS += $(ORC_CFLAGS)
+libpulsecore_@PA_MAJORMINOR@_la_LIBADD += $(ORC_LIBS)
+endif
if HAVE_X11
-libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES += pulsecore/x11wrap.c pulsecore/x11wrap.h
-libpulsecore_@PA_MAJORMINORMICRO@_la_CFLAGS += $(X11_CFLAGS)
-libpulsecore_@PA_MAJORMINORMICRO@_la_LDFLAGS += $(X11_LIBS)
+libpulsecore_@PA_MAJORMINOR@_la_SOURCES += pulsecore/x11wrap.c pulsecore/x11wrap.h
+libpulsecore_@PA_MAJORMINOR@_la_CFLAGS += $(X11_CFLAGS)
+libpulsecore_@PA_MAJORMINOR@_la_LDFLAGS += $(X11_LIBS)
endif
if HAVE_DBUS
-libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES += pulsecore/dbus-shared.c pulsecore/dbus-shared.h
-libpulsecore_@PA_MAJORMINORMICRO@_la_CFLAGS += $(DBUS_CFLAGS)
-libpulsecore_@PA_MAJORMINORMICRO@_la_LIBADD += $(DBUS_LIBS)
+libpulsecore_@PA_MAJORMINOR@_la_SOURCES += \
+ pulsecore/dbus-shared.c pulsecore/dbus-shared.h \
+ pulsecore/protocol-dbus.c pulsecore/protocol-dbus.h
+libpulsecore_@PA_MAJORMINOR@_la_CFLAGS += $(DBUS_CFLAGS)
+libpulsecore_@PA_MAJORMINOR@_la_LIBADD += $(DBUS_LIBS)
endif
if HAVE_GDBM
-libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES += pulsecore/database-gdbm.c
-libpulsecore_@PA_MAJORMINORMICRO@_la_CFLAGS += $(GDBM_CFLAGS)
-libpulsecore_@PA_MAJORMINORMICRO@_la_LIBADD += $(GDBM_LIBS)
+libpulsecore_@PA_MAJORMINOR@_la_SOURCES += pulsecore/database-gdbm.c
+libpulsecore_@PA_MAJORMINOR@_la_CFLAGS += $(GDBM_CFLAGS)
+libpulsecore_@PA_MAJORMINOR@_la_LIBADD += $(GDBM_LIBS)
endif
if HAVE_TDB
-libpulsecore_@PA_MAJORMINORMICRO@_la_SOURCES += pulsecore/database-tdb.c
-libpulsecore_@PA_MAJORMINORMICRO@_la_CFLAGS += $(TDB_CFLAGS)
-libpulsecore_@PA_MAJORMINORMICRO@_la_LIBADD += $(TDB_LIBS)
+libpulsecore_@PA_MAJORMINOR@_la_SOURCES += pulsecore/database-tdb.c
+libpulsecore_@PA_MAJORMINOR@_la_CFLAGS += $(TDB_CFLAGS)
+libpulsecore_@PA_MAJORMINOR@_la_LIBADD += $(TDB_LIBS)
endif
+if HAVE_SIMPLEDB
+libpulsecore_@PA_MAJORMINOR@_la_SOURCES += pulsecore/database-simple.c
+endif
# We split the foreign code off to not be annoyed by warnings we don't care about
noinst_LTLIBRARIES = libpulsecore-foreign.la
@@ -882,28 +898,33 @@ modlibexec_LTLIBRARIES += \
endif
libprotocol_simple_la_SOURCES = pulsecore/protocol-simple.c pulsecore/protocol-simple.h
-libprotocol_simple_la_LDFLAGS = -avoid-version
-libprotocol_simple_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libprotocol_simple_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libprotocol_simple_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
libcli_la_SOURCES = pulsecore/cli.c pulsecore/cli.h
-libcli_la_LDFLAGS = -avoid-version
-libcli_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libcli_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libcli_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
libprotocol_cli_la_SOURCES = pulsecore/protocol-cli.c pulsecore/protocol-cli.h
-libprotocol_cli_la_LDFLAGS = -avoid-version
-libprotocol_cli_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la libcli.la
+libprotocol_cli_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libprotocol_cli_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la libcli.la
libprotocol_http_la_SOURCES = pulsecore/protocol-http.c pulsecore/protocol-http.h pulsecore/mime-type.c pulsecore/mime-type.h
-libprotocol_http_la_LDFLAGS = -avoid-version
-libprotocol_http_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libprotocol_http_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libprotocol_http_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
libprotocol_native_la_SOURCES = pulsecore/protocol-native.c pulsecore/protocol-native.h pulsecore/native-common.h
-libprotocol_native_la_LDFLAGS = -avoid-version
-libprotocol_native_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libprotocol_native_la_CFLAGS = $(AM_CFLAGS)
+libprotocol_native_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libprotocol_native_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
+if HAVE_DBUS
+libprotocol_native_la_CFLAGS += $(DBUS_CFLAGS)
+libprotocol_native_la_LIBADD += $(DBUS_LIBS)
+endif
libprotocol_esound_la_SOURCES = pulsecore/protocol-esound.c pulsecore/protocol-esound.h pulsecore/esound.h
-libprotocol_esound_la_LDFLAGS = -avoid-version
-libprotocol_esound_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libprotocol_esound_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libprotocol_esound_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
librtp_la_SOURCES = \
modules/rtp/rtp.c modules/rtp/rtp.h \
@@ -911,21 +932,21 @@ librtp_la_SOURCES = \
modules/rtp/sap.c modules/rtp/sap.h \
modules/rtp/rtsp_client.c modules/rtp/rtsp_client.h \
modules/rtp/headerlist.c modules/rtp/headerlist.h
-librtp_la_LDFLAGS = -avoid-version
-librtp_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+librtp_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+librtp_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
libraop_la_SOURCES = \
modules/raop/raop_client.c modules/raop/raop_client.h \
modules/raop/base64.c modules/raop/base64.h
-libraop_la_CFLAGS = $(AM_CFLAGS) $(OPENSSL_CFLAGS)
-libraop_la_LDFLAGS = -avoid-version
-libraop_la_LIBADD = $(AM_LIBADD) $(OPENSSL_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la librtp.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libraop_la_CFLAGS = $(AM_CFLAGS) $(OPENSSL_CFLAGS) -I$(top_srcdir)/src/modules/rtp
+libraop_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
+libraop_la_LIBADD = $(AM_LIBADD) $(OPENSSL_LIBS) libpulsecore-@PA_MAJORMINOR@.la librtp.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
# Avahi
libavahi_wrap_la_SOURCES = pulsecore/avahi-wrap.c pulsecore/avahi-wrap.h
-libavahi_wrap_la_LDFLAGS = -avoid-version
+libavahi_wrap_la_LDFLAGS = $(AM_LDFLAGS) -avoid-version
libavahi_wrap_la_CFLAGS = $(AM_CFLAGS) $(AVAHI_CFLAGS)
-libavahi_wrap_la_LIBADD = $(AM_LIBADD) $(AVAHI_CFLAGS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libavahi_wrap_la_LIBADD = $(AM_LIBADD) $(AVAHI_CFLAGS) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
###################################
# Plug-in libraries #
@@ -942,22 +963,27 @@ modlibexec_LTLIBRARIES += \
module-cli-protocol-tcp.la \
module-simple-protocol-tcp.la \
module-null-sink.la \
+ module-null-source.la \
module-sine-source.la \
module-detect.la \
module-volume-restore.la \
+ module-device-manager.la \
module-device-restore.la \
module-stream-restore.la \
module-card-restore.la \
module-default-device-restore.la \
module-always-sink.la \
module-rescue-streams.la \
+ module-intended-roles.la \
module-suspend-on-idle.la \
+ module-echo-cancel.la \
module-http-protocol-tcp.la \
module-sine.la \
module-native-protocol-tcp.la \
module-native-protocol-fd.la \
module-esound-protocol-tcp.la \
module-combine.la \
+ module-combine-sink.la \
module-remap-sink.la \
module-ladspa-sink.la \
module-esound-sink.la \
@@ -965,8 +991,13 @@ modlibexec_LTLIBRARIES += \
module-tunnel-source.la \
module-position-event-sounds.la \
module-augment-properties.la \
- module-cork-music-on-phone.la
-
+ module-cork-music-on-phone.la \
+ module-loopback.la \
+ module-virtual-sink.la \
+ module-virtual-source.la \
+ module-switch-on-connect.la \
+ module-filter-apply.la \
+ module-filter-heuristics.la
# See comment at librtp.la above
if !OS_IS_WIN32
@@ -1009,12 +1040,18 @@ modlibexec_LTLIBRARIES += \
module-x11-cork-request.la
endif
-if HAVE_OSS
+if HAVE_OSS_OUTPUT
modlibexec_LTLIBRARIES += \
liboss-util.la \
module-oss.la
endif
+if HAVE_COREAUDIO
+modlibexec_LTLIBRARIES += \
+ module-coreaudio-detect.la \
+ module-coreaudio-device.la
+endif
+
pulselibexec_PROGRAMS =
if HAVE_ALSA
@@ -1023,6 +1060,48 @@ modlibexec_LTLIBRARIES += \
module-alsa-sink.la \
module-alsa-source.la \
module-alsa-card.la
+
+dist_alsaprofilesets_DATA = \
+ modules/alsa/mixer/profile-sets/default.conf \
+ modules/alsa/mixer/profile-sets/maudio-fasttrack-pro.conf \
+ modules/alsa/mixer/profile-sets/native-instruments-audio4dj.conf \
+ modules/alsa/mixer/profile-sets/native-instruments-audio8dj.conf \
+ modules/alsa/mixer/profile-sets/native-instruments-traktor-audio6.conf \
+ modules/alsa/mixer/profile-sets/native-instruments-traktor-audio10.conf \
+ modules/alsa/mixer/profile-sets/native-instruments-traktorkontrol-s4.conf \
+ modules/alsa/mixer/profile-sets/native-instruments-korecontroller.conf \
+ modules/alsa/mixer/profile-sets/usb-headset.conf
+
+if HAVE_UDEV
+dist_udevrules_DATA = \
+ modules/alsa/mixer/profile-sets/90-pulseaudio.rules
+endif
+
+dist_alsapaths_DATA = \
+ modules/alsa/mixer/paths/analog-input-aux.conf \
+ modules/alsa/mixer/paths/analog-input.conf \
+ modules/alsa/mixer/paths/analog-input.conf.common \
+ modules/alsa/mixer/paths/analog-input-fm.conf \
+ modules/alsa/mixer/paths/analog-input-linein.conf \
+ modules/alsa/mixer/paths/analog-input-mic.conf \
+ modules/alsa/mixer/paths/analog-input-dock-mic.conf \
+ modules/alsa/mixer/paths/analog-input-front-mic.conf \
+ modules/alsa/mixer/paths/analog-input-internal-mic.conf \
+ modules/alsa/mixer/paths/analog-input-rear-mic.conf \
+ modules/alsa/mixer/paths/analog-input-mic.conf.common \
+ modules/alsa/mixer/paths/analog-input-mic-line.conf \
+ modules/alsa/mixer/paths/analog-input-tvtuner.conf \
+ modules/alsa/mixer/paths/analog-input-video.conf \
+ modules/alsa/mixer/paths/analog-output.conf \
+ modules/alsa/mixer/paths/analog-output-speaker.conf \
+ modules/alsa/mixer/paths/analog-output.conf.common \
+ modules/alsa/mixer/paths/analog-output-desktop-speaker.conf \
+ modules/alsa/mixer/paths/analog-output-headphones.conf \
+ modules/alsa/mixer/paths/analog-output-headphones-2.conf \
+ modules/alsa/mixer/paths/analog-output-lfe-on-mono.conf \
+ modules/alsa/mixer/paths/analog-output-mono.conf \
+ modules/alsa/mixer/paths/iec958-stereo-output.conf
+
endif
if HAVE_SOLARIS
@@ -1036,6 +1115,11 @@ modlibexec_LTLIBRARIES += \
module-zeroconf-discover.la
endif
+if HAVE_BONJOUR
+modlibexec_LTLIBRARIES += \
+ module-bonjour-publish.la
+endif
+
if HAVE_LIRC
modlibexec_LTLIBRARIES += \
module-lirc.la
@@ -1050,6 +1134,12 @@ if HAVE_JACK
modlibexec_LTLIBRARIES += \
module-jack-sink.la \
module-jack-source.la
+
+if HAVE_DBUS
+modlibexec_LTLIBRARIES += \
+ module-jackdbus-detect.la
+endif
+
endif
if HAVE_GCONF
@@ -1060,16 +1150,26 @@ pulselibexec_PROGRAMS += \
gconf-helper
endif
-#if OS_IS_WIN32
-#modlibexec_LTLIBRARIES += \
-# module-waveout.la
-#endif
+if HAVE_WAVEOUT
+modlibexec_LTLIBRARIES += \
+ module-waveout.la
+endif
if HAVE_HAL
modlibexec_LTLIBRARIES += \
module-hal-detect.la
endif
+if HAVE_HAL_COMPAT
+modlibexec_LTLIBRARIES += \
+ module-hal-detect.la
+endif
+
+if HAVE_UDEV
+modlibexec_LTLIBRARIES += \
+ module-udev-detect.la
+endif
+
if HAVE_DBUS
modlibexec_LTLIBRARIES += \
module-rygel-media-server.la \
@@ -1099,259 +1199,355 @@ modlibexec_LTLIBRARIES += \
endif
endif
+if HAVE_DBUS
+if HAVE_FFTW
+modlibexec_LTLIBRARIES += \
+ module-equalizer-sink.la
+bin_SCRIPTS += utils/qpaeq
+endif
+endif
+
# These are generated by an M4 script
SYMDEF_FILES = \
- modules/module-cli-symdef.h \
- modules/module-cli-protocol-tcp-symdef.h \
- modules/module-cli-protocol-unix-symdef.h \
- modules/module-pipe-sink-symdef.h \
- modules/module-pipe-source-symdef.h \
- modules/module-simple-protocol-tcp-symdef.h \
- modules/module-simple-protocol-unix-symdef.h \
- modules/module-esound-protocol-tcp-symdef.h \
- modules/module-esound-protocol-unix-symdef.h \
- modules/module-native-protocol-tcp-symdef.h \
- modules/module-native-protocol-unix-symdef.h \
- modules/module-native-protocol-fd-symdef.h \
- modules/module-sine-symdef.h \
- modules/module-combine-symdef.h \
- modules/module-remap-sink-symdef.h \
- modules/module-ladspa-sink-symdef.h \
- modules/module-esound-compat-spawnfd-symdef.h \
- modules/module-esound-compat-spawnpid-symdef.h \
- modules/module-match-symdef.h \
- modules/module-tunnel-sink-symdef.h \
- modules/module-tunnel-source-symdef.h \
- modules/module-null-sink-symdef.h \
- modules/module-sine-source-symdef.h \
- modules/module-esound-sink-symdef.h \
- modules/module-zeroconf-publish-symdef.h \
- modules/module-zeroconf-discover-symdef.h \
- modules/module-lirc-symdef.h \
- modules/module-mmkbd-evdev-symdef.h \
- modules/module-http-protocol-tcp-symdef.h \
- modules/module-http-protocol-unix-symdef.h \
- modules/module-rygel-media-server-symdef.h \
- modules/x11/module-x11-bell-symdef.h \
- modules/x11/module-x11-publish-symdef.h \
- modules/x11/module-x11-xsmp-symdef.h \
- modules/x11/module-x11-cork-request-symdef.h \
- modules/oss/module-oss-symdef.h \
- modules/alsa/module-alsa-sink-symdef.h \
- modules/alsa/module-alsa-source-symdef.h \
- modules/alsa/module-alsa-card-symdef.h \
- modules/module-solaris-symdef.h \
- modules/module-waveout-symdef.h \
- modules/module-detect-symdef.h \
- modules/rtp/module-rtp-send-symdef.h \
- modules/rtp/module-rtp-recv-symdef.h \
- modules/jack/module-jack-sink-symdef.h \
- modules/jack/module-jack-source-symdef.h \
- modules/module-volume-restore-symdef.h \
- modules/module-device-restore-symdef.h \
- modules/module-stream-restore-symdef.h \
- modules/module-card-restore-symdef.h \
- modules/module-default-device-restore-symdef.h \
- modules/module-always-sink-symdef.h \
- modules/module-rescue-streams-symdef.h \
- modules/module-suspend-on-idle-symdef.h \
- modules/module-hal-detect-symdef.h \
- modules/bluetooth/module-bluetooth-proximity-symdef.h \
- modules/bluetooth/module-bluetooth-discover-symdef.h \
- modules/bluetooth/module-bluetooth-device-symdef.h \
- modules/module-raop-sink-symdef.h \
- modules/module-raop-discover-symdef.h \
- modules/gconf/module-gconf-symdef.h \
- modules/module-position-event-sounds-symdef.h \
- modules/module-augment-properties-symdef.h \
- modules/module-cork-music-on-phone-symdef.h \
- modules/module-console-kit-symdef.h \
- modules/module-dbus-protocol-symdef.h
+ module-cli-symdef.h \
+ module-cli-protocol-tcp-symdef.h \
+ module-cli-protocol-unix-symdef.h \
+ module-pipe-sink-symdef.h \
+ module-pipe-source-symdef.h \
+ module-simple-protocol-tcp-symdef.h \
+ module-simple-protocol-unix-symdef.h \
+ module-esound-protocol-tcp-symdef.h \
+ module-esound-protocol-unix-symdef.h \
+ module-native-protocol-tcp-symdef.h \
+ module-native-protocol-unix-symdef.h \
+ module-native-protocol-fd-symdef.h \
+ module-sine-symdef.h \
+ module-combine-symdef.h \
+ module-combine-sink-symdef.h \
+ module-remap-sink-symdef.h \
+ module-ladspa-sink-symdef.h \
+ module-equalizer-sink-symdef.h \
+ module-esound-compat-spawnfd-symdef.h \
+ module-esound-compat-spawnpid-symdef.h \
+ module-match-symdef.h \
+ module-tunnel-sink-symdef.h \
+ module-tunnel-source-symdef.h \
+ module-null-sink-symdef.h \
+ module-null-source-symdef.h \
+ module-sine-source-symdef.h \
+ module-esound-sink-symdef.h \
+ module-zeroconf-publish-symdef.h \
+ module-zeroconf-discover-symdef.h \
+ module-bonjour-publish-symdef.h \
+ module-lirc-symdef.h \
+ module-mmkbd-evdev-symdef.h \
+ module-http-protocol-tcp-symdef.h \
+ module-http-protocol-unix-symdef.h \
+ module-rygel-media-server-symdef.h \
+ module-x11-bell-symdef.h \
+ module-x11-publish-symdef.h \
+ module-x11-xsmp-symdef.h \
+ module-x11-cork-request-symdef.h \
+ module-oss-symdef.h \
+ module-alsa-sink-symdef.h \
+ module-alsa-source-symdef.h \
+ module-alsa-card-symdef.h \
+ module-coreaudio-detect-symdef.h \
+ module-coreaudio-device-symdef.h \
+ module-solaris-symdef.h \
+ module-waveout-symdef.h \
+ module-detect-symdef.h \
+ module-rtp-send-symdef.h \
+ module-rtp-recv-symdef.h \
+ module-jackdbus-detect-symdef.h \
+ module-jack-sink-symdef.h \
+ module-jack-source-symdef.h \
+ module-volume-restore-symdef.h \
+ module-device-manager-symdef.h \
+ module-device-restore-symdef.h \
+ module-stream-restore-symdef.h \
+ module-card-restore-symdef.h \
+ module-default-device-restore-symdef.h \
+ module-always-sink-symdef.h \
+ module-rescue-streams-symdef.h \
+ module-intended-roles-symdef.h \
+ module-suspend-on-idle-symdef.h \
+ module-echo-cancel-symdef.h \
+ module-hal-detect-symdef.h \
+ module-udev-detect-symdef.h \
+ module-bluetooth-proximity-symdef.h \
+ module-bluetooth-discover-symdef.h \
+ module-bluetooth-device-symdef.h \
+ module-raop-sink-symdef.h \
+ module-raop-discover-symdef.h \
+ module-gconf-symdef.h \
+ module-position-event-sounds-symdef.h \
+ module-augment-properties-symdef.h \
+ module-cork-music-on-phone-symdef.h \
+ module-console-kit-symdef.h \
+ module-dbus-protocol-symdef.h \
+ module-loopback-symdef.h \
+ module-virtual-sink-symdef.h \
+ module-virtual-source-symdef.h \
+ module-switch-on-connect-symdef.h \
+ module-filter-apply-symdef.h \
+ module-filter-heuristics-symdef.h
EXTRA_DIST += $(SYMDEF_FILES)
-BUILT_SOURCES += $(SYMDEF_FILES)
+BUILT_SOURCES += $(SYMDEF_FILES) builddirs
$(SYMDEF_FILES): modules/module-defs.h.m4
- $(MKDIR_P) $(dir $@)
- $(M4) -Dfname="$@" $< > $@
+ $(AM_V_at)$(MKDIR_P) modules
+ $(AM_V_GEN)$(M4) -Dfname="$@" $< > $@
+
+.PHONY: builddirs
+builddirs:
+ $(AM_V_at)$(MKDIR_P) daemon modules
# Simple protocol
module_simple_protocol_tcp_la_SOURCES = modules/module-protocol-stub.c
module_simple_protocol_tcp_la_CFLAGS = -DUSE_TCP_SOCKETS -DUSE_PROTOCOL_SIMPLE $(AM_CFLAGS)
module_simple_protocol_tcp_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_simple_protocol_tcp_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-simple.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_simple_protocol_tcp_la_LIBADD = $(MODULE_LIBADD) libprotocol-simple.la
module_simple_protocol_unix_la_SOURCES = modules/module-protocol-stub.c
module_simple_protocol_unix_la_CFLAGS = -DUSE_UNIX_SOCKETS -DUSE_PROTOCOL_SIMPLE $(AM_CFLAGS)
module_simple_protocol_unix_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_simple_protocol_unix_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-simple.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_simple_protocol_unix_la_LIBADD = $(MODULE_LIBADD) libprotocol-simple.la
# CLI protocol
module_cli_la_SOURCES = modules/module-cli.c
module_cli_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_cli_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libcli.la
+module_cli_la_LIBADD = $(MODULE_LIBADD) libcli.la
module_cli_protocol_tcp_la_SOURCES = modules/module-protocol-stub.c
module_cli_protocol_tcp_la_CFLAGS = -DUSE_TCP_SOCKETS -DUSE_PROTOCOL_CLI $(AM_CFLAGS)
module_cli_protocol_tcp_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_cli_protocol_tcp_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-cli.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_cli_protocol_tcp_la_LIBADD = $(MODULE_LIBADD) libprotocol-cli.la
module_cli_protocol_unix_la_SOURCES = modules/module-protocol-stub.c
module_cli_protocol_unix_la_CFLAGS = -DUSE_UNIX_SOCKETS -DUSE_PROTOCOL_CLI $(AM_CFLAGS)
module_cli_protocol_unix_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_cli_protocol_unix_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-cli.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_cli_protocol_unix_la_LIBADD = $(MODULE_LIBADD) libprotocol-cli.la
# HTTP protocol
module_http_protocol_tcp_la_SOURCES = modules/module-protocol-stub.c
module_http_protocol_tcp_la_CFLAGS = -DUSE_TCP_SOCKETS -DUSE_PROTOCOL_HTTP $(AM_CFLAGS)
module_http_protocol_tcp_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_http_protocol_tcp_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-http.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_http_protocol_tcp_la_LIBADD = $(MODULE_LIBADD) libprotocol-http.la
module_http_protocol_unix_la_SOURCES = modules/module-protocol-stub.c
module_http_protocol_unix_la_CFLAGS = -DUSE_UNIX_SOCKETS -DUSE_PROTOCOL_HTTP $(AM_CFLAGS)
module_http_protocol_unix_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_http_protocol_unix_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-http.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_http_protocol_unix_la_LIBADD = $(MODULE_LIBADD) libprotocol-http.la
# D-Bus protocol
-module_dbus_protocol_la_SOURCES = modules/module-dbus-protocol.c
+module_dbus_protocol_la_SOURCES = \
+ modules/dbus/iface-card.c modules/dbus/iface-card.h \
+ modules/dbus/iface-card-profile.c modules/dbus/iface-card-profile.h \
+ modules/dbus/iface-client.c modules/dbus/iface-client.h \
+ modules/dbus/iface-core.c modules/dbus/iface-core.h \
+ modules/dbus/iface-device.c modules/dbus/iface-device.h \
+ modules/dbus/iface-device-port.c modules/dbus/iface-device-port.h \
+ modules/dbus/iface-memstats.c modules/dbus/iface-memstats.h \
+ modules/dbus/iface-module.c modules/dbus/iface-module.h \
+ modules/dbus/iface-sample.c modules/dbus/iface-sample.h \
+ modules/dbus/iface-stream.c modules/dbus/iface-stream.h \
+ modules/dbus/module-dbus-protocol.c
module_dbus_protocol_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
module_dbus_protocol_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_dbus_protocol_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_dbus_protocol_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS)
# Native protocol
module_native_protocol_tcp_la_SOURCES = modules/module-protocol-stub.c
module_native_protocol_tcp_la_CFLAGS = -DUSE_TCP_SOCKETS -DUSE_PROTOCOL_NATIVE $(AM_CFLAGS)
module_native_protocol_tcp_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_native_protocol_tcp_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-native.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_native_protocol_tcp_la_LIBADD = $(MODULE_LIBADD) libprotocol-native.la
module_native_protocol_unix_la_SOURCES = modules/module-protocol-stub.c
module_native_protocol_unix_la_CFLAGS = -DUSE_UNIX_SOCKETS -DUSE_PROTOCOL_NATIVE $(AM_CFLAGS)
module_native_protocol_unix_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_native_protocol_unix_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-native.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_native_protocol_unix_la_LIBADD = $(MODULE_LIBADD) libprotocol-native.la
module_native_protocol_fd_la_SOURCES = modules/module-native-protocol-fd.c
module_native_protocol_fd_la_CFLAGS = $(AM_CFLAGS)
module_native_protocol_fd_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_native_protocol_fd_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-native.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_native_protocol_fd_la_LIBADD = $(MODULE_LIBADD) libprotocol-native.la
# EsounD protocol
module_esound_protocol_tcp_la_SOURCES = modules/module-protocol-stub.c
module_esound_protocol_tcp_la_CFLAGS = -DUSE_TCP_SOCKETS -DUSE_PROTOCOL_ESOUND $(AM_CFLAGS)
module_esound_protocol_tcp_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_esound_protocol_tcp_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-esound.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_esound_protocol_tcp_la_LIBADD = $(MODULE_LIBADD) libprotocol-esound.la
module_esound_protocol_unix_la_SOURCES = modules/module-protocol-stub.c
module_esound_protocol_unix_la_CFLAGS = -DUSE_UNIX_SOCKETS -DUSE_PROTOCOL_ESOUND $(AM_CFLAGS)
module_esound_protocol_unix_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_esound_protocol_unix_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libprotocol-esound.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_esound_protocol_unix_la_LIBADD = $(MODULE_LIBADD) libprotocol-esound.la
module_esound_compat_spawnfd_la_SOURCES = modules/module-esound-compat-spawnfd.c
module_esound_compat_spawnfd_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_esound_compat_spawnfd_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_esound_compat_spawnfd_la_LIBADD = $(MODULE_LIBADD)
module_esound_compat_spawnpid_la_SOURCES = modules/module-esound-compat-spawnpid.c
module_esound_compat_spawnpid_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_esound_compat_spawnpid_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_esound_compat_spawnpid_la_LIBADD = $(MODULE_LIBADD)
module_esound_sink_la_SOURCES = modules/module-esound-sink.c
-module_esound_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_esound_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_esound_sink_la_LDFLAGS = $(MODULE_LDFLAGS) $(WINSOCK_LIBS)
+module_esound_sink_la_LIBADD = $(MODULE_LIBADD)
# Pipes
module_pipe_sink_la_SOURCES = modules/module-pipe-sink.c
module_pipe_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_pipe_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_pipe_sink_la_LIBADD = $(MODULE_LIBADD)
module_pipe_source_la_SOURCES = modules/module-pipe-source.c
module_pipe_source_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_pipe_source_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_pipe_source_la_LIBADD = $(MODULE_LIBADD)
# Fake sources/sinks
module_sine_la_SOURCES = modules/module-sine.c
module_sine_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_sine_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_sine_la_LIBADD = $(MODULE_LIBADD)
module_null_sink_la_SOURCES = modules/module-null-sink.c
module_null_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_null_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_null_sink_la_LIBADD = $(MODULE_LIBADD)
+
+module_null_source_la_SOURCES = modules/module-null-source.c
+module_null_source_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_null_source_la_LIBADD = $(MODULE_LIBADD)
module_sine_source_la_SOURCES = modules/module-sine-source.c
-module_sine_source_la_LDFLAGS = -module -avoid-version
-module_sine_source_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_sine_source_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_sine_source_la_LIBADD = $(MODULE_LIBADD)
# Couplings
module_combine_la_SOURCES = modules/module-combine.c
module_combine_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_combine_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_combine_la_LIBADD = $(MODULE_LIBADD)
+
+module_combine_sink_la_SOURCES = modules/module-combine-sink.c
+module_combine_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_combine_sink_la_LIBADD = $(MODULE_LIBADD)
+
+module_switch_on_connect_la_SOURCES = modules/module-switch-on-connect.c
+module_switch_on_connect_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_switch_on_connect_la_LIBADD = $(MODULE_LIBADD)
+
+module_filter_apply_la_SOURCES = modules/module-filter-apply.c
+module_filter_apply_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_filter_apply_la_LIBADD = $(MODULE_LIBADD)
+
+module_filter_heuristics_la_SOURCES = modules/module-filter-heuristics.c
+module_filter_heuristics_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_filter_heuristics_la_LIBADD = $(MODULE_LIBADD)
module_remap_sink_la_SOURCES = modules/module-remap-sink.c
module_remap_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_remap_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_remap_sink_la_LIBADD = $(MODULE_LIBADD)
module_ladspa_sink_la_SOURCES = modules/module-ladspa-sink.c modules/ladspa.h
module_ladspa_sink_la_CFLAGS = -DLADSPA_PATH=\"$(libdir)/ladspa:/usr/local/lib/ladspa:/usr/lib/ladspa:/usr/local/lib64/ladspa:/usr/lib64/ladspa\" $(AM_CFLAGS)
module_ladspa_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_ladspa_sink_la_LIBADD = $(AM_LIBADD) $(LIBLTDL) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_ladspa_sink_la_LIBADD = $(MODULE_LIBADD) $(LIBLTDL)
+
+module_equalizer_sink_la_SOURCES = modules/module-equalizer-sink.c
+module_equalizer_sink_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) $(FFTW_CFLAGS)
+module_equalizer_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_equalizer_sink_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS) $(FFTW_LIBS)
module_match_la_SOURCES = modules/module-match.c
module_match_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_match_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_match_la_LIBADD = $(MODULE_LIBADD)
module_tunnel_sink_la_SOURCES = modules/module-tunnel.c
module_tunnel_sink_la_CFLAGS = -DTUNNEL_SINK=1 $(AM_CFLAGS)
module_tunnel_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_tunnel_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_tunnel_sink_la_LIBADD = $(MODULE_LIBADD)
module_tunnel_source_la_SOURCES = modules/module-tunnel.c
module_tunnel_source_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_tunnel_source_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_tunnel_source_la_LIBADD = $(MODULE_LIBADD)
+
+module_loopback_la_SOURCES = modules/module-loopback.c
+module_loopback_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_loopback_la_LIBADD = $(MODULE_LIBADD)
+
+module_virtual_sink_la_SOURCES = modules/module-virtual-sink.c
+module_virtual_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_virtual_sink_la_LIBADD = $(MODULE_LIBADD)
+
+module_virtual_source_la_SOURCES = modules/module-virtual-source.c
+module_virtual_source_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_virtual_source_la_LIBADD = $(MODULE_LIBADD)
# X11
module_x11_bell_la_SOURCES = modules/x11/module-x11-bell.c
module_x11_bell_la_CFLAGS = $(AM_CFLAGS) $(X11_CFLAGS)
module_x11_bell_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_x11_bell_la_LIBADD = $(AM_LIBADD) $(X11_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_x11_bell_la_LIBADD = $(MODULE_LIBADD) $(X11_LIBS)
module_x11_publish_la_SOURCES = modules/x11/module-x11-publish.c
module_x11_publish_la_CFLAGS = $(AM_CFLAGS) $(X11_CFLAGS)
module_x11_publish_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_x11_publish_la_LIBADD = $(AM_LIBADD) $(X11_LIBS) libprotocol-native.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_x11_publish_la_LIBADD = $(MODULE_LIBADD) libprotocol-native.la $(X11_LIBS)
module_x11_xsmp_la_SOURCES = modules/x11/module-x11-xsmp.c
module_x11_xsmp_la_CFLAGS = $(AM_CFLAGS) $(X11_CFLAGS)
module_x11_xsmp_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_x11_xsmp_la_LIBADD = $(AM_LIBADD) $(X11_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_x11_xsmp_la_LIBADD = $(MODULE_LIBADD) $(X11_LIBS)
module_x11_cork_request_la_SOURCES = modules/x11/module-x11-cork-request.c
module_x11_cork_request_la_CFLAGS = $(AM_CFLAGS) $(X11_CFLAGS)
module_x11_cork_request_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_x11_cork_request_la_LIBADD = $(AM_LIBADD) $(X11_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_x11_cork_request_la_LIBADD = $(MODULE_LIBADD) $(X11_LIBS)
# OSS
liboss_util_la_SOURCES = modules/oss/oss-util.c modules/oss/oss-util.h
liboss_util_la_LDFLAGS = -avoid-version
-liboss_util_la_LIBADD = libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+liboss_util_la_LIBADD = $(MODULE_LIBADD)
module_oss_la_SOURCES = modules/oss/module-oss.c
module_oss_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_oss_la_LIBADD = $(AM_LIBADD) liboss-util.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_oss_la_LIBADD = $(MODULE_LIBADD) liboss-util.la
+
+# COREAUDIO
+
+module_coreaudio_detect_la_SOURCES = modules/macosx/module-coreaudio-detect.c
+module_coreaudio_detect_la_LDFLAGS = $(MODULE_LDFLAGS) \
+ -Wl,-framework -Wl,Cocoa -framework CoreAudio \
+ -Wl,-framework -Wl,AudioUnit -framework AudioUnit
+module_coreaudio_detect_la_LIBADD = $(MODULE_LIBADD)
+
+module_coreaudio_device_la_SOURCES = modules/macosx/module-coreaudio-device.c
+module_coreaudio_device_la_LDFLAGS = $(MODULE_LDFLAGS) \
+ -Wl,-framework -Wl,Cocoa -framework CoreAudio \
+ -Wl,-framework -Wl,AudioUnit -framework AudioUnit
+module_coreaudio_device_la_LIBADD = $(MODULE_LIBADD)
# ALSA
-libalsa_util_la_SOURCES = modules/alsa/alsa-util.c modules/alsa/alsa-util.h modules/alsa/alsa-sink.c modules/alsa/alsa-sink.h modules/alsa/alsa-source.c modules/alsa/alsa-source.h modules/reserve-wrap.c modules/reserve-wrap.h
+libalsa_util_la_SOURCES = \
+ modules/alsa/alsa-util.c modules/alsa/alsa-util.h \
+ modules/alsa/alsa-mixer.c modules/alsa/alsa-mixer.h \
+ modules/alsa/alsa-sink.c modules/alsa/alsa-sink.h \
+ modules/alsa/alsa-source.c modules/alsa/alsa-source.h \
+ modules/reserve-wrap.c modules/reserve-wrap.h
libalsa_util_la_LDFLAGS = -avoid-version
-libalsa_util_la_LIBADD = $(AM_LIBADD) $(ASOUNDLIB_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libalsa_util_la_LIBADD = $(MODULE_LIBADD) $(ASOUNDLIB_LIBS)
libalsa_util_la_CFLAGS = $(AM_CFLAGS) $(ASOUNDLIB_CFLAGS)
if HAVE_HAL
@@ -1367,186 +1563,248 @@ libalsa_util_la_CFLAGS += $(UDEV_CFLAGS)
endif
if HAVE_DBUS
-libalsa_util_la_SOURCES += modules/reserve.h modules/reserve.c
+libalsa_util_la_SOURCES += modules/reserve.h modules/reserve.c modules/reserve-monitor.h modules/reserve-monitor.c
libalsa_util_la_LIBADD += $(DBUS_LIBS)
libalsa_util_la_CFLAGS += $(DBUS_CFLAGS)
endif
module_alsa_sink_la_SOURCES = modules/alsa/module-alsa-sink.c
module_alsa_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_alsa_sink_la_LIBADD = $(AM_LIBADD) $(ASOUNDLIB_LIBS) libalsa-util.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_alsa_sink_la_LIBADD = $(MODULE_LIBADD) $(ASOUNDLIB_LIBS) libalsa-util.la
module_alsa_sink_la_CFLAGS = $(AM_CFLAGS) $(ASOUNDLIB_CFLAGS)
module_alsa_source_la_SOURCES = modules/alsa/module-alsa-source.c
module_alsa_source_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_alsa_source_la_LIBADD = $(AM_LIBADD) $(ASOUNDLIB_LIBS) libalsa-util.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_alsa_source_la_LIBADD = $(MODULE_LIBADD) $(ASOUNDLIB_LIBS) libalsa-util.la
module_alsa_source_la_CFLAGS = $(AM_CFLAGS) $(ASOUNDLIB_CFLAGS)
module_alsa_card_la_SOURCES = modules/alsa/module-alsa-card.c
module_alsa_card_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_alsa_card_la_LIBADD = $(AM_LIBADD) $(ASOUNDLIB_LIBS) libalsa-util.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_alsa_card_la_LIBADD = $(MODULE_LIBADD) $(ASOUNDLIB_LIBS) libalsa-util.la
module_alsa_card_la_CFLAGS = $(AM_CFLAGS) $(ASOUNDLIB_CFLAGS)
# Solaris
module_solaris_la_SOURCES = modules/module-solaris.c
module_solaris_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_solaris_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_solaris_la_LIBADD = $(MODULE_LIBADD)
# Avahi
module_zeroconf_publish_la_SOURCES = modules/module-zeroconf-publish.c
module_zeroconf_publish_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_zeroconf_publish_la_LIBADD = $(AM_LIBADD) $(AVAHI_LIBS) libavahi-wrap.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_zeroconf_publish_la_LIBADD = $(MODULE_LIBADD) $(AVAHI_LIBS) libavahi-wrap.la libprotocol-native.la
module_zeroconf_publish_la_CFLAGS = $(AM_CFLAGS) $(AVAHI_CFLAGS)
module_zeroconf_discover_la_SOURCES = modules/module-zeroconf-discover.c
module_zeroconf_discover_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_zeroconf_discover_la_LIBADD = $(AM_LIBADD) $(AVAHI_LIBS) libavahi-wrap.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_zeroconf_discover_la_LIBADD = $(MODULE_LIBADD) $(AVAHI_LIBS) libavahi-wrap.la
module_zeroconf_discover_la_CFLAGS = $(AM_CFLAGS) $(AVAHI_CFLAGS)
+# Bonjour
+
+module_bonjour_publish_la_SOURCES = modules/macosx/module-bonjour-publish.c
+module_bonjour_publish_la_LDFLAGS = $(MODULE_LDFLAGS) \
+ -Wl,-framework -Wl,CoreFoundation -framework CoreFoundation
+module_bonjour_publish_la_LIBADD = $(MODULE_LIBADD)
+
# LIRC
module_lirc_la_SOURCES = modules/module-lirc.c
module_lirc_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_lirc_la_LIBADD = $(AM_LIBADD) $(LIRC_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_lirc_la_LIBADD = $(MODULE_LIBADD) $(LIRC_LIBS)
module_lirc_la_CFLAGS = $(AM_CFLAGS) $(LIRC_CFLAGS)
# Linux evdev
module_mmkbd_evdev_la_SOURCES = modules/module-mmkbd-evdev.c
module_mmkbd_evdev_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_mmkbd_evdev_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_mmkbd_evdev_la_LIBADD = $(MODULE_LIBADD)
module_mmkbd_evdev_la_CFLAGS = $(AM_CFLAGS)
# Windows waveout
-
-#module_waveout_la_SOURCES = modules/module-waveout.c
-#module_waveout_la_LDFLAGS = $(MODULE_LDFLAGS)
-#module_waveout_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la -lwinmm libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
-#module_waveout_la_CFLAGS = $(AM_CFLAGS)
+module_waveout_la_SOURCES = modules/module-waveout.c
+module_waveout_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_waveout_la_LIBADD = $(MODULE_LIBADD) -lwinmm
+module_waveout_la_CFLAGS = $(AM_CFLAGS)
# Hardware autodetection module
module_detect_la_SOURCES = modules/module-detect.c
module_detect_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_detect_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_detect_la_LIBADD = $(MODULE_LIBADD)
module_detect_la_CFLAGS = $(AM_CFLAGS)
# Volume restore module
module_volume_restore_la_SOURCES = modules/module-volume-restore.c
module_volume_restore_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_volume_restore_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_volume_restore_la_LIBADD = $(MODULE_LIBADD)
module_volume_restore_la_CFLAGS = $(AM_CFLAGS)
# Position event sounds in space
module_position_event_sounds_la_SOURCES = modules/module-position-event-sounds.c
module_position_event_sounds_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_position_event_sounds_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_position_event_sounds_la_LIBADD = $(MODULE_LIBADD)
module_position_event_sounds_la_CFLAGS = $(AM_CFLAGS)
# Augment properties from XDG .desktop files
module_augment_properties_la_SOURCES = modules/module-augment-properties.c
module_augment_properties_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_augment_properties_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_augment_properties_la_LIBADD = $(MODULE_LIBADD)
#module_augment_properties_la_CFLAGS = $(AM_CFLAGS) -DDESKTOPFILEDIR=\"$(datadir)/applications\"
module_augment_properties_la_CFLAGS = $(AM_CFLAGS) -DDESKTOPFILEDIR=\"/usr/share/applications\"
# Cork music streams while a phone stream is active
module_cork_music_on_phone_la_SOURCES = modules/module-cork-music-on-phone.c
module_cork_music_on_phone_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_cork_music_on_phone_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_cork_music_on_phone_la_LIBADD = $(MODULE_LIBADD)
module_cork_music_on_phone_la_CFLAGS = $(AM_CFLAGS)
+# Device description restore module
+module_device_manager_la_SOURCES = modules/module-device-manager.c
+module_device_manager_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_device_manager_la_LIBADD = $(MODULE_LIBADD) libprotocol-native.la
+module_device_manager_la_CFLAGS = $(AM_CFLAGS)
+
# Device volume/muted restore module
module_device_restore_la_SOURCES = modules/module-device-restore.c
module_device_restore_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_device_restore_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_device_restore_la_LIBADD = $(MODULE_LIBADD) libprotocol-native.la
module_device_restore_la_CFLAGS = $(AM_CFLAGS)
+if HAVE_DBUS
+module_device_restore_la_LIBADD += $(DBUS_LIBS)
+module_device_restore_la_CFLAGS += $(DBUS_CFLAGS)
+endif
+
# Stream volume/muted/device restore module
module_stream_restore_la_SOURCES = modules/module-stream-restore.c
module_stream_restore_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_stream_restore_la_LIBADD = $(AM_LIBADD) libprotocol-native.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_stream_restore_la_LIBADD = $(MODULE_LIBADD) libprotocol-native.la
module_stream_restore_la_CFLAGS = $(AM_CFLAGS)
+if HAVE_DBUS
+module_stream_restore_la_LIBADD += $(DBUS_LIBS)
+module_stream_restore_la_CFLAGS += $(DBUS_CFLAGS)
+endif
+
# Card profile restore module
module_card_restore_la_SOURCES = modules/module-card-restore.c
module_card_restore_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_card_restore_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_card_restore_la_LIBADD = $(MODULE_LIBADD)
module_card_restore_la_CFLAGS = $(AM_CFLAGS)
# Default sink/source restore module
module_default_device_restore_la_SOURCES = modules/module-default-device-restore.c
module_default_device_restore_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_default_device_restore_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_default_device_restore_la_LIBADD = $(MODULE_LIBADD)
module_default_device_restore_la_CFLAGS = $(AM_CFLAGS)
# Always Sink module
module_always_sink_la_SOURCES = modules/module-always-sink.c
module_always_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_always_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_always_sink_la_LIBADD = $(MODULE_LIBADD)
module_always_sink_la_CFLAGS = $(AM_CFLAGS)
# Rescue streams module
module_rescue_streams_la_SOURCES = modules/module-rescue-streams.c
module_rescue_streams_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_rescue_streams_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_rescue_streams_la_LIBADD = $(MODULE_LIBADD)
module_rescue_streams_la_CFLAGS = $(AM_CFLAGS)
+# Automatically move streams to devices that are intended for their roles
+module_intended_roles_la_SOURCES = modules/module-intended-roles.c
+module_intended_roles_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_intended_roles_la_LIBADD = $(MODULE_LIBADD)
+module_intended_roles_la_CFLAGS = $(AM_CFLAGS)
+
# Suspend-on-idle module
module_suspend_on_idle_la_SOURCES = modules/module-suspend-on-idle.c
module_suspend_on_idle_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_suspend_on_idle_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_suspend_on_idle_la_LIBADD = $(MODULE_LIBADD)
module_suspend_on_idle_la_CFLAGS = $(AM_CFLAGS)
+# echo-cancel module
+module_echo_cancel_la_SOURCES = \
+ modules/echo-cancel/module-echo-cancel.c modules/echo-cancel/echo-cancel.h \
+ modules/echo-cancel/speex.c \
+ modules/echo-cancel/adrian-aec.c modules/echo-cancel/adrian-aec.h \
+ modules/echo-cancel/adrian.c modules/echo-cancel/adrian.h
+module_echo_cancel_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_echo_cancel_la_LIBADD = $(MODULE_LIBADD) $(LIBSPEEX_LIBS)
+module_echo_cancel_la_CFLAGS = $(AM_CFLAGS) $(LIBSPEEX_CFLAGS)
+if HAVE_ORC
+ORC_SOURCE += modules/echo-cancel/adrian-aec
+nodist_module_echo_cancel_la_SOURCES = \
+ modules/echo-cancel/adrian-aec-orc-gen.c \
+ modules/echo-cancel/adrian-aec-orc-gen.h
+module_echo_cancel_la_LIBADD += $(ORC_LIBS)
+module_echo_cancel_la_CFLAGS += $(ORC_CFLAGS) -I$(top_builddir)/src/modules/echo-cancel
+endif
+
# RTP modules
module_rtp_send_la_SOURCES = modules/rtp/module-rtp-send.c
module_rtp_send_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_rtp_send_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la librtp.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_rtp_send_la_LIBADD = $(MODULE_LIBADD) librtp.la
module_rtp_send_la_CFLAGS = $(AM_CFLAGS)
module_rtp_recv_la_SOURCES = modules/rtp/module-rtp-recv.c
module_rtp_recv_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_rtp_recv_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la librtp.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_rtp_recv_la_LIBADD = $(MODULE_LIBADD) librtp.la
module_rtp_recv_la_CFLAGS = $(AM_CFLAGS)
# JACK
+module_jackdbus_detect_la_SOURCES = modules/jack/module-jackdbus-detect.c
+module_jackdbus_detect_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_jackdbus_detect_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS) $(JACK_LIBS)
+module_jackdbus_detect_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) $(JACK_CFLAGS)
+
module_jack_sink_la_SOURCES = modules/jack/module-jack-sink.c
module_jack_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_jack_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la $(JACK_LIBS) libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_jack_sink_la_LIBADD = $(MODULE_LIBADD) $(JACK_LIBS)
module_jack_sink_la_CFLAGS = $(AM_CFLAGS) $(JACK_CFLAGS)
module_jack_source_la_SOURCES = modules/jack/module-jack-source.c
module_jack_source_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_jack_source_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la $(JACK_LIBS) libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_jack_source_la_LIBADD = $(MODULE_LIBADD) $(JACK_LIBS)
module_jack_source_la_CFLAGS = $(AM_CFLAGS) $(JACK_CFLAGS)
+if HAVE_HAL_COMPAT
+module_hal_detect_la_SOURCES = modules/module-hal-detect-compat.c
+module_hal_detect_la_LIBADD = $(MODULE_LIBADD)
+module_hal_detect_la_CFLAGS = $(AM_CFLAGS)
+else
module_hal_detect_la_SOURCES = modules/module-hal-detect.c
-module_hal_detect_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_hal_detect_la_LIBADD = $(AM_LIBADD) $(HAL_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_hal_detect_la_LIBADD = $(MODULE_LIBADD) $(HAL_LIBS)
module_hal_detect_la_CFLAGS = $(AM_CFLAGS) $(HAL_CFLAGS)
+endif
+module_hal_detect_la_LDFLAGS = $(MODULE_LDFLAGS)
+
+module_udev_detect_la_SOURCES = modules/module-udev-detect.c
+module_udev_detect_la_LDFLAGS = $(MODULE_LDFLAGS)
+module_udev_detect_la_LIBADD = $(MODULE_LIBADD) $(UDEV_LIBS)
+module_udev_detect_la_CFLAGS = $(AM_CFLAGS) $(UDEV_CFLAGS)
module_console_kit_la_SOURCES = modules/module-console-kit.c
module_console_kit_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_console_kit_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_console_kit_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS)
module_console_kit_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
# GConf support
module_gconf_la_SOURCES = modules/gconf/module-gconf.c
module_gconf_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_gconf_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_gconf_la_LIBADD = $(MODULE_LIBADD)
module_gconf_la_CFLAGS = $(AM_CFLAGS) -DPA_GCONF_HELPER=\"$(pulselibexecdir)/gconf-helper\"
gconf_helper_SOURCES = modules/gconf/gconf-helper.c
-gconf_helper_LDADD = $(AM_LDADD) $(GCONF_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+gconf_helper_LDADD = $(AM_LDADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la $(GCONF_LIBS)
gconf_helper_CFLAGS = $(AM_CFLAGS) $(GCONF_CFLAGS)
gconf_helper_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
# Bluetooth proximity
module_bluetooth_proximity_la_SOURCES = modules/bluetooth/module-bluetooth-proximity.c
module_bluetooth_proximity_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_bluetooth_proximity_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_bluetooth_proximity_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS)
module_bluetooth_proximity_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) -DPA_BT_PROXIMITY_HELPER=\"$(pulselibexecdir)/proximity-helper\"
proximity_helper_SOURCES = modules/bluetooth/proximity-helper.c
@@ -1557,107 +1815,87 @@ proximity_helper_LDFLAGS = $(AM_LDFLAGS) $(BINLDFLAGS)
# Bluetooth sink / source
module_bluetooth_discover_la_SOURCES = modules/bluetooth/module-bluetooth-discover.c
module_bluetooth_discover_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_bluetooth_discover_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libbluetooth-util.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_bluetooth_discover_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS) libbluetooth-util.la
module_bluetooth_discover_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
-libbluetooth_sbc_la_SOURCES = modules/bluetooth/sbc.c modules/bluetooth/sbc.h modules/bluetooth/sbc_tables.h modules/bluetooth/sbc_math.h modules/bluetooth/sbc_primitives.h modules/bluetooth/sbc_primitives.c modules/bluetooth/sbc_primitives_mmx.h modules/bluetooth/sbc_primitives_neon.h modules/bluetooth/sbc_primitives_mmx.c modules/bluetooth/sbc_primitives_neon.c
+libbluetooth_sbc_la_SOURCES = \
+ modules/bluetooth/sbc/sbc.c modules/bluetooth/sbc/sbc.h \
+ modules/bluetooth/sbc/sbc_primitives.c modules/bluetooth/sbc/sbc_primitives.h \
+ modules/bluetooth/sbc/sbc_primitives_armv6.h modules/bluetooth/sbc/sbc_primitives_armv6.c \
+ modules/bluetooth/sbc/sbc_primitives_iwmmxt.h modules/bluetooth/sbc/sbc_primitives_iwmmxt.c \
+ modules/bluetooth/sbc/sbc_primitives_mmx.c modules/bluetooth/sbc/sbc_primitives_mmx.h \
+ modules/bluetooth/sbc/sbc_primitives_neon.c modules/bluetooth/sbc/sbc_primitives_neon.h \
+ modules/bluetooth/sbc/sbc_math.h \
+ modules/bluetooth/sbc/sbc_tables.h
libbluetooth_sbc_la_LDFLAGS = -avoid-version
-libbluetooth_sbc_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
-libbluetooth_sbc_la_CFLAGS = $(AM_CFLAGS)
+libbluetooth_sbc_la_LIBADD = $(MODULE_LIBADD)
+libbluetooth_sbc_la_CFLAGS = $(AM_CFLAGS) -I$(top_srcdir)/src/modules/bluetooth/sbc
BLUETOOTH_SBC_FILES = $(subst modules/bluetooth/,,$(libbluetooth_sbc_la_SOURCES))
-libbluetooth_ipc_la_SOURCES = modules/bluetooth/ipc.c modules/bluetooth/ipc.h
+libbluetooth_ipc_la_SOURCES = \
+ modules/bluetooth/a2dp-codecs.h \
+ modules/bluetooth/ipc.c modules/bluetooth/ipc.h
libbluetooth_ipc_la_LDFLAGS = -avoid-version
-libbluetooth_ipc_la_LIBADD = $(AM_LIBADD)libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libbluetooth_ipc_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
libbluetooth_ipc_la_CFLAGS = $(AM_CFLAGS)
BLUETOOTH_IPC_FILES = $(subst modules/bluetooth/,,$(libbluetooth_ipc_la_SOURCES)) rtp.h
libbluetooth_util_la_SOURCES = modules/bluetooth/bluetooth-util.c modules/bluetooth/bluetooth-util.h
libbluetooth_util_la_LDFLAGS = -avoid-version
-libbluetooth_util_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+libbluetooth_util_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS)
libbluetooth_util_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
module_bluetooth_device_la_SOURCES = modules/bluetooth/module-bluetooth-device.c modules/bluetooth/rtp.h
module_bluetooth_device_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_bluetooth_device_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libbluetooth-util.la libbluetooth-ipc.la libbluetooth-sbc.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
-module_bluetooth_device_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
+module_bluetooth_device_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS) libbluetooth-util.la libbluetooth-ipc.la libbluetooth-sbc.la
+module_bluetooth_device_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) -I$(top_srcdir)/src/modules/bluetooth/sbc
# Apple Airtunes/RAOP
-module_raop_sink_la_SOURCES = modules/module-raop-sink.c
+module_raop_sink_la_SOURCES = modules/raop/module-raop-sink.c
module_raop_sink_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_raop_sink_la_LIBADD = $(AM_LIBADD) libpulsecore-@PA_MAJORMINORMICRO@.la librtp.la libraop.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_raop_sink_la_LIBADD = $(MODULE_LIBADD) librtp.la libraop.la
+module_raop_sink_la_CFLAGS = $(AM_CFLAGS) -I$(top_srcdir)/src/modules/rtp
-module_raop_discover_la_SOURCES = modules/module-raop-discover.c
+module_raop_discover_la_SOURCES = modules/raop/module-raop-discover.c
module_raop_discover_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_raop_discover_la_LIBADD = $(AM_LIBADD) $(AVAHI_LIBS) libavahi-wrap.la libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la
+module_raop_discover_la_LIBADD = $(MODULE_LIBADD) $(AVAHI_LIBS) libavahi-wrap.la
module_raop_discover_la_CFLAGS = $(AM_CFLAGS) $(AVAHI_CFLAGS)
# Rygel
module_rygel_media_server_la_SOURCES = modules/module-rygel-media-server.c
module_rygel_media_server_la_LDFLAGS = $(MODULE_LDFLAGS)
-module_rygel_media_server_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la libprotocol-http.la
+module_rygel_media_server_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS) libprotocol-http.la
module_rygel_media_server_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
###################################
# Some minor stuff #
###################################
-suid: pulseaudio .libs/lt-pulseaudio
- chown root $^
- chmod u+s $^
-
-CLEANFILES = esdcompat client.conf default.pa system.pa daemon.conf start-pulseaudio-x11 daemon/pulseaudio.desktop daemon/org.pulseaudio.policy
-
-esdcompat: daemon/esdcompat.in Makefile
- sed -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' \
- -e 's,@PACKAGE_NAME\@,$(PACKAGE_NAME),g' \
- -e 's,@PA_BINARY\@,$(PA_BINARY),g' < $< > $@
- chmod +x esdcompat
-
-start-pulseaudio-x11: daemon/start-pulseaudio-x11.in Makefile
- sed -e 's,@PA_BINARY\@,$(PA_BINARY),g' \
- -e 's,@PACTL_BINARY\@,$(bindir)/pactl,g' < $< > $@
- chmod +x start-pulseaudio-x11
-
-client.conf: pulse/client.conf.in Makefile
- sed -e 's,@PA_BINARY\@,$(PA_BINARY),g' < $< > $@
+CLEANFILES += daemon/pulseaudio.desktop daemon/pulseaudio-kde.desktop
+DISTCLEANFILES = esdcompat client.conf default.pa system.pa daemon.conf start-pulseaudio-x11 start-pulseaudio-kde
if OS_IS_WIN32
-default.pa: daemon/default.pa.win32
- cp $< $@
-system.pa: daemon/default.pa.win32
- cp $< $@
+SYMLINK_PROGRAM=cd $(DESTDIR)$(bindir) && cp
else
-default.pa: daemon/default.pa.in Makefile
- sed -e 's,@PA_BINARY\@,$(PA_BINARY),g' \
- -e 's,@PA_DLSEARCHPATH\@,$(modlibexecdir),g' \
- -e 's,@PA_SOEXT\@,.so,g' < $< > $@
-system.pa: daemon/system.pa.in Makefile
- sed -e 's,@PA_BINARY\@,$(PA_BINARY),g' \
- -e 's,@PA_DLSEARCHPATH\@,$(modlibexecdir),g' \
- -e 's,@PA_SOEXT\@,.so,g' < $< > $@
+SYMLINK_PROGRAM=ln -sf
endif
-
-daemon.conf: daemon/daemon.conf.in Makefile
- sed -e 's,@PA_DLSEARCHPATH\@,$(modlibexecdir),g' \
- -e 's,@PA_DEFAULT_CONFIG_FILE\@,$(DEFAULT_CONFIG_DIR),g' < $< > $@
-
install-exec-hook:
- chown root $(DESTDIR)$(bindir)/pulseaudio ; true
- chmod u+s $(DESTDIR)$(bindir)/pulseaudio
+if HAVE_BLUEZ
+ -chown root $(DESTDIR)$(pulselibexecdir)/proximity-helper
-chmod u+s $(DESTDIR)$(pulselibexecdir)/proximity-helper
- ln -sf pacat $(DESTDIR)$(bindir)/parec
- ln -sf pacat $(DESTDIR)$(bindir)/pamon
- ln -sf pacat $(DESTDIR)$(bindir)/paplay
- ln -sf pacat $(DESTDIR)$(bindir)/parecord
+endif
+ $(SYMLINK_PROGRAM) pacat$(EXEEXT) $(DESTDIR)$(bindir)/parec$(EXEEXT)
+ $(SYMLINK_PROGRAM) pacat$(EXEEXT) $(DESTDIR)$(bindir)/pamon$(EXEEXT)
+ $(SYMLINK_PROGRAM) pacat$(EXEEXT) $(DESTDIR)$(bindir)/paplay$(EXEEXT)
+ $(SYMLINK_PROGRAM) pacat$(EXEEXT) $(DESTDIR)$(bindir)/parecord$(EXEEXT)
rm -f $(DESTDIR)$(libdir)/libpulsedsp.la
rm -f $(DESTDIR)$(modlibexecdir)/*.la
uninstall-hook:
- rm -f $(DESTDIR)$(bindir)/parec
- rm -f $(DESTDIR)$(bindir)/pamon
- rm -f $(DESTDIR)$(bindir)/paplay
- rm -f $(DESTDIR)$(bindir)/parecord
+ rm -f $(DESTDIR)$(bindir)/parec$(EXEEXT)
+ rm -f $(DESTDIR)$(bindir)/pamon$(EXEEXT)
+ rm -f $(DESTDIR)$(bindir)/paplay$(EXEEXT)
+ rm -f $(DESTDIR)$(bindir)/parecord$(EXEEXT)
rm -f $(DESTDIR)$(libdir)/libpulsedsp.*
rm -f $(DESTDIR)$(modlibexecdir)/*.so
@@ -1670,17 +1908,22 @@ update-ffmpeg:
# We get things twice here, because sometimes gitweb will us just give a "Generating..." otherwise.
update-sbc:
for i in $(BLUETOOTH_SBC_FILES) ; do \
- wget -O /dev/null http://git.kernel.org/\?p=bluetooth/bluez.git\;a=blob_plain\;f=sbc/$$i ; \
- wget -O modules/bluetooth/$$i http://git.kernel.org/\?p=bluetooth/bluez.git\;a=blob_plain\;f=sbc/$$i ; \
+ wget -O /dev/null http://git.kernel.org/\?p=bluetooth/bluez.git\;a=blob_plain\;f=$$i ; \
+ wget -O $(top_srcdir)/src/modules/bluetooth/$$i http://git.kernel.org/\?p=bluetooth/bluez.git\;a=blob_plain\;f=$$i ; \
done
for i in $(BLUETOOTH_IPC_FILES); do \
wget -O /dev/null http://git.kernel.org/\?p=bluetooth/bluez.git\;a=blob_plain\;f=audio/$$i ; \
- wget -O modules/bluetooth/$$i http://git.kernel.org/\?p=bluetooth/bluez.git\;a=blob_plain\;f=audio/$$i ; \
+ wget -O $(top_srcdir)/src/modules/bluetooth/$$i http://git.kernel.org/\?p=bluetooth/bluez.git\;a=blob_plain\;f=audio/$$i ; \
done
update-reserve:
- for i in reserve.c reserve.h ; do \
- wget -O modules/$$i http://git.0pointer.de/\?p=reserve.git\;a=blob_plain\;f=$$i\;hb=master ; \
+ for i in reserve.c reserve.h reserve-monitor.c reserve-monitor.h ; do \
+ wget -O $(top_srcdir)/src/modules/$$i http://git.0pointer.de/\?p=reserve.git\;a=blob_plain\;f=$$i\;hb=master ; \
+ done
+
+update-rtkit:
+ for i in rtkit.c rtkit.h ; do \
+ wget -O $(top_srcdir)/src/pulsecore/$$i http://git.0pointer.de/\?p=rtkit.git\;a=blob_plain\;f=$$i\;hb=master ; \
done
# Automatically generate linker version script. We use the same one for all public .sos
diff --git a/src/daemon/.gitignore b/src/daemon/.gitignore
index 0efa55ba..54e4299b 100644
--- a/src/daemon/.gitignore
+++ b/src/daemon/.gitignore
@@ -1,2 +1,3 @@
org.pulseaudio.policy
pulseaudio.desktop
+pulseaudio-kde.desktop
diff --git a/src/daemon/Makefile b/src/daemon/Makefile
deleted file mode 120000
index c110232d..00000000
--- a/src/daemon/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../pulse/Makefile \ No newline at end of file
diff --git a/src/daemon/caps.c b/src/daemon/caps.c
index d2ae8d0e..74ccb1c8 100644
--- a/src/daemon/caps.c
+++ b/src/daemon/caps.c
@@ -26,19 +26,17 @@
#include <unistd.h>
#include <errno.h>
-#include <string.h>
#include <sys/types.h>
#include <pulse/i18n.h>
#include <pulsecore/macro.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
#ifdef HAVE_SYS_CAPABILITY_H
#include <sys/capability.h>
#endif
+
#ifdef HAVE_SYS_PRCTL_H
#include <sys/prctl.h>
#endif
@@ -51,112 +49,47 @@ int setresgid(gid_t r, gid_t e, gid_t s);
int setresuid(uid_t r, uid_t e, uid_t s);
#endif
-#ifdef HAVE_GETUID
-
/* Drop root rights when called SUID root */
void pa_drop_root(void) {
- uid_t uid = getuid();
- if (uid == 0 || geteuid() != 0)
- return;
+#ifdef HAVE_GETUID
+ uid_t uid;
+ gid_t gid;
- pa_log_info(_("Dropping root privileges."));
+ pa_log_debug(_("Cleaning up privileges."));
+ uid = getuid();
+ gid = getgid();
#if defined(HAVE_SETRESUID)
pa_assert_se(setresuid(uid, uid, uid) >= 0);
+ pa_assert_se(setresgid(gid, gid, gid) >= 0);
#elif defined(HAVE_SETREUID)
pa_assert_se(setreuid(uid, uid) >= 0);
+ pa_assert_se(setregid(gid, gid) >= 0);
#else
pa_assert_se(setuid(uid) >= 0);
pa_assert_se(seteuid(uid) >= 0);
+ pa_assert_se(setgid(gid) >= 0);
+ pa_assert_se(setegid(gid) >= 0);
#endif
pa_assert_se(getuid() == uid);
pa_assert_se(geteuid() == uid);
-}
-
-#else
-
-void pa_drop_root(void) {
-}
-
-#endif
-
-#if defined(HAVE_SYS_CAPABILITY_H) && defined(HAVE_SYS_PRCTL_H)
-
-/* Limit permitted capabilities set to CAPSYS_NICE */
-void pa_limit_caps(void) {
- cap_t caps;
- cap_value_t nice_cap = CAP_SYS_NICE;
-
- pa_assert_se(caps = cap_init());
- pa_assert_se(cap_clear(caps) == 0);
- pa_assert_se(cap_set_flag(caps, CAP_EFFECTIVE, 1, &nice_cap, CAP_SET) == 0);
- pa_assert_se(cap_set_flag(caps, CAP_PERMITTED, 1, &nice_cap, CAP_SET) == 0);
-
- if (cap_set_proc(caps) < 0)
- /* Hmm, so we couldn't limit our caps, which probably means we
- * hadn't any in the first place, so let's just make sure of
- * that */
- pa_drop_caps();
- else
- pa_log_info(_("Limited capabilities successfully to CAP_SYS_NICE."));
-
- pa_assert_se(cap_free(caps) == 0);
-
- pa_assert_se(prctl(PR_SET_KEEPCAPS, 1, 0, 0, 0) == 0);
-}
-
-/* Drop all capabilities, effectively becoming a normal user */
-void pa_drop_caps(void) {
- cap_t caps;
-
-#ifndef __OPTIMIZE__
- /* Valgrind doesn't not know set_caps, so we bypass it here -- but
- * only in development builds.*/
-
- if (pa_in_valgrind() && !pa_have_caps())
- return;
+ pa_assert_se(getgid() == gid);
+ pa_assert_se(getegid() == gid);
#endif
+#ifdef HAVE_SYS_PRCTL_H
pa_assert_se(prctl(PR_SET_KEEPCAPS, 0, 0, 0, 0) == 0);
-
- pa_assert_se(caps = cap_init());
- pa_assert_se(cap_clear(caps) == 0);
- pa_assert_se(cap_set_proc(caps) == 0);
- pa_assert_se(cap_free(caps) == 0);
-
- pa_assert_se(!pa_have_caps());
-}
-
-pa_bool_t pa_have_caps(void) {
- cap_t caps;
- cap_flag_value_t flag = CAP_CLEAR;
-
-#ifdef __OPTIMIZE__
- pa_assert_se(caps = cap_get_proc());
-#else
- if (!(caps = cap_get_proc()))
- return FALSE;
#endif
- pa_assert_se(cap_get_flag(caps, CAP_SYS_NICE, CAP_EFFECTIVE, &flag) >= 0);
- pa_assert_se(cap_free(caps) == 0);
-
- return flag == CAP_SET;
-}
-
-#else
-
-/* NOOPs in case capabilities are not available. */
-void pa_limit_caps(void) {
-}
-
-void pa_drop_caps(void) {
- pa_drop_root();
-}
-
-pa_bool_t pa_have_caps(void) {
- return FALSE;
-}
+#ifdef HAVE_SYS_CAPABILITY_H
+ if (uid != 0) {
+ cap_t caps;
+ pa_assert_se(caps = cap_init());
+ pa_assert_se(cap_clear(caps) == 0);
+ pa_assert_se(cap_set_proc(caps) == 0);
+ pa_assert_se(cap_free(caps) == 0);
+ }
#endif
+}
diff --git a/src/daemon/caps.h b/src/daemon/caps.h
index 94241a9a..5d0ee62e 100644
--- a/src/daemon/caps.h
+++ b/src/daemon/caps.h
@@ -25,8 +25,5 @@
#include <pulsecore/macro.h>
void pa_drop_root(void);
-void pa_drop_caps(void);
-void pa_limit_caps(void);
-pa_bool_t pa_have_caps(void);
#endif
diff --git a/src/daemon/cmdline.c b/src/daemon/cmdline.c
index d78089e1..ec37d46b 100644
--- a/src/daemon/cmdline.c
+++ b/src/daemon/cmdline.c
@@ -23,14 +23,13 @@
#include <config.h>
#endif
-#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <getopt.h>
-#include <sys/stat.h>
#include <pulse/xmalloc.h>
#include <pulse/i18n.h>
+#include <pulse/util.h>
#include <pulsecore/core-util.h>
#include <pulsecore/strbuf.h>
@@ -109,15 +108,8 @@ static const struct option long_options[] = {
};
void pa_cmdline_help(const char *argv0) {
- const char *e;
-
pa_assert(argv0);
- if ((e = strrchr(argv0, '/')))
- e++;
- else
- e = argv0;
-
printf(_("%s [options]\n\n"
"COMMANDS:\n"
" -h, --help Show this help\n"
@@ -151,7 +143,8 @@ void pa_cmdline_help(const char *argv0) {
" this time passed\n"
" --log-level[=LEVEL] Increase or set verbosity level\n"
" -v Increase the verbosity level\n"
- " --log-target={auto,syslog,stderr} Specify the log target\n"
+ " --log-target={auto,syslog,stderr,file:PATH}\n"
+ " Specify the log target\n"
" --log-meta[=BOOL] Include code location in log messages\n"
" --log-time[=BOOL] Include timestamps in log messages\n"
" --log-backtrace=FRAMES Include a backtrace in log messages\n"
@@ -172,7 +165,8 @@ void pa_cmdline_help(const char *argv0) {
" -C Open a command line on the running TTY\n"
" after startup\n\n"
- " -n Don't load default script file\n"), e);
+ " -n Don't load default script file\n"),
+ pa_path_get_filename(argv0));
}
int pa_cmdline_parse(pa_daemon_conf *conf, int argc, char *const argv [], int *d) {
@@ -323,7 +317,7 @@ int pa_cmdline_parse(pa_daemon_conf *conf, int argc, char *const argv [], int *d
case ARG_LOG_TARGET:
if (pa_daemon_conf_set_log_target(conf, optarg) < 0) {
- pa_log(_("Invalid log target: use either 'syslog', 'stderr' or 'auto'."));
+ pa_log(_("Invalid log target: use either 'syslog', 'stderr' or 'auto' or a valid file name 'file:<path>'."));
goto fail;
}
break;
@@ -390,11 +384,6 @@ int pa_cmdline_parse(pa_daemon_conf *conf, int argc, char *const argv [], int *d
pa_xfree(conf->script_commands);
conf->script_commands = pa_strbuf_tostring_free(buf);
- if (!conf->script_commands) {
- pa_xfree(conf->script_commands);
- conf->script_commands = NULL;
- }
-
*d = optind;
return 0;
diff --git a/src/daemon/cpulimit.c b/src/daemon/cpulimit.c
index 45d6a0fb..3a972975 100644
--- a/src/daemon/cpulimit.c
+++ b/src/daemon/cpulimit.c
@@ -23,14 +23,13 @@
#include <config.h>
#endif
-#include <pulse/error.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulsecore/core-util.h>
#include <pulsecore/core-error.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
-#include <pulsecore/rtclock.h>
#include "cpulimit.h"
@@ -39,7 +38,6 @@
#include <errno.h>
#include <stdio.h>
#include <string.h>
-#include <sys/time.h>
#include <unistd.h>
#include <signal.h>
@@ -85,7 +83,7 @@ static struct sigaction sigaction_prev;
static pa_bool_t installed = FALSE;
/* The current state of operation */
-static enum {
+static enum {
PHASE_IDLE, /* Normal state */
PHASE_SOFT /* After CPU overload has been detected */
} phase = PHASE_IDLE;
@@ -125,7 +123,7 @@ static void signal_handler(int sig) {
char t[256];
#endif
- now = pa_rtclock_usec();
+ now = pa_rtclock_now();
elapsed = now - last_time;
#ifdef PRINT_CPU_LOAD
@@ -139,7 +137,7 @@ static void signal_handler(int sig) {
write_err("Soft CPU time limit exhausted, terminating.\n");
/* Try a soft cleanup */
- (void) write(the_pipe[1], &c, sizeof(c));
+ (void) pa_write(the_pipe[1], &c, sizeof(c), NULL);
phase = PHASE_SOFT;
reset_cpu_time(CPUTIME_INTERVAL_HARD);
@@ -184,18 +182,16 @@ int pa_cpu_limit_init(pa_mainloop_api *m) {
pa_assert(the_pipe[1] == -1);
pa_assert(!installed);
- last_time = pa_rtclock_usec();
+ last_time = pa_rtclock_now();
/* Prepare the main loop pipe */
- if (pipe(the_pipe) < 0) {
+ if (pa_pipe_cloexec(the_pipe) < 0) {
pa_log("pipe() failed: %s", pa_cstrerror(errno));
return -1;
}
pa_make_fd_nonblock(the_pipe[0]);
pa_make_fd_nonblock(the_pipe[1]);
- pa_make_fd_cloexec(the_pipe[0]);
- pa_make_fd_cloexec(the_pipe[1]);
api = m;
io_event = api->io_new(m, the_pipe[0], PA_IO_EVENT_INPUT, callback, NULL);
diff --git a/src/daemon/daemon-conf.c b/src/daemon/daemon-conf.c
index ac6cc8aa..bb929091 100644
--- a/src/daemon/daemon-conf.c
+++ b/src/daemon/daemon-conf.c
@@ -28,11 +28,17 @@
#include <stdio.h>
#include <string.h>
#include <unistd.h>
+#include <fcntl.h>
+#include <sys/stat.h>
+
+#ifdef HAVE_SCHED_H
#include <sched.h>
+#endif
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
#include <pulse/i18n.h>
+#include <pulse/version.h>
#include <pulsecore/core-error.h>
#include <pulsecore/core-util.h>
@@ -60,7 +66,7 @@ static const pa_daemon_conf default_conf = {
.fail = TRUE,
.high_priority = TRUE,
.nice_level = -11,
- .realtime_scheduling = FALSE,
+ .realtime_scheduling = TRUE,
.realtime_priority = 5, /* Half of JACK's default rtprio */
.disallow_module_loading = FALSE,
.disallow_exit = FALSE,
@@ -83,10 +89,17 @@ static const pa_daemon_conf default_conf = {
.config_file = NULL,
.use_pid_file = TRUE,
.system_instance = FALSE,
- .no_cpu_limit = FALSE,
+#ifdef HAVE_DBUS
+ .local_server_type = PA_SERVER_TYPE_UNSET, /* The actual default is _USER, but we have to detect when the user doesn't specify this option. */
+#endif
+ .no_cpu_limit = TRUE,
.disable_shm = FALSE,
+ .lock_memory = FALSE,
+ .sync_volume = TRUE,
.default_n_fragments = 4,
.default_fragment_size_msec = 25,
+ .sync_volume_safety_margin_usec = 8000,
+ .sync_volume_extra_delay_usec = 0,
.default_sample_spec = { .format = PA_SAMPLE_S16NE, .rate = 44100, .channels = 2 },
.default_channel_map = { .channels = 2, .map = { PA_CHANNEL_POSITION_LEFT, PA_CHANNEL_POSITION_RIGHT } },
.shm_size = 0
@@ -131,15 +144,30 @@ static const pa_daemon_conf default_conf = {
#endif
};
-pa_daemon_conf* pa_daemon_conf_new(void) {
- pa_daemon_conf *c = pa_xnewdup(pa_daemon_conf, &default_conf, 1);
+pa_daemon_conf *pa_daemon_conf_new(void) {
+ pa_daemon_conf *c;
+
+ c = pa_xnewdup(pa_daemon_conf, &default_conf, 1);
+
+#ifdef OS_IS_WIN32
+ c->dl_search_path = pa_sprintf_malloc("%s" PA_PATH_SEP "lib" PA_PATH_SEP "pulse-%d.%d" PA_PATH_SEP "modules",
+ pa_win32_get_toplevel(NULL), PA_MAJOR, PA_MINOR);
+#else
+ if (pa_run_from_build_tree()) {
+ pa_log_notice("Detected that we are run from the build tree, fixing search path.");
+ c->dl_search_path = pa_xstrdup(PA_BUILDDIR "/.libs/");
+ } else
+ c->dl_search_path = pa_xstrdup(PA_DLSEARCHPATH);
+#endif
- c->dl_search_path = pa_xstrdup(PA_DLSEARCHPATH);
return c;
}
void pa_daemon_conf_free(pa_daemon_conf *c) {
pa_assert(c);
+
+ pa_log_set_fd(-1);
+
pa_xfree(c->script_commands);
pa_xfree(c->dl_search_path);
pa_xfree(c->default_script_file);
@@ -159,6 +187,21 @@ int pa_daemon_conf_set_log_target(pa_daemon_conf *c, const char *string) {
} else if (!strcmp(string, "stderr")) {
c->auto_log_target = 0;
c->log_target = PA_LOG_STDERR;
+ } else if (pa_startswith(string, "file:")) {
+ char file_path[512];
+ int log_fd;
+
+ pa_strlcpy(file_path, string + 5, sizeof(file_path));
+
+ /* Open target file with user rights */
+ if ((log_fd = open(file_path, O_RDWR|O_TRUNC|O_CREAT, S_IRWXU)) >= 0) {
+ c->auto_log_target = 0;
+ c->log_target = PA_LOG_FD;
+ pa_log_set_fd(log_fd);
+ } else {
+ printf("Failed to open target file %s, error : %s\n", file_path, pa_cstrerror(errno));
+ return -1;
+ }
} else
return -1;
@@ -203,6 +246,22 @@ int pa_daemon_conf_set_resample_method(pa_daemon_conf *c, const char *string) {
return 0;
}
+int pa_daemon_conf_set_local_server_type(pa_daemon_conf *c, const char *string) {
+ pa_assert(c);
+ pa_assert(string);
+
+ if (!strcmp(string, "user"))
+ c->local_server_type = PA_SERVER_TYPE_USER;
+ else if (!strcmp(string, "system")) {
+ c->local_server_type = PA_SERVER_TYPE_SYSTEM;
+ } else if (!strcmp(string, "none")) {
+ c->local_server_type = PA_SERVER_TYPE_NONE;
+ } else
+ return -1;
+
+ return 0;
+}
+
static int parse_log_target(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
pa_daemon_conf *c = data;
@@ -251,8 +310,8 @@ static int parse_resample_method(const char *filename, unsigned line, const char
return 0;
}
-static int parse_rlimit(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
#ifdef HAVE_SYS_RESOURCE_H
+static int parse_rlimit(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
struct pa_rlimit *r = data;
pa_assert(filename);
@@ -273,12 +332,10 @@ static int parse_rlimit(const char *filename, unsigned line, const char *section
r->is_set = k >= 0;
r->value = k >= 0 ? (rlim_t) k : 0;
}
-#else
- pa_log_warn(_("[%s:%u] rlimit not supported on this platform."), filename, line);
-#endif
return 0;
}
+#endif
static int parse_sample_format(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
pa_daemon_conf *c = data;
@@ -413,6 +470,10 @@ static int parse_nice_level(const char *filename, unsigned line, const char *sec
}
static int parse_rtprio(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
+#ifdef OS_IS_WIN32
+ pa_log("[%s:%u] Realtime priority not available on win32.", filename, line);
+#else
+# ifdef HAVE_SCHED_H
pa_daemon_conf *c = data;
int32_t rtprio;
@@ -427,9 +488,30 @@ static int parse_rtprio(const char *filename, unsigned line, const char *section
}
c->realtime_priority = (int) rtprio;
+# endif
+#endif /* OS_IS_WIN32 */
+
return 0;
}
+#ifdef HAVE_DBUS
+static int parse_server_type(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
+ pa_daemon_conf *c = data;
+
+ pa_assert(filename);
+ pa_assert(lvalue);
+ pa_assert(rvalue);
+ pa_assert(data);
+
+ if (pa_daemon_conf_set_local_server_type(c, rvalue) < 0) {
+ pa_log(_("[%s:%u] Invalid server type '%s'."), filename, line, rvalue);
+ return -1;
+ }
+
+ return 0;
+}
+#endif
+
int pa_daemon_conf_load(pa_daemon_conf *c, const char *filename) {
int r = -1;
FILE *f = NULL;
@@ -440,12 +522,21 @@ int pa_daemon_conf_load(pa_daemon_conf *c, const char *filename) {
{ "high-priority", pa_config_parse_bool, &c->high_priority, NULL },
{ "realtime-scheduling", pa_config_parse_bool, &c->realtime_scheduling, NULL },
{ "disallow-module-loading", pa_config_parse_bool, &c->disallow_module_loading, NULL },
+ { "allow-module-loading", pa_config_parse_not_bool, &c->disallow_module_loading, NULL },
{ "disallow-exit", pa_config_parse_bool, &c->disallow_exit, NULL },
+ { "allow-exit", pa_config_parse_not_bool, &c->disallow_exit, NULL },
{ "use-pid-file", pa_config_parse_bool, &c->use_pid_file, NULL },
{ "system-instance", pa_config_parse_bool, &c->system_instance, NULL },
+#ifdef HAVE_DBUS
+ { "local-server-type", parse_server_type, c, NULL },
+#endif
{ "no-cpu-limit", pa_config_parse_bool, &c->no_cpu_limit, NULL },
+ { "cpu-limit", pa_config_parse_not_bool, &c->no_cpu_limit, NULL },
{ "disable-shm", pa_config_parse_bool, &c->disable_shm, NULL },
+ { "enable-shm", pa_config_parse_not_bool, &c->disable_shm, NULL },
{ "flat-volumes", pa_config_parse_bool, &c->flat_volumes, NULL },
+ { "lock-memory", pa_config_parse_bool, &c->lock_memory, NULL },
+ { "enable-sync-volume", pa_config_parse_bool, &c->sync_volume, NULL },
{ "exit-idle-time", pa_config_parse_int, &c->exit_idle_time, NULL },
{ "scache-idle-time", pa_config_parse_int, &c->scache_idle_time, NULL },
{ "realtime-priority", parse_rtprio, c, NULL },
@@ -461,9 +552,13 @@ int pa_daemon_conf_load(pa_daemon_conf *c, const char *filename) {
{ "default-channel-map", parse_channel_map, &ci, NULL },
{ "default-fragments", parse_fragments, c, NULL },
{ "default-fragment-size-msec", parse_fragment_size_msec, c, NULL },
+ { "sync-volume-safety-margin-usec", pa_config_parse_unsigned, &c->sync_volume_safety_margin_usec, NULL },
+ { "sync-volume-extra-delay-usec", pa_config_parse_int, &c->sync_volume_extra_delay_usec, NULL },
{ "nice-level", parse_nice_level, c, NULL },
{ "disable-remixing", pa_config_parse_bool, &c->disable_remixing, NULL },
+ { "enable-remixing", pa_config_parse_not_bool, &c->disable_remixing, NULL },
{ "disable-lfe-remixing", pa_config_parse_bool, &c->disable_lfe_remixing, NULL },
+ { "enable-lfe-remixing", pa_config_parse_not_bool, &c->disable_lfe_remixing, NULL },
{ "load-default-script-file", pa_config_parse_bool, &c->load_default_script_file, NULL },
{ "shm-size-bytes", pa_config_parse_size, &c->shm_size, NULL },
{ "log-meta", pa_config_parse_bool, &c->log_meta, NULL },
@@ -515,7 +610,7 @@ int pa_daemon_conf_load(pa_daemon_conf *c, const char *filename) {
c->config_file = NULL;
f = filename ?
- fopen(c->config_file = pa_xstrdup(filename), "r") :
+ pa_fopen_cloexec(c->config_file = pa_xstrdup(filename), "r") :
pa_open_config_file(DEFAULT_CONFIG_FILE, DEFAULT_CONFIG_FILE_USER, ENV_CONFIG_FILE, &c->config_file);
if (!f && errno != ENOENT) {
@@ -590,21 +685,29 @@ FILE *pa_daemon_conf_open_default_script_file(pa_daemon_conf *c) {
else
f = pa_open_config_file(DEFAULT_SCRIPT_FILE, DEFAULT_SCRIPT_FILE_USER, ENV_SCRIPT_FILE, &c->default_script_file);
} else
- f = fopen(c->default_script_file, "r");
+ f = pa_fopen_cloexec(c->default_script_file, "r");
return f;
}
+char *pa_daemon_conf_dump(pa_daemon_conf *c) {
+ static const char* const log_level_to_string[] = {
+ [PA_LOG_DEBUG] = "debug",
+ [PA_LOG_INFO] = "info",
+ [PA_LOG_NOTICE] = "notice",
+ [PA_LOG_WARN] = "warning",
+ [PA_LOG_ERROR] = "error"
+ };
-static const char* const log_level_to_string[] = {
- [PA_LOG_DEBUG] = "debug",
- [PA_LOG_INFO] = "info",
- [PA_LOG_NOTICE] = "notice",
- [PA_LOG_WARN] = "warning",
- [PA_LOG_ERROR] = "error"
-};
+#ifdef HAVE_DBUS
+ static const char* const server_type_to_string[] = {
+ [PA_SERVER_TYPE_UNSET] = "!!UNSET!!",
+ [PA_SERVER_TYPE_USER] = "user",
+ [PA_SERVER_TYPE_SYSTEM] = "system",
+ [PA_SERVER_TYPE_NONE] = "none"
+ };
+#endif
-char *pa_daemon_conf_dump(pa_daemon_conf *c) {
pa_strbuf *s;
char cm[PA_CHANNEL_MAP_SNPRINT_MAX];
@@ -623,13 +726,18 @@ char *pa_daemon_conf_dump(pa_daemon_conf *c) {
pa_strbuf_printf(s, "nice-level = %i\n", c->nice_level);
pa_strbuf_printf(s, "realtime-scheduling = %s\n", pa_yes_no(c->realtime_scheduling));
pa_strbuf_printf(s, "realtime-priority = %i\n", c->realtime_priority);
- pa_strbuf_printf(s, "disallow-module-loading = %s\n", pa_yes_no(c->disallow_module_loading));
- pa_strbuf_printf(s, "disallow-exit = %s\n", pa_yes_no(c->disallow_exit));
+ pa_strbuf_printf(s, "allow-module-loading = %s\n", pa_yes_no(!c->disallow_module_loading));
+ pa_strbuf_printf(s, "allow-exit = %s\n", pa_yes_no(!c->disallow_exit));
pa_strbuf_printf(s, "use-pid-file = %s\n", pa_yes_no(c->use_pid_file));
pa_strbuf_printf(s, "system-instance = %s\n", pa_yes_no(c->system_instance));
- pa_strbuf_printf(s, "no-cpu-limit = %s\n", pa_yes_no(c->no_cpu_limit));
- pa_strbuf_printf(s, "disable-shm = %s\n", pa_yes_no(c->disable_shm));
+#ifdef HAVE_DBUS
+ pa_strbuf_printf(s, "local-server-type = %s\n", server_type_to_string[c->local_server_type]);
+#endif
+ pa_strbuf_printf(s, "cpu-limit = %s\n", pa_yes_no(!c->no_cpu_limit));
+ pa_strbuf_printf(s, "enable-shm = %s\n", pa_yes_no(!c->disable_shm));
pa_strbuf_printf(s, "flat-volumes = %s\n", pa_yes_no(c->flat_volumes));
+ pa_strbuf_printf(s, "lock-memory = %s\n", pa_yes_no(c->lock_memory));
+ pa_strbuf_printf(s, "enable-sync-volume = %s\n", pa_yes_no(c->sync_volume));
pa_strbuf_printf(s, "exit-idle-time = %i\n", c->exit_idle_time);
pa_strbuf_printf(s, "scache-idle-time = %i\n", c->scache_idle_time);
pa_strbuf_printf(s, "dl-search-path = %s\n", pa_strempty(c->dl_search_path));
@@ -638,14 +746,16 @@ char *pa_daemon_conf_dump(pa_daemon_conf *c) {
pa_strbuf_printf(s, "log-target = %s\n", c->auto_log_target ? "auto" : (c->log_target == PA_LOG_SYSLOG ? "syslog" : "stderr"));
pa_strbuf_printf(s, "log-level = %s\n", log_level_to_string[c->log_level]);
pa_strbuf_printf(s, "resample-method = %s\n", pa_resample_method_to_string(c->resample_method));
- pa_strbuf_printf(s, "disable-remixing = %s\n", pa_yes_no(c->disable_remixing));
- pa_strbuf_printf(s, "disable-lfe-remixing = %s\n", pa_yes_no(c->disable_lfe_remixing));
+ pa_strbuf_printf(s, "enable-remixing = %s\n", pa_yes_no(!c->disable_remixing));
+ pa_strbuf_printf(s, "enable-lfe-remixing = %s\n", pa_yes_no(!c->disable_lfe_remixing));
pa_strbuf_printf(s, "default-sample-format = %s\n", pa_sample_format_to_string(c->default_sample_spec.format));
pa_strbuf_printf(s, "default-sample-rate = %u\n", c->default_sample_spec.rate);
pa_strbuf_printf(s, "default-sample-channels = %u\n", c->default_sample_spec.channels);
pa_strbuf_printf(s, "default-channel-map = %s\n", pa_channel_map_snprint(cm, sizeof(cm), &c->default_channel_map));
pa_strbuf_printf(s, "default-fragments = %u\n", c->default_n_fragments);
pa_strbuf_printf(s, "default-fragment-size-msec = %u\n", c->default_fragment_size_msec);
+ pa_strbuf_printf(s, "sync-volume-safety-margin-usec = %u\n", c->sync_volume_safety_margin_usec);
+ pa_strbuf_printf(s, "sync-volume-extra-delay-usec = %d\n", c->sync_volume_extra_delay_usec);
pa_strbuf_printf(s, "shm-size-bytes = %lu\n", (unsigned long) c->shm_size);
pa_strbuf_printf(s, "log-meta = %s\n", pa_yes_no(c->log_meta));
pa_strbuf_printf(s, "log-time = %s\n", pa_yes_no(c->log_time));
diff --git a/src/daemon/daemon-conf.h b/src/daemon/daemon-conf.h
index 9cec189f..9fd6aba6 100644
--- a/src/daemon/daemon-conf.h
+++ b/src/daemon/daemon-conf.h
@@ -28,6 +28,7 @@
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
+#include <pulsecore/core.h>
#include <pulsecore/core-util.h>
#ifdef HAVE_SYS_RESOURCE_H
@@ -73,7 +74,10 @@ typedef struct pa_daemon_conf {
disallow_exit,
log_meta,
log_time,
- flat_volumes;
+ flat_volumes,
+ lock_memory,
+ sync_volume;
+ pa_server_type_t local_server_type;
int exit_idle_time,
scache_idle_time,
auto_log_target,
@@ -124,6 +128,8 @@ typedef struct pa_daemon_conf {
#endif
unsigned default_n_fragments, default_fragment_size_msec;
+ unsigned sync_volume_safety_margin_usec;
+ int sync_volume_extra_delay_usec;
pa_sample_spec default_sample_spec;
pa_channel_map default_channel_map;
size_t shm_size;
@@ -151,6 +157,7 @@ int pa_daemon_conf_env(pa_daemon_conf *c);
int pa_daemon_conf_set_log_target(pa_daemon_conf *c, const char *string);
int pa_daemon_conf_set_log_level(pa_daemon_conf *c, const char *string);
int pa_daemon_conf_set_resample_method(pa_daemon_conf *c, const char *string);
+int pa_daemon_conf_set_local_server_type(pa_daemon_conf *c, const char *string);
const char *pa_daemon_conf_get_default_script_file(pa_daemon_conf *c);
FILE *pa_daemon_conf_open_default_script_file(pa_daemon_conf *c);
diff --git a/src/daemon/daemon.conf.in b/src/daemon/daemon.conf.in
index fcd2513a..6437f8f1 100644
--- a/src/daemon/daemon.conf.in
+++ b/src/daemon/daemon.conf.in
@@ -16,32 +16,37 @@
# USA.
## Configuration file for the PulseAudio daemon. See pulse-daemon.conf(5) for
-## more information. Default values a commented out. Use either ; or # for
+## more information. Default values are commented out. Use either ; or # for
## commenting.
+changequote(`[', `]')dnl Set up m4 quoting
; daemonize = no
; fail = yes
-; disallow-module-loading = no
-; disallow-exit = no
+; allow-module-loading = yes
+; allow-exit = yes
; use-pid-file = yes
; system-instance = no
-; disable-shm = no
+ifelse(@HAVE_DBUS@, 1, [dnl
+; local-server-type = user
+])dnl
+; enable-shm = yes
; shm-size-bytes = 0 # setting this 0 will use the system-default, usually 64 MiB
+; lock-memory = no
+; cpu-limit = no
; high-priority = yes
; nice-level = -11
-; realtime-scheduling = no
+; realtime-scheduling = yes
; realtime-priority = 5
; exit-idle-time = 20
-; module-idle-time = 20
; scache-idle-time = 20
; dl-search-path = (depends on architecture)
; load-default-script-file = yes
-; default-script-file = @PA_DEFAULT_CONFIG_FILE@
+; default-script-file = @PA_DEFAULT_CONFIG_DIR@/default.pa
; log-target = auto
; log-level = notice
@@ -50,13 +55,12 @@
; log-backtrace = 0
; resample-method = speex-float-3
-; disable-remixing = no
-; disable-lfe-remixing = yes
+; enable-remixing = yes
+; enable-lfe-remixing = no
; flat-volumes = yes
-; no-cpu-limit = no
-
+ifelse(@HAVE_SYS_RESOURCE_H@, 1, [dnl
; rlimit-fsize = -1
; rlimit-data = -1
; rlimit-stack = -1
@@ -71,7 +75,8 @@
; rlimit-msgqueue = -1
; rlimit-nice = 31
; rlimit-rtprio = 9
-; rlimit-rtttime = 1000000
+; rlimit-rttime = 1000000
+])dnl
; default-sample-format = s16le
; default-sample-rate = 44100
@@ -80,3 +85,7 @@
; default-fragments = 4
; default-fragment-size-msec = 25
+
+; enable-sync-volume = yes
+; sync-volume-safety-margin-usec = 8000
+; sync-volume-extra-delay-usec = 0
diff --git a/src/daemon/default.pa.in b/src/daemon/default.pa.in
index ba8e3c80..55a7423f 100755
--- a/src/daemon/default.pa.in
+++ b/src/daemon/default.pa.in
@@ -18,14 +18,20 @@
# This startup script is used only if PulseAudio is started per-user
# (i.e. not in system mode)
+changequote(`[', `]')dnl Set up m4 quoting
.nofail
### Load something into the sample cache
+ifelse(@OS_IS_WIN32@, 1, [dnl
+load-sample x11-bell %WINDIR%\Media\ding.wav
+load-sample-dir-lazy %WINDIR%\Media\*.wav
+], [dnl
#load-sample-lazy x11-bell /usr/share/sounds/gtk-events/activate.wav
#load-sample-lazy pulse-hotplug /usr/share/sounds/startup3.wav
#load-sample-lazy pulse-coldplug /usr/share/sounds/startup3.wav
#load-sample-lazy pulse-access /usr/share/sounds/generic.wav
+])dnl
.fail
@@ -38,46 +44,71 @@ load-module module-card-restore
### stored in /usr/share/application
load-module module-augment-properties
-### Load audio drivers statically (it's probably better to not load
-### these drivers manually, but instead use module-hal-detect --
-### see below -- for doing this automatically)
+### Load audio drivers statically
+### (it's probably better to not load these drivers manually, but instead
+### use module-udev-detect -- see below -- for doing this automatically)
+ifelse(@HAVE_ALSA@, 1, [dnl
#load-module module-alsa-sink
#load-module module-alsa-source device=hw:1,0
+])dnl
+ifelse(@HAVE_OSS_OUTPUT@, 1, [dnl
#load-module module-oss device="/dev/dsp" sink_name=output source_name=input
#load-module module-oss-mmap device="/dev/dsp" sink_name=output source_name=input
+])dnl
+ifelse(@HAVE_WAVEOUT@, 1, [dnl
+load-module module-waveout sink_name=output source_name=input
+])dnl
#load-module module-null-sink
+ifelse(@HAVE_MKFIFO@, 1, [dnl
#load-module module-pipe-sink
+])dnl
### Automatically load driver modules depending on the hardware available
+ifelse(1, @HAVE_UDEV@, [dnl
+.ifexists module-udev-detect@PA_SOEXT@
+load-module module-udev-detect
+.else
+], @HAVE_HAL@, [dnl
.ifexists module-hal-detect@PA_SOEXT@
load-module module-hal-detect
.else
-### Alternatively use the static hardware detection module (for systems that
-### lack HAL support)
+], [dnl
+.ifexists module-detect@PA_SOEXT@
+])dnl
+### Use the static hardware detection module (for systems that lack udev support)
load-module module-detect
.endif
+ifelse(@HAVE_BLUEZ@, 1, [dnl
### Automatically load driver modules for Bluetooth hardware
.ifexists module-bluetooth-discover@PA_SOEXT@
load-module module-bluetooth-discover
.endif
+])dnl
+ifelse(@HAVE_AF_UNIX@, 1, [dnl
### Load several protocols
-.ifexists module-esound-protocol-unix@PA_SOEXT@
-load-module module-esound-protocol-unix
-.endif
+#.ifexists module-esound-protocol-unix@PA_SOEXT@
+#load-module module-esound-protocol-unix
+#.endif
+load-module module-native-protocol-unix
+])dnl
+ifelse(@HAVE_DBUS@, 1, [dnl
.ifexists module-dbus-protocol@PA_SOEXT@
load-module module-dbus-protocol
.endif
-load-module module-native-protocol-unix
+])dnl
### Network access (may be configured with paprefs, so leave this commented
### here if you plan to use paprefs)
#load-module module-esound-protocol-tcp
#load-module module-native-protocol-tcp
+ifelse(@HAVE_AVAHI@, 1, [dnl
#load-module module-zeroconf-publish
+])dnl
-### Load the RTP reciever module (also configured via paprefs, see above)
+ifelse(@OS_IS_WIN32@, 0, [dnl
+### Load the RTP receiver module (also configured via paprefs, see above)
#load-module module-rtp-recv
### Load the RTP sender module (also configured via paprefs, see above)
@@ -103,19 +134,26 @@ load-module module-rescue-streams
### Make sure we always have a sink around, even if it is a null sink.
load-module module-always-sink
+### Honour intended role device property
+load-module module-intended-roles
+
### Automatically suspend sinks/sources that become idle for too long
load-module module-suspend-on-idle
### If autoexit on idle is enabled we want to make sure we only quit
### when no local session needs us anymore.
+.ifexists module-console-kit@PA_SOEXT@
load-module module-console-kit
+.endif
### Enable positioned event sounds
load-module module-position-event-sounds
### Cork music streams when a phone stream is active
load-module module-cork-music-on-phone
+])dnl
+ifelse(@HAVE_X11@, 1, [dnl
# X11 modules should not be started from default.pa so that one daemon
# can be shared by multiple sessions.
@@ -131,6 +169,7 @@ load-module module-cork-music-on-phone
#load-module module-x11-publish
#.fail
#.endif
+])dnl
### Make some devices default
#set-default-sink output
diff --git a/src/daemon/default.pa.win32 b/src/daemon/default.pa.win32
deleted file mode 100644
index d5a1e183..00000000
--- a/src/daemon/default.pa.win32
+++ /dev/null
@@ -1,43 +0,0 @@
-#
-# This file is part of PulseAudio.
-#
-# PulseAudio is free software; you can redistribute it and/or modify it
-# under the terms of the GNU Lesser General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# PulseAudio is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public License
-# along with PulseAudio; if not, write to the Free Software Foundation,
-# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
-
-
-# Load audio drivers statically
-
-load-module module-waveout sink_name=output source_name=input
-load-module module-null-sink
-
-# Load audio drivers automatically on access
-
-#add-autoload-sink output module-waveout sink_name=output source_name=input
-#add-autoload-source input module-waveout sink_name=output source_name=input
-
-# Load several protocols
-#load-module module-esound-protocol-tcp
-#load-module module-native-protocol-tcp
-#load-module module-simple-protocol-tcp
-#load-module module-cli-protocol-tcp
-
-# Make some devices default
-set-default-sink output
-set-default-source input
-
-.nofail
-
-# Load something to the sample cache
-load-sample x11-bell %WINDIR%\Media\ding.wav
-load-sample-dir-lazy %WINDIR%\Media\*.wav
diff --git a/src/daemon/dumpmodules.c b/src/daemon/dumpmodules.c
index 92470b49..68ab5bba 100644
--- a/src/daemon/dumpmodules.c
+++ b/src/daemon/dumpmodules.c
@@ -25,7 +25,6 @@
#endif
#include <string.h>
-#include <getopt.h>
#include <stdio.h>
#include <ltdl.h>
@@ -90,7 +89,9 @@ static void show_info(const char *name, const char *path, void (*info)(const cha
}
}
+#ifndef OS_IS_WIN32
extern const lt_dlsymlist lt_preloaded_symbols[];
+#endif
static int is_preloaded(const char *name) {
const lt_dlsymlist *l;
diff --git a/src/daemon/esdcompat.in b/src/daemon/esdcompat.in
index 66501803..41a12a02 100755
--- a/src/daemon/esdcompat.in
+++ b/src/daemon/esdcompat.in
@@ -59,7 +59,7 @@ Ignored directives:
-terminate terminate esd daemone after last client exits
-nobeeps disable startup beeps
-trust start esd even if use of /tmp/.esd can be insecure
- -port PORT listen for connections at PORT (only for tcp/ip)
+ -port PORT listen for connections at PORT (only for tcp/ip)
-bind ADDRESS binds to ADDRESS (only for tcp/ip)
EOF
exit 0
diff --git a/src/daemon/ltdl-bind-now.c b/src/daemon/ltdl-bind-now.c
index 276b2a06..2ba73ce7 100644
--- a/src/daemon/ltdl-bind-now.c
+++ b/src/daemon/ltdl-bind-now.c
@@ -51,6 +51,10 @@
#undef PA_BIND_NOW
#endif
+#ifdef OS_IS_WIN32
+#undef PA_BIND_NOW
+#endif
+
#ifdef PA_BIND_NOW
/*
diff --git a/src/daemon/main.c b/src/daemon/main.c
index 3e50baad..94c87d15 100644
--- a/src/daemon/main.c
+++ b/src/daemon/main.c
@@ -33,15 +33,13 @@
#include <stddef.h>
#include <ltdl.h>
#include <limits.h>
-#include <fcntl.h>
#include <unistd.h>
#include <locale.h>
#include <sys/types.h>
+#include <sys/stat.h>
-#include <liboil/liboil.h>
-
-#ifdef HAVE_SYS_IOCTL_H
-#include <sys/ioctl.h>
+#ifdef HAVE_SYS_MMAN_H
+#include <sys/mman.h>
#endif
#ifdef HAVE_PWD_H
@@ -60,6 +58,10 @@
#include <dbus/dbus.h>
#endif
+#include <pulse/client-conf.h>
+#ifdef HAVE_X11
+#include <pulse/client-conf-x11.h>
+#endif
#include <pulse/mainloop.h>
#include <pulse/mainloop-signal.h>
#include <pulse/timeval.h>
@@ -67,10 +69,10 @@
#include <pulse/i18n.h>
#include <pulsecore/lock-autospawn.h>
-#include <pulsecore/winsock.h>
+#include <pulsecore/socket.h>
#include <pulsecore/core-error.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core.h>
-#include <pulsecore/memblock.h>
#include <pulsecore/module.h>
#include <pulsecore/cli-command.h>
#include <pulsecore/log.h>
@@ -78,19 +80,17 @@
#include <pulsecore/sioman.h>
#include <pulsecore/cli-text.h>
#include <pulsecore/pid.h>
-#include <pulsecore/namereg.h>
#include <pulsecore/random.h>
-#include <pulsecore/rtsig.h>
-#include <pulsecore/rtclock.h>
#include <pulsecore/macro.h>
-#include <pulsecore/mutex.h>
-#include <pulsecore/thread.h>
-#include <pulsecore/once.h>
#include <pulsecore/shm.h>
#include <pulsecore/memtrap.h>
+#include <pulsecore/strlist.h>
#ifdef HAVE_DBUS
#include <pulsecore/dbus-shared.h>
#endif
+#include <pulsecore/cpu-arm.h>
+#include <pulsecore/cpu-x86.h>
+#include <pulsecore/cpu-orc.h>
#include "cmdline.h"
#include "cpulimit.h"
@@ -98,7 +98,7 @@
#include "dumpmodules.h"
#include "caps.h"
#include "ltdl-bind-now.h"
-#include "polkit.h"
+#include "server-lookup.h"
#ifdef HAVE_LIBWRAP
/* Only one instance of these variables */
@@ -106,7 +106,7 @@ int allow_severity = LOG_INFO;
int deny_severity = LOG_WARNING;
#endif
-#ifdef HAVE_OSS
+#ifdef HAVE_OSS_WRAPPER
/* padsp looks for this symbol in the running process and disables
* itself if it finds it and it is set to 7 (which is actually a bit
* mask). For details see padsp. */
@@ -256,9 +256,14 @@ static int change_user(void) {
pa_set_env("HOME", PA_SYSTEM_RUNTIME_PATH);
/* Relevant for pa_runtime_path() */
- pa_set_env("PULSE_RUNTIME_PATH", PA_SYSTEM_RUNTIME_PATH);
- pa_set_env("PULSE_CONFIG_PATH", PA_SYSTEM_CONFIG_PATH);
- pa_set_env("PULSE_STATE_PATH", PA_SYSTEM_STATE_PATH);
+ if (!getenv("PULSE_RUNTIME_PATH"))
+ pa_set_env("PULSE_RUNTIME_PATH", PA_SYSTEM_RUNTIME_PATH);
+
+ if (!getenv("PULSE_CONFIG_PATH"))
+ pa_set_env("PULSE_CONFIG_PATH", PA_SYSTEM_CONFIG_PATH);
+
+ if (!getenv("PULSE_STATE_PATH"))
+ pa_set_env("PULSE_STATE_PATH", PA_SYSTEM_STATE_PATH);
pa_log_info(_("Successfully dropped root privileges."));
@@ -334,34 +339,50 @@ static void set_all_rlimits(const pa_daemon_conf *conf) {
}
#endif
+static char *check_configured_address(void) {
+ char *default_server = NULL;
+ pa_client_conf *c = pa_client_conf_new();
+
+ pa_client_conf_load(c, NULL);
+#ifdef HAVE_X11
+ pa_client_conf_from_x11(c, NULL);
+#endif
+ pa_client_conf_env(c);
+
+ if (c->default_server && *c->default_server)
+ default_server = pa_xstrdup(c->default_server);
+
+ pa_client_conf_free(c);
+
+ return default_server;
+}
+
#ifdef HAVE_DBUS
-static pa_dbus_connection *register_dbus(pa_core *c) {
+static pa_dbus_connection *register_dbus_name(pa_core *c, DBusBusType bus, const char* name) {
DBusError error;
pa_dbus_connection *conn;
dbus_error_init(&error);
- if (!(conn = pa_dbus_bus_get(c, pa_in_system_mode() ? DBUS_BUS_SYSTEM : DBUS_BUS_SESSION, &error)) || dbus_error_is_set(&error)) {
+ if (!(conn = pa_dbus_bus_get(c, bus, &error)) || dbus_error_is_set(&error)) {
pa_log_warn("Unable to contact D-Bus: %s: %s", error.name, error.message);
goto fail;
}
- if (dbus_bus_request_name(pa_dbus_connection_get(conn), "org.pulseaudio.Server", DBUS_NAME_FLAG_DO_NOT_QUEUE, &error) == DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER) {
- pa_log_debug("Got org.pulseaudio.Server!");
+ if (dbus_bus_request_name(pa_dbus_connection_get(conn), name, DBUS_NAME_FLAG_DO_NOT_QUEUE, &error) == DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER) {
+ pa_log_debug("Got %s!", name);
return conn;
}
if (dbus_error_is_set(&error))
- pa_log_warn("Failed to acquire org.pulseaudio.Server: %s: %s", error.name, error.message);
+ pa_log_error("Failed to acquire %s: %s: %s", name, error.name, error.message);
else
- pa_log_warn("D-Bus name org.pulseaudio.Server already taken. Weird shit!");
+ pa_log_error("D-Bus name %s already taken. Weird shit!", name);
/* PA cannot be started twice by the same user and hence we can
- * ignore mostly the case that org.pulseaudio.Server is already
- * taken. */
+ * ignore mostly the case that a name is already taken. */
fail:
-
if (conn)
pa_dbus_connection_unref(conn);
@@ -376,15 +397,15 @@ int main(int argc, char *argv[]) {
pa_daemon_conf *conf = NULL;
pa_mainloop *mainloop = NULL;
char *s;
+ char *configured_address;
int r = 0, retval = 1, d = 0;
- pa_bool_t suid_root, real_root;
pa_bool_t valid_pid_file = FALSE;
- gid_t gid = (gid_t) -1;
pa_bool_t ltdl_init = FALSE;
int passed_fd = -1;
const char *e;
#ifdef HAVE_FORK
int daemon_pipe[2] = { -1, -1 };
+ int daemon_pipe2[2] = { -1, -1 };
#endif
#ifdef OS_IS_WIN32
pa_time_event *win32_timer;
@@ -393,7 +414,10 @@ int main(int argc, char *argv[]) {
int autospawn_fd = -1;
pa_bool_t autospawn_locked = FALSE;
#ifdef HAVE_DBUS
- pa_dbus_connection *dbus = NULL;
+ pa_dbusobj_server_lookup *server_lookup = NULL; /* /org/pulseaudio/server_lookup */
+ pa_dbus_connection *lookup_service_bus = NULL; /* Always the user bus. */
+ pa_dbus_connection *server_bus = NULL; /* The bus where we reserve org.pulseaudio.Server, either the user or the system bus. */
+ pa_bool_t start_server;
#endif
pa_log_set_ident("pulseaudio");
@@ -404,47 +428,39 @@ int main(int argc, char *argv[]) {
/*
Disable lazy relocations to make usage of external libraries
more deterministic for our RT threads. We abuse __OPTIMIZE__ as
- a check whether we are a debug build or not.
+ a check whether we are a debug build or not. This all is
+ admittedly a bit snake-oilish.
*/
if (!getenv("LD_BIND_NOW")) {
char *rp;
+ char *canonical_rp;
/* We have to execute ourselves, because the libc caches the
* value of $LD_BIND_NOW on initialization. */
pa_set_env("LD_BIND_NOW", "1");
- if ((rp = pa_readlink("/proc/self/exe")))
- pa_assert_se(execv(rp, argv) == 0);
- else
- pa_log_warn("Couldn't read /proc/self/exe, cannot self execute. Running in a chroot()?");
- }
-#endif
+ if ((canonical_rp = pa_realpath(PA_BINARY))) {
-#ifdef HAVE_GETUID
- real_root = getuid() == 0;
- suid_root = !real_root && geteuid() == 0;
-#else
- real_root = FALSE;
- suid_root = FALSE;
-#endif
+ if ((rp = pa_readlink("/proc/self/exe"))) {
+
+ if (pa_streq(rp, canonical_rp))
+ pa_assert_se(execv(rp, argv) == 0);
+ else
+ pa_log_warn("/proc/self/exe does not point to %s, cannot self execute. Are you playing games?", canonical_rp);
- if (!real_root) {
- /* Drop all capabilities except CAP_SYS_NICE */
- pa_limit_caps();
+ pa_xfree(rp);
- /* Drop privileges, but keep CAP_SYS_NICE */
- pa_drop_root();
+ } else
+ pa_log_warn("Couldn't read /proc/self/exe, cannot self execute. Running in a chroot()?");
- /* After dropping root, the effective set is reset, hence,
- * let's raise it again */
- pa_limit_caps();
+ pa_xfree(canonical_rp);
- /* When capabilities are not supported we will not be able to
- * acquire RT sched anymore. But yes, that's the way it is. It
- * is just too risky tun let PA run as root all the time. */
+ } else
+ pa_log_warn("Couldn't canonicalize binary path, cannot self execute.");
}
+#endif
if ((e = getenv("PULSE_PASSED_FD"))) {
passed_fd = atoi(e);
@@ -453,14 +469,16 @@ int main(int argc, char *argv[]) {
passed_fd = -1;
}
- pa_close_all(passed_fd, -1);
+ /* We might be autospawned, in which case have no idea in which
+ * context we have been started. Let's cleanup our execution
+ * context as good as possible */
+ pa_reset_personality();
+ pa_drop_root();
+ pa_close_all(passed_fd, -1);
pa_reset_sigs(-1);
pa_unblock_sigs(-1);
-
- /* At this point, we are a normal user, possibly with CAP_NICE if
- * we were started SUID. If we are started as normal root, than we
- * still are normal root. */
+ pa_reset_priority();
setlocale(LC_ALL, "");
pa_init_i18n();
@@ -486,150 +504,32 @@ int main(int argc, char *argv[]) {
pa_log_set_flags(PA_LOG_PRINT_TIME, PA_LOG_SET);
pa_log_set_show_backtrace(conf->log_backtrace);
- pa_log_debug("Started as real root: %s, suid root: %s", pa_yes_no(real_root), pa_yes_no(suid_root));
-
- if (!real_root && pa_have_caps()) {
-#ifdef HAVE_SYS_RESOURCE_H
- struct rlimit rl;
-#endif
- pa_bool_t allow_high_priority = FALSE, allow_realtime = FALSE;
-
- /* Let's better not enable high prio or RT by default */
-
- if (conf->high_priority && !allow_high_priority) {
- if (pa_own_uid_in_group(PA_REALTIME_GROUP, &gid) > 0) {
- pa_log_info(_("We're in the group '%s', allowing high-priority scheduling."), PA_REALTIME_GROUP);
- allow_high_priority = TRUE;
- }
- }
-
- if (conf->realtime_scheduling && !allow_realtime) {
- if (pa_own_uid_in_group(PA_REALTIME_GROUP, &gid) > 0) {
- pa_log_info(_("We're in the group '%s', allowing real-time scheduling."), PA_REALTIME_GROUP);
- allow_realtime = TRUE;
- }
- }
-
-#ifdef HAVE_POLKIT
- if (conf->high_priority && !allow_high_priority) {
- if (pa_polkit_check("org.pulseaudio.acquire-high-priority") > 0) {
- pa_log_info(_("PolicyKit grants us acquire-high-priority privilege."));
- allow_high_priority = TRUE;
- } else
- pa_log_info(_("PolicyKit refuses acquire-high-priority privilege."));
- }
-
- if (conf->realtime_scheduling && !allow_realtime) {
- if (pa_polkit_check("org.pulseaudio.acquire-real-time") > 0) {
- pa_log_info(_("PolicyKit grants us acquire-real-time privilege."));
- allow_realtime = TRUE;
- } else
- pa_log_info(_("PolicyKit refuses acquire-real-time privilege."));
- }
-#endif
-
- if (!allow_high_priority && !allow_realtime) {
-
- /* OK, there's no further need to keep CAP_NICE. Hence
- * let's give it up early */
-
- pa_drop_caps();
- }
-
-#ifdef RLIMIT_RTPRIO
- if (getrlimit(RLIMIT_RTPRIO, &rl) >= 0)
- if (rl.rlim_cur > 0) {
- pa_log_info("RLIMIT_RTPRIO is set to %u, allowing real-time scheduling.", (unsigned) rl.rlim_cur);
- allow_realtime = TRUE;
- }
-#endif
-#ifdef RLIMIT_NICE
- if (getrlimit(RLIMIT_NICE, &rl) >= 0)
- if (rl.rlim_cur > 20 ) {
- pa_log_info("RLIMIT_NICE is set to %u, allowing high-priority scheduling.", (unsigned) rl.rlim_cur);
- allow_high_priority = TRUE;
- }
-#endif
-
- if ((conf->high_priority && !allow_high_priority) ||
- (conf->realtime_scheduling && !allow_realtime))
- pa_log_info(_("Called SUID root and real-time and/or high-priority scheduling was requested in the configuration. However, we lack the necessary privileges:\n"
- "We are not in group '%s', PolicyKit refuse to grant us the requested privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource limits.\n"
- "For enabling real-time/high-priority scheduling please acquire the appropriate PolicyKit privileges, or become a member of '%s', or increase the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user."),
- PA_REALTIME_GROUP, PA_REALTIME_GROUP);
-
-
- if (!allow_realtime)
- conf->realtime_scheduling = FALSE;
-
- if (!allow_high_priority)
- conf->high_priority = FALSE;
+#ifdef HAVE_DBUS
+ /* conf->system_instance and conf->local_server_type control almost the
+ * same thing; make them agree about what is requested. */
+ switch (conf->local_server_type) {
+ case PA_SERVER_TYPE_UNSET:
+ conf->local_server_type = conf->system_instance ? PA_SERVER_TYPE_SYSTEM : PA_SERVER_TYPE_USER;
+ break;
+ case PA_SERVER_TYPE_USER:
+ case PA_SERVER_TYPE_NONE:
+ conf->system_instance = FALSE;
+ break;
+ case PA_SERVER_TYPE_SYSTEM:
+ conf->system_instance = TRUE;
+ break;
+ default:
+ pa_assert_not_reached();
}
-#ifdef HAVE_SYS_RESOURCE_H
- /* Reset resource limits. If we are run as root (for system mode)
- * this might end up increasing the limits, which is intended
- * behaviour. For all other cases, i.e. started as normal user, or
- * SUID root at this point we should have no CAP_SYS_RESOURCE and
- * increasing the limits thus should fail. Which is, too, intended
- * behaviour */
+ start_server = conf->local_server_type == PA_SERVER_TYPE_USER || (getuid() == 0 && conf->local_server_type == PA_SERVER_TYPE_SYSTEM);
- set_all_rlimits(conf);
-#endif
-
- if (conf->high_priority && !pa_can_high_priority()) {
- pa_log_info(_("High-priority scheduling enabled in configuration but not allowed by policy."));
- conf->high_priority = FALSE;
+ if (!start_server && conf->local_server_type == PA_SERVER_TYPE_SYSTEM) {
+ pa_log_notice(_("System mode refused for non-root user. Only starting the D-Bus server lookup service."));
+ conf->system_instance = FALSE;
}
-
- if (conf->high_priority && (conf->cmd == PA_CMD_DAEMON || conf->cmd == PA_CMD_START))
- pa_raise_priority(conf->nice_level);
-
- pa_log_debug("Can realtime: %s, can high-priority: %s", pa_yes_no(pa_can_realtime()), pa_yes_no(pa_can_high_priority()));
-
- if (!real_root && pa_have_caps()) {
- pa_bool_t drop;
-
- drop = (conf->cmd != PA_CMD_DAEMON && conf->cmd != PA_CMD_START) || !conf->realtime_scheduling;
-
-#ifdef RLIMIT_RTPRIO
- if (!drop) {
- struct rlimit rl;
- /* At this point we still have CAP_NICE if we were loaded
- * SUID root. If possible let's acquire RLIMIT_RTPRIO
- * instead and give CAP_NICE up. */
-
- if (getrlimit(RLIMIT_RTPRIO, &rl) >= 0) {
-
- if (rl.rlim_cur >= 9)
- drop = TRUE;
- else {
- rl.rlim_max = rl.rlim_cur = 9;
-
- if (setrlimit(RLIMIT_RTPRIO, &rl) >= 0) {
- pa_log_info(_("Successfully increased RLIMIT_RTPRIO"));
- drop = TRUE;
- } else
- pa_log_warn(_("RLIMIT_RTPRIO failed: %s"), pa_cstrerror(errno));
- }
- }
- }
#endif
- if (drop) {
- pa_log_info(_("Giving up CAP_NICE"));
- pa_drop_caps();
- suid_root = FALSE;
- }
- }
-
- if (conf->realtime_scheduling && !pa_can_realtime()) {
- pa_log_info(_("Real-time scheduling enabled in configuration but not allowed by policy."));
- conf->realtime_scheduling = FALSE;
- }
-
- pa_log_debug("Can realtime: %s, can high-priority: %s", pa_yes_no(pa_can_realtime()), pa_yes_no(pa_can_high_priority()));
-
LTDL_SET_PRELOADED_SYMBOLS();
pa_ltdl_init();
ltdl_init = TRUE;
@@ -653,6 +553,12 @@ int main(int argc, char *argv[]) {
goto finish;
case PA_CMD_DUMP_CONF: {
+
+ if (d < argc) {
+ pa_log("Too many arguments.\n");
+ goto finish;
+ }
+
s = pa_daemon_conf_dump(conf);
fputs(s, stdout);
pa_xfree(s);
@@ -663,6 +569,11 @@ int main(int argc, char *argv[]) {
case PA_CMD_DUMP_RESAMPLE_METHODS: {
int i;
+ if (d < argc) {
+ pa_log("Too many arguments.\n");
+ goto finish;
+ }
+
for (i = 0; i < PA_RESAMPLER_MAX; i++)
if (pa_resample_method_supported(i))
printf("%s\n", pa_resample_method_to_string(i));
@@ -677,6 +588,12 @@ int main(int argc, char *argv[]) {
goto finish;
case PA_CMD_VERSION :
+
+ if (d < argc) {
+ pa_log("Too many arguments.\n");
+ goto finish;
+ }
+
printf(PACKAGE_NAME" "PACKAGE_VERSION"\n");
retval = 0;
goto finish;
@@ -684,6 +601,11 @@ int main(int argc, char *argv[]) {
case PA_CMD_CHECK: {
pid_t pid;
+ if (d < argc) {
+ pa_log("Too many arguments.\n");
+ goto finish;
+ }
+
if (pa_pid_file_check_running(&pid, "pulseaudio") < 0)
pa_log_info(_("Daemon not running"));
else {
@@ -696,6 +618,11 @@ int main(int argc, char *argv[]) {
}
case PA_CMD_KILL:
+ if (d < argc) {
+ pa_log("Too many arguments.\n");
+ goto finish;
+ }
+
if (pa_pid_file_kill(SIGINT, NULL, "pulseaudio") < 0)
pa_log(_("Failed to kill daemon: %s"), pa_cstrerror(errno));
else
@@ -705,6 +632,11 @@ int main(int argc, char *argv[]) {
case PA_CMD_CLEANUP_SHM:
+ if (d < argc) {
+ pa_log("Too many arguments.\n");
+ goto finish;
+ }
+
if (pa_shm_cleanup() >= 0)
retval = 0;
@@ -714,18 +646,73 @@ int main(int argc, char *argv[]) {
pa_assert(conf->cmd == PA_CMD_DAEMON || conf->cmd == PA_CMD_START);
}
- if (real_root && !conf->system_instance)
+ if (d < argc) {
+ pa_log("Too many arguments.\n");
+ goto finish;
+ }
+
+#ifdef HAVE_GETUID
+ if (getuid() == 0 && !conf->system_instance)
pa_log_warn(_("This program is not intended to be run as root (unless --system is specified)."));
- else if (!real_root && conf->system_instance) {
+#ifndef HAVE_DBUS /* A similar, only a notice worthy check was done earlier, if D-Bus is enabled. */
+ else if (getuid() != 0 && conf->system_instance) {
pa_log(_("Root privileges required."));
goto finish;
}
+#endif
+#endif /* HAVE_GETUID */
if (conf->cmd == PA_CMD_START && conf->system_instance) {
pa_log(_("--start not supported for system instances."));
goto finish;
}
+ if (conf->cmd == PA_CMD_START && (configured_address = check_configured_address())) {
+ /* There is an server address in our config, but where did it come from?
+ * By default a standard X11 login will load module-x11-publish which will
+ * inject PULSE_SERVER X11 property. If the PA daemon crashes, we will end
+ * up hitting this code path. So we have to check to see if our configured_address
+ * is the same as the value that would go into this property so that we can
+ * recover (i.e. autospawn) from a crash.
+ */
+ char *ufn;
+ pa_bool_t start_anyway = FALSE;
+
+ if ((ufn = pa_runtime_path(PA_NATIVE_DEFAULT_UNIX_SOCKET))) {
+ char *id;
+
+ if ((id = pa_machine_id())) {
+ pa_strlist *server_list;
+ char formatted_ufn[256];
+
+ pa_snprintf(formatted_ufn, sizeof(formatted_ufn), "{%s}unix:%s", id, ufn);
+ pa_xfree(id);
+
+ if ((server_list = pa_strlist_parse(configured_address))) {
+ char *u = NULL;
+
+ /* We only need to check the first server */
+ server_list = pa_strlist_pop(server_list, &u);
+ pa_strlist_free(server_list);
+
+ start_anyway = (u && pa_streq(formatted_ufn, u));
+ pa_xfree(u);
+ }
+ }
+ pa_xfree(ufn);
+ }
+
+ if (!start_anyway) {
+ pa_log_notice(_("User-configured server at %s, refusing to start/autospawn."), configured_address);
+ pa_xfree(configured_address);
+ retval = 0;
+ goto finish;
+ }
+
+ pa_log_notice(_("User-configured server at %s, which appears to be local. Probing deeper."), configured_address);
+ pa_xfree(configured_address);
+ }
+
if (conf->system_instance && !conf->disallow_exit)
pa_log_warn(_("Running in system mode, but --disallow-exit not set!"));
@@ -761,8 +748,9 @@ int main(int argc, char *argv[]) {
}
if (conf->daemonize) {
+#ifdef HAVE_FORK
pid_t child;
- int tty_fd;
+#endif
if (pa_stdio_acquire() < 0) {
pa_log(_("Failed to acquire stdio."));
@@ -771,12 +759,13 @@ int main(int argc, char *argv[]) {
#ifdef HAVE_FORK
if (pipe(daemon_pipe) < 0) {
- pa_log(_("pipe failed: %s"), pa_cstrerror(errno));
+ pa_log(_("pipe() failed: %s"), pa_cstrerror(errno));
goto finish;
}
if ((child = fork()) < 0) {
pa_log(_("fork() failed: %s"), pa_cstrerror(errno));
+ pa_close_pipe(daemon_pipe);
goto finish;
}
@@ -822,22 +811,60 @@ int main(int argc, char *argv[]) {
pa_log_set_target(PA_LOG_SYSLOG);
#ifdef HAVE_SETSID
- setsid();
-#endif
-#ifdef HAVE_SETPGID
- setpgid(0,0);
+ if (setsid() < 0) {
+ pa_log(_("setsid() failed: %s"), pa_cstrerror(errno));
+ goto finish;
+ }
#endif
-#ifndef OS_IS_WIN32
- pa_close(0);
- pa_close(1);
- pa_close(2);
+#ifdef HAVE_FORK
+ /* We now are a session and process group leader. Let's fork
+ * again and let the father die, so that we'll become a
+ * process that can never acquire a TTY again, in a session and
+ * process group without leader */
- pa_assert_se(open("/dev/null", O_RDONLY) == 0);
- pa_assert_se(open("/dev/null", O_WRONLY) == 1);
- pa_assert_se(open("/dev/null", O_WRONLY) == 2);
-#else
- FreeConsole();
+ if (pipe(daemon_pipe2) < 0) {
+ pa_log(_("pipe() failed: %s"), pa_cstrerror(errno));
+ goto finish;
+ }
+
+ if ((child = fork()) < 0) {
+ pa_log(_("fork() failed: %s"), pa_cstrerror(errno));
+ pa_close_pipe(daemon_pipe2);
+ goto finish;
+ }
+
+ if (child != 0) {
+ ssize_t n;
+ /* Father */
+
+ pa_assert_se(pa_close(daemon_pipe2[1]) == 0);
+ daemon_pipe2[1] = -1;
+
+ if ((n = pa_loop_read(daemon_pipe2[0], &retval, sizeof(retval), NULL)) != sizeof(retval)) {
+
+ if (n < 0)
+ pa_log(_("read() failed: %s"), pa_cstrerror(errno));
+
+ retval = 1;
+ }
+
+ /* We now have to take care of signalling the first fork with
+ * the return value we've received from this fork... */
+ pa_assert(daemon_pipe[1] >= 0);
+
+ pa_loop_write(daemon_pipe[1], &retval, sizeof(retval), NULL);
+ pa_close(daemon_pipe[1]);
+ daemon_pipe[1] = -1;
+
+ goto finish;
+ }
+
+ pa_assert_se(pa_close(daemon_pipe2[0]) == 0);
+ daemon_pipe2[0] = -1;
+
+ /* We no longer need the (first) daemon_pipe as it's handled in our child above */
+ pa_close_pipe(daemon_pipe);
#endif
#ifdef SIGTTOU
@@ -850,23 +877,25 @@ int main(int argc, char *argv[]) {
signal(SIGTSTP, SIG_IGN);
#endif
-#ifdef TIOCNOTTY
- if ((tty_fd = open("/dev/tty", O_RDWR)) >= 0) {
- ioctl(tty_fd, TIOCNOTTY, (char*) 0);
- pa_assert_se(pa_close(tty_fd) == 0);
- }
-#endif
+ pa_nullify_stdfds();
}
- pa_set_env("PULSE_INTERNAL", "1");
+ pa_set_env_and_record("PULSE_INTERNAL", "1");
pa_assert_se(chdir("/") == 0);
umask(0022);
+#ifdef HAVE_SYS_RESOURCE_H
+ set_all_rlimits(conf);
+#endif
+ pa_rtclock_hrtimer_enable();
+
+ pa_raise_priority(conf->nice_level);
+
if (conf->system_instance)
if (change_user() < 0)
goto finish;
- pa_set_env("PULSE_SYSTEM", conf->system_instance ? "1" : "0");
+ pa_set_env_and_record("PULSE_SYSTEM", conf->system_instance ? "1" : "0");
pa_log_info(_("This is PulseAudio %s"), PACKAGE_VERSION);
pa_log_debug(_("Compilation host: %s"), CANONICAL_HOST);
@@ -888,6 +917,8 @@ int main(int argc, char *argv[]) {
pa_log_debug(_("Running in valgrind mode: %s"), pa_yes_no(pa_in_valgrind()));
+ pa_log_debug(_("Running in VM: %s"), pa_yes_no(pa_running_in_vm()));
+
#ifdef __OPTIMIZE__
pa_log_debug(_("Optimized build: yes"));
#else
@@ -910,8 +941,8 @@ int main(int argc, char *argv[]) {
pa_xfree(s);
if ((s = pa_session_id())) {
- pa_log_info(_("Session ID is %s."), s);
- pa_xfree(s);
+ pa_log_info(_("Session ID is %s."), s);
+ pa_xfree(s);
}
if (!(s = pa_get_runtime_dir()))
@@ -924,8 +955,15 @@ int main(int argc, char *argv[]) {
pa_log_info(_("Using state directory %s."), s);
pa_xfree(s);
+ pa_log_info(_("Using modules directory %s."), conf->dl_search_path);
+
pa_log_info(_("Running in system mode: %s"), pa_yes_no(pa_in_system_mode()));
+ if (pa_in_system_mode())
+ pa_log_warn(_("OK, so you are running PA in system mode. Please note that you most likely shouldn't be doing that.\n"
+ "If you do it nonetheless then it's your own fault if things don't work as expected.\n"
+ "Please read http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode for an explanation why system mode is usually a bad idea."));
+
if (conf->use_pid_file) {
int z;
@@ -953,12 +991,16 @@ int main(int argc, char *argv[]) {
else
pa_log_info(_("Dude, your kernel stinks! The chef's recommendation today is Linux with high-resolution timers enabled!"));
- pa_rtclock_hrtimer_enable();
-
-#ifdef SIGRTMIN
- /* Valgrind uses SIGRTMAX. To easy debugging we don't use it here */
- pa_rtsig_configure(SIGRTMIN, SIGRTMAX-1);
+ if (conf->lock_memory) {
+#ifdef HAVE_SYS_MMAN_H
+ if (mlockall(MCL_FUTURE) < 0)
+ pa_log_warn("mlockall() failed: %s", pa_cstrerror(errno));
+ else
+ pa_log_info("Successfully locked process into memory.");
+#else
+ pa_log_warn("Memory locking requested but not supported on platform.");
#endif
+ }
pa_memtrap_install();
@@ -973,6 +1015,8 @@ int main(int argc, char *argv[]) {
c->default_channel_map = conf->default_channel_map;
c->default_n_fragments = conf->default_n_fragments;
c->default_fragment_size_msec = conf->default_fragment_size_msec;
+ c->sync_volume_safety_margin_usec = conf->sync_volume_safety_margin_usec;
+ c->sync_volume_extra_delay_usec = conf->sync_volume_extra_delay_usec;
c->exit_idle_time = conf->exit_idle_time;
c->scache_idle_time = conf->scache_idle_time;
c->resample_method = conf->resample_method;
@@ -980,9 +1024,22 @@ int main(int argc, char *argv[]) {
c->realtime_scheduling = !!conf->realtime_scheduling;
c->disable_remixing = !!conf->disable_remixing;
c->disable_lfe_remixing = !!conf->disable_lfe_remixing;
+ c->sync_volume = !!conf->sync_volume;
c->running_as_daemon = !!conf->daemonize;
c->disallow_exit = conf->disallow_exit;
c->flat_volumes = conf->flat_volumes;
+#ifdef HAVE_DBUS
+ c->server_type = conf->local_server_type;
+#endif
+
+ c->cpu_info.cpu_type = PA_CPU_UNDEFINED;
+ if (!getenv("PULSE_NO_SIMD")) {
+ if (pa_cpu_init_x86(&(c->cpu_info.flags.x86)))
+ c->cpu_info.cpu_type = PA_CPU_X86;
+ if (pa_cpu_init_arm(&(c->cpu_info.flags.arm)))
+ c->cpu_info.cpu_type = PA_CPU_ARM;
+ pa_cpu_init_orc(c->cpu_info);
+ }
pa_assert_se(pa_signal_init(pa_mainloop_get_api(mainloop)) == 0);
pa_signal_new(SIGINT, signal_callback, c);
@@ -1001,54 +1058,73 @@ int main(int argc, char *argv[]) {
win32_timer = pa_mainloop_get_api(mainloop)->time_new(pa_mainloop_get_api(mainloop), pa_gettimeofday(&win32_tv), message_cb, NULL);
#endif
- oil_init();
-
if (!conf->no_cpu_limit)
pa_assert_se(pa_cpu_limit_init(pa_mainloop_get_api(mainloop)) == 0);
buf = pa_strbuf_new();
- if (conf->load_default_script_file) {
- FILE *f;
- if ((f = pa_daemon_conf_open_default_script_file(conf))) {
- r = pa_cli_command_execute_file_stream(c, f, buf, &conf->fail);
- fclose(f);
+#ifdef HAVE_DBUS
+ if (start_server) {
+#endif
+ if (conf->load_default_script_file) {
+ FILE *f;
+
+ if ((f = pa_daemon_conf_open_default_script_file(conf))) {
+ r = pa_cli_command_execute_file_stream(c, f, buf, &conf->fail);
+ fclose(f);
+ }
}
- }
- if (r >= 0)
- r = pa_cli_command_execute(c, conf->script_commands, buf, &conf->fail);
+ if (r >= 0)
+ r = pa_cli_command_execute(c, conf->script_commands, buf, &conf->fail);
- pa_log_error("%s", s = pa_strbuf_tostring_free(buf));
- pa_xfree(s);
+ pa_log_error("%s", s = pa_strbuf_tostring_free(buf));
+ pa_xfree(s);
+
+ if (r < 0 && conf->fail) {
+ pa_log(_("Failed to initialize daemon."));
+ goto finish;
+ }
+
+ if (!c->modules || pa_idxset_size(c->modules) == 0) {
+ pa_log(_("Daemon startup without any loaded modules, refusing to work."));
+ goto finish;
+ }
+#ifdef HAVE_DBUS
+ } else {
+ /* When we just provide the D-Bus server lookup service, we don't want
+ * any modules to be loaded. We haven't loaded any so far, so one might
+ * think there's no way to contact the server, but receiving certain
+ * signals could still cause modules to load. */
+ conf->disallow_module_loading = TRUE;
+ }
+#endif
/* We completed the initial module loading, so let's disable it
* from now on, if requested */
c->disallow_module_loading = !!conf->disallow_module_loading;
- if (r < 0 && conf->fail) {
- pa_log(_("Failed to initialize daemon."));
- goto finish;
+#ifdef HAVE_DBUS
+ if (!conf->system_instance) {
+ if (!(server_lookup = pa_dbusobj_server_lookup_new(c)))
+ goto finish;
+ if (!(lookup_service_bus = register_dbus_name(c, DBUS_BUS_SESSION, "org.PulseAudio1")))
+ goto finish;
}
- if (!c->modules || pa_idxset_size(c->modules) == 0) {
- pa_log(_("Daemon startup without any loaded modules, refusing to work."));
+ if (start_server && !(server_bus = register_dbus_name(c, conf->system_instance ? DBUS_BUS_SYSTEM : DBUS_BUS_SESSION, "org.pulseaudio.Server")))
goto finish;
- }
+#endif
#ifdef HAVE_FORK
- if (daemon_pipe[1] >= 0) {
+ if (daemon_pipe2[1] >= 0) {
int ok = 0;
- pa_loop_write(daemon_pipe[1], &ok, sizeof(ok), NULL);
- pa_close(daemon_pipe[1]);
- daemon_pipe[1] = -1;
+ pa_loop_write(daemon_pipe2[1], &ok, sizeof(ok), NULL);
+ pa_close(daemon_pipe2[1]);
+ daemon_pipe2[1] = -1;
}
#endif
-#ifdef HAVE_DBUS
- dbus = register_dbus(c);
-#endif
-
pa_log_info(_("Daemon startup complete."));
retval = 0;
@@ -1059,8 +1135,12 @@ int main(int argc, char *argv[]) {
finish:
#ifdef HAVE_DBUS
- if (dbus)
- pa_dbus_connection_unref(dbus);
+ if (server_bus)
+ pa_dbus_connection_unref(server_bus);
+ if (lookup_service_bus)
+ pa_dbus_connection_unref(lookup_service_bus);
+ if (server_lookup)
+ pa_dbusobj_server_lookup_free(server_lookup);
#endif
if (autospawn_fd >= 0) {
@@ -1071,7 +1151,7 @@ finish:
}
#ifdef OS_IS_WIN32
- if (win32_timer)
+ if (mainloop && win32_timer)
pa_mainloop_get_api(mainloop)->time_free(win32_timer);
#endif
@@ -1086,9 +1166,14 @@ finish:
pa_signal_done();
#ifdef HAVE_FORK
+ /* If we have daemon_pipe[1] still open, this means we've failed after
+ * the first fork, but before the second. Therefore just write to it. */
if (daemon_pipe[1] >= 0)
pa_loop_write(daemon_pipe[1], &retval, sizeof(retval), NULL);
+ else if (daemon_pipe2[1] >= 0)
+ pa_loop_write(daemon_pipe2[1], &retval, sizeof(retval), NULL);
+ pa_close_pipe(daemon_pipe2);
pa_close_pipe(daemon_pipe);
#endif
@@ -1101,6 +1186,9 @@ finish:
if (valid_pid_file)
pa_pid_file_remove();
+ /* This has no real purpose except making things valgrind-clean */
+ pa_unset_env_recorded();
+
#ifdef OS_IS_WIN32
WSACleanup();
#endif
diff --git a/src/daemon/org.pulseaudio.policy.in b/src/daemon/org.pulseaudio.policy.in
deleted file mode 100644
index 1d0b6a7d..00000000
--- a/src/daemon/org.pulseaudio.policy.in
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?><!--*-nxml-*-->
-<!DOCTYPE policyconfig PUBLIC
- "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
- "http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
-
-<!--
-This file is part of PulseAudio.
-
-PulseAudio is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License as
-published by the Free Software Foundation; either version 2.1 of the
-License, or (at your option) any later version.
-
-PulseAudio is distributed in the hope that it will be useful, but WITHOUT
-ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
-Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with PulseAudio; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
-USA.
--->
-
-<policyconfig>
- <vendor>The PulseAudio Project</vendor>
- <vendor_url>http://pulseaudio.org/</vendor_url>
- <icon_name>audio-card</icon_name>
-
- <action id="org.pulseaudio.acquire-real-time">
- <_description>Real-time scheduling for the PulseAudio daemon</_description>
- <_message>System policy prevents PulseAudio from acquiring real-time scheduling.</_message>
- <defaults>
- <allow_any>no</allow_any>
- <allow_inactive>no</allow_inactive>
- <allow_active>no</allow_active>
- </defaults>
- </action>
-
- <action id="org.pulseaudio.acquire-high-priority">
- <_description>High-priority scheduling (negative Unix nice level) for the PulseAudio daemon</_description>
- <_message>System policy prevents PulseAudio from acquiring high-priority scheduling.</_message>
- <defaults>
- <allow_any>no</allow_any>
- <allow_inactive>no</allow_inactive>
- <allow_active>no</allow_active>
- </defaults>
- </action>
-
-</policyconfig>
diff --git a/src/daemon/polkit.c b/src/daemon/polkit.c
deleted file mode 100644
index 9799e094..00000000
--- a/src/daemon/polkit.c
+++ /dev/null
@@ -1,172 +0,0 @@
-/***
- This file is part of PulseAudio.
-
- Copyright 2004-2006 Lennart Poettering
- Copyright 2006 Pierre Ossman <ossman@cendio.se> for Cendio AB
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as published
- by the Free Software Foundation; either version 2.1 of the License,
- or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public License
- along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-
-#include <dbus/dbus.h>
-#include <polkit-dbus/polkit-dbus.h>
-
-#include <pulse/i18n.h>
-
-#include <pulsecore/log.h>
-#include <pulsecore/macro.h>
-
-#include "polkit.h"
-
-int pa_polkit_check(const char *action_id) {
- int ret = -1;
- DBusError dbus_error;
- DBusConnection *bus = NULL;
- PolKitCaller *caller = NULL;
- PolKitAction *action = NULL;
- PolKitContext *context = NULL;
- PolKitError *polkit_error = NULL;
- PolKitSession *session = NULL;
- PolKitResult polkit_result;
-
- dbus_error_init(&dbus_error);
-
- if (!(bus = dbus_bus_get(DBUS_BUS_SYSTEM, &dbus_error))) {
- pa_log_error(_("Cannot connect to system bus: %s"), dbus_error.message);
- goto finish;
- }
-
- /* There seems to be a bug in some versions of D-Bus that causes
- * dbus_shutdown() to call exit() when a connection without this
- * flag disabled was created during runtime.*/
- dbus_connection_set_exit_on_disconnect(bus, FALSE);
-
- if (!(caller = polkit_caller_new_from_pid(bus, getpid(), &dbus_error))) {
- pa_log_error(_("Cannot get caller from PID: %s"), dbus_error.message);
- goto finish;
- }
-
- /* This function is called when PulseAudio is called SUID root. We
- * want to authenticate the real user that called us and not the
- * effective user we gained through being SUID root. Hence we
- * overwrite the UID caller data here explicitly, just for
- * paranoia. In fact PolicyKit should fill in the UID here anyway
- * -- an not the EUID or any other user id. */
-
- if (!(polkit_caller_set_uid(caller, getuid()))) {
- pa_log_error(_("Cannot set UID on caller object."));
- goto finish;
- }
-
- if (!(polkit_caller_get_ck_session(caller, &session))) {
- pa_log_error(_("Failed to get CK session."));
- goto finish;
- }
-
- /* We need to overwrite the UID in both the caller and the session
- * object */
-
- if (!(polkit_session_set_uid(session, getuid()))) {
- pa_log_error(_("Cannot set UID on session object."));
- goto finish;
- }
-
- if (!(action = polkit_action_new())) {
- pa_log_error(_("Cannot allocate PolKitAction."));
- goto finish;
- }
-
- if (!polkit_action_set_action_id(action, action_id)) {
- pa_log_error(_("Cannot set action_id"));
- goto finish;
- }
-
- if (!(context = polkit_context_new())) {
- pa_log_error(_("Cannot allocate PolKitContext."));
- goto finish;
- }
-
- if (!polkit_context_init(context, &polkit_error)) {
- pa_log_error(_("Cannot initialize PolKitContext: %s"), polkit_error_get_error_message(polkit_error));
- goto finish;
- }
-
- for (;;) {
-
- polkit_result = polkit_context_is_caller_authorized(context, action, caller, TRUE, &polkit_error);
-
- if (polkit_error_is_set(polkit_error)) {
- pa_log_error(_("Could not determine whether caller is authorized: %s"), polkit_error_get_error_message(polkit_error));
- goto finish;
- }
-
- if (polkit_result == POLKIT_RESULT_ONLY_VIA_ADMIN_AUTH ||
- polkit_result == POLKIT_RESULT_ONLY_VIA_ADMIN_AUTH_KEEP_SESSION ||
- polkit_result == POLKIT_RESULT_ONLY_VIA_ADMIN_AUTH_KEEP_ALWAYS ||
- polkit_result == POLKIT_RESULT_ONLY_VIA_ADMIN_AUTH_ONE_SHOT ||
- polkit_result == POLKIT_RESULT_ONLY_VIA_SELF_AUTH ||
- polkit_result == POLKIT_RESULT_ONLY_VIA_SELF_AUTH_KEEP_SESSION ||
- polkit_result == POLKIT_RESULT_ONLY_VIA_SELF_AUTH_KEEP_ALWAYS ||
- polkit_result == POLKIT_RESULT_ONLY_VIA_SELF_AUTH_ONE_SHOT
- ) {
-
- if (polkit_auth_obtain(action_id, 0, getpid(), &dbus_error)) {
- polkit_result = POLKIT_RESULT_YES;
- break;
- }
-
- if (dbus_error_is_set(&dbus_error)) {
- pa_log_error(_("Cannot obtain auth: %s"), dbus_error.message);
- goto finish;
- }
- }
-
- break;
- }
-
- if (polkit_result != POLKIT_RESULT_YES && polkit_result != POLKIT_RESULT_NO)
- pa_log_warn(_("PolicyKit responded with '%s'"), polkit_result_to_string_representation(polkit_result));
-
- ret = polkit_result == POLKIT_RESULT_YES;
-
-finish:
-
- if (caller)
- polkit_caller_unref(caller);
-
- if (action)
- polkit_action_unref(action);
-
- if (context)
- polkit_context_unref(context);
-
- if (bus)
- dbus_connection_unref(bus);
-
- dbus_error_free(&dbus_error);
-
- if (polkit_error)
- polkit_error_free(polkit_error);
-
- return ret;
-}
diff --git a/src/daemon/pulseaudio-kde.desktop.in b/src/daemon/pulseaudio-kde.desktop.in
new file mode 100644
index 00000000..06846421
--- /dev/null
+++ b/src/daemon/pulseaudio-kde.desktop.in
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Version=1.0
+Encoding=UTF-8
+_Name=PulseAudio Sound System KDE Routing Policy
+_Comment=Start the PulseAudio Sound System with KDE Routing Policy
+Exec=start-pulseaudio-kde
+Terminal=false
+Type=Application
+Categories=
+GenericName=
+OnlyShowIn=KDE;
diff --git a/src/daemon/pulseaudio-system.conf b/src/daemon/pulseaudio-system.conf
new file mode 100644
index 00000000..edddaf93
--- /dev/null
+++ b/src/daemon/pulseaudio-system.conf
@@ -0,0 +1,37 @@
+<?xml version="1.0"?><!--*-nxml-*-->
+<!DOCTYPE busconfig PUBLIC "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
+ "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
+
+<!--
+This file is part of PulseAudio.
+
+PulseAudio is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of the
+License, or (at your option) any later version.
+
+PulseAudio is distributed in the hope that it will be useful, but WITHOUT
+ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
+Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with PulseAudio; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+USA.
+-->
+
+<busconfig>
+
+ <!-- System-wide PulseAudio runs as 'pulse' user. This fragment is
+ not necessary for user PulseAudio instances. -->
+
+ <policy user="pulse">
+ <allow own="org.pulseaudio.Server"/>
+
+ <!-- Allow pulseaudio to talk to HAL for device detection -->
+ <allow send_destination="org.freedesktop.Hal" send_interface="org.freedesktop.Hal.Manager"/>
+ <allow send_destination="org.freedesktop.Hal" send_interface="org.freedesktop.Hal.Device"/>
+ </policy>
+
+</busconfig>
diff --git a/src/daemon/server-lookup.c b/src/daemon/server-lookup.c
new file mode 100644
index 00000000..45796e72
--- /dev/null
+++ b/src/daemon/server-lookup.c
@@ -0,0 +1,522 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulse/client-conf.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/core.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-shared.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "server-lookup.h"
+
+#define OBJECT_PATH "/org/pulseaudio/server_lookup1"
+#define INTERFACE "org.PulseAudio.ServerLookup1"
+
+struct pa_dbusobj_server_lookup {
+ pa_core *core;
+ pa_dbus_connection *conn;
+ pa_bool_t path_registered;
+};
+
+static const char introspection[] =
+ DBUS_INTROSPECT_1_0_XML_DOCTYPE_DECL_NODE
+ "<node>"
+ " <!-- If you are looking for documentation make sure to check out\n"
+ " http://pulseaudio.org/wiki/DBusInterface -->\n"
+ " <interface name=\"" INTERFACE "\">\n"
+ " <property name=\"Address\" type=\"s\" access=\"read\"/>\n"
+ " </interface>\n"
+ " <interface name=\"" DBUS_INTERFACE_INTROSPECTABLE "\">\n"
+ " <method name=\"Introspect\">\n"
+ " <arg name=\"data\" type=\"s\" direction=\"out\"/>\n"
+ " </method>\n"
+ " </interface>\n"
+ " <interface name=\"" DBUS_INTERFACE_PROPERTIES "\">\n"
+ " <method name=\"Get\">\n"
+ " <arg name=\"interface_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"property_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"value\" type=\"v\" direction=\"out\"/>\n"
+ " </method>\n"
+ " <method name=\"Set\">\n"
+ " <arg name=\"interface_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"property_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"value\" type=\"v\" direction=\"in\"/>\n"
+ " </method>\n"
+ " <method name=\"GetAll\">\n"
+ " <arg name=\"interface_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"props\" type=\"a{sv}\" direction=\"out\"/>\n"
+ " </method>\n"
+ " </interface>\n"
+ "</node>\n";
+
+static void unregister_cb(DBusConnection *conn, void *user_data) {
+ pa_dbusobj_server_lookup *sl = user_data;
+
+ pa_assert(sl);
+ pa_assert(sl->path_registered);
+
+ sl->path_registered = FALSE;
+}
+
+static DBusHandlerResult handle_introspect(DBusConnection *conn, DBusMessage *msg, pa_dbusobj_server_lookup *sl) {
+ DBusHandlerResult r = DBUS_HANDLER_RESULT_HANDLED;
+ const char *i = introspection;
+ DBusMessage *reply = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ if (!(reply = dbus_message_new_method_return(msg))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_message_append_args(reply, DBUS_TYPE_STRING, &i, DBUS_TYPE_INVALID)) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+
+finish:
+ if (reply)
+ dbus_message_unref(reply);
+
+ return r;
+}
+
+enum get_address_result_t {
+ SUCCESS,
+ FAILED_TO_LOAD_CLIENT_CONF,
+ SERVER_FROM_TYPE_FAILED
+};
+
+/* Caller frees the returned address. */
+static enum get_address_result_t get_address(pa_server_type_t server_type, char **address) {
+ enum get_address_result_t r = SUCCESS;
+ pa_client_conf *conf = pa_client_conf_new();
+
+ *address = NULL;
+
+ if (pa_client_conf_load(conf, NULL) < 0) {
+ r = FAILED_TO_LOAD_CLIENT_CONF;
+ goto finish;
+ }
+
+ if (conf->default_dbus_server)
+ *address = pa_xstrdup(conf->default_dbus_server);
+ else if (!(*address = pa_get_dbus_address_from_server_type(server_type))) {
+ r = SERVER_FROM_TYPE_FAILED;
+ goto finish;
+ }
+
+finish:
+ pa_client_conf_free(conf);
+ return r;
+}
+
+static DBusHandlerResult handle_get_address(DBusConnection *conn, DBusMessage *msg, pa_dbusobj_server_lookup *sl) {
+ DBusHandlerResult r = DBUS_HANDLER_RESULT_HANDLED;
+ DBusMessage *reply = NULL;
+ char *address = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter variant_iter;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(sl);
+
+ switch (get_address(sl->core->server_type, &address)) {
+ case SUCCESS:
+ if (!(reply = dbus_message_new_method_return(msg))) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ dbus_message_iter_init_append(reply, &msg_iter);
+ if (!dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_VARIANT, "s", &variant_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_append_basic(&variant_iter, DBUS_TYPE_STRING, &address)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_close_container(&msg_iter, &variant_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+
+ case FAILED_TO_LOAD_CLIENT_CONF:
+ if (!(reply = dbus_message_new_error(msg, "org.pulseaudio.ClientConfLoadError", "Failed to load client.conf."))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+
+ case SERVER_FROM_TYPE_FAILED:
+ if (!(reply = dbus_message_new_error(msg, DBUS_ERROR_FAILED, "PulseAudio internal error: get_dbus_server_from_type() failed."))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+
+ default:
+ pa_assert_not_reached();
+ }
+
+finish:
+ pa_xfree(address);
+ if (reply)
+ dbus_message_unref(reply);
+
+ return r;
+}
+
+static DBusHandlerResult handle_get(DBusConnection *conn, DBusMessage *msg, pa_dbusobj_server_lookup *sl) {
+ DBusHandlerResult r = DBUS_HANDLER_RESULT_HANDLED;
+ const char* interface;
+ const char* property;
+ DBusMessage *reply = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(sl);
+
+ if (!dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &interface, DBUS_TYPE_STRING, &property, DBUS_TYPE_INVALID)) {
+ if (!(reply = dbus_message_new_error(msg, DBUS_ERROR_INVALID_ARGS, "Invalid arguments"))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+ }
+
+ if (*interface && !pa_streq(interface, INTERFACE)) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+
+ if (!pa_streq(property, "Address")) {
+ if (!(reply = dbus_message_new_error_printf(msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "%s: No such property", property))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+ }
+
+ r = handle_get_address(conn, msg, sl);
+
+finish:
+ if (reply)
+ dbus_message_unref(reply);
+
+ return r;
+}
+
+static DBusHandlerResult handle_set(DBusConnection *conn, DBusMessage *msg, pa_dbusobj_server_lookup *sl) {
+ DBusHandlerResult r = DBUS_HANDLER_RESULT_HANDLED;
+ const char* interface;
+ const char* property;
+ DBusMessage *reply = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(sl);
+
+ if (!dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &interface, DBUS_TYPE_STRING, &property, DBUS_TYPE_INVALID)) {
+ if (!(reply = dbus_message_new_error(msg, DBUS_ERROR_INVALID_ARGS, "Invalid arguments"))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+ }
+
+ if (*interface && !pa_streq(interface, INTERFACE)) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+
+ if (!pa_streq(property, "Address")) {
+ if (!(reply = dbus_message_new_error_printf(msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "%s: No such property", property))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+ }
+
+ if (!(reply = dbus_message_new_error_printf(msg, DBUS_ERROR_ACCESS_DENIED, "%s: Property not settable", property))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+
+finish:
+ if (reply)
+ dbus_message_unref(reply);
+
+ return r;
+}
+
+static DBusHandlerResult handle_get_all(DBusConnection *conn, DBusMessage *msg, pa_dbusobj_server_lookup *sl) {
+ DBusHandlerResult r = DBUS_HANDLER_RESULT_HANDLED;
+ DBusMessage *reply = NULL;
+ const char *property = "Address";
+ char *interface = NULL;
+ char *address = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ DBusMessageIter dict_entry_iter;
+ DBusMessageIter variant_iter;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(sl);
+
+ if (!dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &interface, DBUS_TYPE_INVALID)) {
+ if (!(reply = dbus_message_new_error(msg, DBUS_ERROR_INVALID_ARGS, "Invalid arguments"))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+ }
+
+ switch (get_address(sl->core->server_type, &address)) {
+ case SUCCESS:
+ if (!(reply = dbus_message_new_method_return(msg))) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ dbus_message_iter_init_append(reply, &msg_iter);
+ if (!dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_open_container(&dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &property)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_open_container(&dict_entry_iter, DBUS_TYPE_VARIANT, "s", &variant_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_append_basic(&variant_iter, DBUS_TYPE_STRING, &address)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_close_container(&dict_entry_iter, &variant_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_close_container(&dict_iter, &dict_entry_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_message_iter_close_container(&msg_iter, &dict_iter)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+
+ case FAILED_TO_LOAD_CLIENT_CONF:
+ if (!(reply = dbus_message_new_error(msg, "org.pulseaudio.ClientConfLoadError", "Failed to load client.conf."))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+
+ case SERVER_FROM_TYPE_FAILED:
+ if (!(reply = dbus_message_new_error(msg, DBUS_ERROR_FAILED, "PulseAudio internal error: get_dbus_server_from_type() failed."))) {
+ r = DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ goto finish;
+ }
+ if (!dbus_connection_send(conn, reply, NULL)) {
+ r = DBUS_HANDLER_RESULT_NEED_MEMORY;
+ goto finish;
+ }
+ r = DBUS_HANDLER_RESULT_HANDLED;
+ goto finish;
+
+ default:
+ pa_assert_not_reached();
+ }
+
+finish:
+ pa_xfree(address);
+ if (reply)
+ dbus_message_unref(reply);
+
+ return r;
+}
+
+static DBusHandlerResult message_cb(DBusConnection *conn, DBusMessage *msg, void *user_data) {
+ pa_dbusobj_server_lookup *sl = user_data;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(sl);
+
+ /* pa_log("Got message! type = %s path = %s iface = %s member = %s dest = %s", dbus_message_type_to_string(dbus_message_get_type(msg)), dbus_message_get_path(msg), dbus_message_get_interface(msg), dbus_message_get_member(msg), dbus_message_get_destination(msg)); */
+
+ if (dbus_message_get_type(msg) != DBUS_MESSAGE_TYPE_METHOD_CALL)
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+
+ if (dbus_message_is_method_call(msg, DBUS_INTERFACE_INTROSPECTABLE, "Introspect") ||
+ (!dbus_message_get_interface(msg) && dbus_message_has_member(msg, "Introspect")))
+ return handle_introspect(conn, msg, sl);
+
+ if (dbus_message_is_method_call(msg, DBUS_INTERFACE_PROPERTIES, "Get") ||
+ (!dbus_message_get_interface(msg) && dbus_message_has_member(msg, "Get")))
+ return handle_get(conn, msg, sl);
+
+ if (dbus_message_is_method_call(msg, DBUS_INTERFACE_PROPERTIES, "Set") ||
+ (!dbus_message_get_interface(msg) && dbus_message_has_member(msg, "Set")))
+ return handle_set(conn, msg, sl);
+
+ if (dbus_message_is_method_call(msg, DBUS_INTERFACE_PROPERTIES, "GetAll") ||
+ (!dbus_message_get_interface(msg) && dbus_message_has_member(msg, "GetAll")))
+ return handle_get_all(conn, msg, sl);
+
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+}
+
+static DBusObjectPathVTable vtable = {
+ .unregister_function = unregister_cb,
+ .message_function = message_cb,
+ .dbus_internal_pad1 = NULL,
+ .dbus_internal_pad2 = NULL,
+ .dbus_internal_pad3 = NULL,
+ .dbus_internal_pad4 = NULL
+};
+
+pa_dbusobj_server_lookup *pa_dbusobj_server_lookup_new(pa_core *c) {
+ pa_dbusobj_server_lookup *sl;
+ DBusError error;
+
+ dbus_error_init(&error);
+
+ sl = pa_xnew(pa_dbusobj_server_lookup, 1);
+ sl->core = c;
+ sl->path_registered = FALSE;
+
+ if (!(sl->conn = pa_dbus_bus_get(c, DBUS_BUS_SESSION, &error)) || dbus_error_is_set(&error)) {
+ pa_log("Unable to contact D-Bus: %s: %s", error.name, error.message);
+ goto fail;
+ }
+
+ if (!dbus_connection_register_object_path(pa_dbus_connection_get(sl->conn), OBJECT_PATH, &vtable, sl)) {
+ pa_log("dbus_connection_register_object_path() failed for " OBJECT_PATH ".");
+ goto fail;
+ }
+
+ sl->path_registered = TRUE;
+
+ return sl;
+
+fail:
+ dbus_error_free(&error);
+
+ pa_dbusobj_server_lookup_free(sl);
+
+ return NULL;
+}
+
+void pa_dbusobj_server_lookup_free(pa_dbusobj_server_lookup *sl) {
+ pa_assert(sl);
+
+ if (sl->path_registered) {
+ pa_assert(sl->conn);
+ if (!dbus_connection_unregister_object_path(pa_dbus_connection_get(sl->conn), OBJECT_PATH))
+ pa_log_debug("dbus_connection_unregister_object_path() failed for " OBJECT_PATH ".");
+ }
+
+ if (sl->conn)
+ pa_dbus_connection_unref(sl->conn);
+
+ pa_xfree(sl);
+}
diff --git a/src/daemon/server-lookup.h b/src/daemon/server-lookup.h
new file mode 100644
index 00000000..c930d5b7
--- /dev/null
+++ b/src/daemon/server-lookup.h
@@ -0,0 +1,40 @@
+#ifndef fooserverlookuphfoo
+#define fooserverlookuphfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus object at path
+ * /org/pulseaudio/server_lookup. Implemented interfaces
+ * are org.pulseaudio.ServerLookup and org.freedesktop.DBus.Introspectable.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the ServerLookup interface
+ * documentation.
+ */
+
+#include <pulsecore/core.h>
+
+typedef struct pa_dbusobj_server_lookup pa_dbusobj_server_lookup;
+
+pa_dbusobj_server_lookup *pa_dbusobj_server_lookup_new(pa_core *c);
+void pa_dbusobj_server_lookup_free(pa_dbusobj_server_lookup *sl);
+
+#endif
diff --git a/src/daemon/start-pulseaudio-kde.in b/src/daemon/start-pulseaudio-kde.in
new file mode 100755
index 00000000..c319e7dd
--- /dev/null
+++ b/src/daemon/start-pulseaudio-kde.in
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+# USA.
+
+set -e
+
+[ -z "$PULSE_SERVER" ]
+
+@PA_BINARY@ --start "$@"
+
+if [ x"$DISPLAY" != x ] ; then
+
+ @PACTL_BINARY@ load-module module-device-manager "do_routing=1" > /dev/null
+
+fi
diff --git a/src/daemon/start-pulseaudio-x11.in b/src/daemon/start-pulseaudio-x11.in
index c57c489d..391a6d3c 100755
--- a/src/daemon/start-pulseaudio-x11.in
+++ b/src/daemon/start-pulseaudio-x11.in
@@ -19,8 +19,6 @@
set -e
-[ -z "$PULSE_SERVER" ]
-
@PA_BINARY@ --start "$@"
if [ x"$DISPLAY" != x ] ; then
diff --git a/src/daemon/system.pa.in b/src/daemon/system.pa.in
index 5541bbe4..aaefd1d1 100755
--- a/src/daemon/system.pa.in
+++ b/src/daemon/system.pa.in
@@ -20,11 +20,11 @@
# mode.
### Automatically load driver modules depending on the hardware available
-.ifexists module-hal-detect@PA_SOEXT@
-load-module module-hal-detect
+.ifexists module-udev-detect@PA_SOEXT@
+load-module module-udev-detect
.else
### Alternatively use the static hardware detection module (for systems that
-### lack HAL support)
+### lack udev support)
load-module module-detect
.endif
@@ -33,7 +33,8 @@ load-module module-detect
load-module module-esound-protocol-unix
.endif
.ifexists module-dbus-protocol@PA_SOEXT@
-load-module module-dbus-protocol
+### If you want to allow TCP connections, set access to "remote" or "local,remote".
+load-module module-dbus-protocol access=local
.endif
load-module module-native-protocol-unix
diff --git a/src/map-file b/src/map-file
index c46c6792..d9c3e9f6 100644
--- a/src/map-file
+++ b/src/map-file
@@ -2,12 +2,6 @@ PULSE_0 {
global:
pa_ascii_filter;
pa_ascii_valid;
-pa_browser_new;
-pa_browser_new_full;
-pa_browser_ref;
-pa_browser_set_callback;
-pa_browser_set_error_callback;
-pa_browser_unref;
pa_bytes_per_second;
pa_bytes_snprint;
pa_bytes_to_usec;
@@ -28,6 +22,7 @@ pa_channel_map_superset;
pa_channel_map_to_name;
pa_channel_map_to_pretty_name;
pa_channel_map_valid;
+pa_channel_position_from_string;
pa_channel_position_to_pretty_string;
pa_channel_position_to_string;
pa_context_add_autoload;
@@ -65,6 +60,7 @@ pa_context_get_source_info_list;
pa_context_get_source_output_info;
pa_context_get_source_output_info_list;
pa_context_get_state;
+pa_context_get_tile_size;
pa_context_is_local;
pa_context_is_pending;
pa_context_kill_client;
@@ -85,6 +81,8 @@ pa_context_ref;
pa_context_remove_autoload_by_index;
pa_context_remove_autoload_by_name;
pa_context_remove_sample;
+pa_context_rttime_new;
+pa_context_rttime_restart;
pa_context_set_card_profile_by_index;
pa_context_set_card_profile_by_name;
pa_context_set_default_sink;
@@ -95,10 +93,16 @@ pa_context_set_sink_input_mute;
pa_context_set_sink_input_volume;
pa_context_set_sink_mute_by_index;
pa_context_set_sink_mute_by_name;
+pa_context_set_sink_port_by_index;
+pa_context_set_sink_port_by_name;
pa_context_set_sink_volume_by_index;
pa_context_set_sink_volume_by_name;
+pa_context_set_source_output_mute;
+pa_context_set_source_output_volume;
pa_context_set_source_mute_by_index;
pa_context_set_source_mute_by_name;
+pa_context_set_source_port_by_index;
+pa_context_set_source_port_by_name;
pa_context_set_source_volume_by_index;
pa_context_set_source_volume_by_name;
pa_context_set_state_callback;
@@ -116,13 +120,19 @@ pa_cvolume_avg_mask;
pa_cvolume_channels_equal_to;
pa_cvolume_compatible;
pa_cvolume_compatible_with_channel_map;
+pa_cvolume_dec;
pa_cvolume_equal;
pa_cvolume_get_balance;
pa_cvolume_get_fade;
pa_cvolume_get_position;
+pa_cvolume_inc;
+pa_cvolume_inc_clamp;
pa_cvolume_init;
pa_cvolume_max;
pa_cvolume_max_mask;
+pa_cvolume_merge;
+pa_cvolume_min;
+pa_cvolume_min_mask;
pa_cvolume_remap;
pa_cvolume_scale;
pa_cvolume_scale_mask;
@@ -132,12 +142,42 @@ pa_cvolume_set_fade;
pa_cvolume_set_position;
pa_cvolume_snprint;
pa_cvolume_valid;
+pa_encoding_to_string;
+pa_ext_device_manager_delete;
+pa_ext_device_manager_enable_role_device_priority_routing;
+pa_ext_device_manager_read;
+pa_ext_device_manager_reorder_devices_for_role;
+pa_ext_device_manager_set_device_description;
+pa_ext_device_manager_set_subscribe_cb;
+pa_ext_device_manager_subscribe;
+pa_ext_device_manager_test;
+pa_ext_device_restore_read_sink_formats;
+pa_ext_device_restore_read_sink_formats_all;
+pa_ext_device_restore_save_sink_formats;
+pa_ext_device_restore_subscribe;
+pa_ext_device_restore_test;
pa_ext_stream_restore_delete;
pa_ext_stream_restore_read;
pa_ext_stream_restore_set_subscribe_cb;
pa_ext_stream_restore_subscribe;
pa_ext_stream_restore_test;
pa_ext_stream_restore_write;
+pa_format_info_copy;
+pa_format_info_free;
+pa_format_info_is_compatible;
+pa_format_info_is_pcm;
+pa_format_info_new;
+pa_format_info_set_channel_map;
+pa_format_info_set_channels;
+pa_format_info_set_prop_int;
+pa_format_info_set_prop_int_array;
+pa_format_info_set_prop_int_range;
+pa_format_info_set_prop_string;
+pa_format_info_set_prop_string_array;
+pa_format_info_set_rate;
+pa_format_info_set_sample_format;
+pa_format_info_snprint;
+pa_format_info_valid;
pa_frame_size;
pa_get_binary_name;
pa_get_fqdn;
@@ -173,6 +213,7 @@ pa_path_get_filename;
pa_proplist_clear;
pa_proplist_contains;
pa_proplist_copy;
+pa_proplist_equal;
pa_proplist_free;
pa_proplist_from_string;
pa_proplist_get;
@@ -190,6 +231,7 @@ pa_proplist_to_string_sep;
pa_proplist_unset;
pa_proplist_unset_many;
pa_proplist_update;
+pa_rtclock_now;
pa_sample_format_is_be;
pa_sample_format_is_le;
pa_sample_format_to_string;
@@ -211,6 +253,8 @@ pa_simple_get_latency;
pa_simple_new;
pa_simple_read;
pa_simple_write;
+pa_stream_begin_write;
+pa_stream_cancel_write;
pa_stream_connect_playback;
pa_stream_connect_record;
pa_stream_connect_upload;
@@ -225,6 +269,7 @@ pa_stream_get_channel_map;
pa_stream_get_context;
pa_stream_get_device_index;
pa_stream_get_device_name;
+pa_stream_get_format_info;
pa_stream_get_index;
pa_stream_get_latency;
pa_stream_get_monitor_stream;
@@ -235,6 +280,7 @@ pa_stream_get_timing_info;
pa_stream_is_corked;
pa_stream_is_suspended;
pa_stream_new;
+pa_stream_new_extended;
pa_stream_new_with_proplist;
pa_stream_peek;
pa_stream_prebuf;
@@ -264,7 +310,9 @@ pa_stream_writable_size;
pa_stream_write;
pa_strerror;
pa_sw_cvolume_divide;
+pa_sw_cvolume_divide_scalar;
pa_sw_cvolume_multiply;
+pa_sw_cvolume_multiply_scalar;
pa_sw_cvolume_snprint_dB;
pa_sw_volume_divide;
pa_sw_volume_from_dB;
diff --git a/src/modules/.gitignore b/src/modules/.gitignore
deleted file mode 100644
index 2d2d942d..00000000
--- a/src/modules/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-module-*-symdef.h
diff --git a/src/modules/Makefile b/src/modules/Makefile
deleted file mode 120000
index c110232d..00000000
--- a/src/modules/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../pulse/Makefile \ No newline at end of file
diff --git a/src/modules/alsa/Makefile b/src/modules/alsa/Makefile
deleted file mode 120000
index efe5a336..00000000
--- a/src/modules/alsa/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../../pulse/Makefile \ No newline at end of file
diff --git a/src/modules/alsa/alsa-mixer.c b/src/modules/alsa/alsa-mixer.c
new file mode 100644
index 00000000..348f037f
--- /dev/null
+++ b/src/modules/alsa/alsa-mixer.c
@@ -0,0 +1,4194 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2009 Lennart Poettering
+ Copyright 2006 Pierre Ossman <ossman@cendio.se> for Cendio AB
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <sys/types.h>
+#include <asoundlib.h>
+#include <math.h>
+
+#ifdef HAVE_VALGRIND_MEMCHECK_H
+#include <valgrind/memcheck.h>
+#endif
+
+#include <pulse/mainloop-api.h>
+#include <pulse/sample.h>
+#include <pulse/timeval.h>
+#include <pulse/util.h>
+#include <pulse/volume.h>
+#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
+#include <pulse/utf8.h>
+
+#include <pulsecore/log.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/conf-parser.h>
+#include <pulsecore/strbuf.h>
+
+#include "alsa-mixer.h"
+#include "alsa-util.h"
+
+struct description_map {
+ const char *name;
+ const char *description;
+};
+
+static const char *lookup_description(const char *name, const struct description_map dm[], unsigned n) {
+ unsigned i;
+
+ for (i = 0; i < n; i++)
+ if (pa_streq(dm[i].name, name))
+ return _(dm[i].description);
+
+ return NULL;
+}
+
+struct pa_alsa_fdlist {
+ unsigned num_fds;
+ struct pollfd *fds;
+ /* This is a temporary buffer used to avoid lots of mallocs */
+ struct pollfd *work_fds;
+
+ snd_mixer_t *mixer;
+
+ pa_mainloop_api *m;
+ pa_defer_event *defer;
+ pa_io_event **ios;
+
+ pa_bool_t polled;
+
+ void (*cb)(void *userdata);
+ void *userdata;
+};
+
+static void io_cb(pa_mainloop_api *a, pa_io_event *e, int fd, pa_io_event_flags_t events, void *userdata) {
+
+ struct pa_alsa_fdlist *fdl = userdata;
+ int err;
+ unsigned i;
+ unsigned short revents;
+
+ pa_assert(a);
+ pa_assert(fdl);
+ pa_assert(fdl->mixer);
+ pa_assert(fdl->fds);
+ pa_assert(fdl->work_fds);
+
+ if (fdl->polled)
+ return;
+
+ fdl->polled = TRUE;
+
+ memcpy(fdl->work_fds, fdl->fds, sizeof(struct pollfd) * fdl->num_fds);
+
+ for (i = 0; i < fdl->num_fds; i++) {
+ if (e == fdl->ios[i]) {
+ if (events & PA_IO_EVENT_INPUT)
+ fdl->work_fds[i].revents |= POLLIN;
+ if (events & PA_IO_EVENT_OUTPUT)
+ fdl->work_fds[i].revents |= POLLOUT;
+ if (events & PA_IO_EVENT_ERROR)
+ fdl->work_fds[i].revents |= POLLERR;
+ if (events & PA_IO_EVENT_HANGUP)
+ fdl->work_fds[i].revents |= POLLHUP;
+ break;
+ }
+ }
+
+ pa_assert(i != fdl->num_fds);
+
+ if ((err = snd_mixer_poll_descriptors_revents(fdl->mixer, fdl->work_fds, fdl->num_fds, &revents)) < 0) {
+ pa_log_error("Unable to get poll revent: %s", pa_alsa_strerror(err));
+ return;
+ }
+
+ a->defer_enable(fdl->defer, 1);
+
+ if (revents)
+ snd_mixer_handle_events(fdl->mixer);
+}
+
+static void defer_cb(pa_mainloop_api *a, pa_defer_event *e, void *userdata) {
+ struct pa_alsa_fdlist *fdl = userdata;
+ unsigned num_fds, i;
+ int err, n;
+ struct pollfd *temp;
+
+ pa_assert(a);
+ pa_assert(fdl);
+ pa_assert(fdl->mixer);
+
+ a->defer_enable(fdl->defer, 0);
+
+ if ((n = snd_mixer_poll_descriptors_count(fdl->mixer)) < 0) {
+ pa_log("snd_mixer_poll_descriptors_count() failed: %s", pa_alsa_strerror(n));
+ return;
+ }
+ num_fds = (unsigned) n;
+
+ if (num_fds != fdl->num_fds) {
+ if (fdl->fds)
+ pa_xfree(fdl->fds);
+ if (fdl->work_fds)
+ pa_xfree(fdl->work_fds);
+ fdl->fds = pa_xnew0(struct pollfd, num_fds);
+ fdl->work_fds = pa_xnew(struct pollfd, num_fds);
+ }
+
+ memset(fdl->work_fds, 0, sizeof(struct pollfd) * num_fds);
+
+ if ((err = snd_mixer_poll_descriptors(fdl->mixer, fdl->work_fds, num_fds)) < 0) {
+ pa_log_error("Unable to get poll descriptors: %s", pa_alsa_strerror(err));
+ return;
+ }
+
+ fdl->polled = FALSE;
+
+ if (memcmp(fdl->fds, fdl->work_fds, sizeof(struct pollfd) * num_fds) == 0)
+ return;
+
+ if (fdl->ios) {
+ for (i = 0; i < fdl->num_fds; i++)
+ a->io_free(fdl->ios[i]);
+
+ if (num_fds != fdl->num_fds) {
+ pa_xfree(fdl->ios);
+ fdl->ios = NULL;
+ }
+ }
+
+ if (!fdl->ios)
+ fdl->ios = pa_xnew(pa_io_event*, num_fds);
+
+ /* Swap pointers */
+ temp = fdl->work_fds;
+ fdl->work_fds = fdl->fds;
+ fdl->fds = temp;
+
+ fdl->num_fds = num_fds;
+
+ for (i = 0;i < num_fds;i++)
+ fdl->ios[i] = a->io_new(a, fdl->fds[i].fd,
+ ((fdl->fds[i].events & POLLIN) ? PA_IO_EVENT_INPUT : 0) |
+ ((fdl->fds[i].events & POLLOUT) ? PA_IO_EVENT_OUTPUT : 0),
+ io_cb, fdl);
+}
+
+struct pa_alsa_fdlist *pa_alsa_fdlist_new(void) {
+ struct pa_alsa_fdlist *fdl;
+
+ fdl = pa_xnew0(struct pa_alsa_fdlist, 1);
+
+ return fdl;
+}
+
+void pa_alsa_fdlist_free(struct pa_alsa_fdlist *fdl) {
+ pa_assert(fdl);
+
+ if (fdl->defer) {
+ pa_assert(fdl->m);
+ fdl->m->defer_free(fdl->defer);
+ }
+
+ if (fdl->ios) {
+ unsigned i;
+ pa_assert(fdl->m);
+ for (i = 0; i < fdl->num_fds; i++)
+ fdl->m->io_free(fdl->ios[i]);
+ pa_xfree(fdl->ios);
+ }
+
+ if (fdl->fds)
+ pa_xfree(fdl->fds);
+ if (fdl->work_fds)
+ pa_xfree(fdl->work_fds);
+
+ pa_xfree(fdl);
+}
+
+int pa_alsa_fdlist_set_mixer(struct pa_alsa_fdlist *fdl, snd_mixer_t *mixer_handle, pa_mainloop_api *m) {
+ pa_assert(fdl);
+ pa_assert(mixer_handle);
+ pa_assert(m);
+ pa_assert(!fdl->m);
+
+ fdl->mixer = mixer_handle;
+ fdl->m = m;
+ fdl->defer = m->defer_new(m, defer_cb, fdl);
+
+ return 0;
+}
+
+struct pa_alsa_mixer_pdata {
+ pa_rtpoll *rtpoll;
+ pa_rtpoll_item *poll_item;
+ snd_mixer_t *mixer;
+};
+
+
+struct pa_alsa_mixer_pdata *pa_alsa_mixer_pdata_new(void) {
+ struct pa_alsa_mixer_pdata *pd;
+
+ pd = pa_xnew0(struct pa_alsa_mixer_pdata, 1);
+
+ return pd;
+}
+
+void pa_alsa_mixer_pdata_free(struct pa_alsa_mixer_pdata *pd) {
+ pa_assert(pd);
+
+ if (pd->poll_item) {
+ pa_rtpoll_item_free(pd->poll_item);
+ }
+
+ pa_xfree(pd);
+}
+
+static int rtpoll_work_cb(pa_rtpoll_item *i) {
+ struct pa_alsa_mixer_pdata *pd;
+ struct pollfd *p;
+ unsigned n_fds;
+ unsigned short revents = 0;
+ int err;
+
+ pd = pa_rtpoll_item_get_userdata(i);
+ pa_assert_fp(pd);
+ pa_assert_fp(i == pd->poll_item);
+
+ p = pa_rtpoll_item_get_pollfd(i, &n_fds);
+
+ if ((err = snd_mixer_poll_descriptors_revents(pd->mixer, p, n_fds, &revents)) < 0) {
+ pa_log_error("Unable to get poll revent: %s", pa_alsa_strerror(err));
+ pa_rtpoll_item_free(i);
+ return -1;
+ }
+
+ if (revents) {
+ snd_mixer_handle_events(pd->mixer);
+ pa_rtpoll_item_free(i);
+ pa_alsa_set_mixer_rtpoll(pd, pd->mixer, pd->rtpoll);
+ }
+
+ return 0;
+}
+
+int pa_alsa_set_mixer_rtpoll(struct pa_alsa_mixer_pdata *pd, snd_mixer_t *mixer, pa_rtpoll *rtp) {
+ pa_rtpoll_item *i;
+ struct pollfd *p;
+ int err, n;
+
+ pa_assert(pd);
+ pa_assert(mixer);
+ pa_assert(rtp);
+
+ if ((n = snd_mixer_poll_descriptors_count(mixer)) < 0) {
+ pa_log("snd_mixer_poll_descriptors_count() failed: %s", pa_alsa_strerror(n));
+ return -1;
+ }
+
+ i = pa_rtpoll_item_new(rtp, PA_RTPOLL_LATE, (unsigned) n);
+
+ p = pa_rtpoll_item_get_pollfd(i, NULL);
+
+ memset(p, 0, sizeof(struct pollfd) * n);
+
+ if ((err = snd_mixer_poll_descriptors(mixer, p, (unsigned) n)) < 0) {
+ pa_log_error("Unable to get poll descriptors: %s", pa_alsa_strerror(err));
+ pa_rtpoll_item_free(i);
+ return -1;
+ }
+
+ pd->rtpoll = rtp;
+ pd->poll_item = i;
+ pd->mixer = mixer;
+
+ pa_rtpoll_item_set_userdata(i, pd);
+ pa_rtpoll_item_set_work_callback(i, rtpoll_work_cb);
+
+ return 0;
+}
+
+static int prepare_mixer(snd_mixer_t *mixer, const char *dev) {
+ int err;
+
+ pa_assert(mixer);
+ pa_assert(dev);
+
+ if ((err = snd_mixer_attach(mixer, dev)) < 0) {
+ pa_log_info("Unable to attach to mixer %s: %s", dev, pa_alsa_strerror(err));
+ return -1;
+ }
+
+ if ((err = snd_mixer_selem_register(mixer, NULL, NULL)) < 0) {
+ pa_log_warn("Unable to register mixer: %s", pa_alsa_strerror(err));
+ return -1;
+ }
+
+ if ((err = snd_mixer_load(mixer)) < 0) {
+ pa_log_warn("Unable to load mixer: %s", pa_alsa_strerror(err));
+ return -1;
+ }
+
+ pa_log_info("Successfully attached to mixer '%s'", dev);
+ return 0;
+}
+
+snd_mixer_t *pa_alsa_open_mixer_for_pcm(snd_pcm_t *pcm, char **ctl_device) {
+ int err;
+ snd_mixer_t *m;
+ const char *dev;
+ snd_pcm_info_t* info;
+ snd_pcm_info_alloca(&info);
+
+ pa_assert(pcm);
+
+ if ((err = snd_mixer_open(&m, 0)) < 0) {
+ pa_log("Error opening mixer: %s", pa_alsa_strerror(err));
+ return NULL;
+ }
+
+ /* First, try by name */
+ if ((dev = snd_pcm_name(pcm)))
+ if (prepare_mixer(m, dev) >= 0) {
+ if (ctl_device)
+ *ctl_device = pa_xstrdup(dev);
+
+ return m;
+ }
+
+ /* Then, try by card index */
+ if (snd_pcm_info(pcm, info) >= 0) {
+ char *md;
+ int card_idx;
+
+ if ((card_idx = snd_pcm_info_get_card(info)) >= 0) {
+
+ md = pa_sprintf_malloc("hw:%i", card_idx);
+
+ if (!dev || !pa_streq(dev, md))
+ if (prepare_mixer(m, md) >= 0) {
+
+ if (ctl_device)
+ *ctl_device = md;
+ else
+ pa_xfree(md);
+
+ return m;
+ }
+
+ pa_xfree(md);
+ }
+ }
+
+ snd_mixer_close(m);
+ return NULL;
+}
+
+static const snd_mixer_selem_channel_id_t alsa_channel_ids[PA_CHANNEL_POSITION_MAX] = {
+ [PA_CHANNEL_POSITION_MONO] = SND_MIXER_SCHN_MONO, /* The ALSA name is just an alias! */
+
+ [PA_CHANNEL_POSITION_FRONT_CENTER] = SND_MIXER_SCHN_FRONT_CENTER,
+ [PA_CHANNEL_POSITION_FRONT_LEFT] = SND_MIXER_SCHN_FRONT_LEFT,
+ [PA_CHANNEL_POSITION_FRONT_RIGHT] = SND_MIXER_SCHN_FRONT_RIGHT,
+
+ [PA_CHANNEL_POSITION_REAR_CENTER] = SND_MIXER_SCHN_REAR_CENTER,
+ [PA_CHANNEL_POSITION_REAR_LEFT] = SND_MIXER_SCHN_REAR_LEFT,
+ [PA_CHANNEL_POSITION_REAR_RIGHT] = SND_MIXER_SCHN_REAR_RIGHT,
+
+ [PA_CHANNEL_POSITION_LFE] = SND_MIXER_SCHN_WOOFER,
+
+ [PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER] = SND_MIXER_SCHN_UNKNOWN,
+
+ [PA_CHANNEL_POSITION_SIDE_LEFT] = SND_MIXER_SCHN_SIDE_LEFT,
+ [PA_CHANNEL_POSITION_SIDE_RIGHT] = SND_MIXER_SCHN_SIDE_RIGHT,
+
+ [PA_CHANNEL_POSITION_AUX0] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX1] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX2] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX3] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX4] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX5] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX6] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX7] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX8] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX9] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX10] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX11] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX12] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX13] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX14] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX15] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX16] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX17] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX18] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX19] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX20] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX21] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX22] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX23] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX24] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX25] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX26] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX27] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX28] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX29] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX30] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_AUX31] = SND_MIXER_SCHN_UNKNOWN,
+
+ [PA_CHANNEL_POSITION_TOP_CENTER] = SND_MIXER_SCHN_UNKNOWN,
+
+ [PA_CHANNEL_POSITION_TOP_FRONT_CENTER] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_TOP_FRONT_LEFT] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_TOP_FRONT_RIGHT] = SND_MIXER_SCHN_UNKNOWN,
+
+ [PA_CHANNEL_POSITION_TOP_REAR_CENTER] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_TOP_REAR_LEFT] = SND_MIXER_SCHN_UNKNOWN,
+ [PA_CHANNEL_POSITION_TOP_REAR_RIGHT] = SND_MIXER_SCHN_UNKNOWN
+};
+
+static void setting_free(pa_alsa_setting *s) {
+ pa_assert(s);
+
+ if (s->options)
+ pa_idxset_free(s->options, NULL, NULL);
+
+ pa_xfree(s->name);
+ pa_xfree(s->description);
+ pa_xfree(s);
+}
+
+static void option_free(pa_alsa_option *o) {
+ pa_assert(o);
+
+ pa_xfree(o->alsa_name);
+ pa_xfree(o->name);
+ pa_xfree(o->description);
+ pa_xfree(o);
+}
+
+static void decibel_fix_free(pa_alsa_decibel_fix *db_fix) {
+ pa_assert(db_fix);
+
+ pa_xfree(db_fix->name);
+ pa_xfree(db_fix->db_values);
+
+ pa_xfree(db_fix);
+}
+
+static void element_free(pa_alsa_element *e) {
+ pa_alsa_option *o;
+ pa_assert(e);
+
+ while ((o = e->options)) {
+ PA_LLIST_REMOVE(pa_alsa_option, e->options, o);
+ option_free(o);
+ }
+
+ if (e->db_fix)
+ decibel_fix_free(e->db_fix);
+
+ pa_xfree(e->alsa_name);
+ pa_xfree(e);
+}
+
+void pa_alsa_path_free(pa_alsa_path *p) {
+ pa_alsa_element *e;
+ pa_alsa_setting *s;
+
+ pa_assert(p);
+
+ while ((e = p->elements)) {
+ PA_LLIST_REMOVE(pa_alsa_element, p->elements, e);
+ element_free(e);
+ }
+
+ while ((s = p->settings)) {
+ PA_LLIST_REMOVE(pa_alsa_setting, p->settings, s);
+ setting_free(s);
+ }
+
+ pa_xfree(p->name);
+ pa_xfree(p->description);
+ pa_xfree(p);
+}
+
+void pa_alsa_path_set_free(pa_alsa_path_set *ps) {
+ pa_alsa_path *p;
+ pa_assert(ps);
+
+ while ((p = ps->paths)) {
+ PA_LLIST_REMOVE(pa_alsa_path, ps->paths, p);
+ pa_alsa_path_free(p);
+ }
+
+ pa_xfree(ps);
+}
+
+static long to_alsa_dB(pa_volume_t v) {
+ return (long) (pa_sw_volume_to_dB(v) * 100.0);
+}
+
+static pa_volume_t from_alsa_dB(long v) {
+ return pa_sw_volume_from_dB((double) v / 100.0);
+}
+
+static long to_alsa_volume(pa_volume_t v, long min, long max) {
+ long w;
+
+ w = (long) round(((double) v * (double) (max - min)) / PA_VOLUME_NORM) + min;
+ return PA_CLAMP_UNLIKELY(w, min, max);
+}
+
+static pa_volume_t from_alsa_volume(long v, long min, long max) {
+ return (pa_volume_t) round(((double) (v - min) * PA_VOLUME_NORM) / (double) (max - min));
+}
+
+#define SELEM_INIT(sid, name) \
+ do { \
+ snd_mixer_selem_id_alloca(&(sid)); \
+ snd_mixer_selem_id_set_name((sid), (name)); \
+ snd_mixer_selem_id_set_index((sid), 0); \
+ } while(FALSE)
+
+static int element_get_volume(pa_alsa_element *e, snd_mixer_t *m, const pa_channel_map *cm, pa_cvolume *v) {
+ snd_mixer_selem_id_t *sid;
+ snd_mixer_elem_t *me;
+ snd_mixer_selem_channel_id_t c;
+ pa_channel_position_mask_t mask = 0;
+ unsigned k;
+
+ pa_assert(m);
+ pa_assert(e);
+ pa_assert(cm);
+ pa_assert(v);
+
+ SELEM_INIT(sid, e->alsa_name);
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+ pa_log_warn("Element %s seems to have disappeared.", e->alsa_name);
+ return -1;
+ }
+
+ pa_cvolume_mute(v, cm->channels);
+
+ /* We take the highest volume of all channels that match */
+
+ for (c = 0; c <= SND_MIXER_SCHN_LAST; c++) {
+ int r;
+ pa_volume_t f;
+
+ if (e->has_dB) {
+ long value = 0;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ if (snd_mixer_selem_has_playback_channel(me, c)) {
+ if (e->db_fix) {
+ if ((r = snd_mixer_selem_get_playback_volume(me, c, &value)) >= 0) {
+ /* If the channel volume is outside the limits set
+ * by the dB fix, we clamp the hw volume to be
+ * within the limits. */
+ if (value < e->db_fix->min_step) {
+ value = e->db_fix->min_step;
+ snd_mixer_selem_set_playback_volume(me, c, value);
+ pa_log_debug("Playback volume for element %s channel %i was below the dB fix limit. "
+ "Volume reset to %0.2f dB.", e->alsa_name, c,
+ e->db_fix->db_values[value - e->db_fix->min_step] / 100.0);
+ } else if (value > e->db_fix->max_step) {
+ value = e->db_fix->max_step;
+ snd_mixer_selem_set_playback_volume(me, c, value);
+ pa_log_debug("Playback volume for element %s channel %i was over the dB fix limit. "
+ "Volume reset to %0.2f dB.", e->alsa_name, c,
+ e->db_fix->db_values[value - e->db_fix->min_step] / 100.0);
+ }
+
+ /* Volume step -> dB value conversion. */
+ value = e->db_fix->db_values[value - e->db_fix->min_step];
+ }
+ } else
+ r = snd_mixer_selem_get_playback_dB(me, c, &value);
+ } else
+ r = -1;
+ } else {
+ if (snd_mixer_selem_has_capture_channel(me, c)) {
+ if (e->db_fix) {
+ if ((r = snd_mixer_selem_get_capture_volume(me, c, &value)) >= 0) {
+ /* If the channel volume is outside the limits set
+ * by the dB fix, we clamp the hw volume to be
+ * within the limits. */
+ if (value < e->db_fix->min_step) {
+ value = e->db_fix->min_step;
+ snd_mixer_selem_set_capture_volume(me, c, value);
+ pa_log_debug("Capture volume for element %s channel %i was below the dB fix limit. "
+ "Volume reset to %0.2f dB.", e->alsa_name, c,
+ e->db_fix->db_values[value - e->db_fix->min_step] / 100.0);
+ } else if (value > e->db_fix->max_step) {
+ value = e->db_fix->max_step;
+ snd_mixer_selem_set_capture_volume(me, c, value);
+ pa_log_debug("Capture volume for element %s channel %i was over the dB fix limit. "
+ "Volume reset to %0.2f dB.", e->alsa_name, c,
+ e->db_fix->db_values[value - e->db_fix->min_step] / 100.0);
+ }
+
+ /* Volume step -> dB value conversion. */
+ value = e->db_fix->db_values[value - e->db_fix->min_step];
+ }
+ } else
+ r = snd_mixer_selem_get_capture_dB(me, c, &value);
+ } else
+ r = -1;
+ }
+
+ if (r < 0)
+ continue;
+
+#ifdef HAVE_VALGRIND_MEMCHECK_H
+ VALGRIND_MAKE_MEM_DEFINED(&value, sizeof(value));
+#endif
+
+ f = from_alsa_dB(value);
+
+ } else {
+ long value = 0;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ if (snd_mixer_selem_has_playback_channel(me, c))
+ r = snd_mixer_selem_get_playback_volume(me, c, &value);
+ else
+ r = -1;
+ } else {
+ if (snd_mixer_selem_has_capture_channel(me, c))
+ r = snd_mixer_selem_get_capture_volume(me, c, &value);
+ else
+ r = -1;
+ }
+
+ if (r < 0)
+ continue;
+
+ f = from_alsa_volume(value, e->min_volume, e->max_volume);
+ }
+
+ for (k = 0; k < cm->channels; k++)
+ if (e->masks[c][e->n_channels-1] & PA_CHANNEL_POSITION_MASK(cm->map[k]))
+ if (v->values[k] < f)
+ v->values[k] = f;
+
+ mask |= e->masks[c][e->n_channels-1];
+ }
+
+ for (k = 0; k < cm->channels; k++)
+ if (!(mask & PA_CHANNEL_POSITION_MASK(cm->map[k])))
+ v->values[k] = PA_VOLUME_NORM;
+
+ return 0;
+}
+
+int pa_alsa_path_get_volume(pa_alsa_path *p, snd_mixer_t *m, const pa_channel_map *cm, pa_cvolume *v) {
+ pa_alsa_element *e;
+
+ pa_assert(m);
+ pa_assert(p);
+ pa_assert(cm);
+ pa_assert(v);
+
+ if (!p->has_volume)
+ return -1;
+
+ pa_cvolume_reset(v, cm->channels);
+
+ PA_LLIST_FOREACH(e, p->elements) {
+ pa_cvolume ev;
+
+ if (e->volume_use != PA_ALSA_VOLUME_MERGE)
+ continue;
+
+ pa_assert(!p->has_dB || e->has_dB);
+
+ if (element_get_volume(e, m, cm, &ev) < 0)
+ return -1;
+
+ /* If we have no dB information all we can do is take the first element and leave */
+ if (!p->has_dB) {
+ *v = ev;
+ return 0;
+ }
+
+ pa_sw_cvolume_multiply(v, v, &ev);
+ }
+
+ return 0;
+}
+
+static int element_get_switch(pa_alsa_element *e, snd_mixer_t *m, pa_bool_t *b) {
+ snd_mixer_selem_id_t *sid;
+ snd_mixer_elem_t *me;
+ snd_mixer_selem_channel_id_t c;
+
+ pa_assert(m);
+ pa_assert(e);
+ pa_assert(b);
+
+ SELEM_INIT(sid, e->alsa_name);
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+ pa_log_warn("Element %s seems to have disappeared.", e->alsa_name);
+ return -1;
+ }
+
+ /* We return muted if at least one channel is muted */
+
+ for (c = 0; c <= SND_MIXER_SCHN_LAST; c++) {
+ int r;
+ int value = 0;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ if (snd_mixer_selem_has_playback_channel(me, c))
+ r = snd_mixer_selem_get_playback_switch(me, c, &value);
+ else
+ r = -1;
+ } else {
+ if (snd_mixer_selem_has_capture_channel(me, c))
+ r = snd_mixer_selem_get_capture_switch(me, c, &value);
+ else
+ r = -1;
+ }
+
+ if (r < 0)
+ continue;
+
+ if (!value) {
+ *b = FALSE;
+ return 0;
+ }
+ }
+
+ *b = TRUE;
+ return 0;
+}
+
+int pa_alsa_path_get_mute(pa_alsa_path *p, snd_mixer_t *m, pa_bool_t *muted) {
+ pa_alsa_element *e;
+
+ pa_assert(m);
+ pa_assert(p);
+ pa_assert(muted);
+
+ if (!p->has_mute)
+ return -1;
+
+ PA_LLIST_FOREACH(e, p->elements) {
+ pa_bool_t b;
+
+ if (e->switch_use != PA_ALSA_SWITCH_MUTE)
+ continue;
+
+ if (element_get_switch(e, m, &b) < 0)
+ return -1;
+
+ if (!b) {
+ *muted = TRUE;
+ return 0;
+ }
+ }
+
+ *muted = FALSE;
+ return 0;
+}
+
+/* Finds the closest item in db_fix->db_values and returns the corresponding
+ * step. *db_value is replaced with the value from the db_values table.
+ * Rounding is done based on the rounding parameter: -1 means rounding down and
+ * +1 means rounding up. */
+static long decibel_fix_get_step(pa_alsa_decibel_fix *db_fix, long *db_value, int rounding) {
+ unsigned i = 0;
+ unsigned max_i = 0;
+
+ pa_assert(db_fix);
+ pa_assert(db_value);
+ pa_assert(rounding != 0);
+
+ max_i = db_fix->max_step - db_fix->min_step;
+
+ if (rounding > 0) {
+ for (i = 0; i < max_i; i++) {
+ if (db_fix->db_values[i] >= *db_value)
+ break;
+ }
+ } else {
+ for (i = 0; i < max_i; i++) {
+ if (db_fix->db_values[i + 1] > *db_value)
+ break;
+ }
+ }
+
+ *db_value = db_fix->db_values[i];
+
+ return i + db_fix->min_step;
+}
+
+/* Alsa lib documentation says for snd_mixer_selem_set_playback_dB() direction argument,
+ * that "-1 = accurate or first below, 0 = accurate, 1 = accurate or first above".
+ * But even with accurate nearest dB volume step is not selected, so that is why we need
+ * this function. Returns 0 and nearest selectable volume in *value_dB on success or
+ * negative error code if fails. */
+static int element_get_nearest_alsa_dB(snd_mixer_elem_t *me, snd_mixer_selem_channel_id_t c, pa_alsa_direction_t d, long *value_dB) {
+
+ long alsa_val;
+ long value_high;
+ long value_low;
+ int r = -1;
+
+ pa_assert(me);
+ pa_assert(value_dB);
+
+ if (d == PA_ALSA_DIRECTION_OUTPUT) {
+ if ((r = snd_mixer_selem_ask_playback_dB_vol(me, *value_dB, +1, &alsa_val)) >= 0)
+ r = snd_mixer_selem_ask_playback_vol_dB(me, alsa_val, &value_high);
+
+ if (r < 0)
+ return r;
+
+ if (value_high == *value_dB)
+ return r;
+
+ if ((r = snd_mixer_selem_ask_playback_dB_vol(me, *value_dB, -1, &alsa_val)) >= 0)
+ r = snd_mixer_selem_ask_playback_vol_dB(me, alsa_val, &value_low);
+ } else {
+ if ((r = snd_mixer_selem_ask_capture_dB_vol(me, *value_dB, +1, &alsa_val)) >= 0)
+ r = snd_mixer_selem_ask_capture_vol_dB(me, alsa_val, &value_high);
+
+ if (r < 0)
+ return r;
+
+ if (value_high == *value_dB)
+ return r;
+
+ if ((r = snd_mixer_selem_ask_capture_dB_vol(me, *value_dB, -1, &alsa_val)) >= 0)
+ r = snd_mixer_selem_ask_capture_vol_dB(me, alsa_val, &value_low);
+ }
+
+ if (r < 0)
+ return r;
+
+ if (labs(value_high - *value_dB) < labs(value_low - *value_dB))
+ *value_dB = value_high;
+ else
+ *value_dB = value_low;
+
+ return r;
+}
+
+static int element_set_volume(pa_alsa_element *e, snd_mixer_t *m, const pa_channel_map *cm, pa_cvolume *v, pa_bool_t sync_volume, pa_bool_t write_to_hw) {
+
+ snd_mixer_selem_id_t *sid;
+ pa_cvolume rv;
+ snd_mixer_elem_t *me;
+ snd_mixer_selem_channel_id_t c;
+ pa_channel_position_mask_t mask = 0;
+ unsigned k;
+
+ pa_assert(m);
+ pa_assert(e);
+ pa_assert(cm);
+ pa_assert(v);
+ pa_assert(pa_cvolume_compatible_with_channel_map(v, cm));
+
+ SELEM_INIT(sid, e->alsa_name);
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+ pa_log_warn("Element %s seems to have disappeared.", e->alsa_name);
+ return -1;
+ }
+
+ pa_cvolume_mute(&rv, cm->channels);
+
+ for (c = 0; c <= SND_MIXER_SCHN_LAST; c++) {
+ int r;
+ pa_volume_t f = PA_VOLUME_MUTED;
+ pa_bool_t found = FALSE;
+
+ for (k = 0; k < cm->channels; k++)
+ if (e->masks[c][e->n_channels-1] & PA_CHANNEL_POSITION_MASK(cm->map[k])) {
+ found = TRUE;
+ if (v->values[k] > f)
+ f = v->values[k];
+ }
+
+ if (!found) {
+ /* Hmm, so this channel does not exist in the volume
+ * struct, so let's bind it to the overall max of the
+ * volume. */
+ f = pa_cvolume_max(v);
+ }
+
+ if (e->has_dB) {
+ long value = to_alsa_dB(f);
+ int rounding;
+
+ if (e->volume_limit >= 0 && value > (e->max_dB * 100))
+ value = e->max_dB * 100;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ /* If we call set_playback_volume() without checking first
+ * if the channel is available, ALSA behaves very
+ * strangely and doesn't fail the call */
+ if (snd_mixer_selem_has_playback_channel(me, c)) {
+ rounding = +1;
+ if (e->db_fix) {
+ if (write_to_hw)
+ r = snd_mixer_selem_set_playback_volume(me, c, decibel_fix_get_step(e->db_fix, &value, rounding));
+ else {
+ decibel_fix_get_step(e->db_fix, &value, rounding);
+ r = 0;
+ }
+
+ } else {
+ if (write_to_hw) {
+ if (sync_volume) {
+ if ((r = element_get_nearest_alsa_dB(me, c, PA_ALSA_DIRECTION_OUTPUT, &value)) >= 0)
+ r = snd_mixer_selem_set_playback_dB(me, c, value, 0);
+ } else {
+ if ((r = snd_mixer_selem_set_playback_dB(me, c, value, rounding)) >= 0)
+ r = snd_mixer_selem_get_playback_dB(me, c, &value);
+ }
+ } else {
+ long alsa_val;
+ if ((r = snd_mixer_selem_ask_playback_dB_vol(me, value, rounding, &alsa_val)) >= 0)
+ r = snd_mixer_selem_ask_playback_vol_dB(me, alsa_val, &value);
+ }
+ }
+ } else
+ r = -1;
+ } else {
+ if (snd_mixer_selem_has_capture_channel(me, c)) {
+ rounding = -1;
+ if (e->db_fix) {
+ if (write_to_hw)
+ r = snd_mixer_selem_set_capture_volume(me, c, decibel_fix_get_step(e->db_fix, &value, rounding));
+ else {
+ decibel_fix_get_step(e->db_fix, &value, rounding);
+ r = 0;
+ }
+
+ } else {
+ if (write_to_hw) {
+ if (sync_volume) {
+ if ((r = element_get_nearest_alsa_dB(me, c, PA_ALSA_DIRECTION_INPUT, &value)) >= 0)
+ r = snd_mixer_selem_set_capture_dB(me, c, value, 0);
+ } else {
+ if ((r = snd_mixer_selem_set_capture_dB(me, c, value, rounding)) >= 0)
+ r = snd_mixer_selem_get_capture_dB(me, c, &value);
+ }
+ } else {
+ long alsa_val;
+ if ((r = snd_mixer_selem_ask_capture_dB_vol(me, value, rounding, &alsa_val)) >= 0)
+ r = snd_mixer_selem_ask_capture_vol_dB(me, alsa_val, &value);
+ }
+ }
+ } else
+ r = -1;
+ }
+
+ if (r < 0)
+ continue;
+
+#ifdef HAVE_VALGRIND_MEMCHECK_H
+ VALGRIND_MAKE_MEM_DEFINED(&value, sizeof(value));
+#endif
+
+ f = from_alsa_dB(value);
+
+ } else {
+ long value;
+
+ value = to_alsa_volume(f, e->min_volume, e->max_volume);
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ if (snd_mixer_selem_has_playback_channel(me, c)) {
+ if ((r = snd_mixer_selem_set_playback_volume(me, c, value)) >= 0)
+ r = snd_mixer_selem_get_playback_volume(me, c, &value);
+ } else
+ r = -1;
+ } else {
+ if (snd_mixer_selem_has_capture_channel(me, c)) {
+ if ((r = snd_mixer_selem_set_capture_volume(me, c, value)) >= 0)
+ r = snd_mixer_selem_get_capture_volume(me, c, &value);
+ } else
+ r = -1;
+ }
+
+ if (r < 0)
+ continue;
+
+ f = from_alsa_volume(value, e->min_volume, e->max_volume);
+ }
+
+ for (k = 0; k < cm->channels; k++)
+ if (e->masks[c][e->n_channels-1] & PA_CHANNEL_POSITION_MASK(cm->map[k]))
+ if (rv.values[k] < f)
+ rv.values[k] = f;
+
+ mask |= e->masks[c][e->n_channels-1];
+ }
+
+ for (k = 0; k < cm->channels; k++)
+ if (!(mask & PA_CHANNEL_POSITION_MASK(cm->map[k])))
+ rv.values[k] = PA_VOLUME_NORM;
+
+ *v = rv;
+ return 0;
+}
+
+int pa_alsa_path_set_volume(pa_alsa_path *p, snd_mixer_t *m, const pa_channel_map *cm, pa_cvolume *v, pa_bool_t sync_volume, pa_bool_t write_to_hw) {
+
+ pa_alsa_element *e;
+ pa_cvolume rv;
+
+ pa_assert(m);
+ pa_assert(p);
+ pa_assert(cm);
+ pa_assert(v);
+ pa_assert(pa_cvolume_compatible_with_channel_map(v, cm));
+
+ if (!p->has_volume)
+ return -1;
+
+ rv = *v; /* Remaining adjustment */
+ pa_cvolume_reset(v, cm->channels); /* Adjustment done */
+
+ PA_LLIST_FOREACH(e, p->elements) {
+ pa_cvolume ev;
+
+ if (e->volume_use != PA_ALSA_VOLUME_MERGE)
+ continue;
+
+ pa_assert(!p->has_dB || e->has_dB);
+
+ ev = rv;
+ if (element_set_volume(e, m, cm, &ev, sync_volume, write_to_hw) < 0)
+ return -1;
+
+ if (!p->has_dB) {
+ *v = ev;
+ return 0;
+ }
+
+ pa_sw_cvolume_multiply(v, v, &ev);
+ pa_sw_cvolume_divide(&rv, &rv, &ev);
+ }
+
+ return 0;
+}
+
+static int element_set_switch(pa_alsa_element *e, snd_mixer_t *m, pa_bool_t b) {
+ snd_mixer_elem_t *me;
+ snd_mixer_selem_id_t *sid;
+ int r;
+
+ pa_assert(m);
+ pa_assert(e);
+
+ SELEM_INIT(sid, e->alsa_name);
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+ pa_log_warn("Element %s seems to have disappeared.", e->alsa_name);
+ return -1;
+ }
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_set_playback_switch_all(me, b);
+ else
+ r = snd_mixer_selem_set_capture_switch_all(me, b);
+
+ if (r < 0)
+ pa_log_warn("Failed to set switch of %s: %s", e->alsa_name, pa_alsa_strerror(errno));
+
+ return r;
+}
+
+int pa_alsa_path_set_mute(pa_alsa_path *p, snd_mixer_t *m, pa_bool_t muted) {
+ pa_alsa_element *e;
+
+ pa_assert(m);
+ pa_assert(p);
+
+ if (!p->has_mute)
+ return -1;
+
+ PA_LLIST_FOREACH(e, p->elements) {
+
+ if (e->switch_use != PA_ALSA_SWITCH_MUTE)
+ continue;
+
+ if (element_set_switch(e, m, !muted) < 0)
+ return -1;
+ }
+
+ return 0;
+}
+
+/* Depending on whether e->volume_use is _OFF, _ZERO or _CONSTANT, this
+ * function sets all channels of the volume element to e->min_volume, 0 dB or
+ * e->constant_volume. */
+static int element_set_constant_volume(pa_alsa_element *e, snd_mixer_t *m) {
+ snd_mixer_elem_t *me = NULL;
+ snd_mixer_selem_id_t *sid = NULL;
+ int r = 0;
+ long volume = -1;
+ pa_bool_t volume_set = FALSE;
+
+ pa_assert(m);
+ pa_assert(e);
+
+ SELEM_INIT(sid, e->alsa_name);
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+ pa_log_warn("Element %s seems to have disappeared.", e->alsa_name);
+ return -1;
+ }
+
+ switch (e->volume_use) {
+ case PA_ALSA_VOLUME_OFF:
+ volume = e->min_volume;
+ volume_set = TRUE;
+ break;
+
+ case PA_ALSA_VOLUME_ZERO:
+ if (e->db_fix) {
+ long dB = 0;
+
+ volume = decibel_fix_get_step(e->db_fix, &dB, +1);
+ volume_set = TRUE;
+ }
+ break;
+
+ case PA_ALSA_VOLUME_CONSTANT:
+ volume = e->constant_volume;
+ volume_set = TRUE;
+ break;
+
+ default:
+ pa_assert_not_reached();
+ }
+
+ if (volume_set) {
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_set_playback_volume_all(me, volume);
+ else
+ r = snd_mixer_selem_set_capture_volume_all(me, volume);
+ } else {
+ pa_assert(e->volume_use == PA_ALSA_VOLUME_ZERO);
+ pa_assert(!e->db_fix);
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_set_playback_dB_all(me, 0, +1);
+ else
+ r = snd_mixer_selem_set_capture_dB_all(me, 0, +1);
+ }
+
+ if (r < 0)
+ pa_log_warn("Failed to set volume of %s: %s", e->alsa_name, pa_alsa_strerror(errno));
+
+ return r;
+}
+
+int pa_alsa_path_select(pa_alsa_path *p, snd_mixer_t *m) {
+ pa_alsa_element *e;
+ int r = 0;
+
+ pa_assert(m);
+ pa_assert(p);
+
+ pa_log_debug("Activating path %s", p->name);
+ pa_alsa_path_dump(p);
+
+ PA_LLIST_FOREACH(e, p->elements) {
+
+ switch (e->switch_use) {
+ case PA_ALSA_SWITCH_OFF:
+ r = element_set_switch(e, m, FALSE);
+ break;
+
+ case PA_ALSA_SWITCH_ON:
+ r = element_set_switch(e, m, TRUE);
+ break;
+
+ case PA_ALSA_SWITCH_MUTE:
+ case PA_ALSA_SWITCH_IGNORE:
+ case PA_ALSA_SWITCH_SELECT:
+ r = 0;
+ break;
+ }
+
+ if (r < 0)
+ return -1;
+
+ switch (e->volume_use) {
+ case PA_ALSA_VOLUME_OFF:
+ case PA_ALSA_VOLUME_ZERO:
+ case PA_ALSA_VOLUME_CONSTANT:
+ r = element_set_constant_volume(e, m);
+ break;
+
+ case PA_ALSA_VOLUME_MERGE:
+ case PA_ALSA_VOLUME_IGNORE:
+ r = 0;
+ break;
+ }
+
+ if (r < 0)
+ return -1;
+ }
+
+ return 0;
+}
+
+static int check_required(pa_alsa_element *e, snd_mixer_elem_t *me) {
+ pa_bool_t has_switch;
+ pa_bool_t has_enumeration;
+ pa_bool_t has_volume;
+
+ pa_assert(e);
+ pa_assert(me);
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ has_switch =
+ snd_mixer_selem_has_playback_switch(me) ||
+ (e->direction_try_other && snd_mixer_selem_has_capture_switch(me));
+ } else {
+ has_switch =
+ snd_mixer_selem_has_capture_switch(me) ||
+ (e->direction_try_other && snd_mixer_selem_has_playback_switch(me));
+ }
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ has_volume =
+ snd_mixer_selem_has_playback_volume(me) ||
+ (e->direction_try_other && snd_mixer_selem_has_capture_volume(me));
+ } else {
+ has_volume =
+ snd_mixer_selem_has_capture_volume(me) ||
+ (e->direction_try_other && snd_mixer_selem_has_playback_volume(me));
+ }
+
+ has_enumeration = snd_mixer_selem_is_enumerated(me);
+
+ if ((e->required == PA_ALSA_REQUIRED_SWITCH && !has_switch) ||
+ (e->required == PA_ALSA_REQUIRED_VOLUME && !has_volume) ||
+ (e->required == PA_ALSA_REQUIRED_ENUMERATION && !has_enumeration))
+ return -1;
+
+ if (e->required == PA_ALSA_REQUIRED_ANY && !(has_switch || has_volume || has_enumeration))
+ return -1;
+
+ if ((e->required_absent == PA_ALSA_REQUIRED_SWITCH && has_switch) ||
+ (e->required_absent == PA_ALSA_REQUIRED_VOLUME && has_volume) ||
+ (e->required_absent == PA_ALSA_REQUIRED_ENUMERATION && has_enumeration))
+ return -1;
+
+ if (e->required_absent == PA_ALSA_REQUIRED_ANY && (has_switch || has_volume || has_enumeration))
+ return -1;
+
+ if (e->required_any != PA_ALSA_REQUIRED_IGNORE) {
+ switch (e->required_any) {
+ case PA_ALSA_REQUIRED_VOLUME:
+ e->path->req_any_present |= (e->volume_use != PA_ALSA_VOLUME_IGNORE);
+ break;
+ case PA_ALSA_REQUIRED_SWITCH:
+ e->path->req_any_present |= (e->switch_use != PA_ALSA_SWITCH_IGNORE);
+ break;
+ case PA_ALSA_REQUIRED_ENUMERATION:
+ e->path->req_any_present |= (e->enumeration_use != PA_ALSA_ENUMERATION_IGNORE);
+ break;
+ case PA_ALSA_REQUIRED_ANY:
+ e->path->req_any_present |=
+ (e->volume_use != PA_ALSA_VOLUME_IGNORE) ||
+ (e->switch_use != PA_ALSA_SWITCH_IGNORE) ||
+ (e->enumeration_use != PA_ALSA_ENUMERATION_IGNORE);
+ break;
+ default:
+ pa_assert_not_reached();
+ }
+ }
+
+ if (e->enumeration_use == PA_ALSA_ENUMERATION_SELECT) {
+ pa_alsa_option *o;
+ PA_LLIST_FOREACH(o, e->options) {
+ e->path->req_any_present |= (o->required_any != PA_ALSA_REQUIRED_IGNORE) &&
+ (o->alsa_idx >= 0);
+ if (o->required != PA_ALSA_REQUIRED_IGNORE && o->alsa_idx < 0)
+ return -1;
+ if (o->required_absent != PA_ALSA_REQUIRED_IGNORE && o->alsa_idx >= 0)
+ return -1;
+ }
+ }
+
+ return 0;
+}
+
+static int element_probe(pa_alsa_element *e, snd_mixer_t *m) {
+ snd_mixer_selem_id_t *sid;
+ snd_mixer_elem_t *me;
+
+ pa_assert(m);
+ pa_assert(e);
+ pa_assert(e->path);
+
+ SELEM_INIT(sid, e->alsa_name);
+
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+
+ if (e->required != PA_ALSA_REQUIRED_IGNORE)
+ return -1;
+
+ e->switch_use = PA_ALSA_SWITCH_IGNORE;
+ e->volume_use = PA_ALSA_VOLUME_IGNORE;
+ e->enumeration_use = PA_ALSA_ENUMERATION_IGNORE;
+
+ return 0;
+ }
+
+ if (e->switch_use != PA_ALSA_SWITCH_IGNORE) {
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+
+ if (!snd_mixer_selem_has_playback_switch(me)) {
+ if (e->direction_try_other && snd_mixer_selem_has_capture_switch(me))
+ e->direction = PA_ALSA_DIRECTION_INPUT;
+ else
+ e->switch_use = PA_ALSA_SWITCH_IGNORE;
+ }
+
+ } else {
+
+ if (!snd_mixer_selem_has_capture_switch(me)) {
+ if (e->direction_try_other && snd_mixer_selem_has_playback_switch(me))
+ e->direction = PA_ALSA_DIRECTION_OUTPUT;
+ else
+ e->switch_use = PA_ALSA_SWITCH_IGNORE;
+ }
+ }
+
+ if (e->switch_use != PA_ALSA_SWITCH_IGNORE)
+ e->direction_try_other = FALSE;
+ }
+
+ if (e->volume_use != PA_ALSA_VOLUME_IGNORE) {
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT) {
+
+ if (!snd_mixer_selem_has_playback_volume(me)) {
+ if (e->direction_try_other && snd_mixer_selem_has_capture_volume(me))
+ e->direction = PA_ALSA_DIRECTION_INPUT;
+ else
+ e->volume_use = PA_ALSA_VOLUME_IGNORE;
+ }
+
+ } else {
+
+ if (!snd_mixer_selem_has_capture_volume(me)) {
+ if (e->direction_try_other && snd_mixer_selem_has_playback_volume(me))
+ e->direction = PA_ALSA_DIRECTION_OUTPUT;
+ else
+ e->volume_use = PA_ALSA_VOLUME_IGNORE;
+ }
+ }
+
+ if (e->volume_use != PA_ALSA_VOLUME_IGNORE) {
+ long min_dB = 0, max_dB = 0;
+ int r;
+
+ e->direction_try_other = FALSE;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_get_playback_volume_range(me, &e->min_volume, &e->max_volume);
+ else
+ r = snd_mixer_selem_get_capture_volume_range(me, &e->min_volume, &e->max_volume);
+
+ if (r < 0) {
+ pa_log_warn("Failed to get volume range of %s: %s", e->alsa_name, pa_alsa_strerror(r));
+ return -1;
+ }
+
+ if (e->min_volume >= e->max_volume) {
+ pa_log_warn("Your kernel driver is broken: it reports a volume range from %li to %li which makes no sense.", e->min_volume, e->max_volume);
+ e->volume_use = PA_ALSA_VOLUME_IGNORE;
+
+ } else if (e->volume_use == PA_ALSA_VOLUME_CONSTANT &&
+ (e->min_volume > e->constant_volume || e->max_volume < e->constant_volume)) {
+ pa_log_warn("Constant volume %li configured for element %s, but the available range is from %li to %li.",
+ e->constant_volume, e->alsa_name, e->min_volume, e->max_volume);
+ e->volume_use = PA_ALSA_VOLUME_IGNORE;
+
+ } else {
+ pa_bool_t is_mono;
+ pa_channel_position_t p;
+
+ if (e->db_fix &&
+ ((e->min_volume > e->db_fix->min_step) ||
+ (e->max_volume < e->db_fix->max_step))) {
+ pa_log_warn("The step range of the decibel fix for element %s (%li-%li) doesn't fit to the "
+ "real hardware range (%li-%li). Disabling the decibel fix.", e->alsa_name,
+ e->db_fix->min_step, e->db_fix->max_step,
+ e->min_volume, e->max_volume);
+
+ decibel_fix_free(e->db_fix);
+ e->db_fix = NULL;
+ }
+
+ if (e->db_fix) {
+ e->has_dB = TRUE;
+ e->min_volume = e->db_fix->min_step;
+ e->max_volume = e->db_fix->max_step;
+ min_dB = e->db_fix->db_values[0];
+ max_dB = e->db_fix->db_values[e->db_fix->max_step - e->db_fix->min_step];
+ } else if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ e->has_dB = snd_mixer_selem_get_playback_dB_range(me, &min_dB, &max_dB) >= 0;
+ else
+ e->has_dB = snd_mixer_selem_get_capture_dB_range(me, &min_dB, &max_dB) >= 0;
+
+ /* Check that the kernel driver returns consistent limits with
+ * both _get_*_dB_range() and _ask_*_vol_dB(). */
+ if (e->has_dB && !e->db_fix) {
+ long min_dB_checked = 0;
+ long max_dB_checked = 0;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_ask_playback_vol_dB(me, e->min_volume, &min_dB_checked);
+ else
+ r = snd_mixer_selem_ask_capture_vol_dB(me, e->min_volume, &min_dB_checked);
+
+ if (r < 0) {
+ pa_log_warn("Failed to query the dB value for %s at volume level %li", e->alsa_name, e->min_volume);
+ return -1;
+ }
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_ask_playback_vol_dB(me, e->max_volume, &max_dB_checked);
+ else
+ r = snd_mixer_selem_ask_capture_vol_dB(me, e->max_volume, &max_dB_checked);
+
+ if (r < 0) {
+ pa_log_warn("Failed to query the dB value for %s at volume level %li", e->alsa_name, e->max_volume);
+ return -1;
+ }
+
+ if (min_dB != min_dB_checked || max_dB != max_dB_checked) {
+ pa_log_warn("Your kernel driver is broken: the reported dB range for %s (from %0.2f dB to %0.2f dB) "
+ "doesn't match the dB values at minimum and maximum volume levels: %0.2f dB at level %li, "
+ "%0.2f dB at level %li.",
+ e->alsa_name,
+ min_dB / 100.0, max_dB / 100.0,
+ min_dB_checked / 100.0, e->min_volume, max_dB_checked / 100.0, e->max_volume);
+ return -1;
+ }
+ }
+
+ if (e->has_dB) {
+#ifdef HAVE_VALGRIND_MEMCHECK_H
+ VALGRIND_MAKE_MEM_DEFINED(&min_dB, sizeof(min_dB));
+ VALGRIND_MAKE_MEM_DEFINED(&max_dB, sizeof(max_dB));
+#endif
+
+ e->min_dB = ((double) min_dB) / 100.0;
+ e->max_dB = ((double) max_dB) / 100.0;
+
+ if (min_dB >= max_dB) {
+ pa_assert(!e->db_fix);
+ pa_log_warn("Your kernel driver is broken: it reports a volume range from %0.2f dB to %0.2f dB which makes no sense.", e->min_dB, e->max_dB);
+ e->has_dB = FALSE;
+ }
+ }
+
+ if (e->volume_limit >= 0) {
+ if (e->volume_limit <= e->min_volume || e->volume_limit > e->max_volume)
+ pa_log_warn("Volume limit for element %s of path %s is invalid: %li isn't within the valid range "
+ "%li-%li. The volume limit is ignored.",
+ e->alsa_name, e->path->name, e->volume_limit, e->min_volume + 1, e->max_volume);
+
+ else {
+ e->max_volume = e->volume_limit;
+
+ if (e->has_dB) {
+ if (e->db_fix) {
+ e->db_fix->max_step = e->max_volume;
+ e->max_dB = ((double) e->db_fix->db_values[e->db_fix->max_step - e->db_fix->min_step]) / 100.0;
+
+ } else {
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_ask_playback_vol_dB(me, e->max_volume, &max_dB);
+ else
+ r = snd_mixer_selem_ask_capture_vol_dB(me, e->max_volume, &max_dB);
+
+ if (r < 0) {
+ pa_log_warn("Failed to get dB value of %s: %s", e->alsa_name, pa_alsa_strerror(r));
+ e->has_dB = FALSE;
+ } else
+ e->max_dB = ((double) max_dB) / 100.0;
+ }
+ }
+ }
+ }
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ is_mono = snd_mixer_selem_is_playback_mono(me) > 0;
+ else
+ is_mono = snd_mixer_selem_is_capture_mono(me) > 0;
+
+ if (is_mono) {
+ e->n_channels = 1;
+
+ if (!e->override_map) {
+ for (p = PA_CHANNEL_POSITION_FRONT_LEFT; p < PA_CHANNEL_POSITION_MAX; p++) {
+ if (alsa_channel_ids[p] == SND_MIXER_SCHN_UNKNOWN)
+ continue;
+
+ e->masks[alsa_channel_ids[p]][e->n_channels-1] = 0;
+ }
+
+ e->masks[SND_MIXER_SCHN_MONO][e->n_channels-1] = PA_CHANNEL_POSITION_MASK_ALL;
+ }
+
+ e->merged_mask = e->masks[SND_MIXER_SCHN_MONO][e->n_channels-1];
+ } else {
+ e->n_channels = 0;
+ for (p = PA_CHANNEL_POSITION_FRONT_LEFT; p < PA_CHANNEL_POSITION_MAX; p++) {
+
+ if (alsa_channel_ids[p] == SND_MIXER_SCHN_UNKNOWN)
+ continue;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ e->n_channels += snd_mixer_selem_has_playback_channel(me, alsa_channel_ids[p]) > 0;
+ else
+ e->n_channels += snd_mixer_selem_has_capture_channel(me, alsa_channel_ids[p]) > 0;
+ }
+
+ if (e->n_channels <= 0) {
+ pa_log_warn("Volume element %s with no channels?", e->alsa_name);
+ return -1;
+ }
+
+ if (e->n_channels > 2) {
+ /* FIXME: In some places code like this is used:
+ *
+ * e->masks[alsa_channel_ids[p]][e->n_channels-1]
+ *
+ * The definition of e->masks is
+ *
+ * pa_channel_position_mask_t masks[SND_MIXER_SCHN_LAST][2];
+ *
+ * Since the array size is fixed at 2, we obviously
+ * don't support elements with more than two
+ * channels... */
+ pa_log_warn("Volume element %s has %u channels. That's too much! I can't handle that!", e->alsa_name, e->n_channels);
+ return -1;
+ }
+
+ if (!e->override_map) {
+ for (p = PA_CHANNEL_POSITION_FRONT_LEFT; p < PA_CHANNEL_POSITION_MAX; p++) {
+ pa_bool_t has_channel;
+
+ if (alsa_channel_ids[p] == SND_MIXER_SCHN_UNKNOWN)
+ continue;
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ has_channel = snd_mixer_selem_has_playback_channel(me, alsa_channel_ids[p]) > 0;
+ else
+ has_channel = snd_mixer_selem_has_capture_channel(me, alsa_channel_ids[p]) > 0;
+
+ e->masks[alsa_channel_ids[p]][e->n_channels-1] = has_channel ? PA_CHANNEL_POSITION_MASK(p) : 0;
+ }
+ }
+
+ e->merged_mask = 0;
+ for (p = PA_CHANNEL_POSITION_FRONT_LEFT; p < PA_CHANNEL_POSITION_MAX; p++) {
+ if (alsa_channel_ids[p] == SND_MIXER_SCHN_UNKNOWN)
+ continue;
+
+ e->merged_mask |= e->masks[alsa_channel_ids[p]][e->n_channels-1];
+ }
+ }
+ }
+ }
+
+ }
+
+ if (e->switch_use == PA_ALSA_SWITCH_SELECT) {
+ pa_alsa_option *o;
+
+ PA_LLIST_FOREACH(o, e->options)
+ o->alsa_idx = pa_streq(o->alsa_name, "on") ? 1 : 0;
+ } else if (e->enumeration_use == PA_ALSA_ENUMERATION_SELECT) {
+ int n;
+ pa_alsa_option *o;
+
+ if ((n = snd_mixer_selem_get_enum_items(me)) < 0) {
+ pa_log("snd_mixer_selem_get_enum_items() failed: %s", pa_alsa_strerror(n));
+ return -1;
+ }
+
+ PA_LLIST_FOREACH(o, e->options) {
+ int i;
+
+ for (i = 0; i < n; i++) {
+ char buf[128];
+
+ if (snd_mixer_selem_get_enum_item_name(me, i, sizeof(buf), buf) < 0)
+ continue;
+
+ if (!pa_streq(buf, o->alsa_name))
+ continue;
+
+ o->alsa_idx = i;
+ }
+ }
+ }
+
+ if (check_required(e, me) < 0)
+ return -1;
+
+ return 0;
+}
+
+static pa_alsa_element* element_get(pa_alsa_path *p, const char *section, pa_bool_t prefixed) {
+ pa_alsa_element *e;
+
+ pa_assert(p);
+ pa_assert(section);
+
+ if (prefixed) {
+ if (!pa_startswith(section, "Element "))
+ return NULL;
+
+ section += 8;
+ }
+
+ /* This is not an element section, but an enum section? */
+ if (strchr(section, ':'))
+ return NULL;
+
+ if (p->last_element && pa_streq(p->last_element->alsa_name, section))
+ return p->last_element;
+
+ PA_LLIST_FOREACH(e, p->elements)
+ if (pa_streq(e->alsa_name, section))
+ goto finish;
+
+ e = pa_xnew0(pa_alsa_element, 1);
+ e->path = p;
+ e->alsa_name = pa_xstrdup(section);
+ e->direction = p->direction;
+ e->volume_limit = -1;
+
+ PA_LLIST_INSERT_AFTER(pa_alsa_element, p->elements, p->last_element, e);
+
+finish:
+ p->last_element = e;
+ return e;
+}
+
+static pa_alsa_option* option_get(pa_alsa_path *p, const char *section) {
+ char *en;
+ const char *on;
+ pa_alsa_option *o;
+ pa_alsa_element *e;
+
+ if (!pa_startswith(section, "Option "))
+ return NULL;
+
+ section += 7;
+
+ /* This is not an enum section, but an element section? */
+ if (!(on = strchr(section, ':')))
+ return NULL;
+
+ en = pa_xstrndup(section, on - section);
+ on++;
+
+ if (p->last_option &&
+ pa_streq(p->last_option->element->alsa_name, en) &&
+ pa_streq(p->last_option->alsa_name, on)) {
+ pa_xfree(en);
+ return p->last_option;
+ }
+
+ pa_assert_se(e = element_get(p, en, FALSE));
+ pa_xfree(en);
+
+ PA_LLIST_FOREACH(o, e->options)
+ if (pa_streq(o->alsa_name, on))
+ goto finish;
+
+ o = pa_xnew0(pa_alsa_option, 1);
+ o->element = e;
+ o->alsa_name = pa_xstrdup(on);
+ o->alsa_idx = -1;
+
+ if (p->last_option && p->last_option->element == e)
+ PA_LLIST_INSERT_AFTER(pa_alsa_option, e->options, p->last_option, o);
+ else
+ PA_LLIST_PREPEND(pa_alsa_option, e->options, o);
+
+finish:
+ p->last_option = o;
+ return o;
+}
+
+static int element_parse_switch(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+
+ pa_assert(p);
+
+ if (!(e = element_get(p, section, TRUE))) {
+ pa_log("[%s:%u] Switch makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_streq(rvalue, "ignore"))
+ e->switch_use = PA_ALSA_SWITCH_IGNORE;
+ else if (pa_streq(rvalue, "mute"))
+ e->switch_use = PA_ALSA_SWITCH_MUTE;
+ else if (pa_streq(rvalue, "off"))
+ e->switch_use = PA_ALSA_SWITCH_OFF;
+ else if (pa_streq(rvalue, "on"))
+ e->switch_use = PA_ALSA_SWITCH_ON;
+ else if (pa_streq(rvalue, "select"))
+ e->switch_use = PA_ALSA_SWITCH_SELECT;
+ else {
+ pa_log("[%s:%u] Switch invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int element_parse_volume(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+
+ pa_assert(p);
+
+ if (!(e = element_get(p, section, TRUE))) {
+ pa_log("[%s:%u] Volume makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_streq(rvalue, "ignore"))
+ e->volume_use = PA_ALSA_VOLUME_IGNORE;
+ else if (pa_streq(rvalue, "merge"))
+ e->volume_use = PA_ALSA_VOLUME_MERGE;
+ else if (pa_streq(rvalue, "off"))
+ e->volume_use = PA_ALSA_VOLUME_OFF;
+ else if (pa_streq(rvalue, "zero"))
+ e->volume_use = PA_ALSA_VOLUME_ZERO;
+ else {
+ uint32_t constant;
+
+ if (pa_atou(rvalue, &constant) >= 0) {
+ e->volume_use = PA_ALSA_VOLUME_CONSTANT;
+ e->constant_volume = constant;
+ } else {
+ pa_log("[%s:%u] Volume invalid of '%s'", filename, line, section);
+ return -1;
+ }
+ }
+
+ return 0;
+}
+
+static int element_parse_enumeration(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+
+ pa_assert(p);
+
+ if (!(e = element_get(p, section, TRUE))) {
+ pa_log("[%s:%u] Enumeration makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_streq(rvalue, "ignore"))
+ e->enumeration_use = PA_ALSA_ENUMERATION_IGNORE;
+ else if (pa_streq(rvalue, "select"))
+ e->enumeration_use = PA_ALSA_ENUMERATION_SELECT;
+ else {
+ pa_log("[%s:%u] Enumeration invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int option_parse_priority(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_option *o;
+ uint32_t prio;
+
+ pa_assert(p);
+
+ if (!(o = option_get(p, section))) {
+ pa_log("[%s:%u] Priority makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_atou(rvalue, &prio) < 0) {
+ pa_log("[%s:%u] Priority invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ o->priority = prio;
+ return 0;
+}
+
+static int option_parse_name(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_option *o;
+
+ pa_assert(p);
+
+ if (!(o = option_get(p, section))) {
+ pa_log("[%s:%u] Name makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ pa_xfree(o->name);
+ o->name = pa_xstrdup(rvalue);
+
+ return 0;
+}
+
+static int element_parse_required(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+ pa_alsa_option *o;
+ pa_alsa_required_t req;
+
+ pa_assert(p);
+
+ e = element_get(p, section, TRUE);
+ o = option_get(p, section);
+ if (!e && !o) {
+ pa_log("[%s:%u] Required makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_streq(rvalue, "ignore"))
+ req = PA_ALSA_REQUIRED_IGNORE;
+ else if (pa_streq(rvalue, "switch") && e)
+ req = PA_ALSA_REQUIRED_SWITCH;
+ else if (pa_streq(rvalue, "volume") && e)
+ req = PA_ALSA_REQUIRED_VOLUME;
+ else if (pa_streq(rvalue, "enumeration"))
+ req = PA_ALSA_REQUIRED_ENUMERATION;
+ else if (pa_streq(rvalue, "any"))
+ req = PA_ALSA_REQUIRED_ANY;
+ else {
+ pa_log("[%s:%u] Required invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_streq(lvalue, "required-absent")) {
+ if (e)
+ e->required_absent = req;
+ if (o)
+ o->required_absent = req;
+ }
+ else if (pa_streq(lvalue, "required-any")) {
+ if (e) {
+ e->required_any = req;
+ e->path->has_req_any = TRUE;
+ }
+ if (o) {
+ o->required_any = req;
+ o->element->path->has_req_any = TRUE;
+ }
+ }
+ else {
+ if (e)
+ e->required = req;
+ if (o)
+ o->required = req;
+ }
+
+ return 0;
+}
+
+static int element_parse_direction(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+
+ pa_assert(p);
+
+ if (!(e = element_get(p, section, TRUE))) {
+ pa_log("[%s:%u] Direction makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_streq(rvalue, "playback"))
+ e->direction = PA_ALSA_DIRECTION_OUTPUT;
+ else if (pa_streq(rvalue, "capture"))
+ e->direction = PA_ALSA_DIRECTION_INPUT;
+ else {
+ pa_log("[%s:%u] Direction invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int element_parse_direction_try_other(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+ int yes;
+
+ if (!(e = element_get(p, section, TRUE))) {
+ pa_log("[%s:%u] Direction makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if ((yes = pa_parse_boolean(rvalue)) < 0) {
+ pa_log("[%s:%u] Direction invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ e->direction_try_other = !!yes;
+ return 0;
+}
+
+static int element_parse_volume_limit(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+ long volume_limit;
+
+ if (!(e = element_get(p, section, TRUE))) {
+ pa_log("[%s:%u] volume-limit makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ if (pa_atol(rvalue, &volume_limit) < 0 || volume_limit < 0) {
+ pa_log("[%s:%u] Invalid value for volume-limit", filename, line);
+ return -1;
+ }
+
+ e->volume_limit = volume_limit;
+ return 0;
+}
+
+static pa_channel_position_mask_t parse_mask(const char *m) {
+ pa_channel_position_mask_t v;
+
+ if (pa_streq(m, "all-left"))
+ v = PA_CHANNEL_POSITION_MASK_LEFT;
+ else if (pa_streq(m, "all-right"))
+ v = PA_CHANNEL_POSITION_MASK_RIGHT;
+ else if (pa_streq(m, "all-center"))
+ v = PA_CHANNEL_POSITION_MASK_CENTER;
+ else if (pa_streq(m, "all-front"))
+ v = PA_CHANNEL_POSITION_MASK_FRONT;
+ else if (pa_streq(m, "all-rear"))
+ v = PA_CHANNEL_POSITION_MASK_REAR;
+ else if (pa_streq(m, "all-side"))
+ v = PA_CHANNEL_POSITION_MASK_SIDE_OR_TOP_CENTER;
+ else if (pa_streq(m, "all-top"))
+ v = PA_CHANNEL_POSITION_MASK_TOP;
+ else if (pa_streq(m, "all-no-lfe"))
+ v = PA_CHANNEL_POSITION_MASK_ALL ^ PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_LFE);
+ else if (pa_streq(m, "all"))
+ v = PA_CHANNEL_POSITION_MASK_ALL;
+ else {
+ pa_channel_position_t p;
+
+ if ((p = pa_channel_position_from_string(m)) == PA_CHANNEL_POSITION_INVALID)
+ return 0;
+
+ v = PA_CHANNEL_POSITION_MASK(p);
+ }
+
+ return v;
+}
+
+static int element_parse_override_map(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_path *p = userdata;
+ pa_alsa_element *e;
+ const char *state = NULL;
+ unsigned i = 0;
+ char *n;
+
+ if (!(e = element_get(p, section, TRUE))) {
+ pa_log("[%s:%u] Override map makes no sense in '%s'", filename, line, section);
+ return -1;
+ }
+
+ while ((n = pa_split(rvalue, ",", &state))) {
+ pa_channel_position_mask_t m;
+
+ if (!*n)
+ m = 0;
+ else {
+ if ((m = parse_mask(n)) == 0) {
+ pa_log("[%s:%u] Override map '%s' invalid in '%s'", filename, line, n, section);
+ pa_xfree(n);
+ return -1;
+ }
+ }
+
+ if (pa_streq(lvalue, "override-map.1"))
+ e->masks[i++][0] = m;
+ else
+ e->masks[i++][1] = m;
+
+ /* Later on we might add override-map.3 and so on here ... */
+
+ pa_xfree(n);
+ }
+
+ e->override_map = TRUE;
+
+ return 0;
+}
+
+static int element_set_option(pa_alsa_element *e, snd_mixer_t *m, int alsa_idx) {
+ snd_mixer_selem_id_t *sid;
+ snd_mixer_elem_t *me;
+ int r;
+
+ pa_assert(e);
+ pa_assert(m);
+
+ SELEM_INIT(sid, e->alsa_name);
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+ pa_log_warn("Element %s seems to have disappeared.", e->alsa_name);
+ return -1;
+ }
+
+ if (e->switch_use == PA_ALSA_SWITCH_SELECT) {
+
+ if (e->direction == PA_ALSA_DIRECTION_OUTPUT)
+ r = snd_mixer_selem_set_playback_switch_all(me, alsa_idx);
+ else
+ r = snd_mixer_selem_set_capture_switch_all(me, alsa_idx);
+
+ if (r < 0)
+ pa_log_warn("Failed to set switch of %s: %s", e->alsa_name, pa_alsa_strerror(errno));
+
+ } else {
+ pa_assert(e->enumeration_use == PA_ALSA_ENUMERATION_SELECT);
+
+ if ((r = snd_mixer_selem_set_enum_item(me, 0, alsa_idx)) < 0)
+ pa_log_warn("Failed to set enumeration of %s: %s", e->alsa_name, pa_alsa_strerror(errno));
+ }
+
+ return r;
+}
+
+int pa_alsa_setting_select(pa_alsa_setting *s, snd_mixer_t *m) {
+ pa_alsa_option *o;
+ uint32_t idx;
+
+ pa_assert(s);
+ pa_assert(m);
+
+ PA_IDXSET_FOREACH(o, s->options, idx)
+ element_set_option(o->element, m, o->alsa_idx);
+
+ return 0;
+}
+
+static int option_verify(pa_alsa_option *o) {
+ static const struct description_map well_known_descriptions[] = {
+ { "input", N_("Input") },
+ { "input-docking", N_("Docking Station Input") },
+ { "input-docking-microphone", N_("Docking Station Microphone") },
+ { "input-docking-linein", N_("Docking Station Line-In") },
+ { "input-linein", N_("Line-In") },
+ { "input-microphone", N_("Microphone") },
+ { "input-microphone-front", N_("Front Microphone") },
+ { "input-microphone-rear", N_("Rear Microphone") },
+ { "input-microphone-external", N_("External Microphone") },
+ { "input-microphone-internal", N_("Internal Microphone") },
+ { "input-radio", N_("Radio") },
+ { "input-video", N_("Video") },
+ { "input-agc-on", N_("Automatic Gain Control") },
+ { "input-agc-off", N_("No Automatic Gain Control") },
+ { "input-boost-on", N_("Boost") },
+ { "input-boost-off", N_("No Boost") },
+ { "output-amplifier-on", N_("Amplifier") },
+ { "output-amplifier-off", N_("No Amplifier") },
+ { "output-bass-boost-on", N_("Bass Boost") },
+ { "output-bass-boost-off", N_("No Bass Boost") },
+ { "output-speaker", N_("Speaker") },
+ { "output-headphones", N_("Headphones") }
+ };
+
+ pa_assert(o);
+
+ if (!o->name) {
+ pa_log("No name set for option %s", o->alsa_name);
+ return -1;
+ }
+
+ if (o->element->enumeration_use != PA_ALSA_ENUMERATION_SELECT &&
+ o->element->switch_use != PA_ALSA_SWITCH_SELECT) {
+ pa_log("Element %s of option %s not set for select.", o->element->alsa_name, o->name);
+ return -1;
+ }
+
+ if (o->element->switch_use == PA_ALSA_SWITCH_SELECT &&
+ !pa_streq(o->alsa_name, "on") &&
+ !pa_streq(o->alsa_name, "off")) {
+ pa_log("Switch %s options need be named off or on ", o->element->alsa_name);
+ return -1;
+ }
+
+ if (!o->description)
+ o->description = pa_xstrdup(lookup_description(o->name,
+ well_known_descriptions,
+ PA_ELEMENTSOF(well_known_descriptions)));
+ if (!o->description)
+ o->description = pa_xstrdup(o->name);
+
+ return 0;
+}
+
+static int element_verify(pa_alsa_element *e) {
+ pa_alsa_option *o;
+
+ pa_assert(e);
+
+// pa_log_debug("Element %s, path %s: r=%d, r-any=%d, r-abs=%d", e->alsa_name, e->path->name, e->required, e->required_any, e->required_absent);
+ if ((e->required != PA_ALSA_REQUIRED_IGNORE && e->required == e->required_absent) ||
+ (e->required_any != PA_ALSA_REQUIRED_IGNORE && e->required_any == e->required_absent) ||
+ (e->required_absent == PA_ALSA_REQUIRED_ANY && e->required_any != PA_ALSA_REQUIRED_IGNORE) ||
+ (e->required_absent == PA_ALSA_REQUIRED_ANY && e->required != PA_ALSA_REQUIRED_IGNORE)) {
+ pa_log("Element %s cannot be required and absent at the same time.", e->alsa_name);
+ return -1;
+ }
+
+ if (e->switch_use == PA_ALSA_SWITCH_SELECT && e->enumeration_use == PA_ALSA_ENUMERATION_SELECT) {
+ pa_log("Element %s cannot set select for both switch and enumeration.", e->alsa_name);
+ return -1;
+ }
+
+ PA_LLIST_FOREACH(o, e->options)
+ if (option_verify(o) < 0)
+ return -1;
+
+ return 0;
+}
+
+static int path_verify(pa_alsa_path *p) {
+ static const struct description_map well_known_descriptions[] = {
+ { "analog-input", N_("Analog Input") },
+ { "analog-input-microphone", N_("Analog Microphone") },
+ { "analog-input-microphone-front", N_("Front Microphone") },
+ { "analog-input-microphone-rear", N_("Rear Microphone") },
+ { "analog-input-microphone-dock", N_("Docking Station Microphone") },
+ { "analog-input-microphone-internal", N_("Internal Microphone") },
+ { "analog-input-linein", N_("Analog Line-In") },
+ { "analog-input-radio", N_("Analog Radio") },
+ { "analog-input-video", N_("Analog Video") },
+ { "analog-output", N_("Analog Output") },
+ { "analog-output-headphones", N_("Analog Headphones") },
+ { "analog-output-lfe-on-mono", N_("Analog Output (LFE)") },
+ { "analog-output-mono", N_("Analog Mono Output") },
+ { "analog-output-speaker", N_("Analog Speakers") },
+ { "iec958-stereo-output", N_("Digital Output (IEC958)") },
+ { "iec958-passthrough-output", N_("Digital Passthrough (IEC958)") }
+ };
+
+ pa_alsa_element *e;
+
+ pa_assert(p);
+
+ PA_LLIST_FOREACH(e, p->elements)
+ if (element_verify(e) < 0)
+ return -1;
+
+ if (!p->description)
+ p->description = pa_xstrdup(lookup_description(p->name,
+ well_known_descriptions,
+ PA_ELEMENTSOF(well_known_descriptions)));
+
+ if (!p->description)
+ p->description = pa_xstrdup(p->name);
+
+ return 0;
+}
+
+pa_alsa_path* pa_alsa_path_new(const char *fname, pa_alsa_direction_t direction) {
+ pa_alsa_path *p;
+ char *fn;
+ int r;
+ const char *n;
+
+ pa_config_item items[] = {
+ /* [General] */
+ { "priority", pa_config_parse_unsigned, NULL, "General" },
+ { "description", pa_config_parse_string, NULL, "General" },
+ { "name", pa_config_parse_string, NULL, "General" },
+
+ /* [Option ...] */
+ { "priority", option_parse_priority, NULL, NULL },
+ { "name", option_parse_name, NULL, NULL },
+
+ /* [Element ...] */
+ { "switch", element_parse_switch, NULL, NULL },
+ { "volume", element_parse_volume, NULL, NULL },
+ { "enumeration", element_parse_enumeration, NULL, NULL },
+ { "override-map.1", element_parse_override_map, NULL, NULL },
+ { "override-map.2", element_parse_override_map, NULL, NULL },
+ /* ... later on we might add override-map.3 and so on here ... */
+ { "required", element_parse_required, NULL, NULL },
+ { "required-any", element_parse_required, NULL, NULL },
+ { "required-absent", element_parse_required, NULL, NULL },
+ { "direction", element_parse_direction, NULL, NULL },
+ { "direction-try-other", element_parse_direction_try_other, NULL, NULL },
+ { "volume-limit", element_parse_volume_limit, NULL, NULL },
+ { NULL, NULL, NULL, NULL }
+ };
+
+ pa_assert(fname);
+
+ p = pa_xnew0(pa_alsa_path, 1);
+ n = pa_path_get_filename(fname);
+ p->name = pa_xstrndup(n, strcspn(n, "."));
+ p->direction = direction;
+
+ items[0].data = &p->priority;
+ items[1].data = &p->description;
+ items[2].data = &p->name;
+
+ fn = pa_maybe_prefix_path(fname,
+ pa_run_from_build_tree() ? PA_BUILDDIR "/modules/alsa/mixer/paths/" :
+ PA_ALSA_PATHS_DIR);
+
+ r = pa_config_parse(fn, NULL, items, p);
+ pa_xfree(fn);
+
+ if (r < 0)
+ goto fail;
+
+ if (path_verify(p) < 0)
+ goto fail;
+
+ return p;
+
+fail:
+ pa_alsa_path_free(p);
+ return NULL;
+}
+
+pa_alsa_path *pa_alsa_path_synthesize(const char *element, pa_alsa_direction_t direction) {
+ pa_alsa_path *p;
+ pa_alsa_element *e;
+
+ pa_assert(element);
+
+ p = pa_xnew0(pa_alsa_path, 1);
+ p->name = pa_xstrdup(element);
+ p->direction = direction;
+
+ e = pa_xnew0(pa_alsa_element, 1);
+ e->path = p;
+ e->alsa_name = pa_xstrdup(element);
+ e->direction = direction;
+ e->volume_limit = -1;
+
+ e->switch_use = PA_ALSA_SWITCH_MUTE;
+ e->volume_use = PA_ALSA_VOLUME_MERGE;
+
+ PA_LLIST_PREPEND(pa_alsa_element, p->elements, e);
+ p->last_element = e;
+ return p;
+}
+
+static pa_bool_t element_drop_unsupported(pa_alsa_element *e) {
+ pa_alsa_option *o, *n;
+
+ pa_assert(e);
+
+ for (o = e->options; o; o = n) {
+ n = o->next;
+
+ if (o->alsa_idx < 0) {
+ PA_LLIST_REMOVE(pa_alsa_option, e->options, o);
+ option_free(o);
+ }
+ }
+
+ return
+ e->switch_use != PA_ALSA_SWITCH_IGNORE ||
+ e->volume_use != PA_ALSA_VOLUME_IGNORE ||
+ e->enumeration_use != PA_ALSA_ENUMERATION_IGNORE;
+}
+
+static void path_drop_unsupported(pa_alsa_path *p) {
+ pa_alsa_element *e, *n;
+
+ pa_assert(p);
+
+ for (e = p->elements; e; e = n) {
+ n = e->next;
+
+ if (!element_drop_unsupported(e)) {
+ PA_LLIST_REMOVE(pa_alsa_element, p->elements, e);
+ element_free(e);
+ }
+ }
+}
+
+static void path_make_options_unique(pa_alsa_path *p) {
+ pa_alsa_element *e;
+ pa_alsa_option *o, *u;
+
+ PA_LLIST_FOREACH(e, p->elements) {
+ PA_LLIST_FOREACH(o, e->options) {
+ unsigned i;
+ char *m;
+
+ for (u = o->next; u; u = u->next)
+ if (pa_streq(u->name, o->name))
+ break;
+
+ if (!u)
+ continue;
+
+ m = pa_xstrdup(o->name);
+
+ /* OK, this name is not unique, hence let's rename */
+ for (i = 1, u = o; u; u = u->next) {
+ char *nn, *nd;
+
+ if (!pa_streq(u->name, m))
+ continue;
+
+ nn = pa_sprintf_malloc("%s-%u", m, i);
+ pa_xfree(u->name);
+ u->name = nn;
+
+ nd = pa_sprintf_malloc("%s %u", u->description, i);
+ pa_xfree(u->description);
+ u->description = nd;
+
+ i++;
+ }
+
+ pa_xfree(m);
+ }
+ }
+}
+
+static pa_bool_t element_create_settings(pa_alsa_element *e, pa_alsa_setting *template) {
+ pa_alsa_option *o;
+
+ for (; e; e = e->next)
+ if (e->switch_use == PA_ALSA_SWITCH_SELECT ||
+ e->enumeration_use == PA_ALSA_ENUMERATION_SELECT)
+ break;
+
+ if (!e)
+ return FALSE;
+
+ for (o = e->options; o; o = o->next) {
+ pa_alsa_setting *s;
+
+ if (template) {
+ s = pa_xnewdup(pa_alsa_setting, template, 1);
+ s->options = pa_idxset_copy(template->options);
+ s->name = pa_sprintf_malloc(_("%s+%s"), template->name, o->name);
+ s->description =
+ (template->description[0] && o->description[0])
+ ? pa_sprintf_malloc(_("%s / %s"), template->description, o->description)
+ : (template->description[0]
+ ? pa_xstrdup(template->description)
+ : pa_xstrdup(o->description));
+
+ s->priority = PA_MAX(template->priority, o->priority);
+ } else {
+ s = pa_xnew0(pa_alsa_setting, 1);
+ s->options = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ s->name = pa_xstrdup(o->name);
+ s->description = pa_xstrdup(o->description);
+ s->priority = o->priority;
+ }
+
+ pa_idxset_put(s->options, o, NULL);
+
+ if (element_create_settings(e->next, s))
+ /* This is not a leaf, so let's get rid of it */
+ setting_free(s);
+ else {
+ /* This is a leaf, so let's add it */
+ PA_LLIST_INSERT_AFTER(pa_alsa_setting, e->path->settings, e->path->last_setting, s);
+
+ e->path->last_setting = s;
+ }
+ }
+
+ return TRUE;
+}
+
+static void path_create_settings(pa_alsa_path *p) {
+ pa_assert(p);
+
+ element_create_settings(p->elements, NULL);
+}
+
+int pa_alsa_path_probe(pa_alsa_path *p, snd_mixer_t *m, pa_bool_t ignore_dB) {
+ pa_alsa_element *e;
+ double min_dB[PA_CHANNEL_POSITION_MAX], max_dB[PA_CHANNEL_POSITION_MAX];
+ pa_channel_position_t t;
+ pa_channel_position_mask_t path_volume_channels = 0;
+
+ pa_assert(p);
+ pa_assert(m);
+
+ if (p->probed)
+ return 0;
+
+ pa_zero(min_dB);
+ pa_zero(max_dB);
+
+ pa_log_debug("Probing path '%s'", p->name);
+
+ PA_LLIST_FOREACH(e, p->elements) {
+ if (element_probe(e, m) < 0) {
+ p->supported = FALSE;
+ pa_log_debug("Probe of element '%s' failed.", e->alsa_name);
+ return -1;
+ }
+ pa_log_debug("Probe of element '%s' succeeded (volume=%d, switch=%d, enumeration=%d).", e->alsa_name, e->volume_use, e->switch_use, e->enumeration_use);
+
+ if (ignore_dB)
+ e->has_dB = FALSE;
+
+ if (e->volume_use == PA_ALSA_VOLUME_MERGE) {
+
+ if (!p->has_volume) {
+ p->min_volume = e->min_volume;
+ p->max_volume = e->max_volume;
+ }
+
+ if (e->has_dB) {
+ if (!p->has_volume) {
+ for (t = 0; t < PA_CHANNEL_POSITION_MAX; t++)
+ if (PA_CHANNEL_POSITION_MASK(t) & e->merged_mask) {
+ min_dB[t] = e->min_dB;
+ max_dB[t] = e->max_dB;
+ path_volume_channels |= PA_CHANNEL_POSITION_MASK(t);
+ }
+
+ p->has_dB = TRUE;
+ } else {
+
+ if (p->has_dB) {
+ for (t = 0; t < PA_CHANNEL_POSITION_MAX; t++)
+ if (PA_CHANNEL_POSITION_MASK(t) & e->merged_mask) {
+ min_dB[t] += e->min_dB;
+ max_dB[t] += e->max_dB;
+ path_volume_channels |= PA_CHANNEL_POSITION_MASK(t);
+ }
+ } else {
+ /* Hmm, there's another element before us
+ * which cannot do dB volumes, so we we need
+ * to 'neutralize' this slider */
+ e->volume_use = PA_ALSA_VOLUME_ZERO;
+ pa_log_info("Zeroing volume of '%s' on path '%s'", e->alsa_name, p->name);
+ }
+ }
+ } else if (p->has_volume) {
+ /* We can't use this volume, so let's ignore it */
+ e->volume_use = PA_ALSA_VOLUME_IGNORE;
+ pa_log_info("Ignoring volume of '%s' on path '%s' (missing dB info)", e->alsa_name, p->name);
+ }
+ p->has_volume = TRUE;
+ }
+
+ if (e->switch_use == PA_ALSA_SWITCH_MUTE)
+ p->has_mute = TRUE;
+ }
+
+ if (p->has_req_any && !p->req_any_present) {
+ p->supported = FALSE;
+ pa_log_debug("Skipping path '%s', none of required-any elements preset.", p->name);
+ return -1;
+ }
+
+ path_drop_unsupported(p);
+ path_make_options_unique(p);
+ path_create_settings(p);
+
+ p->supported = TRUE;
+ p->probed = TRUE;
+
+ p->min_dB = INFINITY;
+ p->max_dB = -INFINITY;
+
+ for (t = 0; t < PA_CHANNEL_POSITION_MAX; t++) {
+ if (path_volume_channels & PA_CHANNEL_POSITION_MASK(t)) {
+ if (p->min_dB > min_dB[t])
+ p->min_dB = min_dB[t];
+
+ if (p->max_dB < max_dB[t])
+ p->max_dB = max_dB[t];
+ }
+ }
+
+ return 0;
+}
+
+void pa_alsa_setting_dump(pa_alsa_setting *s) {
+ pa_assert(s);
+
+ pa_log_debug("Setting %s (%s) priority=%u",
+ s->name,
+ pa_strnull(s->description),
+ s->priority);
+}
+
+void pa_alsa_option_dump(pa_alsa_option *o) {
+ pa_assert(o);
+
+ pa_log_debug("Option %s (%s/%s) index=%i, priority=%u",
+ o->alsa_name,
+ pa_strnull(o->name),
+ pa_strnull(o->description),
+ o->alsa_idx,
+ o->priority);
+}
+
+void pa_alsa_element_dump(pa_alsa_element *e) {
+ pa_alsa_option *o;
+ pa_assert(e);
+
+ pa_log_debug("Element %s, direction=%i, switch=%i, volume=%i, volume_limit=%li, enumeration=%i, required=%i, required_any=%i, required_absent=%i, mask=0x%llx, n_channels=%u, override_map=%s",
+ e->alsa_name,
+ e->direction,
+ e->switch_use,
+ e->volume_use,
+ e->volume_limit,
+ e->enumeration_use,
+ e->required,
+ e->required_any,
+ e->required_absent,
+ (long long unsigned) e->merged_mask,
+ e->n_channels,
+ pa_yes_no(e->override_map));
+
+ PA_LLIST_FOREACH(o, e->options)
+ pa_alsa_option_dump(o);
+}
+
+void pa_alsa_path_dump(pa_alsa_path *p) {
+ pa_alsa_element *e;
+ pa_alsa_setting *s;
+ pa_assert(p);
+
+ pa_log_debug("Path %s (%s), direction=%i, priority=%u, probed=%s, supported=%s, has_mute=%s, has_volume=%s, "
+ "has_dB=%s, min_volume=%li, max_volume=%li, min_dB=%g, max_dB=%g",
+ p->name,
+ pa_strnull(p->description),
+ p->direction,
+ p->priority,
+ pa_yes_no(p->probed),
+ pa_yes_no(p->supported),
+ pa_yes_no(p->has_mute),
+ pa_yes_no(p->has_volume),
+ pa_yes_no(p->has_dB),
+ p->min_volume, p->max_volume,
+ p->min_dB, p->max_dB);
+
+ PA_LLIST_FOREACH(e, p->elements)
+ pa_alsa_element_dump(e);
+
+ PA_LLIST_FOREACH(s, p->settings)
+ pa_alsa_setting_dump(s);
+}
+
+static void element_set_callback(pa_alsa_element *e, snd_mixer_t *m, snd_mixer_elem_callback_t cb, void *userdata) {
+ snd_mixer_selem_id_t *sid;
+ snd_mixer_elem_t *me;
+
+ pa_assert(e);
+ pa_assert(m);
+ pa_assert(cb);
+
+ SELEM_INIT(sid, e->alsa_name);
+ if (!(me = snd_mixer_find_selem(m, sid))) {
+ pa_log_warn("Element %s seems to have disappeared.", e->alsa_name);
+ return;
+ }
+
+ snd_mixer_elem_set_callback(me, cb);
+ snd_mixer_elem_set_callback_private(me, userdata);
+}
+
+void pa_alsa_path_set_callback(pa_alsa_path *p, snd_mixer_t *m, snd_mixer_elem_callback_t cb, void *userdata) {
+ pa_alsa_element *e;
+
+ pa_assert(p);
+ pa_assert(m);
+ pa_assert(cb);
+
+ PA_LLIST_FOREACH(e, p->elements)
+ element_set_callback(e, m, cb, userdata);
+}
+
+void pa_alsa_path_set_set_callback(pa_alsa_path_set *ps, snd_mixer_t *m, snd_mixer_elem_callback_t cb, void *userdata) {
+ pa_alsa_path *p;
+
+ pa_assert(ps);
+ pa_assert(m);
+ pa_assert(cb);
+
+ PA_LLIST_FOREACH(p, ps->paths)
+ pa_alsa_path_set_callback(p, m, cb, userdata);
+}
+
+pa_alsa_path_set *pa_alsa_path_set_new(pa_alsa_mapping *m, pa_alsa_direction_t direction) {
+ pa_alsa_path_set *ps;
+ char **pn = NULL, **en = NULL, **ie;
+ pa_alsa_decibel_fix *db_fix;
+ void *state;
+
+ pa_assert(m);
+ pa_assert(m->profile_set);
+ pa_assert(m->profile_set->decibel_fixes);
+ pa_assert(direction == PA_ALSA_DIRECTION_OUTPUT || direction == PA_ALSA_DIRECTION_INPUT);
+
+ if (m->direction != PA_ALSA_DIRECTION_ANY && m->direction != direction)
+ return NULL;
+
+ ps = pa_xnew0(pa_alsa_path_set, 1);
+ ps->direction = direction;
+
+ if (direction == PA_ALSA_DIRECTION_OUTPUT)
+ pn = m->output_path_names;
+ else if (direction == PA_ALSA_DIRECTION_INPUT)
+ pn = m->input_path_names;
+
+ if (pn) {
+ char **in;
+
+ for (in = pn; *in; in++) {
+ pa_alsa_path *p;
+ pa_bool_t duplicate = FALSE;
+ char **kn, *fn;
+
+ for (kn = pn; kn < in; kn++)
+ if (pa_streq(*kn, *in)) {
+ duplicate = TRUE;
+ break;
+ }
+
+ if (duplicate)
+ continue;
+
+ fn = pa_sprintf_malloc("%s.conf", *in);
+
+ if ((p = pa_alsa_path_new(fn, direction))) {
+ p->path_set = ps;
+ PA_LLIST_INSERT_AFTER(pa_alsa_path, ps->paths, ps->last_path, p);
+ ps->last_path = p;
+ }
+
+ pa_xfree(fn);
+ }
+
+ goto finish;
+ }
+
+ if (direction == PA_ALSA_DIRECTION_OUTPUT)
+ en = m->output_element;
+ else if (direction == PA_ALSA_DIRECTION_INPUT)
+ en = m->input_element;
+
+ if (!en) {
+ pa_alsa_path_set_free(ps);
+ return NULL;
+ }
+
+ for (ie = en; *ie; ie++) {
+ char **je;
+ pa_alsa_path *p;
+
+ p = pa_alsa_path_synthesize(*ie, direction);
+ p->path_set = ps;
+
+ /* Mark all other passed elements for require-absent */
+ for (je = en; *je; je++) {
+ pa_alsa_element *e;
+
+ if (je == ie)
+ continue;
+
+ e = pa_xnew0(pa_alsa_element, 1);
+ e->path = p;
+ e->alsa_name = pa_xstrdup(*je);
+ e->direction = direction;
+ e->required_absent = PA_ALSA_REQUIRED_ANY;
+ e->volume_limit = -1;
+
+ PA_LLIST_INSERT_AFTER(pa_alsa_element, p->elements, p->last_element, e);
+ p->last_element = e;
+ }
+
+ PA_LLIST_INSERT_AFTER(pa_alsa_path, ps->paths, ps->last_path, p);
+ ps->last_path = p;
+ }
+
+finish:
+ /* Assign decibel fixes to elements. */
+ PA_HASHMAP_FOREACH(db_fix, m->profile_set->decibel_fixes, state) {
+ pa_alsa_path *p;
+
+ PA_LLIST_FOREACH(p, ps->paths) {
+ pa_alsa_element *e;
+
+ PA_LLIST_FOREACH(e, p->elements) {
+ if (e->volume_use != PA_ALSA_VOLUME_IGNORE && pa_streq(db_fix->name, e->alsa_name)) {
+ /* The profile set that contains the dB fix may be freed
+ * before the element, so we have to copy the dB fix
+ * object. */
+ e->db_fix = pa_xnewdup(pa_alsa_decibel_fix, db_fix, 1);
+ e->db_fix->profile_set = NULL;
+ e->db_fix->name = pa_xstrdup(db_fix->name);
+ e->db_fix->db_values = pa_xmemdup(db_fix->db_values, (db_fix->max_step - db_fix->min_step + 1) * sizeof(long));
+ }
+ }
+ }
+ }
+
+ return ps;
+}
+
+void pa_alsa_path_set_dump(pa_alsa_path_set *ps) {
+ pa_alsa_path *p;
+ pa_assert(ps);
+
+ pa_log_debug("Path Set %p, direction=%i, probed=%s",
+ (void*) ps,
+ ps->direction,
+ pa_yes_no(ps->probed));
+
+ PA_LLIST_FOREACH(p, ps->paths)
+ pa_alsa_path_dump(p);
+}
+
+static void path_set_unify(pa_alsa_path_set *ps) {
+ pa_alsa_path *p;
+ pa_bool_t has_dB = TRUE, has_volume = TRUE, has_mute = TRUE;
+ pa_assert(ps);
+
+ /* We have issues dealing with paths that vary too wildly. That
+ * means for now we have to have all paths support volume/mute/dB
+ * or none. */
+
+ PA_LLIST_FOREACH(p, ps->paths) {
+ pa_assert(p->probed);
+
+ if (!p->has_volume)
+ has_volume = FALSE;
+ else if (!p->has_dB)
+ has_dB = FALSE;
+
+ if (!p->has_mute)
+ has_mute = FALSE;
+ }
+
+ if (!has_volume || !has_dB || !has_mute) {
+
+ if (!has_volume)
+ pa_log_debug("Some paths of the device lack hardware volume control, disabling hardware control altogether.");
+ else if (!has_dB)
+ pa_log_debug("Some paths of the device lack dB information, disabling dB logic altogether.");
+
+ if (!has_mute)
+ pa_log_debug("Some paths of the device lack hardware mute control, disabling hardware control altogether.");
+
+ PA_LLIST_FOREACH(p, ps->paths) {
+ if (!has_volume)
+ p->has_volume = FALSE;
+ else if (!has_dB)
+ p->has_dB = FALSE;
+
+ if (!has_mute)
+ p->has_mute = FALSE;
+ }
+ }
+}
+
+static void path_set_make_paths_unique(pa_alsa_path_set *ps) {
+ pa_alsa_path *p, *q;
+
+ PA_LLIST_FOREACH(p, ps->paths) {
+ unsigned i;
+ char *m;
+
+ for (q = p->next; q; q = q->next)
+ if (pa_streq(q->name, p->name))
+ break;
+
+ if (!q)
+ continue;
+
+ m = pa_xstrdup(p->name);
+
+ /* OK, this name is not unique, hence let's rename */
+ for (i = 1, q = p; q; q = q->next) {
+ char *nn, *nd;
+
+ if (!pa_streq(q->name, m))
+ continue;
+
+ nn = pa_sprintf_malloc("%s-%u", m, i);
+ pa_xfree(q->name);
+ q->name = nn;
+
+ nd = pa_sprintf_malloc("%s %u", q->description, i);
+ pa_xfree(q->description);
+ q->description = nd;
+
+ i++;
+ }
+
+ pa_xfree(m);
+ }
+}
+
+void pa_alsa_path_set_probe(pa_alsa_path_set *ps, snd_mixer_t *m, pa_bool_t ignore_dB) {
+ pa_alsa_path *p, *n;
+
+ pa_assert(ps);
+
+ if (ps->probed)
+ return;
+
+ for (p = ps->paths; p; p = n) {
+ n = p->next;
+
+ if (pa_alsa_path_probe(p, m, ignore_dB) < 0) {
+ PA_LLIST_REMOVE(pa_alsa_path, ps->paths, p);
+ pa_alsa_path_free(p);
+ }
+ }
+
+ path_set_unify(ps);
+ path_set_make_paths_unique(ps);
+ ps->probed = TRUE;
+}
+
+static void mapping_free(pa_alsa_mapping *m) {
+ pa_assert(m);
+
+ pa_xfree(m->name);
+ pa_xfree(m->description);
+
+ pa_xstrfreev(m->device_strings);
+ pa_xstrfreev(m->input_path_names);
+ pa_xstrfreev(m->output_path_names);
+ pa_xstrfreev(m->input_element);
+ pa_xstrfreev(m->output_element);
+
+ pa_assert(!m->input_pcm);
+ pa_assert(!m->output_pcm);
+
+ pa_xfree(m);
+}
+
+static void profile_free(pa_alsa_profile *p) {
+ pa_assert(p);
+
+ pa_xfree(p->name);
+ pa_xfree(p->description);
+
+ pa_xstrfreev(p->input_mapping_names);
+ pa_xstrfreev(p->output_mapping_names);
+
+ if (p->input_mappings)
+ pa_idxset_free(p->input_mappings, NULL, NULL);
+
+ if (p->output_mappings)
+ pa_idxset_free(p->output_mappings, NULL, NULL);
+
+ pa_xfree(p);
+}
+
+void pa_alsa_profile_set_free(pa_alsa_profile_set *ps) {
+ pa_assert(ps);
+
+ if (ps->profiles) {
+ pa_alsa_profile *p;
+
+ while ((p = pa_hashmap_steal_first(ps->profiles)))
+ profile_free(p);
+
+ pa_hashmap_free(ps->profiles, NULL, NULL);
+ }
+
+ if (ps->mappings) {
+ pa_alsa_mapping *m;
+
+ while ((m = pa_hashmap_steal_first(ps->mappings)))
+ mapping_free(m);
+
+ pa_hashmap_free(ps->mappings, NULL, NULL);
+ }
+
+ if (ps->decibel_fixes) {
+ pa_alsa_decibel_fix *db_fix;
+
+ while ((db_fix = pa_hashmap_steal_first(ps->decibel_fixes)))
+ decibel_fix_free(db_fix);
+
+ pa_hashmap_free(ps->decibel_fixes, NULL, NULL);
+ }
+
+ pa_xfree(ps);
+}
+
+static pa_alsa_mapping *mapping_get(pa_alsa_profile_set *ps, const char *name) {
+ pa_alsa_mapping *m;
+
+ if (!pa_startswith(name, "Mapping "))
+ return NULL;
+
+ name += 8;
+
+ if ((m = pa_hashmap_get(ps->mappings, name)))
+ return m;
+
+ m = pa_xnew0(pa_alsa_mapping, 1);
+ m->profile_set = ps;
+ m->name = pa_xstrdup(name);
+ pa_channel_map_init(&m->channel_map);
+
+ pa_hashmap_put(ps->mappings, m->name, m);
+
+ return m;
+}
+
+static pa_alsa_profile *profile_get(pa_alsa_profile_set *ps, const char *name) {
+ pa_alsa_profile *p;
+
+ if (!pa_startswith(name, "Profile "))
+ return NULL;
+
+ name += 8;
+
+ if ((p = pa_hashmap_get(ps->profiles, name)))
+ return p;
+
+ p = pa_xnew0(pa_alsa_profile, 1);
+ p->profile_set = ps;
+ p->name = pa_xstrdup(name);
+
+ pa_hashmap_put(ps->profiles, p->name, p);
+
+ return p;
+}
+
+static pa_alsa_decibel_fix *decibel_fix_get(pa_alsa_profile_set *ps, const char *name) {
+ pa_alsa_decibel_fix *db_fix;
+
+ if (!pa_startswith(name, "DecibelFix "))
+ return NULL;
+
+ name += 11;
+
+ if ((db_fix = pa_hashmap_get(ps->decibel_fixes, name)))
+ return db_fix;
+
+ db_fix = pa_xnew0(pa_alsa_decibel_fix, 1);
+ db_fix->profile_set = ps;
+ db_fix->name = pa_xstrdup(name);
+
+ pa_hashmap_put(ps->decibel_fixes, db_fix->name, db_fix);
+
+ return db_fix;
+}
+
+static int mapping_parse_device_strings(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_mapping *m;
+
+ pa_assert(ps);
+
+ if (!(m = mapping_get(ps, section))) {
+ pa_log("[%s:%u] %s invalid in section %s", filename, line, lvalue, section);
+ return -1;
+ }
+
+ pa_xstrfreev(m->device_strings);
+ if (!(m->device_strings = pa_split_spaces_strv(rvalue))) {
+ pa_log("[%s:%u] Device string list empty of '%s'", filename, line, section);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int mapping_parse_channel_map(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_mapping *m;
+
+ pa_assert(ps);
+
+ if (!(m = mapping_get(ps, section))) {
+ pa_log("[%s:%u] %s invalid in section %s", filename, line, lvalue, section);
+ return -1;
+ }
+
+ if (!(pa_channel_map_parse(&m->channel_map, rvalue))) {
+ pa_log("[%s:%u] Channel map invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int mapping_parse_paths(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_mapping *m;
+
+ pa_assert(ps);
+
+ if (!(m = mapping_get(ps, section))) {
+ pa_log("[%s:%u] %s invalid in section %s", filename, line, lvalue, section);
+ return -1;
+ }
+
+ if (pa_streq(lvalue, "paths-input")) {
+ pa_xstrfreev(m->input_path_names);
+ m->input_path_names = pa_split_spaces_strv(rvalue);
+ } else {
+ pa_xstrfreev(m->output_path_names);
+ m->output_path_names = pa_split_spaces_strv(rvalue);
+ }
+
+ return 0;
+}
+
+static int mapping_parse_element(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_mapping *m;
+
+ pa_assert(ps);
+
+ if (!(m = mapping_get(ps, section))) {
+ pa_log("[%s:%u] %s invalid in section %s", filename, line, lvalue, section);
+ return -1;
+ }
+
+ if (pa_streq(lvalue, "element-input")) {
+ pa_xstrfreev(m->input_element);
+ m->input_element = pa_split_spaces_strv(rvalue);
+ } else {
+ pa_xstrfreev(m->output_element);
+ m->output_element = pa_split_spaces_strv(rvalue);
+ }
+
+ return 0;
+}
+
+static int mapping_parse_direction(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_mapping *m;
+
+ pa_assert(ps);
+
+ if (!(m = mapping_get(ps, section))) {
+ pa_log("[%s:%u] Section name %s invalid.", filename, line, section);
+ return -1;
+ }
+
+ if (pa_streq(rvalue, "input"))
+ m->direction = PA_ALSA_DIRECTION_INPUT;
+ else if (pa_streq(rvalue, "output"))
+ m->direction = PA_ALSA_DIRECTION_OUTPUT;
+ else if (pa_streq(rvalue, "any"))
+ m->direction = PA_ALSA_DIRECTION_ANY;
+ else {
+ pa_log("[%s:%u] Direction %s invalid.", filename, line, rvalue);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int mapping_parse_description(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_profile *p;
+ pa_alsa_mapping *m;
+
+ pa_assert(ps);
+
+ if ((m = mapping_get(ps, section))) {
+ pa_xfree(m->description);
+ m->description = pa_xstrdup(rvalue);
+ } else if ((p = profile_get(ps, section))) {
+ pa_xfree(p->description);
+ p->description = pa_xstrdup(rvalue);
+ } else {
+ pa_log("[%s:%u] Section name %s invalid.", filename, line, section);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int mapping_parse_priority(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_profile *p;
+ pa_alsa_mapping *m;
+ uint32_t prio;
+
+ pa_assert(ps);
+
+ if (pa_atou(rvalue, &prio) < 0) {
+ pa_log("[%s:%u] Priority invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ if ((m = mapping_get(ps, section)))
+ m->priority = prio;
+ else if ((p = profile_get(ps, section)))
+ p->priority = prio;
+ else {
+ pa_log("[%s:%u] Section name %s invalid.", filename, line, section);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int profile_parse_mappings(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_profile *p;
+
+ pa_assert(ps);
+
+ if (!(p = profile_get(ps, section))) {
+ pa_log("[%s:%u] %s invalid in section %s", filename, line, lvalue, section);
+ return -1;
+ }
+
+ if (pa_streq(lvalue, "input-mappings")) {
+ pa_xstrfreev(p->input_mapping_names);
+ p->input_mapping_names = pa_split_spaces_strv(rvalue);
+ } else {
+ pa_xstrfreev(p->output_mapping_names);
+ p->output_mapping_names = pa_split_spaces_strv(rvalue);
+ }
+
+ return 0;
+}
+
+static int profile_parse_skip_probe(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_profile *p;
+ int b;
+
+ pa_assert(ps);
+
+ if (!(p = profile_get(ps, section))) {
+ pa_log("[%s:%u] %s invalid in section %s", filename, line, lvalue, section);
+ return -1;
+ }
+
+ if ((b = pa_parse_boolean(rvalue)) < 0) {
+ pa_log("[%s:%u] Skip probe invalid of '%s'", filename, line, section);
+ return -1;
+ }
+
+ p->supported = b;
+
+ return 0;
+}
+
+static int decibel_fix_parse_db_values(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ pa_alsa_profile_set *ps = userdata;
+ pa_alsa_decibel_fix *db_fix;
+ char **items;
+ char *item;
+ long *db_values;
+ unsigned n = 8; /* Current size of the db_values table. */
+ unsigned min_step = 0;
+ unsigned max_step = 0;
+ unsigned i = 0; /* Index to the items table. */
+ unsigned prev_step = 0;
+ double prev_db = 0;
+
+ pa_assert(filename);
+ pa_assert(section);
+ pa_assert(lvalue);
+ pa_assert(rvalue);
+ pa_assert(ps);
+
+ if (!(db_fix = decibel_fix_get(ps, section))) {
+ pa_log("[%s:%u] %s invalid in section %s", filename, line, lvalue, section);
+ return -1;
+ }
+
+ if (!(items = pa_split_spaces_strv(rvalue))) {
+ pa_log("[%s:%u] Value missing", pa_strnull(filename), line);
+ return -1;
+ }
+
+ db_values = pa_xnew(long, n);
+
+ while ((item = items[i++])) {
+ char *s = item; /* Step value string. */
+ char *d = item; /* dB value string. */
+ uint32_t step;
+ double db;
+
+ /* Move d forward until it points to a colon or to the end of the item. */
+ for (; *d && *d != ':'; ++d);
+
+ if (d == s) {
+ /* item started with colon. */
+ pa_log("[%s:%u] No step value found in %s", filename, line, item);
+ goto fail;
+ }
+
+ if (!*d || !*(d + 1)) {
+ /* No colon found, or it was the last character in item. */
+ pa_log("[%s:%u] No dB value found in %s", filename, line, item);
+ goto fail;
+ }
+
+ /* pa_atou() needs a null-terminating string. Let's replace the colon
+ * with a zero byte. */
+ *d++ = '\0';
+
+ if (pa_atou(s, &step) < 0) {
+ pa_log("[%s:%u] Invalid step value: %s", filename, line, s);
+ goto fail;
+ }
+
+ if (pa_atod(d, &db) < 0) {
+ pa_log("[%s:%u] Invalid dB value: %s", filename, line, d);
+ goto fail;
+ }
+
+ if (step <= prev_step && i != 1) {
+ pa_log("[%s:%u] Step value %u not greater than the previous value %u", filename, line, step, prev_step);
+ goto fail;
+ }
+
+ if (db < prev_db && i != 1) {
+ pa_log("[%s:%u] Decibel value %0.2f less than the previous value %0.2f", filename, line, db, prev_db);
+ goto fail;
+ }
+
+ if (i == 1) {
+ min_step = step;
+ db_values[0] = (long) (db * 100.0);
+ prev_step = step;
+ prev_db = db;
+ } else {
+ /* Interpolate linearly. */
+ double db_increment = (db - prev_db) / (step - prev_step);
+
+ for (; prev_step < step; ++prev_step, prev_db += db_increment) {
+
+ /* Reallocate the db_values table if it's about to overflow. */
+ if (prev_step + 1 - min_step == n) {
+ n *= 2;
+ db_values = pa_xrenew(long, db_values, n);
+ }
+
+ db_values[prev_step + 1 - min_step] = (long) ((prev_db + db_increment) * 100.0);
+ }
+ }
+
+ max_step = step;
+ }
+
+ db_fix->min_step = min_step;
+ db_fix->max_step = max_step;
+ pa_xfree(db_fix->db_values);
+ db_fix->db_values = db_values;
+
+ pa_xstrfreev(items);
+
+ return 0;
+
+fail:
+ pa_xstrfreev(items);
+ pa_xfree(db_values);
+
+ return -1;
+}
+
+static int mapping_verify(pa_alsa_mapping *m, const pa_channel_map *bonus) {
+
+ static const struct description_map well_known_descriptions[] = {
+ { "analog-mono", N_("Analog Mono") },
+ { "analog-stereo", N_("Analog Stereo") },
+ { "analog-surround-21", N_("Analog Surround 2.1") },
+ { "analog-surround-30", N_("Analog Surround 3.0") },
+ { "analog-surround-31", N_("Analog Surround 3.1") },
+ { "analog-surround-40", N_("Analog Surround 4.0") },
+ { "analog-surround-41", N_("Analog Surround 4.1") },
+ { "analog-surround-50", N_("Analog Surround 5.0") },
+ { "analog-surround-51", N_("Analog Surround 5.1") },
+ { "analog-surround-61", N_("Analog Surround 6.0") },
+ { "analog-surround-61", N_("Analog Surround 6.1") },
+ { "analog-surround-70", N_("Analog Surround 7.0") },
+ { "analog-surround-71", N_("Analog Surround 7.1") },
+ { "iec958-stereo", N_("Digital Stereo (IEC958)") },
+ { "iec958-passthrough", N_("Digital Passthrough (IEC958)") },
+ { "iec958-ac3-surround-40", N_("Digital Surround 4.0 (IEC958/AC3)") },
+ { "iec958-ac3-surround-51", N_("Digital Surround 5.1 (IEC958/AC3)") },
+ { "hdmi-stereo", N_("Digital Stereo (HDMI)") }
+ };
+
+ pa_assert(m);
+
+ if (!pa_channel_map_valid(&m->channel_map)) {
+ pa_log("Mapping %s is missing channel map.", m->name);
+ return -1;
+ }
+
+ if (!m->device_strings) {
+ pa_log("Mapping %s is missing device strings.", m->name);
+ return -1;
+ }
+
+ if ((m->input_path_names && m->input_element) ||
+ (m->output_path_names && m->output_element)) {
+ pa_log("Mapping %s must have either mixer path or mixer element, not both.", m->name);
+ return -1;
+ }
+
+ if (!m->description)
+ m->description = pa_xstrdup(lookup_description(m->name,
+ well_known_descriptions,
+ PA_ELEMENTSOF(well_known_descriptions)));
+
+ if (!m->description)
+ m->description = pa_xstrdup(m->name);
+
+ if (bonus) {
+ if (pa_channel_map_equal(&m->channel_map, bonus))
+ m->priority += 50;
+ else if (m->channel_map.channels == bonus->channels)
+ m->priority += 30;
+ }
+
+ return 0;
+}
+
+void pa_alsa_mapping_dump(pa_alsa_mapping *m) {
+ char cm[PA_CHANNEL_MAP_SNPRINT_MAX];
+
+ pa_assert(m);
+
+ pa_log_debug("Mapping %s (%s), priority=%u, channel_map=%s, supported=%s, direction=%i",
+ m->name,
+ pa_strnull(m->description),
+ m->priority,
+ pa_channel_map_snprint(cm, sizeof(cm), &m->channel_map),
+ pa_yes_no(m->supported),
+ m->direction);
+}
+
+static void profile_set_add_auto_pair(
+ pa_alsa_profile_set *ps,
+ pa_alsa_mapping *m, /* output */
+ pa_alsa_mapping *n /* input */) {
+
+ char *name;
+ pa_alsa_profile *p;
+
+ pa_assert(ps);
+ pa_assert(m || n);
+
+ if (m && m->direction == PA_ALSA_DIRECTION_INPUT)
+ return;
+
+ if (n && n->direction == PA_ALSA_DIRECTION_OUTPUT)
+ return;
+
+ if (m && n)
+ name = pa_sprintf_malloc("output:%s+input:%s", m->name, n->name);
+ else if (m)
+ name = pa_sprintf_malloc("output:%s", m->name);
+ else
+ name = pa_sprintf_malloc("input:%s", n->name);
+
+ if (pa_hashmap_get(ps->profiles, name)) {
+ pa_xfree(name);
+ return;
+ }
+
+ p = pa_xnew0(pa_alsa_profile, 1);
+ p->profile_set = ps;
+ p->name = name;
+
+ if (m) {
+ p->output_mappings = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ pa_idxset_put(p->output_mappings, m, NULL);
+ p->priority += m->priority * 100;
+ }
+
+ if (n) {
+ p->input_mappings = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ pa_idxset_put(p->input_mappings, n, NULL);
+ p->priority += n->priority;
+ }
+
+ pa_hashmap_put(ps->profiles, p->name, p);
+}
+
+static void profile_set_add_auto(pa_alsa_profile_set *ps) {
+ pa_alsa_mapping *m, *n;
+ void *m_state, *n_state;
+
+ pa_assert(ps);
+
+ PA_HASHMAP_FOREACH(m, ps->mappings, m_state) {
+ profile_set_add_auto_pair(ps, m, NULL);
+
+ PA_HASHMAP_FOREACH(n, ps->mappings, n_state)
+ profile_set_add_auto_pair(ps, m, n);
+ }
+
+ PA_HASHMAP_FOREACH(n, ps->mappings, n_state)
+ profile_set_add_auto_pair(ps, NULL, n);
+}
+
+static int profile_verify(pa_alsa_profile *p) {
+
+ static const struct description_map well_known_descriptions[] = {
+ { "output:analog-mono+input:analog-mono", N_("Analog Mono Duplex") },
+ { "output:analog-stereo+input:analog-stereo", N_("Analog Stereo Duplex") },
+ { "output:iec958-stereo+input:iec958-stereo", N_("Digital Stereo Duplex (IEC958)") },
+ { "off", N_("Off") }
+ };
+
+ pa_assert(p);
+
+ /* Replace the output mapping names by the actual mappings */
+ if (p->output_mapping_names) {
+ char **name;
+
+ pa_assert(!p->output_mappings);
+ p->output_mappings = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+
+ for (name = p->output_mapping_names; *name; name++) {
+ pa_alsa_mapping *m;
+ char **in;
+ pa_bool_t duplicate = FALSE;
+
+ for (in = name + 1; *in; in++)
+ if (pa_streq(*name, *in)) {
+ duplicate = TRUE;
+ break;
+ }
+
+ if (duplicate)
+ continue;
+
+ if (!(m = pa_hashmap_get(p->profile_set->mappings, *name)) || m->direction == PA_ALSA_DIRECTION_INPUT) {
+ pa_log("Profile '%s' refers to unexistant mapping '%s'.", p->name, *name);
+ return -1;
+ }
+
+ pa_idxset_put(p->output_mappings, m, NULL);
+
+ if (p->supported)
+ m->supported++;
+ }
+
+ pa_xstrfreev(p->output_mapping_names);
+ p->output_mapping_names = NULL;
+ }
+
+ /* Replace the input mapping names by the actual mappings */
+ if (p->input_mapping_names) {
+ char **name;
+
+ pa_assert(!p->input_mappings);
+ p->input_mappings = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+
+ for (name = p->input_mapping_names; *name; name++) {
+ pa_alsa_mapping *m;
+ char **in;
+ pa_bool_t duplicate = FALSE;
+
+ for (in = name + 1; *in; in++)
+ if (pa_streq(*name, *in)) {
+ duplicate = TRUE;
+ break;
+ }
+
+ if (duplicate)
+ continue;
+
+ if (!(m = pa_hashmap_get(p->profile_set->mappings, *name)) || m->direction == PA_ALSA_DIRECTION_OUTPUT) {
+ pa_log("Profile '%s' refers to unexistant mapping '%s'.", p->name, *name);
+ return -1;
+ }
+
+ pa_idxset_put(p->input_mappings, m, NULL);
+
+ if (p->supported)
+ m->supported++;
+ }
+
+ pa_xstrfreev(p->input_mapping_names);
+ p->input_mapping_names = NULL;
+ }
+
+ if (!p->input_mappings && !p->output_mappings) {
+ pa_log("Profile '%s' lacks mappings.", p->name);
+ return -1;
+ }
+
+ if (!p->description)
+ p->description = pa_xstrdup(lookup_description(p->name,
+ well_known_descriptions,
+ PA_ELEMENTSOF(well_known_descriptions)));
+
+ if (!p->description) {
+ pa_strbuf *sb;
+ uint32_t idx;
+ pa_alsa_mapping *m;
+
+ sb = pa_strbuf_new();
+
+ if (p->output_mappings)
+ PA_IDXSET_FOREACH(m, p->output_mappings, idx) {
+ if (!pa_strbuf_isempty(sb))
+ pa_strbuf_puts(sb, " + ");
+
+ pa_strbuf_printf(sb, _("%s Output"), m->description);
+ }
+
+ if (p->input_mappings)
+ PA_IDXSET_FOREACH(m, p->input_mappings, idx) {
+ if (!pa_strbuf_isempty(sb))
+ pa_strbuf_puts(sb, " + ");
+
+ pa_strbuf_printf(sb, _("%s Input"), m->description);
+ }
+
+ p->description = pa_strbuf_tostring_free(sb);
+ }
+
+ return 0;
+}
+
+void pa_alsa_profile_dump(pa_alsa_profile *p) {
+ uint32_t idx;
+ pa_alsa_mapping *m;
+ pa_assert(p);
+
+ pa_log_debug("Profile %s (%s), priority=%u, supported=%s n_input_mappings=%u, n_output_mappings=%u",
+ p->name,
+ pa_strnull(p->description),
+ p->priority,
+ pa_yes_no(p->supported),
+ p->input_mappings ? pa_idxset_size(p->input_mappings) : 0,
+ p->output_mappings ? pa_idxset_size(p->output_mappings) : 0);
+
+ if (p->input_mappings)
+ PA_IDXSET_FOREACH(m, p->input_mappings, idx)
+ pa_log_debug("Input %s", m->name);
+
+ if (p->output_mappings)
+ PA_IDXSET_FOREACH(m, p->output_mappings, idx)
+ pa_log_debug("Output %s", m->name);
+}
+
+static int decibel_fix_verify(pa_alsa_decibel_fix *db_fix) {
+ pa_assert(db_fix);
+
+ /* Check that the dB mapping has been configured. Since "db-values" is
+ * currently the only option in the DecibelFix section, and decibel fix
+ * objects don't get created if a DecibelFix section is empty, this is
+ * actually a redundant check. Having this may prevent future bugs,
+ * however. */
+ if (!db_fix->db_values) {
+ pa_log("Decibel fix for element %s lacks the dB values.", db_fix->name);
+ return -1;
+ }
+
+ return 0;
+}
+
+void pa_alsa_decibel_fix_dump(pa_alsa_decibel_fix *db_fix) {
+ char *db_values = NULL;
+
+ pa_assert(db_fix);
+
+ if (db_fix->db_values) {
+ pa_strbuf *buf;
+ unsigned long i, nsteps;
+
+ pa_assert(db_fix->min_step <= db_fix->max_step);
+ nsteps = db_fix->max_step - db_fix->min_step + 1;
+
+ buf = pa_strbuf_new();
+ for (i = 0; i < nsteps; ++i)
+ pa_strbuf_printf(buf, "[%li]:%0.2f ", i + db_fix->min_step, db_fix->db_values[i] / 100.0);
+
+ db_values = pa_strbuf_tostring_free(buf);
+ }
+
+ pa_log_debug("Decibel fix %s, min_step=%li, max_step=%li, db_values=%s",
+ db_fix->name, db_fix->min_step, db_fix->max_step, pa_strnull(db_values));
+
+ pa_xfree(db_values);
+}
+
+pa_alsa_profile_set* pa_alsa_profile_set_new(const char *fname, const pa_channel_map *bonus) {
+ pa_alsa_profile_set *ps;
+ pa_alsa_profile *p;
+ pa_alsa_mapping *m;
+ pa_alsa_decibel_fix *db_fix;
+ char *fn;
+ int r;
+ void *state;
+
+ static pa_config_item items[] = {
+ /* [General] */
+ { "auto-profiles", pa_config_parse_bool, NULL, "General" },
+
+ /* [Mapping ...] */
+ { "device-strings", mapping_parse_device_strings, NULL, NULL },
+ { "channel-map", mapping_parse_channel_map, NULL, NULL },
+ { "paths-input", mapping_parse_paths, NULL, NULL },
+ { "paths-output", mapping_parse_paths, NULL, NULL },
+ { "element-input", mapping_parse_element, NULL, NULL },
+ { "element-output", mapping_parse_element, NULL, NULL },
+ { "direction", mapping_parse_direction, NULL, NULL },
+
+ /* Shared by [Mapping ...] and [Profile ...] */
+ { "description", mapping_parse_description, NULL, NULL },
+ { "priority", mapping_parse_priority, NULL, NULL },
+
+ /* [Profile ...] */
+ { "input-mappings", profile_parse_mappings, NULL, NULL },
+ { "output-mappings", profile_parse_mappings, NULL, NULL },
+ { "skip-probe", profile_parse_skip_probe, NULL, NULL },
+
+ /* [DecibelFix ...] */
+ { "db-values", decibel_fix_parse_db_values, NULL, NULL },
+ { NULL, NULL, NULL, NULL }
+ };
+
+ ps = pa_xnew0(pa_alsa_profile_set, 1);
+ ps->mappings = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ ps->profiles = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ ps->decibel_fixes = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ items[0].data = &ps->auto_profiles;
+
+ if (!fname)
+ fname = "default.conf";
+
+ fn = pa_maybe_prefix_path(fname,
+ pa_run_from_build_tree() ? PA_BUILDDIR "/modules/alsa/mixer/profile-sets/" :
+ PA_ALSA_PROFILE_SETS_DIR);
+
+ r = pa_config_parse(fn, NULL, items, ps);
+ pa_xfree(fn);
+
+ if (r < 0)
+ goto fail;
+
+ PA_HASHMAP_FOREACH(m, ps->mappings, state)
+ if (mapping_verify(m, bonus) < 0)
+ goto fail;
+
+ if (ps->auto_profiles)
+ profile_set_add_auto(ps);
+
+ PA_HASHMAP_FOREACH(p, ps->profiles, state)
+ if (profile_verify(p) < 0)
+ goto fail;
+
+ PA_HASHMAP_FOREACH(db_fix, ps->decibel_fixes, state)
+ if (decibel_fix_verify(db_fix) < 0)
+ goto fail;
+
+ return ps;
+
+fail:
+ pa_alsa_profile_set_free(ps);
+ return NULL;
+}
+
+void pa_alsa_profile_set_probe(
+ pa_alsa_profile_set *ps,
+ const char *dev_id,
+ const pa_sample_spec *ss,
+ unsigned default_n_fragments,
+ unsigned default_fragment_size_msec) {
+
+ void *state;
+ pa_alsa_profile *p, *last = NULL;
+ pa_alsa_mapping *m;
+
+ pa_assert(ps);
+ pa_assert(dev_id);
+ pa_assert(ss);
+
+ if (ps->probed)
+ return;
+
+ PA_HASHMAP_FOREACH(p, ps->profiles, state) {
+ pa_sample_spec try_ss;
+ pa_channel_map try_map;
+ snd_pcm_uframes_t try_period_size, try_buffer_size;
+ uint32_t idx;
+
+ /* Is this already marked that it is supported? (i.e. from the config file) */
+ if (p->supported)
+ continue;
+
+ pa_log_debug("Looking at profile %s", p->name);
+
+ /* Close PCMs from the last iteration we don't need anymore */
+ if (last && last->output_mappings)
+ PA_IDXSET_FOREACH(m, last->output_mappings, idx) {
+
+ if (!m->output_pcm)
+ break;
+
+ if (last->supported)
+ m->supported++;
+
+ if (!p->output_mappings || !pa_idxset_get_by_data(p->output_mappings, m, NULL)) {
+ snd_pcm_close(m->output_pcm);
+ m->output_pcm = NULL;
+ }
+ }
+
+ if (last && last->input_mappings)
+ PA_IDXSET_FOREACH(m, last->input_mappings, idx) {
+
+ if (!m->input_pcm)
+ break;
+
+ if (last->supported)
+ m->supported++;
+
+ if (!p->input_mappings || !pa_idxset_get_by_data(p->input_mappings, m, NULL)) {
+ snd_pcm_close(m->input_pcm);
+ m->input_pcm = NULL;
+ }
+ }
+
+ p->supported = TRUE;
+
+ /* Check if we can open all new ones */
+ if (p->output_mappings)
+ PA_IDXSET_FOREACH(m, p->output_mappings, idx) {
+
+ if (m->output_pcm)
+ continue;
+
+ pa_log_debug("Checking for playback on %s (%s)", m->description, m->name);
+ try_map = m->channel_map;
+ try_ss = *ss;
+ try_ss.channels = try_map.channels;
+
+ try_period_size =
+ pa_usec_to_bytes(default_fragment_size_msec * PA_USEC_PER_MSEC, &try_ss) /
+ pa_frame_size(&try_ss);
+ try_buffer_size = default_n_fragments * try_period_size;
+
+ if (!(m ->output_pcm = pa_alsa_open_by_template(
+ m->device_strings,
+ dev_id,
+ NULL,
+ &try_ss, &try_map,
+ SND_PCM_STREAM_PLAYBACK,
+ &try_period_size, &try_buffer_size, 0, NULL, NULL,
+ TRUE))) {
+ p->supported = FALSE;
+ break;
+ }
+ }
+
+ if (p->input_mappings && p->supported)
+ PA_IDXSET_FOREACH(m, p->input_mappings, idx) {
+
+ if (m->input_pcm)
+ continue;
+
+ pa_log_debug("Checking for recording on %s (%s)", m->description, m->name);
+ try_map = m->channel_map;
+ try_ss = *ss;
+ try_ss.channels = try_map.channels;
+
+ try_period_size =
+ pa_usec_to_bytes(default_fragment_size_msec*PA_USEC_PER_MSEC, &try_ss) /
+ pa_frame_size(&try_ss);
+ try_buffer_size = default_n_fragments * try_period_size;
+
+ if (!(m ->input_pcm = pa_alsa_open_by_template(
+ m->device_strings,
+ dev_id,
+ NULL,
+ &try_ss, &try_map,
+ SND_PCM_STREAM_CAPTURE,
+ &try_period_size, &try_buffer_size, 0, NULL, NULL,
+ TRUE))) {
+ p->supported = FALSE;
+ break;
+ }
+ }
+
+ last = p;
+
+ if (p->supported)
+ pa_log_debug("Profile %s supported.", p->name);
+ }
+
+ /* Clean up */
+ if (last) {
+ uint32_t idx;
+
+ if (last->output_mappings)
+ PA_IDXSET_FOREACH(m, last->output_mappings, idx)
+ if (m->output_pcm) {
+
+ if (last->supported)
+ m->supported++;
+
+ snd_pcm_close(m->output_pcm);
+ m->output_pcm = NULL;
+ }
+
+ if (last->input_mappings)
+ PA_IDXSET_FOREACH(m, last->input_mappings, idx)
+ if (m->input_pcm) {
+
+ if (last->supported)
+ m->supported++;
+
+ snd_pcm_close(m->input_pcm);
+ m->input_pcm = NULL;
+ }
+ }
+
+ PA_HASHMAP_FOREACH(p, ps->profiles, state)
+ if (!p->supported) {
+ pa_hashmap_remove(ps->profiles, p->name);
+ profile_free(p);
+ }
+
+ PA_HASHMAP_FOREACH(m, ps->mappings, state)
+ if (m->supported <= 0) {
+ pa_hashmap_remove(ps->mappings, m->name);
+ mapping_free(m);
+ }
+
+ ps->probed = TRUE;
+}
+
+void pa_alsa_profile_set_dump(pa_alsa_profile_set *ps) {
+ pa_alsa_profile *p;
+ pa_alsa_mapping *m;
+ pa_alsa_decibel_fix *db_fix;
+ void *state;
+
+ pa_assert(ps);
+
+ pa_log_debug("Profile set %p, auto_profiles=%s, probed=%s, n_mappings=%u, n_profiles=%u, n_decibel_fixes=%u",
+ (void*)
+ ps,
+ pa_yes_no(ps->auto_profiles),
+ pa_yes_no(ps->probed),
+ pa_hashmap_size(ps->mappings),
+ pa_hashmap_size(ps->profiles),
+ pa_hashmap_size(ps->decibel_fixes));
+
+ PA_HASHMAP_FOREACH(m, ps->mappings, state)
+ pa_alsa_mapping_dump(m);
+
+ PA_HASHMAP_FOREACH(p, ps->profiles, state)
+ pa_alsa_profile_dump(p);
+
+ PA_HASHMAP_FOREACH(db_fix, ps->decibel_fixes, state)
+ pa_alsa_decibel_fix_dump(db_fix);
+}
+
+void pa_alsa_add_ports(pa_hashmap **p, pa_alsa_path_set *ps) {
+ pa_alsa_path *path;
+
+ pa_assert(p);
+ pa_assert(!*p);
+ pa_assert(ps);
+
+ /* if there is no path, we don't want a port list */
+ if (!ps->paths)
+ return;
+
+ if (!ps->paths->next){
+ pa_alsa_setting *s;
+
+ /* If there is only one path, but no or only one setting, then
+ * we want a port list either */
+ if (!ps->paths->settings || !ps->paths->settings->next)
+ return;
+
+ /* Ok, there is only one path, however with multiple settings,
+ * so let's create a port for each setting */
+ *p = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ PA_LLIST_FOREACH(s, ps->paths->settings) {
+ pa_device_port *port;
+ pa_alsa_port_data *data;
+
+ port = pa_device_port_new(s->name, s->description, sizeof(pa_alsa_port_data));
+ port->priority = s->priority;
+
+ data = PA_DEVICE_PORT_DATA(port);
+ data->path = ps->paths;
+ data->setting = s;
+
+ pa_hashmap_put(*p, port->name, port);
+ }
+
+ } else {
+
+ /* We have multiple paths, so let's create a port for each
+ * one, and each of each settings */
+ *p = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ PA_LLIST_FOREACH(path, ps->paths) {
+
+ if (!path->settings || !path->settings->next) {
+ pa_device_port *port;
+ pa_alsa_port_data *data;
+
+ /* If there is no or just one setting we only need a
+ * single entry */
+
+ port = pa_device_port_new(path->name, path->description, sizeof(pa_alsa_port_data));
+ port->priority = path->priority * 100;
+
+
+ data = PA_DEVICE_PORT_DATA(port);
+ data->path = path;
+ data->setting = path->settings;
+
+ pa_hashmap_put(*p, port->name, port);
+ } else {
+ pa_alsa_setting *s;
+
+ PA_LLIST_FOREACH(s, path->settings) {
+ pa_device_port *port;
+ pa_alsa_port_data *data;
+ char *n, *d;
+
+ n = pa_sprintf_malloc("%s;%s", path->name, s->name);
+
+ if (s->description[0])
+ d = pa_sprintf_malloc(_("%s / %s"), path->description, s->description);
+ else
+ d = pa_xstrdup(path->description);
+
+ port = pa_device_port_new(n, d, sizeof(pa_alsa_port_data));
+ port->priority = path->priority * 100 + s->priority;
+
+ pa_xfree(n);
+ pa_xfree(d);
+
+ data = PA_DEVICE_PORT_DATA(port);
+ data->path = path;
+ data->setting = s;
+
+ pa_hashmap_put(*p, port->name, port);
+ }
+ }
+ }
+ }
+
+ pa_log_debug("Added %u ports", pa_hashmap_size(*p));
+}
diff --git a/src/modules/alsa/alsa-mixer.h b/src/modules/alsa/alsa-mixer.h
new file mode 100644
index 00000000..d92d3e98
--- /dev/null
+++ b/src/modules/alsa/alsa-mixer.h
@@ -0,0 +1,328 @@
+#ifndef fooalsamixerhfoo
+#define fooalsamixerhfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2006 Pierre Ossman <ossman@cendio.se> for Cendio AB
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <asoundlib.h>
+
+#include <pulse/sample.h>
+#include <pulse/mainloop-api.h>
+#include <pulse/channelmap.h>
+#include <pulse/volume.h>
+
+#include <pulsecore/llist.h>
+#include <pulsecore/rtpoll.h>
+
+typedef struct pa_alsa_fdlist pa_alsa_fdlist;
+typedef struct pa_alsa_mixer_pdata pa_alsa_mixer_pdata;
+typedef struct pa_alsa_setting pa_alsa_setting;
+typedef struct pa_alsa_option pa_alsa_option;
+typedef struct pa_alsa_element pa_alsa_element;
+typedef struct pa_alsa_path pa_alsa_path;
+typedef struct pa_alsa_path_set pa_alsa_path_set;
+typedef struct pa_alsa_mapping pa_alsa_mapping;
+typedef struct pa_alsa_profile pa_alsa_profile;
+typedef struct pa_alsa_decibel_fix pa_alsa_decibel_fix;
+typedef struct pa_alsa_profile_set pa_alsa_profile_set;
+typedef struct pa_alsa_port_data pa_alsa_port_data;
+
+#include "alsa-util.h"
+
+typedef enum pa_alsa_switch_use {
+ PA_ALSA_SWITCH_IGNORE,
+ PA_ALSA_SWITCH_MUTE, /* make this switch follow mute status */
+ PA_ALSA_SWITCH_OFF, /* set this switch to 'off' unconditionally */
+ PA_ALSA_SWITCH_ON, /* set this switch to 'on' unconditionally */
+ PA_ALSA_SWITCH_SELECT /* allow the user to select switch status through a setting */
+} pa_alsa_switch_use_t;
+
+typedef enum pa_alsa_volume_use {
+ PA_ALSA_VOLUME_IGNORE,
+ PA_ALSA_VOLUME_MERGE, /* merge this volume slider into the global volume slider */
+ PA_ALSA_VOLUME_OFF, /* set this volume to minimal unconditionally */
+ PA_ALSA_VOLUME_ZERO, /* set this volume to 0dB unconditionally */
+ PA_ALSA_VOLUME_CONSTANT /* set this volume to a constant value unconditionally */
+} pa_alsa_volume_use_t;
+
+typedef enum pa_alsa_enumeration_use {
+ PA_ALSA_ENUMERATION_IGNORE,
+ PA_ALSA_ENUMERATION_SELECT
+} pa_alsa_enumeration_use_t;
+
+typedef enum pa_alsa_required {
+ PA_ALSA_REQUIRED_IGNORE,
+ PA_ALSA_REQUIRED_SWITCH,
+ PA_ALSA_REQUIRED_VOLUME,
+ PA_ALSA_REQUIRED_ENUMERATION,
+ PA_ALSA_REQUIRED_ANY
+} pa_alsa_required_t;
+
+typedef enum pa_alsa_direction {
+ PA_ALSA_DIRECTION_ANY,
+ PA_ALSA_DIRECTION_OUTPUT,
+ PA_ALSA_DIRECTION_INPUT
+} pa_alsa_direction_t;
+
+/* A setting combines a couple of options into a single entity that
+ * may be selected. Only one setting can be active at the same
+ * time. */
+struct pa_alsa_setting {
+ pa_alsa_path *path;
+ PA_LLIST_FIELDS(pa_alsa_setting);
+
+ pa_idxset *options;
+
+ char *name;
+ char *description;
+ unsigned priority;
+};
+
+/* An option belongs to an element and refers to one enumeration item
+ * of the element is an enumeration item, or a switch status if the
+ * element is a switch item. */
+struct pa_alsa_option {
+ pa_alsa_element *element;
+ PA_LLIST_FIELDS(pa_alsa_option);
+
+ char *alsa_name;
+ int alsa_idx;
+
+ char *name;
+ char *description;
+ unsigned priority;
+
+ pa_alsa_required_t required;
+ pa_alsa_required_t required_any;
+ pa_alsa_required_t required_absent;
+};
+
+/* An element wraps one specific ALSA element. A series of elements
+ * make up a path (see below). If the element is an enumeration or switch
+ * element it may include a list of options. */
+struct pa_alsa_element {
+ pa_alsa_path *path;
+ PA_LLIST_FIELDS(pa_alsa_element);
+
+ char *alsa_name;
+ pa_alsa_direction_t direction;
+
+ pa_alsa_switch_use_t switch_use;
+ pa_alsa_volume_use_t volume_use;
+ pa_alsa_enumeration_use_t enumeration_use;
+
+ pa_alsa_required_t required;
+ pa_alsa_required_t required_any;
+ pa_alsa_required_t required_absent;
+
+ long constant_volume;
+
+ pa_bool_t override_map:1;
+ pa_bool_t direction_try_other:1;
+
+ pa_bool_t has_dB:1;
+ long min_volume, max_volume;
+ long volume_limit; /* -1 for no configured limit */
+ double min_dB, max_dB;
+
+ pa_channel_position_mask_t masks[SND_MIXER_SCHN_LAST][2];
+ unsigned n_channels;
+
+ pa_channel_position_mask_t merged_mask;
+
+ PA_LLIST_HEAD(pa_alsa_option, options);
+
+ pa_alsa_decibel_fix *db_fix;
+};
+
+/* A path wraps a series of elements into a single entity which can be
+ * used to control it as if it had a single volume slider, a single
+ * mute switch and a single list of selectable options. */
+struct pa_alsa_path {
+ pa_alsa_path_set *path_set;
+ PA_LLIST_FIELDS(pa_alsa_path);
+
+ pa_alsa_direction_t direction;
+
+ char *name;
+ char *description;
+ unsigned priority;
+
+ pa_bool_t probed:1;
+ pa_bool_t supported:1;
+ pa_bool_t has_mute:1;
+ pa_bool_t has_volume:1;
+ pa_bool_t has_dB:1;
+ /* These two are used during probing only */
+ pa_bool_t has_req_any:1;
+ pa_bool_t req_any_present:1;
+
+ long min_volume, max_volume;
+ double min_dB, max_dB;
+
+ /* This is used during parsing only, as a shortcut so that we
+ * don't have to iterate the list all the time */
+ pa_alsa_element *last_element;
+ pa_alsa_option *last_option;
+ pa_alsa_setting *last_setting;
+
+ PA_LLIST_HEAD(pa_alsa_element, elements);
+ PA_LLIST_HEAD(pa_alsa_setting, settings);
+};
+
+/* A path set is simply a set of paths that are applicable to a
+ * device */
+struct pa_alsa_path_set {
+ PA_LLIST_HEAD(pa_alsa_path, paths);
+ pa_alsa_direction_t direction;
+ pa_bool_t probed:1;
+
+ /* This is used during parsing only, as a shortcut so that we
+ * don't have to iterate the list all the time */
+ pa_alsa_path *last_path;
+};
+
+int pa_alsa_setting_select(pa_alsa_setting *s, snd_mixer_t *m);
+void pa_alsa_setting_dump(pa_alsa_setting *s);
+
+void pa_alsa_option_dump(pa_alsa_option *o);
+
+void pa_alsa_element_dump(pa_alsa_element *e);
+
+pa_alsa_path *pa_alsa_path_new(const char *fname, pa_alsa_direction_t direction);
+pa_alsa_path *pa_alsa_path_synthesize(const char *element, pa_alsa_direction_t direction);
+int pa_alsa_path_probe(pa_alsa_path *p, snd_mixer_t *m, pa_bool_t ignore_dB);
+void pa_alsa_path_dump(pa_alsa_path *p);
+int pa_alsa_path_get_volume(pa_alsa_path *p, snd_mixer_t *m, const pa_channel_map *cm, pa_cvolume *v);
+int pa_alsa_path_get_mute(pa_alsa_path *path, snd_mixer_t *m, pa_bool_t *muted);
+int pa_alsa_path_set_volume(pa_alsa_path *path, snd_mixer_t *m, const pa_channel_map *cm, pa_cvolume *v, pa_bool_t sync_volume, pa_bool_t write_to_hw);
+int pa_alsa_path_set_mute(pa_alsa_path *path, snd_mixer_t *m, pa_bool_t muted);
+int pa_alsa_path_select(pa_alsa_path *p, snd_mixer_t *m);
+void pa_alsa_path_set_callback(pa_alsa_path *p, snd_mixer_t *m, snd_mixer_elem_callback_t cb, void *userdata);
+void pa_alsa_path_free(pa_alsa_path *p);
+
+pa_alsa_path_set *pa_alsa_path_set_new(pa_alsa_mapping *m, pa_alsa_direction_t direction);
+void pa_alsa_path_set_probe(pa_alsa_path_set *s, snd_mixer_t *m, pa_bool_t ignore_dB);
+void pa_alsa_path_set_dump(pa_alsa_path_set *s);
+void pa_alsa_path_set_set_callback(pa_alsa_path_set *ps, snd_mixer_t *m, snd_mixer_elem_callback_t cb, void *userdata);
+void pa_alsa_path_set_free(pa_alsa_path_set *s);
+
+struct pa_alsa_mapping {
+ pa_alsa_profile_set *profile_set;
+
+ char *name;
+ char *description;
+ unsigned priority;
+ pa_alsa_direction_t direction;
+
+ pa_channel_map channel_map;
+
+ char **device_strings;
+
+ char **input_path_names;
+ char **output_path_names;
+ char **input_element; /* list of fallbacks */
+ char **output_element;
+
+ unsigned supported;
+
+ /* Temporarily used during probing */
+ snd_pcm_t *input_pcm;
+ snd_pcm_t *output_pcm;
+
+ pa_sink *sink;
+ pa_source *source;
+};
+
+struct pa_alsa_profile {
+ pa_alsa_profile_set *profile_set;
+
+ char *name;
+ char *description;
+ unsigned priority;
+
+ pa_bool_t supported:1;
+
+ char **input_mapping_names;
+ char **output_mapping_names;
+
+ pa_idxset *input_mappings;
+ pa_idxset *output_mappings;
+};
+
+struct pa_alsa_decibel_fix {
+ pa_alsa_profile_set *profile_set;
+
+ char *name; /* Alsa volume element name. */
+ long min_step;
+ long max_step;
+
+ /* An array that maps alsa volume element steps to decibels. The steps can
+ * be used as indices to this array, after substracting min_step from the
+ * real value.
+ *
+ * The values are actually stored as integers representing millibels,
+ * because that's the format the alsa API uses. */
+ long *db_values;
+};
+
+struct pa_alsa_profile_set {
+ pa_hashmap *mappings;
+ pa_hashmap *profiles;
+ pa_hashmap *decibel_fixes;
+
+ pa_bool_t auto_profiles;
+ pa_bool_t probed:1;
+};
+
+void pa_alsa_mapping_dump(pa_alsa_mapping *m);
+void pa_alsa_profile_dump(pa_alsa_profile *p);
+void pa_alsa_decibel_fix_dump(pa_alsa_decibel_fix *db_fix);
+
+pa_alsa_profile_set* pa_alsa_profile_set_new(const char *fname, const pa_channel_map *bonus);
+void pa_alsa_profile_set_probe(pa_alsa_profile_set *ps, const char *dev_id, const pa_sample_spec *ss, unsigned default_n_fragments, unsigned default_fragment_size_msec);
+void pa_alsa_profile_set_free(pa_alsa_profile_set *s);
+void pa_alsa_profile_set_dump(pa_alsa_profile_set *s);
+
+snd_mixer_t *pa_alsa_open_mixer_for_pcm(snd_pcm_t *pcm, char **ctl_device);
+
+pa_alsa_fdlist *pa_alsa_fdlist_new(void);
+void pa_alsa_fdlist_free(pa_alsa_fdlist *fdl);
+int pa_alsa_fdlist_set_mixer(pa_alsa_fdlist *fdl, snd_mixer_t *mixer_handle, pa_mainloop_api* m);
+
+/* Alternative for handling alsa mixer events in io-thread. */
+
+pa_alsa_mixer_pdata *pa_alsa_mixer_pdata_new(void);
+void pa_alsa_mixer_pdata_free(pa_alsa_mixer_pdata *pd);
+int pa_alsa_set_mixer_rtpoll(struct pa_alsa_mixer_pdata *pd, snd_mixer_t *mixer, pa_rtpoll *rtp);
+
+/* Data structure for inclusion in pa_device_port for alsa
+ * sinks/sources. This contains nothing that needs to be freed
+ * individually */
+struct pa_alsa_port_data {
+ pa_alsa_path *path;
+ pa_alsa_setting *setting;
+};
+
+void pa_alsa_add_ports(pa_hashmap **p, pa_alsa_path_set *ps);
+
+#endif
diff --git a/src/modules/alsa/alsa-sink.c b/src/modules/alsa/alsa-sink.c
index 59f53110..0164040d 100644
--- a/src/modules/alsa/alsa-sink.c
+++ b/src/modules/alsa/alsa-sink.c
@@ -32,25 +32,25 @@
#include <valgrind/memcheck.h>
#endif
-#include <pulse/xmalloc.h>
-#include <pulse/util.h>
-#include <pulse/timeval.h>
#include <pulse/i18n.h>
+#include <pulse/rtclock.h>
+#include <pulse/timeval.h>
+#include <pulse/volume.h>
+#include <pulse/xmalloc.h>
#include <pulsecore/core.h>
#include <pulsecore/module.h>
#include <pulsecore/memchunk.h>
#include <pulsecore/sink.h>
#include <pulsecore/modargs.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/sample-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/thread.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
-#include <pulsecore/rtclock.h>
#include <pulsecore/time-smoother.h>
#include <modules/reserve-wrap.h>
@@ -61,11 +61,32 @@
/* #define DEBUG_TIMING */
#define DEFAULT_DEVICE "default"
-#define DEFAULT_TSCHED_BUFFER_USEC (2*PA_USEC_PER_SEC) /* 2s -- Overall buffer size */
-#define DEFAULT_TSCHED_WATERMARK_USEC (20*PA_USEC_PER_MSEC) /* 20ms -- Fill up when only this much is left in the buffer */
-#define TSCHED_WATERMARK_STEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms -- On underrun, increase watermark by this */
-#define TSCHED_MIN_SLEEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms -- Sleep at least 10ms on each iteration */
-#define TSCHED_MIN_WAKEUP_USEC (4*PA_USEC_PER_MSEC) /* 4ms -- Wakeup at least this long before the buffer runs empty*/
+
+#define DEFAULT_TSCHED_BUFFER_USEC (2*PA_USEC_PER_SEC) /* 2s -- Overall buffer size */
+#define DEFAULT_TSCHED_WATERMARK_USEC (20*PA_USEC_PER_MSEC) /* 20ms -- Fill up when only this much is left in the buffer */
+
+#define TSCHED_WATERMARK_INC_STEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms -- On underrun, increase watermark by this */
+#define TSCHED_WATERMARK_DEC_STEP_USEC (5*PA_USEC_PER_MSEC) /* 5ms -- When everything's great, decrease watermark by this */
+#define TSCHED_WATERMARK_VERIFY_AFTER_USEC (20*PA_USEC_PER_SEC) /* 20s -- How long after a drop out recheck if things are good now */
+#define TSCHED_WATERMARK_INC_THRESHOLD_USEC (0*PA_USEC_PER_MSEC) /* 0ms -- If the buffer level ever below this theshold, increase the watermark */
+#define TSCHED_WATERMARK_DEC_THRESHOLD_USEC (100*PA_USEC_PER_MSEC) /* 100ms -- If the buffer level didn't drop below this theshold in the verification time, decrease the watermark */
+
+/* Note that TSCHED_WATERMARK_INC_THRESHOLD_USEC == 0 means tht we
+ * will increase the watermark only if we hit a real underrun. */
+
+#define TSCHED_MIN_SLEEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms -- Sleep at least 10ms on each iteration */
+#define TSCHED_MIN_WAKEUP_USEC (4*PA_USEC_PER_MSEC) /* 4ms -- Wakeup at least this long before the buffer runs empty*/
+
+#define SMOOTHER_WINDOW_USEC (10*PA_USEC_PER_SEC) /* 10s -- smoother windows size */
+#define SMOOTHER_ADJUST_USEC (1*PA_USEC_PER_SEC) /* 1s -- smoother adjust time */
+
+#define SMOOTHER_MIN_INTERVAL (2*PA_USEC_PER_MSEC) /* 2ms -- min smoother update interval */
+#define SMOOTHER_MAX_INTERVAL (200*PA_USEC_PER_MSEC) /* 200ms -- max smoother update interval */
+
+#define VOLUME_ACCURACY (PA_VOLUME_NORM/100) /* don't require volume adjustments to be perfectly correct. don't necessarily extend granularity in software unless the differences get greater than this level */
+
+#define DEFAULT_REWIND_SAFEGUARD_BYTES (256U) /* 1.33ms @48kHz, we'll never rewind less than this */
+#define DEFAULT_REWIND_SAFEGUARD_USEC (1330) /* 1.33ms, depending on channels/rate/sample we may rewind more than 256 above */
struct userdata {
pa_core *core;
@@ -79,14 +100,15 @@ struct userdata {
snd_pcm_t *pcm_handle;
pa_alsa_fdlist *mixer_fdl;
+ pa_alsa_mixer_pdata *mixer_pd;
snd_mixer_t *mixer_handle;
- snd_mixer_elem_t *mixer_elem;
- long hw_volume_max, hw_volume_min;
- long hw_dB_max, hw_dB_min;
- pa_bool_t hw_dB_supported:1;
- pa_bool_t mixer_seperate_channels:1;
+ pa_alsa_path_set *mixer_path_set;
+ pa_alsa_path *mixer_path;
+
pa_cvolume hardware_volume;
+ uint32_t old_rate;
+
size_t
frame_size,
fragment_size,
@@ -95,12 +117,18 @@ struct userdata {
hwbuf_unused,
min_sleep,
min_wakeup,
- watermark_step;
+ watermark_inc_step,
+ watermark_dec_step,
+ watermark_inc_threshold,
+ watermark_dec_threshold,
+ rewind_safeguard;
+
+ pa_usec_t watermark_dec_not_before;
- unsigned nfragments;
pa_memchunk memchunk;
- char *device_name;
+ char *device_name; /* name of the PCM device */
+ char *control_device; /* name of the control device */
pa_bool_t use_mmap:1, use_tsched:1;
@@ -113,9 +141,13 @@ struct userdata {
pa_smoother *smoother;
uint64_t write_count;
uint64_t since_start;
+ pa_usec_t smoother_interval;
+ pa_usec_t last_smoother_update;
pa_reserve_wrapper *reserve;
pa_hook_slot *reserve_slot;
+ pa_reserve_monitor_wrapper *monitor;
+ pa_hook_slot *monitor_slot;
};
static void userdata_free(struct userdata *u);
@@ -124,7 +156,7 @@ static pa_hook_result_t reserve_cb(pa_reserve_wrapper *r, void *forced, struct u
pa_assert(r);
pa_assert(u);
- if (pa_sink_suspend(u->sink, TRUE) < 0)
+ if (pa_sink_suspend(u->sink, TRUE, PA_SUSPEND_APPLICATION) < 0)
return PA_HOOK_CANCEL;
return PA_HOOK_OK;
@@ -167,10 +199,10 @@ static int reserve_init(struct userdata *u, const char *dname) {
if (pa_in_system_mode())
return 0;
- /* We are resuming, try to lock the device */
if (!(rname = pa_alsa_get_reserve_name(dname)))
return 0;
+ /* We are resuming, try to lock the device */
u->reserve = pa_reserve_wrapper_get(u->core, rname);
pa_xfree(rname);
@@ -185,10 +217,62 @@ static int reserve_init(struct userdata *u, const char *dname) {
return 0;
}
+static pa_hook_result_t monitor_cb(pa_reserve_monitor_wrapper *w, void* busy, struct userdata *u) {
+ pa_bool_t b;
+
+ pa_assert(w);
+ pa_assert(u);
+
+ b = PA_PTR_TO_UINT(busy) && !u->reserve;
+
+ pa_sink_suspend(u->sink, b, PA_SUSPEND_APPLICATION);
+ return PA_HOOK_OK;
+}
+
+static void monitor_done(struct userdata *u) {
+ pa_assert(u);
+
+ if (u->monitor_slot) {
+ pa_hook_slot_free(u->monitor_slot);
+ u->monitor_slot = NULL;
+ }
+
+ if (u->monitor) {
+ pa_reserve_monitor_wrapper_unref(u->monitor);
+ u->monitor = NULL;
+ }
+}
+
+static int reserve_monitor_init(struct userdata *u, const char *dname) {
+ char *rname;
+
+ pa_assert(u);
+ pa_assert(dname);
+
+ if (pa_in_system_mode())
+ return 0;
+
+ if (!(rname = pa_alsa_get_reserve_name(dname)))
+ return 0;
+
+ /* We are resuming, try to lock the device */
+ u->monitor = pa_reserve_monitor_wrapper_get(u->core, rname);
+ pa_xfree(rname);
+
+ if (!(u->monitor))
+ return -1;
+
+ pa_assert(!u->monitor_slot);
+ u->monitor_slot = pa_hook_connect(pa_reserve_monitor_wrapper_hook(u->monitor), PA_HOOK_NORMAL, (pa_hook_cb_t) monitor_cb, u);
+
+ return 0;
+}
+
static void fix_min_sleep_wakeup(struct userdata *u) {
size_t max_use, max_use_2;
pa_assert(u);
+ pa_assert(u->use_tsched);
max_use = u->hwbuf_size - u->hwbuf_unused;
max_use_2 = pa_frame_align(max_use/2, &u->sink->sample_spec);
@@ -203,6 +287,7 @@ static void fix_min_sleep_wakeup(struct userdata *u) {
static void fix_tsched_watermark(struct userdata *u) {
size_t max_use;
pa_assert(u);
+ pa_assert(u->use_tsched);
max_use = u->hwbuf_size - u->hwbuf_unused;
@@ -213,7 +298,7 @@ static void fix_tsched_watermark(struct userdata *u) {
u->tsched_watermark = u->min_wakeup;
}
-static void adjust_after_underrun(struct userdata *u) {
+static void increase_watermark(struct userdata *u) {
size_t old_watermark;
pa_usec_t old_min_latency, new_min_latency;
@@ -222,31 +307,64 @@ static void adjust_after_underrun(struct userdata *u) {
/* First, just try to increase the watermark */
old_watermark = u->tsched_watermark;
- u->tsched_watermark = PA_MIN(u->tsched_watermark * 2, u->tsched_watermark + u->watermark_step);
+ u->tsched_watermark = PA_MIN(u->tsched_watermark * 2, u->tsched_watermark + u->watermark_inc_step);
fix_tsched_watermark(u);
if (old_watermark != u->tsched_watermark) {
- pa_log_notice("Increasing wakeup watermark to %0.2f ms",
- (double) pa_bytes_to_usec(u->tsched_watermark, &u->sink->sample_spec) / PA_USEC_PER_MSEC);
+ pa_log_info("Increasing wakeup watermark to %0.2f ms",
+ (double) pa_bytes_to_usec(u->tsched_watermark, &u->sink->sample_spec) / PA_USEC_PER_MSEC);
return;
}
/* Hmm, we cannot increase the watermark any further, hence let's raise the latency */
old_min_latency = u->sink->thread_info.min_latency;
- new_min_latency = PA_MIN(old_min_latency * 2, old_min_latency + TSCHED_WATERMARK_STEP_USEC);
+ new_min_latency = PA_MIN(old_min_latency * 2, old_min_latency + TSCHED_WATERMARK_INC_STEP_USEC);
new_min_latency = PA_MIN(new_min_latency, u->sink->thread_info.max_latency);
if (old_min_latency != new_min_latency) {
- pa_log_notice("Increasing minimal latency to %0.2f ms",
- (double) new_min_latency / PA_USEC_PER_MSEC);
+ pa_log_info("Increasing minimal latency to %0.2f ms",
+ (double) new_min_latency / PA_USEC_PER_MSEC);
pa_sink_set_latency_range_within_thread(u->sink, new_min_latency, u->sink->thread_info.max_latency);
- return;
}
/* When we reach this we're officialy fucked! */
}
+static void decrease_watermark(struct userdata *u) {
+ size_t old_watermark;
+ pa_usec_t now;
+
+ pa_assert(u);
+ pa_assert(u->use_tsched);
+
+ now = pa_rtclock_now();
+
+ if (u->watermark_dec_not_before <= 0)
+ goto restart;
+
+ if (u->watermark_dec_not_before > now)
+ return;
+
+ old_watermark = u->tsched_watermark;
+
+ if (u->tsched_watermark < u->watermark_dec_step)
+ u->tsched_watermark = u->tsched_watermark / 2;
+ else
+ u->tsched_watermark = PA_MAX(u->tsched_watermark / 2, u->tsched_watermark - u->watermark_dec_step);
+
+ fix_tsched_watermark(u);
+
+ if (old_watermark != u->tsched_watermark)
+ pa_log_info("Decreasing wakeup watermark to %0.2f ms",
+ (double) pa_bytes_to_usec(u->tsched_watermark, &u->sink->sample_spec) / PA_USEC_PER_MSEC);
+
+ /* We don't change the latency range*/
+
+restart:
+ u->watermark_dec_not_before = now + TSCHED_WATERMARK_VERIFY_AFTER_USEC;
+}
+
static void hw_sleep_time(struct userdata *u, pa_usec_t *sleep_usec, pa_usec_t*process_usec) {
pa_usec_t usec, wm;
@@ -254,6 +372,7 @@ static void hw_sleep_time(struct userdata *u, pa_usec_t *sleep_usec, pa_usec_t*p
pa_assert(process_usec);
pa_assert(u);
+ pa_assert(u->use_tsched);
usec = pa_sink_get_requested_latency_within_thread(u->sink);
@@ -288,6 +407,9 @@ static int try_recover(struct userdata *u, const char *call, int err) {
if (err == -EPIPE)
pa_log_debug("%s: Buffer underrun!", call);
+ if (err == -ESTRPIPE)
+ pa_log_debug("%s: System suspended!", call);
+
if ((err = snd_pcm_recover(u->pcm_handle, err, 1)) < 0) {
pa_log("%s: %s", call, pa_alsa_strerror(err));
return -1;
@@ -298,43 +420,66 @@ static int try_recover(struct userdata *u, const char *call, int err) {
return 0;
}
-static size_t check_left_to_play(struct userdata *u, size_t n_bytes) {
+static size_t check_left_to_play(struct userdata *u, size_t n_bytes, pa_bool_t on_timeout) {
size_t left_to_play;
+ pa_bool_t underrun = FALSE;
/* We use <= instead of < for this check here because an underrun
* only happens after the last sample was processed, not already when
* it is removed from the buffer. This is particularly important
* when block transfer is used. */
- if (n_bytes <= u->hwbuf_size) {
+ if (n_bytes <= u->hwbuf_size)
left_to_play = u->hwbuf_size - n_bytes;
+ else {
+
+ /* We got a dropout. What a mess! */
+ left_to_play = 0;
+ underrun = TRUE;
#ifdef DEBUG_TIMING
- pa_log_debug("%0.2f ms left to play", (double) pa_bytes_to_usec(left_to_play, &u->sink->sample_spec) / PA_USEC_PER_MSEC);
+ PA_DEBUG_TRAP;
#endif
- } else {
- left_to_play = 0;
+ if (!u->first && !u->after_rewind)
+ if (pa_log_ratelimit(PA_LOG_INFO))
+ pa_log_info("Underrun!");
+ }
#ifdef DEBUG_TIMING
- PA_DEBUG_TRAP;
+ pa_log_debug("%0.2f ms left to play; inc threshold = %0.2f ms; dec threshold = %0.2f ms",
+ (double) pa_bytes_to_usec(left_to_play, &u->sink->sample_spec) / PA_USEC_PER_MSEC,
+ (double) pa_bytes_to_usec(u->watermark_inc_threshold, &u->sink->sample_spec) / PA_USEC_PER_MSEC,
+ (double) pa_bytes_to_usec(u->watermark_dec_threshold, &u->sink->sample_spec) / PA_USEC_PER_MSEC);
#endif
+ if (u->use_tsched) {
+ pa_bool_t reset_not_before = TRUE;
+
if (!u->first && !u->after_rewind) {
+ if (underrun || left_to_play < u->watermark_inc_threshold)
+ increase_watermark(u);
+ else if (left_to_play > u->watermark_dec_threshold) {
+ reset_not_before = FALSE;
- if (pa_log_ratelimit())
- pa_log_info("Underrun!");
+ /* We decrease the watermark only if have actually
+ * been woken up by a timeout. If something else woke
+ * us up it's too easy to fulfill the deadlines... */
- if (u->use_tsched)
- adjust_after_underrun(u);
+ if (on_timeout)
+ decrease_watermark(u);
+ }
}
+
+ if (reset_not_before)
+ u->watermark_dec_not_before = 0;
}
return left_to_play;
}
-static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled) {
- pa_bool_t work_done = TRUE;
+static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled, pa_bool_t on_timeout) {
+ pa_bool_t work_done = FALSE;
pa_usec_t max_sleep_usec = 0, process_usec = 0;
size_t left_to_play;
unsigned j = 0;
@@ -349,6 +494,7 @@ static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
snd_pcm_sframes_t n;
size_t n_bytes;
int r;
+ pa_bool_t after_avail = TRUE;
/* First we determine how many samples are missing to fill the
* buffer up to 100% */
@@ -367,7 +513,8 @@ static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
pa_log_debug("avail: %lu", (unsigned long) n_bytes);
#endif
- left_to_play = check_left_to_play(u, n_bytes);
+ left_to_play = check_left_to_play(u, n_bytes, on_timeout);
+ on_timeout = FALSE;
if (u->use_tsched)
@@ -432,6 +579,9 @@ static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
if (PA_UNLIKELY((err = pa_alsa_safe_mmap_begin(u->pcm_handle, &areas, &offset, &frames, u->hwbuf_size, &u->sink->sample_spec)) < 0)) {
+ if (!after_avail && err == -EAGAIN)
+ break;
+
if ((r = try_recover(u, "snd_pcm_mmap_begin", err)) == 0)
continue;
@@ -442,6 +592,12 @@ static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
if (frames > pa_mempool_block_size_max(u->sink->core->mempool)/u->frame_size)
frames = pa_mempool_block_size_max(u->sink->core->mempool)/u->frame_size;
+ if (!after_avail && frames == 0)
+ break;
+
+ pa_assert(frames > 0);
+ after_avail = FALSE;
+
/* Check these are multiples of 8 bit */
pa_assert((areas[0].first & 7) == 0);
pa_assert((areas[0].step & 7)== 0);
@@ -461,6 +617,9 @@ static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
if (PA_UNLIKELY((sframes = snd_pcm_mmap_commit(u->pcm_handle, offset, frames)) < 0)) {
+ if (!after_avail && (int) sframes == -EAGAIN)
+ break;
+
if ((r = try_recover(u, "snd_pcm_mmap_commit", (int) sframes)) == 0)
continue;
@@ -483,17 +642,20 @@ static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
}
}
- *sleep_usec = pa_bytes_to_usec(left_to_play, &u->sink->sample_spec);
+ if (u->use_tsched) {
+ *sleep_usec = pa_bytes_to_usec(left_to_play, &u->sink->sample_spec);
- if (*sleep_usec > process_usec)
- *sleep_usec -= process_usec;
- else
+ if (*sleep_usec > process_usec)
+ *sleep_usec -= process_usec;
+ else
+ *sleep_usec = 0;
+ } else
*sleep_usec = 0;
return work_done ? 1 : 0;
}
-static int unix_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled) {
+static int unix_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled, pa_bool_t on_timeout) {
pa_bool_t work_done = FALSE;
pa_usec_t max_sleep_usec = 0, process_usec = 0;
size_t left_to_play;
@@ -509,6 +671,7 @@ static int unix_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
snd_pcm_sframes_t n;
size_t n_bytes;
int r;
+ pa_bool_t after_avail = TRUE;
if (PA_UNLIKELY((n = pa_alsa_safe_avail(u->pcm_handle, u->hwbuf_size, &u->sink->sample_spec)) < 0)) {
@@ -519,7 +682,8 @@ static int unix_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
}
n_bytes = (size_t) n * u->frame_size;
- left_to_play = check_left_to_play(u, n_bytes);
+ left_to_play = check_left_to_play(u, n_bytes, on_timeout);
+ on_timeout = FALSE;
if (u->use_tsched)
@@ -579,16 +743,23 @@ static int unix_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
frames = snd_pcm_writei(u->pcm_handle, (const uint8_t*) p + u->memchunk.index, (snd_pcm_uframes_t) frames);
pa_memblock_release(u->memchunk.memblock);
- pa_assert(frames != 0);
-
if (PA_UNLIKELY(frames < 0)) {
+ if (!after_avail && (int) frames == -EAGAIN)
+ break;
+
if ((r = try_recover(u, "snd_pcm_writei", (int) frames)) == 0)
continue;
return r;
}
+ if (!after_avail && frames == 0)
+ break;
+
+ pa_assert(frames > 0);
+ after_avail = FALSE;
+
u->memchunk.index += (size_t) frames * u->frame_size;
u->memchunk.length -= (size_t) frames * u->frame_size;
@@ -611,11 +782,14 @@ static int unix_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle
}
}
- *sleep_usec = pa_bytes_to_usec(left_to_play, &u->sink->sample_spec);
+ if (u->use_tsched) {
+ *sleep_usec = pa_bytes_to_usec(left_to_play, &u->sink->sample_spec);
- if (*sleep_usec > process_usec)
- *sleep_usec -= process_usec;
- else
+ if (*sleep_usec > process_usec)
+ *sleep_usec -= process_usec;
+ else
+ *sleep_usec = 0;
+ } else
*sleep_usec = 0;
return work_done ? 1 : 0;
@@ -635,7 +809,7 @@ static void update_smoother(struct userdata *u) {
/* Let's update the time smoother */
- if (PA_UNLIKELY((err = pa_alsa_safe_delay(u->pcm_handle, &delay, u->hwbuf_size, &u->sink->sample_spec)) < 0)) {
+ if (PA_UNLIKELY((err = pa_alsa_safe_delay(u->pcm_handle, &delay, u->hwbuf_size, &u->sink->sample_spec, FALSE)) < 0)) {
pa_log_warn("Failed to query DSP status data: %s", pa_alsa_strerror(err));
return;
}
@@ -648,18 +822,27 @@ static void update_smoother(struct userdata *u) {
now1 = pa_timespec_load(&htstamp);
}
+ /* Hmm, if the timestamp is 0, then it wasn't set and we take the current time */
+ if (now1 <= 0)
+ now1 = pa_rtclock_now();
+
+ /* check if the time since the last update is bigger than the interval */
+ if (u->last_smoother_update > 0)
+ if (u->last_smoother_update + u->smoother_interval > now1)
+ return;
+
position = (int64_t) u->write_count - ((int64_t) delay * (int64_t) u->frame_size);
if (PA_UNLIKELY(position < 0))
position = 0;
- /* Hmm, if the timestamp is 0, then it wasn't set and we take the current time */
- if (now1 <= 0)
- now1 = pa_rtclock_usec();
-
now2 = pa_bytes_to_usec((uint64_t) position, &u->sink->sample_spec);
pa_smoother_put(u->smoother, now1, now2);
+
+ u->last_smoother_update = now1;
+ /* exponentially increase the update interval up to the MAX limit */
+ u->smoother_interval = PA_MIN (u->smoother_interval * 2, SMOOTHER_MAX_INTERVAL);
}
static pa_usec_t sink_get_latency(struct userdata *u) {
@@ -669,7 +852,7 @@ static pa_usec_t sink_get_latency(struct userdata *u) {
pa_assert(u);
- now1 = pa_rtclock_usec();
+ now1 = pa_rtclock_now();
now2 = pa_smoother_get(u->smoother, now1);
delay = (int64_t) pa_bytes_to_usec(u->write_count, &u->sink->sample_spec) - (int64_t) now2;
@@ -700,7 +883,7 @@ static int suspend(struct userdata *u) {
pa_assert(u);
pa_assert(u->pcm_handle);
- pa_smoother_pause(u->smoother, pa_rtclock_usec());
+ pa_smoother_pause(u->smoother, pa_rtclock_now());
/* Let's suspend -- we don't call snd_pcm_drain() here since that might
* take awfully long with our long buffer sizes today. */
@@ -712,6 +895,14 @@ static int suspend(struct userdata *u) {
u->alsa_rtpoll_item = NULL;
}
+ /* We reset max_rewind/max_request here to make sure that while we
+ * are suspended the old max_request/max_rewind values set before
+ * the suspend can influence the per-stream buffer of newly
+ * created streams, without their requirements having any
+ * influence on them. */
+ pa_sink_set_max_rewind_within_thread(u->sink, 0);
+ pa_sink_set_max_request_within_thread(u->sink, 0);
+
pa_log_info("Device suspended...");
return 0;
@@ -763,12 +954,18 @@ static int update_sw_params(struct userdata *u) {
pa_log_debug("setting avail_min=%lu", (unsigned long) avail_min);
- if ((err = pa_alsa_set_sw_params(u->pcm_handle, avail_min)) < 0) {
+ if ((err = pa_alsa_set_sw_params(u->pcm_handle, avail_min, !u->use_tsched)) < 0) {
pa_log("Failed to set software parameters: %s", pa_alsa_strerror(err));
return err;
}
pa_sink_set_max_request_within_thread(u->sink, u->hwbuf_size - u->hwbuf_unused);
+ if (pa_alsa_pcm_is_hw(u->pcm_handle))
+ pa_sink_set_max_rewind_within_thread(u->sink, u->hwbuf_size);
+ else {
+ pa_log_info("Disabling rewind_within_thread for device %s", u->device_name);
+ pa_sink_set_max_rewind_within_thread(u->sink, 0);
+ }
return 0;
}
@@ -778,17 +975,15 @@ static int unsuspend(struct userdata *u) {
pa_sample_spec ss;
int err;
pa_bool_t b, d;
- unsigned nfrags;
- snd_pcm_uframes_t period_size;
+ snd_pcm_uframes_t period_size, buffer_size;
pa_assert(u);
pa_assert(!u->pcm_handle);
pa_log_info("Trying resume...");
- snd_config_update_free_global();
if ((err = snd_pcm_open(&u->pcm_handle, u->device_name, SND_PCM_STREAM_PLAYBACK,
- /*SND_PCM_NONBLOCK|*/
+ SND_PCM_NONBLOCK|
SND_PCM_NO_AUTO_RESAMPLE|
SND_PCM_NO_AUTO_CHANNELS|
SND_PCM_NO_AUTO_FORMAT)) < 0) {
@@ -797,12 +992,12 @@ static int unsuspend(struct userdata *u) {
}
ss = u->sink->sample_spec;
- nfrags = u->nfragments;
period_size = u->fragment_size / u->frame_size;
+ buffer_size = u->hwbuf_size / u->frame_size;
b = u->use_mmap;
d = u->use_tsched;
- if ((err = pa_alsa_set_hw_params(u->pcm_handle, &ss, &nfrags, &period_size, u->hwbuf_size / u->frame_size, &b, &d, TRUE)) < 0) {
+ if ((err = pa_alsa_set_hw_params(u->pcm_handle, &ss, &period_size, &buffer_size, 0, &b, &d, TRUE)) < 0) {
pa_log("Failed to set hardware parameters: %s", pa_alsa_strerror(err));
goto fail;
}
@@ -817,10 +1012,11 @@ static int unsuspend(struct userdata *u) {
goto fail;
}
- if (nfrags != u->nfragments || period_size*u->frame_size != u->fragment_size) {
- pa_log_warn("Resume failed, couldn't restore original fragment settings. (Old: %lu*%lu, New %lu*%lu)",
- (unsigned long) u->nfragments, (unsigned long) u->fragment_size,
- (unsigned long) nfrags, period_size * u->frame_size);
+ if (period_size*u->frame_size != u->fragment_size ||
+ buffer_size*u->frame_size != u->hwbuf_size) {
+ pa_log_warn("Resume failed, couldn't restore original fragment settings. (Old: %lu/%lu, New %lu/%lu)",
+ (unsigned long) u->hwbuf_size, (unsigned long) u->fragment_size,
+ (unsigned long) (buffer_size*u->frame_size), (unsigned long) (period_size*u->frame_size));
goto fail;
}
@@ -830,6 +1026,11 @@ static int unsuspend(struct userdata *u) {
if (build_pollfd(u) < 0)
goto fail;
+ u->write_count = 0;
+ pa_smoother_reset(u->smoother, pa_rtclock_now(), TRUE);
+ u->smoother_interval = SMOOTHER_MIN_INTERVAL;
+ u->last_smoother_update = 0;
+
u->first = TRUE;
u->since_start = 0;
@@ -843,7 +1044,7 @@ fail:
u->pcm_handle = NULL;
}
- return -1;
+ return -PA_ERR_IO;
}
/* Called from IO context */
@@ -852,6 +1053,56 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
switch (code) {
+ case PA_SINK_MESSAGE_FINISH_MOVE:
+ case PA_SINK_MESSAGE_ADD_INPUT: {
+ pa_sink_input *i = PA_SINK_INPUT(data);
+ int r = 0;
+
+ if (PA_LIKELY(!pa_sink_input_is_passthrough(i)))
+ break;
+
+ u->old_rate = u->sink->sample_spec.rate;
+
+ /* Passthrough format, see if we need to reset sink sample rate */
+ if (u->sink->sample_spec.rate == i->thread_info.sample_spec.rate)
+ break;
+
+ /* .. we do */
+ if ((r = suspend(u)) < 0)
+ return r;
+
+ u->sink->sample_spec.rate = i->thread_info.sample_spec.rate;
+
+ if ((r = unsuspend(u)) < 0)
+ return r;
+
+ break;
+ }
+
+ case PA_SINK_MESSAGE_START_MOVE:
+ case PA_SINK_MESSAGE_REMOVE_INPUT: {
+ pa_sink_input *i = PA_SINK_INPUT(data);
+ int r = 0;
+
+ if (PA_LIKELY(!pa_sink_input_is_passthrough(i)))
+ break;
+
+ /* Passthrough format, see if we need to reset sink sample rate */
+ if (u->sink->sample_spec.rate == u->old_rate)
+ break;
+
+ /* .. we do */
+ if ((r = suspend(u)) < 0)
+ return r;
+
+ u->sink->sample_spec.rate = u->old_rate;
+
+ if ((r = unsuspend(u)) < 0)
+ return r;
+
+ break;
+ }
+
case PA_SINK_MESSAGE_GET_LATENCY: {
pa_usec_t r = 0;
@@ -867,28 +1118,33 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
switch ((pa_sink_state_t) PA_PTR_TO_UINT(data)) {
- case PA_SINK_SUSPENDED:
+ case PA_SINK_SUSPENDED: {
+ int r;
+
pa_assert(PA_SINK_IS_OPENED(u->sink->thread_info.state));
- if (suspend(u) < 0)
- return -1;
+ if ((r = suspend(u)) < 0)
+ return r;
break;
+ }
case PA_SINK_IDLE:
- case PA_SINK_RUNNING:
+ case PA_SINK_RUNNING: {
+ int r;
if (u->sink->thread_info.state == PA_SINK_INIT) {
if (build_pollfd(u) < 0)
- return -1;
+ return -PA_ERR_IO;
}
if (u->sink->thread_info.state == PA_SINK_SUSPENDED) {
- if (unsuspend(u) < 0)
- return -1;
+ if ((r = unsuspend(u)) < 0)
+ return r;
}
break;
+ }
case PA_SINK_UNLINKED:
case PA_SINK_INIT:
@@ -916,12 +1172,12 @@ static int sink_set_state_cb(pa_sink *s, pa_sink_state_t new_state) {
reserve_done(u);
else if (old_state == PA_SINK_SUSPENDED && PA_SINK_IS_OPENED(new_state))
if (reserve_init(u, u->device_name) < 0)
- return -1;
+ return -PA_ERR_BUSY;
return 0;
}
-static int mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
+static int ctl_mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
struct userdata *u = snd_mixer_elem_get_callback_private(elem);
pa_assert(u);
@@ -930,252 +1186,233 @@ static int mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
if (mask == SND_CTL_EVENT_MASK_REMOVE)
return 0;
+ if (u->sink->suspend_cause & PA_SUSPEND_SESSION)
+ return 0;
+
if (mask & SND_CTL_EVENT_MASK_VALUE) {
- pa_sink_get_volume(u->sink, TRUE, FALSE);
+ pa_sink_get_volume(u->sink, TRUE);
pa_sink_get_mute(u->sink, TRUE);
}
return 0;
}
-static pa_volume_t from_alsa_volume(struct userdata *u, long alsa_vol) {
+static int io_mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
+ struct userdata *u = snd_mixer_elem_get_callback_private(elem);
- return (pa_volume_t) round(((double) (alsa_vol - u->hw_volume_min) * PA_VOLUME_NORM) /
- (double) (u->hw_volume_max - u->hw_volume_min));
-}
+ pa_assert(u);
+ pa_assert(u->mixer_handle);
+
+ if (mask == SND_CTL_EVENT_MASK_REMOVE)
+ return 0;
-static long to_alsa_volume(struct userdata *u, pa_volume_t vol) {
- long alsa_vol;
+ if (u->sink->suspend_cause & PA_SUSPEND_SESSION)
+ return 0;
- alsa_vol = (long) round(((double) vol * (double) (u->hw_volume_max - u->hw_volume_min))
- / PA_VOLUME_NORM) + u->hw_volume_min;
+ if (mask & SND_CTL_EVENT_MASK_VALUE)
+ pa_sink_update_volume_and_mute(u->sink);
- return PA_CLAMP_UNLIKELY(alsa_vol, u->hw_volume_min, u->hw_volume_max);
+ return 0;
}
static void sink_get_volume_cb(pa_sink *s) {
struct userdata *u = s->userdata;
- int err;
- unsigned i;
pa_cvolume r;
- char t[PA_CVOLUME_SNPRINT_MAX];
+ char vol_str_pcnt[PA_CVOLUME_SNPRINT_MAX];
pa_assert(u);
- pa_assert(u->mixer_elem);
-
- if (u->mixer_seperate_channels) {
-
- r.channels = s->sample_spec.channels;
-
- for (i = 0; i < s->sample_spec.channels; i++) {
- long alsa_vol;
-
- if (u->hw_dB_supported) {
-
- if ((err = snd_mixer_selem_get_playback_dB(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
-
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
-
- r.values[i] = pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0);
- } else {
-
- if ((err = snd_mixer_selem_get_playback_volume(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
-
- r.values[i] = from_alsa_volume(u, alsa_vol);
- }
- }
-
- } else {
- long alsa_vol;
-
- if (u->hw_dB_supported) {
-
- if ((err = snd_mixer_selem_get_playback_dB(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
+ if (pa_alsa_path_get_volume(u->mixer_path, u->mixer_handle, &s->channel_map, &r) < 0)
+ return;
- pa_cvolume_set(&r, s->sample_spec.channels, pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0));
+ /* Shift down by the base volume, so that 0dB becomes maximum volume */
+ pa_sw_cvolume_multiply_scalar(&r, &r, s->base_volume);
- } else {
+ pa_log_debug("Read hardware volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &r));
- if ((err = snd_mixer_selem_get_playback_volume(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
+ if (u->mixer_path->has_dB) {
+ char vol_str_db[PA_SW_CVOLUME_SNPRINT_DB_MAX];
- pa_cvolume_set(&r, s->sample_spec.channels, from_alsa_volume(u, alsa_vol));
- }
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &r));
}
- pa_log_debug("Read hardware volume: %s", pa_cvolume_snprint(t, sizeof(t), &r));
-
- if (!pa_cvolume_equal(&u->hardware_volume, &r)) {
-
- s->virtual_volume = u->hardware_volume = r;
-
- if (u->hw_dB_supported) {
- pa_cvolume reset;
-
- /* Hmm, so the hardware volume changed, let's reset our software volume */
- pa_cvolume_reset(&reset, s->sample_spec.channels);
- pa_sink_set_soft_volume(s, &reset);
- }
- }
+ if (pa_cvolume_equal(&u->hardware_volume, &r))
+ return;
- return;
+ s->real_volume = u->hardware_volume = r;
-fail:
- pa_log_error("Unable to read volume: %s", pa_alsa_strerror(err));
+ /* Hmm, so the hardware volume changed, let's reset our software volume */
+ if (u->mixer_path->has_dB)
+ pa_sink_set_soft_volume(s, NULL);
}
static void sink_set_volume_cb(pa_sink *s) {
struct userdata *u = s->userdata;
- int err;
- unsigned i;
pa_cvolume r;
+ char vol_str_pcnt[PA_CVOLUME_SNPRINT_MAX];
+ pa_bool_t sync_volume = !!(s->flags & PA_SINK_SYNC_VOLUME);
pa_assert(u);
- pa_assert(u->mixer_elem);
-
- if (u->mixer_seperate_channels) {
-
- r.channels = s->sample_spec.channels;
-
- for (i = 0; i < s->sample_spec.channels; i++) {
- long alsa_vol;
- pa_volume_t vol;
-
- vol = s->virtual_volume.values[i];
-
- if (u->hw_dB_supported) {
-
- alsa_vol = (long) (pa_sw_volume_to_dB(vol) * 100);
- alsa_vol += u->hw_dB_max;
- alsa_vol = PA_CLAMP_UNLIKELY(alsa_vol, u->hw_dB_min, u->hw_dB_max);
-
- if ((err = snd_mixer_selem_set_playback_dB(u->mixer_elem, u->mixer_map[i], alsa_vol, 1)) < 0)
- goto fail;
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
- if ((err = snd_mixer_selem_get_playback_dB(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
+ /* Shift up by the base volume */
+ pa_sw_cvolume_divide_scalar(&r, &s->real_volume, s->base_volume);
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
-
- r.values[i] = pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0);
+ if (pa_alsa_path_set_volume(u->mixer_path, u->mixer_handle, &s->channel_map, &r, sync_volume, !sync_volume) < 0)
+ return;
- } else {
- alsa_vol = to_alsa_volume(u, vol);
+ /* Shift down by the base volume, so that 0dB becomes maximum volume */
+ pa_sw_cvolume_multiply_scalar(&r, &r, s->base_volume);
- if ((err = snd_mixer_selem_set_playback_volume(u->mixer_elem, u->mixer_map[i], alsa_vol)) < 0)
- goto fail;
+ u->hardware_volume = r;
- if ((err = snd_mixer_selem_get_playback_volume(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
+ if (u->mixer_path->has_dB) {
+ pa_cvolume new_soft_volume;
+ pa_bool_t accurate_enough;
+ char vol_str_db[PA_SW_CVOLUME_SNPRINT_DB_MAX];
- r.values[i] = from_alsa_volume(u, alsa_vol);
- }
- }
+ /* Match exactly what the user requested by software */
+ pa_sw_cvolume_divide(&new_soft_volume, &s->real_volume, &u->hardware_volume);
+
+ /* If the adjustment to do in software is only minimal we
+ * can skip it. That saves us CPU at the expense of a bit of
+ * accuracy */
+ accurate_enough =
+ (pa_cvolume_min(&new_soft_volume) >= (PA_VOLUME_NORM - VOLUME_ACCURACY)) &&
+ (pa_cvolume_max(&new_soft_volume) <= (PA_VOLUME_NORM + VOLUME_ACCURACY));
+
+ pa_log_debug("Requested volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &s->real_volume));
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &s->real_volume));
+ pa_log_debug("Got hardware volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &u->hardware_volume));
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &u->hardware_volume));
+ pa_log_debug("Calculated software volume: %s (accurate-enough=%s)",
+ pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &new_soft_volume),
+ pa_yes_no(accurate_enough));
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &new_soft_volume));
+
+ if (!accurate_enough)
+ s->soft_volume = new_soft_volume;
} else {
- pa_volume_t vol;
- long alsa_vol;
-
- vol = pa_cvolume_max(&s->virtual_volume);
-
- if (u->hw_dB_supported) {
- alsa_vol = (long) (pa_sw_volume_to_dB(vol) * 100);
- alsa_vol += u->hw_dB_max;
- alsa_vol = PA_CLAMP_UNLIKELY(alsa_vol, u->hw_dB_min, u->hw_dB_max);
-
- if ((err = snd_mixer_selem_set_playback_dB_all(u->mixer_elem, alsa_vol, 1)) < 0)
- goto fail;
-
- if ((err = snd_mixer_selem_get_playback_dB(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
+ pa_log_debug("Wrote hardware volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &r));
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
+ /* We can't match exactly what the user requested, hence let's
+ * at least tell the user about it */
- pa_cvolume_set(&r, s->sample_spec.channels, pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0));
+ s->real_volume = r;
+ }
+}
- } else {
- alsa_vol = to_alsa_volume(u, vol);
+static void sink_write_volume_cb(pa_sink *s) {
+ struct userdata *u = s->userdata;
+ pa_cvolume hw_vol = s->thread_info.current_hw_volume;
- if ((err = snd_mixer_selem_set_playback_volume_all(u->mixer_elem, alsa_vol)) < 0)
- goto fail;
+ pa_assert(u);
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
+ pa_assert(s->flags & PA_SINK_SYNC_VOLUME);
- if ((err = snd_mixer_selem_get_playback_volume(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
+ /* Shift up by the base volume */
+ pa_sw_cvolume_divide_scalar(&hw_vol, &hw_vol, s->base_volume);
- pa_cvolume_set(&r, s->sample_spec.channels, from_alsa_volume(u, alsa_vol));
+ if (pa_alsa_path_set_volume(u->mixer_path, u->mixer_handle, &s->channel_map, &hw_vol, TRUE, TRUE) < 0)
+ pa_log_error("Writing HW volume failed");
+ else {
+ pa_cvolume tmp_vol;
+ pa_bool_t accurate_enough;
+
+ /* Shift down by the base volume, so that 0dB becomes maximum volume */
+ pa_sw_cvolume_multiply_scalar(&hw_vol, &hw_vol, s->base_volume);
+
+ pa_sw_cvolume_divide(&tmp_vol, &hw_vol, &s->thread_info.current_hw_volume);
+ accurate_enough =
+ (pa_cvolume_min(&tmp_vol) >= (PA_VOLUME_NORM - VOLUME_ACCURACY)) &&
+ (pa_cvolume_max(&tmp_vol) <= (PA_VOLUME_NORM + VOLUME_ACCURACY));
+
+ if (!accurate_enough) {
+ union {
+ char db[2][PA_SW_CVOLUME_SNPRINT_DB_MAX];
+ char pcnt[2][PA_CVOLUME_SNPRINT_MAX];
+ } vol;
+
+ pa_log_debug("Written HW volume did not match with the request: %s (request) != %s",
+ pa_cvolume_snprint(vol.pcnt[0], sizeof(vol.pcnt[0]), &s->thread_info.current_hw_volume),
+ pa_cvolume_snprint(vol.pcnt[1], sizeof(vol.pcnt[1]), &hw_vol));
+ pa_log_debug(" in dB: %s (request) != %s",
+ pa_sw_cvolume_snprint_dB(vol.db[0], sizeof(vol.db[0]), &s->thread_info.current_hw_volume),
+ pa_sw_cvolume_snprint_dB(vol.db[1], sizeof(vol.db[1]), &hw_vol));
}
}
-
- u->hardware_volume = r;
-
- if (u->hw_dB_supported) {
- char t[PA_CVOLUME_SNPRINT_MAX];
-
- /* Match exactly what the user requested by software */
- pa_sw_cvolume_divide(&s->soft_volume, &s->virtual_volume, &u->hardware_volume);
-
- pa_log_debug("Requested volume: %s", pa_cvolume_snprint(t, sizeof(t), &s->virtual_volume));
- pa_log_debug("Got hardware volume: %s", pa_cvolume_snprint(t, sizeof(t), &u->hardware_volume));
- pa_log_debug("Calculated software volume: %s", pa_cvolume_snprint(t, sizeof(t), &s->soft_volume));
-
- } else
-
- /* We can't match exactly what the user requested, hence let's
- * at least tell the user about it */
-
- s->virtual_volume = r;
-
- return;
-
-fail:
- pa_log_error("Unable to set volume: %s", pa_alsa_strerror(err));
}
static void sink_get_mute_cb(pa_sink *s) {
struct userdata *u = s->userdata;
- int err, sw;
+ pa_bool_t b;
pa_assert(u);
- pa_assert(u->mixer_elem);
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
- if ((err = snd_mixer_selem_get_playback_switch(u->mixer_elem, 0, &sw)) < 0) {
- pa_log_error("Unable to get switch: %s", pa_alsa_strerror(err));
+ if (pa_alsa_path_get_mute(u->mixer_path, u->mixer_handle, &b) < 0)
return;
- }
- s->muted = !sw;
+ s->muted = b;
}
static void sink_set_mute_cb(pa_sink *s) {
struct userdata *u = s->userdata;
- int err;
pa_assert(u);
- pa_assert(u->mixer_elem);
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
- if ((err = snd_mixer_selem_set_playback_switch_all(u->mixer_elem, !s->muted)) < 0) {
- pa_log_error("Unable to set switch: %s", pa_alsa_strerror(err));
- return;
+ pa_alsa_path_set_mute(u->mixer_path, u->mixer_handle, s->muted);
+}
+
+static int sink_set_port_cb(pa_sink *s, pa_device_port *p) {
+ struct userdata *u = s->userdata;
+ pa_alsa_port_data *data;
+
+ pa_assert(u);
+ pa_assert(p);
+ pa_assert(u->mixer_handle);
+
+ data = PA_DEVICE_PORT_DATA(p);
+
+ pa_assert_se(u->mixer_path = data->path);
+ pa_alsa_path_select(u->mixer_path, u->mixer_handle);
+
+ if (u->mixer_path->has_volume && u->mixer_path->has_dB) {
+ s->base_volume = pa_sw_volume_from_dB(-u->mixer_path->max_dB);
+ s->n_volume_steps = PA_VOLUME_NORM+1;
+
+ pa_log_info("Fixing base volume to %0.2f dB", pa_sw_volume_to_dB(s->base_volume));
+ } else {
+ s->base_volume = PA_VOLUME_NORM;
+ s->n_volume_steps = u->mixer_path->max_volume - u->mixer_path->min_volume + 1;
}
+
+ if (data->setting)
+ pa_alsa_setting_select(data->setting, u->mixer_handle);
+
+ if (s->set_mute)
+ s->set_mute(s);
+ if (s->set_volume)
+ s->set_volume(s);
+
+ return 0;
}
static void sink_update_requested_latency_cb(pa_sink *s) {
struct userdata *u = s->userdata;
size_t before;
pa_assert(u);
+ pa_assert(u->use_tsched); /* only when timer scheduling is used
+ * we can dynamically adjust the
+ * latency */
if (!u->pcm_handle)
return;
@@ -1210,7 +1447,10 @@ static int process_rewind(struct userdata *u) {
return -1;
}
- unused_nbytes = u->tsched_watermark + (size_t) unused * u->frame_size;
+ unused_nbytes = (size_t) unused * u->frame_size;
+
+ /* make sure rewind doesn't go too far, can cause issues with DMAs */
+ unused_nbytes += u->rewind_safeguard;
if (u->hwbuf_size > unused_nbytes)
limit_nbytes = u->hwbuf_size - unused_nbytes;
@@ -1229,8 +1469,11 @@ static int process_rewind(struct userdata *u) {
pa_log_debug("before: %lu", (unsigned long) in_frames);
if ((out_frames = snd_pcm_rewind(u->pcm_handle, (snd_pcm_uframes_t) in_frames)) < 0) {
pa_log("snd_pcm_rewind() failed: %s", pa_alsa_strerror((int) out_frames));
- return -1;
+ if (try_recover(u, "process_rewind", out_frames) < 0)
+ return -1;
+ out_frames = 0;
}
+
pa_log_debug("after: %lu", (unsigned long) out_frames);
rewind_nbytes = (size_t) out_frames * u->frame_size;
@@ -1238,7 +1481,7 @@ static int process_rewind(struct userdata *u) {
if (rewind_nbytes <= 0)
pa_log_info("Tried rewind, but was apparently not possible.");
else {
- u->write_count -= out_frames * u->frame_size;
+ u->write_count -= rewind_nbytes;
pa_log_debug("Rewound %lu bytes.", (unsigned long) rewind_nbytes);
pa_sink_process_rewind(u->sink, rewind_nbytes);
@@ -1264,10 +1507,10 @@ static void thread_func(void *userdata) {
pa_make_realtime(u->core->realtime_priority);
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
int ret;
+ pa_usec_t rtpoll_sleep = 0;
#ifdef DEBUG_TIMING
pa_log_debug("Loop");
@@ -1277,15 +1520,16 @@ static void thread_func(void *userdata) {
if (PA_SINK_IS_OPENED(u->sink->thread_info.state)) {
int work_done;
pa_usec_t sleep_usec = 0;
+ pa_bool_t on_timeout = pa_rtpoll_timer_elapsed(u->rtpoll);
if (PA_UNLIKELY(u->sink->thread_info.rewind_requested))
if (process_rewind(u) < 0)
goto fail;
if (u->use_mmap)
- work_done = mmap_write(u, &sleep_usec, revents & POLLOUT);
+ work_done = mmap_write(u, &sleep_usec, revents & POLLOUT, on_timeout);
else
- work_done = unix_write(u, &sleep_usec, revents & POLLOUT);
+ work_done = unix_write(u, &sleep_usec, revents & POLLOUT, on_timeout);
if (work_done < 0)
goto fail;
@@ -1298,7 +1542,9 @@ static void thread_func(void *userdata) {
pa_log_info("Starting playback.");
snd_pcm_start(u->pcm_handle);
- pa_smoother_resume(u->smoother, pa_rtclock_usec(), TRUE);
+ pa_smoother_resume(u->smoother, pa_rtclock_now(), TRUE);
+
+ u->first = FALSE;
}
update_smoother(u);
@@ -1317,7 +1563,8 @@ static void thread_func(void *userdata) {
* we have filled the buffer at least once
* completely.*/
- pa_log_debug("Cutting sleep time for the initial iterations by half.");
+ if (pa_log_ratelimit(PA_LOG_DEBUG))
+ pa_log_debug("Cutting sleep time for the initial iterations by half.");
sleep_usec /= 2;
}
@@ -1327,26 +1574,37 @@ static void thread_func(void *userdata) {
/* Convert from the sound card time domain to the
* system time domain */
- cusec = pa_smoother_translate(u->smoother, pa_rtclock_usec(), sleep_usec);
+ cusec = pa_smoother_translate(u->smoother, pa_rtclock_now(), sleep_usec);
/* pa_log_debug("Waking up in %0.2fms (system clock).", (double) cusec / PA_USEC_PER_MSEC); */
/* We don't trust the conversion, so we wake up whatever comes first */
- pa_rtpoll_set_timer_relative(u->rtpoll, PA_MIN(sleep_usec, cusec));
+ rtpoll_sleep = PA_MIN(sleep_usec, cusec);
}
- u->first = FALSE;
u->after_rewind = FALSE;
- } else if (u->use_tsched)
+ }
+
+ if (u->sink->flags & PA_SINK_SYNC_VOLUME) {
+ pa_usec_t volume_sleep;
+ pa_sink_volume_change_apply(u->sink, &volume_sleep);
+ if (volume_sleep > 0)
+ rtpoll_sleep = PA_MIN(volume_sleep, rtpoll_sleep);
+ }
- /* OK, we're in an invalid state, let's disable our timers */
+ if (rtpoll_sleep > 0)
+ pa_rtpoll_set_timer_relative(u->rtpoll, rtpoll_sleep);
+ else
pa_rtpoll_set_timer_disabled(u->rtpoll);
/* Hmm, nothing to do. Let's sleep */
if ((ret = pa_rtpoll_run(u->rtpoll, TRUE)) < 0)
goto fail;
+ if (u->sink->flags & PA_SINK_SYNC_VOLUME)
+ pa_sink_volume_change_apply(u->sink, NULL);
+
if (ret == 0)
goto finish;
@@ -1369,7 +1627,7 @@ static void thread_func(void *userdata) {
u->first = TRUE;
u->since_start = 0;
- } else if (revents && u->use_tsched && pa_log_ratelimit())
+ } else if (revents && u->use_tsched && pa_log_ratelimit(PA_LOG_DEBUG))
pa_log_debug("Wakeup from ALSA!");
} else
@@ -1386,7 +1644,7 @@ finish:
pa_log_debug("Thread shutting down");
}
-static void set_sink_name(pa_sink_new_data *data, pa_modargs *ma, const char *device_id, const char *device_name) {
+static void set_sink_name(pa_sink_new_data *data, pa_modargs *ma, const char *device_id, const char *device_name, pa_alsa_mapping *mapping) {
const char *n;
char *t;
@@ -1407,108 +1665,184 @@ static void set_sink_name(pa_sink_new_data *data, pa_modargs *ma, const char *de
data->namereg_fail = FALSE;
}
- t = pa_sprintf_malloc("alsa_output.%s", n);
+ if (mapping)
+ t = pa_sprintf_malloc("alsa_output.%s.%s", n, mapping->name);
+ else
+ t = pa_sprintf_malloc("alsa_output.%s", n);
+
pa_sink_new_data_set_name(data, t);
pa_xfree(t);
}
-static int setup_mixer(struct userdata *u, pa_bool_t ignore_dB) {
+static void find_mixer(struct userdata *u, pa_alsa_mapping *mapping, const char *element, pa_bool_t ignore_dB) {
+
+ if (!mapping && !element)
+ return;
+
+ if (!(u->mixer_handle = pa_alsa_open_mixer_for_pcm(u->pcm_handle, &u->control_device))) {
+ pa_log_info("Failed to find a working mixer device.");
+ return;
+ }
+
+ if (element) {
+
+ if (!(u->mixer_path = pa_alsa_path_synthesize(element, PA_ALSA_DIRECTION_OUTPUT)))
+ goto fail;
+
+ if (pa_alsa_path_probe(u->mixer_path, u->mixer_handle, ignore_dB) < 0)
+ goto fail;
+
+ pa_log_debug("Probed mixer path %s:", u->mixer_path->name);
+ pa_alsa_path_dump(u->mixer_path);
+ } else {
+
+ if (!(u->mixer_path_set = pa_alsa_path_set_new(mapping, PA_ALSA_DIRECTION_OUTPUT)))
+ goto fail;
+
+ pa_alsa_path_set_probe(u->mixer_path_set, u->mixer_handle, ignore_dB);
+
+ pa_log_debug("Probed mixer paths:");
+ pa_alsa_path_set_dump(u->mixer_path_set);
+ }
+
+ return;
+
+fail:
+
+ if (u->mixer_path_set) {
+ pa_alsa_path_set_free(u->mixer_path_set);
+ u->mixer_path_set = NULL;
+ } else if (u->mixer_path) {
+ pa_alsa_path_free(u->mixer_path);
+ u->mixer_path = NULL;
+ }
+
+ if (u->mixer_handle) {
+ snd_mixer_close(u->mixer_handle);
+ u->mixer_handle = NULL;
+ }
+}
+
+static int setup_mixer(struct userdata *u, pa_bool_t ignore_dB, pa_bool_t sync_volume) {
pa_assert(u);
if (!u->mixer_handle)
return 0;
- pa_assert(u->mixer_elem);
+ if (u->sink->active_port) {
+ pa_alsa_port_data *data;
- if (snd_mixer_selem_has_playback_volume(u->mixer_elem)) {
- pa_bool_t suitable = FALSE;
+ /* We have a list of supported paths, so let's activate the
+ * one that has been chosen as active */
- if (snd_mixer_selem_get_playback_volume_range(u->mixer_elem, &u->hw_volume_min, &u->hw_volume_max) < 0)
- pa_log_info("Failed to get volume range. Falling back to software volume control.");
- else if (u->hw_volume_min >= u->hw_volume_max)
- pa_log_warn("Your kernel driver is broken: it reports a volume range from %li to %li which makes no sense.", u->hw_volume_min, u->hw_volume_max);
- else {
- pa_log_info("Volume ranges from %li to %li.", u->hw_volume_min, u->hw_volume_max);
- suitable = TRUE;
- }
+ data = PA_DEVICE_PORT_DATA(u->sink->active_port);
+ u->mixer_path = data->path;
- if (suitable) {
- if (ignore_dB || snd_mixer_selem_get_playback_dB_range(u->mixer_elem, &u->hw_dB_min, &u->hw_dB_max) < 0)
- pa_log_info("Mixer doesn't support dB information or data is ignored.");
- else {
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&u->hw_dB_min, sizeof(u->hw_dB_min));
- VALGRIND_MAKE_MEM_DEFINED(&u->hw_dB_max, sizeof(u->hw_dB_max));
-#endif
+ pa_alsa_path_select(data->path, u->mixer_handle);
- if (u->hw_dB_min >= u->hw_dB_max)
- pa_log_warn("Your kernel driver is broken: it reports a volume range from %0.2f dB to %0.2f dB which makes no sense.", (double) u->hw_dB_min/100.0, (double) u->hw_dB_max/100.0);
- else {
- pa_log_info("Volume ranges from %0.2f dB to %0.2f dB.", (double) u->hw_dB_min/100.0, (double) u->hw_dB_max/100.0);
- u->hw_dB_supported = TRUE;
-
- if (u->hw_dB_max > 0) {
- u->sink->base_volume = pa_sw_volume_from_dB(- (double) u->hw_dB_max/100.0);
- pa_log_info("Fixing base volume to %0.2f dB", pa_sw_volume_to_dB(u->sink->base_volume));
- } else
- pa_log_info("No particular base volume set, fixing to 0 dB");
- }
- }
+ if (data->setting)
+ pa_alsa_setting_select(data->setting, u->mixer_handle);
- if (!u->hw_dB_supported &&
- u->hw_volume_max - u->hw_volume_min < 3) {
+ } else {
- pa_log_info("Device doesn't do dB volume and has less than 4 volume levels. Falling back to software volume control.");
- suitable = FALSE;
- }
- }
+ if (!u->mixer_path && u->mixer_path_set)
+ u->mixer_path = u->mixer_path_set->paths;
- if (suitable) {
- u->mixer_seperate_channels = pa_alsa_calc_mixer_map(u->mixer_elem, &u->sink->channel_map, u->mixer_map, TRUE) >= 0;
+ if (u->mixer_path) {
+ /* Hmm, we have only a single path, then let's activate it */
- u->sink->get_volume = sink_get_volume_cb;
- u->sink->set_volume = sink_set_volume_cb;
- u->sink->flags |= PA_SINK_HW_VOLUME_CTRL | (u->hw_dB_supported ? PA_SINK_DECIBEL_VOLUME : 0);
- pa_log_info("Using hardware volume control. Hardware dB scale %s.", u->hw_dB_supported ? "supported" : "not supported");
+ pa_alsa_path_select(u->mixer_path, u->mixer_handle);
- if (!u->hw_dB_supported)
- u->sink->n_volume_steps = u->hw_volume_max - u->hw_volume_min + 1;
+ if (u->mixer_path->settings)
+ pa_alsa_setting_select(u->mixer_path->settings, u->mixer_handle);
} else
- pa_log_info("Using software volume control.");
+ return 0;
}
- if (snd_mixer_selem_has_playback_switch(u->mixer_elem)) {
+ if (!u->mixer_path->has_volume)
+ pa_log_info("Driver does not support hardware volume control, falling back to software volume control.");
+ else {
+
+ if (u->mixer_path->has_dB) {
+ pa_log_info("Hardware volume ranges from %0.2f dB to %0.2f dB.", u->mixer_path->min_dB, u->mixer_path->max_dB);
+
+ u->sink->base_volume = pa_sw_volume_from_dB(-u->mixer_path->max_dB);
+ u->sink->n_volume_steps = PA_VOLUME_NORM+1;
+
+ pa_log_info("Fixing base volume to %0.2f dB", pa_sw_volume_to_dB(u->sink->base_volume));
+
+ } else {
+ pa_log_info("Hardware volume ranges from %li to %li.", u->mixer_path->min_volume, u->mixer_path->max_volume);
+ u->sink->base_volume = PA_VOLUME_NORM;
+ u->sink->n_volume_steps = u->mixer_path->max_volume - u->mixer_path->min_volume + 1;
+ }
+
+ u->sink->get_volume = sink_get_volume_cb;
+ u->sink->set_volume = sink_set_volume_cb;
+ u->sink->write_volume = sink_write_volume_cb;
+
+ u->sink->flags |= PA_SINK_HW_VOLUME_CTRL;
+ if (u->mixer_path->has_dB) {
+ u->sink->flags |= PA_SINK_DECIBEL_VOLUME;
+ if (sync_volume) {
+ u->sink->flags |= PA_SINK_SYNC_VOLUME;
+ pa_log_info("Successfully enabled synchronous volume.");
+ }
+ }
+
+ pa_log_info("Using hardware volume control. Hardware dB scale %s.", u->mixer_path->has_dB ? "supported" : "not supported");
+ }
+
+ if (!u->mixer_path->has_mute) {
+ pa_log_info("Driver does not support hardware mute control, falling back to software mute control.");
+ } else {
u->sink->get_mute = sink_get_mute_cb;
u->sink->set_mute = sink_set_mute_cb;
u->sink->flags |= PA_SINK_HW_MUTE_CTRL;
- } else
- pa_log_info("Using software mute control.");
+ pa_log_info("Using hardware mute control.");
+ }
- u->mixer_fdl = pa_alsa_fdlist_new();
+ if (u->sink->flags & (PA_SINK_HW_VOLUME_CTRL|PA_SINK_HW_MUTE_CTRL)) {
+ int (*mixer_callback)(snd_mixer_elem_t *, unsigned int);
+ if (u->sink->flags & PA_SINK_SYNC_VOLUME) {
+ u->mixer_pd = pa_alsa_mixer_pdata_new();
+ mixer_callback = io_mixer_callback;
- if (pa_alsa_fdlist_set_mixer(u->mixer_fdl, u->mixer_handle, u->core->mainloop) < 0) {
- pa_log("Failed to initialize file descriptor monitoring");
- return -1;
- }
+ if (pa_alsa_set_mixer_rtpoll(u->mixer_pd, u->mixer_handle, u->rtpoll) < 0) {
+ pa_log("Failed to initialize file descriptor monitoring");
+ return -1;
+ }
+ } else {
+ u->mixer_fdl = pa_alsa_fdlist_new();
+ mixer_callback = ctl_mixer_callback;
+
+ if (pa_alsa_fdlist_set_mixer(u->mixer_fdl, u->mixer_handle, u->core->mainloop) < 0) {
+ pa_log("Failed to initialize file descriptor monitoring");
+ return -1;
+ }
+ }
- snd_mixer_elem_set_callback(u->mixer_elem, mixer_callback);
- snd_mixer_elem_set_callback_private(u->mixer_elem, u);
+ if (u->mixer_path_set)
+ pa_alsa_path_set_set_callback(u->mixer_path_set, u->mixer_handle, mixer_callback, u);
+ else
+ pa_alsa_path_set_callback(u->mixer_path, u->mixer_handle, mixer_callback, u);
+ }
return 0;
}
-pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, const pa_alsa_profile_info *profile) {
+pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, pa_alsa_mapping *mapping) {
struct userdata *u = NULL;
const char *dev_id = NULL;
pa_sample_spec ss, requested_ss;
pa_channel_map map;
- uint32_t nfrags, hwbuf_size, frag_size, tsched_size, tsched_watermark;
- snd_pcm_uframes_t period_frames, tsched_frames;
+ uint32_t nfrags, frag_size, buffer_size, tsched_size, tsched_watermark, rewind_safeguard;
+ snd_pcm_uframes_t period_frames, buffer_frames, tsched_frames;
size_t frame_size;
- pa_bool_t use_mmap = TRUE, b, use_tsched = TRUE, d, ignore_dB = FALSE;
+ pa_bool_t use_mmap = TRUE, b, use_tsched = TRUE, d, ignore_dB = FALSE, namereg_fail = FALSE, sync_volume = FALSE;
pa_sink_new_data data;
- char *control_device = NULL;
+ pa_alsa_profile_set *profile_set = NULL;
pa_assert(m);
pa_assert(ma);
@@ -1538,8 +1872,10 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
goto fail;
}
- hwbuf_size = frag_size * nfrags;
+ buffer_size = nfrags * frag_size;
+
period_frames = frag_size/frame_size;
+ buffer_frames = buffer_size/frame_size;
tsched_frames = tsched_size/frame_size;
if (pa_modargs_get_value_boolean(ma, "mmap", &use_mmap) < 0) {
@@ -1557,64 +1893,81 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
goto fail;
}
- if (use_tsched && !pa_rtclock_hrtimer()) {
- pa_log_notice("Disabling timer-based scheduling because high-resolution timers are not available from the kernel.");
- use_tsched = FALSE;
+ rewind_safeguard = PA_MAX(DEFAULT_REWIND_SAFEGUARD_BYTES, pa_usec_to_bytes(DEFAULT_REWIND_SAFEGUARD_USEC, &ss));
+ if (pa_modargs_get_value_u32(ma, "rewind_safeguard", &rewind_safeguard) < 0) {
+ pa_log("Failed to parse rewind_safeguard argument");
+ goto fail;
}
+ sync_volume = m->core->sync_volume;
+ if (pa_modargs_get_value_boolean(ma, "sync_volume", &sync_volume) < 0) {
+ pa_log("Failed to parse sync_volume argument.");
+ goto fail;
+ }
+
+ use_tsched = pa_alsa_may_tsched(use_tsched);
+
u = pa_xnew0(struct userdata, 1);
u->core = m->core;
u->module = m;
u->use_mmap = use_mmap;
u->use_tsched = use_tsched;
u->first = TRUE;
+ u->rewind_safeguard = rewind_safeguard;
u->rtpoll = pa_rtpoll_new();
pa_thread_mq_init(&u->thread_mq, m->core->mainloop, u->rtpoll);
u->smoother = pa_smoother_new(
- DEFAULT_TSCHED_BUFFER_USEC*2,
- DEFAULT_TSCHED_BUFFER_USEC*2,
+ SMOOTHER_ADJUST_USEC,
+ SMOOTHER_WINDOW_USEC,
TRUE,
TRUE,
5,
- pa_rtclock_usec(),
+ pa_rtclock_now(),
TRUE);
+ u->smoother_interval = SMOOTHER_MIN_INTERVAL;
- if (reserve_init(u, pa_modargs_get_value(
- ma, "device_id",
- pa_modargs_get_value(ma, "device", DEFAULT_DEVICE))) < 0)
+ dev_id = pa_modargs_get_value(
+ ma, "device_id",
+ pa_modargs_get_value(ma, "device", DEFAULT_DEVICE));
+
+ if (reserve_init(u, dev_id) < 0)
+ goto fail;
+
+ if (reserve_monitor_init(u, dev_id) < 0)
goto fail;
b = use_mmap;
d = use_tsched;
- if (profile) {
+ if (mapping) {
if (!(dev_id = pa_modargs_get_value(ma, "device_id", NULL))) {
pa_log("device_id= not set");
goto fail;
}
- if (!(u->pcm_handle = pa_alsa_open_by_device_id_profile(
+ if (!(u->pcm_handle = pa_alsa_open_by_device_id_mapping(
dev_id,
&u->device_name,
&ss, &map,
SND_PCM_STREAM_PLAYBACK,
- &nfrags, &period_frames, tsched_frames,
- &b, &d, profile)))
-
+ &period_frames, &buffer_frames, tsched_frames,
+ &b, &d, mapping)))
goto fail;
} else if ((dev_id = pa_modargs_get_value(ma, "device_id", NULL))) {
+ if (!(profile_set = pa_alsa_profile_set_new(NULL, &map)))
+ goto fail;
+
if (!(u->pcm_handle = pa_alsa_open_by_device_id_auto(
dev_id,
&u->device_name,
&ss, &map,
SND_PCM_STREAM_PLAYBACK,
- &nfrags, &period_frames, tsched_frames,
- &b, &d, &profile)))
-
+ &period_frames, &buffer_frames, tsched_frames,
+ &b, &d, profile_set, &mapping)))
goto fail;
} else {
@@ -1624,10 +1977,9 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
&u->device_name,
&ss, &map,
SND_PCM_STREAM_PLAYBACK,
- &nfrags, &period_frames, tsched_frames,
+ &period_frames, &buffer_frames, tsched_frames,
&b, &d, FALSE)))
goto fail;
-
}
pa_assert(u->device_name);
@@ -1638,8 +1990,8 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
goto fail;
}
- if (profile)
- pa_log_info("Selected configuration '%s' (%s).", profile->description, profile->name);
+ if (mapping)
+ pa_log_info("Selected mapping '%s' (%s).", mapping->description, mapping->name);
if (use_mmap && !b) {
pa_log_info("Device doesn't support mmap(), falling back to UNIX read/write mode.");
@@ -1651,11 +2003,6 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
u->use_tsched = use_tsched = FALSE;
}
- if (use_tsched && !pa_alsa_pcm_is_hw(u->pcm_handle)) {
- pa_log_info("Device is not a hardware device, disabling timer-based scheduling.");
- u->use_tsched = use_tsched = FALSE;
- }
-
if (u->use_mmap)
pa_log_info("Successfully enabled mmap() mode.");
@@ -1665,33 +2012,44 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
/* ALSA might tweak the sample spec, so recalculate the frame size */
frame_size = pa_frame_size(&ss);
- pa_alsa_find_mixer_and_elem(u->pcm_handle, &control_device, &u->mixer_handle, &u->mixer_elem, pa_modargs_get_value(ma, "control", NULL), profile);
+ find_mixer(u, mapping, pa_modargs_get_value(ma, "control", NULL), ignore_dB);
pa_sink_new_data_init(&data);
data.driver = driver;
data.module = m;
data.card = card;
- set_sink_name(&data, ma, dev_id, u->device_name);
+ set_sink_name(&data, ma, dev_id, u->device_name, mapping);
+
+ /* We need to give pa_modargs_get_value_boolean() a pointer to a local
+ * variable instead of using &data.namereg_fail directly, because
+ * data.namereg_fail is a bitfield and taking the address of a bitfield
+ * variable is impossible. */
+ namereg_fail = data.namereg_fail;
+ if (pa_modargs_get_value_boolean(ma, "namereg_fail", &namereg_fail) < 0) {
+ pa_log("Failed to parse boolean argument namereg_fail.");
+ pa_sink_new_data_done(&data);
+ goto fail;
+ }
+ data.namereg_fail = namereg_fail;
+
pa_sink_new_data_set_sample_spec(&data, &ss);
pa_sink_new_data_set_channel_map(&data, &map);
- pa_alsa_init_proplist_pcm(m->core, data.proplist, u->pcm_handle, u->mixer_elem);
+ pa_alsa_init_proplist_pcm(m->core, data.proplist, u->pcm_handle);
pa_proplist_sets(data.proplist, PA_PROP_DEVICE_STRING, u->device_name);
- pa_proplist_setf(data.proplist, PA_PROP_DEVICE_BUFFERING_BUFFER_SIZE, "%lu", (unsigned long) (period_frames * frame_size * nfrags));
+ pa_proplist_setf(data.proplist, PA_PROP_DEVICE_BUFFERING_BUFFER_SIZE, "%lu", (unsigned long) (buffer_frames * frame_size));
pa_proplist_setf(data.proplist, PA_PROP_DEVICE_BUFFERING_FRAGMENT_SIZE, "%lu", (unsigned long) (period_frames * frame_size));
pa_proplist_sets(data.proplist, PA_PROP_DEVICE_ACCESS_MODE, u->use_tsched ? "mmap+timer" : (u->use_mmap ? "mmap" : "serial"));
- if (profile) {
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_NAME, profile->name);
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_DESCRIPTION, profile->description);
+ if (mapping) {
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_NAME, mapping->name);
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_DESCRIPTION, mapping->description);
}
pa_alsa_init_description(data.proplist);
- if (control_device) {
- pa_alsa_init_proplist_ctl(data.proplist, control_device);
- pa_xfree(control_device);
- }
+ if (u->control_device)
+ pa_alsa_init_proplist_ctl(data.proplist, u->control_device);
if (pa_modargs_get_proplist(ma, "sink_properties", data.proplist, PA_UPDATE_REPLACE) < 0) {
pa_log("Invalid properties");
@@ -1699,6 +2057,9 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
goto fail;
}
+ if (u->mixer_path_set)
+ pa_alsa_add_ports(&data.ports, u->mixer_path_set);
+
u->sink = pa_sink_new(m->core, &data, PA_SINK_HARDWARE|PA_SINK_LATENCY|(u->use_tsched ? PA_SINK_DYNAMIC_LATENCY : 0));
pa_sink_new_data_done(&data);
@@ -1707,30 +2068,56 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
goto fail;
}
+ if (pa_modargs_get_value_u32(ma, "sync_volume_safety_margin",
+ &u->sink->thread_info.volume_change_safety_margin) < 0) {
+ pa_log("Failed to parse sync_volume_safety_margin parameter");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_s32(ma, "sync_volume_extra_delay",
+ &u->sink->thread_info.volume_change_extra_delay) < 0) {
+ pa_log("Failed to parse sync_volume_extra_delay parameter");
+ goto fail;
+ }
+
u->sink->parent.process_msg = sink_process_msg;
- u->sink->update_requested_latency = sink_update_requested_latency_cb;
+ if (u->use_tsched)
+ u->sink->update_requested_latency = sink_update_requested_latency_cb;
u->sink->set_state = sink_set_state_cb;
+ u->sink->set_port = sink_set_port_cb;
u->sink->userdata = u;
pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
pa_sink_set_rtpoll(u->sink, u->rtpoll);
u->frame_size = frame_size;
- u->fragment_size = frag_size = (uint32_t) (period_frames * frame_size);
- u->nfragments = nfrags;
- u->hwbuf_size = u->fragment_size * nfrags;
- u->tsched_watermark = pa_usec_to_bytes_round_up(pa_bytes_to_usec_round_up(tsched_watermark, &requested_ss), &u->sink->sample_spec);
+ u->fragment_size = frag_size = (size_t) (period_frames * frame_size);
+ u->hwbuf_size = buffer_size = (size_t) (buffer_frames * frame_size);
pa_cvolume_mute(&u->hardware_volume, u->sink->sample_spec.channels);
- pa_log_info("Using %u fragments of size %lu bytes, buffer time is %0.2fms",
- nfrags, (long unsigned) u->fragment_size,
+ pa_log_info("Using %0.1f fragments of size %lu bytes (%0.2fms), buffer size is %lu bytes (%0.2fms)",
+ (double) u->hwbuf_size / (double) u->fragment_size,
+ (long unsigned) u->fragment_size,
+ (double) pa_bytes_to_usec(u->fragment_size, &ss) / PA_USEC_PER_MSEC,
+ (long unsigned) u->hwbuf_size,
(double) pa_bytes_to_usec(u->hwbuf_size, &ss) / PA_USEC_PER_MSEC);
pa_sink_set_max_request(u->sink, u->hwbuf_size);
- pa_sink_set_max_rewind(u->sink, u->hwbuf_size);
+ if (pa_alsa_pcm_is_hw(u->pcm_handle))
+ pa_sink_set_max_rewind(u->sink, u->hwbuf_size);
+ else {
+ pa_log_info("Disabling rewind for device %s", u->device_name);
+ pa_sink_set_max_rewind(u->sink, 0);
+ }
if (u->use_tsched) {
- u->watermark_step = pa_usec_to_bytes(TSCHED_WATERMARK_STEP_USEC, &u->sink->sample_spec);
+ u->tsched_watermark = pa_usec_to_bytes_round_up(pa_bytes_to_usec_round_up(tsched_watermark, &requested_ss), &u->sink->sample_spec);
+
+ u->watermark_inc_step = pa_usec_to_bytes(TSCHED_WATERMARK_INC_STEP_USEC, &u->sink->sample_spec);
+ u->watermark_dec_step = pa_usec_to_bytes(TSCHED_WATERMARK_DEC_STEP_USEC, &u->sink->sample_spec);
+
+ u->watermark_inc_threshold = pa_usec_to_bytes_round_up(TSCHED_WATERMARK_INC_THRESHOLD_USEC, &u->sink->sample_spec);
+ u->watermark_dec_threshold = pa_usec_to_bytes_round_up(TSCHED_WATERMARK_DEC_THRESHOLD_USEC, &u->sink->sample_spec);
fix_min_sleep_wakeup(u);
fix_tsched_watermark(u);
@@ -1749,12 +2136,12 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
if (update_sw_params(u) < 0)
goto fail;
- if (setup_mixer(u, ignore_dB) < 0)
+ if (setup_mixer(u, ignore_dB, sync_volume) < 0)
goto fail;
pa_alsa_dump(PA_LOG_DEBUG, u->pcm_handle);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("alsa-sink", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
@@ -1778,6 +2165,9 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
pa_sink_put(u->sink);
+ if (profile_set)
+ pa_alsa_profile_set_free(profile_set);
+
return u->sink;
fail:
@@ -1785,6 +2175,9 @@ fail:
if (u)
userdata_free(u);
+ if (profile_set)
+ pa_alsa_profile_set_free(profile_set);
+
return NULL;
}
@@ -1807,29 +2200,39 @@ static void userdata_free(struct userdata *u) {
if (u->memchunk.memblock)
pa_memblock_unref(u->memchunk.memblock);
+ if (u->mixer_pd)
+ pa_alsa_mixer_pdata_free(u->mixer_pd);
+
if (u->alsa_rtpoll_item)
pa_rtpoll_item_free(u->alsa_rtpoll_item);
if (u->rtpoll)
pa_rtpoll_free(u->rtpoll);
+ if (u->pcm_handle) {
+ snd_pcm_drop(u->pcm_handle);
+ snd_pcm_close(u->pcm_handle);
+ }
+
if (u->mixer_fdl)
pa_alsa_fdlist_free(u->mixer_fdl);
+ if (u->mixer_path_set)
+ pa_alsa_path_set_free(u->mixer_path_set);
+ else if (u->mixer_path)
+ pa_alsa_path_free(u->mixer_path);
+
if (u->mixer_handle)
snd_mixer_close(u->mixer_handle);
- if (u->pcm_handle) {
- snd_pcm_drop(u->pcm_handle);
- snd_pcm_close(u->pcm_handle);
- }
-
if (u->smoother)
pa_smoother_free(u->smoother);
reserve_done(u);
+ monitor_done(u);
pa_xfree(u->device_name);
+ pa_xfree(u->control_device);
pa_xfree(u);
}
diff --git a/src/modules/alsa/alsa-sink.h b/src/modules/alsa/alsa-sink.h
index bbf64234..e640b624 100644
--- a/src/modules/alsa/alsa-sink.h
+++ b/src/modules/alsa/alsa-sink.h
@@ -29,7 +29,7 @@
#include "alsa-util.h"
-pa_sink* pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, const pa_alsa_profile_info *profile);
+pa_sink* pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, pa_alsa_mapping *mapping);
void pa_alsa_sink_free(pa_sink *s);
diff --git a/src/modules/alsa/alsa-source.c b/src/modules/alsa/alsa-source.c
index f1c18196..f847b1ee 100644
--- a/src/modules/alsa/alsa-source.c
+++ b/src/modules/alsa/alsa-source.c
@@ -28,31 +28,26 @@
#include <asoundlib.h>
-#ifdef HAVE_VALGRIND_MEMCHECK_H
-#include <valgrind/memcheck.h>
-#endif
-
-#include <pulse/xmalloc.h>
-#include <pulse/util.h>
-#include <pulse/timeval.h>
#include <pulse/i18n.h>
+#include <pulse/rtclock.h>
+#include <pulse/timeval.h>
+#include <pulse/volume.h>
+#include <pulse/xmalloc.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/core.h>
#include <pulsecore/module.h>
#include <pulsecore/memchunk.h>
#include <pulsecore/sink.h>
#include <pulsecore/modargs.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/sample-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/thread.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
#include <pulsecore/time-smoother.h>
-#include <pulsecore/rtclock.h>
#include <modules/reserve-wrap.h>
@@ -62,11 +57,27 @@
/* #define DEBUG_TIMING */
#define DEFAULT_DEVICE "default"
-#define DEFAULT_TSCHED_BUFFER_USEC (2*PA_USEC_PER_SEC) /* 2s */
-#define DEFAULT_TSCHED_WATERMARK_USEC (20*PA_USEC_PER_MSEC) /* 20ms */
-#define TSCHED_WATERMARK_STEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms */
-#define TSCHED_MIN_SLEEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms */
-#define TSCHED_MIN_WAKEUP_USEC (4*PA_USEC_PER_MSEC) /* 4ms */
+
+#define DEFAULT_TSCHED_BUFFER_USEC (2*PA_USEC_PER_SEC) /* 2s */
+#define DEFAULT_TSCHED_WATERMARK_USEC (20*PA_USEC_PER_MSEC) /* 20ms */
+
+#define TSCHED_WATERMARK_INC_STEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms */
+#define TSCHED_WATERMARK_DEC_STEP_USEC (5*PA_USEC_PER_MSEC) /* 5ms */
+#define TSCHED_WATERMARK_VERIFY_AFTER_USEC (20*PA_USEC_PER_SEC) /* 20s */
+#define TSCHED_WATERMARK_INC_THRESHOLD_USEC (0*PA_USEC_PER_MSEC) /* 0ms */
+#define TSCHED_WATERMARK_DEC_THRESHOLD_USEC (100*PA_USEC_PER_MSEC) /* 100ms */
+#define TSCHED_WATERMARK_STEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms */
+
+#define TSCHED_MIN_SLEEP_USEC (10*PA_USEC_PER_MSEC) /* 10ms */
+#define TSCHED_MIN_WAKEUP_USEC (4*PA_USEC_PER_MSEC) /* 4ms */
+
+#define SMOOTHER_WINDOW_USEC (10*PA_USEC_PER_SEC) /* 10s */
+#define SMOOTHER_ADJUST_USEC (1*PA_USEC_PER_SEC) /* 1s */
+
+#define SMOOTHER_MIN_INTERVAL (2*PA_USEC_PER_MSEC) /* 2ms */
+#define SMOOTHER_MAX_INTERVAL (200*PA_USEC_PER_MSEC) /* 200ms */
+
+#define VOLUME_ACCURACY (PA_VOLUME_NORM/100)
struct userdata {
pa_core *core;
@@ -80,12 +91,10 @@ struct userdata {
snd_pcm_t *pcm_handle;
pa_alsa_fdlist *mixer_fdl;
+ pa_alsa_mixer_pdata *mixer_pd;
snd_mixer_t *mixer_handle;
- snd_mixer_elem_t *mixer_elem;
- long hw_volume_max, hw_volume_min;
- long hw_dB_max, hw_dB_min;
- pa_bool_t hw_dB_supported:1;
- pa_bool_t mixer_seperate_channels:1;
+ pa_alsa_path_set *mixer_path_set;
+ pa_alsa_path *mixer_path;
pa_cvolume hardware_volume;
@@ -97,23 +106,33 @@ struct userdata {
hwbuf_unused,
min_sleep,
min_wakeup,
- watermark_step;
+ watermark_inc_step,
+ watermark_dec_step,
+ watermark_inc_threshold,
+ watermark_dec_threshold;
- unsigned nfragments;
+ pa_usec_t watermark_dec_not_before;
- char *device_name;
+ char *device_name; /* name of the PCM device */
+ char *control_device; /* name of the control device */
pa_bool_t use_mmap:1, use_tsched:1;
+ pa_bool_t first;
+
pa_rtpoll_item *alsa_rtpoll_item;
snd_mixer_selem_channel_id_t mixer_map[SND_MIXER_SCHN_LAST];
pa_smoother *smoother;
uint64_t read_count;
+ pa_usec_t smoother_interval;
+ pa_usec_t last_smoother_update;
pa_reserve_wrapper *reserve;
pa_hook_slot *reserve_slot;
+ pa_reserve_monitor_wrapper *monitor;
+ pa_hook_slot *monitor_slot;
};
static void userdata_free(struct userdata *u);
@@ -122,7 +141,7 @@ static pa_hook_result_t reserve_cb(pa_reserve_wrapper *r, void *forced, struct u
pa_assert(r);
pa_assert(u);
- if (pa_source_suspend(u->source, TRUE) < 0)
+ if (pa_source_suspend(u->source, TRUE, PA_SUSPEND_APPLICATION) < 0)
return PA_HOOK_CANCEL;
return PA_HOOK_OK;
@@ -165,10 +184,10 @@ static int reserve_init(struct userdata *u, const char *dname) {
if (pa_in_system_mode())
return 0;
- /* We are resuming, try to lock the device */
if (!(rname = pa_alsa_get_reserve_name(dname)))
return 0;
+ /* We are resuming, try to lock the device */
u->reserve = pa_reserve_wrapper_get(u->core, rname);
pa_xfree(rname);
@@ -183,9 +202,62 @@ static int reserve_init(struct userdata *u, const char *dname) {
return 0;
}
+static pa_hook_result_t monitor_cb(pa_reserve_monitor_wrapper *w, void* busy, struct userdata *u) {
+ pa_bool_t b;
+
+ pa_assert(w);
+ pa_assert(u);
+
+ b = PA_PTR_TO_UINT(busy) && !u->reserve;
+
+ pa_source_suspend(u->source, b, PA_SUSPEND_APPLICATION);
+ return PA_HOOK_OK;
+}
+
+static void monitor_done(struct userdata *u) {
+ pa_assert(u);
+
+ if (u->monitor_slot) {
+ pa_hook_slot_free(u->monitor_slot);
+ u->monitor_slot = NULL;
+ }
+
+ if (u->monitor) {
+ pa_reserve_monitor_wrapper_unref(u->monitor);
+ u->monitor = NULL;
+ }
+}
+
+static int reserve_monitor_init(struct userdata *u, const char *dname) {
+ char *rname;
+
+ pa_assert(u);
+ pa_assert(dname);
+
+ if (pa_in_system_mode())
+ return 0;
+
+ if (!(rname = pa_alsa_get_reserve_name(dname)))
+ return 0;
+
+ /* We are resuming, try to lock the device */
+ u->monitor = pa_reserve_monitor_wrapper_get(u->core, rname);
+ pa_xfree(rname);
+
+ if (!(u->monitor))
+ return -1;
+
+ pa_assert(!u->monitor_slot);
+ u->monitor_slot = pa_hook_connect(pa_reserve_monitor_wrapper_hook(u->monitor), PA_HOOK_NORMAL, (pa_hook_cb_t) monitor_cb, u);
+
+ return 0;
+}
+
static void fix_min_sleep_wakeup(struct userdata *u) {
size_t max_use, max_use_2;
+
pa_assert(u);
+ pa_assert(u->use_tsched);
max_use = u->hwbuf_size - u->hwbuf_unused;
max_use_2 = pa_frame_align(max_use/2, &u->source->sample_spec);
@@ -200,6 +272,7 @@ static void fix_min_sleep_wakeup(struct userdata *u) {
static void fix_tsched_watermark(struct userdata *u) {
size_t max_use;
pa_assert(u);
+ pa_assert(u->use_tsched);
max_use = u->hwbuf_size - u->hwbuf_unused;
@@ -210,7 +283,7 @@ static void fix_tsched_watermark(struct userdata *u) {
u->tsched_watermark = u->min_wakeup;
}
-static void adjust_after_overrun(struct userdata *u) {
+static void increase_watermark(struct userdata *u) {
size_t old_watermark;
pa_usec_t old_min_latency, new_min_latency;
@@ -219,36 +292,72 @@ static void adjust_after_overrun(struct userdata *u) {
/* First, just try to increase the watermark */
old_watermark = u->tsched_watermark;
- u->tsched_watermark = PA_MIN(u->tsched_watermark * 2, u->tsched_watermark + u->watermark_step);
-
+ u->tsched_watermark = PA_MIN(u->tsched_watermark * 2, u->tsched_watermark + u->watermark_inc_step);
fix_tsched_watermark(u);
if (old_watermark != u->tsched_watermark) {
- pa_log_notice("Increasing wakeup watermark to %0.2f ms",
- (double) pa_bytes_to_usec(u->tsched_watermark, &u->source->sample_spec) / PA_USEC_PER_MSEC);
+ pa_log_info("Increasing wakeup watermark to %0.2f ms",
+ (double) pa_bytes_to_usec(u->tsched_watermark, &u->source->sample_spec) / PA_USEC_PER_MSEC);
return;
}
/* Hmm, we cannot increase the watermark any further, hence let's raise the latency */
old_min_latency = u->source->thread_info.min_latency;
- new_min_latency = PA_MIN(old_min_latency * 2, old_min_latency + TSCHED_WATERMARK_STEP_USEC);
+ new_min_latency = PA_MIN(old_min_latency * 2, old_min_latency + TSCHED_WATERMARK_INC_STEP_USEC);
new_min_latency = PA_MIN(new_min_latency, u->source->thread_info.max_latency);
if (old_min_latency != new_min_latency) {
- pa_log_notice("Increasing minimal latency to %0.2f ms",
- (double) new_min_latency / PA_USEC_PER_MSEC);
+ pa_log_info("Increasing minimal latency to %0.2f ms",
+ (double) new_min_latency / PA_USEC_PER_MSEC);
pa_source_set_latency_range_within_thread(u->source, new_min_latency, u->source->thread_info.max_latency);
- return;
}
/* When we reach this we're officialy fucked! */
}
-static pa_usec_t hw_sleep_time(struct userdata *u, pa_usec_t *sleep_usec, pa_usec_t*process_usec) {
+static void decrease_watermark(struct userdata *u) {
+ size_t old_watermark;
+ pa_usec_t now;
+
+ pa_assert(u);
+ pa_assert(u->use_tsched);
+
+ now = pa_rtclock_now();
+
+ if (u->watermark_dec_not_before <= 0)
+ goto restart;
+
+ if (u->watermark_dec_not_before > now)
+ return;
+
+ old_watermark = u->tsched_watermark;
+
+ if (u->tsched_watermark < u->watermark_dec_step)
+ u->tsched_watermark = u->tsched_watermark / 2;
+ else
+ u->tsched_watermark = PA_MAX(u->tsched_watermark / 2, u->tsched_watermark - u->watermark_dec_step);
+
+ fix_tsched_watermark(u);
+
+ if (old_watermark != u->tsched_watermark)
+ pa_log_info("Decreasing wakeup watermark to %0.2f ms",
+ (double) pa_bytes_to_usec(u->tsched_watermark, &u->source->sample_spec) / PA_USEC_PER_MSEC);
+
+ /* We don't change the latency range*/
+
+restart:
+ u->watermark_dec_not_before = now + TSCHED_WATERMARK_VERIFY_AFTER_USEC;
+}
+
+static void hw_sleep_time(struct userdata *u, pa_usec_t *sleep_usec, pa_usec_t*process_usec) {
pa_usec_t wm, usec;
+ pa_assert(sleep_usec);
+ pa_assert(process_usec);
+
pa_assert(u);
+ pa_assert(u->use_tsched);
usec = pa_source_get_requested_latency_within_thread(u->source);
@@ -269,8 +378,6 @@ static pa_usec_t hw_sleep_time(struct userdata *u, pa_usec_t *sleep_usec, pa_use
(unsigned long) (*sleep_usec / PA_USEC_PER_MSEC),
(unsigned long) (*process_usec / PA_USEC_PER_MSEC));
#endif
-
- return usec;
}
static int try_recover(struct userdata *u, const char *call, int err) {
@@ -285,49 +392,72 @@ static int try_recover(struct userdata *u, const char *call, int err) {
if (err == -EPIPE)
pa_log_debug("%s: Buffer overrun!", call);
+ if (err == -ESTRPIPE)
+ pa_log_debug("%s: System suspended!", call);
+
if ((err = snd_pcm_recover(u->pcm_handle, err, 1)) < 0) {
pa_log("%s: %s", call, pa_alsa_strerror(err));
return -1;
}
- snd_pcm_start(u->pcm_handle);
+ u->first = TRUE;
return 0;
}
-static size_t check_left_to_record(struct userdata *u, size_t n_bytes) {
+static size_t check_left_to_record(struct userdata *u, size_t n_bytes, pa_bool_t on_timeout) {
size_t left_to_record;
size_t rec_space = u->hwbuf_size - u->hwbuf_unused;
+ pa_bool_t overrun = FALSE;
/* We use <= instead of < for this check here because an overrun
* only happens after the last sample was processed, not already when
* it is removed from the buffer. This is particularly important
* when block transfer is used. */
- if (n_bytes <= rec_space) {
+ if (n_bytes <= rec_space)
left_to_record = rec_space - n_bytes;
+ else {
-#ifdef DEBUG_TIMING
- pa_log_debug("%0.2f ms left to record", (double) pa_bytes_to_usec(left_to_record, &u->source->sample_spec) / PA_USEC_PER_MSEC);
-#endif
-
- } else {
+ /* We got a dropout. What a mess! */
left_to_record = 0;
+ overrun = TRUE;
#ifdef DEBUG_TIMING
PA_DEBUG_TRAP;
#endif
- if (pa_log_ratelimit())
+ if (pa_log_ratelimit(PA_LOG_INFO))
pa_log_info("Overrun!");
+ }
- if (u->use_tsched)
- adjust_after_overrun(u);
+#ifdef DEBUG_TIMING
+ pa_log_debug("%0.2f ms left to record", (double) pa_bytes_to_usec(left_to_record, &u->source->sample_spec) / PA_USEC_PER_MSEC);
+#endif
+
+ if (u->use_tsched) {
+ pa_bool_t reset_not_before = TRUE;
+
+ if (overrun || left_to_record < u->watermark_inc_threshold)
+ increase_watermark(u);
+ else if (left_to_record > u->watermark_dec_threshold) {
+ reset_not_before = FALSE;
+
+ /* We decrease the watermark only if have actually
+ * been woken up by a timeout. If something else woke
+ * us up it's too easy to fulfill the deadlines... */
+
+ if (on_timeout)
+ decrease_watermark(u);
+ }
+
+ if (reset_not_before)
+ u->watermark_dec_not_before = 0;
}
return left_to_record;
}
-static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled) {
+static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled, pa_bool_t on_timeout) {
pa_bool_t work_done = FALSE;
pa_usec_t max_sleep_usec = 0, process_usec = 0;
size_t left_to_record;
@@ -343,6 +473,7 @@ static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
snd_pcm_sframes_t n;
size_t n_bytes;
int r;
+ pa_bool_t after_avail = TRUE;
if (PA_UNLIKELY((n = pa_alsa_safe_avail(u->pcm_handle, u->hwbuf_size, &u->source->sample_spec)) < 0)) {
@@ -358,7 +489,8 @@ static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
pa_log_debug("avail: %lu", (unsigned long) n_bytes);
#endif
- left_to_record = check_left_to_record(u, n_bytes);
+ left_to_record = check_left_to_record(u, n_bytes, on_timeout);
+ on_timeout = FALSE;
if (u->use_tsched)
if (!polled &&
@@ -387,6 +519,7 @@ static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
break;
}
+
if (++j > 10) {
#ifdef DEBUG_TIMING
pa_log_debug("Not filling up, because already too many iterations.");
@@ -402,19 +535,21 @@ static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
#endif
for (;;) {
+ pa_memchunk chunk;
+ void *p;
int err;
const snd_pcm_channel_area_t *areas;
snd_pcm_uframes_t offset, frames;
- pa_memchunk chunk;
- void *p;
snd_pcm_sframes_t sframes;
frames = (snd_pcm_uframes_t) (n_bytes / u->frame_size);
-
/* pa_log_debug("%lu frames to read", (unsigned long) frames); */
if (PA_UNLIKELY((err = pa_alsa_safe_mmap_begin(u->pcm_handle, &areas, &offset, &frames, u->hwbuf_size, &u->source->sample_spec)) < 0)) {
+ if (!after_avail && err == -EAGAIN)
+ break;
+
if ((r = try_recover(u, "snd_pcm_mmap_begin", err)) == 0)
continue;
@@ -425,6 +560,12 @@ static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
if (frames > pa_mempool_block_size_max(u->source->core->mempool)/u->frame_size)
frames = pa_mempool_block_size_max(u->source->core->mempool)/u->frame_size;
+ if (!after_avail && frames == 0)
+ break;
+
+ pa_assert(frames > 0);
+ after_avail = FALSE;
+
/* Check these are multiples of 8 bit */
pa_assert((areas[0].first & 7) == 0);
pa_assert((areas[0].step & 7)== 0);
@@ -465,17 +606,19 @@ static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
}
}
- *sleep_usec = pa_bytes_to_usec(left_to_record, &u->source->sample_spec);
+ if (u->use_tsched) {
+ *sleep_usec = pa_bytes_to_usec(left_to_record, &u->source->sample_spec);
- if (*sleep_usec > process_usec)
- *sleep_usec -= process_usec;
- else
- *sleep_usec = 0;
+ if (*sleep_usec > process_usec)
+ *sleep_usec -= process_usec;
+ else
+ *sleep_usec = 0;
+ }
return work_done ? 1 : 0;
}
-static int unix_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled) {
+static int unix_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled, pa_bool_t on_timeout) {
int work_done = FALSE;
pa_usec_t max_sleep_usec = 0, process_usec = 0;
size_t left_to_record;
@@ -491,6 +634,7 @@ static int unix_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
snd_pcm_sframes_t n;
size_t n_bytes;
int r;
+ pa_bool_t after_avail = TRUE;
if (PA_UNLIKELY((n = pa_alsa_safe_avail(u->pcm_handle, u->hwbuf_size, &u->source->sample_spec)) < 0)) {
@@ -501,7 +645,8 @@ static int unix_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
}
n_bytes = (size_t) n * u->frame_size;
- left_to_record = check_left_to_record(u, n_bytes);
+ left_to_record = check_left_to_record(u, n_bytes, on_timeout);
+ on_timeout = FALSE;
if (u->use_tsched)
if (!polled &&
@@ -551,17 +696,26 @@ static int unix_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
frames = snd_pcm_readi(u->pcm_handle, (uint8_t*) p, (snd_pcm_uframes_t) frames);
pa_memblock_release(chunk.memblock);
- pa_assert(frames != 0);
-
if (PA_UNLIKELY(frames < 0)) {
pa_memblock_unref(chunk.memblock);
- if ((r = try_recover(u, "snd_pcm_readi", (int) (frames))) == 0)
+ if (!after_avail && (int) frames == -EAGAIN)
+ break;
+
+ if ((r = try_recover(u, "snd_pcm_readi", (int) frames)) == 0)
continue;
return r;
}
+ if (!after_avail && frames == 0) {
+ pa_memblock_unref(chunk.memblock);
+ break;
+ }
+
+ pa_assert(frames > 0);
+ after_avail = FALSE;
+
chunk.index = 0;
chunk.length = (size_t) frames * u->frame_size;
@@ -581,12 +735,14 @@ static int unix_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled
}
}
- *sleep_usec = pa_bytes_to_usec(left_to_record, &u->source->sample_spec);
+ if (u->use_tsched) {
+ *sleep_usec = pa_bytes_to_usec(left_to_record, &u->source->sample_spec);
- if (*sleep_usec > process_usec)
- *sleep_usec -= process_usec;
- else
- *sleep_usec = 0;
+ if (*sleep_usec > process_usec)
+ *sleep_usec -= process_usec;
+ else
+ *sleep_usec = 0;
+ }
return work_done ? 1 : 0;
}
@@ -605,7 +761,7 @@ static void update_smoother(struct userdata *u) {
/* Let's update the time smoother */
- if (PA_UNLIKELY((err = pa_alsa_safe_delay(u->pcm_handle, &delay, u->hwbuf_size, &u->source->sample_spec)) < 0)) {
+ if (PA_UNLIKELY((err = pa_alsa_safe_delay(u->pcm_handle, &delay, u->hwbuf_size, &u->source->sample_spec, TRUE)) < 0)) {
pa_log_warn("Failed to get delay: %s", pa_alsa_strerror(err));
return;
}
@@ -618,24 +774,32 @@ static void update_smoother(struct userdata *u) {
now1 = pa_timespec_load(&htstamp);
}
- position = u->read_count + ((uint64_t) delay * (uint64_t) u->frame_size);
-
/* Hmm, if the timestamp is 0, then it wasn't set and we take the current time */
if (now1 <= 0)
- now1 = pa_rtclock_usec();
+ now1 = pa_rtclock_now();
+ /* check if the time since the last update is bigger than the interval */
+ if (u->last_smoother_update > 0)
+ if (u->last_smoother_update + u->smoother_interval > now1)
+ return;
+
+ position = u->read_count + ((uint64_t) delay * (uint64_t) u->frame_size);
now2 = pa_bytes_to_usec(position, &u->source->sample_spec);
pa_smoother_put(u->smoother, now1, now2);
+
+ u->last_smoother_update = now1;
+ /* exponentially increase the update interval up to the MAX limit */
+ u->smoother_interval = PA_MIN (u->smoother_interval * 2, SMOOTHER_MAX_INTERVAL);
}
static pa_usec_t source_get_latency(struct userdata *u) {
- int64_t delay;
+ int64_t delay;
pa_usec_t now1, now2;
pa_assert(u);
- now1 = pa_rtclock_usec();
+ now1 = pa_rtclock_now();
now2 = pa_smoother_get(u->smoother, now1);
delay = (int64_t) now2 - (int64_t) pa_bytes_to_usec(u->read_count, &u->source->sample_spec);
@@ -656,11 +820,12 @@ static int build_pollfd(struct userdata *u) {
return 0;
}
+/* Called from IO context */
static int suspend(struct userdata *u) {
pa_assert(u);
pa_assert(u->pcm_handle);
- pa_smoother_pause(u->smoother, pa_rtclock_usec());
+ pa_smoother_pause(u->smoother, pa_rtclock_now());
/* Let's suspend */
snd_pcm_close(u->pcm_handle);
@@ -676,6 +841,7 @@ static int suspend(struct userdata *u) {
return 0;
}
+/* Called from IO context */
static int update_sw_params(struct userdata *u) {
snd_pcm_uframes_t avail_min;
int err;
@@ -720,7 +886,7 @@ static int update_sw_params(struct userdata *u) {
pa_log_debug("setting avail_min=%lu", (unsigned long) avail_min);
- if ((err = pa_alsa_set_sw_params(u->pcm_handle, avail_min)) < 0) {
+ if ((err = pa_alsa_set_sw_params(u->pcm_handle, avail_min, !u->use_tsched)) < 0) {
pa_log("Failed to set software parameters: %s", pa_alsa_strerror(err));
return err;
}
@@ -728,22 +894,20 @@ static int update_sw_params(struct userdata *u) {
return 0;
}
+/* Called from IO context */
static int unsuspend(struct userdata *u) {
pa_sample_spec ss;
int err;
pa_bool_t b, d;
- unsigned nfrags;
- snd_pcm_uframes_t period_size;
+ snd_pcm_uframes_t period_size, buffer_size;
pa_assert(u);
pa_assert(!u->pcm_handle);
pa_log_info("Trying resume...");
- snd_config_update_free_global();
-
if ((err = snd_pcm_open(&u->pcm_handle, u->device_name, SND_PCM_STREAM_CAPTURE,
- /*SND_PCM_NONBLOCK|*/
+ SND_PCM_NONBLOCK|
SND_PCM_NO_AUTO_RESAMPLE|
SND_PCM_NO_AUTO_CHANNELS|
SND_PCM_NO_AUTO_FORMAT)) < 0) {
@@ -752,12 +916,12 @@ static int unsuspend(struct userdata *u) {
}
ss = u->source->sample_spec;
- nfrags = u->nfragments;
period_size = u->fragment_size / u->frame_size;
+ buffer_size = u->hwbuf_size / u->frame_size;
b = u->use_mmap;
d = u->use_tsched;
- if ((err = pa_alsa_set_hw_params(u->pcm_handle, &ss, &nfrags, &period_size, u->hwbuf_size / u->frame_size, &b, &d, TRUE)) < 0) {
+ if ((err = pa_alsa_set_hw_params(u->pcm_handle, &ss, &period_size, &buffer_size, 0, &b, &d, TRUE)) < 0) {
pa_log("Failed to set hardware parameters: %s", pa_alsa_strerror(err));
goto fail;
}
@@ -772,10 +936,11 @@ static int unsuspend(struct userdata *u) {
goto fail;
}
- if (nfrags != u->nfragments || period_size*u->frame_size != u->fragment_size) {
- pa_log_warn("Resume failed, couldn't restore original fragment settings. (Old: %lu*%lu, New %lu*%lu)",
- (unsigned long) u->nfragments, (unsigned long) u->fragment_size,
- (unsigned long) nfrags, period_size * u->frame_size);
+ if (period_size*u->frame_size != u->fragment_size ||
+ buffer_size*u->frame_size != u->hwbuf_size) {
+ pa_log_warn("Resume failed, couldn't restore original fragment settings. (Old: %lu/%lu, New %lu/%lu)",
+ (unsigned long) u->hwbuf_size, (unsigned long) u->fragment_size,
+ (unsigned long) (buffer_size*u->frame_size), (unsigned long) (period_size*u->frame_size));
goto fail;
}
@@ -787,8 +952,12 @@ static int unsuspend(struct userdata *u) {
/* FIXME: We need to reload the volume somehow */
- snd_pcm_start(u->pcm_handle);
- pa_smoother_resume(u->smoother, pa_rtclock_usec(), TRUE);
+ u->read_count = 0;
+ pa_smoother_reset(u->smoother, pa_rtclock_now(), TRUE);
+ u->smoother_interval = SMOOTHER_MIN_INTERVAL;
+ u->last_smoother_update = 0;
+
+ u->first = TRUE;
pa_log_info("Resumed successfully...");
@@ -800,9 +969,10 @@ fail:
u->pcm_handle = NULL;
}
- return -1;
+ return -PA_ERR_IO;
}
+/* Called from IO context */
static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
struct userdata *u = PA_SOURCE(o)->userdata;
@@ -823,30 +993,33 @@ static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t off
switch ((pa_source_state_t) PA_PTR_TO_UINT(data)) {
- case PA_SOURCE_SUSPENDED:
+ case PA_SOURCE_SUSPENDED: {
+ int r;
+
pa_assert(PA_SOURCE_IS_OPENED(u->source->thread_info.state));
- if (suspend(u) < 0)
- return -1;
+ if ((r = suspend(u)) < 0)
+ return r;
break;
+ }
case PA_SOURCE_IDLE:
- case PA_SOURCE_RUNNING:
+ case PA_SOURCE_RUNNING: {
+ int r;
if (u->source->thread_info.state == PA_SOURCE_INIT) {
if (build_pollfd(u) < 0)
- return -1;
-
- snd_pcm_start(u->pcm_handle);
+ return -PA_ERR_IO;
}
if (u->source->thread_info.state == PA_SOURCE_SUSPENDED) {
- if (unsuspend(u) < 0)
- return -1;
+ if ((r = unsuspend(u)) < 0)
+ return r;
}
break;
+ }
case PA_SOURCE_UNLINKED:
case PA_SOURCE_INIT:
@@ -870,16 +1043,16 @@ static int source_set_state_cb(pa_source *s, pa_source_state_t new_state) {
old_state = pa_source_get_state(u->source);
- if (PA_SINK_IS_OPENED(old_state) && new_state == PA_SINK_SUSPENDED)
+ if (PA_SOURCE_IS_OPENED(old_state) && new_state == PA_SOURCE_SUSPENDED)
reserve_done(u);
- else if (old_state == PA_SINK_SUSPENDED && PA_SINK_IS_OPENED(new_state))
+ else if (old_state == PA_SOURCE_SUSPENDED && PA_SOURCE_IS_OPENED(new_state))
if (reserve_init(u, u->device_name) < 0)
- return -1;
+ return -PA_ERR_BUSY;
return 0;
}
-static int mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
+static int ctl_mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
struct userdata *u = snd_mixer_elem_get_callback_private(elem);
pa_assert(u);
@@ -888,6 +1061,9 @@ static int mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
if (mask == SND_CTL_EVENT_MASK_REMOVE)
return 0;
+ if (u->source->suspend_cause & PA_SUSPEND_SESSION)
+ return 0;
+
if (mask & SND_CTL_EVENT_MASK_VALUE) {
pa_source_get_volume(u->source, TRUE);
pa_source_get_mute(u->source, TRUE);
@@ -896,244 +1072,221 @@ static int mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
return 0;
}
-static pa_volume_t from_alsa_volume(struct userdata *u, long alsa_vol) {
+static int io_mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
+ struct userdata *u = snd_mixer_elem_get_callback_private(elem);
- return (pa_volume_t) round(((double) (alsa_vol - u->hw_volume_min) * PA_VOLUME_NORM) /
- (double) (u->hw_volume_max - u->hw_volume_min));
-}
+ pa_assert(u);
+ pa_assert(u->mixer_handle);
-static long to_alsa_volume(struct userdata *u, pa_volume_t vol) {
- long alsa_vol;
+ if (mask == SND_CTL_EVENT_MASK_REMOVE)
+ return 0;
- alsa_vol = (long) round(((double) vol * (double) (u->hw_volume_max - u->hw_volume_min))
- / PA_VOLUME_NORM) + u->hw_volume_min;
+ if (u->source->suspend_cause & PA_SUSPEND_SESSION)
+ return 0;
+
+ if (mask & SND_CTL_EVENT_MASK_VALUE)
+ pa_source_update_volume_and_mute(u->source);
- return PA_CLAMP_UNLIKELY(alsa_vol, u->hw_volume_min, u->hw_volume_max);
+ return 0;
}
static void source_get_volume_cb(pa_source *s) {
struct userdata *u = s->userdata;
- int err;
- unsigned i;
pa_cvolume r;
- char t[PA_CVOLUME_SNPRINT_MAX];
+ char vol_str_pcnt[PA_CVOLUME_SNPRINT_MAX];
pa_assert(u);
- pa_assert(u->mixer_elem);
-
- if (u->mixer_seperate_channels) {
-
- r.channels = s->sample_spec.channels;
-
- for (i = 0; i < s->sample_spec.channels; i++) {
- long alsa_vol;
-
- if (u->hw_dB_supported) {
-
- if ((err = snd_mixer_selem_get_capture_dB(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
-
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
-
- r.values[i] = pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0);
- } else {
-
- if ((err = snd_mixer_selem_get_capture_volume(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
-
- r.values[i] = from_alsa_volume(u, alsa_vol);
- }
- }
-
- } else {
- long alsa_vol;
-
- if (u->hw_dB_supported) {
-
- if ((err = snd_mixer_selem_get_capture_dB(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
+ if (pa_alsa_path_get_volume(u->mixer_path, u->mixer_handle, &s->channel_map, &r) < 0)
+ return;
- pa_cvolume_set(&r, s->sample_spec.channels, pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0));
+ /* Shift down by the base volume, so that 0dB becomes maximum volume */
+ pa_sw_cvolume_multiply_scalar(&r, &r, s->base_volume);
- } else {
+ pa_log_debug("Read hardware volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &r));
- if ((err = snd_mixer_selem_get_capture_volume(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
+ if (u->mixer_path->has_dB) {
+ char vol_str_db[PA_SW_CVOLUME_SNPRINT_DB_MAX];
- pa_cvolume_set(&r, s->sample_spec.channels, from_alsa_volume(u, alsa_vol));
- }
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &r));
}
- pa_log_debug("Read hardware volume: %s", pa_cvolume_snprint(t, sizeof(t), &r));
-
- if (!pa_cvolume_equal(&u->hardware_volume, &r)) {
-
- s->virtual_volume = u->hardware_volume = r;
-
- if (u->hw_dB_supported) {
- pa_cvolume reset;
-
- /* Hmm, so the hardware volume changed, let's reset our software volume */
- pa_cvolume_reset(&reset, s->sample_spec.channels);
- pa_source_set_soft_volume(s, &reset);
- }
- }
+ if (pa_cvolume_equal(&u->hardware_volume, &r))
+ return;
- return;
+ s->real_volume = u->hardware_volume = r;
-fail:
- pa_log_error("Unable to read volume: %s", pa_alsa_strerror(err));
+ /* Hmm, so the hardware volume changed, let's reset our software volume */
+ if (u->mixer_path->has_dB)
+ pa_source_set_soft_volume(s, NULL);
}
static void source_set_volume_cb(pa_source *s) {
struct userdata *u = s->userdata;
- int err;
- unsigned i;
pa_cvolume r;
+ char vol_str_pcnt[PA_CVOLUME_SNPRINT_MAX];
+ pa_bool_t sync_volume = !!(s->flags & PA_SOURCE_SYNC_VOLUME);
pa_assert(u);
- pa_assert(u->mixer_elem);
-
- if (u->mixer_seperate_channels) {
-
- r.channels = s->sample_spec.channels;
-
- for (i = 0; i < s->sample_spec.channels; i++) {
- long alsa_vol;
- pa_volume_t vol;
-
- vol = s->virtual_volume.values[i];
-
- if (u->hw_dB_supported) {
-
- alsa_vol = (long) (pa_sw_volume_to_dB(vol) * 100);
- alsa_vol += u->hw_dB_max;
- alsa_vol = PA_CLAMP_UNLIKELY(alsa_vol, u->hw_dB_min, u->hw_dB_max);
-
- if ((err = snd_mixer_selem_set_capture_dB(u->mixer_elem, u->mixer_map[i], alsa_vol, 1)) < 0)
- goto fail;
-
- if ((err = snd_mixer_selem_get_capture_dB(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
+ /* Shift up by the base volume */
+ pa_sw_cvolume_divide_scalar(&r, &s->real_volume, s->base_volume);
- r.values[i] = pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0);
+ if (pa_alsa_path_set_volume(u->mixer_path, u->mixer_handle, &s->channel_map, &r, sync_volume, !sync_volume) < 0)
+ return;
- } else {
- alsa_vol = to_alsa_volume(u, vol);
+ /* Shift down by the base volume, so that 0dB becomes maximum volume */
+ pa_sw_cvolume_multiply_scalar(&r, &r, s->base_volume);
- if ((err = snd_mixer_selem_set_capture_volume(u->mixer_elem, u->mixer_map[i], alsa_vol)) < 0)
- goto fail;
+ u->hardware_volume = r;
- if ((err = snd_mixer_selem_get_capture_volume(u->mixer_elem, u->mixer_map[i], &alsa_vol)) < 0)
- goto fail;
+ if (u->mixer_path->has_dB) {
+ pa_cvolume new_soft_volume;
+ pa_bool_t accurate_enough;
+ char vol_str_db[PA_SW_CVOLUME_SNPRINT_DB_MAX];
- r.values[i] = from_alsa_volume(u, alsa_vol);
- }
- }
+ /* Match exactly what the user requested by software */
+ pa_sw_cvolume_divide(&new_soft_volume, &s->real_volume, &u->hardware_volume);
+
+ /* If the adjustment to do in software is only minimal we
+ * can skip it. That saves us CPU at the expense of a bit of
+ * accuracy */
+ accurate_enough =
+ (pa_cvolume_min(&new_soft_volume) >= (PA_VOLUME_NORM - VOLUME_ACCURACY)) &&
+ (pa_cvolume_max(&new_soft_volume) <= (PA_VOLUME_NORM + VOLUME_ACCURACY));
+
+ pa_log_debug("Requested volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &s->real_volume));
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &s->real_volume));
+ pa_log_debug("Got hardware volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &u->hardware_volume));
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &u->hardware_volume));
+ pa_log_debug("Calculated software volume: %s (accurate-enough=%s)",
+ pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &new_soft_volume),
+ pa_yes_no(accurate_enough));
+ pa_log_debug(" in dB: %s", pa_sw_cvolume_snprint_dB(vol_str_db, sizeof(vol_str_db), &new_soft_volume));
+
+ if (!accurate_enough)
+ s->soft_volume = new_soft_volume;
} else {
- pa_volume_t vol;
- long alsa_vol;
-
- vol = pa_cvolume_max(&s->virtual_volume);
-
- if (u->hw_dB_supported) {
- alsa_vol = (long) (pa_sw_volume_to_dB(vol) * 100);
- alsa_vol += u->hw_dB_max;
- alsa_vol = PA_CLAMP_UNLIKELY(alsa_vol, u->hw_dB_min, u->hw_dB_max);
+ pa_log_debug("Wrote hardware volume: %s", pa_cvolume_snprint(vol_str_pcnt, sizeof(vol_str_pcnt), &r));
- if ((err = snd_mixer_selem_set_capture_dB_all(u->mixer_elem, alsa_vol, 1)) < 0)
- goto fail;
-
- if ((err = snd_mixer_selem_get_capture_dB(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
-
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&alsa_vol, sizeof(alsa_vol));
-#endif
+ /* We can't match exactly what the user requested, hence let's
+ * at least tell the user about it */
- pa_cvolume_set(&r, s->sample_spec.channels, pa_sw_volume_from_dB((double) (alsa_vol - u->hw_dB_max) / 100.0));
+ s->real_volume = r;
+ }
+}
- } else {
- alsa_vol = to_alsa_volume(u, vol);
+static void source_write_volume_cb(pa_source *s) {
+ struct userdata *u = s->userdata;
+ pa_cvolume hw_vol = s->thread_info.current_hw_volume;
- if ((err = snd_mixer_selem_set_capture_volume_all(u->mixer_elem, alsa_vol)) < 0)
- goto fail;
+ pa_assert(u);
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
+ pa_assert(s->flags & PA_SOURCE_SYNC_VOLUME);
- if ((err = snd_mixer_selem_get_capture_volume(u->mixer_elem, SND_MIXER_SCHN_MONO, &alsa_vol)) < 0)
- goto fail;
+ /* Shift up by the base volume */
+ pa_sw_cvolume_divide_scalar(&hw_vol, &hw_vol, s->base_volume);
- pa_cvolume_set(&r, s->sample_spec.channels, from_alsa_volume(u, alsa_vol));
+ if (pa_alsa_path_set_volume(u->mixer_path, u->mixer_handle, &s->channel_map, &hw_vol, TRUE, TRUE) < 0)
+ pa_log_error("Writing HW volume failed");
+ else {
+ pa_cvolume tmp_vol;
+ pa_bool_t accurate_enough;
+
+ /* Shift down by the base volume, so that 0dB becomes maximum volume */
+ pa_sw_cvolume_multiply_scalar(&hw_vol, &hw_vol, s->base_volume);
+
+ pa_sw_cvolume_divide(&tmp_vol, &hw_vol, &s->thread_info.current_hw_volume);
+ accurate_enough =
+ (pa_cvolume_min(&tmp_vol) >= (PA_VOLUME_NORM - VOLUME_ACCURACY)) &&
+ (pa_cvolume_max(&tmp_vol) <= (PA_VOLUME_NORM + VOLUME_ACCURACY));
+
+ if (!accurate_enough) {
+ union {
+ char db[2][PA_SW_CVOLUME_SNPRINT_DB_MAX];
+ char pcnt[2][PA_CVOLUME_SNPRINT_MAX];
+ } vol;
+
+ pa_log_debug("Written HW volume did not match with the request: %s (request) != %s",
+ pa_cvolume_snprint(vol.pcnt[0], sizeof(vol.pcnt[0]), &s->thread_info.current_hw_volume),
+ pa_cvolume_snprint(vol.pcnt[1], sizeof(vol.pcnt[1]), &hw_vol));
+ pa_log_debug(" in dB: %s (request) != %s",
+ pa_sw_cvolume_snprint_dB(vol.db[0], sizeof(vol.db[0]), &s->thread_info.current_hw_volume),
+ pa_sw_cvolume_snprint_dB(vol.db[1], sizeof(vol.db[1]), &hw_vol));
}
}
-
- u->hardware_volume = r;
-
- if (u->hw_dB_supported) {
- char t[PA_CVOLUME_SNPRINT_MAX];
-
- /* Match exactly what the user requested by software */
-
- pa_sw_cvolume_divide(&s->soft_volume, &s->virtual_volume, &u->hardware_volume);
-
- pa_log_debug("Requested volume: %s", pa_cvolume_snprint(t, sizeof(t), &s->virtual_volume));
- pa_log_debug("Got hardware volume: %s", pa_cvolume_snprint(t, sizeof(t), &u->hardware_volume));
- pa_log_debug("Calculated software volume: %s", pa_cvolume_snprint(t, sizeof(t), &s->soft_volume));
-
- } else
-
- /* We can't match exactly what the user requested, hence let's
- * at least tell the user about it */
-
- s->virtual_volume = r;
-
- return;
-
-fail:
- pa_log_error("Unable to set volume: %s", pa_alsa_strerror(err));
}
static void source_get_mute_cb(pa_source *s) {
struct userdata *u = s->userdata;
- int err, sw;
+ pa_bool_t b;
pa_assert(u);
- pa_assert(u->mixer_elem);
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
- if ((err = snd_mixer_selem_get_capture_switch(u->mixer_elem, 0, &sw)) < 0) {
- pa_log_error("Unable to get switch: %s", pa_alsa_strerror(err));
+ if (pa_alsa_path_get_mute(u->mixer_path, u->mixer_handle, &b) < 0)
return;
- }
- s->muted = !sw;
+ s->muted = b;
}
static void source_set_mute_cb(pa_source *s) {
struct userdata *u = s->userdata;
- int err;
pa_assert(u);
- pa_assert(u->mixer_elem);
+ pa_assert(u->mixer_path);
+ pa_assert(u->mixer_handle);
- if ((err = snd_mixer_selem_set_capture_switch_all(u->mixer_elem, !s->muted)) < 0) {
- pa_log_error("Unable to set switch: %s", pa_alsa_strerror(err));
- return;
+ pa_alsa_path_set_mute(u->mixer_path, u->mixer_handle, s->muted);
+}
+
+static int source_set_port_cb(pa_source *s, pa_device_port *p) {
+ struct userdata *u = s->userdata;
+ pa_alsa_port_data *data;
+
+ pa_assert(u);
+ pa_assert(p);
+ pa_assert(u->mixer_handle);
+
+ data = PA_DEVICE_PORT_DATA(p);
+
+ pa_assert_se(u->mixer_path = data->path);
+ pa_alsa_path_select(u->mixer_path, u->mixer_handle);
+
+ if (u->mixer_path->has_volume && u->mixer_path->has_dB) {
+ s->base_volume = pa_sw_volume_from_dB(-u->mixer_path->max_dB);
+ s->n_volume_steps = PA_VOLUME_NORM+1;
+
+ pa_log_info("Fixing base volume to %0.2f dB", pa_sw_volume_to_dB(s->base_volume));
+ } else {
+ s->base_volume = PA_VOLUME_NORM;
+ s->n_volume_steps = u->mixer_path->max_volume - u->mixer_path->min_volume + 1;
}
+
+ if (data->setting)
+ pa_alsa_setting_select(data->setting, u->mixer_handle);
+
+ if (s->set_mute)
+ s->set_mute(s);
+ if (s->set_volume)
+ s->set_volume(s);
+
+ return 0;
}
static void source_update_requested_latency_cb(pa_source *s) {
struct userdata *u = s->userdata;
pa_assert(u);
+ pa_assert(u->use_tsched); /* only when timer scheduling is used
+ * we can dynamically adjust the
+ * latency */
if (!u->pcm_handle)
return;
@@ -1153,10 +1306,10 @@ static void thread_func(void *userdata) {
pa_make_realtime(u->core->realtime_priority);
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
int ret;
+ pa_usec_t rtpoll_sleep = 0;
#ifdef DEBUG_TIMING
pa_log_debug("Loop");
@@ -1166,11 +1319,21 @@ static void thread_func(void *userdata) {
if (PA_SOURCE_IS_OPENED(u->source->thread_info.state)) {
int work_done;
pa_usec_t sleep_usec = 0;
+ pa_bool_t on_timeout = pa_rtpoll_timer_elapsed(u->rtpoll);
+
+ if (u->first) {
+ pa_log_info("Starting capture.");
+ snd_pcm_start(u->pcm_handle);
+
+ pa_smoother_resume(u->smoother, pa_rtclock_now(), TRUE);
+
+ u->first = FALSE;
+ }
if (u->use_mmap)
- work_done = mmap_read(u, &sleep_usec, revents & POLLIN);
+ work_done = mmap_read(u, &sleep_usec, revents & POLLIN, on_timeout);
else
- work_done = unix_read(u, &sleep_usec, revents & POLLIN);
+ work_done = unix_read(u, &sleep_usec, revents & POLLIN, on_timeout);
if (work_done < 0)
goto fail;
@@ -1190,22 +1353,34 @@ static void thread_func(void *userdata) {
/* Convert from the sound card time domain to the
* system time domain */
- cusec = pa_smoother_translate(u->smoother, pa_rtclock_usec(), sleep_usec);
+ cusec = pa_smoother_translate(u->smoother, pa_rtclock_now(), sleep_usec);
/* pa_log_debug("Waking up in %0.2fms (system clock).", (double) cusec / PA_USEC_PER_MSEC); */
/* We don't trust the conversion, so we wake up whatever comes first */
- pa_rtpoll_set_timer_relative(u->rtpoll, PA_MIN(sleep_usec, cusec));
+ rtpoll_sleep = PA_MIN(sleep_usec, cusec);
}
- } else if (u->use_tsched)
+ }
- /* OK, we're in an invalid state, let's disable our timers */
+ if (u->source->flags & PA_SOURCE_SYNC_VOLUME) {
+ pa_usec_t volume_sleep;
+ pa_source_volume_change_apply(u->source, &volume_sleep);
+ if (volume_sleep > 0)
+ rtpoll_sleep = PA_MIN(volume_sleep, rtpoll_sleep);
+ }
+
+ if (rtpoll_sleep > 0)
+ pa_rtpoll_set_timer_relative(u->rtpoll, rtpoll_sleep);
+ else
pa_rtpoll_set_timer_disabled(u->rtpoll);
/* Hmm, nothing to do. Let's sleep */
if ((ret = pa_rtpoll_run(u->rtpoll, TRUE)) < 0)
goto fail;
+ if (u->source->flags & PA_SOURCE_SYNC_VOLUME)
+ pa_source_volume_change_apply(u->source, NULL);
+
if (ret == 0)
goto finish;
@@ -1226,8 +1401,8 @@ static void thread_func(void *userdata) {
if (pa_alsa_recover_from_poll(u->pcm_handle, revents) < 0)
goto fail;
- snd_pcm_start(u->pcm_handle);
- } else if (revents && u->use_tsched && pa_log_ratelimit())
+ u->first = TRUE;
+ } else if (revents && u->use_tsched && pa_log_ratelimit(PA_LOG_DEBUG))
pa_log_debug("Wakeup from ALSA!");
} else
@@ -1244,7 +1419,7 @@ finish:
pa_log_debug("Thread shutting down");
}
-static void set_source_name(pa_source_new_data *data, pa_modargs *ma, const char *device_id, const char *device_name) {
+static void set_source_name(pa_source_new_data *data, pa_modargs *ma, const char *device_id, const char *device_name, pa_alsa_mapping *mapping) {
const char *n;
char *t;
@@ -1265,108 +1440,184 @@ static void set_source_name(pa_source_new_data *data, pa_modargs *ma, const char
data->namereg_fail = FALSE;
}
- t = pa_sprintf_malloc("alsa_input.%s", n);
+ if (mapping)
+ t = pa_sprintf_malloc("alsa_input.%s.%s", n, mapping->name);
+ else
+ t = pa_sprintf_malloc("alsa_input.%s", n);
+
pa_source_new_data_set_name(data, t);
pa_xfree(t);
}
-static int setup_mixer(struct userdata *u, pa_bool_t ignore_dB) {
+static void find_mixer(struct userdata *u, pa_alsa_mapping *mapping, const char *element, pa_bool_t ignore_dB) {
+
+ if (!mapping && !element)
+ return;
+
+ if (!(u->mixer_handle = pa_alsa_open_mixer_for_pcm(u->pcm_handle, &u->control_device))) {
+ pa_log_info("Failed to find a working mixer device.");
+ return;
+ }
+
+ if (element) {
+
+ if (!(u->mixer_path = pa_alsa_path_synthesize(element, PA_ALSA_DIRECTION_INPUT)))
+ goto fail;
+
+ if (pa_alsa_path_probe(u->mixer_path, u->mixer_handle, ignore_dB) < 0)
+ goto fail;
+
+ pa_log_debug("Probed mixer path %s:", u->mixer_path->name);
+ pa_alsa_path_dump(u->mixer_path);
+ } else {
+
+ if (!(u->mixer_path_set = pa_alsa_path_set_new(mapping, PA_ALSA_DIRECTION_INPUT)))
+ goto fail;
+
+ pa_alsa_path_set_probe(u->mixer_path_set, u->mixer_handle, ignore_dB);
+
+ pa_log_debug("Probed mixer paths:");
+ pa_alsa_path_set_dump(u->mixer_path_set);
+ }
+
+ return;
+
+fail:
+
+ if (u->mixer_path_set) {
+ pa_alsa_path_set_free(u->mixer_path_set);
+ u->mixer_path_set = NULL;
+ } else if (u->mixer_path) {
+ pa_alsa_path_free(u->mixer_path);
+ u->mixer_path = NULL;
+ }
+
+ if (u->mixer_handle) {
+ snd_mixer_close(u->mixer_handle);
+ u->mixer_handle = NULL;
+ }
+}
+
+static int setup_mixer(struct userdata *u, pa_bool_t ignore_dB, pa_bool_t sync_volume) {
pa_assert(u);
if (!u->mixer_handle)
return 0;
- pa_assert(u->mixer_elem);
+ if (u->source->active_port) {
+ pa_alsa_port_data *data;
- if (snd_mixer_selem_has_capture_volume(u->mixer_elem)) {
- pa_bool_t suitable = FALSE;
+ /* We have a list of supported paths, so let's activate the
+ * one that has been chosen as active */
- if (snd_mixer_selem_get_capture_volume_range(u->mixer_elem, &u->hw_volume_min, &u->hw_volume_max) < 0)
- pa_log_info("Failed to get volume range. Falling back to software volume control.");
- else if (u->hw_volume_min >= u->hw_volume_max)
- pa_log_warn("Your kernel driver is broken: it reports a volume range from %li to %li which makes no sense.", u->hw_volume_min, u->hw_volume_max);
- else {
- pa_log_info("Volume ranges from %li to %li.", u->hw_volume_min, u->hw_volume_max);
- suitable = TRUE;
- }
+ data = PA_DEVICE_PORT_DATA(u->source->active_port);
+ u->mixer_path = data->path;
- if (suitable) {
- if (ignore_dB || snd_mixer_selem_get_capture_dB_range(u->mixer_elem, &u->hw_dB_min, &u->hw_dB_max) < 0)
- pa_log_info("Mixer doesn't support dB information or data is ignored.");
- else {
-#ifdef HAVE_VALGRIND_MEMCHECK_H
- VALGRIND_MAKE_MEM_DEFINED(&u->hw_dB_min, sizeof(u->hw_dB_min));
- VALGRIND_MAKE_MEM_DEFINED(&u->hw_dB_max, sizeof(u->hw_dB_max));
-#endif
+ pa_alsa_path_select(data->path, u->mixer_handle);
- if (u->hw_dB_min >= u->hw_dB_max)
- pa_log_warn("Your kernel driver is broken: it reports a volume range from %0.2f dB to %0.2f dB which makes no sense.", (double) u->hw_dB_min/100.0, (double) u->hw_dB_max/100.0);
- else {
- pa_log_info("Volume ranges from %0.2f dB to %0.2f dB.", (double) u->hw_dB_min/100.0, (double) u->hw_dB_max/100.0);
- u->hw_dB_supported = TRUE;
-
- if (u->hw_dB_max > 0) {
- u->source->base_volume = pa_sw_volume_from_dB(- (double) u->hw_dB_max/100.0);
- pa_log_info("Fixing base volume to %0.2f dB", pa_sw_volume_to_dB(u->source->base_volume));
- } else
- pa_log_info("No particular base volume set, fixing to 0 dB");
- }
- }
+ if (data->setting)
+ pa_alsa_setting_select(data->setting, u->mixer_handle);
- if (!u->hw_dB_supported &&
- u->hw_volume_max - u->hw_volume_min < 3) {
+ } else {
- pa_log_info("Device has less than 4 volume levels. Falling back to software volume control.");
- suitable = FALSE;
- }
- }
+ if (!u->mixer_path && u->mixer_path_set)
+ u->mixer_path = u->mixer_path_set->paths;
- if (suitable) {
- u->mixer_seperate_channels = pa_alsa_calc_mixer_map(u->mixer_elem, &u->source->channel_map, u->mixer_map, FALSE) >= 0;
+ if (u->mixer_path) {
+ /* Hmm, we have only a single path, then let's activate it */
- u->source->get_volume = source_get_volume_cb;
- u->source->set_volume = source_set_volume_cb;
- u->source->flags |= PA_SOURCE_HW_VOLUME_CTRL | (u->hw_dB_supported ? PA_SOURCE_DECIBEL_VOLUME : 0);
- pa_log_info("Using hardware volume control. Hardware dB scale %s.", u->hw_dB_supported ? "supported" : "not supported");
+ pa_alsa_path_select(u->mixer_path, u->mixer_handle);
- if (!u->hw_dB_supported)
- u->source->n_volume_steps = u->hw_volume_max - u->hw_volume_min + 1;
+ if (u->mixer_path->settings)
+ pa_alsa_setting_select(u->mixer_path->settings, u->mixer_handle);
} else
- pa_log_info("Using software volume control.");
+ return 0;
}
- if (snd_mixer_selem_has_capture_switch(u->mixer_elem)) {
+ if (!u->mixer_path->has_volume)
+ pa_log_info("Driver does not support hardware volume control, falling back to software volume control.");
+ else {
+
+ if (u->mixer_path->has_dB) {
+ pa_log_info("Hardware volume ranges from %0.2f dB to %0.2f dB.", u->mixer_path->min_dB, u->mixer_path->max_dB);
+
+ u->source->base_volume = pa_sw_volume_from_dB(-u->mixer_path->max_dB);
+ u->source->n_volume_steps = PA_VOLUME_NORM+1;
+
+ pa_log_info("Fixing base volume to %0.2f dB", pa_sw_volume_to_dB(u->source->base_volume));
+
+ } else {
+ pa_log_info("Hardware volume ranges from %li to %li.", u->mixer_path->min_volume, u->mixer_path->max_volume);
+ u->source->base_volume = PA_VOLUME_NORM;
+ u->source->n_volume_steps = u->mixer_path->max_volume - u->mixer_path->min_volume + 1;
+ }
+
+ u->source->get_volume = source_get_volume_cb;
+ u->source->set_volume = source_set_volume_cb;
+ u->source->write_volume = source_write_volume_cb;
+
+ u->source->flags |= PA_SOURCE_HW_VOLUME_CTRL;
+ if (u->mixer_path->has_dB) {
+ u->source->flags |= PA_SOURCE_DECIBEL_VOLUME;
+ if (sync_volume) {
+ u->source->flags |= PA_SOURCE_SYNC_VOLUME;
+ pa_log_info("Successfully enabled synchronous volume.");
+ }
+ }
+
+ pa_log_info("Using hardware volume control. Hardware dB scale %s.", u->mixer_path->has_dB ? "supported" : "not supported");
+ }
+
+ if (!u->mixer_path->has_mute) {
+ pa_log_info("Driver does not support hardware mute control, falling back to software mute control.");
+ } else {
u->source->get_mute = source_get_mute_cb;
u->source->set_mute = source_set_mute_cb;
u->source->flags |= PA_SOURCE_HW_MUTE_CTRL;
- } else
- pa_log_info("Using software mute control.");
+ pa_log_info("Using hardware mute control.");
+ }
- u->mixer_fdl = pa_alsa_fdlist_new();
+ if (u->source->flags & (PA_SOURCE_HW_VOLUME_CTRL|PA_SOURCE_HW_MUTE_CTRL)) {
+ int (*mixer_callback)(snd_mixer_elem_t *, unsigned int);
+ if (u->source->flags & PA_SOURCE_SYNC_VOLUME) {
+ u->mixer_pd = pa_alsa_mixer_pdata_new();
+ mixer_callback = io_mixer_callback;
- if (pa_alsa_fdlist_set_mixer(u->mixer_fdl, u->mixer_handle, u->core->mainloop) < 0) {
- pa_log("Failed to initialize file descriptor monitoring");
- return -1;
- }
+ if (pa_alsa_set_mixer_rtpoll(u->mixer_pd, u->mixer_handle, u->rtpoll) < 0) {
+ pa_log("Failed to initialize file descriptor monitoring");
+ return -1;
+ }
+ } else {
+ u->mixer_fdl = pa_alsa_fdlist_new();
+ mixer_callback = ctl_mixer_callback;
- snd_mixer_elem_set_callback(u->mixer_elem, mixer_callback);
- snd_mixer_elem_set_callback_private(u->mixer_elem, u);
+ if (pa_alsa_fdlist_set_mixer(u->mixer_fdl, u->mixer_handle, u->core->mainloop) < 0) {
+ pa_log("Failed to initialize file descriptor monitoring");
+ return -1;
+ }
+ }
+
+ if (u->mixer_path_set)
+ pa_alsa_path_set_set_callback(u->mixer_path_set, u->mixer_handle, mixer_callback, u);
+ else
+ pa_alsa_path_set_callback(u->mixer_path, u->mixer_handle, mixer_callback, u);
+ }
return 0;
}
-pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, const pa_alsa_profile_info *profile) {
+pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, pa_alsa_mapping *mapping) {
struct userdata *u = NULL;
const char *dev_id = NULL;
pa_sample_spec ss, requested_ss;
pa_channel_map map;
- uint32_t nfrags, hwbuf_size, frag_size, tsched_size, tsched_watermark;
- snd_pcm_uframes_t period_frames, tsched_frames;
+ uint32_t nfrags, frag_size, buffer_size, tsched_size, tsched_watermark;
+ snd_pcm_uframes_t period_frames, buffer_frames, tsched_frames;
size_t frame_size;
- pa_bool_t use_mmap = TRUE, b, use_tsched = TRUE, d, ignore_dB = FALSE;
+ pa_bool_t use_mmap = TRUE, b, use_tsched = TRUE, d, ignore_dB = FALSE, namereg_fail = FALSE, sync_volume = FALSE;
pa_source_new_data data;
- char *control_device = NULL;
+ pa_alsa_profile_set *profile_set = NULL;
pa_assert(m);
pa_assert(ma);
@@ -1374,7 +1625,7 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
ss = m->core->default_sample_spec;
map = m->core->default_channel_map;
if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_ALSA) < 0) {
- pa_log("Failed to parse sample specification");
+ pa_log("Failed to parse sample specification and channel map");
goto fail;
}
@@ -1396,8 +1647,10 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
goto fail;
}
- hwbuf_size = frag_size * nfrags;
+ buffer_size = nfrags * frag_size;
+
period_frames = frag_size/frame_size;
+ buffer_frames = buffer_size/frame_size;
tsched_frames = tsched_size/frame_size;
if (pa_modargs_get_value_boolean(ma, "mmap", &use_mmap) < 0) {
@@ -1406,7 +1659,7 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
}
if (pa_modargs_get_value_boolean(ma, "tsched", &use_tsched) < 0) {
- pa_log("Failed to parse timer_scheduling argument.");
+ pa_log("Failed to parse tsched argument.");
goto fail;
}
@@ -1415,62 +1668,74 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
goto fail;
}
- if (use_tsched && !pa_rtclock_hrtimer()) {
- pa_log_notice("Disabling timer-based scheduling because high-resolution timers are not available from the kernel.");
- use_tsched = FALSE;
+ sync_volume = m->core->sync_volume;
+ if (pa_modargs_get_value_boolean(ma, "sync_volume", &sync_volume) < 0) {
+ pa_log("Failed to parse sync_volume argument.");
+ goto fail;
}
+ use_tsched = pa_alsa_may_tsched(use_tsched);
+
u = pa_xnew0(struct userdata, 1);
u->core = m->core;
u->module = m;
u->use_mmap = use_mmap;
u->use_tsched = use_tsched;
+ u->first = TRUE;
u->rtpoll = pa_rtpoll_new();
pa_thread_mq_init(&u->thread_mq, m->core->mainloop, u->rtpoll);
- u->alsa_rtpoll_item = NULL;
u->smoother = pa_smoother_new(
- DEFAULT_TSCHED_WATERMARK_USEC*2,
- DEFAULT_TSCHED_WATERMARK_USEC*2,
+ SMOOTHER_ADJUST_USEC,
+ SMOOTHER_WINDOW_USEC,
TRUE,
TRUE,
5,
- pa_rtclock_usec(),
- FALSE);
+ pa_rtclock_now(),
+ TRUE);
+ u->smoother_interval = SMOOTHER_MIN_INTERVAL;
+
+ dev_id = pa_modargs_get_value(
+ ma, "device_id",
+ pa_modargs_get_value(ma, "device", DEFAULT_DEVICE));
+
+ if (reserve_init(u, dev_id) < 0)
+ goto fail;
- if (reserve_init(u, pa_modargs_get_value(
- ma, "device_id",
- pa_modargs_get_value(ma, "device", DEFAULT_DEVICE))) < 0)
+ if (reserve_monitor_init(u, dev_id) < 0)
goto fail;
b = use_mmap;
d = use_tsched;
- if (profile) {
+ if (mapping) {
if (!(dev_id = pa_modargs_get_value(ma, "device_id", NULL))) {
pa_log("device_id= not set");
goto fail;
}
- if (!(u->pcm_handle = pa_alsa_open_by_device_id_profile(
+ if (!(u->pcm_handle = pa_alsa_open_by_device_id_mapping(
dev_id,
&u->device_name,
&ss, &map,
SND_PCM_STREAM_CAPTURE,
- &nfrags, &period_frames, tsched_frames,
- &b, &d, profile)))
+ &period_frames, &buffer_frames, tsched_frames,
+ &b, &d, mapping)))
goto fail;
} else if ((dev_id = pa_modargs_get_value(ma, "device_id", NULL))) {
+ if (!(profile_set = pa_alsa_profile_set_new(NULL, &map)))
+ goto fail;
+
if (!(u->pcm_handle = pa_alsa_open_by_device_id_auto(
dev_id,
&u->device_name,
&ss, &map,
SND_PCM_STREAM_CAPTURE,
- &nfrags, &period_frames, tsched_frames,
- &b, &d, &profile)))
+ &period_frames, &buffer_frames, tsched_frames,
+ &b, &d, profile_set, &mapping)))
goto fail;
} else {
@@ -1480,7 +1745,7 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
&u->device_name,
&ss, &map,
SND_PCM_STREAM_CAPTURE,
- &nfrags, &period_frames, tsched_frames,
+ &period_frames, &buffer_frames, tsched_frames,
&b, &d, FALSE)))
goto fail;
}
@@ -1493,8 +1758,8 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
goto fail;
}
- if (profile)
- pa_log_info("Selected configuration '%s' (%s).", profile->description, profile->name);
+ if (mapping)
+ pa_log_info("Selected mapping '%s' (%s).", mapping->description, mapping->name);
if (use_mmap && !b) {
pa_log_info("Device doesn't support mmap(), falling back to UNIX read/write mode.");
@@ -1506,11 +1771,6 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
u->use_tsched = use_tsched = FALSE;
}
- if (use_tsched && !pa_alsa_pcm_is_hw(u->pcm_handle)) {
- pa_log_info("Device is not a hardware device, disabling timer-based scheduling.");
- u->use_tsched = use_tsched = FALSE;
- }
-
if (u->use_mmap)
pa_log_info("Successfully enabled mmap() mode.");
@@ -1520,33 +1780,44 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
/* ALSA might tweak the sample spec, so recalculate the frame size */
frame_size = pa_frame_size(&ss);
- pa_alsa_find_mixer_and_elem(u->pcm_handle, &control_device, &u->mixer_handle, &u->mixer_elem, pa_modargs_get_value(ma, "control", NULL), profile);
+ find_mixer(u, mapping, pa_modargs_get_value(ma, "control", NULL), ignore_dB);
pa_source_new_data_init(&data);
data.driver = driver;
data.module = m;
data.card = card;
- set_source_name(&data, ma, dev_id, u->device_name);
+ set_source_name(&data, ma, dev_id, u->device_name, mapping);
+
+ /* We need to give pa_modargs_get_value_boolean() a pointer to a local
+ * variable instead of using &data.namereg_fail directly, because
+ * data.namereg_fail is a bitfield and taking the address of a bitfield
+ * variable is impossible. */
+ namereg_fail = data.namereg_fail;
+ if (pa_modargs_get_value_boolean(ma, "namereg_fail", &namereg_fail) < 0) {
+ pa_log("Failed to parse boolean argument namereg_fail.");
+ pa_source_new_data_done(&data);
+ goto fail;
+ }
+ data.namereg_fail = namereg_fail;
+
pa_source_new_data_set_sample_spec(&data, &ss);
pa_source_new_data_set_channel_map(&data, &map);
- pa_alsa_init_proplist_pcm(m->core, data.proplist, u->pcm_handle, u->mixer_elem);
+ pa_alsa_init_proplist_pcm(m->core, data.proplist, u->pcm_handle);
pa_proplist_sets(data.proplist, PA_PROP_DEVICE_STRING, u->device_name);
- pa_proplist_setf(data.proplist, PA_PROP_DEVICE_BUFFERING_BUFFER_SIZE, "%lu", (unsigned long) (period_frames * frame_size * nfrags));
+ pa_proplist_setf(data.proplist, PA_PROP_DEVICE_BUFFERING_BUFFER_SIZE, "%lu", (unsigned long) (buffer_frames * frame_size));
pa_proplist_setf(data.proplist, PA_PROP_DEVICE_BUFFERING_FRAGMENT_SIZE, "%lu", (unsigned long) (period_frames * frame_size));
pa_proplist_sets(data.proplist, PA_PROP_DEVICE_ACCESS_MODE, u->use_tsched ? "mmap+timer" : (u->use_mmap ? "mmap" : "serial"));
- if (profile) {
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_NAME, profile->name);
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_DESCRIPTION, profile->description);
+ if (mapping) {
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_NAME, mapping->name);
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_PROFILE_DESCRIPTION, mapping->description);
}
pa_alsa_init_description(data.proplist);
- if (control_device) {
- pa_alsa_init_proplist_ctl(data.proplist, control_device);
- pa_xfree(control_device);
- }
+ if (u->control_device)
+ pa_alsa_init_proplist_ctl(data.proplist, u->control_device);
if (pa_modargs_get_proplist(ma, "source_properties", data.proplist, PA_UPDATE_REPLACE) < 0) {
pa_log("Invalid properties");
@@ -1554,6 +1825,9 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
goto fail;
}
+ if (u->mixer_path_set)
+ pa_alsa_add_ports(&data.ports, u->mixer_path_set);
+
u->source = pa_source_new(m->core, &data, PA_SOURCE_HARDWARE|PA_SOURCE_LATENCY|(u->use_tsched ? PA_SOURCE_DYNAMIC_LATENCY : 0));
pa_source_new_data_done(&data);
@@ -1562,27 +1836,48 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
goto fail;
}
+ if (pa_modargs_get_value_u32(ma, "sync_volume_safety_margin",
+ &u->source->thread_info.volume_change_safety_margin) < 0) {
+ pa_log("Failed to parse sync_volume_safety_margin parameter");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_s32(ma, "sync_volume_extra_delay",
+ &u->source->thread_info.volume_change_extra_delay) < 0) {
+ pa_log("Failed to parse sync_volume_extra_delay parameter");
+ goto fail;
+ }
+
u->source->parent.process_msg = source_process_msg;
- u->source->update_requested_latency = source_update_requested_latency_cb;
+ if (u->use_tsched)
+ u->source->update_requested_latency = source_update_requested_latency_cb;
u->source->set_state = source_set_state_cb;
+ u->source->set_port = source_set_port_cb;
u->source->userdata = u;
pa_source_set_asyncmsgq(u->source, u->thread_mq.inq);
pa_source_set_rtpoll(u->source, u->rtpoll);
u->frame_size = frame_size;
- u->fragment_size = frag_size = (uint32_t) (period_frames * frame_size);
- u->nfragments = nfrags;
- u->hwbuf_size = u->fragment_size * nfrags;
- u->tsched_watermark = pa_usec_to_bytes_round_up(pa_bytes_to_usec_round_up(tsched_watermark, &requested_ss), &u->source->sample_spec);
+ u->fragment_size = frag_size = (size_t) (period_frames * frame_size);
+ u->hwbuf_size = buffer_size = (size_t) (buffer_frames * frame_size);
pa_cvolume_mute(&u->hardware_volume, u->source->sample_spec.channels);
- pa_log_info("Using %u fragments of size %lu bytes, buffer time is %0.2fms",
- nfrags, (long unsigned) u->fragment_size,
+ pa_log_info("Using %0.1f fragments of size %lu bytes (%0.2fms), buffer size is %lu bytes (%0.2fms)",
+ (double) u->hwbuf_size / (double) u->fragment_size,
+ (long unsigned) u->fragment_size,
+ (double) pa_bytes_to_usec(u->fragment_size, &ss) / PA_USEC_PER_MSEC,
+ (long unsigned) u->hwbuf_size,
(double) pa_bytes_to_usec(u->hwbuf_size, &ss) / PA_USEC_PER_MSEC);
if (u->use_tsched) {
- u->watermark_step = pa_usec_to_bytes(TSCHED_WATERMARK_STEP_USEC, &u->source->sample_spec);
+ u->tsched_watermark = pa_usec_to_bytes_round_up(pa_bytes_to_usec_round_up(tsched_watermark, &requested_ss), &u->source->sample_spec);
+
+ u->watermark_inc_step = pa_usec_to_bytes(TSCHED_WATERMARK_INC_STEP_USEC, &u->source->sample_spec);
+ u->watermark_dec_step = pa_usec_to_bytes(TSCHED_WATERMARK_DEC_STEP_USEC, &u->source->sample_spec);
+
+ u->watermark_inc_threshold = pa_usec_to_bytes_round_up(TSCHED_WATERMARK_INC_THRESHOLD_USEC, &u->source->sample_spec);
+ u->watermark_dec_threshold = pa_usec_to_bytes_round_up(TSCHED_WATERMARK_DEC_THRESHOLD_USEC, &u->source->sample_spec);
fix_min_sleep_wakeup(u);
fix_tsched_watermark(u);
@@ -1601,15 +1896,16 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
if (update_sw_params(u) < 0)
goto fail;
- if (setup_mixer(u, ignore_dB) < 0)
+ if (setup_mixer(u, ignore_dB, sync_volume) < 0)
goto fail;
pa_alsa_dump(PA_LOG_DEBUG, u->pcm_handle);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("alsa-source", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
+
/* Get initial mixer settings */
if (data.volume_is_set) {
if (u->source->set_volume)
@@ -1629,6 +1925,9 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
pa_source_put(u->source);
+ if (profile_set)
+ pa_alsa_profile_set_free(profile_set);
+
return u->source;
fail:
@@ -1636,6 +1935,9 @@ fail:
if (u)
userdata_free(u);
+ if (profile_set)
+ pa_alsa_profile_set_free(profile_set);
+
return NULL;
}
@@ -1655,29 +1957,39 @@ static void userdata_free(struct userdata *u) {
if (u->source)
pa_source_unref(u->source);
+ if (u->mixer_pd)
+ pa_alsa_mixer_pdata_free(u->mixer_pd);
+
if (u->alsa_rtpoll_item)
pa_rtpoll_item_free(u->alsa_rtpoll_item);
if (u->rtpoll)
pa_rtpoll_free(u->rtpoll);
+ if (u->pcm_handle) {
+ snd_pcm_drop(u->pcm_handle);
+ snd_pcm_close(u->pcm_handle);
+ }
+
if (u->mixer_fdl)
pa_alsa_fdlist_free(u->mixer_fdl);
+ if (u->mixer_path_set)
+ pa_alsa_path_set_free(u->mixer_path_set);
+ else if (u->mixer_path)
+ pa_alsa_path_free(u->mixer_path);
+
if (u->mixer_handle)
snd_mixer_close(u->mixer_handle);
- if (u->pcm_handle) {
- snd_pcm_drop(u->pcm_handle);
- snd_pcm_close(u->pcm_handle);
- }
-
if (u->smoother)
pa_smoother_free(u->smoother);
reserve_done(u);
+ monitor_done(u);
pa_xfree(u->device_name);
+ pa_xfree(u->control_device);
pa_xfree(u);
}
diff --git a/src/modules/alsa/alsa-source.h b/src/modules/alsa/alsa-source.h
index 9cbb0e17..5d9409e2 100644
--- a/src/modules/alsa/alsa-source.h
+++ b/src/modules/alsa/alsa-source.h
@@ -29,7 +29,7 @@
#include "alsa-util.h"
-pa_source* pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, const pa_alsa_profile_info *profile);
+pa_source* pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, pa_card *card, pa_alsa_mapping *mapping);
void pa_alsa_source_free(pa_source *s);
diff --git a/src/modules/alsa/alsa-util.c b/src/modules/alsa/alsa-util.c
index c03866cc..883c26f9 100644
--- a/src/modules/alsa/alsa-util.c
+++ b/src/modules/alsa/alsa-util.c
@@ -25,7 +25,6 @@
#endif
#include <sys/types.h>
-#include <limits.h>
#include <asoundlib.h>
#include <pulse/sample.h>
@@ -40,10 +39,12 @@
#include <pulsecore/core-util.h>
#include <pulsecore/atomic.h>
#include <pulsecore/core-error.h>
-#include <pulsecore/once.h>
#include <pulsecore/thread.h>
+#include <pulsecore/conf-parser.h>
+#include <pulsecore/core-rtclock.h>
#include "alsa-util.h"
+#include "alsa-mixer.h"
#ifdef HAVE_HAL
#include "hal-util.h"
@@ -53,182 +54,6 @@
#include "udev-util.h"
#endif
-struct pa_alsa_fdlist {
- unsigned num_fds;
- struct pollfd *fds;
- /* This is a temporary buffer used to avoid lots of mallocs */
- struct pollfd *work_fds;
-
- snd_mixer_t *mixer;
-
- pa_mainloop_api *m;
- pa_defer_event *defer;
- pa_io_event **ios;
-
- pa_bool_t polled;
-
- void (*cb)(void *userdata);
- void *userdata;
-};
-
-static void io_cb(pa_mainloop_api*a, pa_io_event* e, int fd, pa_io_event_flags_t events, void *userdata) {
-
- struct pa_alsa_fdlist *fdl = userdata;
- int err;
- unsigned i;
- unsigned short revents;
-
- pa_assert(a);
- pa_assert(fdl);
- pa_assert(fdl->mixer);
- pa_assert(fdl->fds);
- pa_assert(fdl->work_fds);
-
- if (fdl->polled)
- return;
-
- fdl->polled = TRUE;
-
- memcpy(fdl->work_fds, fdl->fds, sizeof(struct pollfd) * fdl->num_fds);
-
- for (i = 0; i < fdl->num_fds; i++) {
- if (e == fdl->ios[i]) {
- if (events & PA_IO_EVENT_INPUT)
- fdl->work_fds[i].revents |= POLLIN;
- if (events & PA_IO_EVENT_OUTPUT)
- fdl->work_fds[i].revents |= POLLOUT;
- if (events & PA_IO_EVENT_ERROR)
- fdl->work_fds[i].revents |= POLLERR;
- if (events & PA_IO_EVENT_HANGUP)
- fdl->work_fds[i].revents |= POLLHUP;
- break;
- }
- }
-
- pa_assert(i != fdl->num_fds);
-
- if ((err = snd_mixer_poll_descriptors_revents(fdl->mixer, fdl->work_fds, fdl->num_fds, &revents)) < 0) {
- pa_log_error("Unable to get poll revent: %s", pa_alsa_strerror(err));
- return;
- }
-
- a->defer_enable(fdl->defer, 1);
-
- if (revents)
- snd_mixer_handle_events(fdl->mixer);
-}
-
-static void defer_cb(pa_mainloop_api*a, pa_defer_event* e, void *userdata) {
- struct pa_alsa_fdlist *fdl = userdata;
- unsigned num_fds, i;
- int err, n;
- struct pollfd *temp;
-
- pa_assert(a);
- pa_assert(fdl);
- pa_assert(fdl->mixer);
-
- a->defer_enable(fdl->defer, 0);
-
- if ((n = snd_mixer_poll_descriptors_count(fdl->mixer)) < 0) {
- pa_log("snd_mixer_poll_descriptors_count() failed: %s", pa_alsa_strerror(n));
- return;
- }
- num_fds = (unsigned) n;
-
- if (num_fds != fdl->num_fds) {
- if (fdl->fds)
- pa_xfree(fdl->fds);
- if (fdl->work_fds)
- pa_xfree(fdl->work_fds);
- fdl->fds = pa_xnew0(struct pollfd, num_fds);
- fdl->work_fds = pa_xnew(struct pollfd, num_fds);
- }
-
- memset(fdl->work_fds, 0, sizeof(struct pollfd) * num_fds);
-
- if ((err = snd_mixer_poll_descriptors(fdl->mixer, fdl->work_fds, num_fds)) < 0) {
- pa_log_error("Unable to get poll descriptors: %s", pa_alsa_strerror(err));
- return;
- }
-
- fdl->polled = FALSE;
-
- if (memcmp(fdl->fds, fdl->work_fds, sizeof(struct pollfd) * num_fds) == 0)
- return;
-
- if (fdl->ios) {
- for (i = 0; i < fdl->num_fds; i++)
- a->io_free(fdl->ios[i]);
-
- if (num_fds != fdl->num_fds) {
- pa_xfree(fdl->ios);
- fdl->ios = NULL;
- }
- }
-
- if (!fdl->ios)
- fdl->ios = pa_xnew(pa_io_event*, num_fds);
-
- /* Swap pointers */
- temp = fdl->work_fds;
- fdl->work_fds = fdl->fds;
- fdl->fds = temp;
-
- fdl->num_fds = num_fds;
-
- for (i = 0;i < num_fds;i++)
- fdl->ios[i] = a->io_new(a, fdl->fds[i].fd,
- ((fdl->fds[i].events & POLLIN) ? PA_IO_EVENT_INPUT : 0) |
- ((fdl->fds[i].events & POLLOUT) ? PA_IO_EVENT_OUTPUT : 0),
- io_cb, fdl);
-}
-
-struct pa_alsa_fdlist *pa_alsa_fdlist_new(void) {
- struct pa_alsa_fdlist *fdl;
-
- fdl = pa_xnew0(struct pa_alsa_fdlist, 1);
-
- return fdl;
-}
-
-void pa_alsa_fdlist_free(struct pa_alsa_fdlist *fdl) {
- pa_assert(fdl);
-
- if (fdl->defer) {
- pa_assert(fdl->m);
- fdl->m->defer_free(fdl->defer);
- }
-
- if (fdl->ios) {
- unsigned i;
- pa_assert(fdl->m);
- for (i = 0; i < fdl->num_fds; i++)
- fdl->m->io_free(fdl->ios[i]);
- pa_xfree(fdl->ios);
- }
-
- if (fdl->fds)
- pa_xfree(fdl->fds);
- if (fdl->work_fds)
- pa_xfree(fdl->work_fds);
-
- pa_xfree(fdl);
-}
-
-int pa_alsa_fdlist_set_mixer(struct pa_alsa_fdlist *fdl, snd_mixer_t *mixer_handle, pa_mainloop_api* m) {
- pa_assert(fdl);
- pa_assert(mixer_handle);
- pa_assert(m);
- pa_assert(!fdl->m);
-
- fdl->mixer = mixer_handle;
- fdl->m = m;
- fdl->defer = m->defer_new(m, defer_cb, fdl);
-
- return 0;
-}
-
static int set_format(snd_pcm_t *pcm_handle, snd_pcm_hw_params_t *hwparams, pa_sample_format_t *f) {
static const snd_pcm_format_t format_trans[] = {
@@ -260,13 +85,14 @@ static int set_format(snd_pcm_t *pcm_handle, snd_pcm_hw_params_t *hwparams, pa_s
PA_SAMPLE_S16RE,
PA_SAMPLE_ALAW,
PA_SAMPLE_ULAW,
- PA_SAMPLE_U8,
- PA_SAMPLE_INVALID
+ PA_SAMPLE_U8
};
- int i, ret;
+ unsigned i;
+ int ret;
pa_assert(pcm_handle);
+ pa_assert(hwparams);
pa_assert(f);
if ((ret = snd_pcm_hw_params_set_format(pcm_handle, hwparams, format_trans[*f])) >= 0)
@@ -276,7 +102,6 @@ static int set_format(snd_pcm_t *pcm_handle, snd_pcm_hw_params_t *hwparams, pa_s
snd_pcm_format_description(format_trans[*f]),
pa_alsa_strerror(ret));
-
if (*f == PA_SAMPLE_FLOAT32BE)
*f = PA_SAMPLE_FLOAT32LE;
else if (*f == PA_SAMPLE_FLOAT32LE)
@@ -309,7 +134,7 @@ static int set_format(snd_pcm_t *pcm_handle, snd_pcm_hw_params_t *hwparams, pa_s
try_auto:
- for (i = 0; try_order[i] != PA_SAMPLE_INVALID; i++) {
+ for (i = 0; i < PA_ELEMENTSOF(try_order); i++) {
*f = try_order[i];
if ((ret = snd_pcm_hw_params_set_format(pcm_handle, hwparams, format_trans[*f])) >= 0)
@@ -323,33 +148,71 @@ try_auto:
return -1;
}
+static int set_period_size(snd_pcm_t *pcm_handle, snd_pcm_hw_params_t *hwparams, snd_pcm_uframes_t size) {
+ snd_pcm_uframes_t s;
+ int d, ret;
+
+ pa_assert(pcm_handle);
+ pa_assert(hwparams);
+
+ s = size;
+ d = 0;
+ if (snd_pcm_hw_params_set_period_size_near(pcm_handle, hwparams, &s, &d) < 0) {
+ s = size;
+ d = -1;
+ if (snd_pcm_hw_params_set_period_size_near(pcm_handle, hwparams, &s, &d) < 0) {
+ s = size;
+ d = 1;
+ if ((ret = snd_pcm_hw_params_set_period_size_near(pcm_handle, hwparams, &s, &d)) < 0) {
+ pa_log_info("snd_pcm_hw_params_set_period_size_near() failed: %s", pa_alsa_strerror(ret));
+ return ret;
+ }
+ }
+ }
+
+ return 0;
+}
+
+static int set_buffer_size(snd_pcm_t *pcm_handle, snd_pcm_hw_params_t *hwparams, snd_pcm_uframes_t size) {
+ int ret;
+
+ pa_assert(pcm_handle);
+ pa_assert(hwparams);
+
+ if ((ret = snd_pcm_hw_params_set_buffer_size_near(pcm_handle, hwparams, &size)) < 0) {
+ pa_log_info("snd_pcm_hw_params_set_buffer_size_near() failed: %s", pa_alsa_strerror(ret));
+ return ret;
+ }
+
+ return 0;
+}
+
/* Set the hardware parameters of the given ALSA device. Returns the
- * selected fragment settings in *period and *period_size */
+ * selected fragment settings in *buffer_size and *period_size. If tsched mode can be enabled */
int pa_alsa_set_hw_params(
snd_pcm_t *pcm_handle,
pa_sample_spec *ss,
- uint32_t *periods,
snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *buffer_size,
snd_pcm_uframes_t tsched_size,
pa_bool_t *use_mmap,
pa_bool_t *use_tsched,
pa_bool_t require_exact_channel_number) {
int ret = -1;
+ snd_pcm_hw_params_t *hwparams, *hwparams_copy;
+ int dir;
snd_pcm_uframes_t _period_size = period_size ? *period_size : 0;
- unsigned int _periods = periods ? *periods : 0;
- unsigned int r = ss->rate;
- unsigned int c = ss->channels;
- pa_sample_format_t f = ss->format;
- snd_pcm_hw_params_t *hwparams;
+ snd_pcm_uframes_t _buffer_size = buffer_size ? *buffer_size : 0;
pa_bool_t _use_mmap = use_mmap && *use_mmap;
pa_bool_t _use_tsched = use_tsched && *use_tsched;
- int dir;
+ pa_sample_spec _ss = *ss;
pa_assert(pcm_handle);
pa_assert(ss);
snd_pcm_hw_params_alloca(&hwparams);
+ snd_pcm_hw_params_alloca(&hwparams_copy);
if ((ret = snd_pcm_hw_params_any(pcm_handle, hwparams)) < 0) {
pa_log_debug("snd_pcm_hw_params_any() failed: %s", pa_alsa_strerror(ret));
@@ -383,105 +246,173 @@ int pa_alsa_set_hw_params(
if (!_use_mmap)
_use_tsched = FALSE;
- if ((ret = set_format(pcm_handle, hwparams, &f)) < 0)
+ if (!pa_alsa_pcm_is_hw(pcm_handle))
+ _use_tsched = FALSE;
+
+#if (SND_LIB_VERSION >= ((1<<16)|(0<<8)|24)) /* API additions in 1.0.24 */
+ if (_use_tsched) {
+
+ /* try to disable period wakeups if hardware can do so */
+ if (snd_pcm_hw_params_can_disable_period_wakeup(hwparams)) {
+
+ if (snd_pcm_hw_params_set_period_wakeup(pcm_handle, hwparams, FALSE) < 0)
+ /* don't bail, keep going with default mode with period wakeups */
+ pa_log_debug("snd_pcm_hw_params_set_period_wakeup() failed: %s", pa_alsa_strerror(ret));
+ else
+ pa_log_info("Trying to disable ALSA period wakeups, using timers only");
+ } else
+ pa_log_info("cannot disable ALSA period wakeups");
+ }
+#endif
+
+ if ((ret = set_format(pcm_handle, hwparams, &_ss.format)) < 0)
goto finish;
- if ((ret = snd_pcm_hw_params_set_rate_near(pcm_handle, hwparams, &r, NULL)) < 0) {
+ if ((ret = snd_pcm_hw_params_set_rate_near(pcm_handle, hwparams, &_ss.rate, NULL)) < 0) {
pa_log_debug("snd_pcm_hw_params_set_rate_near() failed: %s", pa_alsa_strerror(ret));
goto finish;
}
+ /* We ignore very small sampling rate deviations */
+ if (_ss.rate >= ss->rate*.95 && _ss.rate <= ss->rate*1.05)
+ _ss.rate = ss->rate;
+
if (require_exact_channel_number) {
- if ((ret = snd_pcm_hw_params_set_channels(pcm_handle, hwparams, c)) < 0) {
- pa_log_debug("snd_pcm_hw_params_set_channels() failed: %s", pa_alsa_strerror(ret));
+ if ((ret = snd_pcm_hw_params_set_channels(pcm_handle, hwparams, _ss.channels)) < 0) {
+ pa_log_debug("snd_pcm_hw_params_set_channels(%u) failed: %s", _ss.channels, pa_alsa_strerror(ret));
goto finish;
}
} else {
+ unsigned int c = _ss.channels;
+
if ((ret = snd_pcm_hw_params_set_channels_near(pcm_handle, hwparams, &c)) < 0) {
- pa_log_debug("snd_pcm_hw_params_set_channels_near() failed: %s", pa_alsa_strerror(ret));
+ pa_log_debug("snd_pcm_hw_params_set_channels_near(%u) failed: %s", _ss.channels, pa_alsa_strerror(ret));
goto finish;
}
+
+ _ss.channels = c;
}
- if ((ret = snd_pcm_hw_params_set_periods_integer(pcm_handle, hwparams)) < 0) {
- pa_log_debug("snd_pcm_hw_params_set_periods_integer() failed: %s", pa_alsa_strerror(ret));
- goto finish;
+ if (_use_tsched && tsched_size > 0) {
+ _buffer_size = (snd_pcm_uframes_t) (((uint64_t) tsched_size * _ss.rate) / ss->rate);
+ _period_size = _buffer_size;
+ } else {
+ _period_size = (snd_pcm_uframes_t) (((uint64_t) _period_size * _ss.rate) / ss->rate);
+ _buffer_size = (snd_pcm_uframes_t) (((uint64_t) _buffer_size * _ss.rate) / ss->rate);
}
- if (_period_size && tsched_size && _periods) {
+ if (_buffer_size > 0 || _period_size > 0) {
+ snd_pcm_uframes_t max_frames = 0;
- /* Adjust the buffer sizes, if we didn't get the rate we were asking for */
- _period_size = (snd_pcm_uframes_t) (((uint64_t) _period_size * r) / ss->rate);
- tsched_size = (snd_pcm_uframes_t) (((uint64_t) tsched_size * r) / ss->rate);
+ if ((ret = snd_pcm_hw_params_get_buffer_size_max(hwparams, &max_frames)) < 0)
+ pa_log_warn("snd_pcm_hw_params_get_buffer_size_max() failed: %s", pa_alsa_strerror(ret));
+ else
+ pa_log_debug("Maximum hw buffer size is %lu ms", (long unsigned) (max_frames * PA_MSEC_PER_SEC / _ss.rate));
- if (_use_tsched) {
- snd_pcm_uframes_t buffer_size;
+ /* Some ALSA drivers really don't like if we set the buffer
+ * size first and the number of periods second. (which would
+ * make a lot more sense to me) So, try a few combinations
+ * before we give up. */
- pa_assert_se(snd_pcm_hw_params_get_buffer_size_max(hwparams, &buffer_size) == 0);
- pa_log_debug("Maximum hw buffer size is %u ms", (unsigned) buffer_size * 1000 / r);
+ if (_buffer_size > 0 && _period_size > 0) {
+ snd_pcm_hw_params_copy(hwparams_copy, hwparams);
- _period_size = tsched_size;
- _periods = 1;
- }
+ /* First try: set buffer size first, followed by period size */
+ if (set_buffer_size(pcm_handle, hwparams_copy, _buffer_size) >= 0 &&
+ set_period_size(pcm_handle, hwparams_copy, _period_size) >= 0 &&
+ snd_pcm_hw_params(pcm_handle, hwparams_copy) >= 0) {
+ pa_log_debug("Set buffer size first (to %lu samples), period size second (to %lu samples).", (unsigned long) _buffer_size, (unsigned long) _period_size);
+ goto success;
+ }
- if (_period_size > 0 && _periods > 0) {
- snd_pcm_uframes_t buffer_size;
+ /* Second try: set period size first, followed by buffer size */
+ if (set_period_size(pcm_handle, hwparams_copy, _period_size) >= 0 &&
+ set_buffer_size(pcm_handle, hwparams_copy, _buffer_size) >= 0 &&
+ snd_pcm_hw_params(pcm_handle, hwparams_copy) >= 0) {
+ pa_log_debug("Set period size first (to %lu samples), buffer size second (to %lu samples).", (unsigned long) _period_size, (unsigned long) _buffer_size);
+ goto success;
+ }
+ }
- buffer_size = _periods * _period_size;
+ if (_buffer_size > 0) {
+ snd_pcm_hw_params_copy(hwparams_copy, hwparams);
- if ((ret = snd_pcm_hw_params_set_buffer_size_near(pcm_handle, hwparams, &buffer_size)) < 0)
- pa_log_info("snd_pcm_hw_params_set_buffer_size_near() failed: %s", pa_alsa_strerror(ret));
+ /* Third try: set only buffer size */
+ if (set_buffer_size(pcm_handle, hwparams_copy, _buffer_size) >= 0 &&
+ snd_pcm_hw_params(pcm_handle, hwparams_copy) >= 0) {
+ pa_log_debug("Set only buffer size (to %lu samples).", (unsigned long) _buffer_size);
+ goto success;
+ }
}
- if (_periods > 0) {
-
- /* First we pass 0 as direction to get exactly what we
- * asked for. That this is necessary is presumably a bug
- * in ALSA. All in all this is mostly a hint to ALSA, so
- * we don't care if this fails. */
-
- dir = 0;
- if (snd_pcm_hw_params_set_periods_near(pcm_handle, hwparams, &_periods, &dir) < 0) {
- dir = 1;
- if (snd_pcm_hw_params_set_periods_near(pcm_handle, hwparams, &_periods, &dir) < 0) {
- dir = -1;
- if ((ret = snd_pcm_hw_params_set_periods_near(pcm_handle, hwparams, &_periods, &dir)) < 0)
- pa_log_info("snd_pcm_hw_params_set_periods_near() failed: %s", pa_alsa_strerror(ret));
- }
+ if (_period_size > 0) {
+ snd_pcm_hw_params_copy(hwparams_copy, hwparams);
+
+ /* Fourth try: set only period size */
+ if (set_period_size(pcm_handle, hwparams_copy, _period_size) >= 0 &&
+ snd_pcm_hw_params(pcm_handle, hwparams_copy) >= 0) {
+ pa_log_debug("Set only period size (to %lu samples).", (unsigned long) _period_size);
+ goto success;
}
}
}
- if ((ret = snd_pcm_hw_params(pcm_handle, hwparams)) < 0)
+ pa_log_debug("Set neither period nor buffer size.");
+
+ /* Last chance, set nothing */
+ if ((ret = snd_pcm_hw_params(pcm_handle, hwparams)) < 0) {
+ pa_log_info("snd_pcm_hw_params failed: %s", pa_alsa_strerror(ret));
goto finish;
+ }
+
+success:
- if (ss->rate != r)
- pa_log_info("Device %s doesn't support %u Hz, changed to %u Hz.", snd_pcm_name(pcm_handle), ss->rate, r);
+ if (ss->rate != _ss.rate)
+ pa_log_info("Device %s doesn't support %u Hz, changed to %u Hz.", snd_pcm_name(pcm_handle), ss->rate, _ss.rate);
- if (ss->channels != c)
- pa_log_info("Device %s doesn't support %u channels, changed to %u.", snd_pcm_name(pcm_handle), ss->channels, c);
+ if (ss->channels != _ss.channels)
+ pa_log_info("Device %s doesn't support %u channels, changed to %u.", snd_pcm_name(pcm_handle), ss->channels, _ss.channels);
- if (ss->format != f)
- pa_log_info("Device %s doesn't support sample format %s, changed to %s.", snd_pcm_name(pcm_handle), pa_sample_format_to_string(ss->format), pa_sample_format_to_string(f));
+ if (ss->format != _ss.format)
+ pa_log_info("Device %s doesn't support sample format %s, changed to %s.", snd_pcm_name(pcm_handle), pa_sample_format_to_string(ss->format), pa_sample_format_to_string(_ss.format));
- if ((ret = snd_pcm_prepare(pcm_handle)) < 0)
+ if ((ret = snd_pcm_prepare(pcm_handle)) < 0) {
+ pa_log_info("snd_pcm_prepare() failed: %s", pa_alsa_strerror(ret));
goto finish;
+ }
+
+ if ((ret = snd_pcm_hw_params_current(pcm_handle, hwparams)) < 0) {
+ pa_log_info("snd_pcm_hw_params_current() failed: %s", pa_alsa_strerror(ret));
+ goto finish;
+ }
if ((ret = snd_pcm_hw_params_get_period_size(hwparams, &_period_size, &dir)) < 0 ||
- (ret = snd_pcm_hw_params_get_periods(hwparams, &_periods, &dir)) < 0)
+ (ret = snd_pcm_hw_params_get_buffer_size(hwparams, &_buffer_size)) < 0) {
+ pa_log_info("snd_pcm_hw_params_get_{period|buffer}_size() failed: %s", pa_alsa_strerror(ret));
goto finish;
+ }
- /* If the sample rate deviates too much, we need to resample */
- if (r < ss->rate*.95 || r > ss->rate*1.05)
- ss->rate = r;
- ss->channels = (uint8_t) c;
- ss->format = f;
+#if (SND_LIB_VERSION >= ((1<<16)|(0<<8)|24)) /* API additions in 1.0.24 */
+ if (_use_tsched) {
+ unsigned int no_wakeup;
+ /* see if period wakeups were disabled */
+ snd_pcm_hw_params_get_period_wakeup(pcm_handle, hwparams, &no_wakeup);
+ if (no_wakeup == 0)
+ pa_log_info("ALSA period wakeups disabled");
+ else
+ pa_log_info("ALSA period wakeups were not disabled");
+ }
+#endif
+
+ ss->rate = _ss.rate;
+ ss->channels = _ss.channels;
+ ss->format = _ss.format;
- pa_assert(_periods > 0);
pa_assert(_period_size > 0);
+ pa_assert(_buffer_size > 0);
- if (periods)
- *periods = _periods;
+ if (buffer_size)
+ *buffer_size = _buffer_size;
if (period_size)
*period_size = _period_size;
@@ -494,14 +425,12 @@ int pa_alsa_set_hw_params(
ret = 0;
- snd_pcm_nonblock(pcm_handle, 1);
-
finish:
return ret;
}
-int pa_alsa_set_sw_params(snd_pcm_t *pcm, snd_pcm_uframes_t avail_min) {
+int pa_alsa_set_sw_params(snd_pcm_t *pcm, snd_pcm_uframes_t avail_min, pa_bool_t period_event) {
snd_pcm_sw_params_t *swparams;
snd_pcm_uframes_t boundary;
int err;
@@ -515,7 +444,7 @@ int pa_alsa_set_sw_params(snd_pcm_t *pcm, snd_pcm_uframes_t avail_min) {
return err;
}
- if ((err = snd_pcm_sw_params_set_period_event(pcm, swparams, 0)) < 0) {
+ if ((err = snd_pcm_sw_params_set_period_event(pcm, swparams, period_event)) < 0) {
pa_log_warn("Unable to disable period event: %s\n", pa_alsa_strerror(err));
return err;
}
@@ -553,335 +482,152 @@ int pa_alsa_set_sw_params(snd_pcm_t *pcm, snd_pcm_uframes_t avail_min) {
return 0;
}
-static const struct pa_alsa_profile_info device_table[] = {
- {{ 1, { PA_CHANNEL_POSITION_MONO }},
- "hw", NULL,
- N_("Analog Mono"),
- "analog-mono",
- 1,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 2, { PA_CHANNEL_POSITION_LEFT, PA_CHANNEL_POSITION_RIGHT }},
- "front", "hw",
- N_("Analog Stereo"),
- "analog-stereo",
- 10,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 2, { PA_CHANNEL_POSITION_LEFT, PA_CHANNEL_POSITION_RIGHT }},
- "iec958", NULL,
- N_("Digital Stereo (IEC958)"),
- "iec958-stereo",
- 5,
- "IEC958", NULL,
- "IEC958 In", NULL },
-
- {{ 2, { PA_CHANNEL_POSITION_LEFT, PA_CHANNEL_POSITION_RIGHT }},
- "hdmi", NULL,
- N_("Digital Stereo (HDMI)"),
- "hdmi-stereo",
- 4,
- "IEC958", NULL,
- "IEC958 In", NULL },
-
- {{ 4, { PA_CHANNEL_POSITION_FRONT_LEFT, PA_CHANNEL_POSITION_FRONT_RIGHT,
- PA_CHANNEL_POSITION_REAR_LEFT, PA_CHANNEL_POSITION_REAR_RIGHT }},
- "surround40", NULL,
- N_("Analog Surround 4.0"),
- "analog-surround-40",
- 7,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 4, { PA_CHANNEL_POSITION_FRONT_LEFT, PA_CHANNEL_POSITION_FRONT_RIGHT,
- PA_CHANNEL_POSITION_REAR_LEFT, PA_CHANNEL_POSITION_REAR_RIGHT }},
- "a52", NULL,
- N_("Digital Surround 4.0 (IEC958/AC3)"),
- "iec958-ac3-surround-40",
- 2,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 5, { PA_CHANNEL_POSITION_FRONT_LEFT, PA_CHANNEL_POSITION_FRONT_RIGHT,
- PA_CHANNEL_POSITION_REAR_LEFT, PA_CHANNEL_POSITION_REAR_RIGHT,
- PA_CHANNEL_POSITION_LFE }},
- "surround41", NULL,
- N_("Analog Surround 4.1"),
- "analog-surround-41",
- 7,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 5, { PA_CHANNEL_POSITION_FRONT_LEFT, PA_CHANNEL_POSITION_FRONT_RIGHT,
- PA_CHANNEL_POSITION_REAR_LEFT, PA_CHANNEL_POSITION_REAR_RIGHT,
- PA_CHANNEL_POSITION_CENTER }},
- "surround50", NULL,
- N_("Analog Surround 5.0"),
- "analog-surround-50",
- 7,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 6, { PA_CHANNEL_POSITION_FRONT_LEFT, PA_CHANNEL_POSITION_FRONT_RIGHT,
- PA_CHANNEL_POSITION_REAR_LEFT, PA_CHANNEL_POSITION_REAR_RIGHT,
- PA_CHANNEL_POSITION_CENTER, PA_CHANNEL_POSITION_LFE }},
- "surround51", NULL,
- N_("Analog Surround 5.1"),
- "analog-surround-51",
- 8,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 6, { PA_CHANNEL_POSITION_FRONT_LEFT, PA_CHANNEL_POSITION_FRONT_RIGHT,
- PA_CHANNEL_POSITION_REAR_LEFT, PA_CHANNEL_POSITION_REAR_RIGHT,
- PA_CHANNEL_POSITION_FRONT_CENTER, PA_CHANNEL_POSITION_LFE}},
- "a52", NULL,
- N_("Digital Surround 5.1 (IEC958/AC3)"),
- "iec958-ac3-surround-51",
- 3,
- "IEC958", NULL,
- "IEC958 In", NULL },
-
- {{ 8, { PA_CHANNEL_POSITION_FRONT_LEFT, PA_CHANNEL_POSITION_FRONT_RIGHT,
- PA_CHANNEL_POSITION_REAR_LEFT, PA_CHANNEL_POSITION_REAR_RIGHT,
- PA_CHANNEL_POSITION_CENTER, PA_CHANNEL_POSITION_LFE,
- PA_CHANNEL_POSITION_SIDE_LEFT, PA_CHANNEL_POSITION_SIDE_RIGHT }},
- "surround71", NULL,
- N_("Analog Surround 7.1"),
- "analog-surround-71",
- 7,
- "Master", "PCM",
- "Capture", "Mic" },
-
- {{ 0, { 0 }}, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL }
-};
-
-static snd_pcm_t *open_by_device_string_with_fallback(
- const char *prefix,
- const char *prefix_fallback,
+snd_pcm_t *pa_alsa_open_by_device_id_auto(
const char *dev_id,
char **dev,
pa_sample_spec *ss,
pa_channel_map* map,
int mode,
- uint32_t *nfrags,
snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *buffer_size,
snd_pcm_uframes_t tsched_size,
pa_bool_t *use_mmap,
pa_bool_t *use_tsched,
- pa_bool_t require_exact_channel_number) {
+ pa_alsa_profile_set *ps,
+ pa_alsa_mapping **mapping) {
- snd_pcm_t *pcm_handle;
char *d;
+ snd_pcm_t *pcm_handle;
+ void *state;
+ pa_alsa_mapping *m;
- d = pa_sprintf_malloc("%s:%s", prefix, dev_id);
+ pa_assert(dev_id);
+ pa_assert(dev);
+ pa_assert(ss);
+ pa_assert(map);
+ pa_assert(ps);
- pcm_handle = pa_alsa_open_by_device_string(
- d,
- dev,
- ss,
- map,
- mode,
- nfrags,
- period_size,
- tsched_size,
- use_mmap,
- use_tsched,
- require_exact_channel_number);
- pa_xfree(d);
+ /* First we try to find a device string with a superset of the
+ * requested channel map. We iterate through our device table from
+ * top to bottom and take the first that matches. If we didn't
+ * find a working device that way, we iterate backwards, and check
+ * all devices that do not provide a superset of the requested
+ * channel map.*/
- if (!pcm_handle && prefix_fallback) {
+ PA_HASHMAP_FOREACH(m, ps->mappings, state) {
+ if (!pa_channel_map_superset(&m->channel_map, map))
+ continue;
- d = pa_sprintf_malloc("%s:%s", prefix_fallback, dev_id);
+ pa_log_debug("Checking for superset %s (%s)", m->name, m->device_strings[0]);
- pcm_handle = pa_alsa_open_by_device_string(
- d,
+ pcm_handle = pa_alsa_open_by_device_id_mapping(
+ dev_id,
dev,
ss,
map,
mode,
- nfrags,
period_size,
+ buffer_size,
tsched_size,
use_mmap,
use_tsched,
- require_exact_channel_number);
- pa_xfree(d);
- }
-
- return pcm_handle;
-}
-
-snd_pcm_t *pa_alsa_open_by_device_id_auto(
- const char *dev_id,
- char **dev,
- pa_sample_spec *ss,
- pa_channel_map* map,
- int mode,
- uint32_t *nfrags,
- snd_pcm_uframes_t *period_size,
- snd_pcm_uframes_t tsched_size,
- pa_bool_t *use_mmap,
- pa_bool_t *use_tsched,
- const pa_alsa_profile_info **profile) {
+ m);
- int i;
- int direction = 1;
- char *d;
- snd_pcm_t *pcm_handle;
+ if (pcm_handle) {
+ if (mapping)
+ *mapping = m;
- pa_assert(dev_id);
- pa_assert(dev);
- pa_assert(ss);
- pa_assert(map);
- pa_assert(nfrags);
- pa_assert(period_size);
-
- /* First we try to find a device string with a superset of the
- * requested channel map and open it without the plug: prefix. We
- * iterate through our device table from top to bottom and take
- * the first that matches. If we didn't find a working device that
- * way, we iterate backwards, and check all devices that do not
- * provide a superset of the requested channel map.*/
-
- i = 0;
- for (;;) {
-
- if ((direction > 0) == pa_channel_map_superset(&device_table[i].map, map)) {
- pa_sample_spec try_ss;
-
- pa_log_debug("Checking for %s (%s)", device_table[i].name, device_table[i].alsa_name);
-
- try_ss.channels = device_table[i].map.channels;
- try_ss.rate = ss->rate;
- try_ss.format = ss->format;
-
- pcm_handle = open_by_device_string_with_fallback(
- device_table[i].alsa_name,
- device_table[i].alsa_name_fallback,
- dev_id,
- dev,
- &try_ss,
- map,
- mode,
- nfrags,
- period_size,
- tsched_size,
- use_mmap,
- use_tsched,
- TRUE);
-
- if (pcm_handle) {
-
- *ss = try_ss;
- *map = device_table[i].map;
- pa_assert(map->channels == ss->channels);
-
- if (profile)
- *profile = &device_table[i];
-
- return pcm_handle;
- }
-
- }
-
- if (direction > 0) {
- if (!device_table[i+1].alsa_name) {
- /* OK, so we are at the end of our list. Let's turn
- * back. */
- direction = -1;
- } else {
- /* We are not at the end of the list, so let's simply
- * try the next entry */
- i++;
- }
+ return pcm_handle;
}
+ }
- if (direction < 0) {
-
- if (device_table[i+1].alsa_name &&
- device_table[i].map.channels == device_table[i+1].map.channels) {
-
- /* OK, the next entry has the same number of channels,
- * let's try it */
- i++;
+ PA_HASHMAP_FOREACH_BACKWARDS(m, ps->mappings, state) {
+ if (pa_channel_map_superset(&m->channel_map, map))
+ continue;
- } else {
- /* Hmm, so the next entry does not have the same
- * number of channels, so let's go backwards until we
- * find the next entry with a different number of
- * channels */
+ pa_log_debug("Checking for subset %s (%s)", m->name, m->device_strings[0]);
- for (i--; i >= 0; i--)
- if (device_table[i].map.channels != device_table[i+1].map.channels)
- break;
+ pcm_handle = pa_alsa_open_by_device_id_mapping(
+ dev_id,
+ dev,
+ ss,
+ map,
+ mode,
+ period_size,
+ buffer_size,
+ tsched_size,
+ use_mmap,
+ use_tsched,
+ m);
- /* Hmm, there is no entry with a different number of
- * entries, then we're done */
- if (i < 0)
- break;
+ if (pcm_handle) {
+ if (mapping)
+ *mapping = m;
- /* OK, now lets find go back as long as we have the same number of channels */
- for (; i > 0; i--)
- if (device_table[i].map.channels != device_table[i-1].map.channels)
- break;
- }
+ return pcm_handle;
}
}
- /* OK, we didn't find any good device, so let's try the raw plughw: stuff */
-
+ /* OK, we didn't find any good device, so let's try the raw hw: stuff */
d = pa_sprintf_malloc("hw:%s", dev_id);
pa_log_debug("Trying %s as last resort...", d);
- pcm_handle = pa_alsa_open_by_device_string(d, dev, ss, map, mode, nfrags, period_size, tsched_size, use_mmap, use_tsched, FALSE);
+ pcm_handle = pa_alsa_open_by_device_string(
+ d,
+ dev,
+ ss,
+ map,
+ mode,
+ period_size,
+ buffer_size,
+ tsched_size,
+ use_mmap,
+ use_tsched,
+ FALSE);
pa_xfree(d);
- if (pcm_handle && profile)
- *profile = NULL;
+ if (pcm_handle && mapping)
+ *mapping = NULL;
return pcm_handle;
}
-snd_pcm_t *pa_alsa_open_by_device_id_profile(
+snd_pcm_t *pa_alsa_open_by_device_id_mapping(
const char *dev_id,
char **dev,
pa_sample_spec *ss,
pa_channel_map* map,
int mode,
- uint32_t *nfrags,
snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *buffer_size,
snd_pcm_uframes_t tsched_size,
pa_bool_t *use_mmap,
pa_bool_t *use_tsched,
- const pa_alsa_profile_info *profile) {
+ pa_alsa_mapping *m) {
snd_pcm_t *pcm_handle;
pa_sample_spec try_ss;
+ pa_channel_map try_map;
pa_assert(dev_id);
pa_assert(dev);
pa_assert(ss);
pa_assert(map);
- pa_assert(nfrags);
- pa_assert(period_size);
- pa_assert(profile);
+ pa_assert(m);
- try_ss.channels = profile->map.channels;
+ try_ss.channels = m->channel_map.channels;
try_ss.rate = ss->rate;
try_ss.format = ss->format;
+ try_map = m->channel_map;
- pcm_handle = open_by_device_string_with_fallback(
- profile->alsa_name,
- profile->alsa_name_fallback,
+ pcm_handle = pa_alsa_open_by_template(
+ m->device_strings,
dev_id,
dev,
&try_ss,
- map,
+ &try_map,
mode,
- nfrags,
period_size,
+ buffer_size,
tsched_size,
use_mmap,
use_tsched,
@@ -891,7 +637,7 @@ snd_pcm_t *pa_alsa_open_by_device_id_profile(
return NULL;
*ss = try_ss;
- *map = profile->map;
+ *map = try_map;
pa_assert(map->channels == ss->channels);
return pcm_handle;
@@ -903,8 +649,8 @@ snd_pcm_t *pa_alsa_open_by_device_string(
pa_sample_spec *ss,
pa_channel_map* map,
int mode,
- uint32_t *nfrags,
snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *buffer_size,
snd_pcm_uframes_t tsched_size,
pa_bool_t *use_mmap,
pa_bool_t *use_tsched,
@@ -924,14 +670,8 @@ snd_pcm_t *pa_alsa_open_by_device_string(
for (;;) {
pa_log_debug("Trying %s %s SND_PCM_NO_AUTO_FORMAT ...", d, reformat ? "without" : "with");
- /* We don't pass SND_PCM_NONBLOCK here, since alsa-lib <=
- * 1.0.17a would then ignore the SND_PCM_NO_xxx flags. Instead
- * we enable nonblock mode afterwards via
- * snd_pcm_nonblock(). Also see
- * http://mailman.alsa-project.org/pipermail/alsa-devel/2008-August/010258.html */
-
if ((err = snd_pcm_open(&pcm_handle, d, mode,
- /*SND_PCM_NONBLOCK|*/
+ SND_PCM_NONBLOCK|
SND_PCM_NO_AUTO_RESAMPLE|
SND_PCM_NO_AUTO_CHANNELS|
(reformat ? 0 : SND_PCM_NO_AUTO_FORMAT))) < 0) {
@@ -941,7 +681,15 @@ snd_pcm_t *pa_alsa_open_by_device_string(
pa_log_debug("Managed to open %s", d);
- if ((err = pa_alsa_set_hw_params(pcm_handle, ss, nfrags, period_size, tsched_size, use_mmap, use_tsched, require_exact_channel_number)) < 0) {
+ if ((err = pa_alsa_set_hw_params(
+ pcm_handle,
+ ss,
+ period_size,
+ buffer_size,
+ tsched_size,
+ use_mmap,
+ use_tsched,
+ require_exact_channel_number)) < 0) {
if (!reformat) {
reformat = TRUE;
@@ -951,7 +699,6 @@ snd_pcm_t *pa_alsa_open_by_device_string(
}
/* Hmm, some hw is very exotic, so we retry with plug, if without it didn't work */
-
if (!pa_startswith(d, "plug:") && !pa_startswith(d, "plughw:")) {
char *t;
@@ -988,440 +735,48 @@ fail:
return NULL;
}
-int pa_alsa_probe_profiles(
+snd_pcm_t *pa_alsa_open_by_template(
+ char **template,
const char *dev_id,
- const pa_sample_spec *ss,
- void (*cb)(const pa_alsa_profile_info *sink, const pa_alsa_profile_info *source, void *userdata),
- void *userdata) {
-
- const pa_alsa_profile_info *i;
-
- pa_assert(dev_id);
- pa_assert(ss);
- pa_assert(cb);
-
- /* We try each combination of playback/capture. We also try to
- * open only for capture resp. only for sink. Don't get confused
- * by the trailing entry in device_table we use for this! */
-
- for (i = device_table; i < device_table + PA_ELEMENTSOF(device_table); i++) {
- const pa_alsa_profile_info *j;
- snd_pcm_t *pcm_i = NULL;
-
- if (i->alsa_name) {
- pa_sample_spec try_ss;
- pa_channel_map try_map;
-
- pa_log_debug("Checking for playback on %s (%s)", i->name, i->alsa_name);
-
- try_ss = *ss;
- try_ss.channels = i->map.channels;
- try_map = i->map;
-
- pcm_i = open_by_device_string_with_fallback(
- i->alsa_name,
- i->alsa_name_fallback,
- dev_id,
- NULL,
- &try_ss, &try_map,
- SND_PCM_STREAM_PLAYBACK,
- NULL, NULL, 0, NULL, NULL,
- TRUE);
-
- if (!pcm_i)
- continue;
- }
-
- for (j = device_table; j < device_table + PA_ELEMENTSOF(device_table); j++) {
- snd_pcm_t *pcm_j = NULL;
-
- if (j->alsa_name) {
- pa_sample_spec try_ss;
- pa_channel_map try_map;
-
- pa_log_debug("Checking for capture on %s (%s)", j->name, j->alsa_name);
-
- try_ss = *ss;
- try_ss.channels = j->map.channels;
- try_map = j->map;
-
- pcm_j = open_by_device_string_with_fallback(
- j->alsa_name,
- j->alsa_name_fallback,
- dev_id,
- NULL,
- &try_ss, &try_map,
- SND_PCM_STREAM_CAPTURE,
- NULL, NULL, 0, NULL, NULL,
- TRUE);
-
- if (!pcm_j)
- continue;
- }
-
- if (pcm_j)
- snd_pcm_close(pcm_j);
-
- if (i->alsa_name || j->alsa_name)
- cb(i->alsa_name ? i : NULL,
- j->alsa_name ? j : NULL, userdata);
- }
-
- if (pcm_i)
- snd_pcm_close(pcm_i);
- }
-
- return TRUE;
-}
-
-int pa_alsa_prepare_mixer(snd_mixer_t *mixer, const char *dev) {
- int err;
-
- pa_assert(mixer);
- pa_assert(dev);
-
- if ((err = snd_mixer_attach(mixer, dev)) < 0) {
- pa_log_info("Unable to attach to mixer %s: %s", dev, pa_alsa_strerror(err));
- return -1;
- }
-
- if ((err = snd_mixer_selem_register(mixer, NULL, NULL)) < 0) {
- pa_log_warn("Unable to register mixer: %s", pa_alsa_strerror(err));
- return -1;
- }
-
- if ((err = snd_mixer_load(mixer)) < 0) {
- pa_log_warn("Unable to load mixer: %s", pa_alsa_strerror(err));
- return -1;
- }
-
- pa_log_info("Successfully attached to mixer '%s'", dev);
-
- return 0;
-}
-
-static pa_bool_t elem_has_volume(snd_mixer_elem_t *elem, pa_bool_t playback) {
- pa_assert(elem);
-
- if (playback && snd_mixer_selem_has_playback_volume(elem))
- return TRUE;
-
- if (!playback && snd_mixer_selem_has_capture_volume(elem))
- return TRUE;
-
- return FALSE;
-}
-
-static pa_bool_t elem_has_switch(snd_mixer_elem_t *elem, pa_bool_t playback) {
- pa_assert(elem);
-
- if (playback && snd_mixer_selem_has_playback_switch(elem))
- return TRUE;
-
- if (!playback && snd_mixer_selem_has_capture_switch(elem))
- return TRUE;
-
- return FALSE;
-}
-
-snd_mixer_elem_t *pa_alsa_find_elem(snd_mixer_t *mixer, const char *name, const char *fallback, pa_bool_t playback) {
- snd_mixer_elem_t *elem = NULL, *fallback_elem = NULL;
- snd_mixer_selem_id_t *sid = NULL;
-
- snd_mixer_selem_id_alloca(&sid);
-
- pa_assert(mixer);
- pa_assert(name);
-
- snd_mixer_selem_id_set_name(sid, name);
- snd_mixer_selem_id_set_index(sid, 0);
-
- if ((elem = snd_mixer_find_selem(mixer, sid))) {
-
- if (elem_has_volume(elem, playback) &&
- elem_has_switch(elem, playback))
- goto success;
-
- if (!elem_has_volume(elem, playback) &&
- !elem_has_switch(elem, playback))
- elem = NULL;
- }
-
- pa_log_info("Cannot find mixer control \"%s\" or mixer control is no combination of switch/volume.", snd_mixer_selem_id_get_name(sid));
-
- if (fallback) {
- snd_mixer_selem_id_set_name(sid, fallback);
- snd_mixer_selem_id_set_index(sid, 0);
-
- if ((fallback_elem = snd_mixer_find_selem(mixer, sid))) {
-
- if (elem_has_volume(fallback_elem, playback) &&
- elem_has_switch(fallback_elem, playback)) {
- elem = fallback_elem;
- goto success;
- }
-
- if (!elem_has_volume(fallback_elem, playback) &&
- !elem_has_switch(fallback_elem, playback))
- fallback_elem = NULL;
- }
-
- pa_log_info("Cannot find fallback mixer control \"%s\" or mixer control is no combination of switch/volume.", snd_mixer_selem_id_get_name(sid));
- }
-
- if (elem && fallback_elem) {
-
- /* Hmm, so we have both elements, but neither has both mute
- * and volume. Let's prefer the one with the volume */
-
- if (elem_has_volume(elem, playback))
- goto success;
-
- if (elem_has_volume(fallback_elem, playback)) {
- elem = fallback_elem;
- goto success;
- }
- }
-
- if (!elem && fallback_elem)
- elem = fallback_elem;
-
-success:
-
- if (elem)
- pa_log_info("Using mixer control \"%s\".", snd_mixer_selem_id_get_name(sid));
-
- return elem;
-}
-
-int pa_alsa_find_mixer_and_elem(
- snd_pcm_t *pcm,
- char **ctl_device,
- snd_mixer_t **_m,
- snd_mixer_elem_t **_e,
- const char *control_name,
- const pa_alsa_profile_info *profile) {
-
- int err;
- snd_mixer_t *m;
- snd_mixer_elem_t *e;
- pa_bool_t found = FALSE;
- const char *dev;
-
- pa_assert(pcm);
- pa_assert(_m);
- pa_assert(_e);
-
- if (control_name && *control_name == 0) {
- pa_log_debug("Hardware mixer usage disabled because empty control name passed");
- return -1;
- }
-
- if ((err = snd_mixer_open(&m, 0)) < 0) {
- pa_log("Error opening mixer: %s", pa_alsa_strerror(err));
- return -1;
- }
-
- /* First, try by name */
- if ((dev = snd_pcm_name(pcm)))
- if (pa_alsa_prepare_mixer(m, dev) >= 0) {
- found = TRUE;
-
- if (ctl_device)
- *ctl_device = pa_xstrdup(dev);
- }
-
- /* Then, try by card index */
- if (!found) {
- snd_pcm_info_t* info;
- snd_pcm_info_alloca(&info);
-
- if (snd_pcm_info(pcm, info) >= 0) {
- char *md;
- int card_idx;
-
- if ((card_idx = snd_pcm_info_get_card(info)) >= 0) {
-
- md = pa_sprintf_malloc("hw:%i", card_idx);
-
- if (!dev || !pa_streq(dev, md))
- if (pa_alsa_prepare_mixer(m, md) >= 0) {
- found = TRUE;
-
- if (ctl_device) {
- *ctl_device = md;
- md = NULL;
- }
- }
-
- pa_xfree(md);
- }
- }
- }
-
- if (!found) {
- snd_mixer_close(m);
- return -1;
- }
-
- switch (snd_pcm_stream(pcm)) {
-
- case SND_PCM_STREAM_PLAYBACK:
- if (control_name)
- e = pa_alsa_find_elem(m, control_name, NULL, TRUE);
- else if (profile)
- e = pa_alsa_find_elem(m, profile->playback_control_name, profile->playback_control_fallback, TRUE);
- else
- e = pa_alsa_find_elem(m, "Master", "PCM", TRUE);
- break;
-
- case SND_PCM_STREAM_CAPTURE:
- if (control_name)
- e = pa_alsa_find_elem(m, control_name, NULL, FALSE);
- else if (profile)
- e = pa_alsa_find_elem(m, profile->record_control_name, profile->record_control_fallback, FALSE);
- else
- e = pa_alsa_find_elem(m, "Capture", "Mic", FALSE);
- break;
-
- default:
- pa_assert_not_reached();
- }
-
- if (!e) {
- if (ctl_device)
- pa_xfree(*ctl_device);
-
- snd_mixer_close(m);
- return -1;
- }
-
- pa_assert(e && m);
-
- *_m = m;
- *_e = e;
-
- return 0;
-}
-
-static const snd_mixer_selem_channel_id_t alsa_channel_ids[PA_CHANNEL_POSITION_MAX] = {
- [PA_CHANNEL_POSITION_MONO] = SND_MIXER_SCHN_MONO, /* The ALSA name is just an alias! */
-
- [PA_CHANNEL_POSITION_FRONT_CENTER] = SND_MIXER_SCHN_FRONT_CENTER,
- [PA_CHANNEL_POSITION_FRONT_LEFT] = SND_MIXER_SCHN_FRONT_LEFT,
- [PA_CHANNEL_POSITION_FRONT_RIGHT] = SND_MIXER_SCHN_FRONT_RIGHT,
-
- [PA_CHANNEL_POSITION_REAR_CENTER] = SND_MIXER_SCHN_REAR_CENTER,
- [PA_CHANNEL_POSITION_REAR_LEFT] = SND_MIXER_SCHN_REAR_LEFT,
- [PA_CHANNEL_POSITION_REAR_RIGHT] = SND_MIXER_SCHN_REAR_RIGHT,
-
- [PA_CHANNEL_POSITION_LFE] = SND_MIXER_SCHN_WOOFER,
-
- [PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER] = SND_MIXER_SCHN_UNKNOWN,
-
- [PA_CHANNEL_POSITION_SIDE_LEFT] = SND_MIXER_SCHN_SIDE_LEFT,
- [PA_CHANNEL_POSITION_SIDE_RIGHT] = SND_MIXER_SCHN_SIDE_RIGHT,
-
- [PA_CHANNEL_POSITION_AUX0] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX1] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX2] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX3] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX4] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX5] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX6] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX7] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX8] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX9] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX10] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX11] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX12] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX13] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX14] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX15] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX16] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX17] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX18] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX19] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX20] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX21] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX22] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX23] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX24] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX25] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX26] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX27] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX28] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX29] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX30] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_AUX31] = SND_MIXER_SCHN_UNKNOWN,
-
- [PA_CHANNEL_POSITION_TOP_CENTER] = SND_MIXER_SCHN_UNKNOWN,
-
- [PA_CHANNEL_POSITION_TOP_FRONT_CENTER] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_TOP_FRONT_LEFT] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_TOP_FRONT_RIGHT] = SND_MIXER_SCHN_UNKNOWN,
-
- [PA_CHANNEL_POSITION_TOP_REAR_CENTER] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_TOP_REAR_LEFT] = SND_MIXER_SCHN_UNKNOWN,
- [PA_CHANNEL_POSITION_TOP_REAR_RIGHT] = SND_MIXER_SCHN_UNKNOWN
-};
-
-
-int pa_alsa_calc_mixer_map(snd_mixer_elem_t *elem, const pa_channel_map *channel_map, snd_mixer_selem_channel_id_t mixer_map[], pa_bool_t playback) {
- unsigned i;
- pa_bool_t alsa_channel_used[SND_MIXER_SCHN_LAST];
- pa_bool_t mono_used = FALSE;
-
- pa_assert(elem);
- pa_assert(channel_map);
- pa_assert(mixer_map);
-
- memset(&alsa_channel_used, 0, sizeof(alsa_channel_used));
-
- if (channel_map->channels > 1 &&
- ((playback && snd_mixer_selem_has_playback_volume_joined(elem)) ||
- (!playback && snd_mixer_selem_has_capture_volume_joined(elem)))) {
- pa_log_info("ALSA device lacks independant volume controls for each channel.");
- return -1;
- }
-
- for (i = 0; i < channel_map->channels; i++) {
- snd_mixer_selem_channel_id_t id;
- pa_bool_t is_mono;
+ char **dev,
+ pa_sample_spec *ss,
+ pa_channel_map* map,
+ int mode,
+ snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *buffer_size,
+ snd_pcm_uframes_t tsched_size,
+ pa_bool_t *use_mmap,
+ pa_bool_t *use_tsched,
+ pa_bool_t require_exact_channel_number) {
- is_mono = channel_map->map[i] == PA_CHANNEL_POSITION_MONO;
- id = alsa_channel_ids[channel_map->map[i]];
+ snd_pcm_t *pcm_handle;
+ char **i;
- if (!is_mono && id == SND_MIXER_SCHN_UNKNOWN) {
- pa_log_info("Configured channel map contains channel '%s' that is unknown to the ALSA mixer.", pa_channel_position_to_string(channel_map->map[i]));
- return -1;
- }
+ for (i = template; *i; i++) {
+ char *d;
- if ((is_mono && mono_used) || (!is_mono && alsa_channel_used[id])) {
- pa_log_info("Channel map has duplicate channel '%s', falling back to software volume control.", pa_channel_position_to_string(channel_map->map[i]));
- return -1;
- }
+ d = pa_replace(*i, "%f", dev_id);
- if ((playback && (!snd_mixer_selem_has_playback_channel(elem, id) || (is_mono && !snd_mixer_selem_is_playback_mono(elem)))) ||
- (!playback && (!snd_mixer_selem_has_capture_channel(elem, id) || (is_mono && !snd_mixer_selem_is_capture_mono(elem))))) {
+ pcm_handle = pa_alsa_open_by_device_string(
+ d,
+ dev,
+ ss,
+ map,
+ mode,
+ period_size,
+ buffer_size,
+ tsched_size,
+ use_mmap,
+ use_tsched,
+ require_exact_channel_number);
- pa_log_info("ALSA device lacks separate volumes control for channel '%s'", pa_channel_position_to_string(channel_map->map[i]));
- return -1;
- }
+ pa_xfree(d);
- if (is_mono) {
- mixer_map[i] = SND_MIXER_SCHN_MONO;
- mono_used = TRUE;
- } else {
- mixer_map[i] = id;
- alsa_channel_used[id] = TRUE;
- }
+ if (pcm_handle)
+ return pcm_handle;
}
- pa_log_info("All %u channels can be mapped to mixer channels.", channel_map->channels);
-
- return 0;
+ return NULL;
}
void pa_alsa_dump(pa_log_level_t level, snd_pcm_t *pcm) {
@@ -1447,24 +802,33 @@ void pa_alsa_dump_status(snd_pcm_t *pcm) {
int err;
snd_output_t *out;
snd_pcm_status_t *status;
+ char *s = NULL;
pa_assert(pcm);
snd_pcm_status_alloca(&status);
- pa_assert_se(snd_output_buffer_open(&out) == 0);
+ if ((err = snd_output_buffer_open(&out)) < 0) {
+ pa_log_debug("snd_output_buffer_open() failed: %s", pa_cstrerror(err));
+ return;
+ }
- pa_assert_se(snd_pcm_status(pcm, status) == 0);
+ if ((err = snd_pcm_status(pcm, status)) < 0) {
+ pa_log_debug("snd_pcm_status() failed: %s", pa_cstrerror(err));
+ goto finish;
+ }
- if ((err = snd_pcm_status_dump(status, out)) < 0)
+ if ((err = snd_pcm_status_dump(status, out)) < 0) {
pa_log_debug("snd_pcm_dump(): %s", pa_alsa_strerror(err));
- else {
- char *s = NULL;
- snd_output_buffer_string(out, &s);
- pa_log_debug("snd_pcm_dump():\n%s", pa_strnull(s));
+ goto finish;
}
- pa_assert_se(snd_output_close(out) == 0);
+ snd_output_buffer_string(out, &s);
+ pa_log_debug("snd_pcm_dump():\n%s", pa_strnull(s));
+
+finish:
+
+ snd_output_close(out);
}
static void alsa_error_handler(const char *file, int line, const char *function, int err, const char *fmt,...) {
@@ -1484,38 +848,43 @@ static void alsa_error_handler(const char *file, int line, const char *function,
static pa_atomic_t n_error_handler_installed = PA_ATOMIC_INIT(0);
-void pa_alsa_redirect_errors_inc(void) {
+void pa_alsa_refcnt_inc(void) {
/* This is not really thread safe, but we do our best */
if (pa_atomic_inc(&n_error_handler_installed) == 0)
snd_lib_error_set_handler(alsa_error_handler);
}
-void pa_alsa_redirect_errors_dec(void) {
+void pa_alsa_refcnt_dec(void) {
int r;
pa_assert_se((r = pa_atomic_dec(&n_error_handler_installed)) >= 1);
- if (r == 1)
+ if (r == 1) {
snd_lib_error_set_handler(NULL);
+ snd_config_update_free_global();
+ }
}
pa_bool_t pa_alsa_init_description(pa_proplist *p) {
- const char *s;
+ const char *d, *k;
pa_assert(p);
if (pa_device_init_description(p))
return TRUE;
- if ((s = pa_proplist_gets(p, "alsa.card_name"))) {
- pa_proplist_sets(p, PA_PROP_DEVICE_DESCRIPTION, s);
- return TRUE;
- }
+ if (!(d = pa_proplist_gets(p, "alsa.card_name")))
+ d = pa_proplist_gets(p, "alsa.name");
- if ((s = pa_proplist_gets(p, "alsa.name"))) {
- pa_proplist_sets(p, PA_PROP_DEVICE_DESCRIPTION, s);
- return TRUE;
- }
+ if (!d)
+ return FALSE;
+
+ k = pa_proplist_gets(p, PA_PROP_DEVICE_PROFILE_DESCRIPTION);
+
+ if (d && k)
+ pa_proplist_setf(p, PA_PROP_DEVICE_DESCRIPTION, _("%s %s"), d, k);
+ else if (d)
+ pa_proplist_sets(p, PA_PROP_DEVICE_DESCRIPTION, d);
return FALSE;
}
@@ -1529,12 +898,12 @@ void pa_alsa_init_proplist_card(pa_core *c, pa_proplist *p, int card) {
pa_proplist_setf(p, "alsa.card", "%i", card);
if (snd_card_get_name(card, &cn) >= 0) {
- pa_proplist_sets(p, "alsa.card_name", cn);
+ pa_proplist_sets(p, "alsa.card_name", pa_strip(cn));
free(cn);
}
if (snd_card_get_longname(card, &lcn) >= 0) {
- pa_proplist_sets(p, "alsa.long_card_name", lcn);
+ pa_proplist_sets(p, "alsa.long_card_name", pa_strip(lcn));
free(lcn);
}
@@ -1544,7 +913,7 @@ void pa_alsa_init_proplist_card(pa_core *c, pa_proplist *p, int card) {
}
#ifdef HAVE_UDEV
- pa_udev_get_info(c, p, card);
+ pa_udev_get_info(card, p);
#endif
#ifdef HAVE_HAL
@@ -1581,21 +950,22 @@ void pa_alsa_init_proplist_pcm_info(pa_core *c, pa_proplist *p, snd_pcm_info_t *
pa_proplist_sets(p, PA_PROP_DEVICE_API, "alsa");
- class = snd_pcm_info_get_class(pcm_info);
- if (class <= SND_PCM_CLASS_LAST) {
+ if ((class = snd_pcm_info_get_class(pcm_info)) <= SND_PCM_CLASS_LAST) {
if (class_table[class])
pa_proplist_sets(p, PA_PROP_DEVICE_CLASS, class_table[class]);
if (alsa_class_table[class])
pa_proplist_sets(p, "alsa.class", alsa_class_table[class]);
}
- subclass = snd_pcm_info_get_subclass(pcm_info);
- if (subclass <= SND_PCM_SUBCLASS_LAST)
+ if ((subclass = snd_pcm_info_get_subclass(pcm_info)) <= SND_PCM_SUBCLASS_LAST)
if (alsa_subclass_table[subclass])
pa_proplist_sets(p, "alsa.subclass", alsa_subclass_table[subclass]);
- if ((n = snd_pcm_info_get_name(pcm_info)))
- pa_proplist_sets(p, "alsa.name", n);
+ if ((n = snd_pcm_info_get_name(pcm_info))) {
+ char *t = pa_xstrdup(n);
+ pa_proplist_sets(p, "alsa.name", pa_strip(t));
+ pa_xfree(t);
+ }
if ((id = snd_pcm_info_get_id(pcm_info)))
pa_proplist_sets(p, "alsa.id", id);
@@ -1610,7 +980,7 @@ void pa_alsa_init_proplist_pcm_info(pa_core *c, pa_proplist *p, snd_pcm_info_t *
pa_alsa_init_proplist_card(c, p, card);
}
-void pa_alsa_init_proplist_pcm(pa_core *c, pa_proplist *p, snd_pcm_t *pcm, snd_mixer_elem_t *elem) {
+void pa_alsa_init_proplist_pcm(pa_core *c, pa_proplist *p, snd_pcm_t *pcm) {
snd_pcm_hw_params_t *hwparams;
snd_pcm_info_t *info;
int bits, err;
@@ -1626,9 +996,6 @@ void pa_alsa_init_proplist_pcm(pa_core *c, pa_proplist *p, snd_pcm_t *pcm, snd_m
pa_proplist_setf(p, "alsa.resolution_bits", "%i", bits);
}
- if (elem)
- pa_proplist_sets(p, "alsa.mixer_element", snd_mixer_selem_get_name(elem));
-
if ((err = snd_pcm_info(pcm, info)) < 0)
pa_log_warn("Error fetching PCM info: %s", pa_alsa_strerror(err));
else
@@ -1646,7 +1013,7 @@ void pa_alsa_init_proplist_ctl(pa_proplist *p, const char *name) {
snd_ctl_card_info_alloca(&info);
if ((err = snd_ctl_open(&ctl, name, 0)) < 0) {
- pa_log_warn("Error opening low-level control device '%s'", name);
+ pa_log_warn("Error opening low-level control device '%s': %s", name, snd_strerror(err));
return;
}
@@ -1656,10 +1023,10 @@ void pa_alsa_init_proplist_ctl(pa_proplist *p, const char *name) {
return;
}
- if ((t = snd_ctl_card_info_get_mixername(info)))
+ if ((t = snd_ctl_card_info_get_mixername(info)) && *t)
pa_proplist_sets(p, "alsa.mixer_name", t);
- if ((t = snd_ctl_card_info_get_components(info)))
+ if ((t = snd_ctl_card_info_get_components(info)) && *t)
pa_proplist_sets(p, "alsa.components", t);
snd_ctl_close(ctl);
@@ -1761,8 +1128,8 @@ snd_pcm_sframes_t pa_alsa_safe_avail(snd_pcm_t *pcm, size_t hwbuf_size, const pa
k = (size_t) n * pa_frame_size(ss);
- if (k >= hwbuf_size * 5 ||
- k >= pa_bytes_per_second(ss)*10) {
+ if (PA_UNLIKELY(k >= hwbuf_size * 5 ||
+ k >= pa_bytes_per_second(ss)*10)) {
PA_ONCE_BEGIN {
char *dn = pa_alsa_get_driver_name_by_pcm(pcm);
@@ -1782,10 +1149,11 @@ snd_pcm_sframes_t pa_alsa_safe_avail(snd_pcm_t *pcm, size_t hwbuf_size, const pa
return n;
}
-int pa_alsa_safe_delay(snd_pcm_t *pcm, snd_pcm_sframes_t *delay, size_t hwbuf_size, const pa_sample_spec *ss) {
+int pa_alsa_safe_delay(snd_pcm_t *pcm, snd_pcm_sframes_t *delay, size_t hwbuf_size, const pa_sample_spec *ss, pa_bool_t capture) {
ssize_t k;
size_t abs_k;
int r;
+ snd_pcm_sframes_t avail = 0;
pa_assert(pcm);
pa_assert(delay);
@@ -1793,17 +1161,18 @@ int pa_alsa_safe_delay(snd_pcm_t *pcm, snd_pcm_sframes_t *delay, size_t hwbuf_si
pa_assert(ss);
/* Some ALSA driver expose weird bugs, let's inform the user about
- * what is going on */
+ * what is going on. We're going to get both the avail and delay values so
+ * that we can compare and check them for capture */
- if ((r = snd_pcm_delay(pcm, delay)) < 0)
+ if ((r = snd_pcm_avail_delay(pcm, &avail, delay)) < 0)
return r;
k = (ssize_t) *delay * (ssize_t) pa_frame_size(ss);
abs_k = k >= 0 ? (size_t) k : (size_t) -k;
- if (abs_k >= hwbuf_size * 5 ||
- abs_k >= pa_bytes_per_second(ss)*10) {
+ if (PA_UNLIKELY(abs_k >= hwbuf_size * 5 ||
+ abs_k >= pa_bytes_per_second(ss)*10)) {
PA_ONCE_BEGIN {
char *dn = pa_alsa_get_driver_name_by_pcm(pcm);
@@ -1824,6 +1193,44 @@ int pa_alsa_safe_delay(snd_pcm_t *pcm, snd_pcm_sframes_t *delay, size_t hwbuf_si
*delay = (snd_pcm_sframes_t) (hwbuf_size / pa_frame_size(ss));
}
+ if (capture) {
+ abs_k = (size_t) avail * pa_frame_size(ss);
+
+ if (PA_UNLIKELY(abs_k >= hwbuf_size * 5 ||
+ abs_k >= pa_bytes_per_second(ss)*10)) {
+
+ PA_ONCE_BEGIN {
+ char *dn = pa_alsa_get_driver_name_by_pcm(pcm);
+ pa_log(_("snd_pcm_avail() returned a value that is exceptionally large: %lu bytes (%lu ms).\n"
+ "Most likely this is a bug in the ALSA driver '%s'. Please report this issue to the ALSA developers."),
+ (unsigned long) k,
+ (unsigned long) (pa_bytes_to_usec(k, ss) / PA_USEC_PER_MSEC),
+ pa_strnull(dn));
+ pa_xfree(dn);
+ pa_alsa_dump(PA_LOG_ERROR, pcm);
+ } PA_ONCE_END;
+
+ /* Mhmm, let's try not to fail completely */
+ avail = (snd_pcm_sframes_t) (hwbuf_size / pa_frame_size(ss));
+ }
+
+ if (PA_UNLIKELY(*delay < avail)) {
+ PA_ONCE_BEGIN {
+ char *dn = pa_alsa_get_driver_name_by_pcm(pcm);
+ pa_log(_("snd_pcm_avail_delay() returned strange values: delay %lu is less than avail %lu.\n"
+ "Most likely this is a bug in the ALSA driver '%s'. Please report this issue to the ALSA developers."),
+ (unsigned long) *delay,
+ (unsigned long) avail,
+ pa_strnull(dn));
+ pa_xfree(dn);
+ pa_alsa_dump(PA_LOG_ERROR, pcm);
+ } PA_ONCE_END;
+
+ /* try to fixup */
+ *delay = avail;
+ }
+ }
+
return 0;
}
@@ -1848,10 +1255,9 @@ int pa_alsa_safe_mmap_begin(snd_pcm_t *pcm, const snd_pcm_channel_area_t **areas
k = (size_t) *frames * pa_frame_size(ss);
- if (*frames > before ||
- k >= hwbuf_size * 3 ||
- k >= pa_bytes_per_second(ss)*10)
-
+ if (PA_UNLIKELY(*frames > before ||
+ k >= hwbuf_size * 3 ||
+ k >= pa_bytes_per_second(ss)*10))
PA_ONCE_BEGIN {
char *dn = pa_alsa_get_driver_name_by_pcm(pcm);
pa_log(_("snd_pcm_mmap_begin() returned a value that is exceptionally large: %lu bytes (%lu ms).\n"
@@ -1971,3 +1377,25 @@ const char* pa_alsa_strerror(int errnum) {
return translated;
}
+
+pa_bool_t pa_alsa_may_tsched(pa_bool_t want) {
+
+ if (!want)
+ return FALSE;
+
+ if (!pa_rtclock_hrtimer()) {
+ /* We cannot depend on being woken up in time when the timers
+ are inaccurate, so let's fallback to classic IO based playback
+ then. */
+ pa_log_notice("Disabling timer-based scheduling because high-resolution timers are not available from the kernel.");
+ return FALSE; }
+
+ if (pa_running_in_vm()) {
+ /* We cannot depend on being woken up when we ask for in a VM,
+ * so let's fallback to classic IO based playback then. */
+ pa_log_notice("Disabling timer-based scheduling because running inside a VM.");
+ return FALSE;
+ }
+
+ return TRUE;
+}
diff --git a/src/modules/alsa/alsa-util.h b/src/modules/alsa/alsa-util.h
index 27f43712..ee5e781e 100644
--- a/src/modules/alsa/alsa-util.h
+++ b/src/modules/alsa/alsa-util.h
@@ -26,8 +26,6 @@
#include <asoundlib.h>
#include <pulse/sample.h>
-#include <pulse/volume.h>
-#include <pulse/mainloop-api.h>
#include <pulse/channelmap.h>
#include <pulse/proplist.h>
@@ -35,100 +33,91 @@
#include <pulsecore/core.h>
#include <pulsecore/log.h>
-typedef struct pa_alsa_fdlist pa_alsa_fdlist;
-
-struct pa_alsa_fdlist *pa_alsa_fdlist_new(void);
-void pa_alsa_fdlist_free(struct pa_alsa_fdlist *fdl);
-int pa_alsa_fdlist_set_mixer(struct pa_alsa_fdlist *fdl, snd_mixer_t *mixer_handle, pa_mainloop_api* m);
+#include "alsa-mixer.h"
int pa_alsa_set_hw_params(
snd_pcm_t *pcm_handle,
- pa_sample_spec *ss,
- uint32_t *periods,
- snd_pcm_uframes_t *period_size,
+ pa_sample_spec *ss, /* modified at return */
+ snd_pcm_uframes_t *period_size, /* modified at return */
+ snd_pcm_uframes_t *buffer_size, /* modified at return */
snd_pcm_uframes_t tsched_size,
- pa_bool_t *use_mmap,
- pa_bool_t *use_tsched,
+ pa_bool_t *use_mmap, /* modified at return */
+ pa_bool_t *use_tsched, /* modified at return */
pa_bool_t require_exact_channel_number);
-int pa_alsa_set_sw_params(snd_pcm_t *pcm, snd_pcm_uframes_t avail_min);
-
-typedef struct pa_alsa_profile_info {
- pa_channel_map map;
- const char *alsa_name;
- const char *alsa_name_fallback;
- const char *description; /* internationalized */
- const char *name;
- unsigned priority;
- const char *playback_control_name, *playback_control_fallback;
- const char *record_control_name, *record_control_fallback;
-} pa_alsa_profile_info;
+int pa_alsa_set_sw_params(
+ snd_pcm_t *pcm,
+ snd_pcm_uframes_t avail_min,
+ pa_bool_t period_event);
-int pa_alsa_prepare_mixer(snd_mixer_t *mixer, const char *dev);
-snd_mixer_elem_t *pa_alsa_find_elem(snd_mixer_t *mixer, const char *name, const char *fallback, pa_bool_t playback);
-int pa_alsa_find_mixer_and_elem(snd_pcm_t *pcm, char **ctl_device, snd_mixer_t **_m, snd_mixer_elem_t **_e, const char *control_name, const pa_alsa_profile_info*profile);
-
-void pa_alsa_init_proplist_ctl(pa_proplist *p, const char *name);
-
-/* Picks a working profile based on the specified ss/map */
+/* Picks a working mapping from the profile set based on the specified ss/map */
snd_pcm_t *pa_alsa_open_by_device_id_auto(
const char *dev_id,
- char **dev,
- pa_sample_spec *ss,
- pa_channel_map* map,
+ char **dev, /* modified at return */
+ pa_sample_spec *ss, /* modified at return */
+ pa_channel_map* map, /* modified at return */
int mode,
- uint32_t *nfrags,
- snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *period_size, /* modified at return */
+ snd_pcm_uframes_t *buffer_size, /* modified at return */
snd_pcm_uframes_t tsched_size,
- pa_bool_t *use_mmap,
- pa_bool_t *use_tsched,
- const pa_alsa_profile_info **profile);
+ pa_bool_t *use_mmap, /* modified at return */
+ pa_bool_t *use_tsched, /* modified at return */
+ pa_alsa_profile_set *ps,
+ pa_alsa_mapping **mapping); /* modified at return */
-/* Uses the specified profile */
-snd_pcm_t *pa_alsa_open_by_device_id_profile(
+/* Uses the specified mapping */
+snd_pcm_t *pa_alsa_open_by_device_id_mapping(
const char *dev_id,
- char **dev,
- pa_sample_spec *ss,
- pa_channel_map* map,
+ char **dev, /* modified at return */
+ pa_sample_spec *ss, /* modified at return */
+ pa_channel_map* map, /* modified at return */
int mode,
- uint32_t *nfrags,
- snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *period_size, /* modified at return */
+ snd_pcm_uframes_t *buffer_size, /* modified at return */
snd_pcm_uframes_t tsched_size,
- pa_bool_t *use_mmap,
- pa_bool_t *use_tsched,
- const pa_alsa_profile_info *profile);
+ pa_bool_t *use_mmap, /* modified at return */
+ pa_bool_t *use_tsched, /* modified at return */
+ pa_alsa_mapping *mapping);
/* Opens the explicit ALSA device */
snd_pcm_t *pa_alsa_open_by_device_string(
- const char *device,
- char **dev,
- pa_sample_spec *ss,
- pa_channel_map* map,
+ const char *dir,
+ char **dev, /* modified at return */
+ pa_sample_spec *ss, /* modified at return */
+ pa_channel_map* map, /* modified at return */
int mode,
- uint32_t *nfrags,
- snd_pcm_uframes_t *period_size,
+ snd_pcm_uframes_t *period_size, /* modified at return */
+ snd_pcm_uframes_t *buffer_size, /* modified at return */
snd_pcm_uframes_t tsched_size,
- pa_bool_t *use_mmap,
- pa_bool_t *use_tsched,
+ pa_bool_t *use_mmap, /* modified at return */
+ pa_bool_t *use_tsched, /* modified at return */
pa_bool_t require_exact_channel_number);
-int pa_alsa_probe_profiles(
+/* Opens the explicit ALSA device with a fallback list */
+snd_pcm_t *pa_alsa_open_by_template(
+ char **template,
const char *dev_id,
- const pa_sample_spec *ss,
- void (*cb)(const pa_alsa_profile_info *sink, const pa_alsa_profile_info *source, void *userdata),
- void *userdata);
-
-int pa_alsa_calc_mixer_map(snd_mixer_elem_t *elem, const pa_channel_map *channel_map, snd_mixer_selem_channel_id_t mixer_map[], pa_bool_t playback);
+ char **dev, /* modified at return */
+ pa_sample_spec *ss, /* modified at return */
+ pa_channel_map* map, /* modified at return */
+ int mode,
+ snd_pcm_uframes_t *period_size, /* modified at return */
+ snd_pcm_uframes_t *buffer_size, /* modified at return */
+ snd_pcm_uframes_t tsched_size,
+ pa_bool_t *use_mmap, /* modified at return */
+ pa_bool_t *use_tsched, /* modified at return */
+ pa_bool_t require_exact_channel_number);
void pa_alsa_dump(pa_log_level_t level, snd_pcm_t *pcm);
void pa_alsa_dump_status(snd_pcm_t *pcm);
-void pa_alsa_redirect_errors_inc(void);
-void pa_alsa_redirect_errors_dec(void);
+void pa_alsa_refcnt_inc(void);
+void pa_alsa_refcnt_dec(void);
void pa_alsa_init_proplist_pcm_info(pa_core *c, pa_proplist *p, snd_pcm_info_t *pcm_info);
void pa_alsa_init_proplist_card(pa_core *c, pa_proplist *p, int card);
-void pa_alsa_init_proplist_pcm(pa_core *c, pa_proplist *p, snd_pcm_t *pcm, snd_mixer_elem_t *elem);
+void pa_alsa_init_proplist_pcm(pa_core *c, pa_proplist *p, snd_pcm_t *pcm);
+void pa_alsa_init_proplist_ctl(pa_proplist *p, const char *name);
pa_bool_t pa_alsa_init_description(pa_proplist *p);
int pa_alsa_recover_from_poll(snd_pcm_t *pcm, int revents);
@@ -136,19 +125,19 @@ int pa_alsa_recover_from_poll(snd_pcm_t *pcm, int revents);
pa_rtpoll_item* pa_alsa_build_pollfd(snd_pcm_t *pcm, pa_rtpoll *rtpoll);
snd_pcm_sframes_t pa_alsa_safe_avail(snd_pcm_t *pcm, size_t hwbuf_size, const pa_sample_spec *ss);
-int pa_alsa_safe_delay(snd_pcm_t *pcm, snd_pcm_sframes_t *delay, size_t hwbuf_size, const pa_sample_spec *ss);
+int pa_alsa_safe_delay(snd_pcm_t *pcm, snd_pcm_sframes_t *delay, size_t hwbuf_size, const pa_sample_spec *ss, pa_bool_t capture);
int pa_alsa_safe_mmap_begin(snd_pcm_t *pcm, const snd_pcm_channel_area_t **areas, snd_pcm_uframes_t *offset, snd_pcm_uframes_t *frames, size_t hwbuf_size, const pa_sample_spec *ss);
char *pa_alsa_get_driver_name(int card);
-
char *pa_alsa_get_driver_name_by_pcm(snd_pcm_t *pcm);
char *pa_alsa_get_reserve_name(const char *device);
pa_bool_t pa_alsa_pcm_is_hw(snd_pcm_t *pcm);
-
pa_bool_t pa_alsa_pcm_is_modem(snd_pcm_t *pcm);
const char* pa_alsa_strerror(int errnum);
+pa_bool_t pa_alsa_may_tsched(pa_bool_t want);
+
#endif
diff --git a/src/modules/alsa/mixer/paths/analog-input-aux.conf b/src/modules/alsa/mixer/paths/analog-input-aux.conf
new file mode 100644
index 00000000..3a7cb7b2
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-aux.conf
@@ -0,0 +1,66 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where an 'Aux' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 90
+name = analog-input
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Line]
+switch = off
+volume = off
+
+[Element Aux]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Video]
+switch = off
+volume = off
+
+[Element Mic/Line]
+switch = off
+volume = off
+
+[Element TV Tuner]
+switch = off
+volume = off
+
+[Element FM]
+switch = off
+volume = off
+
+.include analog-input.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-dock-mic.conf b/src/modules/alsa/mixer/paths/analog-input-dock-mic.conf
new file mode 100644
index 00000000..74826a96
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-dock-mic.conf
@@ -0,0 +1,81 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Dock Mic' or 'Dock Mic Boost' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 80
+name = analog-input-microphone-dock
+
+[Element Dock Mic Boost]
+required-any = any
+switch = select
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Option Dock Mic Boost:on]
+name = input-boost-on
+
+[Option Dock Mic Boost:off]
+name = input-boost-off
+
+[Element Dock Mic]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Input Source]
+enumeration = select
+
+[Option Input Source:Dock Mic]
+name = analog-input-microphone-dock
+required-any = any
+
+[Element Capture Source]
+enumeration = select
+
+[Option Capture Source:Dock Mic]
+name = analog-input-microphone-dock
+required-any = any
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Front Mic]
+switch = off
+volume = off
+
+[Element Rear Mic]
+switch = off
+volume = off
+
+.include analog-input-mic.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-fm.conf b/src/modules/alsa/mixer/paths/analog-input-fm.conf
new file mode 100644
index 00000000..7f150e36
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-fm.conf
@@ -0,0 +1,66 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where an 'FM' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 70
+name = analog-input-radio
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Line]
+switch = off
+volume = off
+
+[Element Aux]
+switch = off
+volume = off
+
+[Element Video]
+switch = off
+volume = off
+
+[Element Mic/Line]
+switch = off
+volume = off
+
+[Element TV Tuner]
+switch = off
+volume = off
+
+[Element FM]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+.include analog-input.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-front-mic.conf b/src/modules/alsa/mixer/paths/analog-input-front-mic.conf
new file mode 100644
index 00000000..6c58ece1
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-front-mic.conf
@@ -0,0 +1,81 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Front Mic' or 'Front Mic Boost' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 90
+name = analog-input-microphone-front
+
+[Element Front Mic Boost]
+required-any = any
+switch = select
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Option Front Mic Boost:on]
+name = input-boost-on
+
+[Option Front Mic Boost:off]
+name = input-boost-off
+
+[Element Front Mic]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Input Source]
+enumeration = select
+
+[Option Input Source:Front Mic]
+name = analog-input-microphone-front
+required-any = any
+
+[Element Capture Source]
+enumeration = select
+
+[Option Capture Source:Front Mic]
+name = analog-input-microphone-front
+required-any = any
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Rear Mic]
+switch = off
+volume = off
+
+[Element Dock Mic]
+switch = off
+volume = off
+
+.include analog-input-mic.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-internal-mic.conf b/src/modules/alsa/mixer/paths/analog-input-internal-mic.conf
new file mode 100644
index 00000000..70a1cd12
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-internal-mic.conf
@@ -0,0 +1,111 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Internal Mic' or 'Internal Mic Boost' element exists
+; 'Int Mic' and 'Int Mic Boost' are for compatibility with kernels < 2.6.38
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 89
+name = analog-input-microphone-internal
+
+[Element Internal Mic Boost]
+required-any = any
+switch = select
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Option Internal Mic Boost:on]
+name = input-boost-on
+
+[Option Internal Mic Boost:off]
+name = input-boost-off
+
+[Element Int Mic Boost]
+required-any = any
+switch = select
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Option Int Mic Boost:on]
+name = input-boost-on
+
+[Option Int Mic Boost:off]
+name = input-boost-off
+
+
+[Element Internal Mic]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Int Mic]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Input Source]
+enumeration = select
+
+[Option Input Source:Internal Mic]
+name = analog-input-microphone-internal
+required-any = any
+
+[Option Input Source:Int Mic]
+name = analog-input-microphone-internal
+required-any = any
+
+[Element Capture Source]
+enumeration = select
+
+[Option Capture Source:Internal Mic]
+name = analog-input-microphone-internal
+required-any = any
+
+[Option Capture Source:Int Mic]
+name = analog-input-microphone-internal
+required-any = any
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Dock Mic]
+switch = off
+volume = off
+
+[Element Front Mic]
+switch = off
+volume = off
+
+[Element Rear Mic]
+switch = off
+volume = off
+
+.include analog-input-mic.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-linein.conf b/src/modules/alsa/mixer/paths/analog-input-linein.conf
new file mode 100644
index 00000000..461cebdb
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-linein.conf
@@ -0,0 +1,93 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Line' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 90
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Line Boost]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Line]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Input Source]
+enumeration = select
+
+[Option Input Source:Line]
+name = analog-input-linein
+required-any = any
+
+[Element Capture Source]
+enumeration = select
+
+[Option Capture Source:Line]
+name = analog-input-linein
+required-any = any
+
+
+[Element Aux]
+switch = off
+volume = off
+
+[Element Video]
+switch = off
+volume = off
+
+[Element Mic/Line]
+switch = off
+volume = off
+
+[Element TV Tuner]
+switch = off
+volume = off
+
+[Element FM]
+switch = off
+volume = off
+
+[Element Mic Jack Mode]
+enumeration = select
+
+[Option Mic Jack Mode:Line In]
+priority = 19
+required-any = any
+name = input-linein
diff --git a/src/modules/alsa/mixer/paths/analog-input-mic-line.conf b/src/modules/alsa/mixer/paths/analog-input-mic-line.conf
new file mode 100644
index 00000000..fa680aab
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-mic-line.conf
@@ -0,0 +1,67 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Mic/Line' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 90
+name = analog-input
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Line]
+switch = off
+volume = off
+
+[Element Aux]
+switch = off
+volume = off
+
+[Element Video]
+switch = off
+volume = off
+
+[Element Mic/Line]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element TV Tuner]
+switch = off
+volume = off
+
+[Element FM]
+switch = off
+volume = off
+
+.include analog-input.conf.common
+.include analog-input-mic.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-mic.conf b/src/modules/alsa/mixer/paths/analog-input-mic.conf
new file mode 100644
index 00000000..d88028bf
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-mic.conf
@@ -0,0 +1,104 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Mic' or 'Mic Boost' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 89
+name = analog-input-microphone
+
+[Element Mic Boost]
+required-any = any
+switch = select
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Option Mic Boost:on]
+name = input-boost-on
+
+[Option Mic Boost:off]
+name = input-boost-off
+
+[Element Mic]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Input Source]
+enumeration = select
+
+[Option Input Source:Mic]
+name = analog-input-microphone
+required-any = any
+
+[Element Capture Source]
+enumeration = select
+
+[Option Capture Source:Mic]
+name = analog-input-microphone
+required-any = any
+
+;;; Some AC'97s have "Mic Select" and "Mic Boost (+20dB)"
+
+[Element Mic Select]
+enumeration = select
+
+[Option Mic Select:Mic1]
+name = input-microphone
+priority = 20
+
+[Option Mic Select:Mic2]
+name = input-microphone
+priority = 19
+
+[Element Mic Boost (+20dB)]
+switch = select
+volume = merge
+
+[Option Mic Boost (+20dB):on]
+name = input-boost-on
+
+[Option Mic Boost (+20dB):off]
+name = input-boost-off
+
+[Element Front Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Rear Mic]
+switch = off
+volume = off
+
+[Element Dock Mic]
+switch = off
+volume = off
+
+.include analog-input-mic.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-mic.conf.common b/src/modules/alsa/mixer/paths/analog-input-mic.conf.common
new file mode 100644
index 00000000..2e4f0d81
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-mic.conf.common
@@ -0,0 +1,54 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Common element for all microphone inputs
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[Element Line]
+switch = off
+volume = off
+
+[Element Line Boost]
+switch = off
+volume = off
+
+[Element Aux]
+switch = off
+volume = off
+
+[Element Video]
+switch = off
+volume = off
+
+[Element Mic/Line]
+switch = off
+volume = off
+
+[Element TV Tuner]
+switch = off
+volume = off
+
+[Element FM]
+switch = off
+volume = off
+
+[Element Mic Jack Mode]
+enumeration = select
+
+[Option Mic Jack Mode:Mic In]
+priority = 19
+name = input-microphone
diff --git a/src/modules/alsa/mixer/paths/analog-input-rear-mic.conf b/src/modules/alsa/mixer/paths/analog-input-rear-mic.conf
new file mode 100644
index 00000000..75ed61b0
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-rear-mic.conf
@@ -0,0 +1,81 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Rear Mic' or 'Rear Mic Boost' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 89
+name = analog-input-microphone-rear
+
+[Element Rear Mic Boost]
+required-any = any
+switch = select
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Option Rear Mic Boost:on]
+name = input-boost-on
+
+[Option Rear Mic Boost:off]
+name = input-boost-off
+
+[Element Rear Mic]
+required-any = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Input Source]
+enumeration = select
+
+[Option Input Source:Rear Mic]
+name = analog-input-microphone-rear
+required-any = any
+
+[Element Capture Source]
+enumeration = select
+
+[Option Capture Source:Rear Mic]
+name = analog-input-microphone-rear
+required-any = any
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Front Mic]
+switch = off
+volume = off
+
+[Element Dock Mic]
+switch = off
+volume = off
+
+.include analog-input-mic.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-tvtuner.conf b/src/modules/alsa/mixer/paths/analog-input-tvtuner.conf
new file mode 100644
index 00000000..fae3ce83
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-tvtuner.conf
@@ -0,0 +1,66 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'TV Tuner' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 70
+name = analog-input-video
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Line]
+switch = off
+volume = off
+
+[Element Aux]
+switch = off
+volume = off
+
+[Element Video]
+switch = off
+volume = off
+
+[Element Mic/Line]
+switch = off
+volume = off
+
+[Element TV Tuner]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element FM]
+switch = off
+volume = off
+
+.include analog-input.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input-video.conf b/src/modules/alsa/mixer/paths/analog-input-video.conf
new file mode 100644
index 00000000..19f18099
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input-video.conf
@@ -0,0 +1,65 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; For devices where a 'Video' element exists
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 70
+
+[Element Capture]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic]
+switch = off
+volume = off
+
+[Element Internal Mic]
+switch = off
+volume = off
+
+[Element Line]
+switch = off
+volume = off
+
+[Element Aux]
+switch = off
+volume = off
+
+[Element Video]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic/Line]
+switch = off
+volume = off
+
+[Element TV Tuner]
+switch = off
+volume = off
+
+[Element FM]
+switch = off
+volume = off
+
+.include analog-input.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input.conf b/src/modules/alsa/mixer/paths/analog-input.conf
new file mode 100644
index 00000000..b86c3564
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input.conf
@@ -0,0 +1,83 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; A fallback for devices that lack seperate Mic/Line/Aux/Video/TV
+; Tuner/FM elements
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 100
+
+[Element Capture]
+required = volume
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Mic]
+required-absent = any
+
+[Element Dock Mic]
+required-absent = any
+
+[Element Dock Mic Boost]
+required-absent = any
+
+[Element Front Mic]
+required-absent = any
+
+[Element Front Mic Boost]
+required-absent = any
+
+[Element Int Mic]
+required-absent = any
+
+[Element Int Mic Boost]
+required-absent = any
+
+[Element Internal Mic]
+required-absent = any
+
+[Element Internal Mic Boost]
+required-absent = any
+
+[Element Rear Mic]
+required-absent = any
+
+[Element Rear Mic Boost]
+required-absent = any
+
+[Element Line]
+required-absent = any
+
+[Element Aux]
+required-absent = any
+
+[Element Video]
+required-absent = any
+
+[Element Mic/Line]
+required-absent = any
+
+[Element TV Tuner]
+required-absent = any
+
+[Element FM]
+required-absent = any
+
+.include analog-input.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-input.conf.common b/src/modules/alsa/mixer/paths/analog-input.conf.common
new file mode 100644
index 00000000..94165776
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-input.conf.common
@@ -0,0 +1,290 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Mixer path for PulseAudio's ALSA backend, common elements for all
+; input paths. If multiple options by the same id are discovered they
+; will be suffixed with a number to distuingish them, in the same
+; order they appear here.
+;
+; Source selection should use the following names:
+;
+; input -- If we don't know the exact kind of input
+; input-microphone
+; input-microphone-internal
+; input-microphone-external
+; input-linein
+; input-video
+; input-radio
+; input-docking-microphone
+; input-docking-linein
+; input-docking
+;
+; We explicitly don't want to wrap the following sources:
+;
+; CD
+; Synth/MIDI
+; Phone
+; Mix
+; Digital/SPDIF
+; Master
+; PC Speaker
+;
+; See analog-output.conf.common for an explanation on the directives
+
+;;; 'Input Source Select'
+
+[Element Input Source Select]
+enumeration = select
+
+[Option Input Source Select:Input1]
+name = input
+priority = 10
+
+[Option Input Source Select:Input2]
+name = input
+priority = 5
+
+;;; 'Input Source'
+
+[Element Input Source]
+enumeration = select
+
+[Option Input Source:Digital Mic]
+name = input-microphone
+priority = 20
+
+[Option Input Source:Microphone]
+name = input-microphone
+priority = 20
+
+[Option Input Source:Front Microphone]
+name = input-microphone
+priority = 19
+
+[Option Input Source:Internal Mic 1]
+name = input-microphone
+priority = 19
+
+[Option Input Source:Line-In]
+name = input-linein
+priority = 18
+
+[Option Input Source:Line In]
+name = input-linein
+priority = 18
+
+[Option Input Source:Docking-Station]
+name = input-docking
+priority = 17
+
+[Option Input Source:AUX IN]
+name = input
+priority = 10
+
+;;; 'Capture Source'
+
+[Element Capture Source]
+enumeration = select
+
+[Option Capture Source:TV Tuner]
+name = input-video
+
+[Option Capture Source:FM]
+name = input-radio
+
+[Option Capture Source:Mic/Line]
+name = input
+
+[Option Capture Source:Line/Mic]
+name = input
+
+[Option Capture Source:Microphone]
+name = input-microphone
+
+[Option Capture Source:Int DMic]
+name = input-microphone-internal
+
+[Option Capture Source:iMic]
+name = input-microphone-internal
+
+[Option Capture Source:i-Mic]
+name = input-microphone-internal
+
+[Option Capture Source:Internal Microphone]
+name = input-microphone-internal
+
+[Option Capture Source:Front Microphone]
+name = input-microphone
+
+[Option Capture Source:Mic1]
+name = input-microphone
+
+[Option Capture Source:Mic2]
+name = input-microphone
+
+[Option Capture Source:D-Mic]
+name = input-microphone
+
+[Option Capture Source:IntMic]
+name = input-microphone-internal
+
+[Option Capture Source:ExtMic]
+name = input-microphone-external
+
+[Option Capture Source:Ext Mic]
+name = input-microphone-external
+
+[Option Capture Source:E-Mic]
+name = input-microphone-external
+
+[Option Capture Source:e-Mic]
+name = input-microphone-external
+
+[Option Capture Source:LineIn]
+name = input-linein
+
+[Option Capture Source:Analog]
+name = input
+
+[Option Capture Source:Line-In]
+name = input-linein
+
+[Option Capture Source:Line In]
+name = input-linein
+
+[Option Capture Source:Video]
+name = input-video
+
+[Option Capture Source:Aux]
+name = input
+
+[Option Capture Source:Aux0]
+name = input
+
+[Option Capture Source:Aux1]
+name = input
+
+[Option Capture Source:Aux2]
+name = input
+
+[Option Capture Source:Aux3]
+name = input
+
+[Option Capture Source:AUX IN]
+name = input
+
+[Option Capture Source:Aux In]
+name = input
+
+[Option Capture Source:AOUT]
+name = input
+
+[Option Capture Source:AUX]
+name = input
+
+[Option Capture Source:Cam Mic]
+name = input-microphone
+
+[Option Capture Source:Digital Mic]
+name = input-microphone
+
+[Option Capture Source:Digital Mic 1]
+name = input-microphone
+
+[Option Capture Source:Digital Mic 2]
+name = input-microphone
+
+[Option Capture Source:Analog Inputs]
+name = input
+
+[Option Capture Source:Unknown1]
+name = input
+
+[Option Capture Source:Unknown2]
+name = input
+
+[Option Capture Source:Docking-Station]
+name = input-docking
+
+;;; 'Mic Jack Mode'
+
+[Element Mic Jack Mode]
+enumeration = select
+
+[Option Mic Jack Mode:Mic In]
+name = input-microphone
+
+[Option Mic Jack Mode:Line In]
+name = input-linein
+
+;;; 'Digital Input Source'
+
+[Element Digital Input Source]
+enumeration = select
+
+[Option Digital Input Source:Analog Inputs]
+name = input
+
+[Option Digital Input Source:Digital Mic 1]
+name = input-microphone
+
+[Option Digital Input Source:Digital Mic 2]
+name = input-microphone
+
+;;; 'Analog Source'
+
+[Element Analog Source]
+enumeration = select
+
+[Option Analog Source:Mic]
+name = input-microphone
+
+[Option Analog Source:Line in]
+name = input-linein
+
+[Option Analog Source:Aux]
+name = input
+
+;;; 'Shared Mic/Line in'
+
+[Element Shared Mic/Line in]
+enumeration = select
+
+[Option Shared Mic/Line in:Mic in]
+name = input-microphone
+
+[Option Shared Mic/Line in:Line in]
+name = input-linein
+
+;;; Various Boosts
+
+[Element Capture Boost]
+switch = select
+
+[Option Capture Boost:on]
+name = input-boost-on
+
+[Option Capture Boost:off]
+name = input-boost-off
+
+[Element Auto Gain Control]
+switch = select
+
+[Option Auto Gain Control:on]
+name = input-agc-on
+
+[Option Auto Gain Control:off]
+name = input-agc-off
diff --git a/src/modules/alsa/mixer/paths/analog-output-desktop-speaker.conf b/src/modules/alsa/mixer/paths/analog-output-desktop-speaker.conf
new file mode 100644
index 00000000..dfdecf41
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output-desktop-speaker.conf
@@ -0,0 +1,99 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Path for mixers that have a 'Desktop Speaker' control
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 101
+name = analog-output-speaker
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master Mono]
+switch = off
+volume = off
+
+; This profile path is intended to control the desktop speaker, not
+; the headphones. But it should not hurt if we leave the headphone
+; jack enabled nonetheless.
+[Element Headphone]
+switch = mute
+volume = zero
+
+[Element Headphone2]
+switch = mute
+volume = zero
+
+[Element Speaker]
+switch = off
+volume = off
+
+[Element Desktop Speaker]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Front]
+switch = mute
+volume = merge
+override-map.1 = all-front
+override-map.2 = front-left,front-right
+
+[Element Rear]
+switch = mute
+volume = merge
+override-map.1 = all-rear
+override-map.2 = rear-left,rear-right
+
+[Element Surround]
+switch = mute
+volume = merge
+override-map.1 = all-rear
+override-map.2 = rear-left,rear-right
+
+[Element Side]
+switch = mute
+volume = merge
+override-map.1 = all-side
+override-map.2 = side-left,side-right
+
+[Element Center]
+switch = mute
+volume = merge
+override-map.1 = all-center
+override-map.2 = all-center,all-center
+
+[Element LFE]
+switch = mute
+volume = merge
+override-map.1 = lfe
+override-map.2 = lfe,lfe
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output-headphones-2.conf b/src/modules/alsa/mixer/paths/analog-output-headphones-2.conf
new file mode 100644
index 00000000..e47543f5
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output-headphones-2.conf
@@ -0,0 +1,87 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Path for mixers that have a 'Headphone2' control
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 89
+name = analog-output-headphones
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master Mono]
+switch = off
+volume = off
+
+; This profile path is intended to control the second headphones, not
+; the first headphones. But it should not hurt if we leave the
+; headphone jack enabled nonetheless.
+[Element Headphone]
+switch = mute
+volume = zero
+
+[Element Headphone2]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Speaker]
+switch = off
+volume = off
+
+[Element Desktop Speaker]
+switch = off
+volume = off
+
+[Element Front]
+switch = off
+volume = off
+
+[Element Rear]
+switch = off
+volume = off
+
+[Element Surround]
+switch = off
+volume = off
+
+[Element Side]
+switch = off
+volume = off
+
+[Element Center]
+switch = off
+volume = off
+
+[Element LFE]
+switch = off
+volume = off
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output-headphones.conf b/src/modules/alsa/mixer/paths/analog-output-headphones.conf
new file mode 100644
index 00000000..1d7bb0ba
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output-headphones.conf
@@ -0,0 +1,87 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Path for mixers that have a 'Headphone' control
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 90
+name = analog-output-headphones
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master Mono]
+switch = off
+volume = off
+
+[Element Headphone]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+; This profile path is intended to control the first headphones, not
+; the second headphones. But it should not hurt if we leave the second
+; headphone jack enabled nonetheless.
+[Element Headphone2]
+switch = mute
+volume = zero
+
+[Element Speaker]
+switch = off
+volume = off
+
+[Element Desktop Speaker]
+switch = off
+volume = off
+
+[Element Front]
+switch = off
+volume = off
+
+[Element Rear]
+switch = off
+volume = off
+
+[Element Surround]
+switch = off
+volume = off
+
+[Element Side]
+switch = off
+volume = off
+
+[Element Center]
+switch = off
+volume = off
+
+[Element LFE]
+switch = off
+volume = off
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output-lfe-on-mono.conf b/src/modules/alsa/mixer/paths/analog-output-lfe-on-mono.conf
new file mode 100644
index 00000000..67ee32f7
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output-lfe-on-mono.conf
@@ -0,0 +1,89 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Intended for usage in laptops that have a seperate LFE speaker
+; connected to the Master mono connector
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 40
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = mute
+volume = merge
+override-map.1 = all-no-lfe
+override-map.2 = all-left,all-right
+
+[Element Master Mono]
+required = any
+switch = mute
+volume = merge
+override-map.1 = lfe
+override-map.2 = lfe,lfe
+
+; This profile path is intended to control the speaker, not the
+; headphones. But it should not hurt if we leave the headphone jack
+; enabled nonetheless.
+[Element Headphone]
+switch = mute
+volume = zero
+
+[Element Headphone2]
+switch = mute
+volume = zero
+
+[Element Speaker]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Desktop Speaker]
+switch = off
+volume = off
+
+[Element Front]
+switch = off
+volume = off
+
+[Element Rear]
+switch = off
+volume = off
+
+[Element Surround]
+switch = off
+volume = off
+
+[Element Side]
+switch = off
+volume = off
+
+[Element Center]
+switch = off
+volume = off
+
+[Element LFE]
+switch = off
+volume = off
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output-mono.conf b/src/modules/alsa/mixer/paths/analog-output-mono.conf
new file mode 100644
index 00000000..13a2d6aa
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output-mono.conf
@@ -0,0 +1,86 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Intended for usage on boards that have a seperate Mono output plug.
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 50
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = off
+volume = off
+
+[Element Master Mono]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+; This profile path is intended to control the speaker, not the
+; headphones. But it should not hurt if we leave the headphone jack
+; enabled nonetheless.
+[Element Headphone]
+switch = mute
+volume = zero
+
+[Element Headphone2]
+switch = mute
+volume = zero
+
+[Element Speaker]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Desktop Speaker]
+switch = off
+volume = off
+
+[Element Front]
+switch = off
+volume = off
+
+[Element Rear]
+switch = off
+volume = off
+
+[Element Surround]
+switch = off
+volume = off
+
+[Element Side]
+switch = off
+volume = off
+
+[Element Center]
+switch = off
+volume = off
+
+[Element LFE]
+switch = off
+volume = off
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output-speaker.conf b/src/modules/alsa/mixer/paths/analog-output-speaker.conf
new file mode 100644
index 00000000..c6916d6b
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output-speaker.conf
@@ -0,0 +1,99 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Path for mixers that have a 'Speaker' control
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 100
+name = analog-output-speaker
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master Mono]
+switch = off
+volume = off
+
+; This profile path is intended to control the speaker, not the
+; headphones. But it should not hurt if we leave the headphone jack
+; enabled nonetheless.
+[Element Headphone]
+switch = mute
+volume = zero
+
+[Element Headphone2]
+switch = mute
+volume = zero
+
+[Element Speaker]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Desktop Speaker]
+switch = off
+volume = off
+
+[Element Front]
+switch = mute
+volume = merge
+override-map.1 = all-front
+override-map.2 = front-left,front-right
+
+[Element Rear]
+switch = mute
+volume = merge
+override-map.1 = all-rear
+override-map.2 = rear-left,rear-right
+
+[Element Surround]
+switch = mute
+volume = merge
+override-map.1 = all-rear
+override-map.2 = rear-left,rear-right
+
+[Element Side]
+switch = mute
+volume = merge
+override-map.1 = all-side
+override-map.2 = side-left,side-right
+
+[Element Center]
+switch = mute
+volume = merge
+override-map.1 = all-center
+override-map.2 = all-center,all-center
+
+[Element LFE]
+switch = mute
+volume = merge
+override-map.1 = lfe
+override-map.2 = lfe,lfe
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output.conf b/src/modules/alsa/mixer/paths/analog-output.conf
new file mode 100644
index 00000000..50fc88ea
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output.conf
@@ -0,0 +1,96 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Intended for the 'default' output. Note that a-o-speaker.conf has a
+; higher priority than this
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 99
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master Mono]
+switch = off
+volume = off
+
+; This profile path is intended to control the default output, not the
+; headphones. But it should not hurt if we leave the headphone jack
+; enabled nonetheless.
+[Element Headphone]
+switch = mute
+volume = zero
+
+[Element Headphone2]
+switch = mute
+volume = zero
+
+[Element Speaker]
+switch = mute
+volume = off
+
+[Element Desktop Speaker]
+switch = mute
+volume = off
+
+[Element Front]
+switch = mute
+volume = merge
+override-map.1 = all-front
+override-map.2 = front-left,front-right
+
+[Element Rear]
+switch = mute
+volume = merge
+override-map.1 = all-rear
+override-map.2 = rear-left,rear-right
+
+[Element Surround]
+switch = mute
+volume = merge
+override-map.1 = all-rear
+override-map.2 = rear-left,rear-right
+
+[Element Side]
+switch = mute
+volume = merge
+override-map.1 = all-side
+override-map.2 = side-left,side-right
+
+[Element Center]
+switch = mute
+volume = merge
+override-map.1 = all-center
+override-map.2 = all-center,all-center
+
+[Element LFE]
+switch = mute
+volume = merge
+override-map.1 = lfe
+override-map.2 = lfe,lfe
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output.conf.common b/src/modules/alsa/mixer/paths/analog-output.conf.common
new file mode 100644
index 00000000..ccaa494b
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output.conf.common
@@ -0,0 +1,147 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Common part of all paths
+
+; So here's generally how mixer paths are used by PA: PA goes through
+; a mixer path file from top to bottom and checks if a mixer element
+; described therein exists. If so it is added to the list of mixer
+; elements PA will control, keeping the order it read them in. If a
+; mixer element described here has set the required= or
+; required-absent= directives a path might not be accepted as valid
+; and is ignored in its entirety (see below). However usually if a
+; element listed here is missing this one element is ignored but not
+; the entire path.
+;
+; When a device shall be muted/unmuted *all* elements listed in a path
+; file with "switch = mute" will be toggled.
+;
+; When a device shall change its volume, PA will got through the list
+; of all elements with "volume = merge" and set the volume on the
+; first element. If that element does not support dB volumes, this is
+; where the story ends. If it does support dB volumes, PA divides the
+; requested volume by the volume that was set on this element, and
+; then go on to the next element with "volume = merge" and then set
+; that there, and so on. That way the first volume element in the
+; path will be the one that does the 'biggest' part of the overall
+; volume adjustment, with the remaining elements usually being set to
+; some value next to 0dB. This logic makes sure we get the full range
+; over all volume sliders and a very high granularity of volumes
+; already in hardware.
+;
+; All switches and enumerations set to "select" are exposed via the
+; "port" functionality of sinks/sources. Basically every possible
+; switch setting and every possible enumeration setting will be
+; combined and made into a "port". So make sure you don't list too
+; many switches/enums for exposing, because the number of ports might
+; rise exponentially.
+;
+; Only one path can be selected at a time. All paths that are valid
+; for an audio device will be exposed as "port" for the sink/source.
+
+
+; [General]
+; priority = ... # Priority for this path
+; description = ...
+;
+; [Option ...:...] # For each option of an enumeration or switch element
+; # that shall be exposed as a sink/source port. Needs to
+; # be named after the Element, followed by a colon, followed
+; # by the option name, resp. on/off if the element is a switch.
+; name = ... # Logical name to use in the path identifier
+; priority = ... # Priority if this is made into a device port
+; required = ignore | enumeration | any # In this element, this option must exist or the path will be invalid. ("any" is an alias for "enumeration".)
+; required-any = ignore | enumeration | any # In this element, either this or another option must exist (or an element)
+; required-absent = ignore | enumeration | any # In this element, this option must not exist or the path will be invalid
+;
+; [Element ...] # For each element that we shall control
+; required = ignore | switch | volume | enumeration | any # If set, require this element to be of this kind and available,
+; # otherwise don't consider this path valid for the card
+; required-any = ignore | switch | volume | enumeration | any # If set, at least one of the elements with required-any in this
+; # path must be present, otherwise this path is invalid for the card
+; required-absent = ignore | switch | volume # If set, require this element to not be of this kind and not
+; # available, otherwise don't consider this path valid for the card
+;
+; switch = ignore | mute | off | on | select # What to do with this switch: ignore it, make it follow mute status,
+; # always set it to off, always to on, or make it selectable as port.
+; # If set to 'select' you need to define an Option section for on
+; # and off
+; volume = ignore | merge | off | zero | <volume step> # What to do with this volume: ignore it, merge it into the device
+; # volume slider, always set it to the lowest value possible, or always
+; # set it to 0 dB (for whatever that means), or always set it to
+; # <volume step> (this only makes sense in path configurations where
+; # the exact hardware and driver are known beforehand).
+; volume-limit = <volume step> # Limit the maximum volume by disabling the volume steps above <volume step>.
+; enumeration = ignore | select # What to do with this enumeration, ignore it or make it selectable
+; # via device ports. If set to 'select' you need to define an Option section
+; # for each of the items you want to expose
+; direction = playback | capture # Is this relevant only for playback or capture? If not set this will implicitly be
+; # set the direction of the PCM device is opened as. Generally this doesn't need to be set
+; # unless you have a broken driver that has playback controls marked for capture or vice
+; # versa
+; direction-try-other = no | yes # If the element does not supported what is requested, try the other direction, too?
+;
+; override-map.1 = ... # Override the channel mask of the mixer control if the control only exposes a single channel
+; override-map.2 = ... # Override the channel masks of the mixer control if the control only exposes two channels
+; # Override maps should list for each element channel which high-level channels it controls via a
+; # channel mask. A channel mask may either be the name of a single channel, or the words "all-left",
+; # "all-right", "all-center", "all-front", "all-rear", and "all" to encode a specific subset of
+; # channels in a mask
+
+[Element PCM]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element External Amplifier]
+switch = select
+
+[Option External Amplifier:on]
+name = output-amplifier-on
+priority = 10
+
+[Option External Amplifier:off]
+name = output-amplifier-off
+priority = 0
+
+[Element Bass Boost]
+switch = select
+
+[Option Bass Boost:on]
+name = output-bass-boost-on
+priority = 0
+
+[Option Bass Boost:off]
+name = output-bass-boost-off
+priority = 10
+
+;;; 'Analog Output'
+
+[Element Analog Output]
+enumeration = select
+
+[Option Analog Output:Speakers]
+name = output-speaker
+priority = 10
+
+[Option Analog Output:Headphones]
+name = output-headphones
+priority = 9
+
+[Option Analog Output:FP Headphones]
+name = output-headphones
+priority = 8
diff --git a/src/modules/alsa/mixer/paths/iec958-stereo-output.conf b/src/modules/alsa/mixer/paths/iec958-stereo-output.conf
new file mode 100644
index 00000000..8506a580
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/iec958-stereo-output.conf
@@ -0,0 +1,19 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+
+[Element IEC958]
+switch = mute
diff --git a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
new file mode 100644
index 00000000..e1da3314
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
@@ -0,0 +1,40 @@
+# do not edit this file, it will be overwritten on update
+
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+SUBSYSTEM!="sound", GOTO="pulseaudio_end"
+ACTION!="change", GOTO="pulseaudio_end"
+KERNEL!="card*", GOTO="pulseaudio_end"
+
+# Some specific work arounds until we can handle heasets/handsets properly (i.e. "Speaker" only, no "master")
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="046d", ATTRS{idProduct}=="01ab", ENV{PULSE_PROFILE_SET}="usb-headset.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="046d", ATTRS{idProduct}=="0a0c", ENV{PULSE_PROFILE_SET}="usb-headset.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="1395", ATTRS{idProduct}=="0002", ENV{PULSE_PROFILE_SET}="usb-headset.conf"
+# UAC1.0 Sennheiser Dongle
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="1395", ATTRS{idProduct}=="3554", ENV{PULSE_PROFILE_SET}="usb-headset.conf"
+# BT Agile Handset
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="1885", ATTRS{idProduct}=="0501", ENV{PULSE_PROFILE_SET}="usb-headset.conf"
+
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="17cc", ATTRS{idProduct}=="1978", ENV{PULSE_PROFILE_SET}="native-instruments-audio8dj.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="17cc", ATTRS{idProduct}=="0839", ENV{PULSE_PROFILE_SET}="native-instruments-audio4dj.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="17cc", ATTRS{idProduct}=="baff", ENV{PULSE_PROFILE_SET}="native-instruments-traktorkontrol-s4.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="17cc", ATTRS{idProduct}=="4711", ENV{PULSE_PROFILE_SET}="native-instruments-korecontroller.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="17cc", ATTRS{idProduct}=="1011", ENV{PULSE_PROFILE_SET}="native-instruments-traktor-audio6.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="17cc", ATTRS{idProduct}=="1021", ENV{PULSE_PROFILE_SET}="native-instruments-traktor-audio10.conf"
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="0763", ATTRS{idProduct}=="2012", ENV{PULSE_PROFILE_SET}="maudio-fasttrack-pro.conf"
+
+LABEL="pulseaudio_end"
diff --git a/src/modules/alsa/mixer/profile-sets/default.conf b/src/modules/alsa/mixer/profile-sets/default.conf
new file mode 100644
index 00000000..283edfb3
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/default.conf
@@ -0,0 +1,180 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Default profile definitions for the ALSA backend of PulseAudio. This
+; is used as fallback for all cards that have no special mapping
+; assigned (and should be good enough for the vast majority of
+; cards). If you want to assign a different profile set than this one
+; to a device, either set the udev property PULSE_PROFILE_SET for the
+; card, or use the "profile_set" module argument when loading
+; module-alsa-card.
+;
+; So what is this about? Simply, what we do here is map ALSA devices
+; to how they are exposed in PA. We say which ALSA device string to
+; use to open a device, which channel mapping to use then, and which
+; mixer path to use. This is encoded in a 'mapping'. Multiple of these
+; mappings can be bound together in a 'profile' which is then directly
+; exposed in the UI as a card profile. Each mapping assigned to a
+; profile will result in one sink/source to be created if the profile
+; is selected for the card.
+;
+; Additionally, the path set configuration files can describe the
+; decibel values assigned to the steps of the volume elements. This
+; can be used to work around situations when the alsa driver doesn't
+; provide any decibel information, or when the information is
+; incorrect.
+
+
+; [General]
+; auto-profiles = no | yes # Instead of defining all profiles manually, autogenerate
+; # them by combining every input mapping with every output mapping.
+;
+; [Mapping id]
+; device-strings = ... # ALSA device string. %f will be replaced by the card identifier.
+; channel-map = ... # Channel mapping to use for this device
+; description = ...
+; paths-input = ... # A list of mixer paths to use. Every path in this list will be probed.
+; # If multiple are found to be working they will be available as device ports
+; paths-output = ...
+; element-input = ... # Instead of configuring a full mixer path simply configure a single
+; # mixer element for volume/mute handling
+; element-output = ...
+; priority = ...
+; direction = any | input | output # Only useful for?
+;
+; [Profile id]
+; input-mappings = ... # Lists mappings for sources on this profile, those mapping must be
+; # defined in this file too
+; output-mappings = ... # Lists mappings for sinks on this profile, those mappings must be
+; # defined in this file too
+; description = ...
+; priority = ... # Numeric value to deduce priority for this profile
+; skip-probe = no | yes # Skip probing for availability? If this is yes then this profile
+; # will be assumed as working without probing. Makes initialization
+; # a bit faster but only works if the card is really known well.
+;
+; [DecibelFix element] # Decibel fixes can be used to work around missing or incorrect dB
+; # information from alsa. A decibel fix is a table that maps volume steps
+; # to decibel values for one volume element. The "element" part in the
+; # section title is the name of the volume element.
+; #
+; # NOTE: This feature is meant just as a help for figuring out the correct
+; # decibel values. Pulseaudio is not the correct place to maintain the
+; # decibel mappings!
+; #
+; # If you need this feature, then you should make sure that when you have
+; # the correct values figured out, the alsa driver developers get informed
+; # too, so that they can fix the driver.
+;
+; db-values = ... # The option value consists of pairs of step numbers and decibel values.
+; # The pairs are separated with whitespace, and steps are separated from
+; # the corresponding decibel values with a colon. The values must be in an
+; # increasing order. Here's an example of a valid string:
+; #
+; # "0:-40.50 1:-38.70 3:-33.00 11:0"
+; #
+; # The lowest step imposes a lower limit for hardware volume and the
+; # highest step correspondingly imposes a higher limit. That means that
+; # that the mixer will never be set outside those values - the rest of the
+; # volume scale is done using software volume.
+; #
+; # As can be seen in the example, you don't need to specify a dB value for
+; # each step. The dB values for skipped steps will be linearly interpolated
+; # using the nearest steps that are given.
+
+[General]
+auto-profiles = yes
+
+[Mapping analog-mono]
+device-strings = hw:%f
+channel-map = mono
+paths-output = analog-output analog-output-speaker analog-output-desktop-speaker analog-output-headphones analog-output-headphones-2 analog-output-mono analog-output-lfe-on-mono
+paths-input = analog-input-front-mic analog-input-rear-mic analog-input-internal-mic analog-input-dock-mic analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line
+priority = 1
+
+[Mapping analog-stereo]
+device-strings = front:%f hw:%f
+channel-map = left,right
+paths-output = analog-output analog-output-speaker analog-output-desktop-speaker analog-output-headphones analog-output-headphones-2 analog-output-mono analog-output-lfe-on-mono
+paths-input = analog-input-front-mic analog-input-rear-mic analog-input-internal-mic analog-input-dock-mic analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line
+priority = 10
+
+[Mapping analog-surround-40]
+device-strings = surround40:%f
+channel-map = front-left,front-right,rear-left,rear-right
+paths-output = analog-output analog-output-speaker analog-output-desktop-speaker analog-output-lfe-on-mono
+priority = 7
+direction = output
+
+[Mapping analog-surround-41]
+device-strings = surround41:%f
+channel-map = front-left,front-right,rear-left,rear-right,lfe
+paths-output = analog-output analog-output-speaker analog-output-desktop-speaker analog-output-lfe-on-mono
+priority = 8
+direction = output
+
+[Mapping analog-surround-50]
+device-strings = surround50:%f
+channel-map = front-left,front-right,rear-left,rear-right,front-center
+paths-output = analog-output analog-output-speaker analog-output-desktop-speaker analog-output-lfe-on-mono
+priority = 7
+direction = output
+
+[Mapping analog-surround-51]
+device-strings = surround51:%f
+channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe
+paths-output = analog-output analog-output-speaker analog-output-desktop-speaker analog-output-lfe-on-mono
+priority = 8
+direction = output
+
+[Mapping analog-surround-71]
+device-strings = surround71:%f
+channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right
+description = Analog Surround 7.1
+paths-output = analog-output analog-output-speaker analog-output-desktop-speaker analog-output-lfe-on-mono
+priority = 7
+direction = output
+
+[Mapping iec958-stereo]
+device-strings = iec958:%f
+channel-map = left,right
+paths-input = iec958-stereo-input
+paths-output = iec958-stereo-output
+priority = 5
+
+[Mapping iec958-ac3-surround-40]
+device-strings = a52:%f
+channel-map = front-left,front-right,rear-left,rear-right
+priority = 2
+direction = output
+
+[Mapping iec958-ac3-surround-51]
+device-strings = a52:%f
+channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe
+priority = 3
+direction = output
+
+[Mapping hdmi-stereo]
+device-strings = hdmi:%f
+channel-map = left,right
+priority = 4
+direction = output
+
+; An example for defining multiple-sink profiles
+#[Profile output:analog-stereo+output:iec958-stereo+input:analog-stereo]
+#description = Foobar
+#output-mappings = analog-stereo iec958-stereo
+#input-mappings = analog-stereo
diff --git a/src/modules/alsa/mixer/profile-sets/maudio-fasttrack-pro.conf b/src/modules/alsa/mixer/profile-sets/maudio-fasttrack-pro.conf
new file mode 100644
index 00000000..75f51121
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/maudio-fasttrack-pro.conf
@@ -0,0 +1,85 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; M-Audio FastTrack Pro
+;
+; This card has one duplex stereo channel called A and an additional
+; stereo output channel called B.
+;
+; We knowingly only define a subset of the theoretically possible
+; mapping combinations as profiles here.
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = no
+
+[Mapping analog-stereo-a-output]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,0
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-a-input]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,0
+channel-map = left,right
+direction = input
+
+[Mapping analog-stereo-b-output]
+description = Analog Stereo Channel B
+device-strings = hw:%f,1,0
+channel-map = left,right
+direction = output
+
+[Profile output:analog-stereo-all+input:analog-stereo-all]
+description = Analog Stereo Duplex Channel A, Analog Stereo output Channel B
+output-mappings = analog-stereo-a-output analog-stereo-b-output
+input-mappings = analog-stereo-a-input
+priority = 100
+skip-probe = yes
+
+[Profile output:analog-stereo-a-output+input:analog-stereo-a-input]
+description = Analog Stereo Duplex Channel A
+output-mappings = analog-stereo-a-output
+input-mappings = analog-stereo-a-input
+priority = 40
+skip-probe = yes
+
+[Profile output:analog-stereo-b+input:analog-stereo-b]
+description = Analog Stereo Output Channel B
+output-mappings = analog-stereo-b-output
+input-mappings =
+priority = 50
+skip-probe = yes
+
+[Profile output:analog-stereo-a]
+description = Analog Stereo Output Channel A
+output-mappings = analog-stereo-a-output
+priority = 5
+skip-probe = yes
+
+[Profile output:analog-stereo-b]
+description = Analog Stereo Output Channel B
+output-mappings = analog-stereo-b-output
+priority = 6
+skip-probe = yes
+
+[Profile input:analog-stereo-a]
+description = Analog Stereo Input Channel A
+input-mappings = analog-stereo-a-input
+priority = 2
+skip-probe = yes
diff --git a/src/modules/alsa/mixer/profile-sets/native-instruments-audio4dj.conf b/src/modules/alsa/mixer/profile-sets/native-instruments-audio4dj.conf
new file mode 100644
index 00000000..2b835308
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/native-instruments-audio4dj.conf
@@ -0,0 +1,91 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Native Instruments Audio 4 DJ
+;
+; This card has two stereo pairs of input and two stereo pairs of
+; output, named channels A and B. Channel B has an additional
+; Headphone connector.
+;
+; We knowingly only define a subset of the theoretically possible
+; mapping combinations as profiles here.
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = no
+
+[Mapping analog-stereo-a]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-b-output]
+description = Analog Stereo Channel B (Headphones)
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-b-input]
+description = Analog Stereo Channel B
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = input
+
+[Profile output:analog-stereo-all+input:analog-stereo-all]
+description = Analog Stereo Duplex Channels A, B (Headphones)
+output-mappings = analog-stereo-a analog-stereo-b-output
+input-mappings = analog-stereo-a analog-stereo-b-input
+priority = 100
+skip-probe = yes
+
+[Profile output:analog-stereo-a+input:analog-stereo-a]
+description = Analog Stereo Duplex Channel A
+output-mappings = analog-stereo-a
+input-mappings = analog-stereo-a
+priority = 40
+skip-probe = yes
+
+[Profile output:analog-stereo-b+input:analog-stereo-b]
+description = Analog Stereo Duplex Channel B (Headphones)
+output-mappings = analog-stereo-b-output
+input-mappings = analog-stereo-b-input
+priority = 50
+skip-probe = yes
+
+[Profile output:analog-stereo-a]
+description = Analog Stereo Output Channel A
+output-mappings = analog-stereo-a
+priority = 5
+skip-probe = yes
+
+[Profile output:analog-stereo-b]
+description = Analog Stereo Output Channel B (Headphones)
+output-mappings = analog-stereo-b-output
+priority = 6
+skip-probe = yes
+
+[Profile input:analog-stereo-a]
+description = Analog Stereo Input Channel A
+input-mappings = analog-stereo-a
+priority = 2
+skip-probe = yes
+
+[Profile input:analog-stereo-b]
+description = Analog Stereo Input Channel B
+input-mappings = analog-stereo-b-input
+priority = 1
+skip-probe = yes
diff --git a/src/modules/alsa/mixer/profile-sets/native-instruments-audio8dj.conf b/src/modules/alsa/mixer/profile-sets/native-instruments-audio8dj.conf
new file mode 100644
index 00000000..3fe3cc56
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/native-instruments-audio8dj.conf
@@ -0,0 +1,162 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Native Instruments Audio 8 DJ
+;
+; This card has four stereo pairs of input and four stereo pairs of
+; output, named channels A to D. Channel C has an additional Mic/Line
+; connector, channel D an additional Headphone connector.
+;
+; We knowingly only define a subset of the theoretically possible
+; mapping combinations as profiles here.
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = no
+
+[Mapping analog-stereo-a]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-b]
+description = Analog Stereo Channel B
+device-strings = hw:%f,0,1
+channel-map = left,right
+
+# Since we want to set a different description for channel C's/D's input
+# and output we define two seperate mappings for them
+[Mapping analog-stereo-c-output]
+description = Analog Stereo Channel C
+device-strings = hw:%f,0,2
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-c-input]
+description = Analog Stereo Channel C (Line/Mic)
+device-strings = hw:%f,0,2
+channel-map = left,right
+direction = input
+
+[Mapping analog-stereo-d-output]
+description = Analog Stereo Channel D (Headphones)
+device-strings = hw:%f,0,3
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-d-input]
+description = Analog Stereo Channel D
+device-strings = hw:%f,0,3
+channel-map = left,right
+direction = input
+
+[Profile output:analog-stereo-all+input:analog-stereo-all]
+description = Analog Stereo Duplex Channels A, B, C (Line/Mic), D (Headphones)
+output-mappings = analog-stereo-a analog-stereo-b analog-stereo-c-output analog-stereo-d-output
+input-mappings = analog-stereo-a analog-stereo-b analog-stereo-c-input analog-stereo-d-input
+priority = 100
+skip-probe = yes
+
+[Profile output:analog-stereo-d+input:analog-stereo-c]
+description = Analog Stereo Channel D (Headphones) Output, Channel C (Line/Mic) Input
+output-mappings = analog-stereo-d-output
+input-mappings = analog-stereo-c-input
+priority = 90
+skip-probe = yes
+
+[Profile output:analog-stereo-c-d+input:analog-stereo-c-d]
+description = Analog Stereo Duplex Channels C (Line/Mic), D (Line/Mic)
+output-mappings = analog-stereo-c-output analog-stereo-d-output
+input-mappings = analog-stereo-c-input analog-stereo-d-input
+priority = 80
+skip-probe = yes
+
+[Profile output:analog-stereo-a+input:analog-stereo-a]
+description = Analog Stereo Duplex Channel A
+output-mappings = analog-stereo-a
+input-mappings = analog-stereo-a
+priority = 50
+skip-probe = yes
+
+[Profile output:analog-stereo-b+input:analog-stereo-b]
+description = Analog Stereo Duplex Channel B
+output-mappings = analog-stereo-b
+input-mappings = analog-stereo-b
+priority = 40
+skip-probe = yes
+
+[Profile output:analog-stereo-c+input:analog-stereo-c]
+description = Analog Stereo Duplex Channel C (Line/Mic)
+output-mappings = analog-stereo-c-output
+input-mappings = analog-stereo-c-input
+priority = 60
+skip-probe = yes
+
+[Profile output:analog-stereo-d+input:analog-stereo-d]
+description = Analog Stereo Duplex Channel D (Headphones)
+output-mappings = analog-stereo-d-output
+input-mappings = analog-stereo-d-input
+priority = 70
+skip-probe = yes
+
+[Profile output:analog-stereo-a]
+description = Analog Stereo Output Channel A
+output-mappings = analog-stereo-a
+priority = 6
+skip-probe = yes
+
+[Profile output:analog-stereo-b]
+description = Analog Stereo Output Channel B
+output-mappings = analog-stereo-b
+priority = 5
+skip-probe = yes
+
+[Profile output:analog-stereo-c]
+description = Analog Stereo Output Channel C
+output-mappings = analog-stereo-c-output
+priority = 7
+skip-probe = yes
+
+[Profile output:analog-stereo-d]
+description = Analog Stereo Output Channel D (Headphones)
+output-mappings = analog-stereo-d-output
+priority = 8
+skip-probe = yes
+
+[Profile input:analog-stereo-a]
+description = Analog Stereo Input Channel A
+input-mappings = analog-stereo-a
+priority = 2
+skip-probe = yes
+
+[Profile input:analog-stereo-b]
+description = Analog Stereo Input Channel B
+input-mappings = analog-stereo-b
+priority = 1
+skip-probe = yes
+
+[Profile input:analog-stereo-c]
+description = Analog Stereo Input Channel C (Line/Mic)
+input-mappings = analog-stereo-c-input
+priority = 4
+skip-probe = yes
+
+[Profile input:analog-stereo-d]
+description = Analog Stereo Input Channel D
+input-mappings = analog-stereo-d-input
+priority = 3
+skip-probe = yes
diff --git a/src/modules/alsa/mixer/profile-sets/native-instruments-korecontroller.conf b/src/modules/alsa/mixer/profile-sets/native-instruments-korecontroller.conf
new file mode 100644
index 00000000..904357d0
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/native-instruments-korecontroller.conf
@@ -0,0 +1,85 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Native Instruments Kore Controller
+;
+; This card has one stereo pairs of input and two stereo pairs of
+; output, named "Master" and "Headphone". The master channel has
+; an additional Coax S/PDIF connector which is always on.
+;
+; We knowingly only define a subset of the theoretically possible
+; mapping combinations as profiles here.
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = no
+
+[Mapping analog-stereo-master-out]
+description = Analog Stereo Master Channel
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-headphone-out]
+description = Analog Stereo Headphone Channel
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-input]
+description = Analog Stereo
+device-strings = hw:%f,0,0
+channel-map = left,right
+direction = input
+
+[Profile output:analog-stereo-all+input:analog-stereo-all]
+description = Analog Stereo Duplex Master Output, Headphones Output
+output-mappings = analog-stereo-master-out analog-stereo-headphone-out
+input-mappings = analog-stereo-input
+priority = 100
+skip-probe = yes
+
+[Profile output:analog-stereo-master+input:analog-stereo-input]
+description = Analog Stereo Duplex Master Output
+output-mappings = analog-stereo-master-out
+input-mappings = analog-stereo-input
+priority = 40
+skip-probe = yes
+
+[Profile output:analog-stereo-headphone-out+input:analog-stereo-input]
+description = Analog Stereo Headphones Output
+output-mappings = analog-stereo-headphone-out
+input-mappings = analog-stereo-input
+priority = 30
+skip-probe = yes
+
+[Profile output:analog-stereo-master]
+description = Analog Stereo Master Output
+output-mappings = analog-stereo-master-out
+priority = 3
+skip-probe = yes
+
+[Profile output:analog-stereo-headphone]
+description = Analog Stereo Headphones Output
+output-mappings = analog-stereo-headphone-out
+priority = 2
+skip-probe = yes
+
+[Profile input:analog-stereo-input]
+description = Analog Stereo Input
+input-mappings = analog-stereo-input
+priority = 1
+skip-probe = yes
diff --git a/src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio10.conf b/src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio10.conf
new file mode 100644
index 00000000..4deb65da
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio10.conf
@@ -0,0 +1,131 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Native Instruments Audio 10 DJ
+;
+; This card has five stereo pairs of input and five stereo pairs of
+; output
+;
+; We knowingly only define a subset of the theoretically possible
+; mapping combinations as profiles here.
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = no
+
+[Mapping analog-stereo-out-main]
+description = Analog Stereo Main
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-out-a]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-out-b]
+description = Analog Stereo Channel B
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-out-c]
+description = Analog Stereo Channel C
+device-strings = hw:%f,0,2
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-out-d]
+description = Analog Stereo Channel D
+device-strings = hw:%f,0,3
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-in-main]
+description = Analog Stereo Main
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-in-a]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = input
+
+[Mapping analog-stereo-in-b]
+description = Analog Stereo Channel B
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = input
+
+[Mapping analog-stereo-in-c]
+description = Analog Stereo Channel C
+device-strings = hw:%f,0,2
+channel-map = left,right
+direction = input
+
+[Mapping analog-stereo-in-d]
+description = Analog Stereo Channel D
+device-strings = hw:%f,0,3
+channel-map = left,right
+direction = input
+
+
+
+
+[Profile output:analog-stereo-all+input:analog-stereo-all]
+description = Analog Stereo Duplex Channels Main, A, B, C, D
+output-mappings = analog-stereo-out-main analog-stereo-out-a analog-stereo-out-b analog-stereo-out-c analog-stereo-out-d
+input-mappings = analog-stereo-in-main analog-stereo-in-a analog-stereo-in-b analog-stereo-in-c analog-stereo-in-d
+priority = 100
+skip-probe = yes
+
+[Profile output:analog-stereo-main+input:analog-stereo-main]
+description = Analog Stereo Duplex Main
+output-mappings = analog-stereo-out-main
+input-mappings = analog-stereo-in-main
+priority = 50
+skip-probe = yes
+
+[Profile output:analog-stereo-a+input:analog-stereo-a]
+description = Analog Stereo Duplex Channel A
+output-mappings = analog-stereo-out-a
+input-mappings = analog-stereo-in-a
+priority = 40
+skip-probe = yes
+
+[Profile output:analog-stereo-b+input:analog-stereo-b]
+description = Analog Stereo Duplex Channel B
+output-mappings = analog-stereo-out-b
+input-mappings = analog-stereo-in-b
+priority = 30
+skip-probe = yes
+
+[Profile output:analog-stereo-a+input:analog-stereo-c]
+description = Analog Stereo Duplex Channel C
+output-mappings = analog-stereo-out-c
+input-mappings = analog-stereo-in-c
+priority = 20
+skip-probe = yes
+
+[Profile output:analog-stereo-a+input:analog-stereo-d]
+description = Analog Stereo Duplex Channel D
+output-mappings = analog-stereo-out-d
+input-mappings = analog-stereo-in-d
+priority = 10
+skip-probe = yes
diff --git a/src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio6.conf b/src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio6.conf
new file mode 100644
index 00000000..48d9058b
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/native-instruments-traktor-audio6.conf
@@ -0,0 +1,92 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Native Instruments Audio 6 DJ
+;
+; This card has three stereo pairs of input and three stereo pairs of
+; output
+;
+; We knowingly only define a subset of the theoretically possible
+; mapping combinations as profiles here.
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = no
+
+[Mapping analog-stereo-out-main]
+description = Analog Stereo Main
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-out-a]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-out-b]
+description = Analog Stereo Channel B
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-in-main]
+description = Analog Stereo Main
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-in-a]
+description = Analog Stereo Channel A
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = input
+
+[Mapping analog-stereo-in-b]
+description = Analog Stereo Channel B
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = input
+
+
+
+[Profile output:analog-stereo-all+input:analog-stereo-all]
+description = Analog Stereo Duplex Channels A, B (Headphones)
+output-mappings = analog-stereo-out-main analog-stereo-out-a analog-stereo-out-b
+input-mappings = analog-stereo-in-main analog-stereo-in-a analog-stereo-in-b
+priority = 100
+skip-probe = yes
+
+[Profile output:analog-stereo-main+input:analog-stereo-main]
+description = Analog Stereo Duplex Channel Main
+output-mappings = analog-stereo-out-main
+input-mappings = analog-stereo-in-main
+priority = 50
+skip-probe = yes
+
+[Profile output:analog-stereo-a+input:analog-stereo-a]
+description = Analog Stereo Duplex Channel A
+output-mappings = analog-stereo-out-a
+input-mappings = analog-stereo-in-a
+priority = 40
+skip-probe = yes
+
+[Profile output:analog-stereo-b+input:analog-stereo-b]
+description = Analog Stereo Duplex Channel B
+output-mappings = analog-stereo-out-b
+input-mappings = analog-stereo-in-b
+priority = 30
+skip-probe = yes
diff --git a/src/modules/alsa/mixer/profile-sets/native-instruments-traktorkontrol-s4.conf b/src/modules/alsa/mixer/profile-sets/native-instruments-traktorkontrol-s4.conf
new file mode 100644
index 00000000..1da843a1
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/native-instruments-traktorkontrol-s4.conf
@@ -0,0 +1,81 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Native Instruments Traktor Kontrol S4
+;
+; This controller has two stereo pairs of input (named "Channel C" and
+; "Channel D") and two stereo pairs of output, one "Main Out" and
+; "Headphone Out".
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = no
+
+[Mapping analog-stereo-output-main]
+description = Analog Stereo Main Out
+device-strings = hw:%f,0,0
+channel-map = left,right
+
+[Mapping analog-stereo-output-headphone]
+description = Analog Stereo Headphones Out
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = output
+
+[Mapping analog-stereo-c-input]
+description = Analog Stereo Channel C
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = input
+
+[Mapping analog-stereo-d-input]
+description = Analog Stereo Channel D
+device-strings = hw:%f,0,1
+channel-map = left,right
+direction = input
+
+[Profile output:analog-stereo-all+input:analog-stereo-all]
+description = Analog Stereo Duplex
+output-mappings = analog-stereo-output-main analog-stereo-output-headphone
+input-mappings = analog-stereo-c-input analog-stereo-d-input
+priority = 100
+skip-probe = yes
+
+[Profile output:analog-stereo-main]
+description = Analog Stereo Main Output
+output-mappings = analog-stereo-output-main
+priority = 4
+skip-probe = yes
+
+[Profile output:analog-stereo-headphone]
+description = Analog Stereo Output Headphones Out
+output-mappings = analog-stereo-output-headphone
+priority = 3
+skip-probe = yes
+
+[Profile input:analog-stereo-c]
+description = Analog Stereo Input Channel C
+input-mappings = analog-stereo-c-input
+priority = 2
+skip-probe = yes
+
+[Profile input:analog-stereo-d]
+description = Analog Stereo Input Channel D
+input-mappings = analog-stereo-d-input
+priority = 1
+skip-probe = yes
+
diff --git a/src/modules/alsa/mixer/profile-sets/usb-headset.conf b/src/modules/alsa/mixer/profile-sets/usb-headset.conf
new file mode 100644
index 00000000..adf78d17
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/usb-headset.conf
@@ -0,0 +1,35 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; This is a workaround - these usb headsets have one output volume control only, labeled "Speaker".
+; This causes the default profile set to not control the volume at all, which is a bug.
+
+[General]
+auto-profiles = yes
+
+[Mapping analog-mono]
+device-strings = hw:%f
+channel-map = mono
+paths-output = analog-output-speaker
+paths-input = analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line
+priority = 1
+
+[Mapping analog-stereo]
+device-strings = front:%f hw:%f
+channel-map = left,right
+paths-output = analog-output-speaker
+paths-input = analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line
+priority = 10
diff --git a/src/modules/alsa/mixer/samples/ATI IXP--Realtek ALC655 rev 0 b/src/modules/alsa/mixer/samples/ATI IXP--Realtek ALC655 rev 0
new file mode 100644
index 00000000..082c9a1b
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/ATI IXP--Realtek ALC655 rev 0
@@ -0,0 +1,150 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 29 [94%] [-3.00dB] [on]
+ Front Right: Playback 29 [94%] [-3.00dB] [on]
+Simple mixer control 'Master Mono',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 23 [74%] [0.00dB] [on]
+ Front Right: Playback 23 [74%] [0.00dB] [on]
+Simple mixer control 'Surround',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-46.50dB] [off]
+ Front Right: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Surround Jack Mode',0
+ Capabilities: enum
+ Items: 'Shared' 'Independent'
+ Item0: 'Shared'
+Simple mixer control 'Center',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'LFE',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Line',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'CD',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-34.50dB] [off]
+ Front Left: Capture [on]
+ Front Right: Capture [on]
+Simple mixer control 'Mic Boost (+20dB)',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'Mic Select',0
+ Capabilities: enum
+ Items: 'Mic1' 'Mic2'
+ Item0: 'Mic1'
+Simple mixer control 'Video',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Phone',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 31 [100%] [12.00dB] [off]
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'IEC958',0
+ Capabilities: pswitch pswitch-joined cswitch cswitch-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Mono: Playback [off] Capture [off]
+Simple mixer control 'IEC958 Playback AC97-SPSA',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 3
+ Mono: 0 [0%]
+Simple mixer control 'IEC958 Playback Source',0
+ Capabilities: enum
+ Items: 'PCM' 'Analog In' 'IEC958 In'
+ Item0: 'PCM'
+Simple mixer control 'PC Speaker',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 15
+ Mono: Playback 0 [0%] [-45.00dB] [on]
+Simple mixer control 'Aux',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [on] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [on] Capture [off]
+Simple mixer control 'Mono Output Select',0
+ Capabilities: enum
+ Items: 'Mix' 'Mic'
+ Item0: 'Mix'
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cswitch cswitch-joined
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 15
+ Front Left: Capture 12 [80%] [18.00dB] [on]
+ Front Right: Capture 12 [80%] [18.00dB] [on]
+Simple mixer control 'Mix',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Mix Mono',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Channel Mode',0
+ Capabilities: enum
+ Items: '2ch' '4ch' '6ch'
+ Item0: '2ch'
+Simple mixer control 'Duplicate Front',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'External Amplifier',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
diff --git a/src/modules/alsa/mixer/samples/Brooktree Bt878--Bt87x b/src/modules/alsa/mixer/samples/Brooktree Bt878--Bt87x
new file mode 100644
index 00000000..b8f61fab
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/Brooktree Bt878--Bt87x
@@ -0,0 +1,24 @@
+Simple mixer control 'FM',0
+ Capabilities: cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Mono
+ Mono: Capture [off]
+Simple mixer control 'Mic/Line',0
+ Capabilities: cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Mono
+ Mono: Capture [off]
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cvolume-joined
+ Capture channels: Mono
+ Limits: Capture 0 - 15
+ Mono: Capture 13 [87%]
+Simple mixer control 'Capture Boost',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
+Simple mixer control 'TV Tuner',0
+ Capabilities: cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Mono
+ Mono: Capture [on]
diff --git a/src/modules/alsa/mixer/samples/Ensoniq AudioPCI--Cirrus Logic CS4297A rev 3 b/src/modules/alsa/mixer/samples/Ensoniq AudioPCI--Cirrus Logic CS4297A rev 3
new file mode 100644
index 00000000..a500a817
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/Ensoniq AudioPCI--Cirrus Logic CS4297A rev 3
@@ -0,0 +1,135 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 63
+ Mono:
+ Front Left: Playback 63 [100%] [0.00dB] [on]
+ Front Right: Playback 63 [100%] [0.00dB] [on]
+Simple mixer control 'Master Mono',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Headphone',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-46.50dB] [off]
+ Front Right: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control '3D Control - Center',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 15
+ Mono: 0 [0%]
+Simple mixer control '3D Control - Depth',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 15
+ Mono: 0 [0%]
+Simple mixer control '3D Control - Switch',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 23 [74%] [0.00dB] [on]
+ Front Right: Playback 23 [74%] [0.00dB] [on]
+Simple mixer control 'Line',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [on]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [on]
+Simple mixer control 'CD',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 23 [74%] [0.00dB] [on]
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Mic Boost (+20dB)',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'Mic Select',0
+ Capabilities: enum
+ Items: 'Mic1' 'Mic2'
+ Item0: 'Mic1'
+Simple mixer control 'Video',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Phone',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-34.50dB] [off]
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'IEC958',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'PC Speaker',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 15
+ Mono: Playback 0 [0%] [-45.00dB] [off]
+Simple mixer control 'Aux',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Mono Output Select',0
+ Capabilities: enum
+ Items: 'Mix' 'Mic'
+ Item0: 'Mic'
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cswitch cswitch-joined
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 15
+ Front Left: Capture 15 [100%] [22.50dB] [on]
+ Front Right: Capture 15 [100%] [22.50dB] [on]
+Simple mixer control 'Mix',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Mix Mono',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'External Amplifier',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
diff --git a/src/modules/alsa/mixer/samples/HDA ATI HDMI--ATI R6xx HDMI b/src/modules/alsa/mixer/samples/HDA ATI HDMI--ATI R6xx HDMI
new file mode 100644
index 00000000..244f24a8
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/HDA ATI HDMI--ATI R6xx HDMI
@@ -0,0 +1,4 @@
+Simple mixer control 'IEC958',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
diff --git a/src/modules/alsa/mixer/samples/HDA Intel--Analog Devices AD1981 b/src/modules/alsa/mixer/samples/HDA Intel--Analog Devices AD1981
new file mode 100644
index 00000000..165522fa
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/HDA Intel--Analog Devices AD1981
@@ -0,0 +1,62 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 63
+ Mono:
+ Front Left: Playback 63 [100%] [3.00dB] [on]
+ Front Right: Playback 63 [100%] [3.00dB] [on]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 23 [74%] [0.00dB] [on]
+ Front Right: Playback 23 [74%] [0.00dB] [on]
+Simple mixer control 'CD',0
+ Capabilities: pvolume pswitch cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Capture [off]
+ Front Left: Playback 0 [0%] [-34.50dB] [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pswitch cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Capture [on]
+ Front Left: Playback 0 [0%] [-34.50dB] [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off]
+Simple mixer control 'Mic Boost',0
+ Capabilities: volume
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: 0 - 3
+ Front Left: 0 [0%]
+ Front Right: 0 [0%]
+Simple mixer control 'IEC958',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 Default PCM',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 Playback Source',0
+ Capabilities: enum
+ Items: 'PCM' 'ADC'
+ Item0: 'PCM'
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cswitch
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 15
+ Front Left: Capture 0 [0%] [0.00dB] [on]
+ Front Right: Capture 0 [0%] [0.00dB] [on]
+Simple mixer control 'Mix',0
+ Capabilities: cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Mono
+ Mono: Capture [off]
diff --git a/src/modules/alsa/mixer/samples/HDA Intel--Realtek ALC889A b/src/modules/alsa/mixer/samples/HDA Intel--Realtek ALC889A
new file mode 100644
index 00000000..28a2e73c
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/HDA Intel--Realtek ALC889A
@@ -0,0 +1,113 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 64
+ Mono: Playback 64 [100%] [0.00dB] [on]
+Simple mixer control 'Headphone',0
+ Capabilities: pswitch
+ Playback channels: Front Left - Front Right
+ Mono:
+ Front Left: Playback [on]
+ Front Right: Playback [on]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 255
+ Mono:
+ Front Left: Playback 255 [100%] [0.00dB]
+ Front Right: Playback 255 [100%] [0.00dB]
+Simple mixer control 'Front',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 64
+ Mono:
+ Front Left: Playback 44 [69%] [-20.00dB] [on]
+ Front Right: Playback 44 [69%] [-20.00dB] [on]
+Simple mixer control 'Front Mic',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-34.50dB] [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off]
+Simple mixer control 'Front Mic Boost',0
+ Capabilities: volume
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: 0 - 3
+ Front Left: 0 [0%]
+ Front Right: 0 [0%]
+Simple mixer control 'Surround',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 64
+ Mono:
+ Front Left: Playback 0 [0%] [-64.00dB] [on]
+ Front Right: Playback 0 [0%] [-64.00dB] [on]
+Simple mixer control 'Center',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 64
+ Mono: Playback 0 [0%] [-64.00dB] [on]
+Simple mixer control 'LFE',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 64
+ Mono: Playback 0 [0%] [-64.00dB] [on]
+Simple mixer control 'Side',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 64
+ Mono:
+ Front Left: Playback 0 [0%] [-64.00dB] [on]
+ Front Right: Playback 0 [0%] [-64.00dB] [on]
+Simple mixer control 'Line',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-34.50dB] [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-34.50dB] [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off]
+Simple mixer control 'Mic Boost',0
+ Capabilities: volume
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: 0 - 3
+ Front Left: 0 [0%]
+ Front Right: 0 [0%]
+Simple mixer control 'IEC958',0
+ Capabilities: pswitch pswitch-joined cswitch cswitch-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Mono: Playback [on] Capture [on]
+Simple mixer control 'IEC958 Default PCM',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cswitch
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 46
+ Front Left: Capture 23 [50%] [7.00dB] [on]
+ Front Right: Capture 23 [50%] [7.00dB] [on]
+Simple mixer control 'Capture',1
+ Capabilities: cvolume cswitch
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 46
+ Front Left: Capture 0 [0%] [-16.00dB] [off]
+ Front Right: Capture 0 [0%] [-16.00dB] [off]
+Simple mixer control 'Input Source',0
+ Capabilities: cenum
+ Items: 'Mic' 'Front Mic' 'Line'
+ Item0: 'Mic'
+Simple mixer control 'Input Source',1
+ Capabilities: cenum
+ Items: 'Mic' 'Front Mic' 'Line'
+ Item0: 'Mic'
diff --git a/src/modules/alsa/mixer/samples/Intel 82801CA-ICH3--Analog Devices AD1881A b/src/modules/alsa/mixer/samples/Intel 82801CA-ICH3--Analog Devices AD1881A
new file mode 100644
index 00000000..3ddd8af6
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/Intel 82801CA-ICH3--Analog Devices AD1881A
@@ -0,0 +1,128 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 63
+ Mono:
+ Front Left: Playback 44 [70%] [-28.50dB] [on]
+ Front Right: Playback 60 [95%] [-4.50dB] [on]
+Simple mixer control 'Master Mono',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 17 [55%] [-21.00dB] [on]
+Simple mixer control '3D Control - Center',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 15
+ Mono: 0 [0%]
+Simple mixer control '3D Control - Depth',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 15
+ Mono: 0 [0%]
+Simple mixer control '3D Control - Switch',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 9 [29%] [-21.00dB] [on]
+ Front Right: Playback 9 [29%] [-21.00dB] [on]
+Simple mixer control 'PCM Out Path & Mute',0
+ Capabilities: enum
+ Items: 'pre 3D' 'post 3D'
+ Item0: 'pre 3D'
+Simple mixer control 'Line',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'CD',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 9 [29%] [-21.00dB] [on] Capture [off]
+ Front Right: Playback 9 [29%] [-21.00dB] [on] Capture [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-34.50dB] [off]
+ Front Left: Capture [on]
+ Front Right: Capture [on]
+Simple mixer control 'Mic Boost (+20dB)',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'Mic Select',0
+ Capabilities: enum
+ Items: 'Mic1' 'Mic2'
+ Item0: 'Mic1'
+Simple mixer control 'Video',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Phone',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-34.50dB] [off]
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'PC Speaker',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 15
+ Mono: Playback 8 [53%] [-21.00dB] [on]
+Simple mixer control 'Aux',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Mono Output Select',0
+ Capabilities: enum
+ Items: 'Mix' 'Mic'
+ Item0: 'Mix'
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cswitch cswitch-joined
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 15
+ Front Left: Capture 13 [87%] [19.50dB] [on]
+ Front Right: Capture 13 [87%] [19.50dB] [on]
+Simple mixer control 'Mix',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Mix Mono',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'External Amplifier',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
diff --git a/src/modules/alsa/mixer/samples/Logitech USB Speaker--USB Mixer b/src/modules/alsa/mixer/samples/Logitech USB Speaker--USB Mixer
new file mode 100644
index 00000000..38cf6778
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/Logitech USB Speaker--USB Mixer
@@ -0,0 +1,27 @@
+Simple mixer control 'Bass',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 48
+ Mono: 22 [46%]
+Simple mixer control 'Bass Boost',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'Treble',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 48
+ Mono: 25 [52%]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 44
+ Mono:
+ Front Left: Playback 10 [23%] [-31.00dB] [on]
+ Front Right: Playback 10 [23%] [-31.00dB] [on]
+Simple mixer control 'Auto Gain Control',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
diff --git a/src/modules/alsa/mixer/samples/USB Audio--USB Mixer b/src/modules/alsa/mixer/samples/USB Audio--USB Mixer
new file mode 100644
index 00000000..9cb4fa7f
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/USB Audio--USB Mixer
@@ -0,0 +1,37 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 255
+ Mono: Playback 105 [41%] [-28.97dB] [on]
+Simple mixer control 'Line',0
+ Capabilities: pvolume cvolume pswitch pswitch-joined cswitch cswitch-joined
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 255 Capture 0 - 128
+ Front Left: Playback 191 [75%] [34.38dB] [off] Capture 0 [0%] [0.18dB] [off]
+ Front Right: Playback 191 [75%] [34.38dB] [off] Capture 0 [0%] [0.18dB] [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pvolume-joined cvolume cvolume-joined pswitch pswitch-joined cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: Playback 0 - 255 Capture 0 - 128
+ Mono: Playback 191 [75%] [34.38dB] [off] Capture 0 [0%] [0.18dB] [on]
+Simple mixer control 'Mic Capture',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 In',0
+ Capabilities: cswitch cswitch-joined
+ Capture channels: Mono
+ Mono: Capture [off]
+Simple mixer control 'Input 1',0
+ Capabilities: cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Mono
+ Mono: Capture [off]
+Simple mixer control 'Input 2',0
+ Capabilities: cswitch cswitch-joined cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Mono
+ Mono: Capture [off]
diff --git a/src/modules/alsa/mixer/samples/USB Device 0x46d:0x9a4--USB Mixer b/src/modules/alsa/mixer/samples/USB Device 0x46d:0x9a4--USB Mixer
new file mode 100644
index 00000000..783f826f
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/USB Device 0x46d:0x9a4--USB Mixer
@@ -0,0 +1,5 @@
+Simple mixer control 'Mic',0
+ Capabilities: cvolume cvolume-joined cswitch cswitch-joined
+ Capture channels: Mono
+ Limits: Capture 0 - 3072
+ Mono: Capture 1536 [50%] [23.00dB] [on]
diff --git a/src/modules/alsa/mixer/samples/VIA 8237--Analog Devices AD1888 b/src/modules/alsa/mixer/samples/VIA 8237--Analog Devices AD1888
new file mode 100644
index 00000000..15e7b5a6
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/VIA 8237--Analog Devices AD1888
@@ -0,0 +1,211 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 31 [100%] [0.00dB] [on]
+ Front Right: Playback 31 [100%] [0.00dB] [on]
+Simple mixer control 'Master Mono',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Master Surround',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-46.50dB] [off]
+ Front Right: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Headphone Jack Sense',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 23 [74%] [0.00dB] [on]
+ Front Right: Playback 23 [74%] [0.00dB] [on]
+Simple mixer control 'Surround',0
+ Capabilities: pvolume pswitch
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-46.50dB] [off]
+ Front Right: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Surround Jack Mode',0
+ Capabilities: enum
+ Items: 'Shared' 'Independent'
+ Item0: 'Shared'
+Simple mixer control 'Center',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 31 [100%] [0.00dB] [off]
+Simple mixer control 'LFE',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Line',0
+ Capabilities: pvolume pswitch cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Line Jack Sense',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'CD',0
+ Capabilities: pvolume pswitch cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-34.50dB] [off]
+ Front Left: Capture [on]
+ Front Right: Capture [on]
+Simple mixer control 'Mic Boost (+20dB)',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'Mic Select',0
+ Capabilities: enum
+ Items: 'Mic1' 'Mic2'
+ Item0: 'Mic1'
+Simple mixer control 'Video',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Phone',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Mono
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-34.50dB] [off]
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'IEC958',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 Output',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 Playback AC97-SPSA',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 3
+ Mono: 3 [100%]
+Simple mixer control 'IEC958 Playback Source',0
+ Capabilities: enum
+ Items: 'AC-Link' 'A/D Converter'
+ Item0: 'AC-Link'
+Simple mixer control 'Aux',0
+ Capabilities: pvolume pswitch cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cswitch
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 15
+ Front Left: Capture 0 [0%] [0.00dB] [on]
+ Front Right: Capture 0 [0%] [0.00dB] [on]
+Simple mixer control 'Mix',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Mix Mono',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Channel Mode',0
+ Capabilities: enum
+ Items: '2ch' '4ch' '6ch'
+ Item0: '2ch'
+Simple mixer control 'Downmix',0
+ Capabilities: enum
+ Items: 'Off' '6 -> 4' '6 -> 2'
+ Item0: 'Off'
+Simple mixer control 'Exchange Front/Surround',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'External Amplifier',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
+Simple mixer control 'High Pass Filter Enable',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'Input Source Select',0
+ Capabilities: enum
+ Items: 'Input1' 'Input2'
+ Item0: 'Input1'
+Simple mixer control 'Input Source Select',1
+ Capabilities: enum
+ Items: 'Input1' 'Input2'
+ Item0: 'Input1'
+Simple mixer control 'Spread Front to Surround and Center/LFE',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'VIA DXS',0
+ Capabilities: pvolume
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 31 [100%] [-48.00dB]
+ Front Right: Playback 31 [100%] [-48.00dB]
+Simple mixer control 'VIA DXS',1
+ Capabilities: pvolume
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 31 [100%] [-48.00dB]
+ Front Right: Playback 31 [100%] [-48.00dB]
+Simple mixer control 'VIA DXS',2
+ Capabilities: pvolume
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 31 [100%] [-48.00dB]
+ Front Right: Playback 31 [100%] [-48.00dB]
+Simple mixer control 'VIA DXS',3
+ Capabilities: pvolume
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 31 [100%] [-48.00dB]
+ Front Right: Playback 31 [100%] [-48.00dB]
+Simple mixer control 'V_REFOUT Enable',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
diff --git a/src/modules/alsa/mixer/samples/VIA 8237--C-Media Electronics CMI9761A+ b/src/modules/alsa/mixer/samples/VIA 8237--C-Media Electronics CMI9761A+
new file mode 100644
index 00000000..d4f3db62
--- /dev/null
+++ b/src/modules/alsa/mixer/samples/VIA 8237--C-Media Electronics CMI9761A+
@@ -0,0 +1,160 @@
+Simple mixer control 'Master',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 0 [0%] [-46.50dB] [off]
+ Front Right: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'PCM',0
+ Capabilities: pvolume pswitch pswitch-joined
+ Playback channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Mono:
+ Front Left: Playback 31 [100%] [-48.00dB] [off]
+ Front Right: Playback 31 [100%] [-48.00dB] [off]
+Simple mixer control 'Surround',0
+ Capabilities: pswitch
+ Playback channels: Front Left - Front Right
+ Mono:
+ Front Left: Playback [off]
+ Front Right: Playback [off]
+Simple mixer control 'Surround Jack Mode',0
+ Capabilities: enum
+ Items: 'Shared' 'Independent'
+ Item0: 'Shared'
+Simple mixer control 'Center',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 31 [100%] [0.00dB] [off]
+Simple mixer control 'LFE',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 31
+ Mono: Playback 0 [0%] [-46.50dB] [off]
+Simple mixer control 'Line',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'CD',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Mic',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [on]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [on]
+Simple mixer control 'Mic Boost (+20dB)',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'Mic Select',0
+ Capabilities: enum
+ Items: 'Mic1' 'Mic2'
+ Item0: 'Mic1'
+Simple mixer control 'Video',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Phone',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'IEC958',0
+ Capabilities: pswitch pswitch-joined cswitch cswitch-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Mono: Playback [off] Capture [off]
+Simple mixer control 'IEC958 Capture Monitor',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 Capture Valid',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 Output',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [off]
+Simple mixer control 'IEC958 Playback AC97-SPSA',0
+ Capabilities: volume volume-joined
+ Playback channels: Mono
+ Capture channels: Mono
+ Limits: 0 - 3
+ Mono: 3 [100%]
+Simple mixer control 'IEC958 Playback Source',0
+ Capabilities: enum
+ Items: 'AC-Link' 'ADC' 'SPDIF-In'
+ Item0: 'AC-Link'
+Simple mixer control 'PC Speaker',0
+ Capabilities: pvolume pvolume-joined pswitch pswitch-joined
+ Playback channels: Mono
+ Limits: Playback 0 - 15
+ Mono: Playback 0 [0%] [-45.00dB] [off]
+Simple mixer control 'Aux',0
+ Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Playback channels: Front Left - Front Right
+ Capture channels: Front Left - Front Right
+ Limits: Playback 0 - 31
+ Front Left: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+ Front Right: Playback 0 [0%] [-34.50dB] [off] Capture [off]
+Simple mixer control 'Mono Output Select',0
+ Capabilities: enum
+ Items: 'Mix' 'Mic'
+ Item0: 'Mix'
+Simple mixer control 'Capture',0
+ Capabilities: cvolume cswitch cswitch-joined
+ Capture channels: Front Left - Front Right
+ Limits: Capture 0 - 15
+ Front Left: Capture 0 [0%] [0.00dB] [on]
+ Front Right: Capture 0 [0%] [0.00dB] [on]
+Simple mixer control 'Mix',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Mix Mono',0
+ Capabilities: cswitch cswitch-exclusive
+ Capture exclusive group: 0
+ Capture channels: Front Left - Front Right
+ Front Left: Capture [off]
+ Front Right: Capture [off]
+Simple mixer control 'Channel Mode',0
+ Capabilities: enum
+ Items: '2ch' '4ch' '6ch'
+ Item0: '2ch'
+Simple mixer control 'DAC Clock Source',0
+ Capabilities: enum
+ Items: 'AC-Link' 'SPDIF-In' 'Both'
+ Item0: 'AC-Link'
+Simple mixer control 'External Amplifier',0
+ Capabilities: pswitch pswitch-joined
+ Playback channels: Mono
+ Mono: Playback [on]
+Simple mixer control 'Input Source Select',0
+ Capabilities: enum
+ Items: 'Input1' 'Input2'
+ Item0: 'Input1'
+Simple mixer control 'Input Source Select',1
+ Capabilities: enum
+ Items: 'Input1' 'Input2'
+ Item0: 'Input1'
diff --git a/src/modules/alsa/module-alsa-card.c b/src/modules/alsa/module-alsa-card.c
index ad52f5e3..e60aa5ef 100644
--- a/src/modules/alsa/module-alsa-card.c
+++ b/src/modules/alsa/module-alsa-card.c
@@ -32,6 +32,10 @@
#include <modules/reserve-wrap.h>
+#ifdef HAVE_UDEV
+#include <modules/udev-util.h>
+#endif
+
#include "alsa-util.h"
#include "alsa-sink.h"
#include "alsa-source.h"
@@ -49,6 +53,7 @@ PA_MODULE_USAGE(
"sink_properties=<properties for the sink> "
"source_name=<name for the source> "
"source_properties=<properties for the source> "
+ "namereg_fail=<pa_namereg_register() fail parameter value> "
"device_id=<ALSA card index> "
"format=<sample format> "
"rate=<sample rate> "
@@ -59,7 +64,9 @@ PA_MODULE_USAGE(
"tsched_buffer_size=<buffer size when using timer based scheduling> "
"tsched_buffer_watermark=<lower fill watermark> "
"profile=<profile name> "
- "ignore_dB=<ignore dB information from the device?>");
+ "ignore_dB=<ignore dB information from the device?> "
+ "sync_volume=<syncronize sw and hw voluchanges in IO-thread?> "
+ "profile_set=<profile set configuration file> ");
static const char* const valid_modargs[] = {
"name",
@@ -69,6 +76,7 @@ static const char* const valid_modargs[] = {
"sink_properties",
"source_name",
"source_properties",
+ "namereg_fail",
"device_id",
"format",
"rate",
@@ -80,6 +88,8 @@ static const char* const valid_modargs[] = {
"tsched_buffer_watermark",
"profile",
"ignore_dB",
+ "sync_volume",
+ "profile_set",
NULL
};
@@ -92,81 +102,53 @@ struct userdata {
char *device_id;
pa_card *card;
- pa_sink *sink;
- pa_source *source;
pa_modargs *modargs;
- pa_hashmap *profiles;
+ pa_alsa_profile_set *profile_set;
};
struct profile_data {
- const pa_alsa_profile_info *sink_profile, *source_profile;
+ pa_alsa_profile *profile;
};
-static void enumerate_cb(
- const pa_alsa_profile_info *sink,
- const pa_alsa_profile_info *source,
- void *userdata) {
-
- struct userdata *u = userdata;
- char *t, *n;
- pa_card_profile *p;
- struct profile_data *d;
- unsigned bonus = 0;
-
- if (sink && source) {
- n = pa_sprintf_malloc("output-%s+input-%s", sink->name, source->name);
- t = pa_sprintf_malloc(_("Output %s + Input %s"), sink->description, _(source->description));
- } else if (sink) {
- n = pa_sprintf_malloc("output-%s", sink->name);
- t = pa_sprintf_malloc(_("Output %s"), _(sink->description));
- } else {
- pa_assert(source);
- n = pa_sprintf_malloc("input-%s", source->name);
- t = pa_sprintf_malloc(_("Input %s"), _(source->description));
- }
-
- if (sink) {
- if (pa_channel_map_equal(&sink->map, &u->core->default_channel_map))
- bonus += 50000;
- else if (sink->map.channels == u->core->default_channel_map.channels)
- bonus += 40000;
- }
+static void add_profiles(struct userdata *u, pa_hashmap *h) {
+ pa_alsa_profile *ap;
+ void *state;
- if (source) {
- if (pa_channel_map_equal(&source->map, &u->core->default_channel_map))
- bonus += 30000;
- else if (source->map.channels == u->core->default_channel_map.channels)
- bonus += 20000;
- }
-
- pa_log_info("Found profile '%s'", t);
+ pa_assert(u);
+ pa_assert(h);
- p = pa_card_profile_new(n, t, sizeof(struct profile_data));
+ PA_HASHMAP_FOREACH(ap, u->profile_set->profiles, state) {
+ struct profile_data *d;
+ pa_card_profile *cp;
+ pa_alsa_mapping *m;
+ uint32_t idx;
- pa_xfree(t);
- pa_xfree(n);
+ cp = pa_card_profile_new(ap->name, ap->description, sizeof(struct profile_data));
+ cp->priority = ap->priority;
- p->priority =
- (sink ? sink->priority : 0) * 100 +
- (source ? source->priority : 0) +
- bonus;
+ if (ap->output_mappings) {
+ cp->n_sinks = pa_idxset_size(ap->output_mappings);
- p->n_sinks = !!sink;
- p->n_sources = !!source;
+ PA_IDXSET_FOREACH(m, ap->output_mappings, idx)
+ if (m->channel_map.channels > cp->max_sink_channels)
+ cp->max_sink_channels = m->channel_map.channels;
+ }
- if (sink)
- p->max_sink_channels = sink->map.channels;
- if (source)
- p->max_source_channels = source->map.channels;
+ if (ap->input_mappings) {
+ cp->n_sources = pa_idxset_size(ap->input_mappings);
- d = PA_CARD_PROFILE_DATA(p);
+ PA_IDXSET_FOREACH(m, ap->input_mappings, idx)
+ if (m->channel_map.channels > cp->max_source_channels)
+ cp->max_source_channels = m->channel_map.channels;
+ }
- d->sink_profile = sink;
- d->source_profile = source;
+ d = PA_CARD_PROFILE_DATA(cp);
+ d->profile = ap;
- pa_hashmap_put(u->profiles, p->name, p);
+ pa_hashmap_put(h, cp->name, cp);
+ }
}
static void add_disabled_profile(pa_hashmap *profiles) {
@@ -176,7 +158,7 @@ static void add_disabled_profile(pa_hashmap *profiles) {
p = pa_card_profile_new("off", _("Off"), sizeof(struct profile_data));
d = PA_CARD_PROFILE_DATA(p);
- d->sink_profile = d->source_profile = NULL;
+ d->profile = NULL;
pa_hashmap_put(profiles, p->name, p);
}
@@ -184,6 +166,9 @@ static void add_disabled_profile(pa_hashmap *profiles) {
static int card_set_profile(pa_card *c, pa_card_profile *new_profile) {
struct userdata *u;
struct profile_data *nd, *od;
+ uint32_t idx;
+ pa_alsa_mapping *am;
+ pa_queue *sink_inputs = NULL, *source_outputs = NULL;
pa_assert(c);
pa_assert(new_profile);
@@ -192,67 +177,85 @@ static int card_set_profile(pa_card *c, pa_card_profile *new_profile) {
nd = PA_CARD_PROFILE_DATA(new_profile);
od = PA_CARD_PROFILE_DATA(c->active_profile);
- if (od->sink_profile != nd->sink_profile) {
- pa_queue *inputs = NULL;
+ if (od->profile && od->profile->output_mappings)
+ PA_IDXSET_FOREACH(am, od->profile->output_mappings, idx) {
+ if (!am->sink)
+ continue;
- if (u->sink) {
- if (nd->sink_profile)
- inputs = pa_sink_move_all_start(u->sink);
+ if (nd->profile &&
+ nd->profile->output_mappings &&
+ pa_idxset_get_by_data(nd->profile->output_mappings, am, NULL))
+ continue;
- pa_alsa_sink_free(u->sink);
- u->sink = NULL;
+ sink_inputs = pa_sink_move_all_start(am->sink, sink_inputs);
+ pa_alsa_sink_free(am->sink);
+ am->sink = NULL;
}
- if (nd->sink_profile) {
- u->sink = pa_alsa_sink_new(c->module, u->modargs, __FILE__, c, nd->sink_profile);
+ if (od->profile && od->profile->input_mappings)
+ PA_IDXSET_FOREACH(am, od->profile->input_mappings, idx) {
+ if (!am->source)
+ continue;
- if (inputs) {
- if (u->sink)
- pa_sink_move_all_finish(u->sink, inputs, FALSE);
- else
- pa_sink_move_all_fail(inputs);
- }
+ if (nd->profile &&
+ nd->profile->input_mappings &&
+ pa_idxset_get_by_data(nd->profile->input_mappings, am, NULL))
+ continue;
+
+ source_outputs = pa_source_move_all_start(am->source, source_outputs);
+ pa_alsa_source_free(am->source);
+ am->source = NULL;
}
- }
- if (od->source_profile != nd->source_profile) {
- pa_queue *outputs = NULL;
+ if (nd->profile && nd->profile->output_mappings)
+ PA_IDXSET_FOREACH(am, nd->profile->output_mappings, idx) {
- if (u->source) {
- if (nd->source_profile)
- outputs = pa_source_move_all_start(u->source);
+ if (!am->sink)
+ am->sink = pa_alsa_sink_new(c->module, u->modargs, __FILE__, c, am);
- pa_alsa_source_free(u->source);
- u->source = NULL;
+ if (sink_inputs && am->sink) {
+ pa_sink_move_all_finish(am->sink, sink_inputs, FALSE);
+ sink_inputs = NULL;
+ }
}
- if (nd->source_profile) {
- u->source = pa_alsa_source_new(c->module, u->modargs, __FILE__, c, nd->source_profile);
+ if (nd->profile && nd->profile->input_mappings)
+ PA_IDXSET_FOREACH(am, nd->profile->input_mappings, idx) {
+
+ if (!am->source)
+ am->source = pa_alsa_source_new(c->module, u->modargs, __FILE__, c, am);
- if (outputs) {
- if (u->source)
- pa_source_move_all_finish(u->source, outputs, FALSE);
- else
- pa_source_move_all_fail(outputs);
+ if (source_outputs && am->source) {
+ pa_source_move_all_finish(am->source, source_outputs, FALSE);
+ source_outputs = NULL;
}
}
- }
+
+ if (sink_inputs)
+ pa_sink_move_all_fail(sink_inputs);
+
+ if (source_outputs)
+ pa_source_move_all_fail(source_outputs);
return 0;
}
static void init_profile(struct userdata *u) {
+ uint32_t idx;
+ pa_alsa_mapping *am;
struct profile_data *d;
pa_assert(u);
d = PA_CARD_PROFILE_DATA(u->card->active_profile);
- if (d->sink_profile)
- u->sink = pa_alsa_sink_new(u->module, u->modargs, __FILE__, u->card, d->sink_profile);
+ if (d->profile && d->profile->output_mappings)
+ PA_IDXSET_FOREACH(am, d->profile->output_mappings, idx)
+ am->sink = pa_alsa_sink_new(u->module, u->modargs, __FILE__, u->card, am);
- if (d->source_profile)
- u->source = pa_alsa_source_new(u->module, u->modargs, __FILE__, u->card, d->source_profile);
+ if (d->profile && d->profile->input_mappings)
+ PA_IDXSET_FOREACH(am, d->profile->input_mappings, idx)
+ am->source = pa_alsa_source_new(u->module, u->modargs, __FILE__, u->card, am);
}
static void set_card_name(pa_card_new_data *data, pa_modargs *ma, const char *device_id) {
@@ -286,12 +289,12 @@ int pa__init(pa_module *m) {
pa_modargs *ma;
int alsa_card_index;
struct userdata *u;
- char rname[32];
pa_reserve_wrapper *reserve = NULL;
const char *description;
+ char *fn = NULL;
+ pa_bool_t namereg_fail = FALSE;
- pa_alsa_redirect_errors_inc();
- snd_config_update_free_global();
+ pa_alsa_refcnt_inc();
pa_assert(m);
@@ -300,13 +303,10 @@ int pa__init(pa_module *m) {
goto fail;
}
- m->userdata = u = pa_xnew(struct userdata, 1);
+ m->userdata = u = pa_xnew0(struct userdata, 1);
u->core = m->core;
u->module = m;
u->device_id = pa_xstrdup(pa_modargs_get_value(ma, "device_id", DEFAULT_DEVICE_ID));
- u->card = NULL;
- u->sink = NULL;
- u->source = NULL;
u->modargs = ma;
if ((alsa_card_index = snd_card_get_index(u->device_id)) < 0) {
@@ -314,29 +314,64 @@ int pa__init(pa_module *m) {
goto fail;
}
- pa_snprintf(rname, sizeof(rname), "Audio%i", alsa_card_index);
+ if (!pa_in_system_mode()) {
+ char *rname;
+
+ if ((rname = pa_alsa_get_reserve_name(u->device_id))) {
+ reserve = pa_reserve_wrapper_get(m->core, rname);
+ pa_xfree(rname);
+
+ if (!reserve)
+ goto fail;
+ }
+ }
+
+#ifdef HAVE_UDEV
+ fn = pa_udev_get_property(alsa_card_index, "PULSE_PROFILE_SET");
+#endif
+
+ if (pa_modargs_get_value(ma, "profile_set", NULL)) {
+ pa_xfree(fn);
+ fn = pa_xstrdup(pa_modargs_get_value(ma, "profile_set", NULL));
+ }
+
+ u->profile_set = pa_alsa_profile_set_new(fn, &u->core->default_channel_map);
+ pa_xfree(fn);
- if (!pa_in_system_mode())
- if (!(reserve = pa_reserve_wrapper_get(m->core, rname)))
- goto fail;
+ if (!u->profile_set)
+ goto fail;
+
+ pa_alsa_profile_set_probe(u->profile_set, u->device_id, &m->core->default_sample_spec, m->core->default_n_fragments, m->core->default_fragment_size_msec);
+ pa_alsa_profile_set_dump(u->profile_set);
pa_card_new_data_init(&data);
data.driver = __FILE__;
data.module = m;
+
pa_alsa_init_proplist_card(m->core, data.proplist, alsa_card_index);
+
pa_proplist_sets(data.proplist, PA_PROP_DEVICE_STRING, u->device_id);
pa_alsa_init_description(data.proplist);
set_card_name(&data, ma, u->device_id);
+ /* We need to give pa_modargs_get_value_boolean() a pointer to a local
+ * variable instead of using &data.namereg_fail directly, because
+ * data.namereg_fail is a bitfield and taking the address of a bitfield
+ * variable is impossible. */
+ namereg_fail = data.namereg_fail;
+ if (pa_modargs_get_value_boolean(ma, "namereg_fail", &namereg_fail) < 0) {
+ pa_log("Failed to parse boolean argument namereg_fail.");
+ pa_card_new_data_done(&data);
+ goto fail;
+ }
+ data.namereg_fail = namereg_fail;
+
if (reserve)
if ((description = pa_proplist_gets(data.proplist, PA_PROP_DEVICE_DESCRIPTION)))
pa_reserve_wrapper_set_application_device_name(reserve, description);
- u->profiles = data.profiles = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
- if (pa_alsa_probe_profiles(u->device_id, &m->core->default_sample_spec, enumerate_cb, u) < 0) {
- pa_card_new_data_done(&data);
- goto fail;
- }
+ data.profiles = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ add_profiles(u, data.profiles);
if (pa_hashmap_isempty(data.profiles)) {
pa_log("Failed to find a working profile.");
@@ -366,6 +401,14 @@ int pa__init(pa_module *m) {
if (reserve)
pa_reserve_wrapper_unref(reserve);
+ if (!pa_hashmap_isempty(u->profile_set->decibel_fixes))
+ pa_log_warn("Card %s uses decibel fixes (i.e. overrides the decibel information for some alsa volume elements). "
+ "Please note that this feature is meant just as a help for figuring out the correct decibel values. "
+ "Pulseaudio is not the correct place to maintain the decibel mappings! The fixed decibel values "
+ "should be sent to ALSA developers so that they can fix the driver. If it turns out that this feature "
+ "is abused (i.e. fixes are not pushed to ALSA), the decibel fix feature may be removed in some future "
+ "Pulseaudio version.", u->card->name);
+
return 0;
fail:
@@ -379,13 +422,22 @@ fail:
int pa__get_n_used(pa_module *m) {
struct userdata *u;
+ int n = 0;
+ uint32_t idx;
+ pa_sink *sink;
+ pa_source *source;
pa_assert(m);
pa_assert_se(u = m->userdata);
+ pa_assert(u->card);
- return
- (u->sink ? pa_sink_linked_by(u->sink) : 0) +
- (u->source ? pa_source_linked_by(u->source) : 0);
+ PA_IDXSET_FOREACH(sink, u->card->sinks, idx)
+ n += pa_sink_linked_by(sink);
+
+ PA_IDXSET_FOREACH(source, u->card->sources, idx)
+ n += pa_source_linked_by(source);
+
+ return n;
}
void pa__done(pa_module*m) {
@@ -396,11 +448,19 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
goto finish;
- if (u->sink)
- pa_alsa_sink_free(u->sink);
+ if (u->card && u->card->sinks) {
+ pa_sink *s;
+
+ while ((s = pa_idxset_steal_first(u->card->sinks, NULL)))
+ pa_alsa_sink_free(s);
+ }
- if (u->source)
- pa_alsa_source_free(u->source);
+ if (u->card && u->card->sources) {
+ pa_source *s;
+
+ while ((s = pa_idxset_steal_first(u->card->sources, NULL)))
+ pa_alsa_source_free(s);
+ }
if (u->card)
pa_card_free(u->card);
@@ -408,10 +468,12 @@ void pa__done(pa_module*m) {
if (u->modargs)
pa_modargs_free(u->modargs);
+ if (u->profile_set)
+ pa_alsa_profile_set_free(u->profile_set);
+
pa_xfree(u->device_id);
pa_xfree(u);
finish:
- snd_config_update_free_global();
- pa_alsa_redirect_errors_dec();
+ pa_alsa_refcnt_dec();
}
diff --git a/src/modules/alsa/module-alsa-sink.c b/src/modules/alsa/module-alsa-sink.c
index 058ea205..6e64ab31 100644
--- a/src/modules/alsa/module-alsa-sink.c
+++ b/src/modules/alsa/module-alsa-sink.c
@@ -24,7 +24,6 @@
#include <config.h>
#endif
-#include <pulsecore/core.h>
#include <pulsecore/module.h>
#include <pulsecore/sink.h>
#include <pulsecore/modargs.h>
@@ -40,7 +39,8 @@ PA_MODULE_LOAD_ONCE(FALSE);
PA_MODULE_USAGE(
"name=<name of the sink, to be prefixed> "
"sink_name=<name for the sink> "
- "sink_properities=<properties for the sink> "
+ "sink_properties=<properties for the sink> "
+ "namereg_fail=<pa_namereg_register() fail parameter value> "
"device=<ALSA device> "
"device_id=<ALSA card index> "
"format=<sample format> "
@@ -54,12 +54,17 @@ PA_MODULE_USAGE(
"tsched_buffer_size=<buffer size when using timer based scheduling> "
"tsched_buffer_watermark=<lower fill watermark> "
"ignore_dB=<ignore dB information from the device?> "
- "control=<name of mixer control>");
+ "control=<name of mixer control> "
+ "rewind_safeguard=<number of bytes that cannot be rewound> "
+ "sync_volume=<syncronize sw and hw voluchanges in IO-thread?> "
+ "sync_volume_safety_margin=<usec adjustment depending on volume direction> "
+ "sync_volume_extra_delay=<usec adjustment to HW volume changes>");
static const char* const valid_modargs[] = {
"name",
"sink_name",
"sink_properties",
+ "namereg_fail",
"device",
"device_id",
"format",
@@ -74,6 +79,10 @@ static const char* const valid_modargs[] = {
"tsched_buffer_watermark",
"ignore_dB",
"control",
+ "rewind_safeguard",
+ "sync_volume",
+ "sync_volume_safety_margin",
+ "sync_volume_extra_delay",
NULL
};
@@ -82,8 +91,7 @@ int pa__init(pa_module*m) {
pa_assert(m);
- pa_alsa_redirect_errors_inc();
- snd_config_update_free_global();
+ pa_alsa_refcnt_inc();
if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
pa_log("Failed to parse module arguments");
@@ -124,6 +132,5 @@ void pa__done(pa_module*m) {
if ((sink = m->userdata))
pa_alsa_sink_free(sink);
- snd_config_update_free_global();
- pa_alsa_redirect_errors_dec();
+ pa_alsa_refcnt_dec();
}
diff --git a/src/modules/alsa/module-alsa-source.c b/src/modules/alsa/module-alsa-source.c
index 3bd1b451..5ecd1e34 100644
--- a/src/modules/alsa/module-alsa-source.c
+++ b/src/modules/alsa/module-alsa-source.c
@@ -32,26 +32,10 @@
#include <valgrind/memcheck.h>
#endif
-#include <pulse/xmalloc.h>
-#include <pulse/util.h>
-#include <pulse/timeval.h>
-
-#include <pulsecore/core-error.h>
-#include <pulsecore/core.h>
#include <pulsecore/module.h>
-#include <pulsecore/memchunk.h>
-#include <pulsecore/sink.h>
#include <pulsecore/modargs.h>
-#include <pulsecore/core-util.h>
-#include <pulsecore/sample-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
-#include <pulsecore/thread.h>
-#include <pulsecore/core-error.h>
-#include <pulsecore/thread-mq.h>
-#include <pulsecore/rtpoll.h>
-#include <pulsecore/time-smoother.h>
-#include <pulsecore/rtclock.h>
#include "alsa-util.h"
#include "alsa-source.h"
@@ -65,6 +49,7 @@ PA_MODULE_USAGE(
"name=<name for the source, to be prefixed> "
"source_name=<name for the source> "
"source_properties=<properties for the source> "
+ "namereg_fail=<pa_namereg_register() fail parameter value> "
"device=<ALSA device> "
"device_id=<ALSA card index> "
"format=<sample format> "
@@ -78,12 +63,16 @@ PA_MODULE_USAGE(
"tsched_buffer_size=<buffer size when using timer based scheduling> "
"tsched_buffer_watermark=<upper fill watermark> "
"ignore_dB=<ignore dB information from the device?> "
- "control=<name of mixer control>");
+ "control=<name of mixer control>"
+ "sync_volume=<syncronize sw and hw voluchanges in IO-thread?> "
+ "sync_volume_safety_margin=<usec adjustment depending on volume direction> "
+ "sync_volume_extra_delay=<usec adjustment to HW volume changes>");
static const char* const valid_modargs[] = {
"name",
"source_name",
"source_properties",
+ "namereg_fail",
"device",
"device_id",
"format",
@@ -98,6 +87,9 @@ static const char* const valid_modargs[] = {
"tsched_buffer_watermark",
"ignore_dB",
"control",
+ "sync_volume",
+ "sync_volume_safety_margin",
+ "sync_volume_extra_delay",
NULL
};
@@ -106,8 +98,7 @@ int pa__init(pa_module*m) {
pa_assert(m);
- pa_alsa_redirect_errors_inc();
- snd_config_update_free_global();
+ pa_alsa_refcnt_inc();
if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
pa_log("Failed to parse module arguments");
@@ -148,6 +139,5 @@ void pa__done(pa_module*m) {
if ((source = m->userdata))
pa_alsa_source_free(source);
- snd_config_update_free_global();
- pa_alsa_redirect_errors_dec();
+ pa_alsa_refcnt_dec();
}
diff --git a/src/modules/bluetooth/Makefile b/src/modules/bluetooth/Makefile
deleted file mode 120000
index efe5a336..00000000
--- a/src/modules/bluetooth/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../../pulse/Makefile \ No newline at end of file
diff --git a/src/modules/bluetooth/a2dp-codecs.h b/src/modules/bluetooth/a2dp-codecs.h
new file mode 100644
index 00000000..e44634ea
--- /dev/null
+++ b/src/modules/bluetooth/a2dp-codecs.h
@@ -0,0 +1,116 @@
+/*
+ *
+ * BlueZ - Bluetooth protocol stack for Linux
+ *
+ * Copyright (C) 2006-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#define A2DP_CODEC_SBC 0x00
+#define A2DP_CODEC_MPEG12 0x01
+#define A2DP_CODEC_MPEG24 0x02
+#define A2DP_CODEC_ATRAC 0x03
+
+#define SBC_SAMPLING_FREQ_16000 (1 << 3)
+#define SBC_SAMPLING_FREQ_32000 (1 << 2)
+#define SBC_SAMPLING_FREQ_44100 (1 << 1)
+#define SBC_SAMPLING_FREQ_48000 1
+
+#define SBC_CHANNEL_MODE_MONO (1 << 3)
+#define SBC_CHANNEL_MODE_DUAL_CHANNEL (1 << 2)
+#define SBC_CHANNEL_MODE_STEREO (1 << 1)
+#define SBC_CHANNEL_MODE_JOINT_STEREO 1
+
+#define SBC_BLOCK_LENGTH_4 (1 << 3)
+#define SBC_BLOCK_LENGTH_8 (1 << 2)
+#define SBC_BLOCK_LENGTH_12 (1 << 1)
+#define SBC_BLOCK_LENGTH_16 1
+
+#define SBC_SUBBANDS_4 (1 << 1)
+#define SBC_SUBBANDS_8 1
+
+#define SBC_ALLOCATION_SNR (1 << 1)
+#define SBC_ALLOCATION_LOUDNESS 1
+
+#define MPEG_CHANNEL_MODE_MONO (1 << 3)
+#define MPEG_CHANNEL_MODE_DUAL_CHANNEL (1 << 2)
+#define MPEG_CHANNEL_MODE_STEREO (1 << 1)
+#define MPEG_CHANNEL_MODE_JOINT_STEREO 1
+
+#define MPEG_LAYER_MP1 (1 << 2)
+#define MPEG_LAYER_MP2 (1 << 1)
+#define MPEG_LAYER_MP3 1
+
+#define MPEG_SAMPLING_FREQ_16000 (1 << 5)
+#define MPEG_SAMPLING_FREQ_22050 (1 << 4)
+#define MPEG_SAMPLING_FREQ_24000 (1 << 3)
+#define MPEG_SAMPLING_FREQ_32000 (1 << 2)
+#define MPEG_SAMPLING_FREQ_44100 (1 << 1)
+#define MPEG_SAMPLING_FREQ_48000 1
+
+#define MAX_BITPOOL 64
+#define MIN_BITPOOL 2
+
+#if __BYTE_ORDER == __LITTLE_ENDIAN
+
+typedef struct {
+ uint8_t channel_mode:4;
+ uint8_t frequency:4;
+ uint8_t allocation_method:2;
+ uint8_t subbands:2;
+ uint8_t block_length:4;
+ uint8_t min_bitpool;
+ uint8_t max_bitpool;
+} __attribute__ ((packed)) a2dp_sbc_t;
+
+typedef struct {
+ uint8_t channel_mode:4;
+ uint8_t crc:1;
+ uint8_t layer:3;
+ uint8_t frequency:6;
+ uint8_t mpf:1;
+ uint8_t rfa:1;
+ uint16_t bitrate;
+} __attribute__ ((packed)) a2dp_mpeg_t;
+
+#elif __BYTE_ORDER == __BIG_ENDIAN
+
+typedef struct {
+ uint8_t frequency:4;
+ uint8_t channel_mode:4;
+ uint8_t block_length:4;
+ uint8_t subbands:2;
+ uint8_t allocation_method:2;
+ uint8_t min_bitpool;
+ uint8_t max_bitpool;
+} __attribute__ ((packed)) a2dp_sbc_t;
+
+typedef struct {
+ uint8_t layer:3;
+ uint8_t crc:1;
+ uint8_t channel_mode:4;
+ uint8_t rfa:1;
+ uint8_t mpf:1;
+ uint8_t frequency:6;
+ uint16_t bitrate;
+} __attribute__ ((packed)) a2dp_mpeg_t;
+
+#else
+#error "Unknown byte order"
+#endif
diff --git a/src/modules/bluetooth/bluetooth-util.c b/src/modules/bluetooth/bluetooth-util.c
index 5c7681d4..b24fe7a3 100644
--- a/src/modules/bluetooth/bluetooth-util.c
+++ b/src/modules/bluetooth/bluetooth-util.c
@@ -1,7 +1,7 @@
/***
This file is part of PulseAudio.
- Copyright 2008 Joao Paulo Rechi Vita
+ Copyright 2008-2009 Joao Paulo Rechi Vita
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as
@@ -23,11 +23,43 @@
#include <config.h>
#endif
+#include <pulse/xmalloc.h>
+
#include <pulsecore/core-util.h>
#include <pulsecore/shared.h>
#include <pulsecore/dbus-shared.h>
#include "bluetooth-util.h"
+#include "ipc.h"
+#include "a2dp-codecs.h"
+
+#define HFP_AG_ENDPOINT "/MediaEndpoint/HFPAG"
+#define A2DP_SOURCE_ENDPOINT "/MediaEndpoint/A2DPSource"
+#define A2DP_SINK_ENDPOINT "/MediaEndpoint/A2DPSink"
+
+#define ENDPOINT_INTROSPECT_XML \
+ DBUS_INTROSPECT_1_0_XML_DOCTYPE_DECL_NODE \
+ "<node>" \
+ " <interface name=\"org.bluez.MediaEndpoint\">" \
+ " <method name=\"SetConfiguration\">" \
+ " <arg name=\"transport\" direction=\"in\" type=\"o\"/>" \
+ " <arg name=\"configuration\" direction=\"in\" type=\"ay\"/>" \
+ " </method>" \
+ " <method name=\"SelectConfiguration\">" \
+ " <arg name=\"capabilities\" direction=\"in\" type=\"ay\"/>" \
+ " <arg name=\"configuration\" direction=\"out\" type=\"ay\"/>" \
+ " </method>" \
+ " <method name=\"ClearConfiguration\">" \
+ " </method>" \
+ " <method name=\"Release\">" \
+ " </method>" \
+ " </interface>" \
+ " <interface name=\"org.freedesktop.DBus.Introspectable\">" \
+ " <method name=\"Introspect\">" \
+ " <arg name=\"data\" type=\"s\" direction=\"out\"/>" \
+ " </method>" \
+ " </interface>" \
+ "</node>"
struct pa_bluetooth_discovery {
PA_REFCNT_DECLARE;
@@ -37,10 +69,11 @@ struct pa_bluetooth_discovery {
PA_LLIST_HEAD(pa_dbus_pending, pending);
pa_hashmap *devices;
pa_hook hook;
+ pa_bool_t filter_added;
};
static void get_properties_reply(DBusPendingCall *pending, void *userdata);
-static pa_dbus_pending* send_and_add_to_pending(pa_bluetooth_discovery *y, pa_bluetooth_device *d, DBusMessage *m, DBusPendingCallNotifyFunction func);
+static pa_dbus_pending* send_and_add_to_pending(pa_bluetooth_discovery *y, DBusMessage *m, DBusPendingCallNotifyFunction func, void *call_data);
static pa_bt_audio_state_t pa_bt_audio_state_from_string(const char* value) {
pa_assert(value);
@@ -85,6 +118,7 @@ static pa_bluetooth_device* device_new(const char *path) {
d->name = NULL;
d->path = pa_xstrdup(path);
+ d->transports = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
d->paired = -1;
d->alias = NULL;
d->device_connected = -1;
@@ -95,16 +129,32 @@ static pa_bluetooth_device* device_new(const char *path) {
d->audio_state = PA_BT_AUDIO_STATE_INVALID;
d->audio_sink_state = PA_BT_AUDIO_STATE_INVALID;
+ d->audio_source_state = PA_BT_AUDIO_STATE_INVALID;
d->headset_state = PA_BT_AUDIO_STATE_INVALID;
+ d->hfgw_state = PA_BT_AUDIO_STATE_INVALID;
return d;
}
+static void transport_free(pa_bluetooth_transport *t) {
+ pa_assert(t);
+
+ pa_xfree(t->path);
+ pa_xfree(t->config);
+ pa_xfree(t);
+}
+
static void device_free(pa_bluetooth_device *d) {
pa_bluetooth_uuid *u;
+ pa_bluetooth_transport *t;
pa_assert(d);
+ while ((t = pa_hashmap_steal_first(d->transports)))
+ transport_free(t);
+
+ pa_hashmap_free(d->transports, NULL, NULL);
+
while ((u = d->uuids)) {
PA_LLIST_REMOVE(pa_bluetooth_uuid, d->uuids, u);
uuid_free(u);
@@ -121,10 +171,11 @@ static pa_bool_t device_is_audio(pa_bluetooth_device *d) {
pa_assert(d);
return
- d->device_info_valid &&
- (d->audio_state != PA_BT_AUDIO_STATE_INVALID ||
- d->audio_sink_state != PA_BT_AUDIO_STATE_INVALID ||
- d->headset_state != PA_BT_AUDIO_STATE_INVALID);
+ d->device_info_valid && (d->hfgw_state != PA_BT_AUDIO_STATE_INVALID ||
+ (d->audio_state != PA_BT_AUDIO_STATE_INVALID &&
+ (d->audio_sink_state != PA_BT_AUDIO_STATE_INVALID ||
+ d->audio_source_state != PA_BT_AUDIO_STATE_INVALID ||
+ d->headset_state != PA_BT_AUDIO_STATE_INVALID)));
}
static int parse_device_property(pa_bluetooth_discovery *y, pa_bluetooth_device *d, DBusMessageIter *i) {
@@ -142,7 +193,7 @@ static int parse_device_property(pa_bluetooth_discovery *y, pa_bluetooth_device
dbus_message_iter_get_basic(i, &key);
- if (!dbus_message_iter_next(i)) {
+ if (!dbus_message_iter_next(i)) {
pa_log("Property value missing");
return -1;
}
@@ -226,19 +277,25 @@ static int parse_device_property(pa_bluetooth_discovery *y, pa_bluetooth_device
node = uuid_new(value);
PA_LLIST_PREPEND(pa_bluetooth_uuid, d->uuids, node);
- /* this might eventually be racy if .Audio is not there yet, but the State change will come anyway later, so this call is for cold-detection mostly */
- pa_assert_se(m = dbus_message_new_method_call("org.bluez", d->path, "org.bluez.Audio", "GetProperties"));
- send_and_add_to_pending(y, d, m, get_properties_reply);
-
/* Vudentz said the interfaces are here when the UUIDs are announced */
- if (strcasecmp(HSP_HS_UUID, value) == 0 || strcasecmp(HFP_HS_UUID, value) == 0) {
+ if (strcasecmp(HSP_AG_UUID, value) == 0 || strcasecmp(HFP_AG_UUID, value) == 0) {
+ pa_assert_se(m = dbus_message_new_method_call("org.bluez", d->path, "org.bluez.HandsfreeGateway", "GetProperties"));
+ send_and_add_to_pending(y, m, get_properties_reply, d);
+ } else if (strcasecmp(HSP_HS_UUID, value) == 0 || strcasecmp(HFP_HS_UUID, value) == 0) {
pa_assert_se(m = dbus_message_new_method_call("org.bluez", d->path, "org.bluez.Headset", "GetProperties"));
- send_and_add_to_pending(y, d, m, get_properties_reply);
+ send_and_add_to_pending(y, m, get_properties_reply, d);
} else if (strcasecmp(A2DP_SINK_UUID, value) == 0) {
pa_assert_se(m = dbus_message_new_method_call("org.bluez", d->path, "org.bluez.AudioSink", "GetProperties"));
- send_and_add_to_pending(y, d, m, get_properties_reply);
+ send_and_add_to_pending(y, m, get_properties_reply, d);
+ } else if (strcasecmp(A2DP_SOURCE_UUID, value) == 0) {
+ pa_assert_se(m = dbus_message_new_method_call("org.bluez", d->path, "org.bluez.AudioSource", "GetProperties"));
+ send_and_add_to_pending(y, m, get_properties_reply, d);
}
+ /* this might eventually be racy if .Audio is not there yet, but the State change will come anyway later, so this call is for cold-detection mostly */
+ pa_assert_se(m = dbus_message_new_method_call("org.bluez", d->path, "org.bluez.Audio", "GetProperties"));
+ send_and_add_to_pending(y, m, get_properties_reply, d);
+
if (!dbus_message_iter_next(&ai))
break;
}
@@ -266,7 +323,7 @@ static int parse_audio_property(pa_bluetooth_discovery *u, int *state, DBusMessa
dbus_message_iter_get_basic(i, &key);
- if (!dbus_message_iter_next(i)) {
+ if (!dbus_message_iter_next(i)) {
pa_log("Property value missing");
return -1;
}
@@ -278,7 +335,7 @@ static int parse_audio_property(pa_bluetooth_discovery *u, int *state, DBusMessa
dbus_message_iter_recurse(i, &variant_i);
-/* pa_log_debug("Parsing property org.bluez.{Audio|AudioSink|Headset}.%s", key); */
+/* pa_log_debug("Parsing property org.bluez.{Audio|AudioSink|AudioSource|Headset}.%s", key); */
switch (dbus_message_iter_get_arg_type(&variant_i)) {
@@ -287,9 +344,10 @@ static int parse_audio_property(pa_bluetooth_discovery *u, int *state, DBusMessa
const char *value;
dbus_message_iter_get_basic(&variant_i, &value);
- if (pa_streq(key, "State"))
+ if (pa_streq(key, "State")) {
*state = pa_bt_audio_state_from_string(value);
-/* pa_log_debug("Value %s", value); */
+ pa_log_debug("dbus: property 'State' changed to value '%s'", value);
+ }
break;
}
@@ -309,6 +367,40 @@ static void run_callback(pa_bluetooth_discovery *y, pa_bluetooth_device *d, pa_b
pa_hook_fire(&y->hook, d);
}
+static void remove_all_devices(pa_bluetooth_discovery *y) {
+ pa_bluetooth_device *d;
+
+ pa_assert(y);
+
+ while ((d = pa_hashmap_steal_first(y->devices))) {
+ run_callback(y, d, TRUE);
+ device_free(d);
+ }
+}
+
+static pa_bluetooth_device *found_device(pa_bluetooth_discovery *y, const char* path) {
+ DBusMessage *m;
+ pa_bluetooth_device *d;
+
+ pa_assert(y);
+ pa_assert(path);
+
+ d = pa_hashmap_get(y->devices, path);
+ if (d)
+ return d;
+
+ d = device_new(path);
+
+ pa_hashmap_put(y->devices, d->path, d);
+
+ pa_assert_se(m = dbus_message_new_method_call("org.bluez", path, "org.bluez.Device", "GetProperties"));
+ send_and_add_to_pending(y, m, get_properties_reply, d);
+
+ /* Before we read the other properties (Audio, AudioSink, AudioSource,
+ * Headset) we wait that the UUID is read */
+ return d;
+}
+
static void get_properties_reply(DBusPendingCall *pending, void *userdata) {
DBusMessage *r;
DBusMessageIter arg_i, element_i;
@@ -325,13 +417,25 @@ static void get_properties_reply(DBusPendingCall *pending, void *userdata) {
/* dbus_message_get_interface(p->message), */
/* dbus_message_get_path(p->message)); */
- d = p->call_data;
+ /* We don't use p->call_data here right-away since the device
+ * might already be invalidated at this point */
+
+ if (!(d = pa_hashmap_get(y->devices, dbus_message_get_path(p->message))))
+ return;
+
+ pa_assert(p->call_data == d);
valid = dbus_message_get_type(r) == DBUS_MESSAGE_TYPE_ERROR ? -1 : 1;
if (dbus_message_is_method_call(p->message, "org.bluez.Device", "GetProperties"))
d->device_info_valid = valid;
+ if (dbus_message_is_error(r, DBUS_ERROR_SERVICE_UNKNOWN)) {
+ pa_log_debug("Bluetooth daemon is apparently not available.");
+ remove_all_devices(y);
+ goto finish2;
+ }
+
if (dbus_message_get_type(r) == DBUS_MESSAGE_TYPE_ERROR) {
if (!dbus_message_is_error(r, DBUS_ERROR_UNKNOWN_METHOD))
@@ -373,6 +477,15 @@ static void get_properties_reply(DBusPendingCall *pending, void *userdata) {
} else if (dbus_message_has_interface(p->message, "org.bluez.AudioSink")) {
if (parse_audio_property(y, &d->audio_sink_state, &dict_i) < 0)
goto finish;
+
+ } else if (dbus_message_has_interface(p->message, "org.bluez.AudioSource")) {
+ if (parse_audio_property(y, &d->audio_source_state, &dict_i) < 0)
+ goto finish;
+
+ } else if (dbus_message_has_interface(p->message, "org.bluez.HandsfreeGateway")) {
+ if (parse_audio_property(y, &d->hfgw_state, &arg_i) < 0)
+ goto finish;
+
}
}
@@ -383,13 +496,14 @@ static void get_properties_reply(DBusPendingCall *pending, void *userdata) {
finish:
run_callback(y, d, FALSE);
+finish2:
dbus_message_unref(r);
PA_LLIST_REMOVE(pa_dbus_pending, y->pending, p);
pa_dbus_pending_free(p);
}
-static pa_dbus_pending* send_and_add_to_pending(pa_bluetooth_discovery *y, pa_bluetooth_device *d, DBusMessage *m, DBusPendingCallNotifyFunction func) {
+static pa_dbus_pending* send_and_add_to_pending(pa_bluetooth_discovery *y, DBusMessage *m, DBusPendingCallNotifyFunction func, void *call_data) {
pa_dbus_pending *p;
DBusPendingCall *call;
@@ -398,30 +512,55 @@ static pa_dbus_pending* send_and_add_to_pending(pa_bluetooth_discovery *y, pa_bl
pa_assert_se(dbus_connection_send_with_reply(pa_dbus_connection_get(y->connection), m, &call, -1));
- p = pa_dbus_pending_new(pa_dbus_connection_get(y->connection), m, call, y, d);
+ p = pa_dbus_pending_new(pa_dbus_connection_get(y->connection), m, call, y, call_data);
PA_LLIST_PREPEND(pa_dbus_pending, y->pending, p);
dbus_pending_call_set_notify(call, func, p, NULL);
return p;
}
-static void found_device(pa_bluetooth_discovery *y, const char* path) {
- DBusMessage *m;
- pa_bluetooth_device *d;
+#ifdef DBUS_TYPE_UNIX_FD
+static void register_endpoint_reply(DBusPendingCall *pending, void *userdata) {
+ DBusError e;
+ DBusMessage *r;
+ pa_dbus_pending *p;
+ pa_bluetooth_discovery *y;
+ char *endpoint;
- pa_assert(y);
- pa_assert(path);
+ pa_assert(pending);
- d = device_new(path);
+ dbus_error_init(&e);
- pa_hashmap_put(y->devices, d->path, d);
+ pa_assert_se(p = userdata);
+ pa_assert_se(y = p->context_data);
+ pa_assert_se(endpoint = p->call_data);
+ pa_assert_se(r = dbus_pending_call_steal_reply(pending));
- pa_assert_se(m = dbus_message_new_method_call("org.bluez", path, "org.bluez.Device", "GetProperties"));
- send_and_add_to_pending(y, d, m, get_properties_reply);
+ if (dbus_message_is_error(r, DBUS_ERROR_SERVICE_UNKNOWN)) {
+ pa_log_debug("Bluetooth daemon is apparently not available.");
+ remove_all_devices(y);
+ goto finish;
+ }
+
+ if (dbus_message_is_error(r, PA_BLUETOOTH_ERROR_NOT_SUPPORTED)) {
+ pa_log_info("Couldn't register endpoint %s, because BlueZ is configured to disable the endpoint type.", endpoint);
+ goto finish;
+ }
+
+ if (dbus_message_get_type(r) == DBUS_MESSAGE_TYPE_ERROR) {
+ pa_log("Error from RegisterEndpoint reply: %s", dbus_message_get_error_name(r));
+ goto finish;
+ }
- /* Before we read the other properties (Audio, AudioSink, Headset) we wait
- * that the UUID is read */
+finish:
+ dbus_message_unref(r);
+
+ PA_LLIST_REMOVE(pa_dbus_pending, y->pending, p);
+ pa_dbus_pending_free(p);
+
+ pa_xfree(endpoint);
}
+#endif
static void list_devices_reply(DBusPendingCall *pending, void *userdata) {
DBusError e;
@@ -439,9 +578,15 @@ static void list_devices_reply(DBusPendingCall *pending, void *userdata) {
pa_assert_se(y = p->context_data);
pa_assert_se(r = dbus_pending_call_steal_reply(pending));
+ if (dbus_message_is_error(r, DBUS_ERROR_SERVICE_UNKNOWN)) {
+ pa_log_debug("Bluetooth daemon is apparently not available.");
+ remove_all_devices(y);
+ goto finish;
+ }
+
if (dbus_message_get_type(r) == DBUS_MESSAGE_TYPE_ERROR) {
pa_log("Error from ListDevices reply: %s", dbus_message_get_error_name(r));
- goto end;
+ goto finish;
}
if (!dbus_message_get_args(r, &e, DBUS_TYPE_ARRAY, DBUS_TYPE_OBJECT_PATH, &paths, &num, DBUS_TYPE_INVALID)) {
@@ -454,9 +599,9 @@ static void list_devices_reply(DBusPendingCall *pending, void *userdata) {
found_device(y, paths[i]);
}
-end:
+finish:
if (paths)
- dbus_free_string_array (paths);
+ dbus_free_string_array(paths);
dbus_message_unref(r);
@@ -464,11 +609,65 @@ end:
pa_dbus_pending_free(p);
}
+#ifdef DBUS_TYPE_UNIX_FD
+static void register_endpoint(pa_bluetooth_discovery *y, const char *path, const char *endpoint, const char *uuid) {
+ DBusMessage *m;
+ DBusMessageIter i, d;
+ uint8_t codec = 0;
+
+ pa_log_debug("Registering %s on adapter %s.", endpoint, path);
+
+ pa_assert_se(m = dbus_message_new_method_call("org.bluez", path, "org.bluez.Media", "RegisterEndpoint"));
+
+ dbus_message_iter_init_append(m, &i);
+
+ dbus_message_iter_append_basic(&i, DBUS_TYPE_OBJECT_PATH, &endpoint);
+
+ dbus_message_iter_open_container(&i, DBUS_TYPE_ARRAY, DBUS_DICT_ENTRY_BEGIN_CHAR_AS_STRING
+ DBUS_TYPE_STRING_AS_STRING DBUS_TYPE_VARIANT_AS_STRING DBUS_DICT_ENTRY_END_CHAR_AS_STRING,
+ &d);
+
+ pa_dbus_append_basic_variant_dict_entry(&d, "UUID", DBUS_TYPE_STRING, &uuid);
+
+ pa_dbus_append_basic_variant_dict_entry(&d, "Codec", DBUS_TYPE_BYTE, &codec);
+
+ if (pa_streq(uuid, HFP_AG_UUID)) {
+ uint8_t capability = 0;
+ pa_dbus_append_basic_array_variant_dict_entry(&d, "Capabilities", DBUS_TYPE_BYTE, &capability, 1);
+ } else {
+ a2dp_sbc_t capabilities;
+
+ capabilities.channel_mode = BT_A2DP_CHANNEL_MODE_MONO | BT_A2DP_CHANNEL_MODE_DUAL_CHANNEL |
+ BT_A2DP_CHANNEL_MODE_STEREO | BT_A2DP_CHANNEL_MODE_JOINT_STEREO;
+ capabilities.frequency = BT_SBC_SAMPLING_FREQ_16000 | BT_SBC_SAMPLING_FREQ_32000 |
+ BT_SBC_SAMPLING_FREQ_44100 | BT_SBC_SAMPLING_FREQ_48000;
+ capabilities.allocation_method = BT_A2DP_ALLOCATION_SNR | BT_A2DP_ALLOCATION_LOUDNESS;
+ capabilities.subbands = BT_A2DP_SUBBANDS_4 | BT_A2DP_SUBBANDS_8;
+ capabilities.block_length = BT_A2DP_BLOCK_LENGTH_4 | BT_A2DP_BLOCK_LENGTH_8 |
+ BT_A2DP_BLOCK_LENGTH_12 | BT_A2DP_BLOCK_LENGTH_16;
+ capabilities.min_bitpool = MIN_BITPOOL;
+ capabilities.max_bitpool = MAX_BITPOOL;
+
+ pa_dbus_append_basic_array_variant_dict_entry(&d, "Capabilities", DBUS_TYPE_BYTE, &capabilities, sizeof(capabilities));
+ }
+
+ dbus_message_iter_close_container(&i, &d);
+
+ send_and_add_to_pending(y, m, register_endpoint_reply, pa_xstrdup(endpoint));
+}
+#endif
+
static void found_adapter(pa_bluetooth_discovery *y, const char *path) {
DBusMessage *m;
pa_assert_se(m = dbus_message_new_method_call("org.bluez", path, "org.bluez.Adapter", "ListDevices"));
- send_and_add_to_pending(y, NULL, m, list_devices_reply);
+ send_and_add_to_pending(y, m, list_devices_reply, NULL);
+
+#ifdef DBUS_TYPE_UNIX_FD
+ register_endpoint(y, path, HFP_AG_ENDPOINT, HFP_AG_UUID);
+ register_endpoint(y, path, A2DP_SOURCE_ENDPOINT, A2DP_SOURCE_UUID);
+ register_endpoint(y, path, A2DP_SINK_ENDPOINT, A2DP_SINK_UUID);
+#endif
}
static void list_adapters_reply(DBusPendingCall *pending, void *userdata) {
@@ -487,9 +686,15 @@ static void list_adapters_reply(DBusPendingCall *pending, void *userdata) {
pa_assert_se(y = p->context_data);
pa_assert_se(r = dbus_pending_call_steal_reply(pending));
+ if (dbus_message_is_error(r, DBUS_ERROR_SERVICE_UNKNOWN)) {
+ pa_log_debug("Bluetooth daemon is apparently not available.");
+ remove_all_devices(y);
+ goto finish;
+ }
+
if (dbus_message_get_type(r) == DBUS_MESSAGE_TYPE_ERROR) {
pa_log("Error from ListAdapters reply: %s", dbus_message_get_error_name(r));
- goto end;
+ goto finish;
}
if (!dbus_message_get_args(r, &e, DBUS_TYPE_ARRAY, DBUS_TYPE_OBJECT_PATH, &paths, &num, DBUS_TYPE_INVALID)) {
@@ -502,9 +707,9 @@ static void list_adapters_reply(DBusPendingCall *pending, void *userdata) {
found_adapter(y, paths[i]);
}
-end:
+finish:
if (paths)
- dbus_free_string_array (paths);
+ dbus_free_string_array(paths);
dbus_message_unref(r);
@@ -517,7 +722,48 @@ static void list_adapters(pa_bluetooth_discovery *y) {
pa_assert(y);
pa_assert_se(m = dbus_message_new_method_call("org.bluez", "/", "org.bluez.Manager", "ListAdapters"));
- send_and_add_to_pending(y, NULL, m, list_adapters_reply);
+ send_and_add_to_pending(y, m, list_adapters_reply, NULL);
+}
+
+int pa_bluetooth_transport_parse_property(pa_bluetooth_transport *t, DBusMessageIter *i)
+{
+ const char *key;
+ DBusMessageIter variant_i;
+
+ if (dbus_message_iter_get_arg_type(i) != DBUS_TYPE_STRING) {
+ pa_log("Property name not a string.");
+ return -1;
+ }
+
+ dbus_message_iter_get_basic(i, &key);
+
+ if (!dbus_message_iter_next(i)) {
+ pa_log("Property value missing");
+ return -1;
+ }
+
+ if (dbus_message_iter_get_arg_type(i) != DBUS_TYPE_VARIANT) {
+ pa_log("Property value not a variant.");
+ return -1;
+ }
+
+ dbus_message_iter_recurse(i, &variant_i);
+
+ switch (dbus_message_iter_get_arg_type(&variant_i)) {
+
+ case DBUS_TYPE_BOOLEAN: {
+
+ pa_bool_t *value;
+ dbus_message_iter_get_basic(&variant_i, &value);
+
+ if (pa_streq(key, "NREC"))
+ t->nrec = value;
+
+ break;
+ }
+ }
+
+ return 0;
}
static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *m, void *userdata) {
@@ -583,6 +829,8 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *m, void *us
} else if (dbus_message_is_signal(m, "org.bluez.Audio", "PropertyChanged") ||
dbus_message_is_signal(m, "org.bluez.Headset", "PropertyChanged") ||
dbus_message_is_signal(m, "org.bluez.AudioSink", "PropertyChanged") ||
+ dbus_message_is_signal(m, "org.bluez.AudioSource", "PropertyChanged") ||
+ dbus_message_is_signal(m, "org.bluez.HandsfreeGateway", "PropertyChanged") ||
dbus_message_is_signal(m, "org.bluez.Device", "PropertyChanged")) {
pa_bluetooth_device *d;
@@ -610,12 +858,84 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *m, void *us
} else if (dbus_message_has_interface(m, "org.bluez.AudioSink")) {
if (parse_audio_property(y, &d->audio_sink_state, &arg_i) < 0)
goto fail;
+
+ } else if (dbus_message_has_interface(m, "org.bluez.AudioSource")) {
+ if (parse_audio_property(y, &d->audio_source_state, &arg_i) < 0)
+ goto fail;
+
+ } else if (dbus_message_has_interface(m, "org.bluez.HandsfreeGateway")) {
+ if (parse_audio_property(y, &d->hfgw_state, &arg_i) < 0)
+ goto fail;
}
run_callback(y, d, FALSE);
}
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+
+ } else if (dbus_message_is_signal(m, "org.bluez.Device", "DisconnectRequested")) {
+ pa_bluetooth_device *d;
+
+ if ((d = pa_hashmap_get(y->devices, dbus_message_get_path(m)))) {
+ /* Device will disconnect in 2 sec */
+ d->audio_state = PA_BT_AUDIO_STATE_DISCONNECTED;
+ d->audio_sink_state = PA_BT_AUDIO_STATE_DISCONNECTED;
+ d->audio_source_state = PA_BT_AUDIO_STATE_DISCONNECTED;
+ d->headset_state = PA_BT_AUDIO_STATE_DISCONNECTED;
+ d->hfgw_state = PA_BT_AUDIO_STATE_DISCONNECTED;
+
+ run_callback(y, d, FALSE);
+ }
+
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+
+ } else if (dbus_message_is_signal(m, "org.freedesktop.DBus", "NameOwnerChanged")) {
+ const char *name, *old_owner, *new_owner;
+
+ if (!dbus_message_get_args(m, &err,
+ DBUS_TYPE_STRING, &name,
+ DBUS_TYPE_STRING, &old_owner,
+ DBUS_TYPE_STRING, &new_owner,
+ DBUS_TYPE_INVALID)) {
+ pa_log("Failed to parse org.freedesktop.DBus.NameOwnerChanged: %s", err.message);
+ goto fail;
+ }
+
+ if (pa_streq(name, "org.bluez")) {
+ if (old_owner && *old_owner) {
+ pa_log_debug("Bluetooth daemon disappeared.");
+ remove_all_devices(y);
+ }
+
+ if (new_owner && *new_owner) {
+ pa_log_debug("Bluetooth daemon appeared.");
+ list_adapters(y);
+ }
+ }
+
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+ } else if (dbus_message_is_signal(m, "org.bluez.MediaTransport", "PropertyChanged")) {
+ pa_bluetooth_device *d;
+ pa_bluetooth_transport *t;
+ void *state = NULL;
+ DBusMessageIter arg_i;
+
+ while ((d = pa_hashmap_iterate(y->devices, &state, NULL)))
+ if ((t = pa_hashmap_get(d->transports, dbus_message_get_path(m))))
+ break;
+
+ if (!t)
+ goto fail;
+
+ if (!dbus_message_iter_init(m, &arg_i)) {
+ pa_log("Failed to parse PropertyChanged: %s", err.message);
+ goto fail;
+ }
+
+ if (pa_bluetooth_transport_parse_property(t, &arg_i) < 0)
+ goto fail;
+
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
}
fail:
@@ -637,12 +957,14 @@ const pa_bluetooth_device* pa_bluetooth_discovery_get_by_address(pa_bluetooth_di
while ((d = pa_hashmap_iterate(y->devices, &state, NULL)))
if (pa_streq(d->address, address))
- return d;
+ return device_is_audio(d) ? d : NULL;
return NULL;
}
const pa_bluetooth_device* pa_bluetooth_discovery_get_by_path(pa_bluetooth_discovery *y, const char* path) {
+ pa_bluetooth_device *d;
+
pa_assert(y);
pa_assert(PA_REFCNT_VALUE(y) > 0);
pa_assert(path);
@@ -650,7 +972,103 @@ const pa_bluetooth_device* pa_bluetooth_discovery_get_by_path(pa_bluetooth_disco
if (!pa_hook_is_firing(&y->hook))
pa_bluetooth_discovery_sync(y);
- return pa_hashmap_get(y->devices, path);
+ if ((d = pa_hashmap_get(y->devices, path)))
+ if (device_is_audio(d))
+ return d;
+
+ return NULL;
+}
+
+const pa_bluetooth_transport* pa_bluetooth_discovery_get_transport(pa_bluetooth_discovery *y, const char *path) {
+ pa_bluetooth_device *d;
+ pa_bluetooth_transport *t;
+ void *state = NULL;
+
+ pa_assert(y);
+ pa_assert(PA_REFCNT_VALUE(y) > 0);
+ pa_assert(path);
+
+ while ((d = pa_hashmap_iterate(y->devices, &state, NULL)))
+ if ((t = pa_hashmap_get(d->transports, path)))
+ return t;
+
+ return NULL;
+}
+
+const pa_bluetooth_transport* pa_bluetooth_device_get_transport(const pa_bluetooth_device *d, enum profile profile) {
+ pa_bluetooth_transport *t;
+ void *state = NULL;
+
+ pa_assert(d);
+
+ while ((t = pa_hashmap_iterate(d->transports, &state, NULL)))
+ if (t->profile == profile)
+ return t;
+
+ return NULL;
+}
+
+int pa_bluetooth_transport_acquire(const pa_bluetooth_transport *t, const char *accesstype, size_t *imtu, size_t *omtu) {
+ DBusMessage *m, *r;
+ DBusError err;
+ int ret;
+ uint16_t i, o;
+
+ pa_assert(t);
+ pa_assert(t->y);
+
+ dbus_error_init(&err);
+
+ pa_assert_se(m = dbus_message_new_method_call("org.bluez", t->path, "org.bluez.MediaTransport", "Acquire"));
+ pa_assert_se(dbus_message_append_args(m, DBUS_TYPE_STRING, &accesstype, DBUS_TYPE_INVALID));
+ r = dbus_connection_send_with_reply_and_block(pa_dbus_connection_get(t->y->connection), m, -1, &err);
+
+ if (dbus_error_is_set(&err) || !r) {
+ pa_log("Failed to acquire transport fd: %s", err.message);
+ dbus_error_free(&err);
+ return -1;
+ }
+
+#ifdef DBUS_TYPE_UNIX_FD
+ if (!dbus_message_get_args(r, &err, DBUS_TYPE_UNIX_FD, &ret, DBUS_TYPE_UINT16, &i, DBUS_TYPE_UINT16, &o, DBUS_TYPE_INVALID)) {
+ pa_log("Failed to parse org.bluez.MediaTransport.Acquire(): %s", err.message);
+ ret = -1;
+ dbus_error_free(&err);
+ goto fail;
+ }
+#endif
+
+ if (imtu)
+ *imtu = i;
+
+ if (omtu)
+ *omtu = o;
+
+#ifdef DBUS_TYPE_UNIX_FD
+fail:
+#endif
+ dbus_message_unref(r);
+ return ret;
+}
+
+void pa_bluetooth_transport_release(const pa_bluetooth_transport *t, const char *accesstype) {
+ DBusMessage *m;
+ DBusError err;
+
+ pa_assert(t);
+ pa_assert(t->y);
+
+ dbus_error_init(&err);
+
+ pa_assert_se(m = dbus_message_new_method_call("org.bluez", t->path, "org.bluez.MediaTransport", "Release"));
+ pa_assert_se(dbus_message_append_args(m, DBUS_TYPE_STRING, &accesstype, DBUS_TYPE_INVALID));
+ dbus_connection_send_with_reply_and_block(pa_dbus_connection_get(t->y->connection), m, -1, &err);
+
+ if (dbus_error_is_set(&err)) {
+ pa_log("Failed to release transport %s: %s", t->path, err.message);
+ dbus_error_free(&err);
+ } else
+ pa_log_info("Transport %s released", t->path);
}
static int setup_dbus(pa_bluetooth_discovery *y) {
@@ -669,9 +1087,369 @@ static int setup_dbus(pa_bluetooth_discovery *y) {
return 0;
}
+#ifdef DBUS_TYPE_UNIX_FD
+static pa_bluetooth_transport *transport_new(pa_bluetooth_discovery *y, const char *path, enum profile p, const uint8_t *config, int size) {
+ pa_bluetooth_transport *t;
+
+ t = pa_xnew0(pa_bluetooth_transport, 1);
+ t->y = y;
+ t->path = pa_xstrdup(path);
+ t->profile = p;
+ t->config_size = size;
+
+ if (size > 0) {
+ t->config = pa_xnew(uint8_t, size);
+ memcpy(t->config, config, size);
+ }
+
+ return t;
+}
+
+static DBusMessage *endpoint_set_configuration(DBusConnection *conn, DBusMessage *m, void *userdata) {
+ pa_bluetooth_discovery *y = userdata;
+ pa_bluetooth_device *d;
+ pa_bluetooth_transport *t;
+ const char *path, *dev_path = NULL, *uuid = NULL;
+ uint8_t *config = NULL;
+ int size = 0;
+ pa_bool_t nrec;
+ enum profile p;
+ DBusMessageIter args, props;
+ DBusMessage *r;
+
+ dbus_message_iter_init(m, &args);
+
+ dbus_message_iter_get_basic(&args, &path);
+ if (!dbus_message_iter_next(&args))
+ goto fail;
+
+ dbus_message_iter_recurse(&args, &props);
+ if (dbus_message_iter_get_arg_type(&props) != DBUS_TYPE_DICT_ENTRY)
+ goto fail;
+
+ /* Read transport properties */
+ while (dbus_message_iter_get_arg_type(&props) == DBUS_TYPE_DICT_ENTRY) {
+ const char *key;
+ DBusMessageIter value, entry;
+ int var;
+
+ dbus_message_iter_recurse(&props, &entry);
+ dbus_message_iter_get_basic(&entry, &key);
+
+ dbus_message_iter_next(&entry);
+ dbus_message_iter_recurse(&entry, &value);
+
+ var = dbus_message_iter_get_arg_type(&value);
+ if (strcasecmp(key, "UUID") == 0) {
+ if (var != DBUS_TYPE_STRING)
+ goto fail;
+ dbus_message_iter_get_basic(&value, &uuid);
+ } else if (strcasecmp(key, "Device") == 0) {
+ if (var != DBUS_TYPE_OBJECT_PATH)
+ goto fail;
+ dbus_message_iter_get_basic(&value, &dev_path);
+ } else if (strcasecmp(key, "NREC") == 0) {
+ if (var != DBUS_TYPE_BOOLEAN)
+ goto fail;
+ dbus_message_iter_get_basic(&value, &nrec);
+ } else if (strcasecmp(key, "Configuration") == 0) {
+ DBusMessageIter array;
+ if (var != DBUS_TYPE_ARRAY)
+ goto fail;
+ dbus_message_iter_recurse(&value, &array);
+ dbus_message_iter_get_fixed_array(&array, &config, &size);
+ }
+
+ dbus_message_iter_next(&props);
+ }
+
+ d = found_device(y, dev_path);
+ if (!d)
+ goto fail;
+
+ if (dbus_message_has_path(m, HFP_AG_ENDPOINT))
+ p = PROFILE_HSP;
+ else if (dbus_message_has_path(m, A2DP_SOURCE_ENDPOINT))
+ p = PROFILE_A2DP;
+ else
+ p = PROFILE_A2DP_SOURCE;
+
+ t = transport_new(y, path, p, config, size);
+ if (nrec)
+ t->nrec = nrec;
+ pa_hashmap_put(d->transports, t->path, t);
+
+ pa_log_debug("Transport %s profile %d available", t->path, t->profile);
+
+ pa_assert_se(r = dbus_message_new_method_return(m));
+
+ return r;
+
+fail:
+ pa_log("org.bluez.MediaEndpoint.SetConfiguration: invalid arguments");
+ pa_assert_se(r = (dbus_message_new_error(m, "org.bluez.MediaEndpoint.Error.InvalidArguments",
+ "Unable to set configuration")));
+ return r;
+}
+
+static DBusMessage *endpoint_clear_configuration(DBusConnection *c, DBusMessage *m, void *userdata) {
+ pa_bluetooth_discovery *y = userdata;
+ pa_bluetooth_device *d;
+ pa_bluetooth_transport *t;
+ void *state = NULL;
+ DBusMessage *r;
+ DBusError e;
+ const char *path;
+
+ dbus_error_init(&e);
+
+ if (!dbus_message_get_args(m, &e, DBUS_TYPE_OBJECT_PATH, &path, DBUS_TYPE_INVALID)) {
+ pa_log("org.bluez.MediaEndpoint.ClearConfiguration: %s", e.message);
+ dbus_error_free(&e);
+ goto fail;
+ }
+
+ while ((d = pa_hashmap_iterate(y->devices, &state, NULL))) {
+ if ((t = pa_hashmap_get(d->transports, path))) {
+ pa_log_debug("Clearing transport %s profile %d", t->path, t->profile);
+ pa_hashmap_remove(d->transports, t->path);
+ transport_free(t);
+ break;
+ }
+ }
+
+ pa_assert_se(r = dbus_message_new_method_return(m));
+
+ return r;
+
+fail:
+ pa_assert_se(r = (dbus_message_new_error(m, "org.bluez.MediaEndpoint.Error.InvalidArguments",
+ "Unable to clear configuration")));
+ return r;
+}
+
+static uint8_t a2dp_default_bitpool(uint8_t freq, uint8_t mode) {
+
+ switch (freq) {
+ case BT_SBC_SAMPLING_FREQ_16000:
+ case BT_SBC_SAMPLING_FREQ_32000:
+ return 53;
+
+ case BT_SBC_SAMPLING_FREQ_44100:
+
+ switch (mode) {
+ case BT_A2DP_CHANNEL_MODE_MONO:
+ case BT_A2DP_CHANNEL_MODE_DUAL_CHANNEL:
+ return 31;
+
+ case BT_A2DP_CHANNEL_MODE_STEREO:
+ case BT_A2DP_CHANNEL_MODE_JOINT_STEREO:
+ return 53;
+
+ default:
+ pa_log_warn("Invalid channel mode %u", mode);
+ return 53;
+ }
+
+ case BT_SBC_SAMPLING_FREQ_48000:
+
+ switch (mode) {
+ case BT_A2DP_CHANNEL_MODE_MONO:
+ case BT_A2DP_CHANNEL_MODE_DUAL_CHANNEL:
+ return 29;
+
+ case BT_A2DP_CHANNEL_MODE_STEREO:
+ case BT_A2DP_CHANNEL_MODE_JOINT_STEREO:
+ return 51;
+
+ default:
+ pa_log_warn("Invalid channel mode %u", mode);
+ return 51;
+ }
+
+ default:
+ pa_log_warn("Invalid sampling freq %u", freq);
+ return 53;
+ }
+}
+
+static DBusMessage *endpoint_select_configuration(DBusConnection *c, DBusMessage *m, void *userdata) {
+ pa_bluetooth_discovery *y = userdata;
+ a2dp_sbc_t *cap, config;
+ uint8_t *pconf = (uint8_t *) &config;
+ int i, size;
+ DBusMessage *r;
+ DBusError e;
+
+ static const struct {
+ uint32_t rate;
+ uint8_t cap;
+ } freq_table[] = {
+ { 16000U, BT_SBC_SAMPLING_FREQ_16000 },
+ { 32000U, BT_SBC_SAMPLING_FREQ_32000 },
+ { 44100U, BT_SBC_SAMPLING_FREQ_44100 },
+ { 48000U, BT_SBC_SAMPLING_FREQ_48000 }
+ };
+
+ dbus_error_init(&e);
+
+ if (!dbus_message_get_args(m, &e, DBUS_TYPE_ARRAY, DBUS_TYPE_BYTE, &cap, &size, DBUS_TYPE_INVALID)) {
+ pa_log("org.bluez.MediaEndpoint.SelectConfiguration: %s", e.message);
+ dbus_error_free(&e);
+ goto fail;
+ }
+
+ if (dbus_message_has_path(m, HFP_AG_ENDPOINT))
+ goto done;
+
+ pa_assert(size == sizeof(config));
+
+ memset(&config, 0, sizeof(config));
+
+ /* Find the lowest freq that is at least as high as the requested
+ * sampling rate */
+ for (i = 0; (unsigned) i < PA_ELEMENTSOF(freq_table); i++)
+ if (freq_table[i].rate >= y->core->default_sample_spec.rate && (cap->frequency & freq_table[i].cap)) {
+ config.frequency = freq_table[i].cap;
+ break;
+ }
+
+ if ((unsigned) i == PA_ELEMENTSOF(freq_table)) {
+ for (--i; i >= 0; i--) {
+ if (cap->frequency & freq_table[i].cap) {
+ config.frequency = freq_table[i].cap;
+ break;
+ }
+ }
+
+ if (i < 0) {
+ pa_log("Not suitable sample rate");
+ goto fail;
+ }
+ }
+
+ pa_assert((unsigned) i < PA_ELEMENTSOF(freq_table));
+
+ if (y->core->default_sample_spec.channels <= 1) {
+ if (cap->channel_mode & BT_A2DP_CHANNEL_MODE_MONO)
+ config.channel_mode = BT_A2DP_CHANNEL_MODE_MONO;
+ }
+
+ if (y->core->default_sample_spec.channels >= 2) {
+ if (cap->channel_mode & BT_A2DP_CHANNEL_MODE_JOINT_STEREO)
+ config.channel_mode = BT_A2DP_CHANNEL_MODE_JOINT_STEREO;
+ else if (cap->channel_mode & BT_A2DP_CHANNEL_MODE_STEREO)
+ config.channel_mode = BT_A2DP_CHANNEL_MODE_STEREO;
+ else if (cap->channel_mode & BT_A2DP_CHANNEL_MODE_DUAL_CHANNEL)
+ config.channel_mode = BT_A2DP_CHANNEL_MODE_DUAL_CHANNEL;
+ else if (cap->channel_mode & BT_A2DP_CHANNEL_MODE_MONO) {
+ config.channel_mode = BT_A2DP_CHANNEL_MODE_MONO;
+ } else {
+ pa_log("No supported channel modes");
+ goto fail;
+ }
+ }
+
+ if (cap->block_length & BT_A2DP_BLOCK_LENGTH_16)
+ config.block_length = BT_A2DP_BLOCK_LENGTH_16;
+ else if (cap->block_length & BT_A2DP_BLOCK_LENGTH_12)
+ config.block_length = BT_A2DP_BLOCK_LENGTH_12;
+ else if (cap->block_length & BT_A2DP_BLOCK_LENGTH_8)
+ config.block_length = BT_A2DP_BLOCK_LENGTH_8;
+ else if (cap->block_length & BT_A2DP_BLOCK_LENGTH_4)
+ config.block_length = BT_A2DP_BLOCK_LENGTH_4;
+ else {
+ pa_log_error("No supported block lengths");
+ goto fail;
+ }
+
+ if (cap->subbands & BT_A2DP_SUBBANDS_8)
+ config.subbands = BT_A2DP_SUBBANDS_8;
+ else if (cap->subbands & BT_A2DP_SUBBANDS_4)
+ config.subbands = BT_A2DP_SUBBANDS_4;
+ else {
+ pa_log_error("No supported subbands");
+ goto fail;
+ }
+
+ if (cap->allocation_method & BT_A2DP_ALLOCATION_LOUDNESS)
+ config.allocation_method = BT_A2DP_ALLOCATION_LOUDNESS;
+ else if (cap->allocation_method & BT_A2DP_ALLOCATION_SNR)
+ config.allocation_method = BT_A2DP_ALLOCATION_SNR;
+
+ config.min_bitpool = (uint8_t) PA_MAX(MIN_BITPOOL, cap->min_bitpool);
+ config.max_bitpool = (uint8_t) PA_MIN(a2dp_default_bitpool(config.frequency, config.channel_mode), cap->max_bitpool);
+
+done:
+ pa_assert_se(r = dbus_message_new_method_return(m));
+
+ pa_assert_se(dbus_message_append_args(
+ r,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_BYTE, &pconf, size,
+ DBUS_TYPE_INVALID));
+
+ return r;
+
+fail:
+ pa_assert_se(r = (dbus_message_new_error(m, "org.bluez.MediaEndpoint.Error.InvalidArguments",
+ "Unable to select configuration")));
+ return r;
+}
+
+static DBusHandlerResult endpoint_handler(DBusConnection *c, DBusMessage *m, void *userdata) {
+ struct pa_bluetooth_discovery *y = userdata;
+ DBusMessage *r = NULL;
+ DBusError e;
+ const char *path;
+
+ pa_assert(y);
+
+ pa_log_debug("dbus: interface=%s, path=%s, member=%s\n",
+ dbus_message_get_interface(m),
+ dbus_message_get_path(m),
+ dbus_message_get_member(m));
+
+ path = dbus_message_get_path(m);
+ dbus_error_init(&e);
+
+ if (!pa_streq(path, A2DP_SOURCE_ENDPOINT) && !pa_streq(path, A2DP_SINK_ENDPOINT) && !pa_streq(path, HFP_AG_ENDPOINT))
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+
+ if (dbus_message_is_method_call(m, "org.freedesktop.DBus.Introspectable", "Introspect")) {
+ const char *xml = ENDPOINT_INTROSPECT_XML;
+
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ pa_assert_se(dbus_message_append_args(
+ r,
+ DBUS_TYPE_STRING, &xml,
+ DBUS_TYPE_INVALID));
+
+ } else if (dbus_message_is_method_call(m, "org.bluez.MediaEndpoint", "SetConfiguration")) {
+ r = endpoint_set_configuration(c, m, userdata);
+ } else if (dbus_message_is_method_call(m, "org.bluez.MediaEndpoint", "SelectConfiguration")) {
+ r = endpoint_select_configuration(c, m, userdata);
+ } else if (dbus_message_is_method_call(m, "org.bluez.MediaEndpoint", "ClearConfiguration"))
+ r = endpoint_clear_configuration(c, m, userdata);
+ else
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+
+ if (r) {
+ pa_assert_se(dbus_connection_send(pa_dbus_connection_get(y->connection), r, NULL));
+ dbus_message_unref(r);
+ }
+
+ return DBUS_HANDLER_RESULT_HANDLED;
+}
+#endif /* DBUS_TYPE_UNIX_FD */
+
pa_bluetooth_discovery* pa_bluetooth_discovery_get(pa_core *c) {
DBusError err;
pa_bluetooth_discovery *y;
+#ifdef DBUS_TYPE_UNIX_FD
+ static const DBusObjectPathVTable vtable_endpoint = {
+ .message_function = endpoint_handler,
+ };
+#endif
pa_assert(c);
@@ -696,20 +1474,33 @@ pa_bluetooth_discovery* pa_bluetooth_discovery_get(pa_core *c) {
pa_log_error("Failed to add filter function");
goto fail;
}
+ y->filter_added = TRUE;
if (pa_dbus_add_matches(
pa_dbus_connection_get(y->connection), &err,
+ "type='signal',sender='org.freedesktop.DBus',interface='org.freedesktop.DBus',member='NameOwnerChanged',arg0='org.bluez'",
"type='signal',sender='org.bluez',interface='org.bluez.Manager',member='AdapterAdded'",
"type='signal',sender='org.bluez',interface='org.bluez.Adapter',member='DeviceRemoved'",
"type='signal',sender='org.bluez',interface='org.bluez.Adapter',member='DeviceCreated'",
"type='signal',sender='org.bluez',interface='org.bluez.Device',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.Device',member='DisconnectRequested'",
"type='signal',sender='org.bluez',interface='org.bluez.Audio',member='PropertyChanged'",
"type='signal',sender='org.bluez',interface='org.bluez.Headset',member='PropertyChanged'",
- "type='signal',sender='org.bluez',interface='org.bluez.AudioSink',member='PropertyChanged'", NULL) < 0) {
+ "type='signal',sender='org.bluez',interface='org.bluez.AudioSink',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.AudioSource',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.HandsfreeGateway',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.MediaTransport',member='PropertyChanged'",
+ NULL) < 0) {
pa_log("Failed to add D-Bus matches: %s", err.message);
goto fail;
}
+#ifdef DBUS_TYPE_UNIX_FD
+ pa_assert_se(dbus_connection_register_object_path(pa_dbus_connection_get(y->connection), HFP_AG_ENDPOINT, &vtable_endpoint, y));
+ pa_assert_se(dbus_connection_register_object_path(pa_dbus_connection_get(y->connection), A2DP_SOURCE_ENDPOINT, &vtable_endpoint, y));
+ pa_assert_se(dbus_connection_register_object_path(pa_dbus_connection_get(y->connection), A2DP_SINK_ENDPOINT, &vtable_endpoint, y));
+#endif
+
list_adapters(y);
return y;
@@ -734,8 +1525,6 @@ pa_bluetooth_discovery* pa_bluetooth_discovery_ref(pa_bluetooth_discovery *y) {
}
void pa_bluetooth_discovery_unref(pa_bluetooth_discovery *y) {
- pa_bluetooth_device *d;
-
pa_assert(y);
pa_assert(PA_REFCNT_VALUE(y) > 0);
@@ -745,26 +1534,34 @@ void pa_bluetooth_discovery_unref(pa_bluetooth_discovery *y) {
pa_dbus_free_pending_list(&y->pending);
if (y->devices) {
- while ((d = pa_hashmap_steal_first(y->devices))) {
- run_callback(y, d, TRUE);
- device_free(d);
- }
-
+ remove_all_devices(y);
pa_hashmap_free(y->devices, NULL, NULL);
}
if (y->connection) {
+#ifdef DBUS_TYPE_UNIX_FD
+ dbus_connection_unregister_object_path(pa_dbus_connection_get(y->connection), HFP_AG_ENDPOINT);
+ dbus_connection_unregister_object_path(pa_dbus_connection_get(y->connection), A2DP_SOURCE_ENDPOINT);
+ dbus_connection_unregister_object_path(pa_dbus_connection_get(y->connection), A2DP_SINK_ENDPOINT);
+#endif
pa_dbus_remove_matches(pa_dbus_connection_get(y->connection),
+ "type='signal',sender='org.freedesktop.DBus',interface='org.freedesktop.DBus',member='NameOwnerChanged',arg0='org.bluez'",
"type='signal',sender='org.bluez',interface='org.bluez.Manager',member='AdapterAdded'",
"type='signal',sender='org.bluez',interface='org.bluez.Manager',member='AdapterRemoved'",
"type='signal',sender='org.bluez',interface='org.bluez.Adapter',member='DeviceRemoved'",
"type='signal',sender='org.bluez',interface='org.bluez.Adapter',member='DeviceCreated'",
"type='signal',sender='org.bluez',interface='org.bluez.Device',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.Device',member='DisconnectRequested'",
"type='signal',sender='org.bluez',interface='org.bluez.Audio',member='PropertyChanged'",
"type='signal',sender='org.bluez',interface='org.bluez.Headset',member='PropertyChanged'",
- "type='signal',sender='org.bluez',interface='org.bluez.AudioSink',member='PropertyChanged'", NULL);
-
- dbus_connection_remove_filter(pa_dbus_connection_get(y->connection), filter_cb, y);
+ "type='signal',sender='org.bluez',interface='org.bluez.AudioSink',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.AudioSource',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.HandsfreeGateway',member='PropertyChanged'",
+ "type='signal',sender='org.bluez',interface='org.bluez.MediaTransport',member='PropertyChanged'",
+ NULL);
+
+ if (y->filter_added)
+ dbus_connection_remove_filter(pa_dbus_connection_get(y->connection), filter_cb, y);
pa_dbus_connection_unref(y->connection);
}
diff --git a/src/modules/bluetooth/bluetooth-util.h b/src/modules/bluetooth/bluetooth-util.h
index 265caf40..248ca47d 100644
--- a/src/modules/bluetooth/bluetooth-util.h
+++ b/src/modules/bluetooth/bluetooth-util.h
@@ -4,7 +4,7 @@
/***
This file is part of PulseAudio.
- Copyright 2008 Joao Paulo Rechi Vita
+ Copyright 2008-2009 Joao Paulo Rechi Vita
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as
@@ -26,25 +26,27 @@
#include <pulsecore/llist.h>
#include <pulsecore/macro.h>
-#include <pulsecore/core-util.h>
+
+#define PA_BLUETOOTH_ERROR_NOT_SUPPORTED "org.bluez.Error.NotSupported"
/* UUID copied from bluez/audio/device.h */
-#define GENERIC_AUDIO_UUID "00001203-0000-1000-8000-00805F9B34FB"
+#define GENERIC_AUDIO_UUID "00001203-0000-1000-8000-00805f9b34fb"
-#define HSP_HS_UUID "00001108-0000-1000-8000-00805F9B34FB"
-#define HSP_AG_UUID "00001112-0000-1000-8000-00805F9B34FB"
+#define HSP_HS_UUID "00001108-0000-1000-8000-00805f9b34fb"
+#define HSP_AG_UUID "00001112-0000-1000-8000-00805f9b34fb"
-#define HFP_HS_UUID "0000111E-0000-1000-8000-00805F9B34FB"
-#define HFP_AG_UUID "0000111F-0000-1000-8000-00805F9B34FB"
+#define HFP_HS_UUID "0000111e-0000-1000-8000-00805f9b34fb"
+#define HFP_AG_UUID "0000111f-0000-1000-8000-00805f9b34fb"
-#define ADVANCED_AUDIO_UUID "0000110D-0000-1000-8000-00805F9B34FB"
+#define ADVANCED_AUDIO_UUID "0000110d-0000-1000-8000-00805f9b34fb"
-#define A2DP_SOURCE_UUID "0000110A-0000-1000-8000-00805F9B34FB"
-#define A2DP_SINK_UUID "0000110B-0000-1000-8000-00805F9B34FB"
+#define A2DP_SOURCE_UUID "0000110a-0000-1000-8000-00805f9b34fb"
+#define A2DP_SINK_UUID "0000110b-0000-1000-8000-00805f9b34fb"
typedef struct pa_bluetooth_uuid pa_bluetooth_uuid;
typedef struct pa_bluetooth_device pa_bluetooth_device;
typedef struct pa_bluetooth_discovery pa_bluetooth_discovery;
+typedef struct pa_bluetooth_transport pa_bluetooth_transport;
struct userdata;
@@ -53,14 +55,31 @@ struct pa_bluetooth_uuid {
PA_LLIST_FIELDS(pa_bluetooth_uuid);
};
-/* This enum is shared among Audio, Headset, and AudioSink, although not all values are acceptable in all profiles */
+enum profile {
+ PROFILE_A2DP,
+ PROFILE_A2DP_SOURCE,
+ PROFILE_HSP,
+ PROFILE_HFGW,
+ PROFILE_OFF
+};
+
+struct pa_bluetooth_transport {
+ pa_bluetooth_discovery *y;
+ char *path;
+ enum profile profile;
+ uint8_t codec;
+ uint8_t *config;
+ int config_size;
+ pa_bool_t nrec;
+};
+
+/* This enum is shared among Audio, Headset, AudioSink, and AudioSource, although not all values are acceptable in all profiles */
typedef enum pa_bt_audio_state {
PA_BT_AUDIO_STATE_INVALID = -1,
PA_BT_AUDIO_STATE_DISCONNECTED,
PA_BT_AUDIO_STATE_CONNECTING,
PA_BT_AUDIO_STATE_CONNECTED,
- PA_BT_AUDIO_STATE_PLAYING,
- PA_BT_AUDIO_STATE_LAST
+ PA_BT_AUDIO_STATE_PLAYING
} pa_bt_audio_state_t;
struct pa_bluetooth_device {
@@ -71,6 +90,7 @@ struct pa_bluetooth_device {
/* Device information */
char *name;
char *path;
+ pa_hashmap *transports;
int paired;
char *alias;
int device_connected;
@@ -85,8 +105,14 @@ struct pa_bluetooth_device {
/* AudioSink state */
pa_bt_audio_state_t audio_sink_state;
+ /* AudioSource state */
+ pa_bt_audio_state_t audio_source_state;
+
/* Headset state */
pa_bt_audio_state_t headset_state;
+
+ /* HandsfreeGateway state */
+ pa_bt_audio_state_t hfgw_state;
};
pa_bluetooth_discovery* pa_bluetooth_discovery_get(pa_core *core);
@@ -98,6 +124,13 @@ void pa_bluetooth_discovery_sync(pa_bluetooth_discovery *d);
const pa_bluetooth_device* pa_bluetooth_discovery_get_by_path(pa_bluetooth_discovery *d, const char* path);
const pa_bluetooth_device* pa_bluetooth_discovery_get_by_address(pa_bluetooth_discovery *d, const char* address);
+const pa_bluetooth_transport* pa_bluetooth_discovery_get_transport(pa_bluetooth_discovery *y, const char *path);
+const pa_bluetooth_transport* pa_bluetooth_device_get_transport(const pa_bluetooth_device *d, enum profile profile);
+
+int pa_bluetooth_transport_acquire(const pa_bluetooth_transport *t, const char *accesstype, size_t *imtu, size_t *omtu);
+void pa_bluetooth_transport_release(const pa_bluetooth_transport *t, const char *accesstype);
+int pa_bluetooth_transport_parse_property(pa_bluetooth_transport *t, DBusMessageIter *i);
+
pa_hook* pa_bluetooth_discovery_hook(pa_bluetooth_discovery *d);
const char* pa_bluetooth_get_form_factor(uint32_t class);
diff --git a/src/modules/bluetooth/ipc.c b/src/modules/bluetooth/ipc.c
index dcecad8a..1bdad784 100644
--- a/src/modules/bluetooth/ipc.c
+++ b/src/modules/bluetooth/ipc.c
@@ -2,7 +2,7 @@
*
* BlueZ - Bluetooth protocol stack for Linux
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -106,8 +106,10 @@ int bt_audio_service_get_data_fd(int sk)
for (cmsg = CMSG_FIRSTHDR(&msgh); cmsg != NULL;
cmsg = CMSG_NXTHDR(&msgh, cmsg)) {
if (cmsg->cmsg_level == SOL_SOCKET
- && cmsg->cmsg_type == SCM_RIGHTS)
- return (*(int *) CMSG_DATA(cmsg));
+ && cmsg->cmsg_type == SCM_RIGHTS) {
+ memcpy(&ret, CMSG_DATA(cmsg), sizeof(int));
+ return ret;
+ }
}
errno = EINVAL;
diff --git a/src/modules/bluetooth/ipc.h b/src/modules/bluetooth/ipc.h
index 2e170f50..d69b97e4 100644
--- a/src/modules/bluetooth/ipc.h
+++ b/src/modules/bluetooth/ipc.h
@@ -2,7 +2,7 @@
*
* BlueZ - Bluetooth protocol stack for Linux
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -101,6 +101,7 @@ typedef struct {
#define BT_STOP_STREAM 5
#define BT_CLOSE 6
#define BT_CONTROL 7
+#define BT_DELAY_REPORT 8
#define BT_CAPABILITIES_TRANSPORT_A2DP 0
#define BT_CAPABILITIES_TRANSPORT_SCO 1
@@ -324,6 +325,16 @@ struct bt_control_ind {
uint8_t key; /* Control Key */
} __attribute__ ((packed));
+struct bt_delay_report_req {
+ bt_audio_msg_header_t h;
+ uint16_t delay;
+} __attribute__ ((packed));
+
+struct bt_delay_report_ind {
+ bt_audio_msg_header_t h;
+ uint16_t delay;
+} __attribute__ ((packed));
+
/* Function declaration */
/* Opens a connection to the audio service: return a socket descriptor */
diff --git a/src/modules/bluetooth/module-bluetooth-device.c b/src/modules/bluetooth/module-bluetooth-device.c
index dbec00d4..288ad2fd 100644
--- a/src/modules/bluetooth/module-bluetooth-device.c
+++ b/src/modules/bluetooth/module-bluetooth-device.c
@@ -1,7 +1,7 @@
/***
This file is part of PulseAudio.
- Copyright 2008 Joao Paulo Rechi Vita
+ Copyright 2008-2009 Joao Paulo Rechi Vita
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as
@@ -25,37 +25,40 @@
#include <string.h>
#include <errno.h>
-#include <poll.h>
-#include <sys/ioctl.h>
#include <linux/sockios.h>
#include <arpa/inet.h>
-#include <pulse/xmalloc.h>
-#include <pulse/timeval.h>
-#include <pulse/sample.h>
#include <pulse/i18n.h>
+#include <pulse/rtclock.h>
+#include <pulse/sample.h>
+#include <pulse/timeval.h>
+#include <pulse/xmalloc.h>
#include <pulsecore/module.h>
#include <pulsecore/modargs.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/core-error.h>
+#include <pulsecore/shared.h>
#include <pulsecore/socket-util.h>
#include <pulsecore/thread.h>
#include <pulsecore/thread-mq.h>
+#include <pulsecore/poll.h>
#include <pulsecore/rtpoll.h>
#include <pulsecore/time-smoother.h>
-#include <pulsecore/rtclock.h>
#include <pulsecore/namereg.h>
#include <pulsecore/dbus-shared.h>
#include "module-bluetooth-device-symdef.h"
#include "ipc.h"
#include "sbc.h"
+#include "a2dp-codecs.h"
#include "rtp.h"
#include "bluetooth-util.h"
-#define MAX_BITPOOL 64
-#define MIN_BITPOOL 2U
+#define BITPOOL_DEC_LIMIT 32
+#define BITPOOL_DEC_STEP 5
+#define HSP_MAX_GAIN 15
PA_MODULE_AUTHOR("Joao Paulo Rechi Vita");
PA_MODULE_DESCRIPTION("Bluetooth audio sink and source");
@@ -70,17 +73,13 @@ PA_MODULE_USAGE(
"source_name=<name for the source> "
"source_properties=<properties for the source> "
"address=<address of the device> "
- "profile=<a2dp|hsp> "
+ "profile=<a2dp|hsp|hfgw> "
"rate=<sample rate> "
"channels=<number of channels> "
- "path=<device object path>");
-
-/*
-#ifdef NOKIA
+ "path=<device object path> "
+ "auto_connect=<automatically connect?> "
"sco_sink=<SCO over PCM sink name> "
- "sco_source=<SCO over PCM source name>"
-#endif
-*/
+ "sco_source=<SCO over PCM source name>");
/* TODO: not close fd when entering suspend mode in a2dp */
@@ -97,10 +96,9 @@ static const char* const valid_modargs[] = {
"rate",
"channels",
"path",
-#ifdef NOKIA
+ "auto_connect",
"sco_sink",
"sco_source",
-#endif
NULL
};
@@ -114,31 +112,31 @@ struct a2dp_info {
size_t buffer_size; /* Size of the buffer */
uint16_t seq_num; /* Cumulative packet sequence */
+ uint8_t min_bitpool;
+ uint8_t max_bitpool;
};
struct hsp_info {
pcm_capabilities_t pcm_capabilities;
-#ifdef NOKIA
pa_sink *sco_sink;
+ void (*sco_sink_set_volume)(pa_sink *s);
pa_source *sco_source;
-#endif
+ void (*sco_source_set_volume)(pa_source *s);
pa_hook_slot *sink_state_changed_slot;
pa_hook_slot *source_state_changed_slot;
};
-enum profile {
- PROFILE_A2DP,
- PROFILE_HSP,
- PROFILE_OFF
-};
-
struct userdata {
pa_core *core;
pa_module *module;
char *address;
char *path;
+ char *transport;
+ char *accesstype;
+
pa_bluetooth_discovery *discovery;
+ pa_bool_t auto_connect;
pa_dbus_connection *connection;
@@ -174,17 +172,18 @@ struct userdata {
int stream_write_type;
int service_write_type, service_read_type;
+
+ pa_bool_t filter_added;
};
#define FIXED_LATENCY_PLAYBACK_A2DP (25*PA_USEC_PER_MSEC)
+#define FIXED_LATENCY_RECORD_A2DP (25*PA_USEC_PER_MSEC)
#define FIXED_LATENCY_PLAYBACK_HSP (125*PA_USEC_PER_MSEC)
#define FIXED_LATENCY_RECORD_HSP (25*PA_USEC_PER_MSEC)
#define MAX_PLAYBACK_CATCH_UP_USEC (100*PA_USEC_PER_MSEC)
-#ifdef NOKIA
#define USE_SCO_OVER_PCM(u) (u->profile == PROFILE_HSP && (u->hsp.sco_sink && u->hsp.sco_source))
-#endif
static int init_bt(struct userdata *u);
static int init_profile(struct userdata *u);
@@ -193,10 +192,14 @@ static int service_send(struct userdata *u, const bt_audio_msg_header_t *msg) {
ssize_t r;
pa_assert(u);
- pa_assert(u->service_fd >= 0);
pa_assert(msg);
pa_assert(msg->length > 0);
+ if (u->service_fd < 0) {
+ pa_log_warn("Service not connected");
+ return -1;
+ }
+
pa_log_debug("Sending %s -> %s",
pa_strnull(bt_audio_strtype(msg->type)),
pa_strnull(bt_audio_strname(msg->name)));
@@ -218,9 +221,7 @@ static int service_recv(struct userdata *u, bt_audio_msg_header_t *msg, size_t r
pa_assert(u);
pa_assert(u->service_fd >= 0);
pa_assert(msg);
-
- if (room <= 0)
- room = BT_SUGGESTED_BUFFER_SIZE;
+ pa_assert(room >= sizeof(*msg));
pa_log_debug("Trying to receive message from audio service...");
@@ -233,6 +234,11 @@ static int service_recv(struct userdata *u, bt_audio_msg_header_t *msg, size_t r
return -1;
}
+ if (msg->length > room) {
+ pa_log_error("Not enough room.");
+ return -1;
+ }
+
/* Secondly, read the payload */
if (msg->length > sizeof(*msg)) {
@@ -306,13 +312,13 @@ static int parse_caps(struct userdata *u, uint8_t seid, const struct bt_get_capa
pa_log_debug("Payload size is %lu %lu", (unsigned long) bytes_left, (unsigned long) sizeof(*codec));
- if ((u->profile == PROFILE_A2DP && codec->transport != BT_CAPABILITIES_TRANSPORT_A2DP) ||
- (u->profile == PROFILE_HSP && codec->transport != BT_CAPABILITIES_TRANSPORT_SCO)) {
+ if (((u->profile == PROFILE_A2DP || u->profile == PROFILE_A2DP_SOURCE) && codec->transport != BT_CAPABILITIES_TRANSPORT_A2DP) ||
+ ((u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW) && codec->transport != BT_CAPABILITIES_TRANSPORT_SCO)) {
pa_log_error("Got capabilities for wrong codec.");
return -1;
}
- if (u->profile == PROFILE_HSP) {
+ if (u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW) {
if (bytes_left <= 0 || codec->length != sizeof(u->hsp.pcm_capabilities))
return -1;
@@ -343,6 +349,26 @@ static int parse_caps(struct userdata *u, uint8_t seid, const struct bt_get_capa
return codec->seid;
memcpy(&u->a2dp.sbc_capabilities, codec, sizeof(u->a2dp.sbc_capabilities));
+
+ } else if (u->profile == PROFILE_A2DP_SOURCE) {
+
+ while (bytes_left > 0) {
+ if ((codec->type == BT_A2DP_SBC_SOURCE) && !codec->lock)
+ break;
+
+ bytes_left -= codec->length;
+ codec = (const codec_capabilities_t*) ((const uint8_t*) codec + codec->length);
+ }
+
+ if (bytes_left <= 0 || codec->length != sizeof(u->a2dp.sbc_capabilities))
+ return -1;
+
+ pa_assert(codec->type == BT_A2DP_SBC_SOURCE);
+
+ if (codec->configured && seid == 0)
+ return codec->seid;
+
+ memcpy(&u->a2dp.sbc_capabilities, codec, sizeof(u->a2dp.sbc_capabilities));
}
return 0;
@@ -367,13 +393,13 @@ static int get_caps(struct userdata *u, uint8_t seid) {
msg.getcaps_req.seid = seid;
pa_strlcpy(msg.getcaps_req.object, u->path, sizeof(msg.getcaps_req.object));
- if (u->profile == PROFILE_A2DP)
+ if (u->profile == PROFILE_A2DP || u->profile == PROFILE_A2DP_SOURCE)
msg.getcaps_req.transport = BT_CAPABILITIES_TRANSPORT_A2DP;
else {
- pa_assert(u->profile == PROFILE_HSP);
+ pa_assert(u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW);
msg.getcaps_req.transport = BT_CAPABILITIES_TRANSPORT_SCO;
}
- msg.getcaps_req.flags = BT_FLAG_AUTOCONNECT;
+ msg.getcaps_req.flags = u->auto_connect ? BT_FLAG_AUTOCONNECT : 0;
if (service_send(u, &msg.getcaps_req.h) < 0)
return -1;
@@ -450,7 +476,7 @@ static int setup_a2dp(struct userdata *u) {
};
pa_assert(u);
- pa_assert(u->profile == PROFILE_A2DP);
+ pa_assert(u->profile == PROFILE_A2DP || u->profile == PROFILE_A2DP_SOURCE);
cap = &u->a2dp.sbc_capabilities;
@@ -543,7 +569,7 @@ static int setup_a2dp(struct userdata *u) {
}
/* Run from main thread */
-static void setup_sbc(struct a2dp_info *a2dp) {
+static void setup_sbc(struct a2dp_info *a2dp, enum profile p) {
sbc_capabilities_t *active_capabilities;
pa_assert(a2dp);
@@ -629,7 +655,11 @@ static void setup_sbc(struct a2dp_info *a2dp) {
pa_assert_not_reached();
}
- a2dp->sbc.bitpool = active_capabilities->max_bitpool;
+ a2dp->min_bitpool = active_capabilities->min_bitpool;
+ a2dp->max_bitpool = active_capabilities->max_bitpool;
+
+ /* Set minimum bitpool for source to get the maximum possible block_size */
+ a2dp->sbc.bitpool = p == PROFILE_A2DP ? a2dp->max_bitpool : a2dp->min_bitpool;
a2dp->codesize = sbc_get_codesize(&a2dp->sbc);
a2dp->frame_length = sbc_get_frame_length(&a2dp->sbc);
}
@@ -651,8 +681,8 @@ static int set_conf(struct userdata *u) {
msg.open_req.h.length = sizeof(msg.open_req);
pa_strlcpy(msg.open_req.object, u->path, sizeof(msg.open_req.object));
- msg.open_req.seid = u->profile == PROFILE_A2DP ? u->a2dp.sbc_capabilities.capability.seid : BT_A2DP_SEID_RANGE + 1;
- msg.open_req.lock = u->profile == PROFILE_A2DP ? BT_WRITE_LOCK : BT_READ_LOCK | BT_WRITE_LOCK;
+ msg.open_req.seid = (u->profile == PROFILE_A2DP || u->profile == PROFILE_A2DP_SOURCE) ? u->a2dp.sbc_capabilities.capability.seid : BT_A2DP_SEID_RANGE + 1;
+ msg.open_req.lock = (u->profile == PROFILE_A2DP) ? BT_WRITE_LOCK : BT_READ_LOCK | BT_WRITE_LOCK;
if (service_send(u, &msg.open_req.h) < 0)
return -1;
@@ -660,13 +690,13 @@ static int set_conf(struct userdata *u) {
if (service_expect(u, &msg.open_rsp.h, sizeof(msg), BT_OPEN, sizeof(msg.open_rsp)) < 0)
return -1;
- if (u->profile == PROFILE_A2DP ) {
+ if (u->profile == PROFILE_A2DP || u->profile == PROFILE_A2DP_SOURCE) {
u->sample_spec.format = PA_SAMPLE_S16LE;
if (setup_a2dp(u) < 0)
return -1;
} else {
- pa_assert(u->profile == PROFILE_HSP);
+ pa_assert(u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW);
u->sample_spec.format = PA_SAMPLE_S16LE;
u->sample_spec.channels = 1;
@@ -678,7 +708,7 @@ static int set_conf(struct userdata *u) {
msg.setconf_req.h.name = BT_SET_CONFIGURATION;
msg.setconf_req.h.length = sizeof(msg.setconf_req);
- if (u->profile == PROFILE_A2DP) {
+ if (u->profile == PROFILE_A2DP || u->profile == PROFILE_A2DP_SOURCE) {
memcpy(&msg.setconf_req.codec, &u->a2dp.sbc_capabilities, sizeof(u->a2dp.sbc_capabilities));
} else {
msg.setconf_req.codec.transport = BT_CAPABILITIES_TRANSPORT_SCO;
@@ -696,8 +726,8 @@ static int set_conf(struct userdata *u) {
u->link_mtu = msg.setconf_rsp.link_mtu;
/* setup SBC encoder now we agree on parameters */
- if (u->profile == PROFILE_A2DP) {
- setup_sbc(&u->a2dp);
+ if (u->profile == PROFILE_A2DP || u->profile == PROFILE_A2DP_SOURCE) {
+ setup_sbc(&u->a2dp, u->profile);
u->block_size =
((u->link_mtu - sizeof(struct rtp_header) - sizeof(struct rtp_payload))
@@ -712,42 +742,44 @@ static int set_conf(struct userdata *u) {
return 0;
}
-/* from IO thread, except in SCO over PCM */
-static int start_stream_fd(struct userdata *u) {
- union {
- bt_audio_msg_header_t rsp;
- struct bt_start_stream_req start_req;
- struct bt_start_stream_rsp start_rsp;
- struct bt_new_stream_ind streamfd_ind;
- bt_audio_error_t error;
- uint8_t buf[BT_SUGGESTED_BUFFER_SIZE];
- } msg;
- struct pollfd *pollfd;
- int one;
+/* from IO thread */
+static void a2dp_set_bitpool(struct userdata *u, uint8_t bitpool)
+{
+ struct a2dp_info *a2dp;
pa_assert(u);
- pa_assert(u->rtpoll);
- pa_assert(!u->rtpoll_item);
- pa_assert(u->stream_fd < 0);
- memset(msg.buf, 0, BT_SUGGESTED_BUFFER_SIZE);
- msg.start_req.h.type = BT_REQUEST;
- msg.start_req.h.name = BT_START_STREAM;
- msg.start_req.h.length = sizeof(msg.start_req);
+ a2dp = &u->a2dp;
- if (service_send(u, &msg.start_req.h) < 0)
- return -1;
+ if (a2dp->sbc.bitpool == bitpool)
+ return;
- if (service_expect(u, &msg.rsp, sizeof(msg), BT_START_STREAM, sizeof(msg.start_rsp)) < 0)
- return -1;
+ if (bitpool > a2dp->max_bitpool)
+ bitpool = a2dp->max_bitpool;
+ else if (bitpool < a2dp->min_bitpool)
+ bitpool = a2dp->min_bitpool;
- if (service_expect(u, &msg.rsp, sizeof(msg), BT_NEW_STREAM, sizeof(msg.streamfd_ind)) < 0)
- return -1;
+ a2dp->sbc.bitpool = bitpool;
- if ((u->stream_fd = bt_audio_service_get_data_fd(u->service_fd)) < 0) {
- pa_log("Failed to get stream fd from audio service.");
- return -1;
- }
+ a2dp->codesize = sbc_get_codesize(&a2dp->sbc);
+ a2dp->frame_length = sbc_get_frame_length(&a2dp->sbc);
+
+ pa_log_debug("Bitpool has changed to %u", a2dp->sbc.bitpool);
+
+ u->block_size =
+ (u->link_mtu - sizeof(struct rtp_header) - sizeof(struct rtp_payload))
+ / a2dp->frame_length * a2dp->codesize;
+
+ pa_sink_set_max_request_within_thread(u->sink, u->block_size);
+ pa_sink_set_fixed_latency_within_thread(u->sink,
+ FIXED_LATENCY_PLAYBACK_A2DP + pa_bytes_to_usec(u->block_size, &u->sample_spec));
+}
+
+/* from IO thread, except in SCO over PCM */
+
+static int setup_stream(struct userdata *u) {
+ struct pollfd *pollfd;
+ int one;
pa_make_fd_nonblock(u->stream_fd);
pa_make_socket_low_delay(u->stream_fd);
@@ -758,6 +790,9 @@ static int start_stream_fd(struct userdata *u) {
pa_log_debug("Stream properly set up, we're ready to roll!");
+ if (u->profile == PROFILE_A2DP)
+ a2dp_set_bitpool(u, u->a2dp.max_bitpool);
+
u->rtpoll_item = pa_rtpoll_item_new(u->rtpoll, PA_RTPOLL_NEVER, 1);
pollfd = pa_rtpoll_item_get_pollfd(u->rtpoll_item, NULL);
pollfd->fd = u->stream_fd;
@@ -773,12 +808,49 @@ static int start_stream_fd(struct userdata *u) {
TRUE,
TRUE,
10,
- pa_rtclock_usec(),
+ pa_rtclock_now(),
TRUE);
return 0;
}
+static int start_stream_fd(struct userdata *u) {
+ union {
+ bt_audio_msg_header_t rsp;
+ struct bt_start_stream_req start_req;
+ struct bt_start_stream_rsp start_rsp;
+ struct bt_new_stream_ind streamfd_ind;
+ bt_audio_error_t error;
+ uint8_t buf[BT_SUGGESTED_BUFFER_SIZE];
+ } msg;
+
+ pa_assert(u);
+ pa_assert(u->rtpoll);
+ pa_assert(!u->rtpoll_item);
+ pa_assert(u->stream_fd < 0);
+
+ memset(msg.buf, 0, BT_SUGGESTED_BUFFER_SIZE);
+ msg.start_req.h.type = BT_REQUEST;
+ msg.start_req.h.name = BT_START_STREAM;
+ msg.start_req.h.length = sizeof(msg.start_req);
+
+ if (service_send(u, &msg.start_req.h) < 0)
+ return -1;
+
+ if (service_expect(u, &msg.rsp, sizeof(msg), BT_START_STREAM, sizeof(msg.start_rsp)) < 0)
+ return -1;
+
+ if (service_expect(u, &msg.rsp, sizeof(msg), BT_NEW_STREAM, sizeof(msg.streamfd_ind)) < 0)
+ return -1;
+
+ if ((u->stream_fd = bt_audio_service_get_data_fd(u->service_fd)) < 0) {
+ pa_log("Failed to get stream fd from audio service.");
+ return -1;
+ }
+
+ return setup_stream(u);
+}
+
/* from IO thread */
static int stop_stream_fd(struct userdata *u) {
union {
@@ -792,23 +864,25 @@ static int stop_stream_fd(struct userdata *u) {
pa_assert(u);
pa_assert(u->rtpoll);
- pa_assert(u->rtpoll_item);
- pa_assert(u->stream_fd >= 0);
- pa_rtpoll_item_free(u->rtpoll_item);
- u->rtpoll_item = NULL;
+ if (u->rtpoll_item) {
+ pa_rtpoll_item_free(u->rtpoll_item);
+ u->rtpoll_item = NULL;
+ }
- memset(msg.buf, 0, BT_SUGGESTED_BUFFER_SIZE);
- msg.start_req.h.type = BT_REQUEST;
- msg.start_req.h.name = BT_STOP_STREAM;
- msg.start_req.h.length = sizeof(msg.start_req);
+ if (u->stream_fd >= 0) {
+ memset(msg.buf, 0, BT_SUGGESTED_BUFFER_SIZE);
+ msg.start_req.h.type = BT_REQUEST;
+ msg.start_req.h.name = BT_STOP_STREAM;
+ msg.start_req.h.length = sizeof(msg.start_req);
- if (service_send(u, &msg.start_req.h) < 0 ||
- service_expect(u, &msg.rsp, sizeof(msg), BT_STOP_STREAM, sizeof(msg.start_rsp)) < 0)
- r = -1;
+ if (service_send(u, &msg.start_req.h) < 0 ||
+ service_expect(u, &msg.rsp, sizeof(msg), BT_STOP_STREAM, sizeof(msg.start_rsp)) < 0)
+ r = -1;
- pa_close(u->stream_fd);
- u->stream_fd = -1;
+ pa_close(u->stream_fd);
+ u->stream_fd = -1;
+ }
if (u->read_smoother) {
pa_smoother_free(u->read_smoother);
@@ -818,6 +892,75 @@ static int stop_stream_fd(struct userdata *u) {
return r;
}
+static void bt_transport_release(struct userdata *u) {
+ const char *accesstype = "rw";
+ const pa_bluetooth_transport *t;
+
+ /* Ignore if already released */
+ if (!u->accesstype)
+ return;
+
+ pa_log_debug("Releasing transport %s", u->transport);
+
+ t = pa_bluetooth_discovery_get_transport(u->discovery, u->transport);
+ if (t)
+ pa_bluetooth_transport_release(t, accesstype);
+
+ pa_xfree(u->accesstype);
+ u->accesstype = NULL;
+
+ if (u->rtpoll_item) {
+ pa_rtpoll_item_free(u->rtpoll_item);
+ u->rtpoll_item = NULL;
+ }
+
+ if (u->stream_fd >= 0) {
+ pa_close(u->stream_fd);
+ u->stream_fd = -1;
+ }
+
+ if (u->read_smoother) {
+ pa_smoother_free(u->read_smoother);
+ u->read_smoother = NULL;
+ }
+}
+
+static int bt_transport_acquire(struct userdata *u, pa_bool_t start) {
+ const char *accesstype = "rw";
+ const pa_bluetooth_transport *t;
+
+ if (u->accesstype) {
+ if (start)
+ goto done;
+ return 0;
+ }
+
+ pa_log_debug("Acquiring transport %s", u->transport);
+
+ t = pa_bluetooth_discovery_get_transport(u->discovery, u->transport);
+ if (!t) {
+ pa_log("Transport %s no longer available", u->transport);
+ pa_xfree(u->transport);
+ u->transport = NULL;
+ return -1;
+ }
+
+ /* FIXME: Handle in/out MTU properly when unix socket is not longer supported */
+ u->stream_fd = pa_bluetooth_transport_acquire(t, accesstype, NULL, &u->link_mtu);
+ if (u->stream_fd < 0)
+ return -1;
+
+ u->accesstype = pa_xstrdup(accesstype);
+ pa_log_info("Transport %s acquired: fd %d", u->transport, u->stream_fd);
+
+ if (!start)
+ return 0;
+
+done:
+ pa_log_info("Transport %s resuming", u->transport);
+ return setup_stream(u);
+}
+
/* Run from IO thread */
static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
struct userdata *u = PA_SINK(o)->userdata;
@@ -836,11 +979,15 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
pa_assert(PA_SINK_IS_OPENED(u->sink->thread_info.state));
/* Stop the device if the source is suspended as well */
- if (!u->source || u->source->state == PA_SOURCE_SUSPENDED)
+ if (!u->source || u->source->state == PA_SOURCE_SUSPENDED) {
/* We deliberately ignore whether stopping
* actually worked. Since the stream_fd is
* closed it doesn't really matter */
- stop_stream_fd(u);
+ if (u->transport)
+ bt_transport_release(u);
+ else
+ stop_stream_fd(u);
+ }
break;
@@ -850,9 +997,13 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
break;
/* Resume the device if the source was suspended as well */
- if (!u->source || u->source->state == PA_SOURCE_SUSPENDED)
- if (start_stream_fd(u) < 0)
+ if (!u->source || u->source->state == PA_SOURCE_SUSPENDED) {
+ if (u->transport) {
+ if (bt_transport_acquire(u, TRUE) < 0)
+ failed = TRUE;
+ } else if (start_stream_fd(u) < 0)
failed = TRUE;
+ }
break;
case PA_SINK_UNLINKED:
@@ -867,20 +1018,20 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
if (u->read_smoother) {
pa_usec_t wi, ri;
- ri = pa_smoother_get(u->read_smoother, pa_rtclock_usec());
+ ri = pa_smoother_get(u->read_smoother, pa_rtclock_now());
wi = pa_bytes_to_usec(u->write_index + u->block_size, &u->sample_spec);
*((pa_usec_t*) data) = wi > ri ? wi - ri : 0;
} else {
pa_usec_t ri, wi;
- ri = pa_rtclock_usec() - u->started_at;
+ ri = pa_rtclock_now() - u->started_at;
wi = pa_bytes_to_usec(u->write_index, &u->sample_spec);
*((pa_usec_t*) data) = wi > ri ? wi - ri : 0;
}
- *((pa_usec_t*) data) += u->sink->fixed_latency;
+ *((pa_usec_t*) data) += u->sink->thread_info.fixed_latency;
return 0;
}
}
@@ -908,11 +1059,15 @@ static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t off
pa_assert(PA_SOURCE_IS_OPENED(u->source->thread_info.state));
/* Stop the device if the sink is suspended as well */
- if (!u->sink || u->sink->state == PA_SINK_SUSPENDED)
- stop_stream_fd(u);
+ if (!u->sink || u->sink->state == PA_SINK_SUSPENDED) {
+ if (u->transport)
+ bt_transport_release(u);
+ else
+ stop_stream_fd(u);
+ }
if (u->read_smoother)
- pa_smoother_pause(u->read_smoother, pa_rtclock_usec());
+ pa_smoother_pause(u->read_smoother, pa_rtclock_now());
break;
case PA_SOURCE_IDLE:
@@ -921,10 +1076,13 @@ static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t off
break;
/* Resume the device if the sink was suspended as well */
- if (!u->sink || u->sink->thread_info.state == PA_SINK_SUSPENDED)
- if (start_stream_fd(u) < 0)
+ if (!u->sink || u->sink->thread_info.state == PA_SINK_SUSPENDED) {
+ if (u->transport) {
+ if (bt_transport_acquire(u, TRUE) < 0)
failed = TRUE;
-
+ } else if (start_stream_fd(u) < 0)
+ failed = TRUE;
+ }
/* We don't resume the smoother here. Instead we
* wait until the first packet arrives */
break;
@@ -939,10 +1097,14 @@ static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t off
case PA_SOURCE_MESSAGE_GET_LATENCY: {
pa_usec_t wi, ri;
- wi = pa_smoother_get(u->read_smoother, pa_rtclock_usec());
- ri = pa_bytes_to_usec(u->read_index, &u->sample_spec);
+ if (u->read_smoother) {
+ wi = pa_smoother_get(u->read_smoother, pa_rtclock_now());
+ ri = pa_bytes_to_usec(u->read_index, &u->sample_spec);
+
+ *((pa_usec_t*) data) = (wi > ri ? wi - ri : 0) + u->source->thread_info.fixed_latency;
+ } else
+ *((pa_usec_t*) data) = 0;
- *((pa_usec_t*) data) = (wi > ri ? wi - ri : 0) + u->source->fixed_latency;
return 0;
}
@@ -958,7 +1120,7 @@ static int hsp_process_render(struct userdata *u) {
int ret = 0;
pa_assert(u);
- pa_assert(u->profile == PROFILE_HSP);
+ pa_assert(u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW);
pa_assert(u->sink);
/* First, render some data */
@@ -1023,7 +1185,7 @@ static int hsp_process_push(struct userdata *u) {
pa_memchunk memchunk;
pa_assert(u);
- pa_assert(u->profile == PROFILE_HSP);
+ pa_assert(u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW);
pa_assert(u->source);
pa_assert(u->read_smoother);
@@ -1086,7 +1248,7 @@ static int hsp_process_push(struct userdata *u) {
if (!found_tstamp) {
pa_log_warn("Couldn't find SO_TIMESTAMP data in auxiliary recvmsg() data!");
- tstamp = pa_rtclock_usec();
+ tstamp = pa_rtclock_now();
}
pa_smoother_put(u->read_smoother, tstamp, pa_bytes_to_usec(u->read_index, &u->sample_spec));
@@ -1154,7 +1316,7 @@ static int a2dp_process_render(struct userdata *u) {
to_write = a2dp->buffer_size - sizeof(*header) - sizeof(*payload);
while (PA_LIKELY(to_encode > 0 && to_write > 0)) {
- size_t written;
+ ssize_t written;
ssize_t encoded;
encoded = sbc_encode(&a2dp->sbc,
@@ -1223,7 +1385,7 @@ static int a2dp_process_render(struct userdata *u) {
break;
pa_log_error("Failed to write data to socket: %s", pa_cstrerror(errno));
- ret = -1;
+ ret = -1;
break;
}
@@ -1249,6 +1411,144 @@ static int a2dp_process_render(struct userdata *u) {
return ret;
}
+static int a2dp_process_push(struct userdata *u) {
+ int ret = 0;
+ pa_memchunk memchunk;
+
+ pa_assert(u);
+ pa_assert(u->profile == PROFILE_A2DP_SOURCE);
+ pa_assert(u->source);
+ pa_assert(u->read_smoother);
+
+ memchunk.memblock = pa_memblock_new(u->core->mempool, u->block_size);
+ memchunk.index = memchunk.length = 0;
+
+ for (;;) {
+ pa_bool_t found_tstamp = FALSE;
+ pa_usec_t tstamp;
+ struct a2dp_info *a2dp;
+ struct rtp_header *header;
+ struct rtp_payload *payload;
+ const void *p;
+ void *d;
+ ssize_t l;
+ size_t to_write, to_decode;
+ unsigned frame_count;
+
+ a2dp_prepare_buffer(u);
+
+ a2dp = &u->a2dp;
+ header = a2dp->buffer;
+ payload = (struct rtp_payload*) ((uint8_t*) a2dp->buffer + sizeof(*header));
+
+ l = pa_read(u->stream_fd, a2dp->buffer, a2dp->buffer_size, &u->stream_write_type);
+
+ if (l <= 0) {
+
+ if (l < 0 && errno == EINTR)
+ /* Retry right away if we got interrupted */
+ continue;
+
+ else if (l < 0 && errno == EAGAIN)
+ /* Hmm, apparently the socket was not readable, give up for now. */
+ break;
+
+ pa_log_error("Failed to read data from socket: %s", l < 0 ? pa_cstrerror(errno) : "EOF");
+ ret = -1;
+ break;
+ }
+
+ pa_assert((size_t) l <= a2dp->buffer_size);
+
+ u->read_index += (uint64_t) l;
+
+ /* TODO: get timestamp from rtp */
+ if (!found_tstamp) {
+ /* pa_log_warn("Couldn't find SO_TIMESTAMP data in auxiliary recvmsg() data!"); */
+ tstamp = pa_rtclock_now();
+ }
+
+ pa_smoother_put(u->read_smoother, tstamp, pa_bytes_to_usec(u->read_index, &u->sample_spec));
+ pa_smoother_resume(u->read_smoother, tstamp, TRUE);
+
+ p = (uint8_t*) a2dp->buffer + sizeof(*header) + sizeof(*payload);
+ to_decode = l - sizeof(*header) - sizeof(*payload);
+
+ d = pa_memblock_acquire(memchunk.memblock);
+ to_write = memchunk.length = pa_memblock_get_length(memchunk.memblock);
+
+ while (PA_LIKELY(to_decode > 0)) {
+ size_t written;
+ ssize_t decoded;
+
+ decoded = sbc_decode(&a2dp->sbc,
+ p, to_decode,
+ d, to_write,
+ &written);
+
+ if (PA_UNLIKELY(decoded <= 0)) {
+ pa_log_error("SBC decoding error (%li)", (long) decoded);
+ pa_memblock_release(memchunk.memblock);
+ pa_memblock_unref(memchunk.memblock);
+ return -1;
+ }
+
+/* pa_log_debug("SBC: decoded: %lu; written: %lu", (unsigned long) decoded, (unsigned long) written); */
+/* pa_log_debug("SBC: frame_length: %lu; codesize: %lu", (unsigned long) a2dp->frame_length, (unsigned long) a2dp->codesize); */
+
+ /* Reset frame length, it can be changed due to bitpool change */
+ a2dp->frame_length = sbc_get_frame_length(&a2dp->sbc);
+
+ pa_assert_fp((size_t) decoded <= to_decode);
+ pa_assert_fp((size_t) decoded == a2dp->frame_length);
+
+ pa_assert_fp((size_t) written == a2dp->codesize);
+
+ p = (const uint8_t*) p + decoded;
+ to_decode -= decoded;
+
+ d = (uint8_t*) d + written;
+ to_write -= written;
+
+ frame_count++;
+ }
+
+ memchunk.length -= to_write;
+
+ pa_memblock_release(memchunk.memblock);
+
+ pa_source_post(u->source, &memchunk);
+
+ ret = 1;
+ break;
+ }
+
+ pa_memblock_unref(memchunk.memblock);
+
+ return ret;
+}
+
+static void a2dp_reduce_bitpool(struct userdata *u)
+{
+ struct a2dp_info *a2dp;
+ uint8_t bitpool;
+
+ pa_assert(u);
+
+ a2dp = &u->a2dp;
+
+ /* Check if bitpool is already at its limit */
+ if (a2dp->sbc.bitpool <= BITPOOL_DEC_LIMIT)
+ return;
+
+ bitpool = a2dp->sbc.bitpool - BITPOOL_DEC_STEP;
+
+ if (bitpool < BITPOOL_DEC_LIMIT)
+ bitpool = BITPOOL_DEC_LIMIT;
+
+ a2dp_set_bitpool(u, bitpool);
+}
+
static void thread_func(void *userdata) {
struct userdata *u = userdata;
unsigned do_write = 0;
@@ -1261,11 +1561,13 @@ static void thread_func(void *userdata) {
if (u->core->realtime_scheduling)
pa_make_realtime(u->core->realtime_priority);
- if (start_stream_fd(u) < 0)
- goto fail;
-
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
+
+ if (u->transport) {
+ if (bt_transport_acquire(u, TRUE) < 0)
+ goto fail;
+ } else if (start_stream_fd(u) < 0)
+ goto fail;
for (;;) {
struct pollfd *pollfd;
@@ -1285,7 +1587,12 @@ static void thread_func(void *userdata) {
if (pollfd && (pollfd->revents & POLLIN)) {
int n_read;
- if ((n_read = hsp_process_push(u)) < 0)
+ if (u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW)
+ n_read = hsp_process_push(u);
+ else
+ n_read = a2dp_process_push(u);
+
+ if (n_read < 0)
goto fail;
/* We just read something, so we are supposed to write something, too */
@@ -1309,7 +1616,7 @@ static void thread_func(void *userdata) {
/* Hmm, there is no input stream we could synchronize
* to. So let's do things by time */
- time_passed = pa_rtclock_usec() - u->started_at;
+ time_passed = pa_rtclock_now() - u->started_at;
audio_sent = pa_bytes_to_usec(u->write_index, &u->sample_spec);
if (audio_sent <= time_passed) {
@@ -1319,18 +1626,24 @@ static void thread_func(void *userdata) {
if (u->write_index > 0 && audio_to_send > MAX_PLAYBACK_CATCH_UP_USEC) {
pa_usec_t skip_usec;
uint64_t skip_bytes;
- pa_memchunk tmp;
skip_usec = audio_to_send - MAX_PLAYBACK_CATCH_UP_USEC;
skip_bytes = pa_usec_to_bytes(skip_usec, &u->sample_spec);
- pa_log_warn("Skipping %llu us (= %llu bytes) in audio stream",
- (unsigned long long) skip_usec,
- (unsigned long long) skip_bytes);
+ if (skip_bytes > 0) {
+ pa_memchunk tmp;
+
+ pa_log_warn("Skipping %llu us (= %llu bytes) in audio stream",
+ (unsigned long long) skip_usec,
+ (unsigned long long) skip_bytes);
- pa_sink_render_full(u->sink, skip_bytes, &tmp);
- pa_memblock_unref(tmp.memblock);
- u->write_index += skip_bytes;
+ pa_sink_render_full(u->sink, skip_bytes, &tmp);
+ pa_memblock_unref(tmp.memblock);
+ u->write_index += skip_bytes;
+
+ if (u->profile == PROFILE_A2DP)
+ a2dp_reduce_bitpool(u);
+ }
}
do_write = 1;
@@ -1341,7 +1654,7 @@ static void thread_func(void *userdata) {
int n_written;
if (u->write_index <= 0)
- u->started_at = pa_rtclock_usec();
+ u->started_at = pa_rtclock_now();
if (u->profile == PROFILE_A2DP) {
if ((n_written = a2dp_process_render(u)) < 0)
@@ -1351,21 +1664,27 @@ static void thread_func(void *userdata) {
goto fail;
}
+ if (n_written == 0)
+ pa_log("Broken kernel: we got EAGAIN on write() after POLLOUT!");
+
do_write -= n_written;
writable = FALSE;
}
if ((!u->source || !PA_SOURCE_IS_LINKED(u->source->thread_info.state)) && do_write <= 0) {
- pa_usec_t time_passed, next_write_at, sleep_for;
-
- /* Hmm, there is no input stream we could synchronize
- * to. So let's estimate when we need to wake up the latest */
-
- time_passed = pa_rtclock_usec() - u->started_at;
- next_write_at = pa_bytes_to_usec(u->write_index, &u->sample_spec);
- sleep_for = time_passed < next_write_at ? next_write_at - time_passed : 0;
-
-/* pa_log("Sleeping for %lu; time passed %lu, next write at %lu", (unsigned long) sleep_for, (unsigned long) time_passed, (unsigned long)next_write_at); */
+ pa_usec_t sleep_for;
+ pa_usec_t time_passed, next_write_at;
+
+ if (writable) {
+ /* Hmm, there is no input stream we could synchronize
+ * to. So let's estimate when we need to wake up the latest */
+ time_passed = pa_rtclock_now() - u->started_at;
+ next_write_at = pa_bytes_to_usec(u->write_index, &u->sample_spec);
+ sleep_for = time_passed < next_write_at ? next_write_at - time_passed : 0;
+ /* pa_log("Sleeping for %lu; time passed %lu, next write at %lu", (unsigned long) sleep_for, (unsigned long) time_passed, (unsigned long)next_write_at); */
+ } else
+ /* drop stream every 500 ms */
+ sleep_for = PA_USEC_PER_MSEC * 500;
pa_rtpoll_set_timer_relative(u->rtpoll, sleep_for);
disable_timer = FALSE;
@@ -1425,8 +1744,8 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *m, void *us
dbus_message_get_path(m),
dbus_message_get_member(m));
- if (!dbus_message_has_path(m, u->path))
- goto fail;
+ if (!dbus_message_has_path(m, u->path) && !dbus_message_has_path(m, u->transport))
+ goto fail;
if (dbus_message_is_signal(m, "org.bluez.Headset", "SpeakerGainChanged") ||
dbus_message_is_signal(m, "org.bluez.Headset", "MicrophoneGainChanged")) {
@@ -1434,23 +1753,55 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *m, void *us
dbus_uint16_t gain;
pa_cvolume v;
- if (!dbus_message_get_args(m, &err, DBUS_TYPE_UINT16, &gain, DBUS_TYPE_INVALID) || gain > 15) {
+ if (!dbus_message_get_args(m, &err, DBUS_TYPE_UINT16, &gain, DBUS_TYPE_INVALID) || gain > HSP_MAX_GAIN) {
pa_log("Failed to parse org.bluez.Headset.{Speaker|Microphone}GainChanged: %s", err.message);
goto fail;
}
if (u->profile == PROFILE_HSP) {
if (u->sink && dbus_message_is_signal(m, "org.bluez.Headset", "SpeakerGainChanged")) {
+ pa_volume_t volume = (pa_volume_t) (gain * PA_VOLUME_NORM / HSP_MAX_GAIN);
+
+ /* increment volume by one to correct rounding errors */
+ if (volume < PA_VOLUME_NORM)
+ volume++;
- pa_cvolume_set(&v, u->sample_spec.channels, (pa_volume_t) (gain * PA_VOLUME_NORM / 15));
+ pa_cvolume_set(&v, u->sample_spec.channels, volume);
pa_sink_volume_changed(u->sink, &v);
} else if (u->source && dbus_message_is_signal(m, "org.bluez.Headset", "MicrophoneGainChanged")) {
+ pa_volume_t volume = (pa_volume_t) (gain * PA_VOLUME_NORM / HSP_MAX_GAIN);
- pa_cvolume_set(&v, u->sample_spec.channels, (pa_volume_t) (gain * PA_VOLUME_NORM / 15));
+ /* increment volume by one to correct rounding errors */
+ if (volume < PA_VOLUME_NORM)
+ volume++;
+
+ pa_cvolume_set(&v, u->sample_spec.channels, volume);
pa_source_volume_changed(u->source, &v);
}
}
+ } else if (dbus_message_is_signal(m, "org.bluez.MediaTransport", "PropertyChanged")) {
+ DBusMessageIter arg_i;
+ pa_bluetooth_transport *t;
+ pa_bool_t nrec;
+
+ t = (pa_bluetooth_transport *) pa_bluetooth_discovery_get_transport(u->discovery, u->transport);
+ pa_assert(t);
+
+ if (!dbus_message_iter_init(m, &arg_i)) {
+ pa_log("Failed to parse PropertyChanged: %s", err.message);
+ goto fail;
+ }
+
+ nrec = t->nrec;
+
+ if (pa_bluetooth_transport_parse_property(t, &arg_i) < 0)
+ goto fail;
+
+ if (nrec != t->nrec) {
+ pa_log_debug("dbus: property 'NREC' changed to value '%s'", t->nrec ? "True" : "False");
+ pa_proplist_sets(u->source->proplist, "bluetooth.nrec", t->nrec ? "1" : "0");
+ }
}
fail:
@@ -1461,21 +1812,35 @@ fail:
/* Run from main thread */
static void sink_set_volume_cb(pa_sink *s) {
- struct userdata *u = s->userdata;
DBusMessage *m;
dbus_uint16_t gain;
+ pa_volume_t volume;
+ struct userdata *u;
+ char *k;
+
+ pa_assert(s);
+ pa_assert(s->core);
+
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) s);
+ u = pa_shared_get(s->core, k);
+ pa_xfree(k);
pa_assert(u);
+ pa_assert(u->sink == s);
+ pa_assert(u->profile == PROFILE_HSP);
- if (u->profile != PROFILE_HSP)
- return;
+ gain = (pa_cvolume_max(&s->real_volume) * HSP_MAX_GAIN) / PA_VOLUME_NORM;
- gain = (pa_cvolume_max(&s->virtual_volume) * 15) / PA_VOLUME_NORM;
+ if (gain > HSP_MAX_GAIN)
+ gain = HSP_MAX_GAIN;
- if (gain > 15)
- gain = 15;
+ volume = (pa_volume_t) (gain * PA_VOLUME_NORM / HSP_MAX_GAIN);
- pa_cvolume_set(&s->virtual_volume, u->sample_spec.channels, (pa_volume_t) (gain * PA_VOLUME_NORM / 15));
+ /* increment volume by one to correct rounding errors */
+ if (volume < PA_VOLUME_NORM)
+ volume++;
+
+ pa_cvolume_set(&s->real_volume, u->sample_spec.channels, volume);
pa_assert_se(m = dbus_message_new_method_call("org.bluez", u->path, "org.bluez.Headset", "SetSpeakerGain"));
pa_assert_se(dbus_message_append_args(m, DBUS_TYPE_UINT16, &gain, DBUS_TYPE_INVALID));
@@ -1485,21 +1850,35 @@ static void sink_set_volume_cb(pa_sink *s) {
/* Run from main thread */
static void source_set_volume_cb(pa_source *s) {
- struct userdata *u = s->userdata;
DBusMessage *m;
dbus_uint16_t gain;
+ pa_volume_t volume;
+ struct userdata *u;
+ char *k;
+
+ pa_assert(s);
+ pa_assert(s->core);
+
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) s);
+ u = pa_shared_get(s->core, k);
+ pa_xfree(k);
pa_assert(u);
+ pa_assert(u->source == s);
+ pa_assert(u->profile == PROFILE_HSP);
- if (u->profile != PROFILE_HSP)
- return;
+ gain = (pa_cvolume_max(&s->real_volume) * HSP_MAX_GAIN) / PA_VOLUME_NORM;
- gain = (pa_cvolume_max(&s->virtual_volume) * 15) / PA_VOLUME_NORM;
+ if (gain > HSP_MAX_GAIN)
+ gain = HSP_MAX_GAIN;
- if (gain > 15)
- gain = 15;
+ volume = (pa_volume_t) (gain * PA_VOLUME_NORM / HSP_MAX_GAIN);
- pa_cvolume_set(&s->virtual_volume, u->sample_spec.channels, (pa_volume_t) (gain * PA_VOLUME_NORM / 15));
+ /* increment volume by one to correct rounding errors */
+ if (volume < PA_VOLUME_NORM)
+ volume++;
+
+ pa_cvolume_set(&s->real_volume, u->sample_spec.channels, volume);
pa_assert_se(m = dbus_message_new_method_call("org.bluez", u->path, "org.bluez.Headset", "SetMicrophoneGain"));
pa_assert_se(dbus_message_append_args(m, DBUS_TYPE_UINT16, &gain, DBUS_TYPE_INVALID));
@@ -1536,34 +1915,48 @@ static char *get_name(const char *type, pa_modargs *ma, const char *device_id, p
return pa_sprintf_malloc("bluez_%s.%s", type, n);
}
-#ifdef NOKIA
-
-static void sco_over_pcm_state_update(struct userdata *u) {
+static int sco_over_pcm_state_update(struct userdata *u, pa_bool_t changed) {
pa_assert(u);
pa_assert(USE_SCO_OVER_PCM(u));
if (PA_SINK_IS_OPENED(pa_sink_get_state(u->hsp.sco_sink)) ||
PA_SOURCE_IS_OPENED(pa_source_get_state(u->hsp.sco_source))) {
- if (u->service_fd >= 0)
- return;
+ if (u->service_fd >= 0 && u->stream_fd >= 0)
+ return 0;
+
+ init_bt(u);
pa_log_debug("Resuming SCO over PCM");
- if ((init_bt(u) < 0) || (init_profile(u) < 0))
+ if (init_profile(u) < 0) {
pa_log("Can't resume SCO over PCM");
+ return -1;
+ }
- start_stream_fd(u);
- } else {
+ if (u->transport)
+ return bt_transport_acquire(u, TRUE);
- if (u->service_fd < 0)
- return;
+ return start_stream_fd(u);
+ }
- stop_stream_fd(u);
+ if (changed) {
+ if (u->service_fd < 0 && u->stream_fd < 0)
+ return 0;
pa_log_debug("Closing SCO over PCM");
- pa_close(u->service_fd);
- u->service_fd = -1;
+
+ if (u->transport)
+ bt_transport_release(u);
+ else if (u->stream_fd >= 0)
+ stop_stream_fd(u);
+
+ if (u->service_fd >= 0) {
+ pa_close(u->service_fd);
+ u->service_fd = -1;
+ }
}
+
+ return 0;
}
static pa_hook_result_t sink_state_changed_cb(pa_core *c, pa_sink *s, struct userdata *u) {
@@ -1574,7 +1967,7 @@ static pa_hook_result_t sink_state_changed_cb(pa_core *c, pa_sink *s, struct use
if (s != u->hsp.sco_sink)
return PA_HOOK_OK;
- sco_over_pcm_state_update(u);
+ sco_over_pcm_state_update(u, TRUE);
return PA_HOOK_OK;
}
@@ -1587,17 +1980,15 @@ static pa_hook_result_t source_state_changed_cb(pa_core *c, pa_source *s, struct
if (s != u->hsp.sco_source)
return PA_HOOK_OK;
- sco_over_pcm_state_update(u);
+ sco_over_pcm_state_update(u, TRUE);
return PA_HOOK_OK;
}
-#endif
-
/* Run from main thread */
static int add_sink(struct userdata *u) {
+ char *k;
-#ifdef NOKIA
if (USE_SCO_OVER_PCM(u)) {
pa_proplist *p;
@@ -1610,10 +2001,7 @@ static int add_sink(struct userdata *u) {
if (!u->hsp.sink_state_changed_slot)
u->hsp.sink_state_changed_slot = pa_hook_connect(&u->core->hooks[PA_CORE_HOOK_SINK_STATE_CHANGED], PA_HOOK_NORMAL, (pa_hook_cb_t) sink_state_changed_cb, u);
- } else
-#endif
-
- {
+ } else {
pa_sink_new_data data;
pa_bool_t b;
@@ -1622,6 +2010,8 @@ static int add_sink(struct userdata *u) {
data.module = u->module;
pa_sink_new_data_set_sample_spec(&data, &u->sample_spec);
pa_proplist_sets(data.proplist, "bluetooth.protocol", u->profile == PROFILE_A2DP ? "a2dp" : "sco");
+ if (u->profile == PROFILE_HSP)
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_INTENDED_ROLES, "phone");
data.card = u->card;
data.name = get_name("sink", u->modargs, u->address, &b);
data.namereg_fail = b;
@@ -1652,6 +2042,10 @@ static int add_sink(struct userdata *u) {
if (u->profile == PROFILE_HSP) {
u->sink->set_volume = sink_set_volume_cb;
u->sink->n_volume_steps = 16;
+
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) u->sink);
+ pa_shared_set(u->core, k, u);
+ pa_xfree(k);
}
return 0;
@@ -1659,8 +2053,8 @@ static int add_sink(struct userdata *u) {
/* Run from main thread */
static int add_source(struct userdata *u) {
+ char *k;
-#ifdef NOKIA
if (USE_SCO_OVER_PCM(u)) {
u->source = u->hsp.sco_source;
pa_proplist_sets(u->source->proplist, "bluetooth.protocol", "hsp");
@@ -1668,10 +2062,7 @@ static int add_source(struct userdata *u) {
if (!u->hsp.source_state_changed_slot)
u->hsp.source_state_changed_slot = pa_hook_connect(&u->core->hooks[PA_CORE_HOOK_SOURCE_STATE_CHANGED], PA_HOOK_NORMAL, (pa_hook_cb_t) source_state_changed_cb, u);
- } else
-#endif
-
- {
+ } else {
pa_source_new_data data;
pa_bool_t b;
@@ -1679,7 +2070,10 @@ static int add_source(struct userdata *u) {
data.driver = __FILE__;
data.module = u->module;
pa_source_new_data_set_sample_spec(&data, &u->sample_spec);
- pa_proplist_sets(data.proplist, "bluetooth.protocol", u->profile == PROFILE_A2DP ? "a2dp" : "hsp");
+ pa_proplist_sets(data.proplist, "bluetooth.protocol", u->profile == PROFILE_A2DP_SOURCE ? "a2dp_source" : "hsp");
+ if ((u->profile == PROFILE_HSP) || (u->profile == PROFILE_HFGW))
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_INTENDED_ROLES, "phone");
+
data.card = u->card;
data.name = get_name("source", u->modargs, u->address, &b);
data.namereg_fail = b;
@@ -1702,14 +2096,27 @@ static int add_source(struct userdata *u) {
u->source->parent.process_msg = source_process_msg;
pa_source_set_fixed_latency(u->source,
- (/* u->profile == PROFILE_A2DP ? FIXED_LATENCY_RECORD_A2DP : */ FIXED_LATENCY_RECORD_HSP) +
+ (u->profile == PROFILE_A2DP_SOURCE ? FIXED_LATENCY_RECORD_A2DP : FIXED_LATENCY_RECORD_HSP) +
pa_bytes_to_usec(u->block_size, &u->sample_spec));
}
+ if ((u->profile == PROFILE_HSP) || (u->profile == PROFILE_HFGW)) {
+ if (u->transport) {
+ const pa_bluetooth_transport *t;
+ t = pa_bluetooth_discovery_get_transport(u->discovery, u->transport);
+ pa_assert(t);
+ pa_proplist_sets(u->source->proplist, "bluetooth.nrec", t->nrec ? "1" : "0");
+ } else
+ pa_proplist_sets(u->source->proplist, "bluetooth.nrec", (u->hsp.pcm_capabilities.flags & BT_PCM_FLAG_NREC) ? "1" : "0");
+ }
+
if (u->profile == PROFILE_HSP) {
- pa_proplist_sets(u->source->proplist, "bluetooth.nrec", (u->hsp.pcm_capabilities.flags & BT_PCM_FLAG_NREC) ? "1" : "0");
u->source->set_volume = source_set_volume_cb;
u->source->n_volume_steps = 16;
+
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) u->source);
+ pa_shared_set(u->core, k, u);
+ pa_xfree(k);
}
return 0;
@@ -1729,7 +2136,8 @@ static void shutdown_bt(struct userdata *u) {
if (u->service_fd >= 0) {
pa_close(u->service_fd);
u->service_fd = -1;
- u->service_write_type = u->service_write_type = 0;
+ u->service_write_type = 0;
+ u->service_read_type = 0;
}
if (u->write_memchunk.memblock) {
@@ -1738,6 +2146,144 @@ static void shutdown_bt(struct userdata *u) {
}
}
+static int bt_transport_config_a2dp(struct userdata *u) {
+ const pa_bluetooth_transport *t;
+ struct a2dp_info *a2dp = &u->a2dp;
+ a2dp_sbc_t *config;
+
+ t = pa_bluetooth_discovery_get_transport(u->discovery, u->transport);
+ pa_assert(t);
+
+ config = (a2dp_sbc_t *) t->config;
+
+ u->sample_spec.format = PA_SAMPLE_S16LE;
+
+ if (a2dp->sbc_initialized)
+ sbc_reinit(&a2dp->sbc, 0);
+ else
+ sbc_init(&a2dp->sbc, 0);
+ a2dp->sbc_initialized = TRUE;
+
+ switch (config->frequency) {
+ case BT_SBC_SAMPLING_FREQ_16000:
+ a2dp->sbc.frequency = SBC_FREQ_16000;
+ u->sample_spec.rate = 16000U;
+ break;
+ case BT_SBC_SAMPLING_FREQ_32000:
+ a2dp->sbc.frequency = SBC_FREQ_32000;
+ u->sample_spec.rate = 32000U;
+ break;
+ case BT_SBC_SAMPLING_FREQ_44100:
+ a2dp->sbc.frequency = SBC_FREQ_44100;
+ u->sample_spec.rate = 44100U;
+ break;
+ case BT_SBC_SAMPLING_FREQ_48000:
+ a2dp->sbc.frequency = SBC_FREQ_48000;
+ u->sample_spec.rate = 48000U;
+ break;
+ default:
+ pa_assert_not_reached();
+ }
+
+ switch (config->channel_mode) {
+ case BT_A2DP_CHANNEL_MODE_MONO:
+ a2dp->sbc.mode = SBC_MODE_MONO;
+ u->sample_spec.channels = 1;
+ break;
+ case BT_A2DP_CHANNEL_MODE_DUAL_CHANNEL:
+ a2dp->sbc.mode = SBC_MODE_DUAL_CHANNEL;
+ u->sample_spec.channels = 2;
+ break;
+ case BT_A2DP_CHANNEL_MODE_STEREO:
+ a2dp->sbc.mode = SBC_MODE_STEREO;
+ u->sample_spec.channels = 2;
+ break;
+ case BT_A2DP_CHANNEL_MODE_JOINT_STEREO:
+ a2dp->sbc.mode = SBC_MODE_JOINT_STEREO;
+ u->sample_spec.channels = 2;
+ break;
+ default:
+ pa_assert_not_reached();
+ }
+
+ switch (config->allocation_method) {
+ case BT_A2DP_ALLOCATION_SNR:
+ a2dp->sbc.allocation = SBC_AM_SNR;
+ break;
+ case BT_A2DP_ALLOCATION_LOUDNESS:
+ a2dp->sbc.allocation = SBC_AM_LOUDNESS;
+ break;
+ default:
+ pa_assert_not_reached();
+ }
+
+ switch (config->subbands) {
+ case BT_A2DP_SUBBANDS_4:
+ a2dp->sbc.subbands = SBC_SB_4;
+ break;
+ case BT_A2DP_SUBBANDS_8:
+ a2dp->sbc.subbands = SBC_SB_8;
+ break;
+ default:
+ pa_assert_not_reached();
+ }
+
+ switch (config->block_length) {
+ case BT_A2DP_BLOCK_LENGTH_4:
+ a2dp->sbc.blocks = SBC_BLK_4;
+ break;
+ case BT_A2DP_BLOCK_LENGTH_8:
+ a2dp->sbc.blocks = SBC_BLK_8;
+ break;
+ case BT_A2DP_BLOCK_LENGTH_12:
+ a2dp->sbc.blocks = SBC_BLK_12;
+ break;
+ case BT_A2DP_BLOCK_LENGTH_16:
+ a2dp->sbc.blocks = SBC_BLK_16;
+ break;
+ default:
+ pa_assert_not_reached();
+ }
+
+ a2dp->min_bitpool = config->min_bitpool;
+ a2dp->max_bitpool = config->max_bitpool;
+
+ /* Set minimum bitpool for source to get the maximum possible block_size */
+ a2dp->sbc.bitpool = u->profile == PROFILE_A2DP ? a2dp->max_bitpool : a2dp->min_bitpool;
+ a2dp->codesize = sbc_get_codesize(&a2dp->sbc);
+ a2dp->frame_length = sbc_get_frame_length(&a2dp->sbc);
+
+ u->block_size =
+ ((u->link_mtu - sizeof(struct rtp_header) - sizeof(struct rtp_payload))
+ / a2dp->frame_length
+ * a2dp->codesize);
+
+ pa_log_info("SBC parameters:\n\tallocation=%u\n\tsubbands=%u\n\tblocks=%u\n\tbitpool=%u\n",
+ a2dp->sbc.allocation, a2dp->sbc.subbands, a2dp->sbc.blocks, a2dp->sbc.bitpool);
+
+ return 0;
+}
+
+static int bt_transport_config(struct userdata *u) {
+ if (u->profile == PROFILE_HSP || u->profile == PROFILE_HFGW) {
+ u->block_size = u->link_mtu;
+ u->sample_spec.format = PA_SAMPLE_S16LE;
+ u->sample_spec.channels = 1;
+ u->sample_spec.rate = 8000;
+ return 0;
+ }
+
+ return bt_transport_config_a2dp(u);
+}
+
+/* Run from main thread */
+static int bt_transport_open(struct userdata *u) {
+ if (bt_transport_acquire(u, FALSE) < 0)
+ return -1;
+
+ return bt_transport_config(u);
+}
+
/* Run from main thread */
static int init_bt(struct userdata *u) {
pa_assert(u);
@@ -1745,10 +2291,11 @@ static int init_bt(struct userdata *u) {
shutdown_bt(u);
u->stream_write_type = 0;
- u->service_write_type = u->service_write_type = 0;
+ u->service_write_type = 0;
+ u->service_read_type = 0;
if ((u->service_fd = bt_audio_service_open()) < 0) {
- pa_log_error("Couldn't connect to bluetooth audio service");
+ pa_log_warn("Bluetooth audio service not available");
return -1;
}
@@ -1759,8 +2306,30 @@ static int init_bt(struct userdata *u) {
/* Run from main thread */
static int setup_bt(struct userdata *u) {
+ const pa_bluetooth_device *d;
+ const pa_bluetooth_transport *t;
+
pa_assert(u);
+ if (!(d = pa_bluetooth_discovery_get_by_path(u->discovery, u->path))) {
+ pa_log_error("Failed to get device object.");
+ return -1;
+ }
+
+ /* release transport if exist */
+ if (u->transport) {
+ bt_transport_release(u);
+ pa_xfree(u->transport);
+ u->transport = NULL;
+ }
+
+ /* check if profile has a transport */
+ t = pa_bluetooth_device_get_transport(d, u->profile);
+ if (t) {
+ u->transport = pa_xstrdup(t->path);
+ return bt_transport_open(u);
+ }
+
if (get_caps(u, 0) < 0)
return -1;
@@ -1771,12 +2340,10 @@ static int setup_bt(struct userdata *u) {
pa_log_debug("Connection to the device configured");
-#ifdef NOKIA
if (USE_SCO_OVER_PCM(u)) {
pa_log_debug("Configured to use SCO over PCM");
return 0;
}
-#endif
pa_log_debug("Got the stream socket");
@@ -1793,11 +2360,14 @@ static int init_profile(struct userdata *u) {
return -1;
if (u->profile == PROFILE_A2DP ||
- u->profile == PROFILE_HSP)
+ u->profile == PROFILE_HSP ||
+ u->profile == PROFILE_HFGW)
if (add_sink(u) < 0)
r = -1;
- if (u->profile == PROFILE_HSP)
+ if (u->profile == PROFILE_HSP ||
+ u->profile == PROFILE_A2DP_SOURCE ||
+ u->profile == PROFILE_HFGW)
if (add_source(u) < 0)
r = -1;
@@ -1806,6 +2376,8 @@ static int init_profile(struct userdata *u) {
/* Run from main thread */
static void stop_thread(struct userdata *u) {
+ char *k;
+
pa_assert(u);
if (u->thread) {
@@ -1830,11 +2402,23 @@ static void stop_thread(struct userdata *u) {
}
if (u->sink) {
+ if (u->profile == PROFILE_HSP) {
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) u->sink);
+ pa_shared_remove(u->core, k);
+ pa_xfree(k);
+ }
+
pa_sink_unref(u->sink);
u->sink = NULL;
}
if (u->source) {
+ if (u->profile == PROFILE_HSP) {
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) u->source);
+ pa_shared_remove(u->core, k);
+ pa_xfree(k);
+ }
+
pa_source_unref(u->source);
u->source = NULL;
}
@@ -1862,19 +2446,32 @@ static int start_thread(struct userdata *u) {
u->rtpoll = pa_rtpoll_new();
pa_thread_mq_init(&u->thread_mq, u->core->mainloop, u->rtpoll);
-#ifdef NOKIA
if (USE_SCO_OVER_PCM(u)) {
- if (start_stream_fd(u) < 0)
+ if (sco_over_pcm_state_update(u, FALSE) < 0) {
+ char *k;
+
+ if (u->sink) {
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) u->sink);
+ pa_shared_remove(u->core, k);
+ pa_xfree(k);
+ u->sink = NULL;
+ }
+ if (u->source) {
+ k = pa_sprintf_malloc("bluetooth-device@%p", (void*) u->source);
+ pa_shared_remove(u->core, k);
+ pa_xfree(k);
+ u->source = NULL;
+ }
return -1;
+ }
pa_sink_ref(u->sink);
pa_source_ref(u->source);
/* FIXME: monitor stream_fd error */
return 0;
}
-#endif
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("bluetooth", thread_func, u))) {
pa_log_error("Failed to create IO thread");
stop_thread(u);
return -1;
@@ -1901,6 +2498,22 @@ static int start_thread(struct userdata *u) {
return 0;
}
+static void save_sco_volume_callbacks(struct userdata *u) {
+ pa_assert(u);
+ pa_assert(USE_SCO_OVER_PCM(u));
+
+ u->hsp.sco_sink_set_volume = u->hsp.sco_sink->set_volume;
+ u->hsp.sco_source_set_volume = u->hsp.sco_source->set_volume;
+}
+
+static void restore_sco_volume_callbacks(struct userdata *u) {
+ pa_assert(u);
+ pa_assert(USE_SCO_OVER_PCM(u));
+
+ u->hsp.sco_sink->set_volume = u->hsp.sco_sink_set_volume;
+ u->hsp.sco_source->set_volume = u->hsp.sco_source_set_volume;
+}
+
/* Run from main thread */
static int card_set_profile(pa_card *c, pa_card_profile *new_profile) {
struct userdata *u;
@@ -1916,7 +2529,7 @@ static int card_set_profile(pa_card *c, pa_card_profile *new_profile) {
if (!(device = pa_bluetooth_discovery_get_by_path(u->discovery, u->path))) {
pa_log_error("Failed to get device object.");
- return -1;
+ return -PA_ERR_IO;
}
/* The state signal is sent by bluez, so it is racy to check
@@ -1926,35 +2539,43 @@ static int card_set_profile(pa_card *c, pa_card_profile *new_profile) {
module will be unloaded. */
if (device->headset_state < PA_BT_AUDIO_STATE_CONNECTED && *d == PROFILE_HSP) {
pa_log_warn("HSP is not connected, refused to switch profile");
- return -1;
+ return -PA_ERR_IO;
}
else if (device->audio_sink_state < PA_BT_AUDIO_STATE_CONNECTED && *d == PROFILE_A2DP) {
pa_log_warn("A2DP is not connected, refused to switch profile");
- return -1;
+ return -PA_ERR_IO;
+ }
+ else if (device->hfgw_state <= PA_BT_AUDIO_STATE_CONNECTED && *d == PROFILE_HFGW) {
+ pa_log_warn("HandsfreeGateway is not connected, refused to switch profile");
+ return -PA_ERR_IO;
}
if (u->sink) {
- inputs = pa_sink_move_all_start(u->sink);
-#ifdef NOKIA
+ inputs = pa_sink_move_all_start(u->sink, NULL);
+
if (!USE_SCO_OVER_PCM(u))
-#endif
pa_sink_unlink(u->sink);
}
if (u->source) {
- outputs = pa_source_move_all_start(u->source);
-#ifdef NOKIA
+ outputs = pa_source_move_all_start(u->source, NULL);
+
if (!USE_SCO_OVER_PCM(u))
-#endif
pa_source_unlink(u->source);
}
stop_thread(u);
shutdown_bt(u);
+ if (USE_SCO_OVER_PCM(u))
+ restore_sco_volume_callbacks(u);
+
u->profile = *d;
u->sample_spec = u->requested_sample_spec;
+ if (USE_SCO_OVER_PCM(u))
+ save_sco_volume_callbacks(u);
+
init_bt(u);
if (u->profile != PROFILE_OFF)
@@ -2038,6 +2659,20 @@ static int add_card(struct userdata *u, const pa_bluetooth_device *device) {
pa_hashmap_put(data.profiles, p->name, p);
}
+ if (pa_bluetooth_uuid_has(device->uuids, A2DP_SOURCE_UUID)) {
+ p = pa_card_profile_new("a2dp_source", _("High Fidelity Capture (A2DP)"), sizeof(enum profile));
+ p->priority = 10;
+ p->n_sinks = 0;
+ p->n_sources = 1;
+ p->max_sink_channels = 0;
+ p->max_source_channels = 2;
+
+ d = PA_CARD_PROFILE_DATA(p);
+ *d = PROFILE_A2DP_SOURCE;
+
+ pa_hashmap_put(data.profiles, p->name, p);
+ }
+
if (pa_bluetooth_uuid_has(device->uuids, HSP_HS_UUID) ||
pa_bluetooth_uuid_has(device->uuids, HFP_HS_UUID)) {
p = pa_card_profile_new("hsp", _("Telephony Duplex (HSP/HFP)"), sizeof(enum profile));
@@ -2053,6 +2688,20 @@ static int add_card(struct userdata *u, const pa_bluetooth_device *device) {
pa_hashmap_put(data.profiles, p->name, p);
}
+ if (pa_bluetooth_uuid_has(device->uuids, HFP_AG_UUID)) {
+ p = pa_card_profile_new("hfgw", _("Handsfree Gateway"), sizeof(enum profile));
+ p->priority = 20;
+ p->n_sinks = 1;
+ p->n_sources = 1;
+ p->max_sink_channels = 1;
+ p->max_source_channels = 1;
+
+ d = PA_CARD_PROFILE_DATA(p);
+ *d = PROFILE_HFGW;
+
+ pa_hashmap_put(data.profiles, p->name, p);
+ }
+
pa_assert(!pa_hashmap_isempty(data.profiles));
p = pa_card_profile_new("off", _("Off"), sizeof(enum profile));
@@ -2079,8 +2728,21 @@ static int add_card(struct userdata *u, const pa_bluetooth_device *device) {
u->card->set_profile = card_set_profile;
d = PA_CARD_PROFILE_DATA(u->card->active_profile);
+
+ if ((device->headset_state < PA_BT_AUDIO_STATE_CONNECTED && *d == PROFILE_HSP) ||
+ (device->audio_sink_state < PA_BT_AUDIO_STATE_CONNECTED && *d == PROFILE_A2DP) ||
+ (device->hfgw_state < PA_BT_AUDIO_STATE_CONNECTED && *d == PROFILE_HFGW)) {
+ pa_log_warn("Default profile not connected, selecting off profile");
+ u->card->active_profile = pa_hashmap_get(u->card->profiles, "off");
+ u->card->save_profile = FALSE;
+ }
+
+ d = PA_CARD_PROFILE_DATA(u->card->active_profile);
u->profile = *d;
+ if (USE_SCO_OVER_PCM(u))
+ save_sco_volume_callbacks(u);
+
return 0;
}
@@ -2102,7 +2764,7 @@ static const pa_bluetooth_device* find_device(struct userdata *u, const char *ad
}
if (address && !(pa_streq(d->address, address))) {
- pa_log_error("Passed path %s and address %s don't match.", path, address);
+ pa_log_error("Passed path %s address %s != %s don't match.", path, d->address, address);
return NULL;
}
@@ -2144,7 +2806,7 @@ int pa__init(pa_module* m) {
struct userdata *u;
const char *address, *path;
DBusError err;
- char *mike, *speaker;
+ char *mike, *speaker, *transport;
const pa_bluetooth_device *device;
pa_assert(m);
@@ -2164,7 +2826,6 @@ int pa__init(pa_module* m) {
u->sample_spec = m->core->default_sample_spec;
u->modargs = ma;
-#ifdef NOKIA
if (pa_modargs_get_value(ma, "sco_sink", NULL) &&
!(u->hsp.sco_sink = pa_namereg_get(m->core, pa_modargs_get_value(ma, "sco_sink", NULL), PA_NAMEREG_SINK))) {
pa_log("SCO sink not found");
@@ -2176,7 +2837,6 @@ int pa__init(pa_module* m) {
pa_log("SCO source not found");
goto fail;
}
-#endif
if (pa_modargs_get_value_u32(ma, "rate", &u->sample_spec.rate) < 0 ||
u->sample_spec.rate <= 0 || u->sample_spec.rate > PA_RATE_MAX) {
@@ -2184,6 +2844,12 @@ int pa__init(pa_module* m) {
goto fail;
}
+ u->auto_connect = TRUE;
+ if (pa_modargs_get_value_boolean(ma, "auto_connect", &u->auto_connect)) {
+ pa_log("Failed to parse auto_connect= argument");
+ goto fail;
+ }
+
channels = u->sample_spec.channels;
if (pa_modargs_get_value_u32(ma, "channels", &channels) < 0 ||
channels <= 0 || channels > PA_CHANNELS_MAX) {
@@ -2209,26 +2875,26 @@ int pa__init(pa_module* m) {
if (add_card(u, device) < 0)
goto fail;
- /* Connect to the BT service and query capabilities */
- if (init_bt(u) < 0)
- goto fail;
-
if (!dbus_connection_add_filter(pa_dbus_connection_get(u->connection), filter_cb, u, NULL)) {
pa_log_error("Failed to add filter function");
goto fail;
}
+ u->filter_added = TRUE;
speaker = pa_sprintf_malloc("type='signal',sender='org.bluez',interface='org.bluez.Headset',member='SpeakerGainChanged',path='%s'", u->path);
mike = pa_sprintf_malloc("type='signal',sender='org.bluez',interface='org.bluez.Headset',member='MicrophoneGainChanged',path='%s'", u->path);
+ transport = pa_sprintf_malloc("type='signal',sender='org.bluez',interface='org.bluez.MediaTransport',member='PropertyChanged'");
if (pa_dbus_add_matches(
pa_dbus_connection_get(u->connection), &err,
speaker,
mike,
+ transport,
NULL) < 0) {
pa_xfree(speaker);
pa_xfree(mike);
+ pa_xfree(transport);
pa_log("Failed to add D-Bus matches: %s", err.message);
goto fail;
@@ -2236,6 +2902,10 @@ int pa__init(pa_module* m) {
pa_xfree(speaker);
pa_xfree(mike);
+ pa_xfree(transport);
+
+ /* Connect to the BT service */
+ init_bt(u);
if (u->profile != PROFILE_OFF)
if (init_profile(u) < 0)
@@ -2269,27 +2939,23 @@ int pa__get_n_used(pa_module *m) {
void pa__done(pa_module *m) {
struct userdata *u;
+
pa_assert(m);
if (!(u = m->userdata))
return;
- if (u->sink
-#ifdef NOKIA
- && !USE_SCO_OVER_PCM(u)
-#endif
- )
+ if (u->sink && !USE_SCO_OVER_PCM(u))
pa_sink_unlink(u->sink);
- if (u->source
-#ifdef NOKIA
- && !USE_SCO_OVER_PCM(u)
-#endif
- )
+ if (u->source && !USE_SCO_OVER_PCM(u))
pa_source_unlink(u->source);
stop_thread(u);
+ if (USE_SCO_OVER_PCM(u))
+ restore_sco_volume_callbacks(u);
+
if (u->connection) {
if (u->path) {
@@ -2297,16 +2963,15 @@ void pa__done(pa_module *m) {
speaker = pa_sprintf_malloc("type='signal',sender='org.bluez',interface='org.bluez.Headset',member='SpeakerGainChanged',path='%s'", u->path);
mike = pa_sprintf_malloc("type='signal',sender='org.bluez',interface='org.bluez.Headset',member='MicrophoneGainChanged',path='%s'", u->path);
- pa_dbus_remove_matches(pa_dbus_connection_get(u->connection),
- speaker,
- mike,
- NULL);
+ pa_dbus_remove_matches(pa_dbus_connection_get(u->connection), speaker, mike, NULL);
pa_xfree(speaker);
pa_xfree(mike);
}
- dbus_connection_remove_filter(pa_dbus_connection_get(u->connection), filter_cb, u);
+ if (u->filter_added)
+ dbus_connection_remove_filter(pa_dbus_connection_get(u->connection), filter_cb, u);
+
pa_dbus_connection_unref(u->connection);
}
@@ -2329,6 +2994,11 @@ void pa__done(pa_module *m) {
pa_xfree(u->address);
pa_xfree(u->path);
+ if (u->transport) {
+ bt_transport_release(u);
+ pa_xfree(u->transport);
+ }
+
if (u->discovery)
pa_bluetooth_discovery_unref(u->discovery);
diff --git a/src/modules/bluetooth/module-bluetooth-discover.c b/src/modules/bluetooth/module-bluetooth-discover.c
index 788fee00..7b27f6bb 100644
--- a/src/modules/bluetooth/module-bluetooth-discover.c
+++ b/src/modules/bluetooth/module-bluetooth-discover.c
@@ -1,7 +1,7 @@
/***
This file is part of PulseAudio.
- Copyright 2008 Joao Paulo Rechi Vita
+ Copyright 2008-2009 Joao Paulo Rechi Vita
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as
@@ -25,14 +25,12 @@
#include <stdio.h>
#include <stdlib.h>
-#include <string.h>
#include <pulse/xmalloc.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
#include <pulsecore/macro.h>
-#include <pulsecore/llist.h>
#include <pulsecore/core-util.h>
#include <pulsecore/dbus-shared.h>
@@ -42,21 +40,14 @@
PA_MODULE_AUTHOR("Joao Paulo Rechi Vita");
PA_MODULE_DESCRIPTION("Detect available bluetooth audio devices and load bluetooth audio drivers");
PA_MODULE_VERSION(PACKAGE_VERSION);
-PA_MODULE_USAGE("async=<Asynchronous initialization?>");
+PA_MODULE_USAGE("async=<Asynchronous initialization?> "
+ "sco_sink=<name of sink> "
+ "sco_source=<name of source> ");
PA_MODULE_LOAD_ONCE(TRUE);
-/*
-#ifdef NOKIA
- "sco_sink=<name of sink> "
- "sco_source=<name of source>"
-#endif
-*/
-
static const char* const valid_modargs[] = {
-#ifdef NOKIA
"sco_sink",
"sco_source",
-#endif
"async",
NULL
};
@@ -83,8 +74,10 @@ static pa_hook_result_t load_module_for_device(pa_bluetooth_discovery *y, const
mi = pa_hashmap_get(u->hashmap, d->path);
- if (!d->dead &&
- d->device_connected > 0 && d->audio_state >= PA_BT_AUDIO_STATE_CONNECTED) {
+ if (!d->dead && d->device_connected > 0 &&
+ (d->audio_state >= PA_BT_AUDIO_STATE_CONNECTED ||
+ d->audio_source_state >= PA_BT_AUDIO_STATE_CONNECTED ||
+ d->hfgw_state > PA_BT_AUDIO_STATE_CONNECTED)) {
if (!mi) {
pa_module *m = NULL;
@@ -103,7 +96,6 @@ static pa_hook_result_t load_module_for_device(pa_bluetooth_discovery *y, const
}
#endif
-#ifdef NOKIA
if (pa_modargs_get_value(u->modargs, "sco_sink", NULL) &&
pa_modargs_get_value(u->modargs, "sco_source", NULL)) {
char *tmp;
@@ -114,7 +106,12 @@ static pa_hook_result_t load_module_for_device(pa_bluetooth_discovery *y, const
pa_xfree(args);
args = tmp;
}
-#endif
+
+ if (d->audio_source_state >= PA_BT_AUDIO_STATE_CONNECTED)
+ args = pa_sprintf_malloc("%s profile=\"a2dp_source\" auto_connect=no", args);
+
+ if (d->hfgw_state > PA_BT_AUDIO_STATE_CONNECTED)
+ args = pa_sprintf_malloc("%s profile=\"hfgw\"", args);
pa_log_debug("Loading module-bluetooth-device %s", args);
m = pa_module_load(u->module->core, "module-bluetooth-device", args);
diff --git a/src/modules/bluetooth/module-bluetooth-proximity.c b/src/modules/bluetooth/module-bluetooth-proximity.c
index 9993c8dc..8c3a5b9f 100644
--- a/src/modules/bluetooth/module-bluetooth-proximity.c
+++ b/src/modules/bluetooth/module-bluetooth-proximity.c
@@ -59,7 +59,6 @@ PA_MODULE_USAGE(
static const char* const valid_modargs[] = {
"sink",
- "rssi",
"hci",
NULL,
};
@@ -92,7 +91,8 @@ struct userdata {
unsigned n_found;
unsigned n_unknown;
- pa_bool_t muted;
+ pa_bool_t muted:1;
+ pa_bool_t filter_added:1;
};
static void update_volume(struct userdata *u) {
@@ -109,7 +109,7 @@ static void update_volume(struct userdata *u) {
}
pa_log_info("Found %u BT devices, unmuting.", u->n_found);
- pa_sink_set_mute(s, FALSE);
+ pa_sink_set_mute(s, FALSE, FALSE);
} else if (!u->muted && (u->n_found+u->n_unknown) <= 0) {
pa_sink *s;
@@ -122,7 +122,7 @@ static void update_volume(struct userdata *u) {
}
pa_log_info("No BT devices found, muting.");
- pa_sink_set_mute(s, TRUE);
+ pa_sink_set_mute(s, TRUE, FALSE);
} else
pa_log_info("%u devices now active, %u with unknown state.", u->n_found, u->n_unknown);
@@ -358,9 +358,10 @@ static int add_matches(struct userdata *u, pa_bool_t add) {
} else
dbus_bus_remove_match(pa_dbus_connection_get(u->dbus_connection), filter2, &e);
- if (add)
+ if (add) {
pa_assert_se(dbus_connection_add_filter(pa_dbus_connection_get(u->dbus_connection), filter_func, u, NULL));
- else
+ u->filter_added = TRUE;
+ } else if (u->filter_added)
dbus_connection_remove_filter(pa_dbus_connection_get(u->dbus_connection), filter_func, u);
r = 0;
@@ -393,9 +394,6 @@ int pa__init(pa_module*m) {
u->sink_name = pa_xstrdup(pa_modargs_get_value(ma, "sink", NULL));
u->hci = pa_xstrdup(pa_modargs_get_value(ma, "hci", DEFAULT_HCI));
u->hci_path = pa_sprintf_malloc("/org/bluez/%s", u->hci);
- u->n_found = u->n_unknown = 0;
- u->muted = FALSE;
-
u->bondings = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
if (!(u->dbus_connection = pa_dbus_bus_get(m->core, DBUS_BUS_SYSTEM, &e))) {
diff --git a/src/modules/bluetooth/rtp.h b/src/modules/bluetooth/rtp.h
index 14573628..45fddcf1 100644
--- a/src/modules/bluetooth/rtp.h
+++ b/src/modules/bluetooth/rtp.h
@@ -2,7 +2,7 @@
*
* BlueZ - Bluetooth protocol stack for Linux
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
*
*
* This library is free software; you can redistribute it and/or
diff --git a/src/modules/bluetooth/sbc.c b/src/modules/bluetooth/sbc/sbc.c
index 779be4bd..77fcc5d1 100644
--- a/src/modules/bluetooth/sbc.c
+++ b/src/modules/bluetooth/sbc/sbc.c
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2008 Brad Midgley <bmidgley@xmission.com>
*
@@ -77,7 +78,7 @@ struct sbc_frame {
uint8_t joint;
/* only the lower 4 bits of every element are to be used */
- uint32_t scale_factor[2][8];
+ uint32_t SBC_ALIGNED scale_factor[2][8];
/* raw integer subband samples in the frame */
int32_t SBC_ALIGNED sb_sample_f[16][2][8];
@@ -159,7 +160,8 @@ static uint8_t sbc_crc8(const uint8_t *data, size_t len)
* Takes a pointer to the frame in question, a pointer to the bits array and
* the sampling frequency (as 2 bit integer)
*/
-static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
+static SBC_ALWAYS_INLINE void sbc_calculate_bits_internal(
+ const struct sbc_frame *frame, int (*bits)[8], int subbands)
{
uint8_t sf = frame->frequency;
@@ -170,17 +172,17 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
for (ch = 0; ch < frame->channels; ch++) {
max_bitneed = 0;
if (frame->allocation == SNR) {
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
bitneed[ch][sb] = frame->scale_factor[ch][sb];
if (bitneed[ch][sb] > max_bitneed)
max_bitneed = bitneed[ch][sb];
}
} else {
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
if (frame->scale_factor[ch][sb] == 0)
bitneed[ch][sb] = -5;
else {
- if (frame->subbands == 4)
+ if (subbands == 4)
loudness = frame->scale_factor[ch][sb] - sbc_offset4[sf][sb];
else
loudness = frame->scale_factor[ch][sb] - sbc_offset8[sf][sb];
@@ -201,7 +203,7 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
bitslice--;
bitcount += slicecount;
slicecount = 0;
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
if ((bitneed[ch][sb] > bitslice + 1) && (bitneed[ch][sb] < bitslice + 16))
slicecount++;
else if (bitneed[ch][sb] == bitslice + 1)
@@ -214,7 +216,7 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
bitslice--;
}
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
if (bitneed[ch][sb] < bitslice + 2)
bits[ch][sb] = 0;
else {
@@ -224,7 +226,8 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
}
}
- for (sb = 0; bitcount < frame->bitpool && sb < frame->subbands; sb++) {
+ for (sb = 0; bitcount < frame->bitpool &&
+ sb < subbands; sb++) {
if ((bits[ch][sb] >= 2) && (bits[ch][sb] < 16)) {
bits[ch][sb]++;
bitcount++;
@@ -234,7 +237,8 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
}
}
- for (sb = 0; bitcount < frame->bitpool && sb < frame->subbands; sb++) {
+ for (sb = 0; bitcount < frame->bitpool &&
+ sb < subbands; sb++) {
if (bits[ch][sb] < 16) {
bits[ch][sb]++;
bitcount++;
@@ -250,7 +254,7 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
max_bitneed = 0;
if (frame->allocation == SNR) {
for (ch = 0; ch < 2; ch++) {
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
bitneed[ch][sb] = frame->scale_factor[ch][sb];
if (bitneed[ch][sb] > max_bitneed)
max_bitneed = bitneed[ch][sb];
@@ -258,11 +262,11 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
}
} else {
for (ch = 0; ch < 2; ch++) {
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
if (frame->scale_factor[ch][sb] == 0)
bitneed[ch][sb] = -5;
else {
- if (frame->subbands == 4)
+ if (subbands == 4)
loudness = frame->scale_factor[ch][sb] - sbc_offset4[sf][sb];
else
loudness = frame->scale_factor[ch][sb] - sbc_offset8[sf][sb];
@@ -285,7 +289,7 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
bitcount += slicecount;
slicecount = 0;
for (ch = 0; ch < 2; ch++) {
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
if ((bitneed[ch][sb] > bitslice + 1) && (bitneed[ch][sb] < bitslice + 16))
slicecount++;
else if (bitneed[ch][sb] == bitslice + 1)
@@ -300,7 +304,7 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
}
for (ch = 0; ch < 2; ch++) {
- for (sb = 0; sb < frame->subbands; sb++) {
+ for (sb = 0; sb < subbands; sb++) {
if (bitneed[ch][sb] < bitslice + 2) {
bits[ch][sb] = 0;
} else {
@@ -324,7 +328,8 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
if (ch == 1) {
ch = 0;
sb++;
- if (sb >= frame->subbands) break;
+ if (sb >= subbands)
+ break;
} else
ch = 1;
}
@@ -339,7 +344,8 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
if (ch == 1) {
ch = 0;
sb++;
- if (sb >= frame->subbands) break;
+ if (sb >= subbands)
+ break;
} else
ch = 1;
}
@@ -348,6 +354,14 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
}
+static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
+{
+ if (frame->subbands == 4)
+ sbc_calculate_bits_internal(frame, bits, 4);
+ else
+ sbc_calculate_bits_internal(frame, bits, 8);
+}
+
/*
* Unpacks a SBC frame at the beginning of the stream in data,
* which has at most len bytes into frame.
@@ -360,7 +374,7 @@ static void sbc_calculate_bits(const struct sbc_frame *frame, int (*bits)[8])
* -4 Bitpool value out of bounds
*/
static int sbc_unpack_frame(const uint8_t *data, struct sbc_frame *frame,
- size_t len)
+ size_t len)
{
unsigned int consumed;
/* Will copy the parts of the header that are relevant to crc
@@ -522,7 +536,7 @@ static int sbc_unpack_frame(const uint8_t *data, struct sbc_frame *frame,
}
static void sbc_decoder_init(struct sbc_decoder_state *state,
- const struct sbc_frame *frame)
+ const struct sbc_frame *frame)
{
int i, ch;
@@ -534,6 +548,16 @@ static void sbc_decoder_init(struct sbc_decoder_state *state,
state->offset[ch][i] = (10 * i + 10);
}
+static SBC_ALWAYS_INLINE int16_t sbc_clip16(int32_t s)
+{
+ if (s > 0x7FFF)
+ return 0x7FFF;
+ else if (s < -0x8000)
+ return -0x8000;
+ else
+ return s;
+}
+
static inline void sbc_synthesize_four(struct sbc_decoder_state *state,
struct sbc_frame *frame, int ch, int blk)
{
@@ -562,7 +586,7 @@ static inline void sbc_synthesize_four(struct sbc_decoder_state *state,
k = (i + 4) & 0xf;
/* Store in output, Q0 */
- frame->pcm_sample[ch][blk * 4 + i] = SCALE4_STAGED1(
+ frame->pcm_sample[ch][blk * 4 + i] = sbc_clip16(SCALE4_STAGED1(
MULA(v[offset[i] + 0], sbc_proto_4_40m0[idx + 0],
MULA(v[offset[k] + 1], sbc_proto_4_40m1[idx + 0],
MULA(v[offset[i] + 2], sbc_proto_4_40m0[idx + 1],
@@ -572,7 +596,7 @@ static inline void sbc_synthesize_four(struct sbc_decoder_state *state,
MULA(v[offset[i] + 6], sbc_proto_4_40m0[idx + 3],
MULA(v[offset[k] + 7], sbc_proto_4_40m1[idx + 3],
MULA(v[offset[i] + 8], sbc_proto_4_40m0[idx + 4],
- MUL( v[offset[k] + 9], sbc_proto_4_40m1[idx + 4])))))))))));
+ MUL( v[offset[k] + 9], sbc_proto_4_40m1[idx + 4]))))))))))));
}
}
@@ -607,8 +631,8 @@ static inline void sbc_synthesize_eight(struct sbc_decoder_state *state,
for (idx = 0, i = 0; i < 8; i++, idx += 5) {
k = (i + 8) & 0xf;
- /* Store in output */
- frame->pcm_sample[ch][blk * 8 + i] = SCALE8_STAGED1( // Q0
+ /* Store in output, Q0 */
+ frame->pcm_sample[ch][blk * 8 + i] = sbc_clip16(SCALE8_STAGED1(
MULA(state->V[ch][offset[i] + 0], sbc_proto_8_80m0[idx + 0],
MULA(state->V[ch][offset[k] + 1], sbc_proto_8_80m1[idx + 0],
MULA(state->V[ch][offset[i] + 2], sbc_proto_8_80m0[idx + 1],
@@ -618,12 +642,12 @@ static inline void sbc_synthesize_eight(struct sbc_decoder_state *state,
MULA(state->V[ch][offset[i] + 6], sbc_proto_8_80m0[idx + 3],
MULA(state->V[ch][offset[k] + 7], sbc_proto_8_80m1[idx + 3],
MULA(state->V[ch][offset[i] + 8], sbc_proto_8_80m0[idx + 4],
- MUL( state->V[ch][offset[k] + 9], sbc_proto_8_80m1[idx + 4])))))))))));
+ MUL( state->V[ch][offset[k] + 9], sbc_proto_8_80m1[idx + 4]))))))))))));
}
}
static int sbc_synthesize_audio(struct sbc_decoder_state *state,
- struct sbc_frame *frame)
+ struct sbc_frame *frame)
{
int ch, blk;
@@ -648,7 +672,7 @@ static int sbc_synthesize_audio(struct sbc_decoder_state *state,
}
static int sbc_analyze_audio(struct sbc_encoder_state *state,
- struct sbc_frame *frame)
+ struct sbc_frame *frame)
{
int ch, blk;
int16_t *x;
@@ -732,9 +756,10 @@ static int sbc_analyze_audio(struct sbc_encoder_state *state,
* -99 not implemented
*/
-static SBC_ALWAYS_INLINE int sbc_pack_frame_internal(
- uint8_t *data, struct sbc_frame *frame, size_t len,
- int frame_subbands, int frame_channels)
+static SBC_ALWAYS_INLINE ssize_t sbc_pack_frame_internal(uint8_t *data,
+ struct sbc_frame *frame, size_t len,
+ int frame_subbands, int frame_channels,
+ int joint)
{
/* Bitstream writer starts from the fourth byte */
uint8_t *data_ptr = data + 4;
@@ -791,63 +816,6 @@ static SBC_ALWAYS_INLINE int sbc_pack_frame_internal(
crc_pos = 16;
if (frame->mode == JOINT_STEREO) {
- /* like frame->sb_sample but joint stereo */
- int32_t sb_sample_j[16][2];
- /* scalefactor and scale_factor in joint case */
- uint32_t scalefactor_j[2];
- uint8_t scale_factor_j[2];
-
- uint8_t joint = 0;
- frame->joint = 0;
-
- for (sb = 0; sb < frame_subbands - 1; sb++) {
- scale_factor_j[0] = 0;
- scalefactor_j[0] = 2 << SCALE_OUT_BITS;
- scale_factor_j[1] = 0;
- scalefactor_j[1] = 2 << SCALE_OUT_BITS;
-
- for (blk = 0; blk < frame->blocks; blk++) {
- uint32_t tmp;
- /* Calculate joint stereo signal */
- sb_sample_j[blk][0] =
- ASR(frame->sb_sample_f[blk][0][sb], 1) +
- ASR(frame->sb_sample_f[blk][1][sb], 1);
- sb_sample_j[blk][1] =
- ASR(frame->sb_sample_f[blk][0][sb], 1) -
- ASR(frame->sb_sample_f[blk][1][sb], 1);
-
- /* calculate scale_factor_j and scalefactor_j for joint case */
- tmp = fabs(sb_sample_j[blk][0]);
- while (scalefactor_j[0] < tmp) {
- scale_factor_j[0]++;
- scalefactor_j[0] *= 2;
- }
- tmp = fabs(sb_sample_j[blk][1]);
- while (scalefactor_j[1] < tmp) {
- scale_factor_j[1]++;
- scalefactor_j[1] *= 2;
- }
- }
-
- /* decide whether to join this subband */
- if ((frame->scale_factor[0][sb] +
- frame->scale_factor[1][sb]) >
- (scale_factor_j[0] +
- scale_factor_j[1])) {
- /* use joint stereo for this subband */
- joint |= 1 << (frame_subbands - 1 - sb);
- frame->joint |= 1 << sb;
- frame->scale_factor[0][sb] = scale_factor_j[0];
- frame->scale_factor[1][sb] = scale_factor_j[1];
- for (blk = 0; blk < frame->blocks; blk++) {
- frame->sb_sample_f[blk][0][sb] =
- sb_sample_j[blk][0];
- frame->sb_sample_f[blk][1][sb] =
- sb_sample_j[blk][1];
- }
- }
- }
-
PUT_BITS(data_ptr, bits_cache, bits_count,
joint, frame_subbands);
crc_header[crc_pos >> 3] = joint;
@@ -905,26 +873,31 @@ static SBC_ALWAYS_INLINE int sbc_pack_frame_internal(
return data_ptr - data;
}
-static int sbc_pack_frame(uint8_t *data, struct sbc_frame *frame, size_t len)
+static ssize_t sbc_pack_frame(uint8_t *data, struct sbc_frame *frame, size_t len,
+ int joint)
{
if (frame->subbands == 4) {
if (frame->channels == 1)
- return sbc_pack_frame_internal(data, frame, len, 4, 1);
+ return sbc_pack_frame_internal(
+ data, frame, len, 4, 1, joint);
else
- return sbc_pack_frame_internal(data, frame, len, 4, 2);
+ return sbc_pack_frame_internal(
+ data, frame, len, 4, 2, joint);
} else {
if (frame->channels == 1)
- return sbc_pack_frame_internal(data, frame, len, 8, 1);
+ return sbc_pack_frame_internal(
+ data, frame, len, 8, 1, joint);
else
- return sbc_pack_frame_internal(data, frame, len, 8, 2);
+ return sbc_pack_frame_internal(
+ data, frame, len, 8, 2, joint);
}
}
static void sbc_encoder_init(struct sbc_encoder_state *state,
- const struct sbc_frame *frame)
+ const struct sbc_frame *frame)
{
memset(&state->X, 0, sizeof(state->X));
- state->position = SBC_X_BUFFER_SIZE - frame->subbands * 9;
+ state->position = (SBC_X_BUFFER_SIZE - frame->subbands * 9) & ~7;
sbc_init_primitives(state);
}
@@ -1005,6 +978,9 @@ ssize_t sbc_decode(sbc_t *sbc, const void *input, size_t input_len,
priv->frame.codesize = sbc_get_codesize(sbc);
priv->frame.length = framelen;
+ } else if (priv->frame.bitpool != sbc->bitpool) {
+ priv->frame.length = framelen;
+ sbc->bitpool = priv->frame.bitpool;
}
if (!output)
@@ -1045,10 +1021,11 @@ ssize_t sbc_decode(sbc_t *sbc, const void *input, size_t input_len,
}
ssize_t sbc_encode(sbc_t *sbc, const void *input, size_t input_len,
- void *output, size_t output_len, size_t *written)
+ void *output, size_t output_len, ssize_t *written)
{
struct sbc_priv *priv;
- int framelen, samples;
+ int samples;
+ ssize_t framelen;
int (*sbc_enc_process_input)(int position,
const uint8_t *pcm, int16_t X[2][SBC_X_BUFFER_SIZE],
int nsamples, int nchannels);
@@ -1076,6 +1053,9 @@ ssize_t sbc_encode(sbc_t *sbc, const void *input, size_t input_len,
sbc_encoder_init(&priv->enc_state, &priv->frame);
priv->init = 1;
+ } else if (priv->frame.bitpool != sbc->bitpool) {
+ priv->frame.length = sbc_get_frame_length(sbc);
+ priv->frame.bitpool = sbc->bitpool;
}
/* input must be large enough to encode a complete frame */
@@ -1110,11 +1090,18 @@ ssize_t sbc_encode(sbc_t *sbc, const void *input, size_t input_len,
samples = sbc_analyze_audio(&priv->enc_state, &priv->frame);
- priv->enc_state.sbc_calc_scalefactors(
- priv->frame.sb_sample_f, priv->frame.scale_factor,
- priv->frame.blocks, priv->frame.channels, priv->frame.subbands);
-
- framelen = sbc_pack_frame(output, &priv->frame, output_len);
+ if (priv->frame.mode == JOINT_STEREO) {
+ int j = priv->enc_state.sbc_calc_scalefactors_j(
+ priv->frame.sb_sample_f, priv->frame.scale_factor,
+ priv->frame.blocks, priv->frame.subbands);
+ framelen = sbc_pack_frame(output, &priv->frame, output_len, j);
+ } else {
+ priv->enc_state.sbc_calc_scalefactors(
+ priv->frame.sb_sample_f, priv->frame.scale_factor,
+ priv->frame.blocks, priv->frame.channels,
+ priv->frame.subbands);
+ framelen = sbc_pack_frame(output, &priv->frame, output_len, 0);
+ }
if (written)
*written = framelen;
@@ -1127,20 +1114,19 @@ void sbc_finish(sbc_t *sbc)
if (!sbc)
return;
- if (sbc->priv_alloc_base)
- free(sbc->priv_alloc_base);
+ free(sbc->priv_alloc_base);
memset(sbc, 0, sizeof(sbc_t));
}
size_t sbc_get_frame_length(sbc_t *sbc)
{
- size_t ret;
+ int ret;
uint8_t subbands, channels, blocks, joint, bitpool;
struct sbc_priv *priv;
priv = sbc->priv;
- if (priv->init)
+ if (priv->init && priv->frame.bitpool == sbc->bitpool)
return priv->frame.length;
subbands = sbc->subbands ? 8 : 4;
diff --git a/src/modules/bluetooth/sbc.h b/src/modules/bluetooth/sbc/sbc.h
index 65435884..2f830ad5 100644
--- a/src/modules/bluetooth/sbc.h
+++ b/src/modules/bluetooth/sbc/sbc.h
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
*
@@ -85,12 +86,13 @@ int sbc_reinit(sbc_t *sbc, unsigned long flags);
ssize_t sbc_parse(sbc_t *sbc, const void *input, size_t input_len);
+/* Decodes ONE input block into ONE output block */
ssize_t sbc_decode(sbc_t *sbc, const void *input, size_t input_len,
void *output, size_t output_len, size_t *written);
/* Encodes ONE input block into ONE output block */
ssize_t sbc_encode(sbc_t *sbc, const void *input, size_t input_len,
- void *output, size_t output_len, size_t *written);
+ void *output, size_t output_len, ssize_t *written);
/* Returns the output block size in bytes */
size_t sbc_get_frame_length(sbc_t *sbc);
diff --git a/src/modules/bluetooth/sbc_math.h b/src/modules/bluetooth/sbc/sbc_math.h
index b87bc81c..5476860d 100644
--- a/src/modules/bluetooth/sbc_math.h
+++ b/src/modules/bluetooth/sbc/sbc_math.h
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2008 Brad Midgley <bmidgley@xmission.com>
*
@@ -47,7 +48,7 @@ typedef int32_t sbc_fixed_t;
#define SBC_FIXED_0(val) { val = 0; }
#define MUL(a, b) ((a) * (b))
-#ifdef __arm__
+#if defined(__arm__) && (!defined(__thumb__) || defined(__thumb2__))
#define MULA(a, b, res) ({ \
int tmp = res; \
__asm__( \
diff --git a/src/modules/bluetooth/sbc_primitives.c b/src/modules/bluetooth/sbc/sbc_primitives.c
index 6b0be3f5..ad780d08 100644
--- a/src/modules/bluetooth/sbc_primitives.c
+++ b/src/modules/bluetooth/sbc/sbc_primitives.c
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
*
@@ -32,7 +33,9 @@
#include "sbc_primitives.h"
#include "sbc_primitives_mmx.h"
+#include "sbc_primitives_iwmmxt.h"
#include "sbc_primitives_neon.h"
+#include "sbc_primitives_armv6.h"
/*
* A reference C code of analysis filter with SIMD-friendly tables
@@ -231,12 +234,12 @@ static SBC_ALWAYS_INLINE int sbc_encoder_process_input_s4_internal(
/* handle X buffer wraparound */
if (position < nsamples) {
if (nchannels > 0)
- memcpy(&X[0][SBC_X_BUFFER_SIZE - 36], &X[0][position],
+ memcpy(&X[0][SBC_X_BUFFER_SIZE - 40], &X[0][position],
36 * sizeof(int16_t));
if (nchannels > 1)
- memcpy(&X[1][SBC_X_BUFFER_SIZE - 36], &X[1][position],
+ memcpy(&X[1][SBC_X_BUFFER_SIZE - 40], &X[1][position],
36 * sizeof(int16_t));
- position = SBC_X_BUFFER_SIZE - 36;
+ position = SBC_X_BUFFER_SIZE - 40;
}
#define PCM(i) (big_endian ? \
@@ -439,6 +442,80 @@ static void sbc_calc_scalefactors(
}
}
+static int sbc_calc_scalefactors_j(
+ int32_t sb_sample_f[16][2][8],
+ uint32_t scale_factor[2][8],
+ int blocks, int subbands)
+{
+ int blk, joint = 0;
+ int32_t tmp0, tmp1;
+ uint32_t x, y;
+
+ /* last subband does not use joint stereo */
+ int sb = subbands - 1;
+ x = 1 << SCALE_OUT_BITS;
+ y = 1 << SCALE_OUT_BITS;
+ for (blk = 0; blk < blocks; blk++) {
+ tmp0 = fabs(sb_sample_f[blk][0][sb]);
+ tmp1 = fabs(sb_sample_f[blk][1][sb]);
+ if (tmp0 != 0)
+ x |= tmp0 - 1;
+ if (tmp1 != 0)
+ y |= tmp1 - 1;
+ }
+ scale_factor[0][sb] = (31 - SCALE_OUT_BITS) - sbc_clz(x);
+ scale_factor[1][sb] = (31 - SCALE_OUT_BITS) - sbc_clz(y);
+
+ /* the rest of subbands can use joint stereo */
+ while (--sb >= 0) {
+ int32_t sb_sample_j[16][2];
+ x = 1 << SCALE_OUT_BITS;
+ y = 1 << SCALE_OUT_BITS;
+ for (blk = 0; blk < blocks; blk++) {
+ tmp0 = sb_sample_f[blk][0][sb];
+ tmp1 = sb_sample_f[blk][1][sb];
+ sb_sample_j[blk][0] = ASR(tmp0, 1) + ASR(tmp1, 1);
+ sb_sample_j[blk][1] = ASR(tmp0, 1) - ASR(tmp1, 1);
+ tmp0 = fabs(tmp0);
+ tmp1 = fabs(tmp1);
+ if (tmp0 != 0)
+ x |= tmp0 - 1;
+ if (tmp1 != 0)
+ y |= tmp1 - 1;
+ }
+ scale_factor[0][sb] = (31 - SCALE_OUT_BITS) -
+ sbc_clz(x);
+ scale_factor[1][sb] = (31 - SCALE_OUT_BITS) -
+ sbc_clz(y);
+ x = 1 << SCALE_OUT_BITS;
+ y = 1 << SCALE_OUT_BITS;
+ for (blk = 0; blk < blocks; blk++) {
+ tmp0 = fabs(sb_sample_j[blk][0]);
+ tmp1 = fabs(sb_sample_j[blk][1]);
+ if (tmp0 != 0)
+ x |= tmp0 - 1;
+ if (tmp1 != 0)
+ y |= tmp1 - 1;
+ }
+ x = (31 - SCALE_OUT_BITS) - sbc_clz(x);
+ y = (31 - SCALE_OUT_BITS) - sbc_clz(y);
+
+ /* decide whether to use joint stereo for this subband */
+ if ((scale_factor[0][sb] + scale_factor[1][sb]) > x + y) {
+ joint |= 1 << (subbands - 1 - sb);
+ scale_factor[0][sb] = x;
+ scale_factor[1][sb] = y;
+ for (blk = 0; blk < blocks; blk++) {
+ sb_sample_f[blk][0][sb] = sb_sample_j[blk][0];
+ sb_sample_f[blk][1][sb] = sb_sample_j[blk][1];
+ }
+ }
+ }
+
+ /* bitmask with the information about subbands using joint stereo */
+ return joint;
+}
+
/*
* Detect CPU features and setup function pointers
*/
@@ -456,6 +533,7 @@ void sbc_init_primitives(struct sbc_encoder_state *state)
/* Default implementation for scale factors calculation */
state->sbc_calc_scalefactors = sbc_calc_scalefactors;
+ state->sbc_calc_scalefactors_j = sbc_calc_scalefactors_j;
state->implementation_info = "Generic C";
/* X86/AMD64 optimizations */
@@ -464,6 +542,12 @@ void sbc_init_primitives(struct sbc_encoder_state *state)
#endif
/* ARM optimizations */
+#ifdef SBC_BUILD_WITH_ARMV6_SUPPORT
+ sbc_init_primitives_armv6(state);
+#endif
+#ifdef SBC_BUILD_WITH_IWMMXT_SUPPORT
+ sbc_init_primitives_iwmmxt(state);
+#endif
#ifdef SBC_BUILD_WITH_NEON_SUPPORT
sbc_init_primitives_neon(state);
#endif
diff --git a/src/modules/bluetooth/sbc_primitives.h b/src/modules/bluetooth/sbc/sbc_primitives.h
index 3d01c115..3fec8d5b 100644
--- a/src/modules/bluetooth/sbc_primitives.h
+++ b/src/modules/bluetooth/sbc/sbc_primitives.h
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
*
@@ -62,6 +63,10 @@ struct sbc_encoder_state {
void (*sbc_calc_scalefactors)(int32_t sb_sample_f[16][2][8],
uint32_t scale_factor[2][8],
int blocks, int channels, int subbands);
+ /* Scale factors calculation with joint stereo support */
+ int (*sbc_calc_scalefactors_j)(int32_t sb_sample_f[16][2][8],
+ uint32_t scale_factor[2][8],
+ int blocks, int subbands);
const char *implementation_info;
};
diff --git a/src/modules/bluetooth/sbc/sbc_primitives_armv6.c b/src/modules/bluetooth/sbc/sbc_primitives_armv6.c
new file mode 100644
index 00000000..95860980
--- /dev/null
+++ b/src/modules/bluetooth/sbc/sbc_primitives_armv6.c
@@ -0,0 +1,299 @@
+/*
+ *
+ * Bluetooth low-complexity, subband codec (SBC) library
+ *
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
+ * Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
+ *
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#include <stdint.h>
+#include <limits.h>
+#include "sbc.h"
+#include "sbc_math.h"
+#include "sbc_tables.h"
+
+#include "sbc_primitives_armv6.h"
+
+/*
+ * ARMv6 optimizations. The instructions are scheduled for ARM11 pipeline.
+ */
+
+#ifdef SBC_BUILD_WITH_ARMV6_SUPPORT
+
+static void __attribute__((naked)) sbc_analyze_four_armv6()
+{
+ /* r0 = in, r1 = out, r2 = consts */
+ asm volatile (
+ "push {r1, r4-r7, lr}\n"
+ "push {r8-r11}\n"
+ "ldrd r4, r5, [r0, #0]\n"
+ "ldrd r6, r7, [r2, #0]\n"
+ "ldrd r8, r9, [r0, #16]\n"
+ "ldrd r10, r11, [r2, #16]\n"
+ "mov r14, #0x8000\n"
+ "smlad r3, r4, r6, r14\n"
+ "smlad r12, r5, r7, r14\n"
+ "ldrd r4, r5, [r0, #32]\n"
+ "ldrd r6, r7, [r2, #32]\n"
+ "smlad r3, r8, r10, r3\n"
+ "smlad r12, r9, r11, r12\n"
+ "ldrd r8, r9, [r0, #48]\n"
+ "ldrd r10, r11, [r2, #48]\n"
+ "smlad r3, r4, r6, r3\n"
+ "smlad r12, r5, r7, r12\n"
+ "ldrd r4, r5, [r0, #64]\n"
+ "ldrd r6, r7, [r2, #64]\n"
+ "smlad r3, r8, r10, r3\n"
+ "smlad r12, r9, r11, r12\n"
+ "ldrd r8, r9, [r0, #8]\n"
+ "ldrd r10, r11, [r2, #8]\n"
+ "smlad r3, r4, r6, r3\n" /* t1[0] is done */
+ "smlad r12, r5, r7, r12\n" /* t1[1] is done */
+ "ldrd r4, r5, [r0, #24]\n"
+ "ldrd r6, r7, [r2, #24]\n"
+ "pkhtb r3, r12, r3, asr #16\n" /* combine t1[0] and t1[1] */
+ "smlad r12, r8, r10, r14\n"
+ "smlad r14, r9, r11, r14\n"
+ "ldrd r8, r9, [r0, #40]\n"
+ "ldrd r10, r11, [r2, #40]\n"
+ "smlad r12, r4, r6, r12\n"
+ "smlad r14, r5, r7, r14\n"
+ "ldrd r4, r5, [r0, #56]\n"
+ "ldrd r6, r7, [r2, #56]\n"
+ "smlad r12, r8, r10, r12\n"
+ "smlad r14, r9, r11, r14\n"
+ "ldrd r8, r9, [r0, #72]\n"
+ "ldrd r10, r11, [r2, #72]\n"
+ "smlad r12, r4, r6, r12\n"
+ "smlad r14, r5, r7, r14\n"
+ "ldrd r4, r5, [r2, #80]\n" /* start loading cos table */
+ "smlad r12, r8, r10, r12\n" /* t1[2] is done */
+ "smlad r14, r9, r11, r14\n" /* t1[3] is done */
+ "ldrd r6, r7, [r2, #88]\n"
+ "ldrd r8, r9, [r2, #96]\n"
+ "ldrd r10, r11, [r2, #104]\n" /* cos table fully loaded */
+ "pkhtb r12, r14, r12, asr #16\n" /* combine t1[2] and t1[3] */
+ "smuad r4, r3, r4\n"
+ "smuad r5, r3, r5\n"
+ "smlad r4, r12, r8, r4\n"
+ "smlad r5, r12, r9, r5\n"
+ "smuad r6, r3, r6\n"
+ "smuad r7, r3, r7\n"
+ "smlad r6, r12, r10, r6\n"
+ "smlad r7, r12, r11, r7\n"
+ "pop {r8-r11}\n"
+ "stmia r1, {r4, r5, r6, r7}\n"
+ "pop {r1, r4-r7, pc}\n"
+ );
+}
+
+#define sbc_analyze_four(in, out, consts) \
+ ((void (*)(int16_t *, int32_t *, const FIXED_T*)) \
+ sbc_analyze_four_armv6)((in), (out), (consts))
+
+static void __attribute__((naked)) sbc_analyze_eight_armv6()
+{
+ /* r0 = in, r1 = out, r2 = consts */
+ asm volatile (
+ "push {r1, r4-r7, lr}\n"
+ "push {r8-r11}\n"
+ "ldrd r4, r5, [r0, #24]\n"
+ "ldrd r6, r7, [r2, #24]\n"
+ "ldrd r8, r9, [r0, #56]\n"
+ "ldrd r10, r11, [r2, #56]\n"
+ "mov r14, #0x8000\n"
+ "smlad r3, r4, r6, r14\n"
+ "smlad r12, r5, r7, r14\n"
+ "ldrd r4, r5, [r0, #88]\n"
+ "ldrd r6, r7, [r2, #88]\n"
+ "smlad r3, r8, r10, r3\n"
+ "smlad r12, r9, r11, r12\n"
+ "ldrd r8, r9, [r0, #120]\n"
+ "ldrd r10, r11, [r2, #120]\n"
+ "smlad r3, r4, r6, r3\n"
+ "smlad r12, r5, r7, r12\n"
+ "ldrd r4, r5, [r0, #152]\n"
+ "ldrd r6, r7, [r2, #152]\n"
+ "smlad r3, r8, r10, r3\n"
+ "smlad r12, r9, r11, r12\n"
+ "ldrd r8, r9, [r0, #16]\n"
+ "ldrd r10, r11, [r2, #16]\n"
+ "smlad r3, r4, r6, r3\n" /* t1[6] is done */
+ "smlad r12, r5, r7, r12\n" /* t1[7] is done */
+ "ldrd r4, r5, [r0, #48]\n"
+ "ldrd r6, r7, [r2, #48]\n"
+ "pkhtb r3, r12, r3, asr #16\n" /* combine t1[6] and t1[7] */
+ "str r3, [sp, #-4]!\n" /* save to stack */
+ "smlad r3, r8, r10, r14\n"
+ "smlad r12, r9, r11, r14\n"
+ "ldrd r8, r9, [r0, #80]\n"
+ "ldrd r10, r11, [r2, #80]\n"
+ "smlad r3, r4, r6, r3\n"
+ "smlad r12, r5, r7, r12\n"
+ "ldrd r4, r5, [r0, #112]\n"
+ "ldrd r6, r7, [r2, #112]\n"
+ "smlad r3, r8, r10, r3\n"
+ "smlad r12, r9, r11, r12\n"
+ "ldrd r8, r9, [r0, #144]\n"
+ "ldrd r10, r11, [r2, #144]\n"
+ "smlad r3, r4, r6, r3\n"
+ "smlad r12, r5, r7, r12\n"
+ "ldrd r4, r5, [r0, #0]\n"
+ "ldrd r6, r7, [r2, #0]\n"
+ "smlad r3, r8, r10, r3\n" /* t1[4] is done */
+ "smlad r12, r9, r11, r12\n" /* t1[5] is done */
+ "ldrd r8, r9, [r0, #32]\n"
+ "ldrd r10, r11, [r2, #32]\n"
+ "pkhtb r3, r12, r3, asr #16\n" /* combine t1[4] and t1[5] */
+ "str r3, [sp, #-4]!\n" /* save to stack */
+ "smlad r3, r4, r6, r14\n"
+ "smlad r12, r5, r7, r14\n"
+ "ldrd r4, r5, [r0, #64]\n"
+ "ldrd r6, r7, [r2, #64]\n"
+ "smlad r3, r8, r10, r3\n"
+ "smlad r12, r9, r11, r12\n"
+ "ldrd r8, r9, [r0, #96]\n"
+ "ldrd r10, r11, [r2, #96]\n"
+ "smlad r3, r4, r6, r3\n"
+ "smlad r12, r5, r7, r12\n"
+ "ldrd r4, r5, [r0, #128]\n"
+ "ldrd r6, r7, [r2, #128]\n"
+ "smlad r3, r8, r10, r3\n"
+ "smlad r12, r9, r11, r12\n"
+ "ldrd r8, r9, [r0, #8]\n"
+ "ldrd r10, r11, [r2, #8]\n"
+ "smlad r3, r4, r6, r3\n" /* t1[0] is done */
+ "smlad r12, r5, r7, r12\n" /* t1[1] is done */
+ "ldrd r4, r5, [r0, #40]\n"
+ "ldrd r6, r7, [r2, #40]\n"
+ "pkhtb r3, r12, r3, asr #16\n" /* combine t1[0] and t1[1] */
+ "smlad r12, r8, r10, r14\n"
+ "smlad r14, r9, r11, r14\n"
+ "ldrd r8, r9, [r0, #72]\n"
+ "ldrd r10, r11, [r2, #72]\n"
+ "smlad r12, r4, r6, r12\n"
+ "smlad r14, r5, r7, r14\n"
+ "ldrd r4, r5, [r0, #104]\n"
+ "ldrd r6, r7, [r2, #104]\n"
+ "smlad r12, r8, r10, r12\n"
+ "smlad r14, r9, r11, r14\n"
+ "ldrd r8, r9, [r0, #136]\n"
+ "ldrd r10, r11, [r2, #136]!\n"
+ "smlad r12, r4, r6, r12\n"
+ "smlad r14, r5, r7, r14\n"
+ "ldrd r4, r5, [r2, #(160 - 136 + 0)]\n"
+ "smlad r12, r8, r10, r12\n" /* t1[2] is done */
+ "smlad r14, r9, r11, r14\n" /* t1[3] is done */
+ "ldrd r6, r7, [r2, #(160 - 136 + 8)]\n"
+ "smuad r4, r3, r4\n"
+ "smuad r5, r3, r5\n"
+ "pkhtb r12, r14, r12, asr #16\n" /* combine t1[2] and t1[3] */
+ /* r3 = t2[0:1] */
+ /* r12 = t2[2:3] */
+ "pop {r0, r14}\n" /* t2[4:5], t2[6:7] */
+ "ldrd r8, r9, [r2, #(160 - 136 + 32)]\n"
+ "smuad r6, r3, r6\n"
+ "smuad r7, r3, r7\n"
+ "ldrd r10, r11, [r2, #(160 - 136 + 40)]\n"
+ "smlad r4, r12, r8, r4\n"
+ "smlad r5, r12, r9, r5\n"
+ "ldrd r8, r9, [r2, #(160 - 136 + 64)]\n"
+ "smlad r6, r12, r10, r6\n"
+ "smlad r7, r12, r11, r7\n"
+ "ldrd r10, r11, [r2, #(160 - 136 + 72)]\n"
+ "smlad r4, r0, r8, r4\n"
+ "smlad r5, r0, r9, r5\n"
+ "ldrd r8, r9, [r2, #(160 - 136 + 96)]\n"
+ "smlad r6, r0, r10, r6\n"
+ "smlad r7, r0, r11, r7\n"
+ "ldrd r10, r11, [r2, #(160 - 136 + 104)]\n"
+ "smlad r4, r14, r8, r4\n"
+ "smlad r5, r14, r9, r5\n"
+ "ldrd r8, r9, [r2, #(160 - 136 + 16 + 0)]\n"
+ "smlad r6, r14, r10, r6\n"
+ "smlad r7, r14, r11, r7\n"
+ "ldrd r10, r11, [r2, #(160 - 136 + 16 + 8)]\n"
+ "stmia r1!, {r4, r5}\n"
+ "smuad r4, r3, r8\n"
+ "smuad r5, r3, r9\n"
+ "ldrd r8, r9, [r2, #(160 - 136 + 16 + 32)]\n"
+ "stmia r1!, {r6, r7}\n"
+ "smuad r6, r3, r10\n"
+ "smuad r7, r3, r11\n"
+ "ldrd r10, r11, [r2, #(160 - 136 + 16 + 40)]\n"
+ "smlad r4, r12, r8, r4\n"
+ "smlad r5, r12, r9, r5\n"
+ "ldrd r8, r9, [r2, #(160 - 136 + 16 + 64)]\n"
+ "smlad r6, r12, r10, r6\n"
+ "smlad r7, r12, r11, r7\n"
+ "ldrd r10, r11, [r2, #(160 - 136 + 16 + 72)]\n"
+ "smlad r4, r0, r8, r4\n"
+ "smlad r5, r0, r9, r5\n"
+ "ldrd r8, r9, [r2, #(160 - 136 + 16 + 96)]\n"
+ "smlad r6, r0, r10, r6\n"
+ "smlad r7, r0, r11, r7\n"
+ "ldrd r10, r11, [r2, #(160 - 136 + 16 + 104)]\n"
+ "smlad r4, r14, r8, r4\n"
+ "smlad r5, r14, r9, r5\n"
+ "smlad r6, r14, r10, r6\n"
+ "smlad r7, r14, r11, r7\n"
+ "pop {r8-r11}\n"
+ "stmia r1!, {r4, r5, r6, r7}\n"
+ "pop {r1, r4-r7, pc}\n"
+ );
+}
+
+#define sbc_analyze_eight(in, out, consts) \
+ ((void (*)(int16_t *, int32_t *, const FIXED_T*)) \
+ sbc_analyze_eight_armv6)((in), (out), (consts))
+
+static void sbc_analyze_4b_4s_armv6(int16_t *x, int32_t *out, int out_stride)
+{
+ /* Analyze blocks */
+ sbc_analyze_four(x + 12, out, analysis_consts_fixed4_simd_odd);
+ out += out_stride;
+ sbc_analyze_four(x + 8, out, analysis_consts_fixed4_simd_even);
+ out += out_stride;
+ sbc_analyze_four(x + 4, out, analysis_consts_fixed4_simd_odd);
+ out += out_stride;
+ sbc_analyze_four(x + 0, out, analysis_consts_fixed4_simd_even);
+}
+
+static void sbc_analyze_4b_8s_armv6(int16_t *x, int32_t *out, int out_stride)
+{
+ /* Analyze blocks */
+ sbc_analyze_eight(x + 24, out, analysis_consts_fixed8_simd_odd);
+ out += out_stride;
+ sbc_analyze_eight(x + 16, out, analysis_consts_fixed8_simd_even);
+ out += out_stride;
+ sbc_analyze_eight(x + 8, out, analysis_consts_fixed8_simd_odd);
+ out += out_stride;
+ sbc_analyze_eight(x + 0, out, analysis_consts_fixed8_simd_even);
+}
+
+void sbc_init_primitives_armv6(struct sbc_encoder_state *state)
+{
+ state->sbc_analyze_4b_4s = sbc_analyze_4b_4s_armv6;
+ state->sbc_analyze_4b_8s = sbc_analyze_4b_8s_armv6;
+ state->implementation_info = "ARMv6 SIMD";
+}
+
+#endif
diff --git a/src/modules/bluetooth/sbc/sbc_primitives_armv6.h b/src/modules/bluetooth/sbc/sbc_primitives_armv6.h
new file mode 100644
index 00000000..6a9efe50
--- /dev/null
+++ b/src/modules/bluetooth/sbc/sbc_primitives_armv6.h
@@ -0,0 +1,52 @@
+/*
+ *
+ * Bluetooth low-complexity, subband codec (SBC) library
+ *
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
+ * Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
+ *
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#ifndef __SBC_PRIMITIVES_ARMV6_H
+#define __SBC_PRIMITIVES_ARMV6_H
+
+#include "sbc_primitives.h"
+
+#if defined(__ARM_ARCH_6__) || defined(__ARM_ARCH_6J__) || \
+ defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_6Z__) || \
+ defined(__ARM_ARCH_6ZK__) || defined(__ARM_ARCH_6T2__) || \
+ defined(__ARM_ARCH_6M__) || defined(__ARM_ARCH_7__) || \
+ defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_7R__) || \
+ defined(__ARM_ARCH_7M__)
+#define SBC_HAVE_ARMV6 1
+#endif
+
+#if !defined(SBC_HIGH_PRECISION) && (SCALE_OUT_BITS == 15) && \
+ defined(__GNUC__) && defined(SBC_HAVE_ARMV6) && \
+ defined(__ARM_EABI__) && !defined(__ARM_NEON__) && \
+ (!defined(__thumb__) || defined(__thumb2__))
+
+#define SBC_BUILD_WITH_ARMV6_SUPPORT
+
+void sbc_init_primitives_armv6(struct sbc_encoder_state *encoder_state);
+
+#endif
+
+#endif
diff --git a/src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.c b/src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.c
new file mode 100644
index 00000000..213967ef
--- /dev/null
+++ b/src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.c
@@ -0,0 +1,304 @@
+/*
+ *
+ * Bluetooth low-complexity, subband codec (SBC) library
+ *
+ * Copyright (C) 2010 Keith Mok <ek9852@gmail.com>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
+ * Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
+ *
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#include <stdint.h>
+#include <limits.h>
+#include "sbc.h"
+#include "sbc_math.h"
+#include "sbc_tables.h"
+
+#include "sbc_primitives_iwmmxt.h"
+
+/*
+ * IWMMXT optimizations
+ */
+
+#ifdef SBC_BUILD_WITH_IWMMXT_SUPPORT
+
+static inline void sbc_analyze_four_iwmmxt(const int16_t *in, int32_t *out,
+ const FIXED_T *consts)
+{
+ asm volatile (
+ "wldrd wr0, [%0]\n"
+ "tbcstw wr4, %2\n"
+ "wldrd wr2, [%1]\n"
+ "wldrd wr1, [%0, #8]\n"
+ "wldrd wr3, [%1, #8]\n"
+ "wmadds wr0, wr2, wr0\n"
+ " wldrd wr6, [%0, #16]\n"
+ "wmadds wr1, wr3, wr1\n"
+ " wldrd wr7, [%0, #24]\n"
+ "waddwss wr0, wr0, wr4\n"
+ " wldrd wr8, [%1, #16]\n"
+ "waddwss wr1, wr1, wr4\n"
+ " wldrd wr9, [%1, #24]\n"
+ " wmadds wr6, wr8, wr6\n"
+ " wldrd wr2, [%0, #32]\n"
+ " wmadds wr7, wr9, wr7\n"
+ " wldrd wr3, [%0, #40]\n"
+ " waddwss wr0, wr6, wr0\n"
+ " wldrd wr4, [%1, #32]\n"
+ " waddwss wr1, wr7, wr1\n"
+ " wldrd wr5, [%1, #40]\n"
+ " wmadds wr2, wr4, wr2\n"
+ "wldrd wr6, [%0, #48]\n"
+ " wmadds wr3, wr5, wr3\n"
+ "wldrd wr7, [%0, #56]\n"
+ " waddwss wr0, wr2, wr0\n"
+ "wldrd wr8, [%1, #48]\n"
+ " waddwss wr1, wr3, wr1\n"
+ "wldrd wr9, [%1, #56]\n"
+ "wmadds wr6, wr8, wr6\n"
+ " wldrd wr2, [%0, #64]\n"
+ "wmadds wr7, wr9, wr7\n"
+ " wldrd wr3, [%0, #72]\n"
+ "waddwss wr0, wr6, wr0\n"
+ " wldrd wr4, [%1, #64]\n"
+ "waddwss wr1, wr7, wr1\n"
+ " wldrd wr5, [%1, #72]\n"
+ " wmadds wr2, wr4, wr2\n"
+ "tmcr wcgr0, %4\n"
+ " wmadds wr3, wr5, wr3\n"
+ " waddwss wr0, wr2, wr0\n"
+ " waddwss wr1, wr3, wr1\n"
+ "\n"
+ "wsrawg wr0, wr0, wcgr0\n"
+ " wldrd wr4, [%1, #80]\n"
+ "wsrawg wr1, wr1, wcgr0\n"
+ " wldrd wr5, [%1, #88]\n"
+ "wpackwss wr0, wr0, wr0\n"
+ " wldrd wr6, [%1, #96]\n"
+ "wpackwss wr1, wr1, wr1\n"
+ "wmadds wr2, wr5, wr0\n"
+ " wldrd wr7, [%1, #104]\n"
+ "wmadds wr0, wr4, wr0\n"
+ "\n"
+ " wmadds wr3, wr7, wr1\n"
+ " wmadds wr1, wr6, wr1\n"
+ " waddwss wr2, wr3, wr2\n"
+ " waddwss wr0, wr1, wr0\n"
+ "\n"
+ "wstrd wr0, [%3]\n"
+ "wstrd wr2, [%3, #8]\n"
+ :
+ : "r" (in), "r" (consts),
+ "r" (1 << (SBC_PROTO_FIXED4_SCALE - 1)), "r" (out),
+ "r" (SBC_PROTO_FIXED4_SCALE)
+ : "wr0", "wr1", "wr2", "wr3", "wr4", "wr5", "wr6", "wr7",
+ "wr8", "wr9", "wcgr0", "memory");
+}
+
+static inline void sbc_analyze_eight_iwmmxt(const int16_t *in, int32_t *out,
+ const FIXED_T *consts)
+{
+ asm volatile (
+ "wldrd wr0, [%0]\n"
+ "tbcstw wr15, %2\n"
+ "wldrd wr1, [%0, #8]\n"
+ "wldrd wr2, [%0, #16]\n"
+ "wldrd wr3, [%0, #24]\n"
+ "wldrd wr4, [%1]\n"
+ "wldrd wr5, [%1, #8]\n"
+ "wldrd wr6, [%1, #16]\n"
+ "wldrd wr7, [%1, #24]\n"
+ "wmadds wr0, wr0, wr4\n"
+ " wldrd wr8, [%1, #32]\n"
+ "wmadds wr1, wr1, wr5\n"
+ " wldrd wr9, [%1, #40]\n"
+ "wmadds wr2, wr2, wr6\n"
+ " wldrd wr10, [%1, #48]\n"
+ "wmadds wr3, wr3, wr7\n"
+ " wldrd wr11, [%1, #56]\n"
+ "waddwss wr0, wr0, wr15\n"
+ " wldrd wr4, [%0, #32]\n"
+ "waddwss wr1, wr1, wr15\n"
+ " wldrd wr5, [%0, #40]\n"
+ "waddwss wr2, wr2, wr15\n"
+ " wldrd wr6, [%0, #48]\n"
+ "waddwss wr3, wr3, wr15\n"
+ " wldrd wr7, [%0, #56]\n"
+ " wmadds wr4, wr4, wr8\n"
+ " wldrd wr12, [%0, #64]\n"
+ " wmadds wr5, wr5, wr9\n"
+ " wldrd wr13, [%0, #72]\n"
+ " wmadds wr6, wr6, wr10\n"
+ " wldrd wr14, [%0, #80]\n"
+ " wmadds wr7, wr7, wr11\n"
+ " wldrd wr15, [%0, #88]\n"
+ " waddwss wr0, wr4, wr0\n"
+ " wldrd wr8, [%1, #64]\n"
+ " waddwss wr1, wr5, wr1\n"
+ " wldrd wr9, [%1, #72]\n"
+ " waddwss wr2, wr6, wr2\n"
+ " wldrd wr10, [%1, #80]\n"
+ " waddwss wr3, wr7, wr3\n"
+ " wldrd wr11, [%1, #88]\n"
+ " wmadds wr12, wr12, wr8\n"
+ "wldrd wr4, [%0, #96]\n"
+ " wmadds wr13, wr13, wr9\n"
+ "wldrd wr5, [%0, #104]\n"
+ " wmadds wr14, wr14, wr10\n"
+ "wldrd wr6, [%0, #112]\n"
+ " wmadds wr15, wr15, wr11\n"
+ "wldrd wr7, [%0, #120]\n"
+ " waddwss wr0, wr12, wr0\n"
+ "wldrd wr8, [%1, #96]\n"
+ " waddwss wr1, wr13, wr1\n"
+ "wldrd wr9, [%1, #104]\n"
+ " waddwss wr2, wr14, wr2\n"
+ "wldrd wr10, [%1, #112]\n"
+ " waddwss wr3, wr15, wr3\n"
+ "wldrd wr11, [%1, #120]\n"
+ "wmadds wr4, wr4, wr8\n"
+ " wldrd wr12, [%0, #128]\n"
+ "wmadds wr5, wr5, wr9\n"
+ " wldrd wr13, [%0, #136]\n"
+ "wmadds wr6, wr6, wr10\n"
+ " wldrd wr14, [%0, #144]\n"
+ "wmadds wr7, wr7, wr11\n"
+ " wldrd wr15, [%0, #152]\n"
+ "waddwss wr0, wr4, wr0\n"
+ " wldrd wr8, [%1, #128]\n"
+ "waddwss wr1, wr5, wr1\n"
+ " wldrd wr9, [%1, #136]\n"
+ "waddwss wr2, wr6, wr2\n"
+ " wldrd wr10, [%1, #144]\n"
+ " waddwss wr3, wr7, wr3\n"
+ " wldrd wr11, [%1, #152]\n"
+ " wmadds wr12, wr12, wr8\n"
+ "tmcr wcgr0, %4\n"
+ " wmadds wr13, wr13, wr9\n"
+ " wmadds wr14, wr14, wr10\n"
+ " wmadds wr15, wr15, wr11\n"
+ " waddwss wr0, wr12, wr0\n"
+ " waddwss wr1, wr13, wr1\n"
+ " waddwss wr2, wr14, wr2\n"
+ " waddwss wr3, wr15, wr3\n"
+ "\n"
+ "wsrawg wr0, wr0, wcgr0\n"
+ "wsrawg wr1, wr1, wcgr0\n"
+ "wsrawg wr2, wr2, wcgr0\n"
+ "wsrawg wr3, wr3, wcgr0\n"
+ "\n"
+ "wpackwss wr0, wr0, wr0\n"
+ "wpackwss wr1, wr1, wr1\n"
+ " wldrd wr4, [%1, #160]\n"
+ "wpackwss wr2, wr2, wr2\n"
+ " wldrd wr5, [%1, #168]\n"
+ "wpackwss wr3, wr3, wr3\n"
+ " wldrd wr6, [%1, #192]\n"
+ " wmadds wr4, wr4, wr0\n"
+ " wldrd wr7, [%1, #200]\n"
+ " wmadds wr5, wr5, wr0\n"
+ " wldrd wr8, [%1, #224]\n"
+ " wmadds wr6, wr6, wr1\n"
+ " wldrd wr9, [%1, #232]\n"
+ " wmadds wr7, wr7, wr1\n"
+ " waddwss wr4, wr6, wr4\n"
+ " waddwss wr5, wr7, wr5\n"
+ " wmadds wr8, wr8, wr2\n"
+ "wldrd wr6, [%1, #256]\n"
+ " wmadds wr9, wr9, wr2\n"
+ "wldrd wr7, [%1, #264]\n"
+ "waddwss wr4, wr8, wr4\n"
+ " waddwss wr5, wr9, wr5\n"
+ "wmadds wr6, wr6, wr3\n"
+ "wmadds wr7, wr7, wr3\n"
+ "waddwss wr4, wr6, wr4\n"
+ "waddwss wr5, wr7, wr5\n"
+ "\n"
+ "wstrd wr4, [%3]\n"
+ "wstrd wr5, [%3, #8]\n"
+ "\n"
+ "wldrd wr6, [%1, #176]\n"
+ "wldrd wr5, [%1, #184]\n"
+ "wmadds wr5, wr5, wr0\n"
+ "wldrd wr8, [%1, #208]\n"
+ "wmadds wr0, wr6, wr0\n"
+ "wldrd wr9, [%1, #216]\n"
+ "wmadds wr9, wr9, wr1\n"
+ "wldrd wr6, [%1, #240]\n"
+ "wmadds wr1, wr8, wr1\n"
+ "wldrd wr7, [%1, #248]\n"
+ "waddwss wr0, wr1, wr0\n"
+ "waddwss wr5, wr9, wr5\n"
+ "wmadds wr7, wr7, wr2\n"
+ "wldrd wr8, [%1, #272]\n"
+ "wmadds wr2, wr6, wr2\n"
+ "wldrd wr9, [%1, #280]\n"
+ "waddwss wr0, wr2, wr0\n"
+ "waddwss wr5, wr7, wr5\n"
+ "wmadds wr9, wr9, wr3\n"
+ "wmadds wr3, wr8, wr3\n"
+ "waddwss wr0, wr3, wr0\n"
+ "waddwss wr5, wr9, wr5\n"
+ "\n"
+ "wstrd wr0, [%3, #16]\n"
+ "wstrd wr5, [%3, #24]\n"
+ :
+ : "r" (in), "r" (consts),
+ "r" (1 << (SBC_PROTO_FIXED8_SCALE - 1)), "r" (out),
+ "r" (SBC_PROTO_FIXED8_SCALE)
+ : "wr0", "wr1", "wr2", "wr3", "wr4", "wr5", "wr6", "wr7",
+ "wr8", "wr9", "wr10", "wr11", "wr12", "wr13", "wr14", "wr15",
+ "wcgr0", "memory");
+}
+
+static inline void sbc_analyze_4b_4s_iwmmxt(int16_t *x, int32_t *out,
+ int out_stride)
+{
+ /* Analyze blocks */
+ sbc_analyze_four_iwmmxt(x + 12, out, analysis_consts_fixed4_simd_odd);
+ out += out_stride;
+ sbc_analyze_four_iwmmxt(x + 8, out, analysis_consts_fixed4_simd_even);
+ out += out_stride;
+ sbc_analyze_four_iwmmxt(x + 4, out, analysis_consts_fixed4_simd_odd);
+ out += out_stride;
+ sbc_analyze_four_iwmmxt(x + 0, out, analysis_consts_fixed4_simd_even);
+}
+
+static inline void sbc_analyze_4b_8s_iwmmxt(int16_t *x, int32_t *out,
+ int out_stride)
+{
+ /* Analyze blocks */
+ sbc_analyze_eight_iwmmxt(x + 24, out, analysis_consts_fixed8_simd_odd);
+ out += out_stride;
+ sbc_analyze_eight_iwmmxt(x + 16, out, analysis_consts_fixed8_simd_even);
+ out += out_stride;
+ sbc_analyze_eight_iwmmxt(x + 8, out, analysis_consts_fixed8_simd_odd);
+ out += out_stride;
+ sbc_analyze_eight_iwmmxt(x + 0, out, analysis_consts_fixed8_simd_even);
+}
+
+void sbc_init_primitives_iwmmxt(struct sbc_encoder_state *state)
+{
+ state->sbc_analyze_4b_4s = sbc_analyze_4b_4s_iwmmxt;
+ state->sbc_analyze_4b_8s = sbc_analyze_4b_8s_iwmmxt;
+ state->implementation_info = "IWMMXT";
+}
+
+#endif
diff --git a/src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.h b/src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.h
new file mode 100644
index 00000000..b535e686
--- /dev/null
+++ b/src/modules/bluetooth/sbc/sbc_primitives_iwmmxt.h
@@ -0,0 +1,42 @@
+/*
+ *
+ * Bluetooth low-complexity, subband codec (SBC) library
+ *
+ * Copyright (C) 2010 Keith Mok <ek9852@gmail.com>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
+ * Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
+ *
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#ifndef __SBC_PRIMITIVES_IWMMXT_H
+#define __SBC_PRIMITIVES_IWMMXT_H
+
+#include "sbc_primitives.h"
+
+#if defined(__GNUC__) && defined(__IWMMXT__) && \
+ !defined(SBC_HIGH_PRECISION) && (SCALE_OUT_BITS == 15)
+
+#define SBC_BUILD_WITH_IWMMXT_SUPPORT
+
+void sbc_init_primitives_iwmmxt(struct sbc_encoder_state *encoder_state);
+
+#endif
+
+#endif
diff --git a/src/modules/bluetooth/sbc_primitives_mmx.c b/src/modules/bluetooth/sbc/sbc_primitives_mmx.c
index 08e9ca28..7f2fbc37 100644
--- a/src/modules/bluetooth/sbc_primitives_mmx.c
+++ b/src/modules/bluetooth/sbc/sbc_primitives_mmx.c
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
*
@@ -100,7 +101,7 @@ static inline void sbc_analyze_four_mmx(const int16_t *in, int32_t *out,
:
: "r" (in), "r" (consts), "r" (&round_c), "r" (out),
"i" (SBC_PROTO_FIXED4_SCALE)
- : "memory");
+ : "cc", "memory");
}
static inline void sbc_analyze_eight_mmx(const int16_t *in, int32_t *out,
@@ -242,7 +243,7 @@ static inline void sbc_analyze_eight_mmx(const int16_t *in, int32_t *out,
:
: "r" (in), "r" (consts), "r" (&round_c), "r" (out),
"i" (SBC_PROTO_FIXED8_SCALE)
- : "memory");
+ : "cc", "memory");
}
static inline void sbc_analyze_4b_4s_mmx(int16_t *x, int32_t *out,
@@ -275,6 +276,59 @@ static inline void sbc_analyze_4b_8s_mmx(int16_t *x, int32_t *out,
asm volatile ("emms\n");
}
+static void sbc_calc_scalefactors_mmx(
+ int32_t sb_sample_f[16][2][8],
+ uint32_t scale_factor[2][8],
+ int blocks, int channels, int subbands)
+{
+ static const SBC_ALIGNED int32_t consts[2] = {
+ 1 << SCALE_OUT_BITS,
+ 1 << SCALE_OUT_BITS,
+ };
+ int ch, sb;
+ intptr_t blk;
+ for (ch = 0; ch < channels; ch++) {
+ for (sb = 0; sb < subbands; sb += 2) {
+ blk = (blocks - 1) * (((char *) &sb_sample_f[1][0][0] -
+ (char *) &sb_sample_f[0][0][0]));
+ asm volatile (
+ "movq (%4), %%mm0\n"
+ "1:\n"
+ "movq (%1, %0), %%mm1\n"
+ "pxor %%mm2, %%mm2\n"
+ "pcmpgtd %%mm2, %%mm1\n"
+ "paddd (%1, %0), %%mm1\n"
+ "pcmpgtd %%mm1, %%mm2\n"
+ "pxor %%mm2, %%mm1\n"
+
+ "por %%mm1, %%mm0\n"
+
+ "sub %2, %0\n"
+ "jns 1b\n"
+
+ "movd %%mm0, %k0\n"
+ "psrlq $32, %%mm0\n"
+ "bsrl %k0, %k0\n"
+ "subl %5, %k0\n"
+ "movl %k0, (%3)\n"
+
+ "movd %%mm0, %k0\n"
+ "bsrl %k0, %k0\n"
+ "subl %5, %k0\n"
+ "movl %k0, 4(%3)\n"
+ : "+r" (blk)
+ : "r" (&sb_sample_f[0][ch][sb]),
+ "i" ((char *) &sb_sample_f[1][0][0] -
+ (char *) &sb_sample_f[0][0][0]),
+ "r" (&scale_factor[ch][sb]),
+ "r" (&consts),
+ "i" (SCALE_OUT_BITS)
+ : "cc", "memory");
+ }
+ }
+ asm volatile ("emms\n");
+}
+
static int check_mmx_support(void)
{
#ifdef __amd64__
@@ -313,6 +367,7 @@ void sbc_init_primitives_mmx(struct sbc_encoder_state *state)
if (check_mmx_support()) {
state->sbc_analyze_4b_4s = sbc_analyze_4b_4s_mmx;
state->sbc_analyze_4b_8s = sbc_analyze_4b_8s_mmx;
+ state->sbc_calc_scalefactors = sbc_calc_scalefactors_mmx;
state->implementation_info = "MMX";
}
}
diff --git a/src/modules/bluetooth/sbc_primitives_mmx.h b/src/modules/bluetooth/sbc/sbc_primitives_mmx.h
index c1e44a5d..e0e728bc 100644
--- a/src/modules/bluetooth/sbc_primitives_mmx.h
+++ b/src/modules/bluetooth/sbc/sbc_primitives_mmx.h
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
*
diff --git a/src/modules/bluetooth/sbc/sbc_primitives_neon.c b/src/modules/bluetooth/sbc/sbc_primitives_neon.c
new file mode 100644
index 00000000..0572158d
--- /dev/null
+++ b/src/modules/bluetooth/sbc/sbc_primitives_neon.c
@@ -0,0 +1,893 @@
+/*
+ *
+ * Bluetooth low-complexity, subband codec (SBC) library
+ *
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
+ * Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
+ *
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#include <stdint.h>
+#include <limits.h>
+#include "sbc.h"
+#include "sbc_math.h"
+#include "sbc_tables.h"
+
+#include "sbc_primitives_neon.h"
+
+/*
+ * ARM NEON optimizations
+ */
+
+#ifdef SBC_BUILD_WITH_NEON_SUPPORT
+
+static inline void _sbc_analyze_four_neon(const int16_t *in, int32_t *out,
+ const FIXED_T *consts)
+{
+ /* TODO: merge even and odd cases (or even merge all four calls to this
+ * function) in order to have only aligned reads from 'in' array
+ * and reduce number of load instructions */
+ asm volatile (
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmull.s16 q0, d4, d8\n"
+ "vld1.16 {d6, d7}, [%0, :64]!\n"
+ "vmull.s16 q1, d5, d9\n"
+ "vld1.16 {d10, d11}, [%1, :128]!\n"
+
+ "vmlal.s16 q0, d6, d10\n"
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vmlal.s16 q1, d7, d11\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmlal.s16 q0, d4, d8\n"
+ "vld1.16 {d6, d7}, [%0, :64]!\n"
+ "vmlal.s16 q1, d5, d9\n"
+ "vld1.16 {d10, d11}, [%1, :128]!\n"
+
+ "vmlal.s16 q0, d6, d10\n"
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vmlal.s16 q1, d7, d11\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmlal.s16 q0, d4, d8\n"
+ "vmlal.s16 q1, d5, d9\n"
+
+ "vpadd.s32 d0, d0, d1\n"
+ "vpadd.s32 d1, d2, d3\n"
+
+ "vrshrn.s32 d0, q0, %3\n"
+
+ "vld1.16 {d2, d3, d4, d5}, [%1, :128]!\n"
+
+ "vdup.i32 d1, d0[1]\n" /* TODO: can be eliminated */
+ "vdup.i32 d0, d0[0]\n" /* TODO: can be eliminated */
+
+ "vmull.s16 q3, d2, d0\n"
+ "vmull.s16 q4, d3, d0\n"
+ "vmlal.s16 q3, d4, d1\n"
+ "vmlal.s16 q4, d5, d1\n"
+
+ "vpadd.s32 d0, d6, d7\n" /* TODO: can be eliminated */
+ "vpadd.s32 d1, d8, d9\n" /* TODO: can be eliminated */
+
+ "vst1.32 {d0, d1}, [%2, :128]\n"
+ : "+r" (in), "+r" (consts)
+ : "r" (out),
+ "i" (SBC_PROTO_FIXED4_SCALE)
+ : "memory",
+ "d0", "d1", "d2", "d3", "d4", "d5",
+ "d6", "d7", "d8", "d9", "d10", "d11");
+}
+
+static inline void _sbc_analyze_eight_neon(const int16_t *in, int32_t *out,
+ const FIXED_T *consts)
+{
+ /* TODO: merge even and odd cases (or even merge all four calls to this
+ * function) in order to have only aligned reads from 'in' array
+ * and reduce number of load instructions */
+ asm volatile (
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmull.s16 q6, d4, d8\n"
+ "vld1.16 {d6, d7}, [%0, :64]!\n"
+ "vmull.s16 q7, d5, d9\n"
+ "vld1.16 {d10, d11}, [%1, :128]!\n"
+ "vmull.s16 q8, d6, d10\n"
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vmull.s16 q9, d7, d11\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmlal.s16 q6, d4, d8\n"
+ "vld1.16 {d6, d7}, [%0, :64]!\n"
+ "vmlal.s16 q7, d5, d9\n"
+ "vld1.16 {d10, d11}, [%1, :128]!\n"
+ "vmlal.s16 q8, d6, d10\n"
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vmlal.s16 q9, d7, d11\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmlal.s16 q6, d4, d8\n"
+ "vld1.16 {d6, d7}, [%0, :64]!\n"
+ "vmlal.s16 q7, d5, d9\n"
+ "vld1.16 {d10, d11}, [%1, :128]!\n"
+ "vmlal.s16 q8, d6, d10\n"
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vmlal.s16 q9, d7, d11\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmlal.s16 q6, d4, d8\n"
+ "vld1.16 {d6, d7}, [%0, :64]!\n"
+ "vmlal.s16 q7, d5, d9\n"
+ "vld1.16 {d10, d11}, [%1, :128]!\n"
+ "vmlal.s16 q8, d6, d10\n"
+ "vld1.16 {d4, d5}, [%0, :64]!\n"
+ "vmlal.s16 q9, d7, d11\n"
+ "vld1.16 {d8, d9}, [%1, :128]!\n"
+
+ "vmlal.s16 q6, d4, d8\n"
+ "vld1.16 {d6, d7}, [%0, :64]!\n"
+ "vmlal.s16 q7, d5, d9\n"
+ "vld1.16 {d10, d11}, [%1, :128]!\n"
+
+ "vmlal.s16 q8, d6, d10\n"
+ "vmlal.s16 q9, d7, d11\n"
+
+ "vpadd.s32 d0, d12, d13\n"
+ "vpadd.s32 d1, d14, d15\n"
+ "vpadd.s32 d2, d16, d17\n"
+ "vpadd.s32 d3, d18, d19\n"
+
+ "vrshr.s32 q0, q0, %3\n"
+ "vrshr.s32 q1, q1, %3\n"
+ "vmovn.s32 d0, q0\n"
+ "vmovn.s32 d1, q1\n"
+
+ "vdup.i32 d3, d1[1]\n" /* TODO: can be eliminated */
+ "vdup.i32 d2, d1[0]\n" /* TODO: can be eliminated */
+ "vdup.i32 d1, d0[1]\n" /* TODO: can be eliminated */
+ "vdup.i32 d0, d0[0]\n" /* TODO: can be eliminated */
+
+ "vld1.16 {d4, d5}, [%1, :128]!\n"
+ "vmull.s16 q6, d4, d0\n"
+ "vld1.16 {d6, d7}, [%1, :128]!\n"
+ "vmull.s16 q7, d5, d0\n"
+ "vmull.s16 q8, d6, d0\n"
+ "vmull.s16 q9, d7, d0\n"
+
+ "vld1.16 {d4, d5}, [%1, :128]!\n"
+ "vmlal.s16 q6, d4, d1\n"
+ "vld1.16 {d6, d7}, [%1, :128]!\n"
+ "vmlal.s16 q7, d5, d1\n"
+ "vmlal.s16 q8, d6, d1\n"
+ "vmlal.s16 q9, d7, d1\n"
+
+ "vld1.16 {d4, d5}, [%1, :128]!\n"
+ "vmlal.s16 q6, d4, d2\n"
+ "vld1.16 {d6, d7}, [%1, :128]!\n"
+ "vmlal.s16 q7, d5, d2\n"
+ "vmlal.s16 q8, d6, d2\n"
+ "vmlal.s16 q9, d7, d2\n"
+
+ "vld1.16 {d4, d5}, [%1, :128]!\n"
+ "vmlal.s16 q6, d4, d3\n"
+ "vld1.16 {d6, d7}, [%1, :128]!\n"
+ "vmlal.s16 q7, d5, d3\n"
+ "vmlal.s16 q8, d6, d3\n"
+ "vmlal.s16 q9, d7, d3\n"
+
+ "vpadd.s32 d0, d12, d13\n" /* TODO: can be eliminated */
+ "vpadd.s32 d1, d14, d15\n" /* TODO: can be eliminated */
+ "vpadd.s32 d2, d16, d17\n" /* TODO: can be eliminated */
+ "vpadd.s32 d3, d18, d19\n" /* TODO: can be eliminated */
+
+ "vst1.32 {d0, d1, d2, d3}, [%2, :128]\n"
+ : "+r" (in), "+r" (consts)
+ : "r" (out),
+ "i" (SBC_PROTO_FIXED8_SCALE)
+ : "memory",
+ "d0", "d1", "d2", "d3", "d4", "d5",
+ "d6", "d7", "d8", "d9", "d10", "d11",
+ "d12", "d13", "d14", "d15", "d16", "d17",
+ "d18", "d19");
+}
+
+static inline void sbc_analyze_4b_4s_neon(int16_t *x,
+ int32_t *out, int out_stride)
+{
+ /* Analyze blocks */
+ _sbc_analyze_four_neon(x + 12, out, analysis_consts_fixed4_simd_odd);
+ out += out_stride;
+ _sbc_analyze_four_neon(x + 8, out, analysis_consts_fixed4_simd_even);
+ out += out_stride;
+ _sbc_analyze_four_neon(x + 4, out, analysis_consts_fixed4_simd_odd);
+ out += out_stride;
+ _sbc_analyze_four_neon(x + 0, out, analysis_consts_fixed4_simd_even);
+}
+
+static inline void sbc_analyze_4b_8s_neon(int16_t *x,
+ int32_t *out, int out_stride)
+{
+ /* Analyze blocks */
+ _sbc_analyze_eight_neon(x + 24, out, analysis_consts_fixed8_simd_odd);
+ out += out_stride;
+ _sbc_analyze_eight_neon(x + 16, out, analysis_consts_fixed8_simd_even);
+ out += out_stride;
+ _sbc_analyze_eight_neon(x + 8, out, analysis_consts_fixed8_simd_odd);
+ out += out_stride;
+ _sbc_analyze_eight_neon(x + 0, out, analysis_consts_fixed8_simd_even);
+}
+
+static void sbc_calc_scalefactors_neon(
+ int32_t sb_sample_f[16][2][8],
+ uint32_t scale_factor[2][8],
+ int blocks, int channels, int subbands)
+{
+ int ch, sb;
+ for (ch = 0; ch < channels; ch++) {
+ for (sb = 0; sb < subbands; sb += 4) {
+ int blk = blocks;
+ int32_t *in = &sb_sample_f[0][ch][sb];
+ asm volatile (
+ "vmov.s32 q0, #0\n"
+ "vmov.s32 q1, %[c1]\n"
+ "vmov.s32 q14, #1\n"
+ "vmov.s32 q15, %[c2]\n"
+ "vadd.s32 q1, q1, q14\n"
+ "1:\n"
+ "vld1.32 {d16, d17}, [%[in], :128], %[inc]\n"
+ "vabs.s32 q8, q8\n"
+ "vld1.32 {d18, d19}, [%[in], :128], %[inc]\n"
+ "vabs.s32 q9, q9\n"
+ "vld1.32 {d20, d21}, [%[in], :128], %[inc]\n"
+ "vabs.s32 q10, q10\n"
+ "vld1.32 {d22, d23}, [%[in], :128], %[inc]\n"
+ "vabs.s32 q11, q11\n"
+ "vmax.s32 q0, q0, q8\n"
+ "vmax.s32 q1, q1, q9\n"
+ "vmax.s32 q0, q0, q10\n"
+ "vmax.s32 q1, q1, q11\n"
+ "subs %[blk], %[blk], #4\n"
+ "bgt 1b\n"
+ "vmax.s32 q0, q0, q1\n"
+ "vsub.s32 q0, q0, q14\n"
+ "vclz.s32 q0, q0\n"
+ "vsub.s32 q0, q15, q0\n"
+ "vst1.32 {d0, d1}, [%[out], :128]\n"
+ :
+ [blk] "+r" (blk),
+ [in] "+r" (in)
+ :
+ [inc] "r" ((char *) &sb_sample_f[1][0][0] -
+ (char *) &sb_sample_f[0][0][0]),
+ [out] "r" (&scale_factor[ch][sb]),
+ [c1] "i" (1 << SCALE_OUT_BITS),
+ [c2] "i" (31 - SCALE_OUT_BITS)
+ : "d0", "d1", "d2", "d3", "d16", "d17", "d18", "d19",
+ "d20", "d21", "d22", "d23", "d24", "d25", "d26",
+ "d27", "d28", "d29", "d30", "d31", "cc", "memory");
+ }
+ }
+}
+
+int sbc_calc_scalefactors_j_neon(
+ int32_t sb_sample_f[16][2][8],
+ uint32_t scale_factor[2][8],
+ int blocks, int subbands)
+{
+ static SBC_ALIGNED int32_t joint_bits_mask[8] = {
+ 8, 4, 2, 1, 128, 64, 32, 16
+ };
+ int joint, i;
+ int32_t *in0, *in1;
+ int32_t *in = &sb_sample_f[0][0][0];
+ uint32_t *out0, *out1;
+ uint32_t *out = &scale_factor[0][0];
+ int32_t *consts = joint_bits_mask;
+
+ i = subbands;
+
+ asm volatile (
+ /*
+ * constants: q13 = (31 - SCALE_OUT_BITS), q14 = 1
+ * input: q0 = ((1 << SCALE_OUT_BITS) + 1)
+ * %[in0] - samples for channel 0
+ * %[in1] - samples for shannel 1
+ * output: q0, q1 - scale factors without joint stereo
+ * q2, q3 - scale factors with joint stereo
+ * q15 - joint stereo selection mask
+ */
+ ".macro calc_scalefactors\n"
+ "vmov.s32 q1, q0\n"
+ "vmov.s32 q2, q0\n"
+ "vmov.s32 q3, q0\n"
+ "mov %[i], %[blocks]\n"
+ "1:\n"
+ "vld1.32 {d18, d19}, [%[in1], :128], %[inc]\n"
+ "vbic.s32 q11, q9, q14\n"
+ "vld1.32 {d16, d17}, [%[in0], :128], %[inc]\n"
+ "vhadd.s32 q10, q8, q11\n"
+ "vhsub.s32 q11, q8, q11\n"
+ "vabs.s32 q8, q8\n"
+ "vabs.s32 q9, q9\n"
+ "vabs.s32 q10, q10\n"
+ "vabs.s32 q11, q11\n"
+ "vmax.s32 q0, q0, q8\n"
+ "vmax.s32 q1, q1, q9\n"
+ "vmax.s32 q2, q2, q10\n"
+ "vmax.s32 q3, q3, q11\n"
+ "subs %[i], %[i], #1\n"
+ "bgt 1b\n"
+ "vsub.s32 q0, q0, q14\n"
+ "vsub.s32 q1, q1, q14\n"
+ "vsub.s32 q2, q2, q14\n"
+ "vsub.s32 q3, q3, q14\n"
+ "vclz.s32 q0, q0\n"
+ "vclz.s32 q1, q1\n"
+ "vclz.s32 q2, q2\n"
+ "vclz.s32 q3, q3\n"
+ "vsub.s32 q0, q13, q0\n"
+ "vsub.s32 q1, q13, q1\n"
+ "vsub.s32 q2, q13, q2\n"
+ "vsub.s32 q3, q13, q3\n"
+ ".endm\n"
+ /*
+ * constants: q14 = 1
+ * input: q15 - joint stereo selection mask
+ * %[in0] - value set by calc_scalefactors macro
+ * %[in1] - value set by calc_scalefactors macro
+ */
+ ".macro update_joint_stereo_samples\n"
+ "sub %[out1], %[in1], %[inc]\n"
+ "sub %[out0], %[in0], %[inc]\n"
+ "sub %[in1], %[in1], %[inc], asl #1\n"
+ "sub %[in0], %[in0], %[inc], asl #1\n"
+ "vld1.32 {d18, d19}, [%[in1], :128]\n"
+ "vbic.s32 q11, q9, q14\n"
+ "vld1.32 {d16, d17}, [%[in0], :128]\n"
+ "vld1.32 {d2, d3}, [%[out1], :128]\n"
+ "vbic.s32 q3, q1, q14\n"
+ "vld1.32 {d0, d1}, [%[out0], :128]\n"
+ "vhsub.s32 q10, q8, q11\n"
+ "vhadd.s32 q11, q8, q11\n"
+ "vhsub.s32 q2, q0, q3\n"
+ "vhadd.s32 q3, q0, q3\n"
+ "vbif.s32 q10, q9, q15\n"
+ "vbif.s32 d22, d16, d30\n"
+ "sub %[inc], %[zero], %[inc], asl #1\n"
+ "sub %[i], %[blocks], #2\n"
+ "2:\n"
+ "vbif.s32 d23, d17, d31\n"
+ "vst1.32 {d20, d21}, [%[in1], :128], %[inc]\n"
+ "vbif.s32 d4, d2, d30\n"
+ "vld1.32 {d18, d19}, [%[in1], :128]\n"
+ "vbif.s32 d5, d3, d31\n"
+ "vst1.32 {d22, d23}, [%[in0], :128], %[inc]\n"
+ "vbif.s32 d6, d0, d30\n"
+ "vld1.32 {d16, d17}, [%[in0], :128]\n"
+ "vbif.s32 d7, d1, d31\n"
+ "vst1.32 {d4, d5}, [%[out1], :128], %[inc]\n"
+ "vbic.s32 q11, q9, q14\n"
+ "vld1.32 {d2, d3}, [%[out1], :128]\n"
+ "vst1.32 {d6, d7}, [%[out0], :128], %[inc]\n"
+ "vbic.s32 q3, q1, q14\n"
+ "vld1.32 {d0, d1}, [%[out0], :128]\n"
+ "vhsub.s32 q10, q8, q11\n"
+ "vhadd.s32 q11, q8, q11\n"
+ "vhsub.s32 q2, q0, q3\n"
+ "vhadd.s32 q3, q0, q3\n"
+ "vbif.s32 q10, q9, q15\n"
+ "vbif.s32 d22, d16, d30\n"
+ "subs %[i], %[i], #2\n"
+ "bgt 2b\n"
+ "sub %[inc], %[zero], %[inc], asr #1\n"
+ "vbif.s32 d23, d17, d31\n"
+ "vst1.32 {d20, d21}, [%[in1], :128]\n"
+ "vbif.s32 q2, q1, q15\n"
+ "vst1.32 {d22, d23}, [%[in0], :128]\n"
+ "vbif.s32 q3, q0, q15\n"
+ "vst1.32 {d4, d5}, [%[out1], :128]\n"
+ "vst1.32 {d6, d7}, [%[out0], :128]\n"
+ ".endm\n"
+
+ "vmov.s32 q14, #1\n"
+ "vmov.s32 q13, %[c2]\n"
+
+ "cmp %[i], #4\n"
+ "bne 8f\n"
+
+ "4:\n" /* 4 subbands */
+ "add %[in0], %[in], #0\n"
+ "add %[in1], %[in], #32\n"
+ "add %[out0], %[out], #0\n"
+ "add %[out1], %[out], #32\n"
+ "vmov.s32 q0, %[c1]\n"
+ "vadd.s32 q0, q0, q14\n"
+
+ "calc_scalefactors\n"
+
+ /* check whether to use joint stereo for subbands 0, 1, 2 */
+ "vadd.s32 q15, q0, q1\n"
+ "vadd.s32 q9, q2, q3\n"
+ "vmov.s32 d31[1], %[zero]\n" /* last subband -> no joint */
+ "vld1.32 {d16, d17}, [%[consts], :128]!\n"
+ "vcgt.s32 q15, q15, q9\n"
+
+ /* calculate and save to memory 'joint' variable */
+ /* update and save scale factors to memory */
+ " vand.s32 q8, q8, q15\n"
+ "vbit.s32 q0, q2, q15\n"
+ " vpadd.s32 d16, d16, d17\n"
+ "vbit.s32 q1, q3, q15\n"
+ " vpadd.s32 d16, d16, d16\n"
+ "vst1.32 {d0, d1}, [%[out0], :128]\n"
+ "vst1.32 {d2, d3}, [%[out1], :128]\n"
+ " vst1.32 {d16[0]}, [%[joint]]\n"
+
+ "update_joint_stereo_samples\n"
+ "b 9f\n"
+
+ "8:\n" /* 8 subbands */
+ "add %[in0], %[in], #16\n\n"
+ "add %[in1], %[in], #48\n"
+ "add %[out0], %[out], #16\n\n"
+ "add %[out1], %[out], #48\n"
+ "vmov.s32 q0, %[c1]\n"
+ "vadd.s32 q0, q0, q14\n"
+
+ "calc_scalefactors\n"
+
+ /* check whether to use joint stereo for subbands 4, 5, 6 */
+ "vadd.s32 q15, q0, q1\n"
+ "vadd.s32 q9, q2, q3\n"
+ "vmov.s32 d31[1], %[zero]\n" /* last subband -> no joint */
+ "vld1.32 {d16, d17}, [%[consts], :128]!\n"
+ "vcgt.s32 q15, q15, q9\n"
+
+ /* calculate part of 'joint' variable and save it to d24 */
+ /* update and save scale factors to memory */
+ " vand.s32 q8, q8, q15\n"
+ "vbit.s32 q0, q2, q15\n"
+ " vpadd.s32 d16, d16, d17\n"
+ "vbit.s32 q1, q3, q15\n"
+ "vst1.32 {d0, d1}, [%[out0], :128]\n"
+ "vst1.32 {d2, d3}, [%[out1], :128]\n"
+ " vpadd.s32 d24, d16, d16\n"
+
+ "update_joint_stereo_samples\n"
+
+ "add %[in0], %[in], #0\n"
+ "add %[in1], %[in], #32\n"
+ "add %[out0], %[out], #0\n\n"
+ "add %[out1], %[out], #32\n"
+ "vmov.s32 q0, %[c1]\n"
+ "vadd.s32 q0, q0, q14\n"
+
+ "calc_scalefactors\n"
+
+ /* check whether to use joint stereo for subbands 0, 1, 2, 3 */
+ "vadd.s32 q15, q0, q1\n"
+ "vadd.s32 q9, q2, q3\n"
+ "vld1.32 {d16, d17}, [%[consts], :128]!\n"
+ "vcgt.s32 q15, q15, q9\n"
+
+ /* combine last part of 'joint' with d24 and save to memory */
+ /* update and save scale factors to memory */
+ " vand.s32 q8, q8, q15\n"
+ "vbit.s32 q0, q2, q15\n"
+ " vpadd.s32 d16, d16, d17\n"
+ "vbit.s32 q1, q3, q15\n"
+ " vpadd.s32 d16, d16, d16\n"
+ "vst1.32 {d0, d1}, [%[out0], :128]\n"
+ " vadd.s32 d16, d16, d24\n"
+ "vst1.32 {d2, d3}, [%[out1], :128]\n"
+ " vst1.32 {d16[0]}, [%[joint]]\n"
+
+ "update_joint_stereo_samples\n"
+ "9:\n"
+ ".purgem calc_scalefactors\n"
+ ".purgem update_joint_stereo_samples\n"
+ :
+ [i] "+&r" (i),
+ [in] "+&r" (in),
+ [in0] "=&r" (in0),
+ [in1] "=&r" (in1),
+ [out] "+&r" (out),
+ [out0] "=&r" (out0),
+ [out1] "=&r" (out1),
+ [consts] "+&r" (consts)
+ :
+ [inc] "r" ((char *) &sb_sample_f[1][0][0] -
+ (char *) &sb_sample_f[0][0][0]),
+ [blocks] "r" (blocks),
+ [joint] "r" (&joint),
+ [c1] "i" (1 << SCALE_OUT_BITS),
+ [c2] "i" (31 - SCALE_OUT_BITS),
+ [zero] "r" (0)
+ : "d0", "d1", "d2", "d3", "d4", "d5", "d6", "d7",
+ "d16", "d17", "d18", "d19", "d20", "d21", "d22",
+ "d23", "d24", "d25", "d26", "d27", "d28", "d29",
+ "d30", "d31", "cc", "memory");
+
+ return joint;
+}
+
+#define PERM_BE(a, b, c, d) { \
+ (a * 2) + 1, (a * 2) + 0, \
+ (b * 2) + 1, (b * 2) + 0, \
+ (c * 2) + 1, (c * 2) + 0, \
+ (d * 2) + 1, (d * 2) + 0 \
+ }
+#define PERM_LE(a, b, c, d) { \
+ (a * 2) + 0, (a * 2) + 1, \
+ (b * 2) + 0, (b * 2) + 1, \
+ (c * 2) + 0, (c * 2) + 1, \
+ (d * 2) + 0, (d * 2) + 1 \
+ }
+
+static SBC_ALWAYS_INLINE int sbc_enc_process_input_4s_neon_internal(
+ int position,
+ const uint8_t *pcm, int16_t X[2][SBC_X_BUFFER_SIZE],
+ int nsamples, int nchannels, int big_endian)
+{
+ static SBC_ALIGNED uint8_t perm_be[2][8] = {
+ PERM_BE(7, 3, 6, 4),
+ PERM_BE(0, 2, 1, 5)
+ };
+ static SBC_ALIGNED uint8_t perm_le[2][8] = {
+ PERM_LE(7, 3, 6, 4),
+ PERM_LE(0, 2, 1, 5)
+ };
+ /* handle X buffer wraparound */
+ if (position < nsamples) {
+ int16_t *dst = &X[0][SBC_X_BUFFER_SIZE - 40];
+ int16_t *src = &X[0][position];
+ asm volatile (
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0}, [%[src], :64]!\n"
+ "vst1.16 {d0}, [%[dst], :64]!\n"
+ :
+ [dst] "+r" (dst),
+ [src] "+r" (src)
+ : : "memory", "d0", "d1", "d2", "d3");
+ if (nchannels > 1) {
+ dst = &X[1][SBC_X_BUFFER_SIZE - 40];
+ src = &X[1][position];
+ asm volatile (
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0}, [%[src], :64]!\n"
+ "vst1.16 {d0}, [%[dst], :64]!\n"
+ :
+ [dst] "+r" (dst),
+ [src] "+r" (src)
+ : : "memory", "d0", "d1", "d2", "d3");
+ }
+ position = SBC_X_BUFFER_SIZE - 40;
+ }
+
+ if ((nchannels > 1) && ((uintptr_t)pcm & 1)) {
+ /* poor 'pcm' alignment */
+ int16_t *x = &X[0][position];
+ int16_t *y = &X[1][position];
+ asm volatile (
+ "vld1.8 {d0, d1}, [%[perm], :128]\n"
+ "1:\n"
+ "sub %[x], %[x], #16\n"
+ "sub %[y], %[y], #16\n"
+ "sub %[position], %[position], #8\n"
+ "vld1.8 {d4, d5}, [%[pcm]]!\n"
+ "vuzp.16 d4, d5\n"
+ "vld1.8 {d20, d21}, [%[pcm]]!\n"
+ "vuzp.16 d20, d21\n"
+ "vswp d5, d20\n"
+ "vtbl.8 d16, {d4, d5}, d0\n"
+ "vtbl.8 d17, {d4, d5}, d1\n"
+ "vtbl.8 d18, {d20, d21}, d0\n"
+ "vtbl.8 d19, {d20, d21}, d1\n"
+ "vst1.16 {d16, d17}, [%[x], :128]\n"
+ "vst1.16 {d18, d19}, [%[y], :128]\n"
+ "subs %[nsamples], %[nsamples], #8\n"
+ "bgt 1b\n"
+ :
+ [x] "+r" (x),
+ [y] "+r" (y),
+ [pcm] "+r" (pcm),
+ [nsamples] "+r" (nsamples),
+ [position] "+r" (position)
+ :
+ [perm] "r" (big_endian ? perm_be : perm_le)
+ : "cc", "memory", "d0", "d1", "d2", "d3", "d4",
+ "d5", "d6", "d7", "d16", "d17", "d18", "d19",
+ "d20", "d21", "d22", "d23");
+ } else if (nchannels > 1) {
+ /* proper 'pcm' alignment */
+ int16_t *x = &X[0][position];
+ int16_t *y = &X[1][position];
+ asm volatile (
+ "vld1.8 {d0, d1}, [%[perm], :128]\n"
+ "1:\n"
+ "sub %[x], %[x], #16\n"
+ "sub %[y], %[y], #16\n"
+ "sub %[position], %[position], #8\n"
+ "vld2.16 {d4, d5}, [%[pcm]]!\n"
+ "vld2.16 {d20, d21}, [%[pcm]]!\n"
+ "vswp d5, d20\n"
+ "vtbl.8 d16, {d4, d5}, d0\n"
+ "vtbl.8 d17, {d4, d5}, d1\n"
+ "vtbl.8 d18, {d20, d21}, d0\n"
+ "vtbl.8 d19, {d20, d21}, d1\n"
+ "vst1.16 {d16, d17}, [%[x], :128]\n"
+ "vst1.16 {d18, d19}, [%[y], :128]\n"
+ "subs %[nsamples], %[nsamples], #8\n"
+ "bgt 1b\n"
+ :
+ [x] "+r" (x),
+ [y] "+r" (y),
+ [pcm] "+r" (pcm),
+ [nsamples] "+r" (nsamples),
+ [position] "+r" (position)
+ :
+ [perm] "r" (big_endian ? perm_be : perm_le)
+ : "cc", "memory", "d0", "d1", "d2", "d3", "d4",
+ "d5", "d6", "d7", "d16", "d17", "d18", "d19",
+ "d20", "d21", "d22", "d23");
+ } else {
+ int16_t *x = &X[0][position];
+ asm volatile (
+ "vld1.8 {d0, d1}, [%[perm], :128]\n"
+ "1:\n"
+ "sub %[x], %[x], #16\n"
+ "sub %[position], %[position], #8\n"
+ "vld1.8 {d4, d5}, [%[pcm]]!\n"
+ "vtbl.8 d16, {d4, d5}, d0\n"
+ "vtbl.8 d17, {d4, d5}, d1\n"
+ "vst1.16 {d16, d17}, [%[x], :128]\n"
+ "subs %[nsamples], %[nsamples], #8\n"
+ "bgt 1b\n"
+ :
+ [x] "+r" (x),
+ [pcm] "+r" (pcm),
+ [nsamples] "+r" (nsamples),
+ [position] "+r" (position)
+ :
+ [perm] "r" (big_endian ? perm_be : perm_le)
+ : "cc", "memory", "d0", "d1", "d2", "d3", "d4",
+ "d5", "d6", "d7", "d16", "d17", "d18", "d19");
+ }
+ return position;
+}
+
+static SBC_ALWAYS_INLINE int sbc_enc_process_input_8s_neon_internal(
+ int position,
+ const uint8_t *pcm, int16_t X[2][SBC_X_BUFFER_SIZE],
+ int nsamples, int nchannels, int big_endian)
+{
+ static SBC_ALIGNED uint8_t perm_be[4][8] = {
+ PERM_BE(15, 7, 14, 8),
+ PERM_BE(13, 9, 12, 10),
+ PERM_BE(11, 3, 6, 0),
+ PERM_BE(5, 1, 4, 2)
+ };
+ static SBC_ALIGNED uint8_t perm_le[4][8] = {
+ PERM_LE(15, 7, 14, 8),
+ PERM_LE(13, 9, 12, 10),
+ PERM_LE(11, 3, 6, 0),
+ PERM_LE(5, 1, 4, 2)
+ };
+ /* handle X buffer wraparound */
+ if (position < nsamples) {
+ int16_t *dst = &X[0][SBC_X_BUFFER_SIZE - 72];
+ int16_t *src = &X[0][position];
+ asm volatile (
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1}, [%[dst], :128]!\n"
+ :
+ [dst] "+r" (dst),
+ [src] "+r" (src)
+ : : "memory", "d0", "d1", "d2", "d3");
+ if (nchannels > 1) {
+ dst = &X[1][SBC_X_BUFFER_SIZE - 72];
+ src = &X[1][position];
+ asm volatile (
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1, d2, d3}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1, d2, d3}, [%[dst], :128]!\n"
+ "vld1.16 {d0, d1}, [%[src], :128]!\n"
+ "vst1.16 {d0, d1}, [%[dst], :128]!\n"
+ :
+ [dst] "+r" (dst),
+ [src] "+r" (src)
+ : : "memory", "d0", "d1", "d2", "d3");
+ }
+ position = SBC_X_BUFFER_SIZE - 72;
+ }
+
+ if ((nchannels > 1) && ((uintptr_t)pcm & 1)) {
+ /* poor 'pcm' alignment */
+ int16_t *x = &X[0][position];
+ int16_t *y = &X[1][position];
+ asm volatile (
+ "vld1.8 {d0, d1, d2, d3}, [%[perm], :128]\n"
+ "1:\n"
+ "sub %[x], %[x], #32\n"
+ "sub %[y], %[y], #32\n"
+ "sub %[position], %[position], #16\n"
+ "vld1.8 {d4, d5, d6, d7}, [%[pcm]]!\n"
+ "vuzp.16 q2, q3\n"
+ "vld1.8 {d20, d21, d22, d23}, [%[pcm]]!\n"
+ "vuzp.16 q10, q11\n"
+ "vswp q3, q10\n"
+ "vtbl.8 d16, {d4, d5, d6, d7}, d0\n"
+ "vtbl.8 d17, {d4, d5, d6, d7}, d1\n"
+ "vtbl.8 d18, {d4, d5, d6, d7}, d2\n"
+ "vtbl.8 d19, {d4, d5, d6, d7}, d3\n"
+ "vst1.16 {d16, d17, d18, d19}, [%[x], :128]\n"
+ "vtbl.8 d16, {d20, d21, d22, d23}, d0\n"
+ "vtbl.8 d17, {d20, d21, d22, d23}, d1\n"
+ "vtbl.8 d18, {d20, d21, d22, d23}, d2\n"
+ "vtbl.8 d19, {d20, d21, d22, d23}, d3\n"
+ "vst1.16 {d16, d17, d18, d19}, [%[y], :128]\n"
+ "subs %[nsamples], %[nsamples], #16\n"
+ "bgt 1b\n"
+ :
+ [x] "+r" (x),
+ [y] "+r" (y),
+ [pcm] "+r" (pcm),
+ [nsamples] "+r" (nsamples),
+ [position] "+r" (position)
+ :
+ [perm] "r" (big_endian ? perm_be : perm_le)
+ : "cc", "memory", "d0", "d1", "d2", "d3", "d4",
+ "d5", "d6", "d7", "d16", "d17", "d18", "d19",
+ "d20", "d21", "d22", "d23");
+ } else if (nchannels > 1) {
+ /* proper 'pcm' alignment */
+ int16_t *x = &X[0][position];
+ int16_t *y = &X[1][position];
+ asm volatile (
+ "vld1.8 {d0, d1, d2, d3}, [%[perm], :128]\n"
+ "1:\n"
+ "sub %[x], %[x], #32\n"
+ "sub %[y], %[y], #32\n"
+ "sub %[position], %[position], #16\n"
+ "vld2.16 {d4, d5, d6, d7}, [%[pcm]]!\n"
+ "vld2.16 {d20, d21, d22, d23}, [%[pcm]]!\n"
+ "vswp q3, q10\n"
+ "vtbl.8 d16, {d4, d5, d6, d7}, d0\n"
+ "vtbl.8 d17, {d4, d5, d6, d7}, d1\n"
+ "vtbl.8 d18, {d4, d5, d6, d7}, d2\n"
+ "vtbl.8 d19, {d4, d5, d6, d7}, d3\n"
+ "vst1.16 {d16, d17, d18, d19}, [%[x], :128]\n"
+ "vtbl.8 d16, {d20, d21, d22, d23}, d0\n"
+ "vtbl.8 d17, {d20, d21, d22, d23}, d1\n"
+ "vtbl.8 d18, {d20, d21, d22, d23}, d2\n"
+ "vtbl.8 d19, {d20, d21, d22, d23}, d3\n"
+ "vst1.16 {d16, d17, d18, d19}, [%[y], :128]\n"
+ "subs %[nsamples], %[nsamples], #16\n"
+ "bgt 1b\n"
+ :
+ [x] "+r" (x),
+ [y] "+r" (y),
+ [pcm] "+r" (pcm),
+ [nsamples] "+r" (nsamples),
+ [position] "+r" (position)
+ :
+ [perm] "r" (big_endian ? perm_be : perm_le)
+ : "cc", "memory", "d0", "d1", "d2", "d3", "d4",
+ "d5", "d6", "d7", "d16", "d17", "d18", "d19",
+ "d20", "d21", "d22", "d23");
+ } else {
+ int16_t *x = &X[0][position];
+ asm volatile (
+ "vld1.8 {d0, d1, d2, d3}, [%[perm], :128]\n"
+ "1:\n"
+ "sub %[x], %[x], #32\n"
+ "sub %[position], %[position], #16\n"
+ "vld1.8 {d4, d5, d6, d7}, [%[pcm]]!\n"
+ "vtbl.8 d16, {d4, d5, d6, d7}, d0\n"
+ "vtbl.8 d17, {d4, d5, d6, d7}, d1\n"
+ "vtbl.8 d18, {d4, d5, d6, d7}, d2\n"
+ "vtbl.8 d19, {d4, d5, d6, d7}, d3\n"
+ "vst1.16 {d16, d17, d18, d19}, [%[x], :128]\n"
+ "subs %[nsamples], %[nsamples], #16\n"
+ "bgt 1b\n"
+ :
+ [x] "+r" (x),
+ [pcm] "+r" (pcm),
+ [nsamples] "+r" (nsamples),
+ [position] "+r" (position)
+ :
+ [perm] "r" (big_endian ? perm_be : perm_le)
+ : "cc", "memory", "d0", "d1", "d2", "d3", "d4",
+ "d5", "d6", "d7", "d16", "d17", "d18", "d19");
+ }
+ return position;
+}
+
+#undef PERM_BE
+#undef PERM_LE
+
+static int sbc_enc_process_input_4s_be_neon(int position, const uint8_t *pcm,
+ int16_t X[2][SBC_X_BUFFER_SIZE],
+ int nsamples, int nchannels)
+{
+ return sbc_enc_process_input_4s_neon_internal(
+ position, pcm, X, nsamples, nchannels, 1);
+}
+
+static int sbc_enc_process_input_4s_le_neon(int position, const uint8_t *pcm,
+ int16_t X[2][SBC_X_BUFFER_SIZE],
+ int nsamples, int nchannels)
+{
+ return sbc_enc_process_input_4s_neon_internal(
+ position, pcm, X, nsamples, nchannels, 0);
+}
+
+static int sbc_enc_process_input_8s_be_neon(int position, const uint8_t *pcm,
+ int16_t X[2][SBC_X_BUFFER_SIZE],
+ int nsamples, int nchannels)
+{
+ return sbc_enc_process_input_8s_neon_internal(
+ position, pcm, X, nsamples, nchannels, 1);
+}
+
+static int sbc_enc_process_input_8s_le_neon(int position, const uint8_t *pcm,
+ int16_t X[2][SBC_X_BUFFER_SIZE],
+ int nsamples, int nchannels)
+{
+ return sbc_enc_process_input_8s_neon_internal(
+ position, pcm, X, nsamples, nchannels, 0);
+}
+
+void sbc_init_primitives_neon(struct sbc_encoder_state *state)
+{
+ state->sbc_analyze_4b_4s = sbc_analyze_4b_4s_neon;
+ state->sbc_analyze_4b_8s = sbc_analyze_4b_8s_neon;
+ state->sbc_calc_scalefactors = sbc_calc_scalefactors_neon;
+ state->sbc_calc_scalefactors_j = sbc_calc_scalefactors_j_neon;
+ state->sbc_enc_process_input_4s_le = sbc_enc_process_input_4s_le_neon;
+ state->sbc_enc_process_input_4s_be = sbc_enc_process_input_4s_be_neon;
+ state->sbc_enc_process_input_8s_le = sbc_enc_process_input_8s_le_neon;
+ state->sbc_enc_process_input_8s_be = sbc_enc_process_input_8s_be_neon;
+ state->implementation_info = "NEON";
+}
+
+#endif
diff --git a/src/modules/bluetooth/sbc_primitives_neon.h b/src/modules/bluetooth/sbc/sbc_primitives_neon.h
index 30766ed8..ea3da06a 100644
--- a/src/modules/bluetooth/sbc_primitives_neon.h
+++ b/src/modules/bluetooth/sbc/sbc_primitives_neon.h
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
*
diff --git a/src/modules/bluetooth/sbc_tables.h b/src/modules/bluetooth/sbc/sbc_tables.h
index 0057c73f..28c0d54b 100644
--- a/src/modules/bluetooth/sbc_tables.h
+++ b/src/modules/bluetooth/sbc/sbc_tables.h
@@ -2,7 +2,8 @@
*
* Bluetooth low-complexity, subband codec (SBC) library
*
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
+ * Copyright (C) 2008-2010 Nokia Corporation
+ * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
* Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
* Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
*
diff --git a/src/modules/bluetooth/sbc_primitives_neon.c b/src/modules/bluetooth/sbc_primitives_neon.c
deleted file mode 100644
index f1bc7b48..00000000
--- a/src/modules/bluetooth/sbc_primitives_neon.c
+++ /dev/null
@@ -1,246 +0,0 @@
-/*
- *
- * Bluetooth low-complexity, subband codec (SBC) library
- *
- * Copyright (C) 2004-2009 Marcel Holtmann <marcel@holtmann.org>
- * Copyright (C) 2004-2005 Henryk Ploetz <henryk@ploetzli.ch>
- * Copyright (C) 2005-2006 Brad Midgley <bmidgley@xmission.com>
- *
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
-
-#include <stdint.h>
-#include <limits.h>
-#include "sbc.h"
-#include "sbc_math.h"
-#include "sbc_tables.h"
-
-#include "sbc_primitives_neon.h"
-
-/*
- * ARM NEON optimizations
- */
-
-#ifdef SBC_BUILD_WITH_NEON_SUPPORT
-
-static inline void _sbc_analyze_four_neon(const int16_t *in, int32_t *out,
- const FIXED_T *consts)
-{
- /* TODO: merge even and odd cases (or even merge all four calls to this
- * function) in order to have only aligned reads from 'in' array
- * and reduce number of load instructions */
- asm volatile (
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmull.s16 q0, d4, d8\n"
- "vld1.16 {d6, d7}, [%0, :64]!\n"
- "vmull.s16 q1, d5, d9\n"
- "vld1.16 {d10, d11}, [%1, :128]!\n"
-
- "vmlal.s16 q0, d6, d10\n"
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vmlal.s16 q1, d7, d11\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmlal.s16 q0, d4, d8\n"
- "vld1.16 {d6, d7}, [%0, :64]!\n"
- "vmlal.s16 q1, d5, d9\n"
- "vld1.16 {d10, d11}, [%1, :128]!\n"
-
- "vmlal.s16 q0, d6, d10\n"
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vmlal.s16 q1, d7, d11\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmlal.s16 q0, d4, d8\n"
- "vmlal.s16 q1, d5, d9\n"
-
- "vpadd.s32 d0, d0, d1\n"
- "vpadd.s32 d1, d2, d3\n"
-
- "vrshrn.s32 d0, q0, %3\n"
-
- "vld1.16 {d2, d3, d4, d5}, [%1, :128]!\n"
-
- "vdup.i32 d1, d0[1]\n" /* TODO: can be eliminated */
- "vdup.i32 d0, d0[0]\n" /* TODO: can be eliminated */
-
- "vmull.s16 q3, d2, d0\n"
- "vmull.s16 q4, d3, d0\n"
- "vmlal.s16 q3, d4, d1\n"
- "vmlal.s16 q4, d5, d1\n"
-
- "vpadd.s32 d0, d6, d7\n" /* TODO: can be eliminated */
- "vpadd.s32 d1, d8, d9\n" /* TODO: can be eliminated */
-
- "vst1.32 {d0, d1}, [%2, :128]\n"
- : "+r" (in), "+r" (consts)
- : "r" (out),
- "i" (SBC_PROTO_FIXED4_SCALE)
- : "memory",
- "d0", "d1", "d2", "d3", "d4", "d5",
- "d6", "d7", "d8", "d9", "d10", "d11");
-}
-
-static inline void _sbc_analyze_eight_neon(const int16_t *in, int32_t *out,
- const FIXED_T *consts)
-{
- /* TODO: merge even and odd cases (or even merge all four calls to this
- * function) in order to have only aligned reads from 'in' array
- * and reduce number of load instructions */
- asm volatile (
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmull.s16 q6, d4, d8\n"
- "vld1.16 {d6, d7}, [%0, :64]!\n"
- "vmull.s16 q7, d5, d9\n"
- "vld1.16 {d10, d11}, [%1, :128]!\n"
- "vmull.s16 q8, d6, d10\n"
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vmull.s16 q9, d7, d11\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmlal.s16 q6, d4, d8\n"
- "vld1.16 {d6, d7}, [%0, :64]!\n"
- "vmlal.s16 q7, d5, d9\n"
- "vld1.16 {d10, d11}, [%1, :128]!\n"
- "vmlal.s16 q8, d6, d10\n"
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vmlal.s16 q9, d7, d11\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmlal.s16 q6, d4, d8\n"
- "vld1.16 {d6, d7}, [%0, :64]!\n"
- "vmlal.s16 q7, d5, d9\n"
- "vld1.16 {d10, d11}, [%1, :128]!\n"
- "vmlal.s16 q8, d6, d10\n"
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vmlal.s16 q9, d7, d11\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmlal.s16 q6, d4, d8\n"
- "vld1.16 {d6, d7}, [%0, :64]!\n"
- "vmlal.s16 q7, d5, d9\n"
- "vld1.16 {d10, d11}, [%1, :128]!\n"
- "vmlal.s16 q8, d6, d10\n"
- "vld1.16 {d4, d5}, [%0, :64]!\n"
- "vmlal.s16 q9, d7, d11\n"
- "vld1.16 {d8, d9}, [%1, :128]!\n"
-
- "vmlal.s16 q6, d4, d8\n"
- "vld1.16 {d6, d7}, [%0, :64]!\n"
- "vmlal.s16 q7, d5, d9\n"
- "vld1.16 {d10, d11}, [%1, :128]!\n"
-
- "vmlal.s16 q8, d6, d10\n"
- "vmlal.s16 q9, d7, d11\n"
-
- "vpadd.s32 d0, d12, d13\n"
- "vpadd.s32 d1, d14, d15\n"
- "vpadd.s32 d2, d16, d17\n"
- "vpadd.s32 d3, d18, d19\n"
-
- "vrshr.s32 q0, q0, %3\n"
- "vrshr.s32 q1, q1, %3\n"
- "vmovn.s32 d0, q0\n"
- "vmovn.s32 d1, q1\n"
-
- "vdup.i32 d3, d1[1]\n" /* TODO: can be eliminated */
- "vdup.i32 d2, d1[0]\n" /* TODO: can be eliminated */
- "vdup.i32 d1, d0[1]\n" /* TODO: can be eliminated */
- "vdup.i32 d0, d0[0]\n" /* TODO: can be eliminated */
-
- "vld1.16 {d4, d5}, [%1, :128]!\n"
- "vmull.s16 q6, d4, d0\n"
- "vld1.16 {d6, d7}, [%1, :128]!\n"
- "vmull.s16 q7, d5, d0\n"
- "vmull.s16 q8, d6, d0\n"
- "vmull.s16 q9, d7, d0\n"
-
- "vld1.16 {d4, d5}, [%1, :128]!\n"
- "vmlal.s16 q6, d4, d1\n"
- "vld1.16 {d6, d7}, [%1, :128]!\n"
- "vmlal.s16 q7, d5, d1\n"
- "vmlal.s16 q8, d6, d1\n"
- "vmlal.s16 q9, d7, d1\n"
-
- "vld1.16 {d4, d5}, [%1, :128]!\n"
- "vmlal.s16 q6, d4, d2\n"
- "vld1.16 {d6, d7}, [%1, :128]!\n"
- "vmlal.s16 q7, d5, d2\n"
- "vmlal.s16 q8, d6, d2\n"
- "vmlal.s16 q9, d7, d2\n"
-
- "vld1.16 {d4, d5}, [%1, :128]!\n"
- "vmlal.s16 q6, d4, d3\n"
- "vld1.16 {d6, d7}, [%1, :128]!\n"
- "vmlal.s16 q7, d5, d3\n"
- "vmlal.s16 q8, d6, d3\n"
- "vmlal.s16 q9, d7, d3\n"
-
- "vpadd.s32 d0, d12, d13\n" /* TODO: can be eliminated */
- "vpadd.s32 d1, d14, d15\n" /* TODO: can be eliminated */
- "vpadd.s32 d2, d16, d17\n" /* TODO: can be eliminated */
- "vpadd.s32 d3, d18, d19\n" /* TODO: can be eliminated */
-
- "vst1.32 {d0, d1, d2, d3}, [%2, :128]\n"
- : "+r" (in), "+r" (consts)
- : "r" (out),
- "i" (SBC_PROTO_FIXED8_SCALE)
- : "memory",
- "d0", "d1", "d2", "d3", "d4", "d5",
- "d6", "d7", "d8", "d9", "d10", "d11",
- "d12", "d13", "d14", "d15", "d16", "d17",
- "d18", "d19");
-}
-
-static inline void sbc_analyze_4b_4s_neon(int16_t *x,
- int32_t *out, int out_stride)
-{
- /* Analyze blocks */
- _sbc_analyze_four_neon(x + 12, out, analysis_consts_fixed4_simd_odd);
- out += out_stride;
- _sbc_analyze_four_neon(x + 8, out, analysis_consts_fixed4_simd_even);
- out += out_stride;
- _sbc_analyze_four_neon(x + 4, out, analysis_consts_fixed4_simd_odd);
- out += out_stride;
- _sbc_analyze_four_neon(x + 0, out, analysis_consts_fixed4_simd_even);
-}
-
-static inline void sbc_analyze_4b_8s_neon(int16_t *x,
- int32_t *out, int out_stride)
-{
- /* Analyze blocks */
- _sbc_analyze_eight_neon(x + 24, out, analysis_consts_fixed8_simd_odd);
- out += out_stride;
- _sbc_analyze_eight_neon(x + 16, out, analysis_consts_fixed8_simd_even);
- out += out_stride;
- _sbc_analyze_eight_neon(x + 8, out, analysis_consts_fixed8_simd_odd);
- out += out_stride;
- _sbc_analyze_eight_neon(x + 0, out, analysis_consts_fixed8_simd_even);
-}
-
-void sbc_init_primitives_neon(struct sbc_encoder_state *state)
-{
- state->sbc_analyze_4b_4s = sbc_analyze_4b_4s_neon;
- state->sbc_analyze_4b_8s = sbc_analyze_4b_8s_neon;
- state->implementation_info = "NEON";
-}
-
-#endif
diff --git a/src/modules/dbus/iface-card-profile.c b/src/modules/dbus/iface-card-profile.c
new file mode 100644
index 00000000..004e2e88
--- /dev/null
+++ b/src/modules/dbus/iface-card-profile.c
@@ -0,0 +1,228 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+
+#include "iface-card-profile.h"
+
+#define OBJECT_NAME "profile"
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_description(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sinks(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sources(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_priority(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+struct pa_dbusiface_card_profile {
+ uint32_t index;
+ pa_card_profile *profile;
+ char *path;
+ pa_dbus_protocol *dbus_protocol;
+};
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_NAME,
+ PROPERTY_HANDLER_DESCRIPTION,
+ PROPERTY_HANDLER_SINKS,
+ PROPERTY_HANDLER_SOURCES,
+ PROPERTY_HANDLER_PRIORITY,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_get_name, .set_cb = NULL },
+ [PROPERTY_HANDLER_DESCRIPTION] = { .property_name = "Description", .type = "s", .get_cb = handle_get_description, .set_cb = NULL },
+ [PROPERTY_HANDLER_SINKS] = { .property_name = "Sinks", .type = "u", .get_cb = handle_get_sinks, .set_cb = NULL },
+ [PROPERTY_HANDLER_SOURCES] = { .property_name = "Sources", .type = "u", .get_cb = handle_get_sources, .set_cb = NULL },
+ [PROPERTY_HANDLER_PRIORITY] = { .property_name = "Priority", .type = "u", .get_cb = handle_get_priority, .set_cb = NULL },
+};
+
+static pa_dbus_interface_info profile_interface_info = {
+ .name = PA_DBUSIFACE_CARD_PROFILE_INTERFACE,
+ .method_handlers = NULL,
+ .n_method_handlers = 0,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = NULL,
+ .n_signals = 0
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card_profile *p = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &p->index);
+}
+
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card_profile *p = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &p->profile->name);
+}
+
+static void handle_get_description(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card_profile *p = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &p->profile->description);
+}
+
+static void handle_get_sinks(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card_profile *p = userdata;
+ dbus_uint32_t sinks = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ sinks = p->profile->n_sinks;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sinks);
+}
+
+static void handle_get_sources(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card_profile *p = userdata;
+ dbus_uint32_t sources = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ sources = p->profile->n_sources;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sources);
+}
+
+static void handle_get_priority(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card_profile *p = userdata;
+ dbus_uint32_t priority = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ priority = p->profile->priority;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &priority);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card_profile *p = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t sinks = 0;
+ dbus_uint32_t sources = 0;
+ dbus_uint32_t priority = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ sinks = p->profile->n_sinks;
+ sources = p->profile->n_sources;
+ priority = p->profile->priority;
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &p->index);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &p->profile->name);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DESCRIPTION].property_name, DBUS_TYPE_STRING, &p->profile->description);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SINKS].property_name, DBUS_TYPE_UINT32, &sinks);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SOURCES].property_name, DBUS_TYPE_UINT32, &sources);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PRIORITY].property_name, DBUS_TYPE_UINT32, &priority);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+pa_dbusiface_card_profile *pa_dbusiface_card_profile_new(
+ pa_dbusiface_card *card,
+ pa_core *core,
+ pa_card_profile *profile,
+ uint32_t idx) {
+ pa_dbusiface_card_profile *p = NULL;
+
+ pa_assert(card);
+ pa_assert(core);
+ pa_assert(profile);
+
+ p = pa_xnew(pa_dbusiface_card_profile, 1);
+ p->index = idx;
+ p->profile = profile;
+ p->path = pa_sprintf_malloc("%s/%s%u", pa_dbusiface_card_get_path(card), OBJECT_NAME, idx);
+ p->dbus_protocol = pa_dbus_protocol_get(core);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(p->dbus_protocol, p->path, &profile_interface_info, p) >= 0);
+
+ return p;
+}
+
+void pa_dbusiface_card_profile_free(pa_dbusiface_card_profile *p) {
+ pa_assert(p);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(p->dbus_protocol, p->path, profile_interface_info.name) >= 0);
+
+ pa_dbus_protocol_unref(p->dbus_protocol);
+
+ pa_xfree(p->path);
+ pa_xfree(p);
+}
+
+const char *pa_dbusiface_card_profile_get_path(pa_dbusiface_card_profile *p) {
+ pa_assert(p);
+
+ return p->path;
+}
+
+const char *pa_dbusiface_card_profile_get_name(pa_dbusiface_card_profile *p) {
+ pa_assert(p);
+
+ return p->profile->name;
+}
diff --git a/src/modules/dbus/iface-card-profile.h b/src/modules/dbus/iface-card-profile.h
new file mode 100644
index 00000000..8ffb4b9c
--- /dev/null
+++ b/src/modules/dbus/iface-card-profile.h
@@ -0,0 +1,49 @@
+#ifndef foodbusifacecardprofilehfoo
+#define foodbusifacecardprofilehfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.CardProfile.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the CardProfile interface
+ * documentation.
+ */
+
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-card.h"
+
+#define PA_DBUSIFACE_CARD_PROFILE_INTERFACE PA_DBUS_CORE_INTERFACE ".CardProfile"
+
+typedef struct pa_dbusiface_card_profile pa_dbusiface_card_profile;
+
+pa_dbusiface_card_profile *pa_dbusiface_card_profile_new(
+ pa_dbusiface_card *card,
+ pa_core *core,
+ pa_card_profile *profile,
+ uint32_t idx);
+void pa_dbusiface_card_profile_free(pa_dbusiface_card_profile *p);
+
+const char *pa_dbusiface_card_profile_get_path(pa_dbusiface_card_profile *p);
+const char *pa_dbusiface_card_profile_get_name(pa_dbusiface_card_profile *p);
+
+#endif
diff --git a/src/modules/dbus/iface-card.c b/src/modules/dbus/iface-card.c
new file mode 100644
index 00000000..d99c8b95
--- /dev/null
+++ b/src/modules/dbus/iface-card.c
@@ -0,0 +1,561 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-card-profile.h"
+
+#include "iface-card.h"
+
+#define OBJECT_NAME "card"
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sinks(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sources(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_profiles(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_active_profile(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_active_profile(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_profile_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+struct pa_dbusiface_card {
+ pa_dbusiface_core *core;
+
+ pa_card *card;
+ char *path;
+ pa_hashmap *profiles;
+ uint32_t next_profile_index;
+ pa_card_profile *active_profile;
+ pa_proplist *proplist;
+
+ pa_dbus_protocol *dbus_protocol;
+ pa_subscription *subscription;
+};
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_NAME,
+ PROPERTY_HANDLER_DRIVER,
+ PROPERTY_HANDLER_OWNER_MODULE,
+ PROPERTY_HANDLER_SINKS,
+ PROPERTY_HANDLER_SOURCES,
+ PROPERTY_HANDLER_PROFILES,
+ PROPERTY_HANDLER_ACTIVE_PROFILE,
+ PROPERTY_HANDLER_PROPERTY_LIST,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_get_name, .set_cb = NULL },
+ [PROPERTY_HANDLER_DRIVER] = { .property_name = "Driver", .type = "s", .get_cb = handle_get_driver, .set_cb = NULL },
+ [PROPERTY_HANDLER_OWNER_MODULE] = { .property_name = "OwnerModule", .type = "o", .get_cb = handle_get_owner_module, .set_cb = NULL },
+ [PROPERTY_HANDLER_SINKS] = { .property_name = "Sinks", .type = "ao", .get_cb = handle_get_sinks, .set_cb = NULL },
+ [PROPERTY_HANDLER_SOURCES] = { .property_name = "Sources", .type = "ao", .get_cb = handle_get_sources, .set_cb = NULL },
+ [PROPERTY_HANDLER_PROFILES] = { .property_name = "Profiles", .type = "ao", .get_cb = handle_get_profiles, .set_cb = NULL },
+ [PROPERTY_HANDLER_ACTIVE_PROFILE] = { .property_name = "ActiveProfile", .type = "o", .get_cb = handle_get_active_profile, .set_cb = handle_set_active_profile },
+ [PROPERTY_HANDLER_PROPERTY_LIST] = { .property_name = "PropertyList", .type = "a{say}", .get_cb = handle_get_property_list, .set_cb = NULL }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_GET_PROFILE_BY_NAME,
+ METHOD_HANDLER_MAX
+};
+
+static pa_dbus_arg_info get_profile_by_name_args[] = { { "name", "s", "in" }, { "profile", "o", "out" } };
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_GET_PROFILE_BY_NAME] = {
+ .method_name = "GetProfileByName",
+ .arguments = get_profile_by_name_args,
+ .n_arguments = sizeof(get_profile_by_name_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_get_profile_by_name }
+};
+
+enum signal_index {
+ SIGNAL_ACTIVE_PROFILE_UPDATED,
+ SIGNAL_PROPERTY_LIST_UPDATED,
+ SIGNAL_MAX
+};
+
+static pa_dbus_arg_info active_profile_updated_args[] = { { "profile", "o", NULL } };
+static pa_dbus_arg_info property_list_updated_args[] = { { "property_list", "a{say}", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_ACTIVE_PROFILE_UPDATED] = { .name = "ActiveProfileUpdated", .arguments = active_profile_updated_args, .n_arguments = 1 },
+ [SIGNAL_PROPERTY_LIST_UPDATED] = { .name = "PropertyListUpdated", .arguments = property_list_updated_args, .n_arguments = 1 }
+};
+
+static pa_dbus_interface_info card_interface_info = {
+ .name = PA_DBUSIFACE_CARD_INTERFACE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ dbus_uint32_t idx;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ idx = c->card->index;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &idx);
+}
+
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &c->card->name);
+}
+
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &c->card->driver);
+}
+
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ const char *owner_module;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (!c->card->module) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "Card %s doesn't have an owner module.", c->card->name);
+ return;
+ }
+
+ owner_module = pa_dbusiface_core_get_module_path(c->core, c->card->module);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &owner_module);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_sinks(pa_dbusiface_card *c, unsigned *n) {
+ const char **sinks = NULL;
+ unsigned i = 0;
+ uint32_t idx = 0;
+ pa_sink *sink = NULL;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_idxset_size(c->card->sinks);
+
+ if (*n == 0)
+ return NULL;
+
+ sinks = pa_xnew(const char *, *n);
+
+ PA_IDXSET_FOREACH(sink, c->card->sinks, idx) {
+ sinks[i] = pa_dbusiface_core_get_sink_path(c->core, sink);
+ ++i;
+ }
+
+ return sinks;
+}
+
+static void handle_get_sinks(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ const char **sinks;
+ unsigned n_sinks;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ sinks = get_sinks(c, &n_sinks);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, sinks, n_sinks);
+
+ pa_xfree(sinks);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_sources(pa_dbusiface_card *c, unsigned *n) {
+ const char **sources = NULL;
+ unsigned i = 0;
+ uint32_t idx = 0;
+ pa_source *source = NULL;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_idxset_size(c->card->sources);
+
+ if (*n == 0)
+ return NULL;
+
+ sources = pa_xnew(const char *, *n);
+
+ PA_IDXSET_FOREACH(source, c->card->sinks, idx) {
+ sources[i] = pa_dbusiface_core_get_source_path(c->core, source);
+ ++i;
+ }
+
+ return sources;
+}
+
+static void handle_get_sources(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ const char **sources;
+ unsigned n_sources;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ sources = get_sources(c, &n_sources);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, sources, n_sources);
+
+ pa_xfree(sources);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_profiles(pa_dbusiface_card *c, unsigned *n) {
+ const char **profiles;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_card_profile *profile;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->profiles);
+
+ if (*n == 0)
+ return NULL;
+
+ profiles = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(profile, c->profiles, state)
+ profiles[i++] = pa_dbusiface_card_profile_get_path(profile);
+
+ return profiles;
+}
+
+static void handle_get_profiles(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ const char **profiles;
+ unsigned n_profiles;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ profiles = get_profiles(c, &n_profiles);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, profiles, n_profiles);
+
+ pa_xfree(profiles);
+}
+
+static void handle_get_active_profile(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ const char *active_profile;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (!c->active_profile) {
+ pa_assert(pa_hashmap_isempty(c->profiles));
+
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "The card %s has no profiles, and therefore there's no active profile either.", c->card->name);
+ return;
+ }
+
+ active_profile = pa_dbusiface_card_profile_get_path(pa_hashmap_get(c->profiles, c->active_profile->name));
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &active_profile);
+}
+
+static void handle_set_active_profile(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ const char *new_active_path;
+ pa_dbusiface_card_profile *new_active;
+ int r;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(c);
+
+ if (!c->active_profile) {
+ pa_assert(pa_hashmap_isempty(c->profiles));
+
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "The card %s has no profiles, and therefore there's no active profile either.",
+ c->card->name);
+ return;
+ }
+
+ dbus_message_iter_get_basic(iter, &new_active_path);
+
+ if (!(new_active = pa_hashmap_get(c->profiles, new_active_path))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such profile.", new_active_path);
+ return;
+ }
+
+ if ((r = pa_card_set_profile(c->card, pa_dbusiface_card_profile_get_name(new_active), TRUE)) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED,
+ "Internal error in PulseAudio: pa_card_set_profile() failed with error code %i.", r);
+ return;
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_dbus_send_proplist_variant_reply(conn, msg, c->proplist);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t idx;
+ const char *owner_module = NULL;
+ const char **sinks = NULL;
+ unsigned n_sinks = 0;
+ const char **sources = NULL;
+ unsigned n_sources = 0;
+ const char **profiles = NULL;
+ unsigned n_profiles = 0;
+ const char *active_profile = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ idx = c->card->index;
+ if (c->card->module)
+ owner_module = pa_dbusiface_core_get_module_path(c->core, c->card->module);
+ sinks = get_sinks(c, &n_sinks);
+ sources = get_sources(c, &n_sources);
+ profiles = get_profiles(c, &n_profiles);
+ if (c->active_profile)
+ active_profile = pa_dbusiface_card_profile_get_path(pa_hashmap_get(c->profiles, c->active_profile->name));
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &idx);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &c->card->name);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DRIVER].property_name, DBUS_TYPE_STRING, &c->card->driver);
+
+ if (owner_module)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_OWNER_MODULE].property_name, DBUS_TYPE_OBJECT_PATH, &owner_module);
+
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SINKS].property_name, DBUS_TYPE_OBJECT_PATH, sinks, n_sinks);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SOURCES].property_name, DBUS_TYPE_OBJECT_PATH, sources, n_sources);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PROFILES].property_name, DBUS_TYPE_OBJECT_PATH, profiles, n_profiles);
+
+ if (active_profile)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_ACTIVE_PROFILE].property_name, DBUS_TYPE_OBJECT_PATH, &active_profile);
+
+ pa_dbus_append_proplist_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PROPERTY_LIST].property_name, c->proplist);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+
+ pa_xfree(sinks);
+ pa_xfree(sources);
+ pa_xfree(profiles);
+}
+
+static void handle_get_profile_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ const char *profile_name = NULL;
+ pa_dbusiface_card_profile *profile = NULL;
+ const char *profile_path = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &profile_name, DBUS_TYPE_INVALID));
+
+ if (!(profile = pa_hashmap_get(c->profiles, profile_name))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such profile on card %s.", profile_name, c->card->name);
+ return;
+ }
+
+ profile_path = pa_dbusiface_card_profile_get_path(profile);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &profile_path);
+}
+
+static void subscription_cb(pa_core *core, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ pa_dbusiface_card *c = userdata;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(core);
+ pa_assert((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_CARD);
+ pa_assert(c);
+
+ /* We can't use idx != c->card->index, because the c->card pointer may
+ * be stale at this point. */
+ if (pa_idxset_get_by_index(core->cards, idx) != c->card)
+ return;
+
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) != PA_SUBSCRIPTION_EVENT_CHANGE)
+ return;
+
+ if (c->active_profile != c->card->active_profile) {
+ const char *object_path;
+
+ c->active_profile = c->card->active_profile;
+ object_path = pa_dbusiface_card_profile_get_path(pa_hashmap_get(c->profiles, c->active_profile->name));
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(c->path,
+ PA_DBUSIFACE_CARD_INTERFACE,
+ signals[SIGNAL_ACTIVE_PROFILE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+
+ if (!pa_proplist_equal(c->proplist, c->card->proplist)) {
+ DBusMessageIter msg_iter;
+
+ pa_proplist_update(c->proplist, PA_UPDATE_SET, c->card->proplist);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(c->path,
+ PA_DBUSIFACE_CARD_INTERFACE,
+ signals[SIGNAL_PROPERTY_LIST_UPDATED].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_dbus_append_proplist(&msg_iter, c->proplist);
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+}
+
+pa_dbusiface_card *pa_dbusiface_card_new(pa_dbusiface_core *core, pa_card *card) {
+ pa_dbusiface_card *c = NULL;
+
+ pa_assert(core);
+ pa_assert(card);
+
+ c = pa_xnew0(pa_dbusiface_card, 1);
+ c->core = core;
+ c->card = card;
+ c->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, OBJECT_NAME, card->index);
+ c->profiles = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ c->next_profile_index = 0;
+ c->active_profile = NULL;
+ c->proplist = pa_proplist_copy(card->proplist);
+ c->dbus_protocol = pa_dbus_protocol_get(card->core);
+ c->subscription = pa_subscription_new(card->core, PA_SUBSCRIPTION_MASK_CARD, subscription_cb, c);
+
+ if (card->profiles) {
+ pa_card_profile *profile;
+ void *state = NULL;
+
+ PA_HASHMAP_FOREACH(profile, card->profiles, state) {
+ pa_dbusiface_card_profile *p = pa_dbusiface_card_profile_new(c, card->core, profile, c->next_profile_index++);
+ pa_hashmap_put(c->profiles, pa_dbusiface_card_profile_get_name(p), p);
+ }
+ pa_assert_se(c->active_profile = card->active_profile);
+ }
+
+ pa_assert_se(pa_dbus_protocol_add_interface(c->dbus_protocol, c->path, &card_interface_info, c) >= 0);
+
+ return c;
+}
+
+static void profile_free_cb(void *p, void *userdata) {
+ pa_dbusiface_card_profile *profile = p;
+
+ pa_assert(profile);
+
+ pa_dbusiface_card_profile_free(profile);
+}
+
+void pa_dbusiface_card_free(pa_dbusiface_card *c) {
+ pa_assert(c);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(c->dbus_protocol, c->path, card_interface_info.name) >= 0);
+
+ pa_hashmap_free(c->profiles, profile_free_cb, NULL);
+ pa_proplist_free(c->proplist);
+ pa_dbus_protocol_unref(c->dbus_protocol);
+ pa_subscription_free(c->subscription);
+
+ pa_xfree(c->path);
+ pa_xfree(c);
+}
+
+const char *pa_dbusiface_card_get_path(pa_dbusiface_card *c) {
+ pa_assert(c);
+
+ return c->path;
+}
diff --git a/src/modules/dbus/iface-card.h b/src/modules/dbus/iface-card.h
new file mode 100644
index 00000000..e2c08a3b
--- /dev/null
+++ b/src/modules/dbus/iface-card.h
@@ -0,0 +1,45 @@
+#ifndef foodbusifacecardhfoo
+#define foodbusifacecardhfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.Card.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the Card interface
+ * documentation.
+ */
+
+#include <pulsecore/card.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-core.h"
+
+#define PA_DBUSIFACE_CARD_INTERFACE PA_DBUS_CORE_INTERFACE ".Card"
+
+typedef struct pa_dbusiface_card pa_dbusiface_card;
+
+pa_dbusiface_card *pa_dbusiface_card_new(pa_dbusiface_core *core, pa_card *card);
+void pa_dbusiface_card_free(pa_dbusiface_card *c);
+
+const char *pa_dbusiface_card_get_path(pa_dbusiface_card *c);
+
+#endif
diff --git a/src/modules/dbus/iface-client.c b/src/modules/dbus/iface-client.c
new file mode 100644
index 00000000..e6675449
--- /dev/null
+++ b/src/modules/dbus/iface-client.c
@@ -0,0 +1,461 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+ Copyright 2009 Vincent Filali-Ansary <filali.v@azurdigitalnetworks.net>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-client.h"
+
+#define OBJECT_NAME "client"
+
+struct pa_dbusiface_client {
+ pa_dbusiface_core *core;
+
+ pa_client *client;
+ char *path;
+ pa_proplist *proplist;
+
+ pa_dbus_protocol *dbus_protocol;
+ pa_subscription *subscription;
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_playback_streams(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_record_streams(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_kill(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_update_properties(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_remove_properties(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_DRIVER,
+ PROPERTY_HANDLER_OWNER_MODULE,
+ PROPERTY_HANDLER_PLAYBACK_STREAMS,
+ PROPERTY_HANDLER_RECORD_STREAMS,
+ PROPERTY_HANDLER_PROPERTY_LIST,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_DRIVER] = { .property_name = "Driver", .type = "s", .get_cb = handle_get_driver, .set_cb = NULL },
+ [PROPERTY_HANDLER_OWNER_MODULE] = { .property_name = "OwnerModule", .type = "o", .get_cb = handle_get_owner_module, .set_cb = NULL },
+ [PROPERTY_HANDLER_PLAYBACK_STREAMS] = { .property_name = "PlaybackStreams", .type = "ao", .get_cb = handle_get_playback_streams, .set_cb = NULL },
+ [PROPERTY_HANDLER_RECORD_STREAMS] = { .property_name = "RecordStreams", .type = "ao", .get_cb = handle_get_record_streams, .set_cb = NULL },
+ [PROPERTY_HANDLER_PROPERTY_LIST] = { .property_name = "PropertyList", .type = "a{say}", .get_cb = handle_get_property_list, .set_cb = NULL }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_KILL,
+ METHOD_HANDLER_UPDATE_PROPERTIES,
+ METHOD_HANDLER_REMOVE_PROPERTIES,
+ METHOD_HANDLER_MAX
+};
+
+static pa_dbus_arg_info update_properties_args[] = { { "property_list", "a{say}", "in" }, { "update_mode", "u", "in" } };
+static pa_dbus_arg_info remove_properties_args[] = { { "keys", "as", "in" } };
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_KILL] = {
+ .method_name = "Kill",
+ .arguments = NULL,
+ .n_arguments = 0,
+ .receive_cb = handle_kill },
+ [METHOD_HANDLER_UPDATE_PROPERTIES] = {
+ .method_name = "UpdateProperties",
+ .arguments = update_properties_args,
+ .n_arguments = sizeof(update_properties_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_update_properties },
+ [METHOD_HANDLER_REMOVE_PROPERTIES] = {
+ .method_name = "RemoveProperties",
+ .arguments = remove_properties_args,
+ .n_arguments = sizeof(remove_properties_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_remove_properties }
+};
+
+enum signal_index {
+ SIGNAL_PROPERTY_LIST_UPDATED,
+ SIGNAL_CLIENT_EVENT,
+ SIGNAL_MAX
+};
+
+static pa_dbus_arg_info property_list_updated_args[] = { { "property_list", "a{say}", NULL } };
+static pa_dbus_arg_info client_event_args[] = { { "name", "s", NULL },
+ { "property_list", "a{say}", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_PROPERTY_LIST_UPDATED] = { .name = "PropertyListUpdated", .arguments = property_list_updated_args, .n_arguments = 1 },
+ /* ClientEvent is sent from module-dbus-protocol.c. */
+ [SIGNAL_CLIENT_EVENT] = { .name = "ClientEvent", .arguments = client_event_args, .n_arguments = 1 }
+};
+
+static pa_dbus_interface_info client_interface_info = {
+ .name = PA_DBUSIFACE_CLIENT_INTERFACE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ dbus_uint32_t idx = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ idx = c->client->index;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &idx);
+}
+
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &c->client->driver);
+}
+
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ const char *owner_module = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (!c->client->module) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "Client %d doesn't have an owner module.", c->client->index);
+ return;
+ }
+
+ owner_module = pa_dbusiface_core_get_module_path(c->core, c->client->module);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &owner_module);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_playback_streams(pa_dbusiface_client *c, unsigned *n) {
+ const char **playback_streams = NULL;
+ unsigned i = 0;
+ uint32_t idx = 0;
+ pa_sink_input *sink_input = NULL;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_idxset_size(c->client->sink_inputs);
+
+ if (*n == 0)
+ return NULL;
+
+ playback_streams = pa_xnew(const char *, *n);
+
+ PA_IDXSET_FOREACH(sink_input, c->client->sink_inputs, idx)
+ playback_streams[i++] = pa_dbusiface_core_get_playback_stream_path(c->core, sink_input);
+
+ return playback_streams;
+}
+
+static void handle_get_playback_streams(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ const char **playback_streams = NULL;
+ unsigned n_playback_streams = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ playback_streams = get_playback_streams(c, &n_playback_streams);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, playback_streams, n_playback_streams);
+
+ pa_xfree(playback_streams);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_record_streams(pa_dbusiface_client *c, unsigned *n) {
+ const char **record_streams = NULL;
+ unsigned i = 0;
+ uint32_t idx = 0;
+ pa_source_output *source_output = NULL;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_idxset_size(c->client->source_outputs);
+
+ if (*n == 0)
+ return NULL;
+
+ record_streams = pa_xnew(const char *, *n);
+
+ PA_IDXSET_FOREACH(source_output, c->client->source_outputs, idx)
+ record_streams[i++] = pa_dbusiface_core_get_record_stream_path(c->core, source_output);
+
+ return record_streams;
+}
+
+static void handle_get_record_streams(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ const char **record_streams = NULL;
+ unsigned n_record_streams = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ record_streams = get_record_streams(c, &n_record_streams);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, record_streams, n_record_streams);
+
+ pa_xfree(record_streams);
+}
+
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_dbus_send_proplist_variant_reply(conn, msg, c->client->proplist);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t idx = 0;
+ const char *owner_module = NULL;
+ const char **playback_streams = NULL;
+ unsigned n_playback_streams = 0;
+ const char **record_streams = NULL;
+ unsigned n_record_streams = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ idx = c->client->index;
+ if (c->client->module)
+ owner_module = pa_dbusiface_core_get_module_path(c->core, c->client->module);
+ playback_streams = get_playback_streams(c, &n_playback_streams);
+ record_streams = get_record_streams(c, &n_record_streams);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &idx);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DRIVER].property_name, DBUS_TYPE_STRING, &c->client->driver);
+
+ if (owner_module)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_OWNER_MODULE].property_name, DBUS_TYPE_OBJECT_PATH, &owner_module);
+
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PLAYBACK_STREAMS].property_name, DBUS_TYPE_OBJECT_PATH, playback_streams, n_playback_streams);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_RECORD_STREAMS].property_name, DBUS_TYPE_OBJECT_PATH, record_streams, n_record_streams);
+ pa_dbus_append_proplist_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PROPERTY_LIST].property_name, c->client->proplist);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+
+ pa_xfree(playback_streams);
+ pa_xfree(record_streams);
+}
+
+static void handle_kill(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ dbus_connection_ref(conn);
+
+ pa_client_kill(c->client);
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ dbus_connection_unref(conn);
+}
+
+static void handle_update_properties(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ DBusMessageIter msg_iter;
+ pa_proplist *property_list = NULL;
+ dbus_uint32_t update_mode = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (pa_dbus_protocol_get_client(c->dbus_protocol, conn) != c->client) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_ACCESS_DENIED, "Client tried to modify the property list of another client.");
+ return;
+ }
+
+ pa_assert_se(dbus_message_iter_init(msg, &msg_iter));
+
+ if (!(property_list = pa_dbus_get_proplist_arg(conn, msg, &msg_iter)))
+ return;
+
+ dbus_message_iter_get_basic(&msg_iter, &update_mode);
+
+ if (!(update_mode == PA_UPDATE_SET || update_mode == PA_UPDATE_MERGE || update_mode == PA_UPDATE_REPLACE)) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid update mode: %u", update_mode);
+ goto finish;
+ }
+
+ pa_client_update_proplist(c->client, update_mode, property_list);
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+finish:
+ if (property_list)
+ pa_proplist_free(property_list);
+}
+
+static void handle_remove_properties(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ char **keys = NULL;
+ int n_keys = 0;
+ pa_bool_t changed = FALSE;
+ int i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (pa_dbus_protocol_get_client(c->dbus_protocol, conn) != c->client) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_ACCESS_DENIED, "Client tried to modify the property list of another client.");
+ return;
+ }
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_ARRAY, DBUS_TYPE_STRING, &keys, &n_keys, DBUS_TYPE_INVALID));
+
+ for (i = 0; i < n_keys; ++i)
+ changed |= pa_proplist_unset(c->client->proplist, keys[i]) >= 0;
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ if (changed)
+ pa_subscription_post(c->client->core, PA_SUBSCRIPTION_EVENT_CLIENT|PA_SUBSCRIPTION_EVENT_CHANGE, c->client->index);
+
+ dbus_free_string_array(keys);
+}
+
+static void subscription_cb(pa_core *core, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ pa_dbusiface_client *c = userdata;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(core);
+ pa_assert((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_CLIENT);
+ pa_assert(c);
+
+ /* We can't use idx != c->client->index, because the c->client pointer may
+ * be stale at this point. */
+ if (pa_idxset_get_by_index(core->clients, idx) != c->client)
+ return;
+
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) != PA_SUBSCRIPTION_EVENT_CHANGE)
+ return;
+
+ if (!pa_proplist_equal(c->proplist, c->client->proplist)) {
+ DBusMessageIter msg_iter;
+
+ pa_proplist_update(c->proplist, PA_UPDATE_SET, c->client->proplist);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(c->path,
+ PA_DBUSIFACE_CLIENT_INTERFACE,
+ signals[SIGNAL_PROPERTY_LIST_UPDATED].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_dbus_append_proplist(&msg_iter, c->proplist);
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+}
+
+pa_dbusiface_client *pa_dbusiface_client_new(pa_dbusiface_core *core, pa_client *client) {
+ pa_dbusiface_client *c = NULL;
+
+ pa_assert(core);
+ pa_assert(client);
+
+ c = pa_xnew(pa_dbusiface_client, 1);
+ c->core = core;
+ c->client = client;
+ c->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, OBJECT_NAME, client->index);
+ c->proplist = pa_proplist_copy(client->proplist);
+ c->dbus_protocol = pa_dbus_protocol_get(client->core);
+ c->subscription = pa_subscription_new(client->core, PA_SUBSCRIPTION_MASK_CLIENT, subscription_cb, c);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(c->dbus_protocol, c->path, &client_interface_info, c) >= 0);
+
+ return c;
+}
+
+void pa_dbusiface_client_free(pa_dbusiface_client *c) {
+ pa_assert(c);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(c->dbus_protocol, c->path, client_interface_info.name) >= 0);
+
+ pa_proplist_free(c->proplist);
+ pa_dbus_protocol_unref(c->dbus_protocol);
+ pa_subscription_free(c->subscription);
+
+ pa_xfree(c->path);
+ pa_xfree(c);
+}
+
+const char *pa_dbusiface_client_get_path(pa_dbusiface_client *c) {
+ pa_assert(c);
+
+ return c->path;
+}
diff --git a/src/modules/dbus/iface-client.h b/src/modules/dbus/iface-client.h
new file mode 100644
index 00000000..e8f151cd
--- /dev/null
+++ b/src/modules/dbus/iface-client.h
@@ -0,0 +1,45 @@
+#ifndef foodbusifaceclienthfoo
+#define foodbusifaceclienthfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.Client.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the Client interface
+ * documentation.
+ */
+
+#include <pulsecore/client.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-core.h"
+
+#define PA_DBUSIFACE_CLIENT_INTERFACE PA_DBUS_CORE_INTERFACE ".Client"
+
+typedef struct pa_dbusiface_client pa_dbusiface_client;
+
+pa_dbusiface_client *pa_dbusiface_client_new(pa_dbusiface_core *core, pa_client *client);
+void pa_dbusiface_client_free(pa_dbusiface_client *c);
+
+const char *pa_dbusiface_client_get_path(pa_dbusiface_client *c);
+
+#endif
diff --git a/src/modules/dbus/iface-core.c b/src/modules/dbus/iface-core.c
new file mode 100644
index 00000000..bb43df9b
--- /dev/null
+++ b/src/modules/dbus/iface-core.c
@@ -0,0 +1,2206 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <ctype.h>
+
+#include <dbus/dbus.h>
+
+#include <pulse/utf8.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/protocol-dbus.h>
+#include <pulsecore/socket-util.h>
+#include <pulsecore/strbuf.h>
+
+#include "iface-card.h"
+#include "iface-client.h"
+#include "iface-device.h"
+#include "iface-memstats.h"
+#include "iface-module.h"
+#include "iface-sample.h"
+#include "iface-stream.h"
+
+#include "iface-core.h"
+
+#define INTERFACE_REVISION 0
+
+static void handle_get_interface_revision(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_version(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_is_local(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_username(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_hostname(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_default_channels(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_default_channels(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_default_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_default_sample_format(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_default_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_default_sample_rate(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_cards(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sinks(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_fallback_sink(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_fallback_sink(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_sources(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_fallback_source(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_fallback_source(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_playback_streams(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_record_streams(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_samples(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_modules(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_clients(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_my_client(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_extensions(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_card_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sink_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_source_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_upload_sample(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_load_module(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_exit(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_listen_for_signal(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_stop_listening_for_signal(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+struct pa_dbusiface_core {
+ pa_core *core;
+ pa_subscription *subscription;
+
+ pa_dbus_protocol *dbus_protocol;
+
+ pa_hashmap *cards;
+ pa_hashmap *sinks_by_index;
+ pa_hashmap *sinks_by_path;
+ pa_hashmap *sources_by_index;
+ pa_hashmap *sources_by_path;
+ pa_hashmap *playback_streams;
+ pa_hashmap *record_streams;
+ pa_hashmap *samples;
+ pa_hashmap *modules;
+ pa_hashmap *clients;
+
+ pa_sink *fallback_sink;
+ pa_source *fallback_source;
+
+ pa_hook_slot *sink_put_slot;
+ pa_hook_slot *sink_unlink_slot;
+ pa_hook_slot *source_put_slot;
+ pa_hook_slot *source_unlink_slot;
+ pa_hook_slot *extension_registered_slot;
+ pa_hook_slot *extension_unregistered_slot;
+
+ pa_dbusiface_memstats *memstats;
+};
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INTERFACE_REVISION,
+ PROPERTY_HANDLER_NAME,
+ PROPERTY_HANDLER_VERSION,
+ PROPERTY_HANDLER_IS_LOCAL,
+ PROPERTY_HANDLER_USERNAME,
+ PROPERTY_HANDLER_HOSTNAME,
+ PROPERTY_HANDLER_DEFAULT_CHANNELS,
+ PROPERTY_HANDLER_DEFAULT_SAMPLE_FORMAT,
+ PROPERTY_HANDLER_DEFAULT_SAMPLE_RATE,
+ PROPERTY_HANDLER_CARDS,
+ PROPERTY_HANDLER_SINKS,
+ PROPERTY_HANDLER_FALLBACK_SINK,
+ PROPERTY_HANDLER_SOURCES,
+ PROPERTY_HANDLER_FALLBACK_SOURCE,
+ PROPERTY_HANDLER_PLAYBACK_STREAMS,
+ PROPERTY_HANDLER_RECORD_STREAMS,
+ PROPERTY_HANDLER_SAMPLES,
+ PROPERTY_HANDLER_MODULES,
+ PROPERTY_HANDLER_CLIENTS,
+ PROPERTY_HANDLER_MY_CLIENT,
+ PROPERTY_HANDLER_EXTENSIONS,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INTERFACE_REVISION] = { .property_name = "InterfaceRevision", .type = "u", .get_cb = handle_get_interface_revision, .set_cb = NULL },
+ [PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_get_name, .set_cb = NULL },
+ [PROPERTY_HANDLER_VERSION] = { .property_name = "Version", .type = "s", .get_cb = handle_get_version, .set_cb = NULL },
+ [PROPERTY_HANDLER_IS_LOCAL] = { .property_name = "IsLocal", .type = "b", .get_cb = handle_get_is_local, .set_cb = NULL },
+ [PROPERTY_HANDLER_USERNAME] = { .property_name = "Username", .type = "s", .get_cb = handle_get_username, .set_cb = NULL },
+ [PROPERTY_HANDLER_HOSTNAME] = { .property_name = "Hostname", .type = "s", .get_cb = handle_get_hostname, .set_cb = NULL },
+ [PROPERTY_HANDLER_DEFAULT_CHANNELS] = { .property_name = "DefaultChannels", .type = "au", .get_cb = handle_get_default_channels, .set_cb = handle_set_default_channels },
+ [PROPERTY_HANDLER_DEFAULT_SAMPLE_FORMAT] = { .property_name = "DefaultSampleFormat", .type = "u", .get_cb = handle_get_default_sample_format, .set_cb = handle_set_default_sample_format },
+ [PROPERTY_HANDLER_DEFAULT_SAMPLE_RATE] = { .property_name = "DefaultSampleRate", .type = "u", .get_cb = handle_get_default_sample_rate, .set_cb = handle_set_default_sample_rate },
+ [PROPERTY_HANDLER_CARDS] = { .property_name = "Cards", .type = "ao", .get_cb = handle_get_cards, .set_cb = NULL },
+ [PROPERTY_HANDLER_SINKS] = { .property_name = "Sinks", .type = "ao", .get_cb = handle_get_sinks, .set_cb = NULL },
+ [PROPERTY_HANDLER_FALLBACK_SINK] = { .property_name = "FallbackSink", .type = "o", .get_cb = handle_get_fallback_sink, .set_cb = handle_set_fallback_sink },
+ [PROPERTY_HANDLER_SOURCES] = { .property_name = "Sources", .type = "ao", .get_cb = handle_get_sources, .set_cb = NULL },
+ [PROPERTY_HANDLER_FALLBACK_SOURCE] = { .property_name = "FallbackSource", .type = "o", .get_cb = handle_get_fallback_source, .set_cb = handle_set_fallback_source },
+ [PROPERTY_HANDLER_PLAYBACK_STREAMS] = { .property_name = "PlaybackStreams", .type = "ao", .get_cb = handle_get_playback_streams, .set_cb = NULL },
+ [PROPERTY_HANDLER_RECORD_STREAMS] = { .property_name = "RecordStreams", .type = "ao", .get_cb = handle_get_record_streams, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLES] = { .property_name = "Samples", .type = "ao", .get_cb = handle_get_samples, .set_cb = NULL },
+ [PROPERTY_HANDLER_MODULES] = { .property_name = "Modules", .type = "ao", .get_cb = handle_get_modules, .set_cb = NULL },
+ [PROPERTY_HANDLER_CLIENTS] = { .property_name = "Clients", .type = "ao", .get_cb = handle_get_clients, .set_cb = NULL },
+ [PROPERTY_HANDLER_MY_CLIENT] = { .property_name = "MyClient", .type = "o", .get_cb = handle_get_my_client, .set_cb = NULL },
+ [PROPERTY_HANDLER_EXTENSIONS] = { .property_name = "Extensions", .type = "as", .get_cb = handle_get_extensions, .set_cb = NULL }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_GET_CARD_BY_NAME,
+ METHOD_HANDLER_GET_SINK_BY_NAME,
+ METHOD_HANDLER_GET_SOURCE_BY_NAME,
+ METHOD_HANDLER_GET_SAMPLE_BY_NAME,
+ METHOD_HANDLER_UPLOAD_SAMPLE,
+ METHOD_HANDLER_LOAD_MODULE,
+ METHOD_HANDLER_EXIT,
+ METHOD_HANDLER_LISTEN_FOR_SIGNAL,
+ METHOD_HANDLER_STOP_LISTENING_FOR_SIGNAL,
+ METHOD_HANDLER_MAX
+};
+
+static pa_dbus_arg_info get_card_by_name_args[] = { { "name", "s", "in" }, { "card", "o", "out" } };
+static pa_dbus_arg_info get_sink_by_name_args[] = { { "name", "s", "in" }, { "sink", "o", "out" } };
+static pa_dbus_arg_info get_source_by_name_args[] = { { "name", "s", "in" }, { "source", "o", "out" } };
+static pa_dbus_arg_info get_sample_by_name_args[] = { { "name", "s", "in" }, { "sample", "o", "out" } };
+static pa_dbus_arg_info upload_sample_args[] = { { "name", "s", "in" },
+ { "sample_format", "u", "in" },
+ { "sample_rate", "u", "in" },
+ { "channels", "au", "in" },
+ { "default_volume", "au", "in" },
+ { "property_list", "a{say}", "in" },
+ { "data", "ay", "in" },
+ { "sample", "o", "out" } };
+static pa_dbus_arg_info load_module_args[] = { { "name", "s", "in" }, { "arguments", "a{ss}", "in" }, { "module", "o", "out" } };
+static pa_dbus_arg_info listen_for_signal_args[] = { { "signal", "s", "in" }, { "objects", "ao", "in" } };
+static pa_dbus_arg_info stop_listening_for_signal_args[] = { { "signal", "s", "in" } };
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_GET_CARD_BY_NAME] = {
+ .method_name = "GetCardByName",
+ .arguments = get_card_by_name_args,
+ .n_arguments = sizeof(get_card_by_name_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_get_card_by_name },
+ [METHOD_HANDLER_GET_SINK_BY_NAME] = {
+ .method_name = "GetSinkByName",
+ .arguments = get_sink_by_name_args,
+ .n_arguments = sizeof(get_sink_by_name_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_get_sink_by_name },
+ [METHOD_HANDLER_GET_SOURCE_BY_NAME] = {
+ .method_name = "GetSourceByName",
+ .arguments = get_source_by_name_args,
+ .n_arguments = sizeof(get_source_by_name_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_get_source_by_name },
+ [METHOD_HANDLER_GET_SAMPLE_BY_NAME] = {
+ .method_name = "GetSampleByName",
+ .arguments = get_sample_by_name_args,
+ .n_arguments = sizeof(get_sample_by_name_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_get_sample_by_name },
+ [METHOD_HANDLER_UPLOAD_SAMPLE] = {
+ .method_name = "UploadSample",
+ .arguments = upload_sample_args,
+ .n_arguments = sizeof(upload_sample_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_upload_sample },
+ [METHOD_HANDLER_LOAD_MODULE] = {
+ .method_name = "LoadModule",
+ .arguments = load_module_args,
+ .n_arguments = sizeof(load_module_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_load_module },
+ [METHOD_HANDLER_EXIT] = {
+ .method_name = "Exit",
+ .arguments = NULL,
+ .n_arguments = 0,
+ .receive_cb = handle_exit },
+ [METHOD_HANDLER_LISTEN_FOR_SIGNAL] = {
+ .method_name = "ListenForSignal",
+ .arguments = listen_for_signal_args,
+ .n_arguments = sizeof(listen_for_signal_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_listen_for_signal },
+ [METHOD_HANDLER_STOP_LISTENING_FOR_SIGNAL] = {
+ .method_name = "StopListeningForSignal",
+ .arguments = stop_listening_for_signal_args,
+ .n_arguments = sizeof(stop_listening_for_signal_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_stop_listening_for_signal }
+};
+
+enum signal_index {
+ SIGNAL_NEW_CARD,
+ SIGNAL_CARD_REMOVED,
+ SIGNAL_NEW_SINK,
+ SIGNAL_SINK_REMOVED,
+ SIGNAL_FALLBACK_SINK_UPDATED,
+ SIGNAL_FALLBACK_SINK_UNSET,
+ SIGNAL_NEW_SOURCE,
+ SIGNAL_SOURCE_REMOVED,
+ SIGNAL_FALLBACK_SOURCE_UPDATED,
+ SIGNAL_FALLBACK_SOURCE_UNSET,
+ SIGNAL_NEW_PLAYBACK_STREAM,
+ SIGNAL_PLAYBACK_STREAM_REMOVED,
+ SIGNAL_NEW_RECORD_STREAM,
+ SIGNAL_RECORD_STREAM_REMOVED,
+ SIGNAL_NEW_SAMPLE,
+ SIGNAL_SAMPLE_REMOVED,
+ SIGNAL_NEW_MODULE,
+ SIGNAL_MODULE_REMOVED,
+ SIGNAL_NEW_CLIENT,
+ SIGNAL_CLIENT_REMOVED,
+ SIGNAL_NEW_EXTENSION,
+ SIGNAL_EXTENSION_REMOVED,
+ SIGNAL_MAX
+};
+
+static pa_dbus_arg_info new_card_args[] = { { "card", "o", NULL } };
+static pa_dbus_arg_info card_removed_args[] = { { "card", "o", NULL } };
+static pa_dbus_arg_info new_sink_args[] = { { "sink", "o", NULL } };
+static pa_dbus_arg_info sink_removed_args[] = { { "sink", "o", NULL } };
+static pa_dbus_arg_info fallback_sink_updated_args[] = { { "sink", "o", NULL } };
+static pa_dbus_arg_info new_source_args[] = { { "source", "o", NULL } };
+static pa_dbus_arg_info source_removed_args[] = { { "source", "o", NULL } };
+static pa_dbus_arg_info fallback_source_updated_args[] = { { "source", "o", NULL } };
+static pa_dbus_arg_info new_playback_stream_args[] = { { "playback_stream", "o", NULL } };
+static pa_dbus_arg_info playback_stream_removed_args[] = { { "playback_stream", "o", NULL } };
+static pa_dbus_arg_info new_record_stream_args[] = { { "record_stream", "o", NULL } };
+static pa_dbus_arg_info record_stream_removed_args[] = { { "record_stream", "o", NULL } };
+static pa_dbus_arg_info new_sample_args[] = { { "sample", "o", NULL } };
+static pa_dbus_arg_info sample_removed_args[] = { { "sample", "o", NULL } };
+static pa_dbus_arg_info new_module_args[] = { { "module", "o", NULL } };
+static pa_dbus_arg_info module_removed_args[] = { { "module", "o", NULL } };
+static pa_dbus_arg_info new_client_args[] = { { "client", "o", NULL } };
+static pa_dbus_arg_info client_removed_args[] = { { "client", "o", NULL } };
+static pa_dbus_arg_info new_extension_args[] = { { "extension", "s", NULL } };
+static pa_dbus_arg_info extension_removed_args[] = { { "extension", "s", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_NEW_CARD] = { .name = "NewCard", .arguments = new_card_args, .n_arguments = 1 },
+ [SIGNAL_CARD_REMOVED] = { .name = "CardRemoved", .arguments = card_removed_args, .n_arguments = 1 },
+ [SIGNAL_NEW_SINK] = { .name = "NewSink", .arguments = new_sink_args, .n_arguments = 1 },
+ [SIGNAL_SINK_REMOVED] = { .name = "SinkRemoved", .arguments = sink_removed_args, .n_arguments = 1 },
+ [SIGNAL_FALLBACK_SINK_UPDATED] = { .name = "FallbackSinkUpdated", .arguments = fallback_sink_updated_args, .n_arguments = 1 },
+ [SIGNAL_FALLBACK_SINK_UNSET] = { .name = "FallbackSinkUnset", .arguments = NULL, .n_arguments = 0 },
+ [SIGNAL_NEW_SOURCE] = { .name = "NewSource", .arguments = new_source_args, .n_arguments = 1 },
+ [SIGNAL_SOURCE_REMOVED] = { .name = "SourceRemoved", .arguments = source_removed_args, .n_arguments = 1 },
+ [SIGNAL_FALLBACK_SOURCE_UPDATED] = { .name = "FallbackSourceUpdated", .arguments = fallback_source_updated_args, .n_arguments = 1 },
+ [SIGNAL_FALLBACK_SOURCE_UNSET] = { .name = "FallbackSourceUnset", .arguments = NULL, .n_arguments = 0 },
+ [SIGNAL_NEW_PLAYBACK_STREAM] = { .name = "NewPlaybackStream", .arguments = new_playback_stream_args, .n_arguments = 1 },
+ [SIGNAL_PLAYBACK_STREAM_REMOVED] = { .name = "PlaybackStreamRemoved", .arguments = playback_stream_removed_args, .n_arguments = 1 },
+ [SIGNAL_NEW_RECORD_STREAM] = { .name = "NewRecordStream", .arguments = new_record_stream_args, .n_arguments = 1 },
+ [SIGNAL_RECORD_STREAM_REMOVED] = { .name = "RecordStreamRemoved", .arguments = record_stream_removed_args, .n_arguments = 1 },
+ [SIGNAL_NEW_SAMPLE] = { .name = "NewSample", .arguments = new_sample_args, .n_arguments = 1 },
+ [SIGNAL_SAMPLE_REMOVED] = { .name = "SampleRemoved", .arguments = sample_removed_args, .n_arguments = 1 },
+ [SIGNAL_NEW_MODULE] = { .name = "NewModule", .arguments = new_module_args, .n_arguments = 1 },
+ [SIGNAL_MODULE_REMOVED] = { .name = "ModuleRemoved", .arguments = module_removed_args, .n_arguments = 1 },
+ [SIGNAL_NEW_CLIENT] = { .name = "NewClient", .arguments = new_client_args, .n_arguments = 1 },
+ [SIGNAL_CLIENT_REMOVED] = { .name = "ClientRemoved", .arguments = client_removed_args, .n_arguments = 1 },
+ [SIGNAL_NEW_EXTENSION] = { .name = "NewExtension", .arguments = new_extension_args, .n_arguments = 1 },
+ [SIGNAL_EXTENSION_REMOVED] = { .name = "ExtensionRemoved", .arguments = extension_removed_args, .n_arguments = 1 }
+};
+
+static pa_dbus_interface_info core_interface_info = {
+ .name = PA_DBUS_CORE_INTERFACE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static void handle_get_interface_revision(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ dbus_uint32_t interface_revision = INTERFACE_REVISION;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &interface_revision);
+}
+
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ const char *server_name = PACKAGE_NAME;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &server_name);
+}
+
+static void handle_get_version(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ const char *version = PACKAGE_VERSION;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &version);
+}
+
+static dbus_bool_t get_is_local(DBusConnection *conn) {
+ int conn_fd;
+
+ pa_assert(conn);
+
+ if (!dbus_connection_get_socket(conn, &conn_fd))
+ return FALSE;
+
+ return pa_socket_is_local(conn_fd);
+}
+
+static void handle_get_is_local(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ dbus_bool_t is_local;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ is_local = get_is_local(conn);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &is_local);
+}
+
+static void handle_get_username(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ char *username = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ username = pa_get_user_name_malloc();
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &username);
+
+ pa_xfree(username);
+}
+
+static void handle_get_hostname(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ char *hostname = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ hostname = pa_get_host_name_malloc();
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &hostname);
+
+ pa_xfree(hostname);
+}
+
+/* Caller frees the returned array. */
+static dbus_uint32_t *get_default_channels(pa_dbusiface_core *c, unsigned *n) {
+ dbus_uint32_t *default_channels = NULL;
+ unsigned i;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = c->core->default_channel_map.channels;
+ default_channels = pa_xnew(dbus_uint32_t, *n);
+
+ for (i = 0; i < *n; ++i)
+ default_channels[i] = c->core->default_channel_map.map[i];
+
+ return default_channels;
+}
+
+static void handle_get_default_channels(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ dbus_uint32_t *default_channels = NULL;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ default_channels = get_default_channels(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_UINT32, default_channels, n);
+
+ pa_xfree(default_channels);
+}
+
+static void handle_set_default_channels(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ DBusMessageIter array_iter;
+ pa_channel_map new_channel_map;
+ const dbus_uint32_t *default_channels;
+ int n_channels;
+ unsigned i;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(c);
+
+ pa_channel_map_init(&new_channel_map);
+
+ dbus_message_iter_recurse(iter, &array_iter);
+ dbus_message_iter_get_fixed_array(&array_iter, &default_channels, &n_channels);
+
+ if (n_channels <= 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Empty channel array.");
+ return;
+ }
+
+ if (n_channels > (int) PA_CHANNELS_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS,
+ "Too many channels: %i. The maximum number of channels is %u.", n_channels, PA_CHANNELS_MAX);
+ return;
+ }
+
+ new_channel_map.channels = n_channels;
+
+ for (i = 0; i < new_channel_map.channels; ++i) {
+ if (default_channels[i] >= PA_CHANNEL_POSITION_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid channel position: %u.", default_channels[i]);
+ return;
+ }
+
+ new_channel_map.map[i] = default_channels[i];
+ }
+
+ c->core->default_channel_map = new_channel_map;
+ c->core->default_sample_spec.channels = n_channels;
+
+ pa_dbus_send_empty_reply(conn, msg);
+};
+
+static void handle_get_default_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ dbus_uint32_t default_sample_format;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ default_sample_format = c->core->default_sample_spec.format;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &default_sample_format);
+}
+
+static void handle_set_default_sample_format(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ dbus_uint32_t default_sample_format;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(c);
+
+ dbus_message_iter_get_basic(iter, &default_sample_format);
+
+ if (default_sample_format >= PA_SAMPLE_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid sample format.");
+ return;
+ }
+
+ c->core->default_sample_spec.format = default_sample_format;
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_get_default_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ dbus_uint32_t default_sample_rate;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ default_sample_rate = c->core->default_sample_spec.rate;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &default_sample_rate);
+}
+
+static void handle_set_default_sample_rate(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ dbus_uint32_t default_sample_rate;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(c);
+
+ dbus_message_iter_get_basic(iter, &default_sample_rate);
+
+ if (default_sample_rate <= 0 || default_sample_rate > PA_RATE_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid sample rate.");
+ return;
+ }
+
+ c->core->default_sample_spec.rate = default_sample_rate;
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_cards(pa_dbusiface_core *c, unsigned *n) {
+ const char **cards;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_card *card;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->cards);
+
+ if (*n == 0)
+ return NULL;
+
+ cards = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(card, c->cards, state)
+ cards[i++] = pa_dbusiface_card_get_path(card);
+
+ return cards;
+}
+
+static void handle_get_cards(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **cards;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ cards = get_cards(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, cards, n);
+
+ pa_xfree(cards);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_sinks(pa_dbusiface_core *c, unsigned *n) {
+ const char **sinks;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_device *sink;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->sinks_by_index);
+
+ if (*n == 0)
+ return NULL;
+
+ sinks = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(sink, c->sinks_by_index, state)
+ sinks[i++] = pa_dbusiface_device_get_path(sink);
+
+ return sinks;
+}
+
+static void handle_get_sinks(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **sinks;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ sinks = get_sinks(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, sinks, n);
+
+ pa_xfree(sinks);
+}
+
+static void handle_get_fallback_sink(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ pa_dbusiface_device *fallback_sink;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (!c->fallback_sink) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "There are no sinks, and therefore no fallback sink either.");
+ return;
+ }
+
+ pa_assert_se((fallback_sink = pa_hashmap_get(c->sinks_by_index, PA_UINT32_TO_PTR(c->fallback_sink->index))));
+ object_path = pa_dbusiface_device_get_path(fallback_sink);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_set_fallback_sink(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ pa_dbusiface_device *fallback_sink;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(c);
+
+ if (!c->fallback_sink) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "There are no sinks, and therefore no fallback sink either.");
+ return;
+ }
+
+ dbus_message_iter_get_basic(iter, &object_path);
+
+ if (!(fallback_sink = pa_hashmap_get(c->sinks_by_path, object_path))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such sink.", object_path);
+ return;
+ }
+
+ pa_namereg_set_default_sink(c->core, pa_dbusiface_device_get_sink(fallback_sink));
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_sources(pa_dbusiface_core *c, unsigned *n) {
+ const char **sources;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_device *source;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->sources_by_index);
+
+ if (*n == 0)
+ return NULL;
+
+ sources = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(source, c->sources_by_index, state)
+ sources[i++] = pa_dbusiface_device_get_path(source);
+
+ return sources;
+}
+
+static void handle_get_sources(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **sources;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ sources = get_sources(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, sources, n);
+
+ pa_xfree(sources);
+}
+
+static void handle_get_fallback_source(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ pa_dbusiface_device *fallback_source;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (!c->fallback_source) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "There are no sources, and therefore no fallback source either.");
+ return;
+ }
+
+ pa_assert_se((fallback_source = pa_hashmap_get(c->sources_by_index, PA_UINT32_TO_PTR(c->fallback_source->index))));
+ object_path = pa_dbusiface_device_get_path(fallback_source);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_set_fallback_source(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ pa_dbusiface_device *fallback_source;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(c);
+
+ if (!c->fallback_source) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "There are no sources, and therefore no fallback source either.");
+ return;
+ }
+
+ dbus_message_iter_get_basic(iter, &object_path);
+
+ if (!(fallback_source = pa_hashmap_get(c->sources_by_path, object_path))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such source.", object_path);
+ return;
+ }
+
+ pa_namereg_set_default_source(c->core, pa_dbusiface_device_get_source(fallback_source));
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_playback_streams(pa_dbusiface_core *c, unsigned *n) {
+ const char **streams;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_stream *stream;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->playback_streams);
+
+ if (*n == 0)
+ return NULL;
+
+ streams = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(stream, c->playback_streams, state)
+ streams[i++] = pa_dbusiface_stream_get_path(stream);
+
+ return streams;
+}
+
+static void handle_get_playback_streams(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **playback_streams;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ playback_streams = get_playback_streams(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, playback_streams, n);
+
+ pa_xfree(playback_streams);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_record_streams(pa_dbusiface_core *c, unsigned *n) {
+ const char **streams;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_stream *stream;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->record_streams);
+
+ if (*n == 0)
+ return NULL;
+
+ streams = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(stream, c->record_streams, state)
+ streams[i++] = pa_dbusiface_stream_get_path(stream);
+
+ return streams;
+}
+
+static void handle_get_record_streams(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **record_streams;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ record_streams = get_record_streams(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, record_streams, n);
+
+ pa_xfree(record_streams);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_samples(pa_dbusiface_core *c, unsigned *n) {
+ const char **samples;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_sample *sample;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->samples);
+
+ if (*n == 0)
+ return NULL;
+
+ samples = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(sample, c->samples, state)
+ samples[i++] = pa_dbusiface_sample_get_path(sample);
+
+ return samples;
+}
+
+static void handle_get_samples(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **samples;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ samples = get_samples(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, samples, n);
+
+ pa_xfree(samples);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_modules(pa_dbusiface_core *c, unsigned *n) {
+ const char **modules;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_module *module;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->modules);
+
+ if (*n == 0)
+ return NULL;
+
+ modules = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(module, c->modules, state)
+ modules[i++] = pa_dbusiface_module_get_path(module);
+
+ return modules;
+}
+
+static void handle_get_modules(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **modules;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ modules = get_modules(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, modules, n);
+
+ pa_xfree(modules);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_clients(pa_dbusiface_core *c, unsigned *n) {
+ const char **clients;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_client *client;
+
+ pa_assert(c);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(c->clients);
+
+ if (*n == 0)
+ return NULL;
+
+ clients = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(client, c->clients, state)
+ clients[i++] = pa_dbusiface_client_get_path(client);
+
+ return clients;
+}
+
+static void handle_get_clients(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **clients;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ clients = get_clients(c, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, clients, n);
+
+ pa_xfree(clients);
+}
+
+static const char *get_my_client(pa_dbusiface_core *c, DBusConnection *conn) {
+ pa_client *my_client;
+
+ pa_assert(c);
+ pa_assert(conn);
+
+ pa_assert_se((my_client = pa_dbus_protocol_get_client(c->dbus_protocol, conn)));
+
+ return pa_dbusiface_client_get_path(pa_hashmap_get(c->clients, PA_UINT32_TO_PTR(my_client->index)));
+}
+
+static void handle_get_my_client(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char *my_client;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ my_client = get_my_client(c, conn);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &my_client);
+}
+
+static void handle_get_extensions(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char **extensions;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ extensions = pa_dbus_protocol_get_extensions(c->dbus_protocol, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_STRING, extensions, n);
+
+ pa_xfree(extensions);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t interface_revision;
+ const char *server_name;
+ const char *version;
+ dbus_bool_t is_local;
+ char *username;
+ char *hostname;
+ dbus_uint32_t *default_channels;
+ unsigned n_default_channels;
+ dbus_uint32_t default_sample_format;
+ dbus_uint32_t default_sample_rate;
+ const char **cards;
+ unsigned n_cards;
+ const char **sinks;
+ unsigned n_sinks;
+ const char *fallback_sink;
+ const char **sources;
+ unsigned n_sources;
+ const char *fallback_source;
+ const char **playback_streams;
+ unsigned n_playback_streams;
+ const char **record_streams;
+ unsigned n_record_streams;
+ const char **samples;
+ unsigned n_samples;
+ const char **modules;
+ unsigned n_modules;
+ const char **clients;
+ unsigned n_clients;
+ const char *my_client;
+ const char **extensions;
+ unsigned n_extensions;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ interface_revision = INTERFACE_REVISION;
+ server_name = PACKAGE_NAME;
+ version = PACKAGE_VERSION;
+ is_local = get_is_local(conn);
+ username = pa_get_user_name_malloc();
+ hostname = pa_get_host_name_malloc();
+ default_channels = get_default_channels(c, &n_default_channels);
+ default_sample_format = c->core->default_sample_spec.format;
+ default_sample_rate = c->core->default_sample_spec.rate;
+ cards = get_cards(c, &n_cards);
+ sinks = get_sinks(c, &n_sinks);
+ fallback_sink = c->fallback_sink
+ ? pa_dbusiface_device_get_path(pa_hashmap_get(c->sinks_by_index, PA_UINT32_TO_PTR(c->fallback_sink->index)))
+ : NULL;
+ sources = get_sources(c, &n_sources);
+ fallback_source = c->fallback_source
+ ? pa_dbusiface_device_get_path(pa_hashmap_get(c->sources_by_index,
+ PA_UINT32_TO_PTR(c->fallback_source->index)))
+ : NULL;
+ playback_streams = get_playback_streams(c, &n_playback_streams);
+ record_streams = get_record_streams(c, &n_record_streams);
+ samples = get_samples(c, &n_samples);
+ modules = get_modules(c, &n_modules);
+ clients = get_clients(c, &n_clients);
+ my_client = get_my_client(c, conn);
+ extensions = pa_dbus_protocol_get_extensions(c->dbus_protocol, &n_extensions);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INTERFACE_REVISION].property_name, DBUS_TYPE_UINT32, &interface_revision);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &server_name);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_VERSION].property_name, DBUS_TYPE_STRING, &version);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_IS_LOCAL].property_name, DBUS_TYPE_BOOLEAN, &is_local);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_USERNAME].property_name, DBUS_TYPE_STRING, &username);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_HOSTNAME].property_name, DBUS_TYPE_STRING, &hostname);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DEFAULT_CHANNELS].property_name, DBUS_TYPE_UINT32, default_channels, n_default_channels);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DEFAULT_SAMPLE_FORMAT].property_name, DBUS_TYPE_UINT32, &default_sample_format);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DEFAULT_SAMPLE_RATE].property_name, DBUS_TYPE_UINT32, &default_sample_rate);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CARDS].property_name, DBUS_TYPE_OBJECT_PATH, cards, n_cards);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SINKS].property_name, DBUS_TYPE_OBJECT_PATH, sinks, n_sinks);
+
+ if (fallback_sink)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_FALLBACK_SINK].property_name, DBUS_TYPE_OBJECT_PATH, &fallback_sink);
+
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SOURCES].property_name, DBUS_TYPE_OBJECT_PATH, sources, n_sources);
+
+ if (fallback_source)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_FALLBACK_SOURCE].property_name, DBUS_TYPE_OBJECT_PATH, &fallback_source);
+
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PLAYBACK_STREAMS].property_name, DBUS_TYPE_OBJECT_PATH, playback_streams, n_playback_streams);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_RECORD_STREAMS].property_name, DBUS_TYPE_OBJECT_PATH, record_streams, n_record_streams);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLES].property_name, DBUS_TYPE_OBJECT_PATH, samples, n_samples);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_MODULES].property_name, DBUS_TYPE_OBJECT_PATH, modules, n_modules);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CLIENTS].property_name, DBUS_TYPE_OBJECT_PATH, clients, n_clients);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_MY_CLIENT].property_name, DBUS_TYPE_OBJECT_PATH, &my_client);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_EXTENSIONS].property_name, DBUS_TYPE_STRING, extensions, n_extensions);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+
+ pa_xfree(username);
+ pa_xfree(hostname);
+ pa_xfree(default_channels);
+ pa_xfree(cards);
+ pa_xfree(sinks);
+ pa_xfree(sources);
+ pa_xfree(playback_streams);
+ pa_xfree(record_streams);
+ pa_xfree(samples);
+ pa_xfree(modules);
+ pa_xfree(clients);
+ pa_xfree(extensions);
+}
+
+static void handle_get_card_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ char *card_name;
+ pa_card *card;
+ pa_dbusiface_card *dbus_card;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &card_name, DBUS_TYPE_INVALID));
+
+ if (!(card = pa_namereg_get(c->core, card_name, PA_NAMEREG_CARD))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "No such card.");
+ return;
+ }
+
+ pa_assert_se((dbus_card = pa_hashmap_get(c->cards, PA_UINT32_TO_PTR(card->index))));
+
+ object_path = pa_dbusiface_card_get_path(dbus_card);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_get_sink_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ char *sink_name;
+ pa_sink *sink;
+ pa_dbusiface_device *dbus_sink;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &sink_name, DBUS_TYPE_INVALID));
+
+ if (!(sink = pa_namereg_get(c->core, sink_name, PA_NAMEREG_SINK))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such sink.", sink_name);
+ return;
+ }
+
+ pa_assert_se((dbus_sink = pa_hashmap_get(c->sinks_by_index, PA_UINT32_TO_PTR(sink->index))));
+
+ object_path = pa_dbusiface_device_get_path(dbus_sink);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_get_source_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ char *source_name;
+ pa_source *source;
+ pa_dbusiface_device *dbus_source;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &source_name, DBUS_TYPE_INVALID));
+
+ if (!(source = pa_namereg_get(c->core, source_name, PA_NAMEREG_SOURCE))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such source.", source_name);
+ return;
+ }
+
+ pa_assert_se((dbus_source = pa_hashmap_get(c->sources_by_index, PA_UINT32_TO_PTR(source->index))));
+
+ object_path = pa_dbusiface_device_get_path(dbus_source);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_get_sample_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ char *sample_name;
+ pa_scache_entry *sample;
+ pa_dbusiface_sample *dbus_sample;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &sample_name, DBUS_TYPE_INVALID));
+
+ if (!(sample = pa_namereg_get(c->core, sample_name, PA_NAMEREG_SAMPLE))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "No such sample.");
+ return;
+ }
+
+ pa_assert_se((dbus_sample = pa_hashmap_get(c->samples, PA_UINT32_TO_PTR(sample->index))));
+
+ object_path = pa_dbusiface_sample_get_path(dbus_sample);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_upload_sample(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ DBusMessageIter msg_iter;
+ DBusMessageIter array_iter;
+ const char *name;
+ dbus_uint32_t sample_format;
+ dbus_uint32_t sample_rate;
+ const dbus_uint32_t *channels;
+ int n_channels;
+ const dbus_uint32_t *default_volume;
+ int n_volume_entries;
+ pa_proplist *property_list;
+ const uint8_t *data;
+ int data_length;
+ int i;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ pa_memchunk chunk;
+ uint32_t idx;
+ pa_dbusiface_sample *dbus_sample = NULL;
+ pa_scache_entry *sample = NULL;
+ const char *object_path;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ chunk.memblock = NULL;
+
+ pa_assert_se(dbus_message_iter_init(msg, &msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &name);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &sample_format);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &sample_rate);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_recurse(&msg_iter, &array_iter);
+ dbus_message_iter_get_fixed_array(&array_iter, &channels, &n_channels);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_recurse(&msg_iter, &array_iter);
+ dbus_message_iter_get_fixed_array(&array_iter, &default_volume, &n_volume_entries);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ if (!(property_list = pa_dbus_get_proplist_arg(conn, msg, &msg_iter)))
+ return;
+
+ dbus_message_iter_recurse(&msg_iter, &array_iter);
+ dbus_message_iter_get_fixed_array(&array_iter, &data, &data_length);
+
+ if (sample_format >= PA_SAMPLE_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid sample format.");
+ goto finish;
+ }
+
+ if (sample_rate <= 0 || sample_rate > PA_RATE_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid sample rate.");
+ goto finish;
+ }
+
+ if (n_channels <= 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Empty channel map.");
+ goto finish;
+ }
+
+ if (n_channels > (int) PA_CHANNELS_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS,
+ "Too many channels: %i. The maximum is %u.", n_channels, PA_CHANNELS_MAX);
+ goto finish;
+ }
+
+ for (i = 0; i < n_channels; ++i) {
+ if (channels[i] >= PA_CHANNEL_POSITION_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid channel position.");
+ goto finish;
+ }
+ }
+
+ if (n_volume_entries != 0 && n_volume_entries != n_channels) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS,
+ "The channels and default_volume arguments have different number of elements (%i and %i, resp).",
+ n_channels, n_volume_entries);
+ goto finish;
+ }
+
+ for (i = 0; i < n_volume_entries; ++i) {
+ if (!PA_VOLUME_IS_VALID(default_volume[i])) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid volume: %u.", default_volume[i]);
+ goto finish;
+ }
+ }
+
+ if (data_length == 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Empty data.");
+ goto finish;
+ }
+
+ if (data_length > PA_SCACHE_ENTRY_SIZE_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS,
+ "Too big sample: %i bytes. The maximum sample length is %u bytes.",
+ data_length, PA_SCACHE_ENTRY_SIZE_MAX);
+ goto finish;
+ }
+
+ ss.format = sample_format;
+ ss.rate = sample_rate;
+ ss.channels = n_channels;
+
+ pa_assert(pa_sample_spec_valid(&ss));
+
+ if (!pa_frame_aligned(data_length, &ss)) {
+ char buf[PA_SAMPLE_SPEC_SNPRINT_MAX];
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS,
+ "The sample length (%i bytes) doesn't align with the sample format and channels (%s).",
+ data_length, pa_sample_spec_snprint(buf, sizeof(buf), &ss));
+ goto finish;
+ }
+
+ map.channels = n_channels;
+ for (i = 0; i < n_channels; ++i)
+ map.map[i] = channels[i];
+
+ chunk.memblock = pa_memblock_new(c->core->mempool, data_length);
+ chunk.index = 0;
+ chunk.length = data_length;
+
+ memcpy(pa_memblock_acquire(chunk.memblock), data, data_length);
+ pa_memblock_release(chunk.memblock);
+
+ if (pa_scache_add_item(c->core, name, &ss, &map, &chunk, property_list, &idx) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "Adding the sample failed.");
+ goto finish;
+ }
+
+ sample = pa_idxset_get_by_index(c->core->scache, idx);
+
+ if (n_volume_entries > 0) {
+ sample->volume.channels = n_channels;
+ for (i = 0; i < n_volume_entries; ++i)
+ sample->volume.values[i] = default_volume[i];
+ sample->volume_is_set = TRUE;
+ } else {
+ sample->volume_is_set = FALSE;
+ }
+
+ dbus_sample = pa_dbusiface_sample_new(c, sample);
+ pa_hashmap_put(c->samples, PA_UINT32_TO_PTR(idx), dbus_sample);
+
+ object_path = pa_dbusiface_sample_get_path(dbus_sample);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+
+finish:
+ if (property_list)
+ pa_proplist_free(property_list);
+
+ if (chunk.memblock)
+ pa_memblock_unref(chunk.memblock);
+}
+
+static pa_bool_t contains_space(const char *string) {
+ const char *p;
+
+ pa_assert(string);
+
+ for (p = string; *p; ++p) {
+ if (isspace(*p))
+ return TRUE;
+ }
+
+ return FALSE;
+}
+
+static void handle_load_module(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ DBusMessageIter dict_entry_iter;
+ char *name = NULL;
+ const char *key = NULL;
+ const char *value = NULL;
+ char *escaped_value = NULL;
+ pa_strbuf *arg_buffer = NULL;
+ char *arg_string = NULL;
+ pa_module *module = NULL;
+ pa_dbusiface_module *dbus_module = NULL;
+ const char *object_path = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (c->core->disallow_module_loading) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_ACCESS_DENIED, "The server is configured to disallow module loading.");
+ return;
+ }
+
+ pa_assert_se(dbus_message_iter_init(msg, &msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &name);
+
+ arg_buffer = pa_strbuf_new();
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_recurse(&msg_iter, &dict_iter);
+
+ while (dbus_message_iter_get_arg_type(&dict_iter) != DBUS_TYPE_INVALID) {
+ if (!pa_strbuf_isempty(arg_buffer))
+ pa_strbuf_putc(arg_buffer, ' ');
+
+ dbus_message_iter_recurse(&dict_iter, &dict_entry_iter);
+
+ dbus_message_iter_get_basic(&dict_entry_iter, &key);
+
+ if (strlen(key) <= 0 || !pa_ascii_valid(key) || contains_space(key)) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid module argument name: %s", key);
+ goto finish;
+ }
+
+ pa_assert_se(dbus_message_iter_next(&dict_entry_iter));
+ dbus_message_iter_get_basic(&dict_entry_iter, &value);
+
+ escaped_value = pa_escape(value, "\"");
+ pa_strbuf_printf(arg_buffer, "%s=\"%s\"", key, escaped_value);
+ pa_xfree(escaped_value);
+
+ dbus_message_iter_next(&dict_iter);
+ }
+
+ arg_string = pa_strbuf_tostring(arg_buffer);
+
+ if (!(module = pa_module_load(c->core, name, arg_string))) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "Failed to load module.");
+ goto finish;
+ }
+
+ dbus_module = pa_dbusiface_module_new(module);
+ pa_hashmap_put(c->modules, PA_UINT32_TO_PTR(module->index), dbus_module);
+
+ object_path = pa_dbusiface_module_get_path(dbus_module);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+
+finish:
+ if (arg_buffer)
+ pa_strbuf_free(arg_buffer);
+
+ pa_xfree(arg_string);
+}
+
+static void handle_exit(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ if (c->core->disallow_exit) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_ACCESS_DENIED, "The server is configured to disallow exiting.");
+ return;
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ pa_core_exit(c->core, FALSE, 0);
+}
+
+static void handle_listen_for_signal(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char *signal_str;
+ char **objects = NULL;
+ int n_objects;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL,
+ DBUS_TYPE_STRING, &signal_str,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_OBJECT_PATH, &objects, &n_objects,
+ DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_add_signal_listener(c->dbus_protocol, conn, *signal_str ? signal_str : NULL, objects, n_objects);
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ dbus_free_string_array(objects);
+}
+
+static void handle_stop_listening_for_signal(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ const char *signal_str;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &signal_str, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_remove_signal_listener(c->dbus_protocol, conn, *signal_str ? signal_str : NULL);
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void subscription_cb(pa_core *core, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ pa_dbusiface_core *c = userdata;
+ pa_dbusiface_card *card_iface = NULL;
+ pa_dbusiface_device *device_iface = NULL;
+ pa_dbusiface_stream *stream_iface = NULL;
+ pa_dbusiface_sample *sample_iface = NULL;
+ pa_dbusiface_module *module_iface = NULL;
+ pa_dbusiface_client *client_iface = NULL;
+ DBusMessage *signal_msg = NULL;
+ const char *object_path = NULL;
+ pa_sink *new_fallback_sink = NULL;
+ pa_source *new_fallback_source = NULL;
+
+ pa_assert(c);
+
+ switch (t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) {
+ case PA_SUBSCRIPTION_EVENT_SERVER:
+ new_fallback_sink = pa_namereg_get_default_sink(core);
+ new_fallback_source = pa_namereg_get_default_source(core);
+
+ if (c->fallback_sink != new_fallback_sink) {
+ if (c->fallback_sink)
+ pa_sink_unref(c->fallback_sink);
+ c->fallback_sink = new_fallback_sink ? pa_sink_ref(new_fallback_sink) : NULL;
+
+ if (c->fallback_sink) {
+ pa_assert_se(device_iface = pa_hashmap_get(c->sinks_by_index, PA_UINT32_TO_PTR(c->fallback_sink->index)));
+ object_path = pa_dbusiface_device_get_path(device_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_FALLBACK_SINK_UPDATED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+
+ } else {
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_FALLBACK_SINK_UNSET].name)));
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+ }
+
+ if (c->fallback_source != new_fallback_source) {
+ if (c->fallback_source)
+ pa_source_unref(c->fallback_source);
+ c->fallback_source = new_fallback_source ? pa_source_ref(new_fallback_source) : NULL;
+
+ if (c->fallback_source) {
+ pa_assert_se(device_iface = pa_hashmap_get(c->sources_by_index, PA_UINT32_TO_PTR(c->fallback_source->index)));
+ object_path = pa_dbusiface_device_get_path(device_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_FALLBACK_SOURCE_UPDATED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+
+ } else {
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_FALLBACK_SOURCE_UNSET].name)));
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+ }
+ break;
+
+ case PA_SUBSCRIPTION_EVENT_CARD:
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_NEW) {
+ if (!(card_iface = pa_hashmap_get(c->cards, PA_UINT32_TO_PTR(idx)))) {
+ pa_card *card = NULL;
+
+ if (!(card = pa_idxset_get_by_index(core->cards, idx)))
+ return; /* The card was removed immediately after creation. */
+
+ card_iface = pa_dbusiface_card_new(c, card);
+ pa_hashmap_put(c->cards, PA_UINT32_TO_PTR(idx), card_iface);
+ }
+
+ object_path = pa_dbusiface_card_get_path(card_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_CARD].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ } else if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_REMOVE) {
+ if (!(card_iface = pa_hashmap_remove(c->cards, PA_UINT32_TO_PTR(idx))))
+ return;
+
+ object_path = pa_dbusiface_card_get_path(card_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_CARD_REMOVED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbusiface_card_free(card_iface);
+ }
+ break;
+
+ case PA_SUBSCRIPTION_EVENT_SINK_INPUT:
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_NEW) {
+ pa_sink_input *sink_input = NULL;
+
+ if (!(sink_input = pa_idxset_get_by_index(core->sink_inputs, idx)))
+ return; /* The sink input was removed immediately after creation. */
+
+ if (!(stream_iface = pa_hashmap_get(c->playback_streams, PA_UINT32_TO_PTR(idx)))) {
+ stream_iface = pa_dbusiface_stream_new_playback(c, sink_input);
+ pa_hashmap_put(c->playback_streams, PA_UINT32_TO_PTR(idx), stream_iface);
+ }
+
+ object_path = pa_dbusiface_stream_get_path(stream_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_PLAYBACK_STREAM].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ } else if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_REMOVE) {
+ if (!(stream_iface = pa_hashmap_remove(c->playback_streams, PA_UINT32_TO_PTR(idx))))
+ return;
+
+ object_path = pa_dbusiface_stream_get_path(stream_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_PLAYBACK_STREAM_REMOVED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbusiface_stream_free(stream_iface);
+ }
+ break;
+
+ case PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT:
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_NEW) {
+ pa_source_output *source_output = NULL;
+
+ if (!(source_output = pa_idxset_get_by_index(core->source_outputs, idx)))
+ return; /* The source output was removed immediately after creation. */
+
+ if (!(stream_iface = pa_hashmap_get(c->record_streams, PA_UINT32_TO_PTR(idx)))) {
+ stream_iface = pa_dbusiface_stream_new_record(c, source_output);
+ pa_hashmap_put(c->record_streams, PA_UINT32_TO_PTR(idx), stream_iface);
+ }
+
+ object_path = pa_dbusiface_stream_get_path(stream_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_RECORD_STREAM].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ } else if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_REMOVE) {
+ if (!(stream_iface = pa_hashmap_remove(c->record_streams, PA_UINT32_TO_PTR(idx))))
+ return;
+
+ object_path = pa_dbusiface_stream_get_path(stream_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_RECORD_STREAM_REMOVED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbusiface_stream_free(stream_iface);
+ }
+ break;
+
+ case PA_SUBSCRIPTION_EVENT_SAMPLE_CACHE:
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_NEW) {
+ pa_scache_entry *sample = NULL;
+
+ if (!(sample = pa_idxset_get_by_index(core->scache, idx)))
+ return; /* The sample was removed immediately after creation. */
+
+ if (!(sample_iface = pa_hashmap_get(c->samples, PA_UINT32_TO_PTR(idx)))) {
+ sample_iface = pa_dbusiface_sample_new(c, sample);
+ pa_hashmap_put(c->samples, PA_UINT32_TO_PTR(idx), sample_iface);
+ }
+
+ object_path = pa_dbusiface_sample_get_path(sample_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_SAMPLE].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ } else if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_REMOVE) {
+ if (!(sample_iface = pa_hashmap_remove(c->samples, PA_UINT32_TO_PTR(idx))))
+ return;
+
+ object_path = pa_dbusiface_sample_get_path(sample_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_SAMPLE_REMOVED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbusiface_sample_free(sample_iface);
+ }
+ break;
+
+ case PA_SUBSCRIPTION_EVENT_MODULE:
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_NEW) {
+ pa_module *module = NULL;
+
+ if (!(module = pa_idxset_get_by_index(core->modules, idx)))
+ return; /* The module was removed immediately after creation. */
+
+ if (!(module_iface = pa_hashmap_get(c->modules, PA_UINT32_TO_PTR(idx)))) {
+ module_iface = pa_dbusiface_module_new(module);
+ pa_hashmap_put(c->modules, PA_UINT32_TO_PTR(idx), module_iface);
+ }
+
+ object_path = pa_dbusiface_module_get_path(module_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_MODULE].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ } else if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_REMOVE) {
+ if (!(module_iface = pa_hashmap_remove(c->modules, PA_UINT32_TO_PTR(idx))))
+ return;
+
+ object_path = pa_dbusiface_module_get_path(module_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_MODULE_REMOVED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbusiface_module_free(module_iface);
+ }
+ break;
+
+ case PA_SUBSCRIPTION_EVENT_CLIENT:
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_NEW) {
+ pa_client *client = NULL;
+
+ if (!(client = pa_idxset_get_by_index(core->clients, idx)))
+ return; /* The client was removed immediately after creation. */
+
+ if (!(client_iface = pa_hashmap_get(c->clients, PA_UINT32_TO_PTR(idx)))) {
+ client_iface = pa_dbusiface_client_new(c, client);
+ pa_hashmap_put(c->clients, PA_UINT32_TO_PTR(idx), client_iface);
+ }
+
+ object_path = pa_dbusiface_client_get_path(client_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_CLIENT].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ } else if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) == PA_SUBSCRIPTION_EVENT_REMOVE) {
+ if (!(client_iface = pa_hashmap_remove(c->clients, PA_UINT32_TO_PTR(idx))))
+ return;
+
+ object_path = pa_dbusiface_client_get_path(client_iface);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_CLIENT_REMOVED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbusiface_client_free(client_iface);
+ }
+ break;
+ }
+
+ if (signal_msg) {
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ }
+}
+
+static pa_hook_result_t sink_put_cb(void *hook_data, void *call_data, void *slot_data) {
+ pa_dbusiface_core *c = slot_data;
+ pa_sink *s = call_data;
+ pa_dbusiface_device *d = NULL;
+ const char *object_path = NULL;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(c);
+ pa_assert(s);
+
+ d = pa_dbusiface_device_new_sink(c, s);
+ object_path = pa_dbusiface_device_get_path(d);
+
+ pa_assert_se(pa_hashmap_put(c->sinks_by_index, PA_UINT32_TO_PTR(s->index), d) >= 0);
+ pa_assert_se(pa_hashmap_put(c->sinks_by_path, object_path, d) >= 0);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_SINK].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_unlink_cb(void *hook_data, void *call_data, void *slot_data) {
+ pa_dbusiface_core *c = slot_data;
+ pa_sink *s = call_data;
+ pa_dbusiface_device *d = NULL;
+ const char *object_path = NULL;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(c);
+ pa_assert(s);
+
+ pa_assert_se(d = pa_hashmap_remove(c->sinks_by_index, PA_UINT32_TO_PTR(s->index)));
+ object_path = pa_dbusiface_device_get_path(d);
+ pa_assert_se(pa_hashmap_remove(c->sinks_by_path, object_path));
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_SINK_REMOVED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+
+ pa_dbusiface_device_free(d);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_put_cb(void *hook_data, void *call_data, void *slot_data) {
+ pa_dbusiface_core *c = slot_data;
+ pa_source *s = call_data;
+ pa_dbusiface_device *d = NULL;
+ const char *object_path = NULL;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(c);
+ pa_assert(s);
+
+ d = pa_dbusiface_device_new_source(c, s);
+ object_path = pa_dbusiface_device_get_path(d);
+
+ pa_assert_se(pa_hashmap_put(c->sources_by_index, PA_UINT32_TO_PTR(s->index), d) >= 0);
+ pa_assert_se(pa_hashmap_put(c->sources_by_path, object_path, d) >= 0);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_SOURCE].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_unlink_cb(void *hook_data, void *call_data, void *slot_data) {
+ pa_dbusiface_core *c = slot_data;
+ pa_source *s = call_data;
+ pa_dbusiface_device *d = NULL;
+ const char *object_path = NULL;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(c);
+ pa_assert(s);
+
+ pa_assert_se(d = pa_hashmap_remove(c->sources_by_index, PA_UINT32_TO_PTR(s->index)));
+ object_path = pa_dbusiface_device_get_path(d);
+ pa_assert_se(pa_hashmap_remove(c->sources_by_path, object_path));
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_SOURCE_REMOVED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+
+ pa_dbusiface_device_free(d);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t extension_registered_cb(void *hook_data, void *call_data, void *slot_data) {
+ pa_dbusiface_core *c = slot_data;
+ const char *ext_name = call_data;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(c);
+ pa_assert(ext_name);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_NEW_EXTENSION].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_STRING, &ext_name, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t extension_unregistered_cb(void *hook_data, void *call_data, void *slot_data) {
+ pa_dbusiface_core *c = slot_data;
+ const char *ext_name = call_data;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(c);
+ pa_assert(ext_name);
+
+ pa_assert_se((signal_msg = dbus_message_new_signal(PA_DBUS_CORE_OBJECT_PATH,
+ PA_DBUS_CORE_INTERFACE,
+ signals[SIGNAL_EXTENSION_REMOVED].name)));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_STRING, &ext_name, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(c->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+
+ return PA_HOOK_OK;
+}
+
+pa_dbusiface_core *pa_dbusiface_core_new(pa_core *core) {
+ pa_dbusiface_core *c;
+ pa_card *card;
+ pa_sink *sink;
+ pa_source *source;
+ pa_dbusiface_device *device;
+ pa_sink_input *sink_input;
+ pa_source_output *source_output;
+ pa_scache_entry *sample;
+ pa_module *module;
+ pa_client *client;
+ uint32_t idx;
+
+ pa_assert(core);
+
+ c = pa_xnew(pa_dbusiface_core, 1);
+ c->core = core;
+ c->subscription = pa_subscription_new(core, PA_SUBSCRIPTION_MASK_ALL, subscription_cb, c);
+ c->dbus_protocol = pa_dbus_protocol_get(core);
+ c->cards = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->sinks_by_index = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->sinks_by_path = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ c->sources_by_index = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->sources_by_path = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ c->playback_streams = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->record_streams = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->samples = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->modules = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->clients = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->fallback_sink = pa_namereg_get_default_sink(core);
+ c->fallback_source = pa_namereg_get_default_source(core);
+ c->sink_put_slot = pa_hook_connect(&core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_NORMAL, sink_put_cb, c);
+ c->sink_unlink_slot = pa_hook_connect(&core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_NORMAL, sink_unlink_cb, c);
+ c->source_put_slot = pa_hook_connect(&core->hooks[PA_CORE_HOOK_SOURCE_PUT], PA_HOOK_NORMAL, source_put_cb, c);
+ c->source_unlink_slot = pa_hook_connect(&core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_NORMAL, source_unlink_cb, c);
+ c->extension_registered_slot = pa_dbus_protocol_hook_connect(c->dbus_protocol,
+ PA_DBUS_PROTOCOL_HOOK_EXTENSION_REGISTERED,
+ PA_HOOK_NORMAL,
+ extension_registered_cb,
+ c);
+ c->extension_unregistered_slot = pa_dbus_protocol_hook_connect(c->dbus_protocol,
+ PA_DBUS_PROTOCOL_HOOK_EXTENSION_UNREGISTERED,
+ PA_HOOK_NORMAL,
+ extension_unregistered_cb,
+ c);
+ c->memstats = pa_dbusiface_memstats_new(c, core);
+
+ if (c->fallback_sink)
+ pa_sink_ref(c->fallback_sink);
+ if (c->fallback_source)
+ pa_source_ref(c->fallback_source);
+
+ PA_IDXSET_FOREACH(card, core->cards, idx)
+ pa_hashmap_put(c->cards, PA_UINT32_TO_PTR(idx), pa_dbusiface_card_new(c, card));
+
+ PA_IDXSET_FOREACH(sink, core->sinks, idx) {
+ device = pa_dbusiface_device_new_sink(c, sink);
+ pa_hashmap_put(c->sinks_by_index, PA_UINT32_TO_PTR(idx), device);
+ pa_hashmap_put(c->sinks_by_path, pa_dbusiface_device_get_path(device), device);
+ }
+
+ PA_IDXSET_FOREACH(source, core->sources, idx) {
+ device = pa_dbusiface_device_new_source(c, source);
+ pa_hashmap_put(c->sources_by_index, PA_UINT32_TO_PTR(idx), device);
+ pa_hashmap_put(c->sources_by_path, pa_dbusiface_device_get_path(device), device);
+ }
+
+ PA_IDXSET_FOREACH(sink_input, core->sink_inputs, idx)
+ pa_hashmap_put(c->playback_streams, PA_UINT32_TO_PTR(idx), pa_dbusiface_stream_new_playback(c, sink_input));
+
+ PA_IDXSET_FOREACH(source_output, core->source_outputs, idx)
+ pa_hashmap_put(c->record_streams, PA_UINT32_TO_PTR(idx), pa_dbusiface_stream_new_record(c, source_output));
+
+ PA_IDXSET_FOREACH(sample, core->scache, idx)
+ pa_hashmap_put(c->samples, PA_UINT32_TO_PTR(idx), pa_dbusiface_sample_new(c, sample));
+
+ PA_IDXSET_FOREACH(module, core->modules, idx)
+ pa_hashmap_put(c->modules, PA_UINT32_TO_PTR(idx), pa_dbusiface_module_new(module));
+
+ PA_IDXSET_FOREACH(client, core->clients, idx)
+ pa_hashmap_put(c->clients, PA_UINT32_TO_PTR(idx), pa_dbusiface_client_new(c, client));
+
+ pa_assert_se(pa_dbus_protocol_add_interface(c->dbus_protocol, PA_DBUS_CORE_OBJECT_PATH, &core_interface_info, c) >= 0);
+
+ return c;
+}
+
+static void free_card_cb(void *p, void *userdata) {
+ pa_dbusiface_card *c = p;
+
+ pa_assert(c);
+
+ pa_dbusiface_card_free(c);
+}
+
+static void free_device_cb(void *p, void *userdata) {
+ pa_dbusiface_device *d = p;
+
+ pa_assert(d);
+
+ pa_dbusiface_device_free(d);
+}
+
+static void free_stream_cb(void *p, void *userdata) {
+ pa_dbusiface_stream *s = p;
+
+ pa_assert(s);
+
+ pa_dbusiface_stream_free(s);
+}
+
+static void free_sample_cb(void *p, void *userdata) {
+ pa_dbusiface_sample *s = p;
+
+ pa_assert(s);
+
+ pa_dbusiface_sample_free(s);
+}
+
+static void free_module_cb(void *p, void *userdata) {
+ pa_dbusiface_module *m = p;
+
+ pa_assert(m);
+
+ pa_dbusiface_module_free(m);
+}
+
+static void free_client_cb(void *p, void *userdata) {
+ pa_dbusiface_client *c = p;
+
+ pa_assert(c);
+
+ pa_dbusiface_client_free(c);
+}
+
+void pa_dbusiface_core_free(pa_dbusiface_core *c) {
+ pa_assert(c);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(c->dbus_protocol, PA_DBUS_CORE_OBJECT_PATH, core_interface_info.name) >= 0);
+
+ pa_subscription_free(c->subscription);
+ pa_hashmap_free(c->cards, free_card_cb, NULL);
+ pa_hashmap_free(c->sinks_by_index, free_device_cb, NULL);
+ pa_hashmap_free(c->sinks_by_path, NULL, NULL);
+ pa_hashmap_free(c->sources_by_index, free_device_cb, NULL);
+ pa_hashmap_free(c->sources_by_path, NULL, NULL);
+ pa_hashmap_free(c->playback_streams, free_stream_cb, NULL);
+ pa_hashmap_free(c->record_streams, free_stream_cb, NULL);
+ pa_hashmap_free(c->samples, free_sample_cb, NULL);
+ pa_hashmap_free(c->modules, free_module_cb, NULL);
+ pa_hashmap_free(c->clients, free_client_cb, NULL);
+ pa_hook_slot_free(c->sink_put_slot);
+ pa_hook_slot_free(c->sink_unlink_slot);
+ pa_hook_slot_free(c->source_put_slot);
+ pa_hook_slot_free(c->source_unlink_slot);
+ pa_hook_slot_free(c->extension_registered_slot);
+ pa_hook_slot_free(c->extension_unregistered_slot);
+ pa_dbusiface_memstats_free(c->memstats);
+
+ if (c->fallback_sink)
+ pa_sink_unref(c->fallback_sink);
+ if (c->fallback_source)
+ pa_source_unref(c->fallback_source);
+
+ pa_dbus_protocol_unref(c->dbus_protocol);
+
+ pa_xfree(c);
+}
+
+const char *pa_dbusiface_core_get_card_path(pa_dbusiface_core *c, const pa_card *card) {
+ pa_assert(c);
+ pa_assert(card);
+
+ return pa_dbusiface_card_get_path(pa_hashmap_get(c->cards, PA_UINT32_TO_PTR(card->index)));
+}
+
+const char *pa_dbusiface_core_get_sink_path(pa_dbusiface_core *c, const pa_sink *sink) {
+ pa_assert(c);
+ pa_assert(sink);
+
+ return pa_dbusiface_device_get_path(pa_hashmap_get(c->sinks_by_index, PA_UINT32_TO_PTR(sink->index)));
+}
+
+const char *pa_dbusiface_core_get_source_path(pa_dbusiface_core *c, const pa_source *source) {
+ pa_assert(c);
+ pa_assert(source);
+
+ return pa_dbusiface_device_get_path(pa_hashmap_get(c->sources_by_index, PA_UINT32_TO_PTR(source->index)));
+}
+
+const char *pa_dbusiface_core_get_playback_stream_path(pa_dbusiface_core *c, const pa_sink_input *sink_input) {
+ pa_assert(c);
+ pa_assert(sink_input);
+
+ return pa_dbusiface_stream_get_path(pa_hashmap_get(c->playback_streams, PA_UINT32_TO_PTR(sink_input->index)));
+}
+
+const char *pa_dbusiface_core_get_record_stream_path(pa_dbusiface_core *c, const pa_source_output *source_output) {
+ pa_assert(c);
+ pa_assert(source_output);
+
+ return pa_dbusiface_stream_get_path(pa_hashmap_get(c->record_streams, PA_UINT32_TO_PTR(source_output->index)));
+}
+
+const char *pa_dbusiface_core_get_module_path(pa_dbusiface_core *c, const pa_module *module) {
+ pa_assert(c);
+ pa_assert(module);
+
+ return pa_dbusiface_module_get_path(pa_hashmap_get(c->modules, PA_UINT32_TO_PTR(module->index)));
+}
+
+const char *pa_dbusiface_core_get_client_path(pa_dbusiface_core *c, const pa_client *client) {
+ pa_assert(c);
+ pa_assert(client);
+
+ return pa_dbusiface_client_get_path(pa_hashmap_get(c->clients, PA_UINT32_TO_PTR(client->index)));
+}
+
+pa_sink *pa_dbusiface_core_get_sink(pa_dbusiface_core *c, const char *object_path) {
+ pa_dbusiface_device *device = NULL;
+
+ pa_assert(c);
+ pa_assert(object_path);
+
+ device = pa_hashmap_get(c->sinks_by_path, object_path);
+
+ if (device)
+ return pa_dbusiface_device_get_sink(device);
+ else
+ return NULL;
+}
+
+pa_source *pa_dbusiface_core_get_source(pa_dbusiface_core *c, const char *object_path) {
+ pa_dbusiface_device *device = NULL;
+
+ pa_assert(c);
+ pa_assert(object_path);
+
+ device = pa_hashmap_get(c->sources_by_path, object_path);
+
+ if (device)
+ return pa_dbusiface_device_get_source(device);
+ else
+ return NULL;
+}
diff --git a/src/modules/dbus/iface-core.h b/src/modules/dbus/iface-core.h
new file mode 100644
index 00000000..900b6d1c
--- /dev/null
+++ b/src/modules/dbus/iface-core.h
@@ -0,0 +1,52 @@
+#ifndef foodbusifacecorehfoo
+#define foodbusifacecorehfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the Core interface
+ * documentation.
+ */
+
+#include <pulsecore/core.h>
+
+typedef struct pa_dbusiface_core pa_dbusiface_core;
+
+pa_dbusiface_core *pa_dbusiface_core_new(pa_core *core);
+void pa_dbusiface_core_free(pa_dbusiface_core *c);
+
+const char *pa_dbusiface_core_get_card_path(pa_dbusiface_core *c, const pa_card *card);
+const char *pa_dbusiface_core_get_sink_path(pa_dbusiface_core *c, const pa_sink *sink);
+const char *pa_dbusiface_core_get_source_path(pa_dbusiface_core *c, const pa_source *source);
+const char *pa_dbusiface_core_get_playback_stream_path(pa_dbusiface_core *c, const pa_sink_input *sink_input);
+const char *pa_dbusiface_core_get_record_stream_path(pa_dbusiface_core *c, const pa_source_output *source_output);
+const char *pa_dbusiface_core_get_module_path(pa_dbusiface_core *c, const pa_module *module);
+const char *pa_dbusiface_core_get_client_path(pa_dbusiface_core *c, const pa_client *client);
+
+/* Returns NULL if there's no sink with the given path. */
+pa_sink *pa_dbusiface_core_get_sink(pa_dbusiface_core *c, const char *object_path);
+
+/* Returns NULL if there's no source with the given path. */
+pa_source *pa_dbusiface_core_get_source(pa_dbusiface_core *c, const char *object_path);
+
+#endif
diff --git a/src/modules/dbus/iface-device-port.c b/src/modules/dbus/iface-device-port.c
new file mode 100644
index 00000000..d403b6a2
--- /dev/null
+++ b/src/modules/dbus/iface-device-port.c
@@ -0,0 +1,190 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+
+#include "iface-device-port.h"
+
+#define OBJECT_NAME "port"
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_description(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_priority(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+struct pa_dbusiface_device_port {
+ uint32_t index;
+ pa_device_port *port;
+ char *path;
+ pa_dbus_protocol *dbus_protocol;
+};
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_NAME,
+ PROPERTY_HANDLER_DESCRIPTION,
+ PROPERTY_HANDLER_PRIORITY,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_get_name, .set_cb = NULL },
+ [PROPERTY_HANDLER_DESCRIPTION] = { .property_name = "Description", .type = "s", .get_cb = handle_get_description, .set_cb = NULL },
+ [PROPERTY_HANDLER_PRIORITY] = { .property_name = "Priority", .type = "u", .get_cb = handle_get_priority, .set_cb = NULL },
+};
+
+static pa_dbus_interface_info port_interface_info = {
+ .name = PA_DBUSIFACE_DEVICE_PORT_INTERFACE,
+ .method_handlers = NULL,
+ .n_method_handlers = 0,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = NULL,
+ .n_signals = 0
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device_port *p = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &p->index);
+}
+
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device_port *p = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &p->port->name);
+}
+
+static void handle_get_description(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device_port *p = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &p->port->description);
+}
+
+static void handle_get_priority(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device_port *p = userdata;
+ dbus_uint32_t priority = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ priority = p->port->priority;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &priority);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device_port *p = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t priority = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(p);
+
+ priority = p->port->priority;
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &p->index);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &p->port->name);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DESCRIPTION].property_name, DBUS_TYPE_STRING, &p->port->description);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PRIORITY].property_name, DBUS_TYPE_UINT32, &priority);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+pa_dbusiface_device_port *pa_dbusiface_device_port_new(
+ pa_dbusiface_device *device,
+ pa_core *core,
+ pa_device_port *port,
+ uint32_t idx) {
+ pa_dbusiface_device_port *p = NULL;
+
+ pa_assert(device);
+ pa_assert(core);
+ pa_assert(port);
+
+ p = pa_xnew(pa_dbusiface_device_port, 1);
+ p->index = idx;
+ p->port = port;
+ p->path = pa_sprintf_malloc("%s/%s%u", pa_dbusiface_device_get_path(device), OBJECT_NAME, idx);
+ p->dbus_protocol = pa_dbus_protocol_get(core);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(p->dbus_protocol, p->path, &port_interface_info, p) >= 0);
+
+ return p;
+}
+
+void pa_dbusiface_device_port_free(pa_dbusiface_device_port *p) {
+ pa_assert(p);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(p->dbus_protocol, p->path, port_interface_info.name) >= 0);
+
+ pa_dbus_protocol_unref(p->dbus_protocol);
+
+ pa_xfree(p->path);
+ pa_xfree(p);
+}
+
+const char *pa_dbusiface_device_port_get_path(pa_dbusiface_device_port *p) {
+ pa_assert(p);
+
+ return p->path;
+}
+
+const char *pa_dbusiface_device_port_get_name(pa_dbusiface_device_port *p) {
+ pa_assert(p);
+
+ return p->port->name;
+}
diff --git a/src/modules/dbus/iface-device-port.h b/src/modules/dbus/iface-device-port.h
new file mode 100644
index 00000000..0461e2ff
--- /dev/null
+++ b/src/modules/dbus/iface-device-port.h
@@ -0,0 +1,50 @@
+#ifndef foodbusifacedeviceporthfoo
+#define foodbusifacedeviceporthfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.DevicePort.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the DevicePort interface
+ * documentation.
+ */
+
+#include <pulsecore/protocol-dbus.h>
+#include <pulsecore/sink.h>
+
+#include "iface-device.h"
+
+#define PA_DBUSIFACE_DEVICE_PORT_INTERFACE PA_DBUS_CORE_INTERFACE ".DevicePort"
+
+typedef struct pa_dbusiface_device_port pa_dbusiface_device_port;
+
+pa_dbusiface_device_port *pa_dbusiface_device_port_new(
+ pa_dbusiface_device *device,
+ pa_core *core,
+ pa_device_port *port,
+ uint32_t idx);
+void pa_dbusiface_device_port_free(pa_dbusiface_device_port *p);
+
+const char *pa_dbusiface_device_port_get_path(pa_dbusiface_device_port *p);
+const char *pa_dbusiface_device_port_get_name(pa_dbusiface_device_port *p);
+
+#endif
diff --git a/src/modules/dbus/iface-device.c b/src/modules/dbus/iface-device.c
new file mode 100644
index 00000000..652790f0
--- /dev/null
+++ b/src/modules/dbus/iface-device.c
@@ -0,0 +1,1315 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-device-port.h"
+
+#include "iface-device.h"
+
+#define SINK_OBJECT_NAME "sink"
+#define SOURCE_OBJECT_NAME "source"
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_card(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_channels(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_volume(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_has_flat_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_has_convertible_to_decibel_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_base_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_volume_steps(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_mute(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_mute(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_has_hardware_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_has_hardware_mute(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_configured_latency(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_has_dynamic_latency(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_latency(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_is_hardware_device(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_is_network_device(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_state(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_ports(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_active_port(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_active_port(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_suspend(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_port_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_sink_get_monitor_source(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_sink_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_source_get_monitor_of_sink(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_source_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+enum device_type {
+ DEVICE_TYPE_SINK,
+ DEVICE_TYPE_SOURCE
+};
+
+struct pa_dbusiface_device {
+ pa_dbusiface_core *core;
+
+ union {
+ pa_sink *sink;
+ pa_source *source;
+ };
+ enum device_type type;
+ char *path;
+ pa_cvolume volume;
+ dbus_bool_t mute;
+ union {
+ pa_sink_state_t sink_state;
+ pa_source_state_t source_state;
+ };
+ pa_hashmap *ports;
+ uint32_t next_port_index;
+ pa_device_port *active_port;
+ pa_proplist *proplist;
+
+ pa_dbus_protocol *dbus_protocol;
+ pa_subscription *subscription;
+};
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_NAME,
+ PROPERTY_HANDLER_DRIVER,
+ PROPERTY_HANDLER_OWNER_MODULE,
+ PROPERTY_HANDLER_CARD,
+ PROPERTY_HANDLER_SAMPLE_FORMAT,
+ PROPERTY_HANDLER_SAMPLE_RATE,
+ PROPERTY_HANDLER_CHANNELS,
+ PROPERTY_HANDLER_VOLUME,
+ PROPERTY_HANDLER_HAS_FLAT_VOLUME,
+ PROPERTY_HANDLER_HAS_CONVERTIBLE_TO_DECIBEL_VOLUME,
+ PROPERTY_HANDLER_BASE_VOLUME,
+ PROPERTY_HANDLER_VOLUME_STEPS,
+ PROPERTY_HANDLER_MUTE,
+ PROPERTY_HANDLER_HAS_HARDWARE_VOLUME,
+ PROPERTY_HANDLER_HAS_HARDWARE_MUTE,
+ PROPERTY_HANDLER_CONFIGURED_LATENCY,
+ PROPERTY_HANDLER_HAS_DYNAMIC_LATENCY,
+ PROPERTY_HANDLER_LATENCY,
+ PROPERTY_HANDLER_IS_HARDWARE_DEVICE,
+ PROPERTY_HANDLER_IS_NETWORK_DEVICE,
+ PROPERTY_HANDLER_STATE,
+ PROPERTY_HANDLER_PORTS,
+ PROPERTY_HANDLER_ACTIVE_PORT,
+ PROPERTY_HANDLER_PROPERTY_LIST,
+ PROPERTY_HANDLER_MAX
+};
+
+enum sink_property_handler_index {
+ SINK_PROPERTY_HANDLER_MONITOR_SOURCE,
+ SINK_PROPERTY_HANDLER_MAX
+};
+
+enum source_property_handler_index {
+ SOURCE_PROPERTY_HANDLER_MONITOR_OF_SINK,
+ SOURCE_PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_get_name, .set_cb = NULL },
+ [PROPERTY_HANDLER_DRIVER] = { .property_name = "Driver", .type = "s", .get_cb = handle_get_driver, .set_cb = NULL },
+ [PROPERTY_HANDLER_OWNER_MODULE] = { .property_name = "OwnerModule", .type = "o", .get_cb = handle_get_owner_module, .set_cb = NULL },
+ [PROPERTY_HANDLER_CARD] = { .property_name = "Card", .type = "o", .get_cb = handle_get_card, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLE_FORMAT] = { .property_name = "SampleFormat", .type = "u", .get_cb = handle_get_sample_format, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLE_RATE] = { .property_name = "SampleRate", .type = "u", .get_cb = handle_get_sample_rate, .set_cb = NULL },
+ [PROPERTY_HANDLER_CHANNELS] = { .property_name = "Channels", .type = "au", .get_cb = handle_get_channels, .set_cb = NULL },
+ [PROPERTY_HANDLER_VOLUME] = { .property_name = "Volume", .type = "au", .get_cb = handle_get_volume, .set_cb = handle_set_volume },
+ [PROPERTY_HANDLER_HAS_FLAT_VOLUME] = { .property_name = "HasFlatVolume", .type = "b", .get_cb = handle_get_has_flat_volume, .set_cb = NULL },
+ [PROPERTY_HANDLER_HAS_CONVERTIBLE_TO_DECIBEL_VOLUME] = { .property_name = "HasConvertibleToDecibelVolume", .type = "b", .get_cb = handle_get_has_convertible_to_decibel_volume, .set_cb = NULL },
+ [PROPERTY_HANDLER_BASE_VOLUME] = { .property_name = "BaseVolume", .type = "u", .get_cb = handle_get_base_volume, .set_cb = NULL },
+ [PROPERTY_HANDLER_VOLUME_STEPS] = { .property_name = "VolumeSteps", .type = "u", .get_cb = handle_get_volume_steps, .set_cb = NULL },
+ [PROPERTY_HANDLER_MUTE] = { .property_name = "Mute", .type = "b", .get_cb = handle_get_mute, .set_cb = handle_set_mute },
+ [PROPERTY_HANDLER_HAS_HARDWARE_VOLUME] = { .property_name = "HasHardwareVolume", .type = "b", .get_cb = handle_get_has_hardware_volume, .set_cb = NULL },
+ [PROPERTY_HANDLER_HAS_HARDWARE_MUTE] = { .property_name = "HasHardwareMute", .type = "b", .get_cb = handle_get_has_hardware_mute, .set_cb = NULL },
+ [PROPERTY_HANDLER_CONFIGURED_LATENCY] = { .property_name = "ConfiguredLatency", .type = "t", .get_cb = handle_get_configured_latency, .set_cb = NULL },
+ [PROPERTY_HANDLER_HAS_DYNAMIC_LATENCY] = { .property_name = "HasDynamicLatency", .type = "b", .get_cb = handle_get_has_dynamic_latency, .set_cb = NULL },
+ [PROPERTY_HANDLER_LATENCY] = { .property_name = "Latency", .type = "t", .get_cb = handle_get_latency, .set_cb = NULL },
+ [PROPERTY_HANDLER_IS_HARDWARE_DEVICE] = { .property_name = "IsHardwareDevice", .type = "b", .get_cb = handle_get_is_hardware_device, .set_cb = NULL },
+ [PROPERTY_HANDLER_IS_NETWORK_DEVICE] = { .property_name = "IsNetworkDevice", .type = "b", .get_cb = handle_get_is_network_device, .set_cb = NULL },
+ [PROPERTY_HANDLER_STATE] = { .property_name = "State", .type = "u", .get_cb = handle_get_state, .set_cb = NULL },
+ [PROPERTY_HANDLER_PORTS] = { .property_name = "Ports", .type = "ao", .get_cb = handle_get_ports, .set_cb = NULL },
+ [PROPERTY_HANDLER_ACTIVE_PORT] = { .property_name = "ActivePort", .type = "o", .get_cb = handle_get_active_port, .set_cb = handle_set_active_port },
+ [PROPERTY_HANDLER_PROPERTY_LIST] = { .property_name = "PropertyList", .type = "a{say}", .get_cb = handle_get_property_list, .set_cb = NULL }
+};
+
+static pa_dbus_property_handler sink_property_handlers[SINK_PROPERTY_HANDLER_MAX] = {
+ [SINK_PROPERTY_HANDLER_MONITOR_SOURCE] = { .property_name = "MonitorSource", .type = "o", .get_cb = handle_sink_get_monitor_source, .set_cb = NULL }
+};
+
+static pa_dbus_property_handler source_property_handlers[SOURCE_PROPERTY_HANDLER_MAX] = {
+ [SOURCE_PROPERTY_HANDLER_MONITOR_OF_SINK] = { .property_name = "MonitorOfSink", .type = "o", .get_cb = handle_source_get_monitor_of_sink, .set_cb = NULL }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_SUSPEND,
+ METHOD_HANDLER_GET_PORT_BY_NAME,
+ METHOD_HANDLER_MAX
+};
+
+static pa_dbus_arg_info suspend_args[] = { { "suspend", "b", "in" } };
+static pa_dbus_arg_info get_port_by_name_args[] = { { "name", "s", "in" }, { "port", "o", "out" } };
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_SUSPEND] = {
+ .method_name = "Suspend",
+ .arguments = suspend_args,
+ .n_arguments = sizeof(suspend_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_suspend },
+ [METHOD_HANDLER_GET_PORT_BY_NAME] = {
+ .method_name = "GetPortByName",
+ .arguments = get_port_by_name_args,
+ .n_arguments = sizeof(get_port_by_name_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_get_port_by_name }
+};
+
+enum signal_index {
+ SIGNAL_VOLUME_UPDATED,
+ SIGNAL_MUTE_UPDATED,
+ SIGNAL_STATE_UPDATED,
+ SIGNAL_ACTIVE_PORT_UPDATED,
+ SIGNAL_PROPERTY_LIST_UPDATED,
+ SIGNAL_MAX
+};
+
+static pa_dbus_arg_info volume_updated_args[] = { { "volume", "au", NULL } };
+static pa_dbus_arg_info mute_updated_args[] = { { "muted", "b", NULL } };
+static pa_dbus_arg_info state_updated_args[] = { { "state", "u", NULL } };
+static pa_dbus_arg_info active_port_updated_args[] = { { "port", "o", NULL } };
+static pa_dbus_arg_info property_list_updated_args[] = { { "property_list", "a{say}", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_VOLUME_UPDATED] = { .name = "VolumeUpdated", .arguments = volume_updated_args, .n_arguments = 1 },
+ [SIGNAL_MUTE_UPDATED] = { .name = "MuteUpdated", .arguments = mute_updated_args, .n_arguments = 1 },
+ [SIGNAL_STATE_UPDATED] = { .name = "StateUpdated", .arguments = state_updated_args, .n_arguments = 1 },
+ [SIGNAL_ACTIVE_PORT_UPDATED] = { .name = "ActivePortUpdated", .arguments = active_port_updated_args, .n_arguments = 1 },
+ [SIGNAL_PROPERTY_LIST_UPDATED] = { .name = "PropertyListUpdated", .arguments = property_list_updated_args, .n_arguments = 1 }
+};
+
+static pa_dbus_interface_info device_interface_info = {
+ .name = PA_DBUSIFACE_DEVICE_INTERFACE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static pa_dbus_interface_info sink_interface_info = {
+ .name = PA_DBUSIFACE_SINK_INTERFACE,
+ .method_handlers = NULL,
+ .n_method_handlers = 0,
+ .property_handlers = sink_property_handlers,
+ .n_property_handlers = SINK_PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_sink_get_all,
+ .signals = NULL,
+ .n_signals = 0
+};
+
+static pa_dbus_interface_info source_interface_info = {
+ .name = PA_DBUSIFACE_SOURCE_INTERFACE,
+ .method_handlers = NULL,
+ .n_method_handlers = 0,
+ .property_handlers = source_property_handlers,
+ .n_property_handlers = SOURCE_PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_source_get_all,
+ .signals = NULL,
+ .n_signals = 0
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint32_t idx = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ idx = (d->type == DEVICE_TYPE_SINK) ? d->sink->index : d->source->index;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &idx);
+}
+
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char *name = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ name = (d->type == DEVICE_TYPE_SINK) ? d->sink->name : d->source->name;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &name);
+}
+
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char *driver = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ driver = (d->type == DEVICE_TYPE_SINK) ? d->sink->driver : d->source->driver;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &driver);
+}
+
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ pa_module *owner_module = NULL;
+ const char *object_path = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ owner_module = (d->type == DEVICE_TYPE_SINK) ? d->sink->module : d->source->module;
+
+ if (!owner_module) {
+ if (d->type == DEVICE_TYPE_SINK)
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sink %s doesn't have an owner module.", d->sink->name);
+ else
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Source %s doesn't have an owner module.", d->source->name);
+ return;
+ }
+
+ object_path = pa_dbusiface_core_get_module_path(d->core, owner_module);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_get_card(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ pa_card *card = NULL;
+ const char *object_path = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ card = (d->type == DEVICE_TYPE_SINK) ? d->sink->card : d->source->card;
+
+ if (!card) {
+ if (d->type == DEVICE_TYPE_SINK)
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sink %s doesn't belong to any card.", d->sink->name);
+ else
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Source %s doesn't belong to any card.", d->source->name);
+ return;
+ }
+
+ object_path = pa_dbusiface_core_get_card_path(d->core, card);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_get_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint32_t sample_format = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ sample_format = (d->type == DEVICE_TYPE_SINK) ? d->sink->sample_spec.format : d->source->sample_spec.format;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sample_format);
+}
+
+static void handle_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint32_t sample_rate = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ sample_rate = (d->type == DEVICE_TYPE_SINK) ? d->sink->sample_spec.rate : d->source->sample_spec.rate;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sample_rate);
+}
+
+static void handle_get_channels(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ pa_channel_map *channel_map = NULL;
+ dbus_uint32_t channels[PA_CHANNELS_MAX];
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ channel_map = (d->type == DEVICE_TYPE_SINK) ? &d->sink->channel_map : &d->source->channel_map;
+
+ for (i = 0; i < channel_map->channels; ++i)
+ channels[i] = channel_map->map[i];
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_UINT32, channels, channel_map->channels);
+}
+
+static void handle_get_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint32_t volume[PA_CHANNELS_MAX];
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ for (i = 0; i < d->volume.channels; ++i)
+ volume[i] = d->volume.values[i];
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_UINT32, volume, d->volume.channels);
+}
+
+static void handle_set_volume(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ DBusMessageIter array_iter;
+ int device_channels = 0;
+ dbus_uint32_t *volume = NULL;
+ int n_volume_entries = 0;
+ pa_cvolume new_vol;
+ int i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(d);
+
+ device_channels = (d->type == DEVICE_TYPE_SINK) ? d->sink->channel_map.channels : d->source->channel_map.channels;
+
+ dbus_message_iter_recurse(iter, &array_iter);
+ dbus_message_iter_get_fixed_array(&array_iter, &volume, &n_volume_entries);
+
+ if (n_volume_entries != device_channels && n_volume_entries != 1) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS,
+ "Expected %u volume entries, got %i.", device_channels, n_volume_entries);
+ return;
+ }
+
+ pa_cvolume_init(&new_vol);
+ new_vol.channels = n_volume_entries;
+
+ for (i = 0; i < n_volume_entries; ++i) {
+ if (!PA_VOLUME_IS_VALID(volume[i])) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Too large volume value: %u", volume[i]);
+ return;
+ }
+ new_vol.values[i] = volume[i];
+ }
+
+ if (d->type == DEVICE_TYPE_SINK)
+ pa_sink_set_volume(d->sink, &new_vol, TRUE, TRUE);
+ else
+ pa_source_set_volume(d->source, &new_vol, TRUE, TRUE);
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_get_has_flat_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t has_flat_volume = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ has_flat_volume = (d->type == DEVICE_TYPE_SINK) ? (d->sink->flags & PA_SINK_FLAT_VOLUME) : FALSE;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &has_flat_volume);
+}
+
+static void handle_get_has_convertible_to_decibel_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t has_convertible_to_decibel_volume = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ has_convertible_to_decibel_volume = (d->type == DEVICE_TYPE_SINK)
+ ? (d->sink->flags & PA_SINK_DECIBEL_VOLUME)
+ : (d->source->flags & PA_SOURCE_DECIBEL_VOLUME);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &has_convertible_to_decibel_volume);
+}
+
+static void handle_get_base_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint32_t base_volume;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ base_volume = (d->type == DEVICE_TYPE_SINK) ? d->sink->base_volume : d->source->base_volume;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &base_volume);
+}
+
+static void handle_get_volume_steps(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint32_t volume_steps;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ volume_steps = (d->type == DEVICE_TYPE_SINK) ? d->sink->n_volume_steps : d->source->n_volume_steps;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &volume_steps);
+}
+
+static void handle_get_mute(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &d->mute);
+}
+
+static void handle_set_mute(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t mute = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(d);
+
+ dbus_message_iter_get_basic(iter, &mute);
+
+ if (d->type == DEVICE_TYPE_SINK)
+ pa_sink_set_mute(d->sink, mute, TRUE);
+ else
+ pa_source_set_mute(d->source, mute, TRUE);
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_get_has_hardware_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t has_hardware_volume = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ has_hardware_volume = (d->type == DEVICE_TYPE_SINK)
+ ? (d->sink->flags & PA_SINK_HW_VOLUME_CTRL)
+ : (d->source->flags & PA_SOURCE_HW_VOLUME_CTRL);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &has_hardware_volume);
+}
+
+static void handle_get_has_hardware_mute(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t has_hardware_mute = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ has_hardware_mute = (d->type == DEVICE_TYPE_SINK)
+ ? (d->sink->flags & PA_SINK_HW_MUTE_CTRL)
+ : (d->source->flags & PA_SOURCE_HW_MUTE_CTRL);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &has_hardware_mute);
+}
+
+static void handle_get_configured_latency(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint64_t configured_latency = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ configured_latency = (d->type == DEVICE_TYPE_SINK)
+ ? pa_sink_get_requested_latency(d->sink)
+ : pa_source_get_requested_latency(d->source);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT64, &configured_latency);
+}
+
+static void handle_get_has_dynamic_latency(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t has_dynamic_latency = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ has_dynamic_latency = (d->type == DEVICE_TYPE_SINK)
+ ? (d->sink->flags & PA_SINK_DYNAMIC_LATENCY)
+ : (d->source->flags & PA_SOURCE_DYNAMIC_LATENCY);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &has_dynamic_latency);
+}
+
+static void handle_get_latency(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint64_t latency = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ if (d->type == DEVICE_TYPE_SINK && !(d->sink->flags & PA_SINK_LATENCY))
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sink %s doesn't support latency querying.", d->sink->name);
+ else if (d->type == DEVICE_TYPE_SOURCE && !(d->source->flags & PA_SOURCE_LATENCY))
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Source %s doesn't support latency querying.", d->source->name);
+ return;
+
+ latency = (d->type == DEVICE_TYPE_SINK) ? pa_sink_get_latency(d->sink) : pa_source_get_latency(d->source);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT64, &latency);
+}
+
+static void handle_get_is_hardware_device(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t is_hardware_device = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ is_hardware_device = (d->type == DEVICE_TYPE_SINK)
+ ? (d->sink->flags & PA_SINK_HARDWARE)
+ : (d->source->flags & PA_SOURCE_HARDWARE);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &is_hardware_device);
+}
+
+static void handle_get_is_network_device(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t is_network_device = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ is_network_device = (d->type == DEVICE_TYPE_SINK)
+ ? (d->sink->flags & PA_SINK_NETWORK)
+ : (d->source->flags & PA_SOURCE_NETWORK);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &is_network_device);
+}
+
+static void handle_get_state(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_uint32_t state;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ state = (d->type == DEVICE_TYPE_SINK) ? d->sink_state : d->source_state;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &state);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_ports(pa_dbusiface_device *d, unsigned *n) {
+ const char **ports;
+ unsigned i = 0;
+ void *state = NULL;
+ pa_dbusiface_device_port *port = NULL;
+
+ pa_assert(d);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(d->ports);
+
+ if (*n == 0)
+ return NULL;
+
+ ports = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(port, d->ports, state)
+ ports[i++] = pa_dbusiface_device_port_get_path(port);
+
+ return ports;
+}
+
+static void handle_get_ports(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char **ports = NULL;
+ unsigned n_ports = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ ports = get_ports(d, &n_ports);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, ports, n_ports);
+
+ pa_xfree(ports);
+}
+
+static void handle_get_active_port(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char *active_port;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ if (!d->active_port) {
+ pa_assert(pa_hashmap_isempty(d->ports));
+
+ if (d->type == DEVICE_TYPE_SINK)
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "The sink %s has no ports, and therefore there's no active port either.", d->sink->name);
+ else
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "The source %s has no ports, and therefore there's no active port either.", d->source->name);
+ return;
+ }
+
+ active_port = pa_dbusiface_device_port_get_path(pa_hashmap_get(d->ports, d->active_port->name));
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &active_port);
+}
+
+static void handle_set_active_port(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char *new_active_path;
+ pa_dbusiface_device_port *new_active;
+ int r;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(d);
+
+ if (!d->active_port) {
+ pa_assert(pa_hashmap_isempty(d->ports));
+
+ if (d->type == DEVICE_TYPE_SINK)
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "The sink %s has no ports, and therefore there's no active port either.", d->sink->name);
+ else
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "The source %s has no ports, and therefore there's no active port either.", d->source->name);
+ return;
+ }
+
+ dbus_message_iter_get_basic(iter, &new_active_path);
+
+ if (!(new_active = pa_hashmap_get(d->ports, new_active_path))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "No such port: %s", new_active_path);
+ return;
+ }
+
+ if (d->type == DEVICE_TYPE_SINK) {
+ if ((r = pa_sink_set_port(d->sink, pa_dbusiface_device_port_get_name(new_active), TRUE)) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED,
+ "Internal error in PulseAudio: pa_sink_set_port() failed with error code %i.", r);
+ return;
+ }
+ } else {
+ if ((r = pa_source_set_port(d->source, pa_dbusiface_device_port_get_name(new_active), TRUE)) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED,
+ "Internal error in PulseAudio: pa_source_set_port() failed with error code %i.", r);
+ return;
+ }
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ pa_dbus_send_proplist_variant_reply(conn, msg, d->proplist);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t idx = 0;
+ const char *name = NULL;
+ const char *driver = NULL;
+ pa_module *owner_module = NULL;
+ const char *owner_module_path = NULL;
+ pa_card *card = NULL;
+ const char *card_path = NULL;
+ dbus_uint32_t sample_format = 0;
+ dbus_uint32_t sample_rate = 0;
+ pa_channel_map *channel_map = NULL;
+ dbus_uint32_t channels[PA_CHANNELS_MAX];
+ dbus_uint32_t volume[PA_CHANNELS_MAX];
+ dbus_bool_t has_flat_volume = FALSE;
+ dbus_bool_t has_convertible_to_decibel_volume = FALSE;
+ dbus_uint32_t base_volume = 0;
+ dbus_uint32_t volume_steps = 0;
+ dbus_bool_t has_hardware_volume = FALSE;
+ dbus_bool_t has_hardware_mute = FALSE;
+ dbus_uint64_t configured_latency = 0;
+ dbus_bool_t has_dynamic_latency = FALSE;
+ dbus_uint64_t latency = 0;
+ dbus_bool_t is_hardware_device = FALSE;
+ dbus_bool_t is_network_device = FALSE;
+ dbus_uint32_t state = 0;
+ const char **ports = NULL;
+ unsigned n_ports = 0;
+ const char *active_port = NULL;
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ if (d->type == DEVICE_TYPE_SINK) {
+ idx = d->sink->index;
+ name = d->sink->name;
+ driver = d->sink->driver;
+ owner_module = d->sink->module;
+ card = d->sink->card;
+ sample_format = d->sink->sample_spec.format;
+ sample_rate = d->sink->sample_spec.rate;
+ channel_map = &d->sink->channel_map;
+ has_flat_volume = d->sink->flags & PA_SINK_FLAT_VOLUME;
+ has_convertible_to_decibel_volume = d->sink->flags & PA_SINK_DECIBEL_VOLUME;
+ base_volume = d->sink->base_volume;
+ volume_steps = d->sink->n_volume_steps;
+ has_hardware_volume = d->sink->flags & PA_SINK_HW_VOLUME_CTRL;
+ has_hardware_mute = d->sink->flags & PA_SINK_HW_MUTE_CTRL;
+ configured_latency = pa_sink_get_requested_latency(d->sink);
+ has_dynamic_latency = d->sink->flags & PA_SINK_DYNAMIC_LATENCY;
+ latency = pa_sink_get_latency(d->sink);
+ is_hardware_device = d->sink->flags & PA_SINK_HARDWARE;
+ is_network_device = d->sink->flags & PA_SINK_NETWORK;
+ state = pa_sink_get_state(d->sink);
+ } else {
+ idx = d->source->index;
+ name = d->source->name;
+ driver = d->source->driver;
+ owner_module = d->source->module;
+ card = d->source->card;
+ sample_format = d->source->sample_spec.format;
+ sample_rate = d->source->sample_spec.rate;
+ channel_map = &d->source->channel_map;
+ has_flat_volume = FALSE;
+ has_convertible_to_decibel_volume = d->source->flags & PA_SOURCE_DECIBEL_VOLUME;
+ base_volume = d->source->base_volume;
+ volume_steps = d->source->n_volume_steps;
+ has_hardware_volume = d->source->flags & PA_SOURCE_HW_VOLUME_CTRL;
+ has_hardware_mute = d->source->flags & PA_SOURCE_HW_MUTE_CTRL;
+ configured_latency = pa_source_get_requested_latency(d->source);
+ has_dynamic_latency = d->source->flags & PA_SOURCE_DYNAMIC_LATENCY;
+ latency = pa_source_get_latency(d->source);
+ is_hardware_device = d->source->flags & PA_SOURCE_HARDWARE;
+ is_network_device = d->source->flags & PA_SOURCE_NETWORK;
+ state = pa_source_get_state(d->source);
+ }
+ if (owner_module)
+ owner_module_path = pa_dbusiface_core_get_module_path(d->core, owner_module);
+ if (card)
+ card_path = pa_dbusiface_core_get_card_path(d->core, card);
+ for (i = 0; i < channel_map->channels; ++i)
+ channels[i] = channel_map->map[i];
+ for (i = 0; i < d->volume.channels; ++i)
+ volume[i] = d->volume.values[i];
+ ports = get_ports(d, &n_ports);
+ if (d->active_port)
+ active_port = pa_dbusiface_device_port_get_path(pa_hashmap_get(d->ports, d->active_port->name));
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &idx);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &name);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DRIVER].property_name, DBUS_TYPE_STRING, &driver);
+
+ if (owner_module)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_OWNER_MODULE].property_name, DBUS_TYPE_OBJECT_PATH, &owner_module_path);
+
+ if (card)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CARD].property_name, DBUS_TYPE_OBJECT_PATH, &card_path);
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLE_FORMAT].property_name, DBUS_TYPE_UINT32, &sample_format);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLE_RATE].property_name, DBUS_TYPE_UINT32, &sample_rate);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CHANNELS].property_name, DBUS_TYPE_UINT32, channels, channel_map->channels);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_VOLUME].property_name, DBUS_TYPE_UINT32, volume, d->volume.channels);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_HAS_FLAT_VOLUME].property_name, DBUS_TYPE_BOOLEAN, &has_flat_volume);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_HAS_CONVERTIBLE_TO_DECIBEL_VOLUME].property_name, DBUS_TYPE_BOOLEAN, &has_convertible_to_decibel_volume);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_BASE_VOLUME].property_name, DBUS_TYPE_UINT32, &base_volume);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_VOLUME_STEPS].property_name, DBUS_TYPE_UINT32, &volume_steps);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_MUTE].property_name, DBUS_TYPE_BOOLEAN, &d->mute);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_HAS_HARDWARE_VOLUME].property_name, DBUS_TYPE_BOOLEAN, &has_hardware_volume);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_HAS_HARDWARE_MUTE].property_name, DBUS_TYPE_BOOLEAN, &has_hardware_mute);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CONFIGURED_LATENCY].property_name, DBUS_TYPE_UINT64, &configured_latency);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_HAS_DYNAMIC_LATENCY].property_name, DBUS_TYPE_BOOLEAN, &has_dynamic_latency);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_LATENCY].property_name, DBUS_TYPE_UINT64, &latency);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_IS_HARDWARE_DEVICE].property_name, DBUS_TYPE_BOOLEAN, &is_hardware_device);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_IS_NETWORK_DEVICE].property_name, DBUS_TYPE_BOOLEAN, &is_network_device);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_STATE].property_name, DBUS_TYPE_UINT32, &state);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PORTS].property_name, DBUS_TYPE_OBJECT_PATH, ports, n_ports);
+
+ if (active_port)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_ACTIVE_PORT].property_name, DBUS_TYPE_OBJECT_PATH, &active_port);
+
+ pa_dbus_append_proplist_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PROPERTY_LIST].property_name, d->proplist);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+
+ pa_xfree(ports);
+}
+
+static void handle_suspend(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ dbus_bool_t suspend = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_BOOLEAN, &suspend, DBUS_TYPE_INVALID));
+
+ if ((d->type == DEVICE_TYPE_SINK) && (pa_sink_suspend(d->sink, suspend, PA_SUSPEND_USER) < 0)) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "Internal error in PulseAudio: pa_sink_suspend() failed.");
+ return;
+ } else if ((d->type == DEVICE_TYPE_SOURCE) && (pa_source_suspend(d->source, suspend, PA_SUSPEND_USER) < 0)) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "Internal error in PulseAudio: pa_source_suspend() failed.");
+ return;
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_get_port_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char *port_name = NULL;
+ pa_dbusiface_device_port *port = NULL;
+ const char *port_path = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &port_name, DBUS_TYPE_INVALID));
+
+ if (!(port = pa_hashmap_get(d->ports, port_name))) {
+ if (d->type == DEVICE_TYPE_SINK)
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND,
+ "%s: No such port on sink %s.", port_name, d->sink->name);
+ else
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND,
+ "%s: No such port on source %s.", port_name, d->source->name);
+ return;
+ }
+
+ port_path = pa_dbusiface_device_port_get_path(port);
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &port_path);
+}
+
+static void handle_sink_get_monitor_source(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char *monitor_source = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+ pa_assert(d->type == DEVICE_TYPE_SINK);
+
+ monitor_source = pa_dbusiface_core_get_source_path(d->core, d->sink->monitor_source);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &monitor_source);
+}
+
+static void handle_sink_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ const char *monitor_source = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+ pa_assert(d->type == DEVICE_TYPE_SINK);
+
+ monitor_source = pa_dbusiface_core_get_source_path(d->core, d->sink->monitor_source);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[SINK_PROPERTY_HANDLER_MONITOR_SOURCE].property_name, DBUS_TYPE_OBJECT_PATH, &monitor_source);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+}
+
+static void handle_source_get_monitor_of_sink(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ const char *monitor_of_sink = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+ pa_assert(d->type == DEVICE_TYPE_SOURCE);
+
+ if (!d->source->monitor_of) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "Source %s is not a monitor source.", d->source->name);
+ return;
+ }
+
+ monitor_of_sink = pa_dbusiface_core_get_sink_path(d->core, d->source->monitor_of);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &monitor_of_sink);
+}
+
+static void handle_source_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ const char *monitor_of_sink = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(d);
+ pa_assert(d->type == DEVICE_TYPE_SOURCE);
+
+ if (d->source->monitor_of)
+ monitor_of_sink = pa_dbusiface_core_get_sink_path(d->core, d->source->monitor_of);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ if (monitor_of_sink)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[SOURCE_PROPERTY_HANDLER_MONITOR_OF_SINK].property_name, DBUS_TYPE_OBJECT_PATH, &monitor_of_sink);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+}
+
+static void subscription_cb(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ pa_dbusiface_device *d = userdata;
+ DBusMessage *signal_msg = NULL;
+ const pa_cvolume *new_volume = NULL;
+ pa_bool_t new_mute = FALSE;
+ pa_sink_state_t new_sink_state = 0;
+ pa_source_state_t new_source_state = 0;
+ pa_device_port *new_active_port = NULL;
+ pa_proplist *new_proplist = NULL;
+ unsigned i = 0;
+
+ pa_assert(c);
+ pa_assert(d);
+
+ if ((d->type == DEVICE_TYPE_SINK && idx != d->sink->index) || (d->type == DEVICE_TYPE_SOURCE && idx != d->source->index))
+ return;
+
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) != PA_SUBSCRIPTION_EVENT_CHANGE)
+ return;
+
+ pa_assert(((d->type == DEVICE_TYPE_SINK)
+ && ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SINK))
+ || ((d->type == DEVICE_TYPE_SOURCE)
+ && ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SOURCE)));
+
+ new_volume = (d->type == DEVICE_TYPE_SINK)
+ ? pa_sink_get_volume(d->sink, FALSE)
+ : pa_source_get_volume(d->source, FALSE);
+
+ if (!pa_cvolume_equal(&d->volume, new_volume)) {
+ dbus_uint32_t volume[PA_CHANNELS_MAX];
+ dbus_uint32_t *volume_ptr = volume;
+
+ d->volume = *new_volume;
+
+ for (i = 0; i < d->volume.channels; ++i)
+ volume[i] = d->volume.values[i];
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(d->path,
+ PA_DBUSIFACE_DEVICE_INTERFACE,
+ signals[SIGNAL_VOLUME_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_UINT32, &volume_ptr, d->volume.channels,
+ DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(d->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+
+ new_mute = (d->type == DEVICE_TYPE_SINK) ? pa_sink_get_mute(d->sink, FALSE) : pa_source_get_mute(d->source, FALSE);
+
+ if (d->mute != new_mute) {
+ d->mute = new_mute;
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(d->path,
+ PA_DBUSIFACE_DEVICE_INTERFACE,
+ signals[SIGNAL_MUTE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_BOOLEAN, &d->mute, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(d->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+
+ if (d->type == DEVICE_TYPE_SINK)
+ new_sink_state = pa_sink_get_state(d->sink);
+ else
+ new_source_state = pa_source_get_state(d->source);
+
+ if ((d->type == DEVICE_TYPE_SINK && d->sink_state != new_sink_state)
+ || (d->type == DEVICE_TYPE_SOURCE && d->source_state != new_source_state)) {
+ dbus_uint32_t state = 0;
+
+ if (d->type == DEVICE_TYPE_SINK)
+ d->sink_state = new_sink_state;
+ else
+ d->source_state = new_source_state;
+
+ state = (d->type == DEVICE_TYPE_SINK) ? d->sink_state : d->source_state;
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(d->path,
+ PA_DBUSIFACE_DEVICE_INTERFACE,
+ signals[SIGNAL_STATE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_UINT32, &state, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(d->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+
+ new_active_port = (d->type == DEVICE_TYPE_SINK) ? d->sink->active_port : d->source->active_port;
+
+ if (d->active_port != new_active_port) {
+ const char *object_path = NULL;
+
+ d->active_port = new_active_port;
+ object_path = pa_dbusiface_device_port_get_path(pa_hashmap_get(d->ports, d->active_port->name));
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(d->path,
+ PA_DBUSIFACE_DEVICE_INTERFACE,
+ signals[SIGNAL_ACTIVE_PORT_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(d->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+
+ new_proplist = (d->type == DEVICE_TYPE_SINK) ? d->sink->proplist : d->source->proplist;
+
+ if (!pa_proplist_equal(d->proplist, new_proplist)) {
+ DBusMessageIter msg_iter;
+
+ pa_proplist_update(d->proplist, PA_UPDATE_SET, new_proplist);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(d->path,
+ PA_DBUSIFACE_DEVICE_INTERFACE,
+ signals[SIGNAL_PROPERTY_LIST_UPDATED].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_dbus_append_proplist(&msg_iter, d->proplist);
+
+ pa_dbus_protocol_send_signal(d->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+}
+
+pa_dbusiface_device *pa_dbusiface_device_new_sink(pa_dbusiface_core *core, pa_sink *sink) {
+ pa_dbusiface_device *d = NULL;
+
+ pa_assert(core);
+ pa_assert(sink);
+
+ d = pa_xnew0(pa_dbusiface_device, 1);
+ d->core = core;
+ d->sink = pa_sink_ref(sink);
+ d->type = DEVICE_TYPE_SINK;
+ d->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, SINK_OBJECT_NAME, sink->index);
+ d->volume = *pa_sink_get_volume(sink, FALSE);
+ d->mute = pa_sink_get_mute(sink, FALSE);
+ d->sink_state = pa_sink_get_state(sink);
+ d->ports = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ d->next_port_index = 0;
+ d->active_port = NULL;
+ d->proplist = pa_proplist_copy(sink->proplist);
+ d->dbus_protocol = pa_dbus_protocol_get(sink->core);
+ d->subscription = pa_subscription_new(sink->core, PA_SUBSCRIPTION_MASK_SINK, subscription_cb, d);
+
+ if (sink->ports) {
+ pa_device_port *port;
+ void *state = NULL;
+
+ PA_HASHMAP_FOREACH(port, sink->ports, state) {
+ pa_dbusiface_device_port *p = pa_dbusiface_device_port_new(d, sink->core, port, d->next_port_index++);
+ pa_hashmap_put(d->ports, pa_dbusiface_device_port_get_name(p), p);
+ }
+ pa_assert_se(d->active_port = sink->active_port);
+ }
+
+ pa_assert_se(pa_dbus_protocol_add_interface(d->dbus_protocol, d->path, &device_interface_info, d) >= 0);
+ pa_assert_se(pa_dbus_protocol_add_interface(d->dbus_protocol, d->path, &sink_interface_info, d) >= 0);
+
+ return d;
+}
+
+pa_dbusiface_device *pa_dbusiface_device_new_source(pa_dbusiface_core *core, pa_source *source) {
+ pa_dbusiface_device *d = NULL;
+
+ pa_assert(core);
+ pa_assert(source);
+
+ d = pa_xnew0(pa_dbusiface_device, 1);
+ d->core = core;
+ d->source = pa_source_ref(source);
+ d->type = DEVICE_TYPE_SOURCE;
+ d->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, SOURCE_OBJECT_NAME, source->index);
+ d->volume = *pa_source_get_volume(source, FALSE);
+ d->mute = pa_source_get_mute(source, FALSE);
+ d->source_state = pa_source_get_state(source);
+ d->ports = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ d->next_port_index = 0;
+ d->active_port = NULL;
+ d->proplist = pa_proplist_copy(source->proplist);
+ d->dbus_protocol = pa_dbus_protocol_get(source->core);
+ d->subscription = pa_subscription_new(source->core, PA_SUBSCRIPTION_MASK_SOURCE, subscription_cb, d);
+
+ if (source->ports) {
+ pa_device_port *port;
+ void *state = NULL;
+
+ PA_HASHMAP_FOREACH(port, source->ports, state) {
+ pa_dbusiface_device_port *p = pa_dbusiface_device_port_new(d, source->core, port, d->next_port_index++);
+ pa_hashmap_put(d->ports, pa_dbusiface_device_port_get_name(p), p);
+ }
+ pa_assert_se(d->active_port = source->active_port);
+ }
+
+ pa_assert_se(pa_dbus_protocol_add_interface(d->dbus_protocol, d->path, &device_interface_info, d) >= 0);
+ pa_assert_se(pa_dbus_protocol_add_interface(d->dbus_protocol, d->path, &source_interface_info, d) >= 0);
+
+ return d;
+}
+
+static void port_free_cb(void *p, void *userdata) {
+ pa_dbusiface_device_port *port = p;
+
+ pa_assert(port);
+
+ pa_dbusiface_device_port_free(port);
+}
+
+void pa_dbusiface_device_free(pa_dbusiface_device *d) {
+ pa_assert(d);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(d->dbus_protocol, d->path, device_interface_info.name) >= 0);
+
+ if (d->type == DEVICE_TYPE_SINK) {
+ pa_assert_se(pa_dbus_protocol_remove_interface(d->dbus_protocol, d->path, sink_interface_info.name) >= 0);
+ pa_sink_unref(d->sink);
+
+ } else {
+ pa_assert_se(pa_dbus_protocol_remove_interface(d->dbus_protocol, d->path, source_interface_info.name) >= 0);
+ pa_source_unref(d->source);
+ }
+ pa_hashmap_free(d->ports, port_free_cb, NULL);
+ pa_proplist_free(d->proplist);
+ pa_dbus_protocol_unref(d->dbus_protocol);
+ pa_subscription_free(d->subscription);
+
+ pa_xfree(d->path);
+ pa_xfree(d);
+}
+
+const char *pa_dbusiface_device_get_path(pa_dbusiface_device *d) {
+ pa_assert(d);
+
+ return d->path;
+}
+
+pa_sink *pa_dbusiface_device_get_sink(pa_dbusiface_device *d) {
+ pa_assert(d);
+ pa_assert(d->type == DEVICE_TYPE_SINK);
+
+ return d->sink;
+}
+
+pa_source *pa_dbusiface_device_get_source(pa_dbusiface_device *d) {
+ pa_assert(d);
+ pa_assert(d->type == DEVICE_TYPE_SOURCE);
+
+ return d->source;
+}
diff --git a/src/modules/dbus/iface-device.h b/src/modules/dbus/iface-device.h
new file mode 100644
index 00000000..62e05e9a
--- /dev/null
+++ b/src/modules/dbus/iface-device.h
@@ -0,0 +1,53 @@
+#ifndef foodbusifacedevicehfoo
+#define foodbusifacedevicehfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interfaces org.PulseAudio.Core1.Device,
+ * org.PulseAudio.Core1.Sink and org.PulseAudio.Core1.Source.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the interface
+ * documentation.
+ */
+
+#include <pulsecore/protocol-dbus.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/source.h>
+
+#include "iface-core.h"
+
+#define PA_DBUSIFACE_DEVICE_INTERFACE PA_DBUS_CORE_INTERFACE ".Device"
+#define PA_DBUSIFACE_SINK_INTERFACE PA_DBUS_CORE_INTERFACE ".Sink"
+#define PA_DBUSIFACE_SOURCE_INTERFACE PA_DBUS_CORE_INTERFACE ".Source"
+
+typedef struct pa_dbusiface_device pa_dbusiface_device;
+
+pa_dbusiface_device *pa_dbusiface_device_new_sink(pa_dbusiface_core *core, pa_sink *sink);
+pa_dbusiface_device *pa_dbusiface_device_new_source(pa_dbusiface_core *core, pa_source *source);
+void pa_dbusiface_device_free(pa_dbusiface_device *d);
+
+const char *pa_dbusiface_device_get_path(pa_dbusiface_device *d);
+
+pa_sink *pa_dbusiface_device_get_sink(pa_dbusiface_device *d);
+pa_source *pa_dbusiface_device_get_source(pa_dbusiface_device *d);
+
+#endif
diff --git a/src/modules/dbus/iface-memstats.c b/src/modules/dbus/iface-memstats.c
new file mode 100644
index 00000000..4cd692db
--- /dev/null
+++ b/src/modules/dbus/iface-memstats.c
@@ -0,0 +1,230 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulsecore/core-scache.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-memstats.h"
+
+#define OBJECT_NAME "memstats"
+
+static void handle_get_current_memblocks(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_current_memblocks_size(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_accumulated_memblocks(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_accumulated_memblocks_size(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_cache_size(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+struct pa_dbusiface_memstats {
+ pa_core *core;
+ char *path;
+ pa_dbus_protocol *dbus_protocol;
+};
+
+enum property_handler_index {
+ PROPERTY_HANDLER_CURRENT_MEMBLOCKS,
+ PROPERTY_HANDLER_CURRENT_MEMBLOCKS_SIZE,
+ PROPERTY_HANDLER_ACCUMULATED_MEMBLOCKS,
+ PROPERTY_HANDLER_ACCUMULATED_MEMBLOCKS_SIZE,
+ PROPERTY_HANDLER_SAMPLE_CACHE_SIZE,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_CURRENT_MEMBLOCKS] = { .property_name = "CurrentMemblocks", .type = "u", .get_cb = handle_get_current_memblocks, .set_cb = NULL },
+ [PROPERTY_HANDLER_CURRENT_MEMBLOCKS_SIZE] = { .property_name = "CurrentMemblocksSize", .type = "u", .get_cb = handle_get_current_memblocks_size, .set_cb = NULL },
+ [PROPERTY_HANDLER_ACCUMULATED_MEMBLOCKS] = { .property_name = "AccumulatedMemblocks", .type = "u", .get_cb = handle_get_accumulated_memblocks, .set_cb = NULL },
+ [PROPERTY_HANDLER_ACCUMULATED_MEMBLOCKS_SIZE] = { .property_name = "AccumulatedMemblocksSize", .type = "u", .get_cb = handle_get_accumulated_memblocks_size, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLE_CACHE_SIZE] = { .property_name = "SampleCacheSize", .type = "u", .get_cb = handle_get_sample_cache_size, .set_cb = NULL }
+};
+
+static pa_dbus_interface_info memstats_interface_info = {
+ .name = PA_DBUSIFACE_MEMSTATS_INTERFACE,
+ .method_handlers = NULL,
+ .n_method_handlers = 0,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = NULL,
+ .n_signals = 0
+};
+
+static void handle_get_current_memblocks(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_memstats *m = userdata;
+ const pa_mempool_stat *stat;
+ dbus_uint32_t current_memblocks;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ stat = pa_mempool_get_stat(m->core->mempool);
+
+ current_memblocks = pa_atomic_load(&stat->n_allocated);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &current_memblocks);
+}
+
+static void handle_get_current_memblocks_size(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_memstats *m = userdata;
+ const pa_mempool_stat *stat;
+ dbus_uint32_t current_memblocks_size;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ stat = pa_mempool_get_stat(m->core->mempool);
+
+ current_memblocks_size = pa_atomic_load(&stat->allocated_size);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &current_memblocks_size);
+}
+
+static void handle_get_accumulated_memblocks(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_memstats *m = userdata;
+ const pa_mempool_stat *stat;
+ dbus_uint32_t accumulated_memblocks;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ stat = pa_mempool_get_stat(m->core->mempool);
+
+ accumulated_memblocks = pa_atomic_load(&stat->n_accumulated);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &accumulated_memblocks);
+}
+
+static void handle_get_accumulated_memblocks_size(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_memstats *m = userdata;
+ const pa_mempool_stat *stat;
+ dbus_uint32_t accumulated_memblocks_size;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ stat = pa_mempool_get_stat(m->core->mempool);
+
+ accumulated_memblocks_size = pa_atomic_load(&stat->accumulated_size);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &accumulated_memblocks_size);
+}
+
+static void handle_get_sample_cache_size(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_memstats *m = userdata;
+ dbus_uint32_t sample_cache_size;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ sample_cache_size = pa_scache_total_size(m->core);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sample_cache_size);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_memstats *m = userdata;
+ const pa_mempool_stat *stat;
+ dbus_uint32_t current_memblocks;
+ dbus_uint32_t current_memblocks_size;
+ dbus_uint32_t accumulated_memblocks;
+ dbus_uint32_t accumulated_memblocks_size;
+ dbus_uint32_t sample_cache_size;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ stat = pa_mempool_get_stat(m->core->mempool);
+
+ current_memblocks = pa_atomic_load(&stat->n_allocated);
+ current_memblocks_size = pa_atomic_load(&stat->allocated_size);
+ accumulated_memblocks = pa_atomic_load(&stat->n_accumulated);
+ accumulated_memblocks_size = pa_atomic_load(&stat->accumulated_size);
+ sample_cache_size = pa_scache_total_size(m->core);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CURRENT_MEMBLOCKS].property_name, DBUS_TYPE_UINT32, &current_memblocks);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CURRENT_MEMBLOCKS_SIZE].property_name, DBUS_TYPE_UINT32, &current_memblocks_size);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_ACCUMULATED_MEMBLOCKS].property_name, DBUS_TYPE_UINT32, &accumulated_memblocks);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_ACCUMULATED_MEMBLOCKS_SIZE].property_name, DBUS_TYPE_UINT32, &accumulated_memblocks_size);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLE_CACHE_SIZE].property_name, DBUS_TYPE_UINT32, &sample_cache_size);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+}
+
+pa_dbusiface_memstats *pa_dbusiface_memstats_new(pa_dbusiface_core *dbus_core, pa_core *core) {
+ pa_dbusiface_memstats *m;
+
+ pa_assert(dbus_core);
+ pa_assert(core);
+
+ m = pa_xnew(pa_dbusiface_memstats, 1);
+ m->core = core;
+ m->path = pa_sprintf_malloc("%s/%s", PA_DBUS_CORE_OBJECT_PATH, OBJECT_NAME);
+ m->dbus_protocol = pa_dbus_protocol_get(core);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(m->dbus_protocol, m->path, &memstats_interface_info, m) >= 0);
+
+ return m;
+}
+
+void pa_dbusiface_memstats_free(pa_dbusiface_memstats *m) {
+ pa_assert(m);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(m->dbus_protocol, m->path, memstats_interface_info.name) >= 0);
+
+ pa_xfree(m->path);
+
+ pa_dbus_protocol_unref(m->dbus_protocol);
+
+ pa_xfree(m);
+}
+
+const char *pa_dbusiface_memstats_get_path(pa_dbusiface_memstats *m) {
+ pa_assert(m);
+
+ return m->path;
+}
diff --git a/src/modules/dbus/iface-memstats.h b/src/modules/dbus/iface-memstats.h
new file mode 100644
index 00000000..0820e8fe
--- /dev/null
+++ b/src/modules/dbus/iface-memstats.h
@@ -0,0 +1,45 @@
+#ifndef foodbusifacememstatshfoo
+#define foodbusifacememstatshfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.Memstats.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the Memstats interface
+ * documentation.
+ */
+
+#include <pulsecore/core.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-core.h"
+
+#define PA_DBUSIFACE_MEMSTATS_INTERFACE PA_DBUS_CORE_INTERFACE ".Memstats"
+
+typedef struct pa_dbusiface_memstats pa_dbusiface_memstats;
+
+pa_dbusiface_memstats *pa_dbusiface_memstats_new(pa_dbusiface_core *dbus_core, pa_core *core);
+void pa_dbusiface_memstats_free(pa_dbusiface_memstats *m);
+
+const char *pa_dbusiface_memstats_get_path(pa_dbusiface_memstats *m);
+
+#endif
diff --git a/src/modules/dbus/iface-module.c b/src/modules/dbus/iface-module.c
new file mode 100644
index 00000000..9973166c
--- /dev/null
+++ b/src/modules/dbus/iface-module.c
@@ -0,0 +1,336 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-module.h"
+
+#define OBJECT_NAME "module"
+
+struct pa_dbusiface_module {
+ pa_module *module;
+ char *path;
+ pa_proplist *proplist;
+
+ pa_dbus_protocol *dbus_protocol;
+ pa_subscription *subscription;
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_arguments(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_usage_counter(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_unload(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_NAME,
+ PROPERTY_HANDLER_ARGUMENTS,
+ PROPERTY_HANDLER_USAGE_COUNTER,
+ PROPERTY_HANDLER_PROPERTY_LIST,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_get_name, .set_cb = NULL },
+ [PROPERTY_HANDLER_ARGUMENTS] = { .property_name = "Arguments", .type = "a{ss}", .get_cb = handle_get_arguments, .set_cb = NULL },
+ [PROPERTY_HANDLER_USAGE_COUNTER] = { .property_name = "UsageCounter", .type = "u", .get_cb = handle_get_usage_counter, .set_cb = NULL },
+ [PROPERTY_HANDLER_PROPERTY_LIST] = { .property_name = "PropertyList", .type = "a{say}", .get_cb = handle_get_property_list, .set_cb = NULL }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_UNLOAD,
+ METHOD_HANDLER_MAX
+};
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_UNLOAD] = {
+ .method_name = "Unload",
+ .arguments = NULL,
+ .n_arguments = 0,
+ .receive_cb = handle_unload }
+};
+
+enum signal_index {
+ SIGNAL_PROPERTY_LIST_UPDATED,
+ SIGNAL_MAX
+};
+
+static pa_dbus_arg_info property_list_updated_args[] = { { "property_list", "a{say}", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_PROPERTY_LIST_UPDATED] = { .name = "PropertyListUpdated", .arguments = property_list_updated_args, .n_arguments = 1 }
+};
+
+static pa_dbus_interface_info module_interface_info = {
+ .name = PA_DBUSIFACE_MODULE_INTERFACE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+ dbus_uint32_t idx = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ idx = m->module->index;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &idx);
+}
+
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &m->module->name);
+}
+
+static void append_modargs_variant(DBusMessageIter *iter, pa_dbusiface_module *m) {
+ pa_modargs *ma = NULL;
+ DBusMessageIter variant_iter;
+ DBusMessageIter dict_iter;
+ DBusMessageIter dict_entry_iter;
+ void *state = NULL;
+ const char *key = NULL;
+ const char *value = NULL;
+
+ pa_assert(iter);
+ pa_assert(m);
+
+ pa_assert_se(ma = pa_modargs_new(m->module->argument, NULL));
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_VARIANT, "a{ss}", &variant_iter));
+ pa_assert_se(dbus_message_iter_open_container(&variant_iter, DBUS_TYPE_ARRAY, "{ss}", &dict_iter));
+
+ for (state = NULL, key = pa_modargs_iterate(ma, &state); key; key = pa_modargs_iterate(ma, &state)) {
+ pa_assert_se(value = pa_modargs_get_value(ma, key, NULL));
+
+ pa_assert_se(dbus_message_iter_open_container(&dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter));
+
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &key));
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &value));
+
+ pa_assert_se(dbus_message_iter_close_container(&dict_iter, &dict_entry_iter));
+ }
+
+ pa_assert_se(dbus_message_iter_close_container(&variant_iter, &dict_iter));
+ pa_assert_se(dbus_message_iter_close_container(iter, &variant_iter));
+
+ pa_modargs_free(ma);
+}
+
+static void handle_get_arguments(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ pa_assert_se(reply = dbus_message_new_method_return(msg));
+ dbus_message_iter_init_append(reply, &msg_iter);
+ append_modargs_variant(&msg_iter, m);
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+static void handle_get_usage_counter(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+ int real_counter_value = -1;
+ dbus_uint32_t usage_counter = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ if (!m->module->get_n_used || (real_counter_value = m->module->get_n_used(m->module)) < 0) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Module %u (%s) doesn't have a usage counter.", m->module->index, m->module->name);
+ return;
+ }
+
+ usage_counter = real_counter_value;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &usage_counter);
+}
+
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ pa_dbus_send_proplist_variant_reply(conn, msg, m->proplist);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ DBusMessageIter dict_entry_iter;
+ dbus_uint32_t idx = 0;
+ int real_counter_value = -1;
+ dbus_uint32_t usage_counter = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ idx = m->module->index;
+ if (m->module->get_n_used && (real_counter_value = m->module->get_n_used(m->module)) >= 0)
+ usage_counter = real_counter_value;
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &idx);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &m->module->name);
+
+ pa_assert_se(dbus_message_iter_open_container(&dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter));
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &property_handlers[PROPERTY_HANDLER_ARGUMENTS].property_name));
+ append_modargs_variant(&dict_entry_iter, m);
+ pa_assert_se(dbus_message_iter_close_container(&dict_iter, &dict_entry_iter));
+
+ if (real_counter_value >= 0)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_ARGUMENTS].property_name, DBUS_TYPE_UINT32, &usage_counter);
+
+ pa_dbus_append_proplist_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PROPERTY_LIST].property_name, m->proplist);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+}
+
+static void handle_unload(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(m);
+
+ if (m->module->core->disallow_module_loading) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_ACCESS_DENIED, "The server is configured to disallow module unloading.");
+ return;
+ }
+
+ pa_module_unload_request(m->module, FALSE);
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void subscription_cb(pa_core *core, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ pa_dbusiface_module *m = userdata;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(core);
+ pa_assert((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_MODULE);
+ pa_assert(m);
+
+ /* We can't use idx != m->module->index, because the m->module pointer may
+ * be stale at this point. */
+ if (pa_idxset_get_by_index(core->modules, idx) != m->module)
+ return;
+
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) != PA_SUBSCRIPTION_EVENT_CHANGE)
+ return;
+
+ if (!pa_proplist_equal(m->proplist, m->module->proplist)) {
+ DBusMessageIter msg_iter;
+
+ pa_proplist_update(m->proplist, PA_UPDATE_SET, m->module->proplist);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(m->path,
+ PA_DBUSIFACE_MODULE_INTERFACE,
+ signals[SIGNAL_PROPERTY_LIST_UPDATED].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_dbus_append_proplist(&msg_iter, m->proplist);
+
+ pa_dbus_protocol_send_signal(m->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+}
+
+pa_dbusiface_module *pa_dbusiface_module_new(pa_module *module) {
+ pa_dbusiface_module *m;
+
+ pa_assert(module);
+
+ m = pa_xnew0(pa_dbusiface_module, 1);
+ m->module = module;
+ m->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, OBJECT_NAME, module->index);
+ m->proplist = pa_proplist_copy(module->proplist);
+ m->dbus_protocol = pa_dbus_protocol_get(module->core);
+ m->subscription = pa_subscription_new(module->core, PA_SUBSCRIPTION_MASK_MODULE, subscription_cb, m);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(m->dbus_protocol, m->path, &module_interface_info, m) >= 0);
+
+ return m;
+}
+
+void pa_dbusiface_module_free(pa_dbusiface_module *m) {
+ pa_assert(m);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(m->dbus_protocol, m->path, module_interface_info.name) >= 0);
+
+ pa_proplist_free(m->proplist);
+ pa_dbus_protocol_unref(m->dbus_protocol);
+ pa_subscription_free(m->subscription);
+
+ pa_xfree(m->path);
+ pa_xfree(m);
+}
+
+const char *pa_dbusiface_module_get_path(pa_dbusiface_module *m) {
+ pa_assert(m);
+
+ return m->path;
+}
diff --git a/src/modules/module-dbus-protocol.c b/src/modules/dbus/iface-module.h
index 077f4178..68ca1de5 100644
--- a/src/modules/module-dbus-protocol.c
+++ b/src/modules/dbus/iface-module.h
@@ -1,3 +1,6 @@
+#ifndef foodbusifacemodulehfoo
+#define foodbusifacemodulehfoo
+
/***
This file is part of PulseAudio.
@@ -19,48 +22,24 @@
USA.
***/
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <pulse/xmalloc.h>
+/* This object implements the D-Bus interface org.PulseAudio.Core1.Module.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the Module interface
+ * documentation.
+ */
-#include <pulsecore/macro.h>
#include <pulsecore/module.h>
+#include <pulsecore/protocol-dbus.h>
-#include "module-dbus-protocol-symdef.h"
-
-PA_MODULE_DESCRIPTION("D-Bus interface");
-PA_MODULE_USAGE("<no module arguments>");
-PA_MODULE_LOAD_ONCE(TRUE);
-PA_MODULE_AUTHOR("Tanu Kaskinen");
-PA_MODULE_VERSION(PACKAGE_VERSION);
-
-struct userdata {
- pa_module *module;
-};
+#include "iface-core.h"
-int pa__init(pa_module *m) {
- struct userdata *u = NULL;
+#define PA_DBUSIFACE_MODULE_INTERFACE PA_DBUS_CORE_INTERFACE ".Module"
- pa_assert(m);
+typedef struct pa_dbusiface_module pa_dbusiface_module;
- m->userdata = u = pa_xnew0(struct userdata, 1);
- u->module = m;
+pa_dbusiface_module *pa_dbusiface_module_new(pa_module *module);
+void pa_dbusiface_module_free(pa_dbusiface_module *m);
- pa_log_notice("Hello, world!");
+const char *pa_dbusiface_module_get_path(pa_dbusiface_module *m);
- return 0;
-}
-
-void pa__done(pa_module*m) {
- struct userdata *u;
-
- pa_assert(m);
-
- if (!(u = m->userdata))
- return;
-
- pa_xfree(u);
- m->userdata = NULL;
-}
+#endif
diff --git a/src/modules/dbus/iface-sample.c b/src/modules/dbus/iface-sample.c
new file mode 100644
index 00000000..93d4fc8c
--- /dev/null
+++ b/src/modules/dbus/iface-sample.c
@@ -0,0 +1,519 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-sample.h"
+
+#define OBJECT_NAME "sample"
+
+struct pa_dbusiface_sample {
+ pa_dbusiface_core *core;
+
+ pa_scache_entry *sample;
+ char *path;
+ pa_proplist *proplist;
+
+ pa_dbus_protocol *dbus_protocol;
+ pa_subscription *subscription;
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_channels(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_default_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_duration(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_bytes(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_play(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_play_to_sink(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_remove(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_NAME,
+ PROPERTY_HANDLER_SAMPLE_FORMAT,
+ PROPERTY_HANDLER_SAMPLE_RATE,
+ PROPERTY_HANDLER_CHANNELS,
+ PROPERTY_HANDLER_DEFAULT_VOLUME,
+ PROPERTY_HANDLER_DURATION,
+ PROPERTY_HANDLER_BYTES,
+ PROPERTY_HANDLER_PROPERTY_LIST,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_get_name, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLE_FORMAT] = { .property_name = "SampleFormat", .type = "u", .get_cb = handle_get_sample_format, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLE_RATE] = { .property_name = "SampleRate", .type = "u", .get_cb = handle_get_sample_rate, .set_cb = NULL },
+ [PROPERTY_HANDLER_CHANNELS] = { .property_name = "Channels", .type = "au", .get_cb = handle_get_channels, .set_cb = NULL },
+ [PROPERTY_HANDLER_DEFAULT_VOLUME] = { .property_name = "DefaultVolume", .type = "au", .get_cb = handle_get_default_volume, .set_cb = NULL },
+ [PROPERTY_HANDLER_DURATION] = { .property_name = "Duration", .type = "t", .get_cb = handle_get_duration, .set_cb = NULL },
+ [PROPERTY_HANDLER_BYTES] = { .property_name = "Bytes", .type = "u", .get_cb = handle_get_bytes, .set_cb = NULL },
+ [PROPERTY_HANDLER_PROPERTY_LIST] = { .property_name = "PropertyList", .type = "a{say}", .get_cb = handle_get_property_list, .set_cb = NULL }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_PLAY,
+ METHOD_HANDLER_PLAY_TO_SINK,
+ METHOD_HANDLER_REMOVE,
+ METHOD_HANDLER_MAX
+};
+
+static pa_dbus_arg_info play_args[] = { { "volume", "u", "in" }, { "property_list", "a{say}", "in" } };
+static pa_dbus_arg_info play_to_sink_args[] = { { "sink", "o", "in" },
+ { "volume", "u", "in" },
+ { "property_list", "a{say}", "in" } };
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_PLAY] = {
+ .method_name = "Play",
+ .arguments = play_args,
+ .n_arguments = sizeof(play_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_play },
+ [METHOD_HANDLER_PLAY_TO_SINK] = {
+ .method_name = "PlayToSink",
+ .arguments = play_to_sink_args,
+ .n_arguments = sizeof(play_to_sink_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_play_to_sink },
+ [METHOD_HANDLER_REMOVE] = {
+ .method_name = "Remove",
+ .arguments = NULL,
+ .n_arguments = 0,
+ .receive_cb = handle_remove }
+};
+
+enum signal_index {
+ SIGNAL_PROPERTY_LIST_UPDATED,
+ SIGNAL_MAX
+};
+
+static pa_dbus_arg_info property_list_updated_args[] = { { "property_list", "a{say}", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_PROPERTY_LIST_UPDATED] = { .name = "PropertyListUpdated", .arguments = property_list_updated_args, .n_arguments = 1 }
+};
+
+static pa_dbus_interface_info sample_interface_info = {
+ .name = PA_DBUSIFACE_SAMPLE_INTERFACE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ dbus_uint32_t idx = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ idx = s->sample->index;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &idx);
+}
+
+static void handle_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &s->sample->name);
+}
+
+static void handle_get_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ dbus_uint32_t sample_format = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (!s->sample->memchunk.memblock) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sample %s isn't loaded into memory yet, so its sample format is unknown.", s->sample->name);
+ return;
+ }
+
+ sample_format = s->sample->sample_spec.format;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sample_format);
+}
+
+static void handle_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ dbus_uint32_t sample_rate = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (!s->sample->memchunk.memblock) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sample %s isn't loaded into memory yet, so its sample rate is unknown.", s->sample->name);
+ return;
+ }
+
+ sample_rate = s->sample->sample_spec.rate;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sample_rate);
+}
+
+static void handle_get_channels(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ dbus_uint32_t channels[PA_CHANNELS_MAX];
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (!s->sample->memchunk.memblock) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sample %s isn't loaded into memory yet, so its channel map is unknown.", s->sample->name);
+ return;
+ }
+
+ for (i = 0; i < s->sample->channel_map.channels; ++i)
+ channels[i] = s->sample->channel_map.map[i];
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_UINT32, channels, s->sample->channel_map.channels);
+}
+
+static void handle_get_default_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ dbus_uint32_t default_volume[PA_CHANNELS_MAX];
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (!s->sample->volume_is_set) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sample %s doesn't have default volume stored.", s->sample->name);
+ return;
+ }
+
+ for (i = 0; i < s->sample->volume.channels; ++i)
+ default_volume[i] = s->sample->volume.values[i];
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_UINT32, default_volume, s->sample->volume.channels);
+}
+
+static void handle_get_duration(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ dbus_uint64_t duration = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (!s->sample->memchunk.memblock) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sample %s isn't loaded into memory yet, so its duration is unknown.", s->sample->name);
+ return;
+ }
+
+ duration = pa_bytes_to_usec(s->sample->memchunk.length, &s->sample->sample_spec);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT64, &duration);
+}
+
+static void handle_get_bytes(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ dbus_uint32_t bytes = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (!s->sample->memchunk.memblock) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY,
+ "Sample %s isn't loaded into memory yet, so its size is unknown.", s->sample->name);
+ return;
+ }
+
+ bytes = s->sample->memchunk.length;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &bytes);
+}
+
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ pa_dbus_send_proplist_variant_reply(conn, msg, s->proplist);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t idx = 0;
+ dbus_uint32_t sample_format = 0;
+ dbus_uint32_t sample_rate = 0;
+ dbus_uint32_t channels[PA_CHANNELS_MAX];
+ dbus_uint32_t default_volume[PA_CHANNELS_MAX];
+ dbus_uint64_t duration = 0;
+ dbus_uint32_t bytes = 0;
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ idx = s->sample->index;
+ if (s->sample->memchunk.memblock) {
+ sample_format = s->sample->sample_spec.format;
+ sample_rate = s->sample->sample_spec.rate;
+ for (i = 0; i < s->sample->channel_map.channels; ++i)
+ channels[i] = s->sample->channel_map.map[i];
+ duration = pa_bytes_to_usec(s->sample->memchunk.length, &s->sample->sample_spec);
+ bytes = s->sample->memchunk.length;
+ }
+ if (s->sample->volume_is_set) {
+ for (i = 0; i < s->sample->volume.channels; ++i)
+ default_volume[i] = s->sample->volume.values[i];
+ }
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &idx);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &s->sample->name);
+
+ if (s->sample->memchunk.memblock) {
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLE_FORMAT].property_name, DBUS_TYPE_UINT32, &sample_format);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLE_RATE].property_name, DBUS_TYPE_UINT32, &sample_rate);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CHANNELS].property_name, DBUS_TYPE_UINT32, channels, s->sample->channel_map.channels);
+ }
+
+ if (s->sample->volume_is_set)
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DEFAULT_VOLUME].property_name, DBUS_TYPE_UINT32, default_volume, s->sample->volume.channels);
+
+ if (s->sample->memchunk.memblock) {
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DURATION].property_name, DBUS_TYPE_UINT64, &duration);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_BYTES].property_name, DBUS_TYPE_UINT32, &bytes);
+ }
+
+ pa_dbus_append_proplist_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PROPERTY_LIST].property_name, s->proplist);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+static void handle_play(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ DBusMessageIter msg_iter;
+ dbus_uint32_t volume = 0;
+ pa_proplist *property_list = NULL;
+ pa_sink *sink = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ pa_assert_se(dbus_message_iter_init(msg, &msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &volume);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ if (!(property_list = pa_dbus_get_proplist_arg(conn, msg, &msg_iter)))
+ return;
+
+ if (!PA_VOLUME_IS_VALID(volume)) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid volume.");
+ goto finish;
+ }
+
+ if (!(sink = pa_namereg_get_default_sink(s->sample->core))) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED,
+ "Can't play sample %s, because there are no sinks available.", s->sample->name);
+ goto finish;
+ }
+
+ if (pa_scache_play_item(s->sample->core, s->sample->name, sink, volume, property_list, NULL) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "Playing sample %s failed.", s->sample->name);
+ goto finish;
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+finish:
+ if (property_list)
+ pa_proplist_free(property_list);
+}
+
+static void handle_play_to_sink(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ DBusMessageIter msg_iter;
+ const char *sink_path = NULL;
+ dbus_uint32_t volume = 0;
+ pa_proplist *property_list = NULL;
+ pa_sink *sink = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ pa_assert_se(dbus_message_iter_init(msg, &msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &sink_path);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &volume);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ if (!(property_list = pa_dbus_get_proplist_arg(conn, msg, &msg_iter)))
+ return;
+
+ if (!(sink = pa_dbusiface_core_get_sink(s->core, sink_path))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such sink.", sink_path);
+ goto finish;
+ }
+
+ if (!PA_VOLUME_IS_VALID(volume)) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid volume.");
+ goto finish;
+ }
+
+ if (pa_scache_play_item(s->sample->core, s->sample->name, sink, volume, property_list, NULL) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "Playing sample %s failed.", s->sample->name);
+ goto finish;
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+finish:
+ if (property_list)
+ pa_proplist_free(property_list);
+}
+
+static void handle_remove(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (pa_scache_remove_item(s->sample->core, s->sample->name) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "Removing sample %s failed.", s->sample->name);
+ return;
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void subscription_cb(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ pa_dbusiface_sample *s = userdata;
+ DBusMessage *signal_msg = NULL;
+
+ pa_assert(c);
+ pa_assert(s);
+
+ /* We can't use idx != s->sample->index, because the s->sample pointer may
+ * be stale at this point. */
+ if (pa_idxset_get_by_index(c->scache, idx) != s->sample)
+ return;
+
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) != PA_SUBSCRIPTION_EVENT_CHANGE)
+ return;
+
+ if (!pa_proplist_equal(s->proplist, s->sample->proplist)) {
+ DBusMessageIter msg_iter;
+
+ pa_proplist_update(s->proplist, PA_UPDATE_SET, s->sample->proplist);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_SAMPLE_INTERFACE,
+ signals[SIGNAL_PROPERTY_LIST_UPDATED].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_dbus_append_proplist(&msg_iter, s->proplist);
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+}
+
+pa_dbusiface_sample *pa_dbusiface_sample_new(pa_dbusiface_core *core, pa_scache_entry *sample) {
+ pa_dbusiface_sample *s = NULL;
+
+ pa_assert(core);
+ pa_assert(sample);
+
+ s = pa_xnew0(pa_dbusiface_sample, 1);
+ s->core = core;
+ s->sample = sample;
+ s->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, OBJECT_NAME, sample->index);
+ s->proplist = pa_proplist_copy(sample->proplist);
+ s->dbus_protocol = pa_dbus_protocol_get(sample->core);
+ s->subscription = pa_subscription_new(sample->core, PA_SUBSCRIPTION_MASK_SAMPLE_CACHE, subscription_cb, s);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(s->dbus_protocol, s->path, &sample_interface_info, s) >= 0);
+
+ return s;
+}
+
+void pa_dbusiface_sample_free(pa_dbusiface_sample *s) {
+ pa_assert(s);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(s->dbus_protocol, s->path, sample_interface_info.name) >= 0);
+
+ pa_proplist_free(s->proplist);
+ pa_dbus_protocol_unref(s->dbus_protocol);
+ pa_subscription_free(s->subscription);
+
+ pa_xfree(s->path);
+ pa_xfree(s);
+}
+
+const char *pa_dbusiface_sample_get_path(pa_dbusiface_sample *s) {
+ pa_assert(s);
+
+ return s->path;
+}
diff --git a/src/modules/dbus/iface-sample.h b/src/modules/dbus/iface-sample.h
new file mode 100644
index 00000000..f1947ce8
--- /dev/null
+++ b/src/modules/dbus/iface-sample.h
@@ -0,0 +1,45 @@
+#ifndef foodbusifacesamplehfoo
+#define foodbusifacesamplehfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.Sample.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the Sample interface
+ * documentation.
+ */
+
+#include <pulsecore/core-scache.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-core.h"
+
+#define PA_DBUSIFACE_SAMPLE_INTERFACE PA_DBUS_CORE_INTERFACE ".Sample"
+
+typedef struct pa_dbusiface_sample pa_dbusiface_sample;
+
+pa_dbusiface_sample *pa_dbusiface_sample_new(pa_dbusiface_core *core, pa_scache_entry *sample);
+void pa_dbusiface_sample_free(pa_dbusiface_sample *c);
+
+const char *pa_dbusiface_sample_get_path(pa_dbusiface_sample *c);
+
+#endif
diff --git a/src/modules/dbus/iface-stream.c b/src/modules/dbus/iface-stream.c
new file mode 100644
index 00000000..d9f12374
--- /dev/null
+++ b/src/modules/dbus/iface-stream.c
@@ -0,0 +1,933 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+ Copyright 2009 Vincent Filali-Ansary <filali.v@azurdigitalnetworks.net>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-stream.h"
+
+#define PLAYBACK_OBJECT_NAME "playback_stream"
+#define RECORD_OBJECT_NAME "record_stream"
+
+enum stream_type {
+ STREAM_TYPE_PLAYBACK,
+ STREAM_TYPE_RECORD
+};
+
+struct pa_dbusiface_stream {
+ pa_dbusiface_core *core;
+
+ union {
+ pa_sink_input *sink_input;
+ pa_source_output *source_output;
+ };
+ enum stream_type type;
+ char *path;
+ union {
+ pa_sink *sink;
+ pa_source *source;
+ };
+ uint32_t sample_rate;
+ pa_cvolume volume;
+ dbus_bool_t mute;
+ pa_proplist *proplist;
+
+ pa_bool_t has_volume;
+
+ pa_dbus_protocol *dbus_protocol;
+ pa_subscription *subscription;
+ pa_hook_slot *send_event_slot;
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_client(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_device(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_channels(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_volume(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_mute(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_set_mute(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_get_buffer_latency(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_device_latency(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_resample_method(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_move(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_kill(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INDEX,
+ PROPERTY_HANDLER_DRIVER,
+ PROPERTY_HANDLER_OWNER_MODULE,
+ PROPERTY_HANDLER_CLIENT,
+ PROPERTY_HANDLER_DEVICE,
+ PROPERTY_HANDLER_SAMPLE_FORMAT,
+ PROPERTY_HANDLER_SAMPLE_RATE,
+ PROPERTY_HANDLER_CHANNELS,
+ PROPERTY_HANDLER_VOLUME,
+ PROPERTY_HANDLER_MUTE,
+ PROPERTY_HANDLER_BUFFER_LATENCY,
+ PROPERTY_HANDLER_DEVICE_LATENCY,
+ PROPERTY_HANDLER_RESAMPLE_METHOD,
+ PROPERTY_HANDLER_PROPERTY_LIST,
+ PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_get_index, .set_cb = NULL },
+ [PROPERTY_HANDLER_DRIVER] = { .property_name = "Driver", .type = "s", .get_cb = handle_get_driver, .set_cb = NULL },
+ [PROPERTY_HANDLER_OWNER_MODULE] = { .property_name = "OwnerModule", .type = "o", .get_cb = handle_get_owner_module, .set_cb = NULL },
+ [PROPERTY_HANDLER_CLIENT] = { .property_name = "Client", .type = "o", .get_cb = handle_get_client, .set_cb = NULL },
+ [PROPERTY_HANDLER_DEVICE] = { .property_name = "Device", .type = "o", .get_cb = handle_get_device, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLE_FORMAT] = { .property_name = "SampleFormat", .type = "u", .get_cb = handle_get_sample_format, .set_cb = NULL },
+ [PROPERTY_HANDLER_SAMPLE_RATE] = { .property_name = "SampleRate", .type = "u", .get_cb = handle_get_sample_rate, .set_cb = NULL },
+ [PROPERTY_HANDLER_CHANNELS] = { .property_name = "Channels", .type = "au", .get_cb = handle_get_channels, .set_cb = NULL },
+ [PROPERTY_HANDLER_VOLUME] = { .property_name = "Volume", .type = "au", .get_cb = handle_get_volume, .set_cb = handle_set_volume },
+ [PROPERTY_HANDLER_MUTE] = { .property_name = "Mute", .type = "b", .get_cb = handle_get_mute, .set_cb = handle_set_mute },
+ [PROPERTY_HANDLER_BUFFER_LATENCY] = { .property_name = "BufferLatency", .type = "t", .get_cb = handle_get_buffer_latency, .set_cb = NULL },
+ [PROPERTY_HANDLER_DEVICE_LATENCY] = { .property_name = "DeviceLatency", .type = "t", .get_cb = handle_get_device_latency, .set_cb = NULL },
+ [PROPERTY_HANDLER_RESAMPLE_METHOD] = { .property_name = "ResampleMethod", .type = "s", .get_cb = handle_get_resample_method, .set_cb = NULL },
+ [PROPERTY_HANDLER_PROPERTY_LIST] = { .property_name = "PropertyList", .type = "a{say}", .get_cb = handle_get_property_list, .set_cb = NULL }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_MOVE,
+ METHOD_HANDLER_KILL,
+ METHOD_HANDLER_MAX
+};
+
+static pa_dbus_arg_info move_args[] = { { "device", "o", "in" } };
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_MOVE] = {
+ .method_name = "Move",
+ .arguments = move_args,
+ .n_arguments = sizeof(move_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_move },
+ [METHOD_HANDLER_KILL] = {
+ .method_name = "Kill",
+ .arguments = NULL,
+ .n_arguments = 0,
+ .receive_cb = handle_kill }
+};
+
+enum signal_index {
+ SIGNAL_DEVICE_UPDATED,
+ SIGNAL_SAMPLE_RATE_UPDATED,
+ SIGNAL_VOLUME_UPDATED,
+ SIGNAL_MUTE_UPDATED,
+ SIGNAL_PROPERTY_LIST_UPDATED,
+ SIGNAL_STREAM_EVENT,
+ SIGNAL_MAX
+};
+
+static pa_dbus_arg_info device_updated_args[] = { { "device", "o", NULL } };
+static pa_dbus_arg_info sample_rate_updated_args[] = { { "sample_rate", "u", NULL } };
+static pa_dbus_arg_info volume_updated_args[] = { { "volume", "au", NULL } };
+static pa_dbus_arg_info mute_updated_args[] = { { "muted", "b", NULL } };
+static pa_dbus_arg_info property_list_updated_args[] = { { "property_list", "a{say}", NULL } };
+static pa_dbus_arg_info stream_event_args[] = { { "name", "s", NULL }, { "property_list", "a{say}", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_DEVICE_UPDATED] = { .name = "DeviceUpdated", .arguments = device_updated_args, .n_arguments = 1 },
+ [SIGNAL_SAMPLE_RATE_UPDATED] = { .name = "SampleRateUpdated", .arguments = sample_rate_updated_args, .n_arguments = 1 },
+ [SIGNAL_VOLUME_UPDATED] = { .name = "VolumeUpdated", .arguments = volume_updated_args, .n_arguments = 1 },
+ [SIGNAL_MUTE_UPDATED] = { .name = "MuteUpdated", .arguments = mute_updated_args, .n_arguments = 1 },
+ [SIGNAL_PROPERTY_LIST_UPDATED] = { .name = "PropertyListUpdated", .arguments = property_list_updated_args, .n_arguments = 1 },
+ [SIGNAL_STREAM_EVENT] = { .name = "StreamEvent", .arguments = stream_event_args, .n_arguments = sizeof(stream_event_args) / sizeof(pa_dbus_arg_info) }
+};
+
+static pa_dbus_interface_info stream_interface_info = {
+ .name = PA_DBUSIFACE_STREAM_INTERFACE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ dbus_uint32_t idx;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ idx = (s->type == STREAM_TYPE_PLAYBACK) ? s->sink_input->index : s->source_output->index;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &idx);
+}
+
+/* The returned string has to be freed with pa_xfree() by the caller. */
+static char *stream_to_string(pa_dbusiface_stream *s) {
+ if (s->type == STREAM_TYPE_PLAYBACK)
+ return pa_sprintf_malloc("Playback stream %u", (unsigned) s->sink_input->index);
+ else
+ return pa_sprintf_malloc("Record stream %u", (unsigned) s->source_output->index);
+}
+
+static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ const char *driver = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ driver = (s->type == STREAM_TYPE_PLAYBACK) ? s->sink_input->driver : s->source_output->driver;
+
+ if (!driver) {
+ char *str = stream_to_string(s);
+
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "%s doesn't have a driver.", str);
+ pa_xfree(str);
+
+ return;
+ }
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &driver);
+}
+
+static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ pa_module *owner_module = NULL;
+ const char *object_path = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ owner_module = (s->type == STREAM_TYPE_PLAYBACK) ? s->sink_input->module : s->source_output->module;
+
+ if (!owner_module) {
+ char *str = stream_to_string(s);
+
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "%s doesn't have an owner module.", str);
+ pa_xfree(str);
+
+ return;
+ }
+
+ object_path = pa_dbusiface_core_get_module_path(s->core, owner_module);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_get_client(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ pa_client *client = NULL;
+ const char *object_path = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ client = (s->type == STREAM_TYPE_PLAYBACK) ? s->sink_input->client : s->source_output->client;
+
+ if (!client) {
+ char *str = stream_to_string(s);
+
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "%s isn't associated to any client.", str);
+ pa_xfree(str);
+
+ return;
+ }
+
+ object_path = pa_dbusiface_core_get_client_path(s->core, client);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &object_path);
+}
+
+static void handle_get_device(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ const char *device = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (s->type == STREAM_TYPE_PLAYBACK)
+ device = pa_dbusiface_core_get_sink_path(s->core, s->sink);
+ else
+ device = pa_dbusiface_core_get_source_path(s->core, s->source);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &device);
+}
+
+static void handle_get_sample_format(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ dbus_uint32_t sample_format = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ sample_format = (s->type == STREAM_TYPE_PLAYBACK)
+ ? s->sink_input->sample_spec.format
+ : s->source_output->sample_spec.format;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &sample_format);
+}
+
+static void handle_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &s->sample_rate);
+}
+
+static void handle_get_channels(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ pa_channel_map *channel_map = NULL;
+ dbus_uint32_t channels[PA_CHANNELS_MAX];
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ channel_map = (s->type == STREAM_TYPE_PLAYBACK) ? &s->sink_input->channel_map : &s->source_output->channel_map;
+
+ for (i = 0; i < channel_map->channels; ++i)
+ channels[i] = channel_map->map[i];
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_UINT32, channels, channel_map->channels);
+}
+
+static void handle_get_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ dbus_uint32_t volume[PA_CHANNELS_MAX];
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (!s->has_volume) {
+ char *str = stream_to_string(s);
+
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "%s doesn't have volume.", str);
+ pa_xfree(str);
+
+ return;
+ }
+
+ for (i = 0; i < s->volume.channels; ++i)
+ volume[i] = s->volume.values[i];
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_UINT32, volume, s->volume.channels);
+}
+
+static void handle_set_volume(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ pa_bool_t volume_writable = TRUE;
+ DBusMessageIter array_iter;
+ int stream_channels = 0;
+ dbus_uint32_t *volume = NULL;
+ int n_volume_entries = 0;
+ pa_cvolume new_vol;
+ int i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(s);
+
+ volume_writable = (s->type == STREAM_TYPE_PLAYBACK) ? s->sink_input->volume_writable : FALSE;
+
+ if (!s->has_volume || !volume_writable) {
+ char *str = stream_to_string(s);
+
+ if (!s->has_volume)
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "%s doesn't have volume.", str);
+ else if (!volume_writable)
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_ACCESS_DENIED, "%s has read-only volume.", str);
+ pa_xfree(str);
+
+ return;
+ }
+
+ stream_channels = s->sink_input->channel_map.channels;
+
+ dbus_message_iter_recurse(iter, &array_iter);
+ dbus_message_iter_get_fixed_array(&array_iter, &volume, &n_volume_entries);
+
+ if (n_volume_entries != stream_channels && n_volume_entries != 1) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS,
+ "Expected %u volume entries, got %u.", stream_channels, n_volume_entries);
+ return;
+ }
+
+ pa_cvolume_init(&new_vol);
+ new_vol.channels = n_volume_entries;
+
+ for (i = 0; i < n_volume_entries; ++i) {
+ if (!PA_VOLUME_IS_VALID(volume[i])) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid volume: %u", volume[i]);
+ return;
+ }
+ new_vol.values[i] = volume[i];
+ }
+
+ pa_sink_input_set_volume(s->sink_input, &new_vol, TRUE, TRUE);
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_get_mute(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (s->type == STREAM_TYPE_RECORD) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "Record streams don't have mute.");
+ return;
+ }
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &s->mute);
+}
+
+static void handle_set_mute(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ dbus_bool_t mute = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(s);
+
+ dbus_message_iter_get_basic(iter, &mute);
+
+ if (s->type == STREAM_TYPE_RECORD) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "Record streams don't have mute.");
+ return;
+ }
+
+ pa_sink_input_set_mute(s->sink_input, mute, TRUE);
+
+ pa_dbus_send_empty_reply(conn, msg);
+};
+
+static void handle_get_buffer_latency(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ dbus_uint64_t buffer_latency = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (s->type == STREAM_TYPE_PLAYBACK)
+ buffer_latency = pa_sink_input_get_latency(s->sink_input, NULL);
+ else
+ buffer_latency = pa_source_output_get_latency(s->source_output, NULL);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT64, &buffer_latency);
+}
+
+static void handle_get_device_latency(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ dbus_uint64_t device_latency = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (s->type == STREAM_TYPE_PLAYBACK)
+ pa_sink_input_get_latency(s->sink_input, &device_latency);
+ else
+ pa_source_output_get_latency(s->source_output, &device_latency);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT64, &device_latency);
+}
+
+static void handle_get_resample_method(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ const char *resample_method = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (s->type == STREAM_TYPE_PLAYBACK)
+ resample_method = pa_resample_method_to_string(s->sink_input->actual_resample_method);
+ else
+ resample_method = pa_resample_method_to_string(s->source_output->actual_resample_method);
+
+ if (!resample_method)
+ resample_method = "";
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &resample_method);
+}
+
+static void handle_get_property_list(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ pa_dbus_send_proplist_variant_reply(conn, msg, s->proplist);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t idx = 0;
+ const char *driver = NULL;
+ pa_module *owner_module = NULL;
+ const char *owner_module_path = NULL;
+ pa_client *client = NULL;
+ const char *client_path = NULL;
+ const char *device = NULL;
+ dbus_uint32_t sample_format = 0;
+ pa_channel_map *channel_map = NULL;
+ dbus_uint32_t channels[PA_CHANNELS_MAX];
+ dbus_uint32_t volume[PA_CHANNELS_MAX];
+ dbus_uint64_t buffer_latency = 0;
+ dbus_uint64_t device_latency = 0;
+ const char *resample_method = NULL;
+ unsigned i = 0;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (s->has_volume) {
+ for (i = 0; i < s->volume.channels; ++i)
+ volume[i] = s->volume.values[i];
+ }
+
+ if (s->type == STREAM_TYPE_PLAYBACK) {
+ idx = s->sink_input->index;
+ driver = s->sink_input->driver;
+ owner_module = s->sink_input->module;
+ client = s->sink_input->client;
+ device = pa_dbusiface_core_get_sink_path(s->core, s->sink);
+ sample_format = s->sink_input->sample_spec.format;
+ channel_map = &s->sink_input->channel_map;
+ buffer_latency = pa_sink_input_get_latency(s->sink_input, &device_latency);
+ resample_method = pa_resample_method_to_string(s->sink_input->actual_resample_method);
+ } else {
+ idx = s->source_output->index;
+ driver = s->source_output->driver;
+ owner_module = s->source_output->module;
+ client = s->source_output->client;
+ device = pa_dbusiface_core_get_source_path(s->core, s->source);
+ sample_format = s->source_output->sample_spec.format;
+ channel_map = &s->source_output->channel_map;
+ buffer_latency = pa_source_output_get_latency(s->source_output, &device_latency);
+ resample_method = pa_resample_method_to_string(s->source_output->actual_resample_method);
+ }
+ if (owner_module)
+ owner_module_path = pa_dbusiface_core_get_module_path(s->core, owner_module);
+ if (client)
+ client_path = pa_dbusiface_core_get_client_path(s->core, client);
+ for (i = 0; i < channel_map->channels; ++i)
+ channels[i] = channel_map->map[i];
+ if (!resample_method)
+ resample_method = "";
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &idx);
+
+ if (driver)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DRIVER].property_name, DBUS_TYPE_STRING, &driver);
+
+ if (owner_module)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_OWNER_MODULE].property_name, DBUS_TYPE_OBJECT_PATH, &owner_module_path);
+
+ if (client)
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CLIENT].property_name, DBUS_TYPE_OBJECT_PATH, &client_path);
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DEVICE].property_name, DBUS_TYPE_OBJECT_PATH, &device);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLE_FORMAT].property_name, DBUS_TYPE_UINT32, &sample_format);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_SAMPLE_RATE].property_name, DBUS_TYPE_UINT32, &s->sample_rate);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_CHANNELS].property_name, DBUS_TYPE_UINT32, channels, channel_map->channels);
+
+ if (s->has_volume) {
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_VOLUME].property_name, DBUS_TYPE_UINT32, volume, s->volume.channels);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_MUTE].property_name, DBUS_TYPE_BOOLEAN, &s->mute);
+ }
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_BUFFER_LATENCY].property_name, DBUS_TYPE_UINT64, &buffer_latency);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_DEVICE_LATENCY].property_name, DBUS_TYPE_UINT64, &device_latency);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_RESAMPLE_METHOD].property_name, DBUS_TYPE_STRING, &resample_method);
+ pa_dbus_append_proplist_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_PROPERTY_LIST].property_name, s->proplist);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+static void handle_move(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ const char *device = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &device, DBUS_TYPE_INVALID));
+
+ if (s->type == STREAM_TYPE_PLAYBACK) {
+ pa_sink *sink = pa_dbusiface_core_get_sink(s->core, device);
+
+ if (!sink) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such sink.", device);
+ return;
+ }
+
+ if (pa_sink_input_move_to(s->sink_input, sink, TRUE) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED,
+ "Moving playback stream %u to sink %s failed.", s->sink_input->index, sink->name);
+ return;
+ }
+ } else {
+ pa_source *source = pa_dbusiface_core_get_source(s->core, device);
+
+ if (!source) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "%s: No such source.", device);
+ return;
+ }
+
+ if (pa_source_output_move_to(s->source_output, source, TRUE) < 0) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED,
+ "Moving record stream %u to source %s failed.", s->source_output->index, source->name);
+ return;
+ }
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void handle_kill(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(s);
+
+ if (s->type == STREAM_TYPE_PLAYBACK)
+ pa_sink_input_kill(s->sink_input);
+ else
+ pa_source_output_kill(s->source_output);
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+static void subscription_cb(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ pa_dbusiface_stream *s = userdata;
+ DBusMessage *signal_msg = NULL;
+ const char *new_device_path = NULL;
+ uint32_t new_sample_rate = 0;
+ pa_proplist *new_proplist = NULL;
+ unsigned i = 0;
+
+ pa_assert(c);
+ pa_assert(s);
+
+ if ((s->type == STREAM_TYPE_PLAYBACK && idx != s->sink_input->index)
+ || (s->type == STREAM_TYPE_RECORD && idx != s->source_output->index))
+ return;
+
+ if ((t & PA_SUBSCRIPTION_EVENT_TYPE_MASK) != PA_SUBSCRIPTION_EVENT_CHANGE)
+ return;
+
+ pa_assert(((s->type == STREAM_TYPE_PLAYBACK)
+ && ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SINK_INPUT))
+ || ((s->type == STREAM_TYPE_RECORD)
+ && ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT)));
+
+ if (s->type == STREAM_TYPE_PLAYBACK) {
+ pa_sink *new_sink = s->sink_input->sink;
+
+ if (s->sink != new_sink) {
+ pa_sink_unref(s->sink);
+ s->sink = pa_sink_ref(new_sink);
+
+ new_device_path = pa_dbusiface_core_get_sink_path(s->core, new_sink);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_STREAM_INTERFACE,
+ signals[SIGNAL_DEVICE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &new_device_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+ } else {
+ pa_source *new_source = s->source_output->source;
+
+ if (s->source != new_source) {
+ pa_source_unref(s->source);
+ s->source = pa_source_ref(new_source);
+
+ new_device_path = pa_dbusiface_core_get_source_path(s->core, new_source);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_STREAM_INTERFACE,
+ signals[SIGNAL_DEVICE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &new_device_path, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+ }
+
+ new_sample_rate = (s->type == STREAM_TYPE_PLAYBACK) ? s->sink_input->sample_spec.rate : s->source_output->sample_spec.rate;
+
+ if (s->sample_rate != new_sample_rate) {
+ s->sample_rate = new_sample_rate;
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_STREAM_INTERFACE,
+ signals[SIGNAL_SAMPLE_RATE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_UINT32, &s->sample_rate, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+
+ if (s->type == STREAM_TYPE_PLAYBACK) {
+ pa_bool_t new_mute = FALSE;
+
+ if (s->has_volume) {
+ pa_cvolume new_volume;
+
+ pa_sink_input_get_volume(s->sink_input, &new_volume, TRUE);
+
+ if (!pa_cvolume_equal(&s->volume, &new_volume)) {
+ dbus_uint32_t volume[PA_CHANNELS_MAX];
+ dbus_uint32_t *volume_ptr = volume;
+
+ s->volume = new_volume;
+
+ for (i = 0; i < s->volume.channels; ++i)
+ volume[i] = s->volume.values[i];
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_STREAM_INTERFACE,
+ signals[SIGNAL_VOLUME_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_UINT32, &volume_ptr, s->volume.channels,
+ DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+ }
+
+ new_mute = pa_sink_input_get_mute(s->sink_input);
+
+ if (s->mute != new_mute) {
+ s->mute = new_mute;
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_STREAM_INTERFACE,
+ signals[SIGNAL_MUTE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_BOOLEAN, &s->mute, DBUS_TYPE_INVALID));
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+ }
+
+ new_proplist = (s->type == STREAM_TYPE_PLAYBACK) ? s->sink_input->proplist : s->source_output->proplist;
+
+ if (!pa_proplist_equal(s->proplist, new_proplist)) {
+ DBusMessageIter msg_iter;
+
+ pa_proplist_update(s->proplist, PA_UPDATE_SET, new_proplist);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_STREAM_INTERFACE,
+ signals[SIGNAL_PROPERTY_LIST_UPDATED].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_dbus_append_proplist(&msg_iter, s->proplist);
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+ signal_msg = NULL;
+ }
+}
+
+static pa_hook_result_t send_event_cb(void *hook_data, void *call_data, void *slot_data) {
+ pa_dbusiface_stream *s = slot_data;
+ DBusMessage *signal_msg = NULL;
+ DBusMessageIter msg_iter;
+ const char *name = NULL;
+ pa_proplist *property_list = NULL;
+
+ pa_assert(call_data);
+ pa_assert(s);
+
+ if (s->type == STREAM_TYPE_PLAYBACK) {
+ pa_sink_input_send_event_hook_data *data = call_data;
+
+ if (data->sink_input != s->sink_input)
+ return PA_HOOK_OK;
+
+ name = data->event;
+ property_list = data->data;
+ } else {
+ pa_source_output_send_event_hook_data *data = call_data;
+
+ if (data->source_output != s->source_output)
+ return PA_HOOK_OK;
+
+ name = data->event;
+ property_list = data->data;
+ }
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(s->path,
+ PA_DBUSIFACE_STREAM_INTERFACE,
+ signals[SIGNAL_STREAM_EVENT].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_assert_se(dbus_message_iter_append_basic(&msg_iter, DBUS_TYPE_STRING, &name));
+ pa_dbus_append_proplist(&msg_iter, property_list);
+
+ pa_dbus_protocol_send_signal(s->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+
+ return PA_HOOK_OK;
+}
+
+pa_dbusiface_stream *pa_dbusiface_stream_new_playback(pa_dbusiface_core *core, pa_sink_input *sink_input) {
+ pa_dbusiface_stream *s;
+
+ pa_assert(core);
+ pa_assert(sink_input);
+
+ s = pa_xnew(pa_dbusiface_stream, 1);
+ s->core = core;
+ s->sink_input = pa_sink_input_ref(sink_input);
+ s->type = STREAM_TYPE_PLAYBACK;
+ s->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, PLAYBACK_OBJECT_NAME, sink_input->index);
+ s->sink = pa_sink_ref(sink_input->sink);
+ s->sample_rate = sink_input->sample_spec.rate;
+ s->has_volume = pa_sink_input_is_volume_readable(sink_input);
+
+ if (s->has_volume)
+ pa_sink_input_get_volume(sink_input, &s->volume, TRUE);
+ else
+ pa_cvolume_init(&s->volume);
+
+ s->mute = pa_sink_input_get_mute(sink_input);
+ s->proplist = pa_proplist_copy(sink_input->proplist);
+ s->dbus_protocol = pa_dbus_protocol_get(sink_input->core);
+ s->subscription = pa_subscription_new(sink_input->core, PA_SUBSCRIPTION_MASK_SINK_INPUT, subscription_cb, s);
+ s->send_event_slot = pa_hook_connect(&sink_input->core->hooks[PA_CORE_HOOK_SINK_INPUT_SEND_EVENT],
+ PA_HOOK_NORMAL,
+ send_event_cb,
+ s);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(s->dbus_protocol, s->path, &stream_interface_info, s) >= 0);
+
+ return s;
+}
+
+pa_dbusiface_stream *pa_dbusiface_stream_new_record(pa_dbusiface_core *core, pa_source_output *source_output) {
+ pa_dbusiface_stream *s;
+
+ pa_assert(core);
+ pa_assert(source_output);
+
+ s = pa_xnew(pa_dbusiface_stream, 1);
+ s->core = core;
+ s->source_output = pa_source_output_ref(source_output);
+ s->type = STREAM_TYPE_RECORD;
+ s->path = pa_sprintf_malloc("%s/%s%u", PA_DBUS_CORE_OBJECT_PATH, RECORD_OBJECT_NAME, source_output->index);
+ s->source = pa_source_ref(source_output->source);
+ s->sample_rate = source_output->sample_spec.rate;
+ pa_cvolume_init(&s->volume);
+ s->mute = FALSE;
+ s->proplist = pa_proplist_copy(source_output->proplist);
+ s->has_volume = FALSE;
+ s->dbus_protocol = pa_dbus_protocol_get(source_output->core);
+ s->subscription = pa_subscription_new(source_output->core, PA_SUBSCRIPTION_MASK_SOURCE_OUTPUT, subscription_cb, s);
+ s->send_event_slot = pa_hook_connect(&source_output->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_SEND_EVENT],
+ PA_HOOK_NORMAL,
+ send_event_cb,
+ s);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(s->dbus_protocol, s->path, &stream_interface_info, s) >= 0);
+
+ return s;
+}
+
+void pa_dbusiface_stream_free(pa_dbusiface_stream *s) {
+ pa_assert(s);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(s->dbus_protocol, s->path, stream_interface_info.name) >= 0);
+
+ if (s->type == STREAM_TYPE_PLAYBACK) {
+ pa_sink_input_unref(s->sink_input);
+ pa_sink_unref(s->sink);
+ } else {
+ pa_source_output_unref(s->source_output);
+ pa_source_unref(s->source);
+ }
+
+ pa_proplist_free(s->proplist);
+ pa_dbus_protocol_unref(s->dbus_protocol);
+ pa_subscription_free(s->subscription);
+ pa_hook_slot_free(s->send_event_slot);
+
+ pa_xfree(s->path);
+ pa_xfree(s);
+}
+
+const char *pa_dbusiface_stream_get_path(pa_dbusiface_stream *s) {
+ pa_assert(s);
+
+ return s->path;
+}
diff --git a/src/modules/dbus/iface-stream.h b/src/modules/dbus/iface-stream.h
new file mode 100644
index 00000000..036b4e7e
--- /dev/null
+++ b/src/modules/dbus/iface-stream.h
@@ -0,0 +1,47 @@
+#ifndef foodbusifacestreamhfoo
+#define foodbusifacestreamhfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* This object implements the D-Bus interface org.PulseAudio.Core1.Stream.
+ *
+ * See http://pulseaudio.org/wiki/DBusInterface for the Stream interface
+ * documentation.
+ */
+
+#include <pulsecore/protocol-dbus.h>
+#include <pulsecore/sink-input.h>
+#include <pulsecore/source-output.h>
+
+#include "iface-core.h"
+
+#define PA_DBUSIFACE_STREAM_INTERFACE PA_DBUS_CORE_INTERFACE ".Stream"
+
+typedef struct pa_dbusiface_stream pa_dbusiface_stream;
+
+pa_dbusiface_stream *pa_dbusiface_stream_new_playback(pa_dbusiface_core *core, pa_sink_input *sink_input);
+pa_dbusiface_stream *pa_dbusiface_stream_new_record(pa_dbusiface_core *core, pa_source_output *source_output);
+void pa_dbusiface_stream_free(pa_dbusiface_stream *s);
+
+const char *pa_dbusiface_stream_get_path(pa_dbusiface_stream *s);
+
+#endif
diff --git a/src/modules/dbus/module-dbus-protocol.c b/src/modules/dbus/module-dbus-protocol.c
new file mode 100644
index 00000000..4969585f
--- /dev/null
+++ b/src/modules/dbus/module-dbus-protocol.c
@@ -0,0 +1,621 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+ Copyright 2006 Lennart Poettering
+ Copyright 2006 Shams E. King
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulse/mainloop-api.h>
+#include <pulse/timeval.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/client.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/idxset.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/module.h>
+#include <pulsecore/protocol-dbus.h>
+
+#include "iface-client.h"
+#include "iface-core.h"
+
+#include "module-dbus-protocol-symdef.h"
+
+PA_MODULE_DESCRIPTION("D-Bus interface");
+PA_MODULE_USAGE(
+ "access=local|remote|local,remote "
+ "tcp_port=<port number> "
+ "tcp_listen=<hostname>");
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_AUTHOR("Tanu Kaskinen");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+
+enum server_type {
+ SERVER_TYPE_LOCAL,
+ SERVER_TYPE_TCP
+};
+
+struct server;
+struct connection;
+
+struct userdata {
+ pa_module *module;
+ pa_bool_t local_access;
+ pa_bool_t remote_access;
+ uint32_t tcp_port;
+ char *tcp_listen;
+
+ struct server *local_server;
+ struct server *tcp_server;
+
+ pa_idxset *connections;
+
+ pa_defer_event *cleanup_event;
+
+ pa_dbus_protocol *dbus_protocol;
+ pa_dbusiface_core *core_iface;
+};
+
+struct server {
+ struct userdata *userdata;
+ enum server_type type;
+ DBusServer *dbus_server;
+};
+
+struct connection {
+ struct server *server;
+ pa_dbus_wrap_connection *wrap_conn;
+ pa_client *client;
+};
+
+static const char* const valid_modargs[] = {
+ "access",
+ "tcp_port",
+ "tcp_listen",
+ NULL
+};
+
+static void connection_free(struct connection *c) {
+ pa_assert(c);
+
+ pa_assert_se(pa_dbus_protocol_unregister_connection(c->server->userdata->dbus_protocol, pa_dbus_wrap_connection_get(c->wrap_conn)) >= 0);
+
+ pa_client_free(c->client);
+ pa_dbus_wrap_connection_free(c->wrap_conn);
+ pa_xfree(c);
+}
+
+/* Called from pa_client_kill(). */
+static void client_kill_cb(pa_client *c) {
+ struct connection *conn;
+
+ pa_assert(c);
+ pa_assert(c->userdata);
+
+ conn = c->userdata;
+ connection_free(conn);
+ c->userdata = NULL;
+
+ pa_log_info("Connection killed.");
+}
+
+/* Called from pa_client_send_event(). */
+static void client_send_event_cb(pa_client *c, const char *name, pa_proplist *data) {
+ struct connection *conn = NULL;
+ DBusMessage *signal_msg = NULL;
+ DBusMessageIter msg_iter;
+
+ pa_assert(c);
+ pa_assert(name);
+ pa_assert(data);
+ pa_assert(c->userdata);
+
+ conn = c->userdata;
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(pa_dbusiface_core_get_client_path(conn->server->userdata->core_iface, c),
+ PA_DBUSIFACE_CLIENT_INTERFACE,
+ "ClientEvent"));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ pa_assert_se(dbus_message_iter_append_basic(&msg_iter, DBUS_TYPE_STRING, &name));
+ pa_dbus_append_proplist(&msg_iter, data);
+
+ pa_assert_se(dbus_connection_send(pa_dbus_wrap_connection_get(conn->wrap_conn), signal_msg, NULL));
+ dbus_message_unref(signal_msg);
+}
+
+/* Called by D-Bus at the authentication phase. */
+static dbus_bool_t user_check_cb(DBusConnection *connection, unsigned long uid, void *data) {
+ pa_log_debug("Allowing connection by user %lu.", uid);
+
+ return TRUE;
+}
+
+static DBusHandlerResult disconnection_filter_cb(DBusConnection *connection, DBusMessage *message, void *user_data) {
+ struct connection *c = user_data;
+
+ pa_assert(connection);
+ pa_assert(message);
+ pa_assert(c);
+
+ if (dbus_message_is_signal(message, "org.freedesktop.DBus.Local", "Disconnected")) {
+ /* The connection died. Now we want to free the connection object, but
+ * let's wait until this message is fully processed, in case someone
+ * else is interested in this signal too. */
+ c->server->userdata->module->core->mainloop->defer_enable(c->server->userdata->cleanup_event, 1);
+ }
+
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+}
+
+/* Called by D-Bus when a new client connection is received. */
+static void connection_new_cb(DBusServer *dbus_server, DBusConnection *new_connection, void *data) {
+ struct server *s = data;
+ struct connection *c;
+ pa_client_new_data new_data;
+ pa_client *client;
+
+ pa_assert(new_connection);
+ pa_assert(s);
+
+ pa_client_new_data_init(&new_data);
+ new_data.module = s->userdata->module;
+ new_data.driver = __FILE__;
+ pa_proplist_sets(new_data.proplist, PA_PROP_APPLICATION_NAME, "D-Bus client");
+ client = pa_client_new(s->userdata->module->core, &new_data);
+ pa_client_new_data_done(&new_data);
+
+ if (!client) {
+ dbus_connection_close(new_connection);
+ return;
+ }
+
+ if (s->type == SERVER_TYPE_TCP || s->userdata->module->core->server_type == PA_SERVER_TYPE_SYSTEM) {
+ /* FIXME: Here we allow anyone from anywhere to access the server,
+ * anonymously. Access control should be configurable. */
+ dbus_connection_set_unix_user_function(new_connection, user_check_cb, NULL, NULL);
+ dbus_connection_set_allow_anonymous(new_connection, TRUE);
+ }
+
+ c = pa_xnew(struct connection, 1);
+ c->server = s;
+ c->wrap_conn = pa_dbus_wrap_connection_new_from_existing(s->userdata->module->core->mainloop, TRUE, new_connection);
+ c->client = client;
+
+ c->client->kill = client_kill_cb;
+ c->client->send_event = client_send_event_cb;
+ c->client->userdata = c;
+
+ pa_assert_se(dbus_connection_add_filter(new_connection, disconnection_filter_cb, c, NULL));
+
+ pa_idxset_put(s->userdata->connections, c, NULL);
+
+ pa_assert_se(pa_dbus_protocol_register_connection(s->userdata->dbus_protocol, new_connection, c->client) >= 0);
+}
+
+/* Called by PA mainloop when a D-Bus fd watch event needs handling. */
+static void io_event_cb(pa_mainloop_api *mainloop, pa_io_event *e, int fd, pa_io_event_flags_t events, void *userdata) {
+ unsigned int flags = 0;
+ DBusWatch *watch = userdata;
+
+#if HAVE_DBUS_WATCH_GET_UNIX_FD
+ pa_assert(fd == dbus_watch_get_unix_fd(watch));
+#else
+ pa_assert(fd == dbus_watch_get_fd(watch));
+#endif
+
+ if (!dbus_watch_get_enabled(watch)) {
+ pa_log_warn("Asked to handle disabled watch: %p %i", (void*) watch, fd);
+ return;
+ }
+
+ if (events & PA_IO_EVENT_INPUT)
+ flags |= DBUS_WATCH_READABLE;
+ if (events & PA_IO_EVENT_OUTPUT)
+ flags |= DBUS_WATCH_WRITABLE;
+ if (events & PA_IO_EVENT_HANGUP)
+ flags |= DBUS_WATCH_HANGUP;
+ if (events & PA_IO_EVENT_ERROR)
+ flags |= DBUS_WATCH_ERROR;
+
+ dbus_watch_handle(watch, flags);
+}
+
+/* Called by PA mainloop when a D-Bus timer event needs handling. */
+static void time_event_cb(pa_mainloop_api *mainloop, pa_time_event* e, const struct timeval *tv, void *userdata) {
+ DBusTimeout *timeout = userdata;
+
+ if (dbus_timeout_get_enabled(timeout)) {
+ struct timeval next = *tv;
+ dbus_timeout_handle(timeout);
+
+ /* restart it for the next scheduled time */
+ pa_timeval_add(&next, (pa_usec_t) dbus_timeout_get_interval(timeout) * 1000);
+ mainloop->time_restart(e, &next);
+ }
+}
+
+/* Translates D-Bus fd watch event flags to PA IO event flags. */
+static pa_io_event_flags_t get_watch_flags(DBusWatch *watch) {
+ unsigned int flags;
+ pa_io_event_flags_t events = 0;
+
+ pa_assert(watch);
+
+ flags = dbus_watch_get_flags(watch);
+
+ /* no watch flags for disabled watches */
+ if (!dbus_watch_get_enabled(watch))
+ return PA_IO_EVENT_NULL;
+
+ if (flags & DBUS_WATCH_READABLE)
+ events |= PA_IO_EVENT_INPUT;
+ if (flags & DBUS_WATCH_WRITABLE)
+ events |= PA_IO_EVENT_OUTPUT;
+
+ return events | PA_IO_EVENT_HANGUP | PA_IO_EVENT_ERROR;
+}
+
+/* Called by D-Bus when a D-Bus fd watch event is added. */
+static dbus_bool_t watch_add_cb(DBusWatch *watch, void *data) {
+ struct server *s = data;
+ pa_mainloop_api *mainloop;
+ pa_io_event *ev;
+
+ pa_assert(watch);
+ pa_assert(s);
+
+ mainloop = s->userdata->module->core->mainloop;
+
+ ev = mainloop->io_new(
+ mainloop,
+#if HAVE_DBUS_WATCH_GET_UNIX_FD
+ dbus_watch_get_unix_fd(watch),
+#else
+ dbus_watch_get_fd(watch),
+#endif
+ get_watch_flags(watch), io_event_cb, watch);
+
+ dbus_watch_set_data(watch, ev, NULL);
+
+ return TRUE;
+}
+
+/* Called by D-Bus when a D-Bus fd watch event is removed. */
+static void watch_remove_cb(DBusWatch *watch, void *data) {
+ struct server *s = data;
+ pa_io_event *ev;
+
+ pa_assert(watch);
+ pa_assert(s);
+
+ if ((ev = dbus_watch_get_data(watch)))
+ s->userdata->module->core->mainloop->io_free(ev);
+}
+
+/* Called by D-Bus when a D-Bus fd watch event is toggled. */
+static void watch_toggled_cb(DBusWatch *watch, void *data) {
+ struct server *s = data;
+ pa_io_event *ev;
+
+ pa_assert(watch);
+ pa_assert(s);
+
+ pa_assert_se(ev = dbus_watch_get_data(watch));
+
+ /* get_watch_flags() checks if the watch is enabled */
+ s->userdata->module->core->mainloop->io_enable(ev, get_watch_flags(watch));
+}
+
+/* Called by D-Bus when a D-Bus timer event is added. */
+static dbus_bool_t timeout_add_cb(DBusTimeout *timeout, void *data) {
+ struct server *s = data;
+ pa_mainloop_api *mainloop;
+ pa_time_event *ev;
+ struct timeval tv;
+
+ pa_assert(timeout);
+ pa_assert(s);
+
+ if (!dbus_timeout_get_enabled(timeout))
+ return FALSE;
+
+ mainloop = s->userdata->module->core->mainloop;
+
+ pa_gettimeofday(&tv);
+ pa_timeval_add(&tv, (pa_usec_t) dbus_timeout_get_interval(timeout) * 1000);
+
+ ev = mainloop->time_new(mainloop, &tv, time_event_cb, timeout);
+
+ dbus_timeout_set_data(timeout, ev, NULL);
+
+ return TRUE;
+}
+
+/* Called by D-Bus when a D-Bus timer event is removed. */
+static void timeout_remove_cb(DBusTimeout *timeout, void *data) {
+ struct server *s = data;
+ pa_time_event *ev;
+
+ pa_assert(timeout);
+ pa_assert(s);
+
+ if ((ev = dbus_timeout_get_data(timeout)))
+ s->userdata->module->core->mainloop->time_free(ev);
+}
+
+/* Called by D-Bus when a D-Bus timer event is toggled. */
+static void timeout_toggled_cb(DBusTimeout *timeout, void *data) {
+ struct server *s = data;
+ pa_mainloop_api *mainloop;
+ pa_time_event *ev;
+
+ pa_assert(timeout);
+ pa_assert(s);
+
+ mainloop = s->userdata->module->core->mainloop;
+
+ pa_assert_se(ev = dbus_timeout_get_data(timeout));
+
+ if (dbus_timeout_get_enabled(timeout)) {
+ struct timeval tv;
+
+ pa_gettimeofday(&tv);
+ pa_timeval_add(&tv, (pa_usec_t) dbus_timeout_get_interval(timeout) * 1000);
+
+ mainloop->time_restart(ev, &tv);
+ } else
+ mainloop->time_restart(ev, NULL);
+}
+
+static void server_free(struct server *s) {
+ pa_assert(s);
+
+ if (s->dbus_server) {
+ dbus_server_disconnect(s->dbus_server);
+ dbus_server_unref(s->dbus_server);
+ }
+
+ pa_xfree(s);
+}
+
+static struct server *start_server(struct userdata *u, const char *address, enum server_type type) {
+ /* XXX: We assume that when we unref the DBusServer instance at module
+ * shutdown, nobody else holds any references to it. If we stop assuming
+ * that someday, dbus_server_set_new_connection_function,
+ * dbus_server_set_watch_functions and dbus_server_set_timeout_functions
+ * calls should probably register free callbacks, instead of providing NULL
+ * as they do now. */
+
+ struct server *s = NULL;
+ DBusError error;
+
+ pa_assert(u);
+ pa_assert(address);
+
+ dbus_error_init(&error);
+
+ s = pa_xnew0(struct server, 1);
+ s->userdata = u;
+ s->type = type;
+ s->dbus_server = dbus_server_listen(address, &error);
+
+ if (dbus_error_is_set(&error)) {
+ pa_log("dbus_server_listen() failed: %s: %s", error.name, error.message);
+ goto fail;
+ }
+
+ dbus_server_set_new_connection_function(s->dbus_server, connection_new_cb, s, NULL);
+
+ if (!dbus_server_set_watch_functions(s->dbus_server, watch_add_cb, watch_remove_cb, watch_toggled_cb, s, NULL)) {
+ pa_log("dbus_server_set_watch_functions() ran out of memory.");
+ goto fail;
+ }
+
+ if (!dbus_server_set_timeout_functions(s->dbus_server, timeout_add_cb, timeout_remove_cb, timeout_toggled_cb, s, NULL)) {
+ pa_log("dbus_server_set_timeout_functions() ran out of memory.");
+ goto fail;
+ }
+
+ return s;
+
+fail:
+ if (s)
+ server_free(s);
+
+ dbus_error_free(&error);
+
+ return NULL;
+}
+
+static struct server *start_local_server(struct userdata *u) {
+ struct server *s = NULL;
+ char *address = NULL;
+
+ pa_assert(u);
+
+ address = pa_get_dbus_address_from_server_type(u->module->core->server_type);
+
+ s = start_server(u, address, SERVER_TYPE_LOCAL); /* May return NULL */
+
+ pa_xfree(address);
+
+ return s;
+}
+
+static struct server *start_tcp_server(struct userdata *u) {
+ struct server *s = NULL;
+ char *address = NULL;
+
+ pa_assert(u);
+
+ address = pa_sprintf_malloc("tcp:host=%s,port=%u", u->tcp_listen, u->tcp_port);
+
+ s = start_server(u, address, SERVER_TYPE_TCP); /* May return NULL */
+
+ pa_xfree(address);
+
+ return s;
+}
+
+static int get_access_arg(pa_modargs *ma, pa_bool_t *local_access, pa_bool_t *remote_access) {
+ const char *value = NULL;
+
+ pa_assert(ma);
+ pa_assert(local_access);
+ pa_assert(remote_access);
+
+ if (!(value = pa_modargs_get_value(ma, "access", NULL)))
+ return 0;
+
+ if (!strcmp(value, "local")) {
+ *local_access = TRUE;
+ *remote_access = FALSE;
+ } else if (!strcmp(value, "remote")) {
+ *local_access = FALSE;
+ *remote_access = TRUE;
+ } else if (!strcmp(value, "local,remote")) {
+ *local_access = TRUE;
+ *remote_access = TRUE;
+ } else
+ return -1;
+
+ return 0;
+}
+
+/* Frees dead client connections. */
+static void cleanup_cb(pa_mainloop_api *a, pa_defer_event *e, void *userdata) {
+ struct userdata *u = userdata;
+ struct connection *conn = NULL;
+ uint32_t idx;
+
+ PA_IDXSET_FOREACH(conn, u->connections, idx) {
+ if (!dbus_connection_get_is_connected(pa_dbus_wrap_connection_get(conn->wrap_conn))) {
+ pa_idxset_remove_by_data(u->connections, conn, NULL);
+ connection_free(conn);
+ }
+ }
+
+ u->module->core->mainloop->defer_enable(e, 0);
+}
+
+int pa__init(pa_module *m) {
+ struct userdata *u = NULL;
+ pa_modargs *ma = NULL;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->module = m;
+ u->local_access = TRUE;
+ u->remote_access = FALSE;
+ u->tcp_port = PA_DBUS_DEFAULT_PORT;
+
+ if (get_access_arg(ma, &u->local_access, &u->remote_access) < 0) {
+ pa_log("Invalid access argument: '%s'", pa_modargs_get_value(ma, "access", NULL));
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_u32(ma, "tcp_port", &u->tcp_port) < 0 || u->tcp_port < 1 || u->tcp_port > 49150) {
+ pa_log("Invalid tcp_port argument: '%s'", pa_modargs_get_value(ma, "tcp_port", NULL));
+ goto fail;
+ }
+
+ u->tcp_listen = pa_xstrdup(pa_modargs_get_value(ma, "tcp_listen", "0.0.0.0"));
+
+ if (u->local_access && !(u->local_server = start_local_server(u))) {
+ pa_log("Starting the local D-Bus server failed.");
+ goto fail;
+ }
+
+ if (u->remote_access && !(u->tcp_server = start_tcp_server(u))) {
+ pa_log("Starting the D-Bus server for remote connections failed.");
+ goto fail;
+ }
+
+ u->connections = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+
+ u->cleanup_event = m->core->mainloop->defer_new(m->core->mainloop, cleanup_cb, u);
+ m->core->mainloop->defer_enable(u->cleanup_event, 0);
+
+ u->dbus_protocol = pa_dbus_protocol_get(m->core);
+ u->core_iface = pa_dbusiface_core_new(m->core);
+
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+void pa__done(pa_module *m) {
+ struct userdata *u;
+ struct connection *c;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->core_iface)
+ pa_dbusiface_core_free(u->core_iface);
+
+ while ((c = pa_idxset_steal_first(u->connections, NULL)))
+ connection_free(c);
+
+ pa_idxset_free(u->connections, NULL, NULL);
+
+ /* This must not be called before the connections are freed, because if
+ * there are any connections left, they will emit the
+ * org.freedesktop.DBus.Local.Disconnected signal, and
+ * disconnection_filter_cb() will be called. disconnection_filter_cb() then
+ * tries to enable the defer event, and if it's already freed, an assertion
+ * will be hit in mainloop.c. */
+ if (u->cleanup_event)
+ m->core->mainloop->defer_free(u->cleanup_event);
+
+ if (u->tcp_server)
+ server_free(u->tcp_server);
+
+ if (u->local_server)
+ server_free(u->local_server);
+
+ if (u->dbus_protocol)
+ pa_dbus_protocol_unref(u->dbus_protocol);
+
+ pa_xfree(u->tcp_listen);
+ pa_xfree(u);
+ m->userdata = NULL;
+}
diff --git a/src/modules/echo-cancel/adrian-aec.c b/src/modules/echo-cancel/adrian-aec.c
new file mode 100644
index 00000000..e969e8c5
--- /dev/null
+++ b/src/modules/echo-cancel/adrian-aec.c
@@ -0,0 +1,275 @@
+/* aec.cpp
+ *
+ * Copyright (C) DFS Deutsche Flugsicherung (2004, 2005).
+ * All Rights Reserved.
+ *
+ * Acoustic Echo Cancellation NLMS-pw algorithm
+ *
+ * Version 0.3 filter created with www.dsptutor.freeuk.com
+ * Version 0.3.1 Allow change of stability parameter delta
+ * Version 0.4 Leaky Normalized LMS - pre whitening algorithm
+ */
+
+#include <math.h>
+#include <string.h>
+#include <stdint.h>
+
+#include <pulse/xmalloc.h>
+
+#include "adrian-aec.h"
+
+#ifndef DISABLE_ORC
+#include "adrian-aec-orc-gen.h"
+#endif
+
+#ifdef __SSE__
+#include <xmmintrin.h>
+#endif
+
+/* Vector Dot Product */
+static REAL dotp(REAL a[], REAL b[])
+{
+ REAL sum0 = 0.0, sum1 = 0.0;
+ int j;
+
+ for (j = 0; j < NLMS_LEN; j += 2) {
+ // optimize: partial loop unrolling
+ sum0 += a[j] * b[j];
+ sum1 += a[j + 1] * b[j + 1];
+ }
+ return sum0 + sum1;
+}
+
+static REAL dotp_sse(REAL a[], REAL b[])
+{
+#ifdef __SSE__
+ /* This is taken from speex's inner product implementation */
+ int j;
+ REAL sum;
+ __m128 acc = _mm_setzero_ps();
+
+ for (j=0;j<NLMS_LEN;j+=8)
+ {
+ acc = _mm_add_ps(acc, _mm_mul_ps(_mm_load_ps(a+j), _mm_loadu_ps(b+j)));
+ acc = _mm_add_ps(acc, _mm_mul_ps(_mm_load_ps(a+j+4), _mm_loadu_ps(b+j+4)));
+ }
+ acc = _mm_add_ps(acc, _mm_movehl_ps(acc, acc));
+ acc = _mm_add_ss(acc, _mm_shuffle_ps(acc, acc, 0x55));
+ _mm_store_ss(&sum, acc);
+
+ return sum;
+#else
+ return dotp(a, b);
+#endif
+}
+
+
+AEC* AEC_init(int RATE, int have_vector)
+{
+ AEC *a = pa_xnew(AEC, 1);
+ a->hangover = 0;
+ memset(a->x, 0, sizeof(a->x));
+ memset(a->xf, 0, sizeof(a->xf));
+ memset(a->w_arr, 0, sizeof(a->w_arr));
+ a->j = NLMS_EXT;
+ a->delta = 0.0f;
+ AEC_setambient(a, NoiseFloor);
+ a->dfast = a->dslow = M75dB_PCM;
+ a->xfast = a->xslow = M80dB_PCM;
+ a->gain = 1.0f;
+ a->Fx = IIR1_init(2000.0f/RATE);
+ a->Fe = IIR1_init(2000.0f/RATE);
+ a->cutoff = FIR_HP_300Hz_init();
+ a->acMic = IIR_HP_init();
+ a->acSpk = IIR_HP_init();
+
+ a->aes_y2 = M0dB;
+
+ a->fdwdisplay = -1;
+ a->dumpcnt = 0;
+ memset(a->ws, 0, sizeof(a->ws));
+
+ if (have_vector) {
+ /* Get a 16-byte aligned location */
+ a->w = (REAL *) (((uintptr_t) a->w_arr) + (((uintptr_t) a->w_arr) % 16));
+ a->dotp = dotp_sse;
+ } else {
+ /* We don't care about alignment, just use the array as-is */
+ a->w = a->w_arr;
+ a->dotp = dotp;
+ }
+
+ return a;
+}
+
+// Adrian soft decision DTD
+// (Dual Average Near-End to Far-End signal Ratio DTD)
+// This algorithm uses exponential smoothing with differnt
+// ageing parameters to get fast and slow near-end and far-end
+// signal averages. The ratio of NFRs term
+// (dfast / xfast) / (dslow / xslow) is used to compute the stepsize
+// A ratio value of 2.5 is mapped to stepsize 0, a ratio of 0 is
+// mapped to 1.0 with a limited linear function.
+static float AEC_dtd(AEC *a, REAL d, REAL x)
+{
+ float ratio, stepsize;
+
+ // fast near-end and far-end average
+ a->dfast += ALPHAFAST * (fabsf(d) - a->dfast);
+ a->xfast += ALPHAFAST * (fabsf(x) - a->xfast);
+
+ // slow near-end and far-end average
+ a->dslow += ALPHASLOW * (fabsf(d) - a->dslow);
+ a->xslow += ALPHASLOW * (fabsf(x) - a->xslow);
+
+ if (a->xfast < M70dB_PCM) {
+ return 0.0; // no Spk signal
+ }
+
+ if (a->dfast < M70dB_PCM) {
+ return 0.0; // no Mic signal
+ }
+
+ // ratio of NFRs
+ ratio = (a->dfast * a->xslow) / (a->dslow * a->xfast);
+
+ // Linear interpolation with clamping at the limits
+ if (ratio < STEPX1)
+ stepsize = STEPY1;
+ else if (ratio > STEPX2)
+ stepsize = STEPY2;
+ else
+ stepsize = STEPY1 + (STEPY2 - STEPY1) * (ratio - STEPX1) / (STEPX2 - STEPX1);
+
+ return stepsize;
+}
+
+
+static void AEC_leaky(AEC *a)
+// The xfast signal is used to charge the hangover timer to Thold.
+// When hangover expires (no Spk signal for some time) the vector w
+// is erased. This is my implementation of Leaky NLMS.
+{
+ if (a->xfast >= M70dB_PCM) {
+ // vector w is valid for hangover Thold time
+ a->hangover = Thold;
+ } else {
+ if (a->hangover > 1) {
+ --(a->hangover);
+ } else if (1 == a->hangover) {
+ --(a->hangover);
+ // My Leaky NLMS is to erase vector w when hangover expires
+ memset(a->w, 0, sizeof(a->w));
+ }
+ }
+}
+
+
+#if 0
+void AEC::openwdisplay() {
+ // open TCP connection to program wdisplay.tcl
+ fdwdisplay = socket_async("127.0.0.1", 50999);
+};
+#endif
+
+
+static REAL AEC_nlms_pw(AEC *a, REAL d, REAL x_, float stepsize)
+{
+ REAL e;
+ REAL ef;
+ a->x[a->j] = x_;
+ a->xf[a->j] = IIR1_highpass(a->Fx, x_); // pre-whitening of x
+
+ // calculate error value
+ // (mic signal - estimated mic signal from spk signal)
+ e = d;
+ if (a->hangover > 0) {
+ e -= a->dotp(a->w, a->x + a->j);
+ }
+ ef = IIR1_highpass(a->Fe, e); // pre-whitening of e
+
+ // optimize: iterative dotp(xf, xf)
+ a->dotp_xf_xf += (a->xf[a->j] * a->xf[a->j] - a->xf[a->j + NLMS_LEN - 1] * a->xf[a->j + NLMS_LEN - 1]);
+
+ if (stepsize > 0.0) {
+ // calculate variable step size
+ REAL mikro_ef = stepsize * ef / a->dotp_xf_xf;
+
+#ifdef DISABLE_ORC
+ // update tap weights (filter learning)
+ int i;
+ for (i = 0; i < NLMS_LEN; i += 2) {
+ // optimize: partial loop unrolling
+ a->w[i] += mikro_ef * a->xf[i + a->j];
+ a->w[i + 1] += mikro_ef * a->xf[i + a->j + 1];
+ }
+#else
+ update_tap_weights(a->w, &a->xf[a->j], mikro_ef, NLMS_LEN);
+#endif
+ }
+
+ if (--(a->j) < 0) {
+ // optimize: decrease number of memory copies
+ a->j = NLMS_EXT;
+ memmove(a->x + a->j + 1, a->x, (NLMS_LEN - 1) * sizeof(REAL));
+ memmove(a->xf + a->j + 1, a->xf, (NLMS_LEN - 1) * sizeof(REAL));
+ }
+
+ // Saturation
+ if (e > MAXPCM) {
+ return MAXPCM;
+ } else if (e < -MAXPCM) {
+ return -MAXPCM;
+ } else {
+ return e;
+ }
+}
+
+
+int AEC_doAEC(AEC *a, int d_, int x_)
+{
+ REAL d = (REAL) d_;
+ REAL x = (REAL) x_;
+
+ // Mic Highpass Filter - to remove DC
+ d = IIR_HP_highpass(a->acMic, d);
+
+ // Mic Highpass Filter - cut-off below 300Hz
+ d = FIR_HP_300Hz_highpass(a->cutoff, d);
+
+ // Amplify, for e.g. Soundcards with -6dB max. volume
+ d *= a->gain;
+
+ // Spk Highpass Filter - to remove DC
+ x = IIR_HP_highpass(a->acSpk, x);
+
+ // Double Talk Detector
+ a->stepsize = AEC_dtd(a, d, x);
+
+ // Leaky (ageing of vector w)
+ AEC_leaky(a);
+
+ // Acoustic Echo Cancellation
+ d = AEC_nlms_pw(a, d, x, a->stepsize);
+
+#if 0
+ if (fdwdisplay >= 0) {
+ if (++dumpcnt >= (WIDEB*RATE/10)) {
+ // wdisplay creates 10 dumps per seconds = large CPU load!
+ dumpcnt = 0;
+ write(fdwdisplay, ws, DUMP_LEN*sizeof(float));
+ // we don't check return value. This is not production quality!!!
+ memset(ws, 0, sizeof(ws));
+ } else {
+ int i;
+ for (i = 0; i < DUMP_LEN; i += 2) {
+ // optimize: partial loop unrolling
+ ws[i] += w[i];
+ ws[i + 1] += w[i + 1];
+ }
+ }
+ }
+#endif
+
+ return (int) d;
+}
diff --git a/src/modules/echo-cancel/adrian-aec.h b/src/modules/echo-cancel/adrian-aec.h
new file mode 100644
index 00000000..d024b3c5
--- /dev/null
+++ b/src/modules/echo-cancel/adrian-aec.h
@@ -0,0 +1,382 @@
+/* aec.h
+ *
+ * Copyright (C) DFS Deutsche Flugsicherung (2004, 2005).
+ * All Rights Reserved.
+ * Author: Andre Adrian
+ *
+ * Acoustic Echo Cancellation Leaky NLMS-pw algorithm
+ *
+ * Version 0.3 filter created with www.dsptutor.freeuk.com
+ * Version 0.3.1 Allow change of stability parameter delta
+ * Version 0.4 Leaky Normalized LMS - pre whitening algorithm
+ */
+
+#ifndef _AEC_H /* include only once */
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/gccmacro.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/macro.h>
+
+#define WIDEB 2
+
+// use double if your CPU does software-emulation of float
+#define REAL float
+
+/* dB Values */
+#define M0dB 1.0f
+#define M3dB 0.71f
+#define M6dB 0.50f
+#define M9dB 0.35f
+#define M12dB 0.25f
+#define M18dB 0.125f
+#define M24dB 0.063f
+
+/* dB values for 16bit PCM */
+/* MxdB_PCM = 32767 * 10 ^(x / 20) */
+#define M10dB_PCM 10362.0f
+#define M20dB_PCM 3277.0f
+#define M25dB_PCM 1843.0f
+#define M30dB_PCM 1026.0f
+#define M35dB_PCM 583.0f
+#define M40dB_PCM 328.0f
+#define M45dB_PCM 184.0f
+#define M50dB_PCM 104.0f
+#define M55dB_PCM 58.0f
+#define M60dB_PCM 33.0f
+#define M65dB_PCM 18.0f
+#define M70dB_PCM 10.0f
+#define M75dB_PCM 6.0f
+#define M80dB_PCM 3.0f
+#define M85dB_PCM 2.0f
+#define M90dB_PCM 1.0f
+
+#define MAXPCM 32767.0f
+
+/* Design constants (Change to fine tune the algorithms */
+
+/* The following values are for hardware AEC and studio quality
+ * microphone */
+
+/* NLMS filter length in taps (samples). A longer filter length gives
+ * better Echo Cancellation, but maybe slower convergence speed and
+ * needs more CPU power (Order of NLMS is linear) */
+#define NLMS_LEN (100*WIDEB*8)
+
+/* Vector w visualization length in taps (samples).
+ * Must match argv value for wdisplay.tcl */
+#define DUMP_LEN (40*WIDEB*8)
+
+/* minimum energy in xf. Range: M70dB_PCM to M50dB_PCM. Should be equal
+ * to microphone ambient Noise level */
+#define NoiseFloor M55dB_PCM
+
+/* Leaky hangover in taps.
+ */
+#define Thold (60 * WIDEB * 8)
+
+// Adrian soft decision DTD
+// left point. X is ratio, Y is stepsize
+#define STEPX1 1.0
+#define STEPY1 1.0
+// right point. STEPX2=2.0 is good double talk, 3.0 is good single talk.
+#define STEPX2 2.5
+#define STEPY2 0
+#define ALPHAFAST (1.0f / 100.0f)
+#define ALPHASLOW (1.0f / 20000.0f)
+
+
+
+/* Ageing multiplier for LMS memory vector w */
+#define Leaky 0.9999f
+
+/* Double Talk Detector Speaker/Microphone Threshold. Range <=1
+ * Large value (M0dB) is good for Single-Talk Echo cancellation,
+ * small value (M12dB) is good for Doulbe-Talk AEC */
+#define GeigelThreshold M6dB
+
+/* for Non Linear Processor. Range >0 to 1. Large value (M0dB) is good
+ * for Double-Talk, small value (M12dB) is good for Single-Talk */
+#define NLPAttenuation M12dB
+
+/* Below this line there are no more design constants */
+
+typedef struct IIR_HP IIR_HP;
+
+/* Exponential Smoothing or IIR Infinite Impulse Response Filter */
+struct IIR_HP {
+ REAL x;
+};
+
+static IIR_HP* IIR_HP_init(void) {
+ IIR_HP *i = pa_xnew(IIR_HP, 1);
+ i->x = 0.0f;
+ return i;
+ }
+
+static REAL IIR_HP_highpass(IIR_HP *i, REAL in) {
+ const REAL a0 = 0.01f; /* controls Transfer Frequency */
+ /* Highpass = Signal - Lowpass. Lowpass = Exponential Smoothing */
+ i->x += a0 * (in - i->x);
+ return in - i->x;
+ };
+
+typedef struct FIR_HP_300Hz FIR_HP_300Hz;
+
+#if WIDEB==1
+/* 17 taps FIR Finite Impulse Response filter
+ * Coefficients calculated with
+ * www.dsptutor.freeuk.com/KaiserFilterDesign/KaiserFilterDesign.html
+ */
+class FIR_HP_300Hz {
+ REAL z[18];
+
+public:
+ FIR_HP_300Hz() {
+ memset(this, 0, sizeof(FIR_HP_300Hz));
+ }
+
+ REAL highpass(REAL in) {
+ const REAL a[18] = {
+ // Kaiser Window FIR Filter, Filter type: High pass
+ // Passband: 300.0 - 4000.0 Hz, Order: 16
+ // Transition band: 75.0 Hz, Stopband attenuation: 10.0 dB
+ -0.034870606, -0.039650206, -0.044063766, -0.04800318,
+ -0.051370874, -0.054082647, -0.056070227, -0.057283327,
+ 0.8214126, -0.057283327, -0.056070227, -0.054082647,
+ -0.051370874, -0.04800318, -0.044063766, -0.039650206,
+ -0.034870606, 0.0
+ };
+ memmove(z + 1, z, 17 * sizeof(REAL));
+ z[0] = in;
+ REAL sum0 = 0.0, sum1 = 0.0;
+ int j;
+
+ for (j = 0; j < 18; j += 2) {
+ // optimize: partial loop unrolling
+ sum0 += a[j] * z[j];
+ sum1 += a[j + 1] * z[j + 1];
+ }
+ return sum0 + sum1;
+ }
+};
+
+#else
+
+/* 35 taps FIR Finite Impulse Response filter
+ * Passband 150Hz to 4kHz for 8kHz sample rate, 300Hz to 8kHz for 16kHz
+ * sample rate.
+ * Coefficients calculated with
+ * www.dsptutor.freeuk.com/KaiserFilterDesign/KaiserFilterDesign.html
+ */
+struct FIR_HP_300Hz {
+ REAL z[36];
+};
+
+static FIR_HP_300Hz* FIR_HP_300Hz_init(void) {
+ FIR_HP_300Hz *ret = pa_xnew(FIR_HP_300Hz, 1);
+ memset(ret, 0, sizeof(FIR_HP_300Hz));
+ return ret;
+ }
+
+static REAL FIR_HP_300Hz_highpass(FIR_HP_300Hz *f, REAL in) {
+ REAL sum0 = 0.0, sum1 = 0.0;
+ int j;
+ const REAL a[36] = {
+ // Kaiser Window FIR Filter, Filter type: High pass
+ // Passband: 150.0 - 4000.0 Hz, Order: 34
+ // Transition band: 34.0 Hz, Stopband attenuation: 10.0 dB
+ -0.016165324, -0.017454365, -0.01871232, -0.019931411,
+ -0.021104068, -0.022222936, -0.02328091, -0.024271343,
+ -0.025187887, -0.02602462, -0.026776174, -0.027437767,
+ -0.028004972, -0.028474221, -0.028842418, -0.029107114,
+ -0.02926664, 0.8524841, -0.02926664, -0.029107114,
+ -0.028842418, -0.028474221, -0.028004972, -0.027437767,
+ -0.026776174, -0.02602462, -0.025187887, -0.024271343,
+ -0.02328091, -0.022222936, -0.021104068, -0.019931411,
+ -0.01871232, -0.017454365, -0.016165324, 0.0
+ };
+ memmove(f->z + 1, f->z, 35 * sizeof(REAL));
+ f->z[0] = in;
+
+ for (j = 0; j < 36; j += 2) {
+ // optimize: partial loop unrolling
+ sum0 += a[j] * f->z[j];
+ sum1 += a[j + 1] * f->z[j + 1];
+ }
+ return sum0 + sum1;
+ }
+#endif
+
+typedef struct IIR1 IIR1;
+
+/* Recursive single pole IIR Infinite Impulse response High-pass filter
+ *
+ * Reference: The Scientist and Engineer's Guide to Digital Processing
+ *
+ * output[N] = A0 * input[N] + A1 * input[N-1] + B1 * output[N-1]
+ *
+ * X = exp(-2.0 * pi * Fc)
+ * A0 = (1 + X) / 2
+ * A1 = -(1 + X) / 2
+ * B1 = X
+ * Fc = cutoff freq / sample rate
+ */
+struct IIR1 {
+ REAL in0, out0;
+ REAL a0, a1, b1;
+};
+
+#if 0
+ IIR1() {
+ memset(this, 0, sizeof(IIR1));
+ }
+#endif
+
+static IIR1* IIR1_init(REAL Fc) {
+ IIR1 *i = pa_xnew(IIR1, 1);
+ i->b1 = expf(-2.0f * M_PI * Fc);
+ i->a0 = (1.0f + i->b1) / 2.0f;
+ i->a1 = -(i->a0);
+ i->in0 = 0.0f;
+ i->out0 = 0.0f;
+ return i;
+ }
+
+static REAL IIR1_highpass(IIR1 *i, REAL in) {
+ REAL out = i->a0 * in + i->a1 * i->in0 + i->b1 * i->out0;
+ i->in0 = in;
+ i->out0 = out;
+ return out;
+ }
+
+
+#if 0
+/* Recursive two pole IIR Infinite Impulse Response filter
+ * Coefficients calculated with
+ * http://www.dsptutor.freeuk.com/IIRFilterDesign/IIRFiltDes102.html
+ */
+class IIR2 {
+ REAL x[2], y[2];
+
+public:
+ IIR2() {
+ memset(this, 0, sizeof(IIR2));
+ }
+
+ REAL highpass(REAL in) {
+ // Butterworth IIR filter, Filter type: HP
+ // Passband: 2000 - 4000.0 Hz, Order: 2
+ const REAL a[] = { 0.29289323f, -0.58578646f, 0.29289323f };
+ const REAL b[] = { 1.3007072E-16f, 0.17157288f };
+ REAL out =
+ a[0] * in + a[1] * x[0] + a[2] * x[1] - b[0] * y[0] - b[1] * y[1];
+
+ x[1] = x[0];
+ x[0] = in;
+ y[1] = y[0];
+ y[0] = out;
+ return out;
+ }
+};
+#endif
+
+
+// Extention in taps to reduce mem copies
+#define NLMS_EXT (10*8)
+
+// block size in taps to optimize DTD calculation
+#define DTD_LEN 16
+
+typedef struct AEC AEC;
+
+struct AEC {
+ // Time domain Filters
+ IIR_HP *acMic, *acSpk; // DC-level remove Highpass)
+ FIR_HP_300Hz *cutoff; // 150Hz cut-off Highpass
+ REAL gain; // Mic signal amplify
+ IIR1 *Fx, *Fe; // pre-whitening Highpass for x, e
+
+ // Adrian soft decision DTD (Double Talk Detector)
+ REAL dfast, xfast;
+ REAL dslow, xslow;
+
+ // NLMS-pw
+ REAL x[NLMS_LEN + NLMS_EXT]; // tap delayed loudspeaker signal
+ REAL xf[NLMS_LEN + NLMS_EXT]; // pre-whitening tap delayed signal
+ REAL w_arr[NLMS_LEN + (16 / sizeof(REAL))]; // tap weights
+ REAL *w; // this will be a 16-byte aligned pointer into w_arr
+ int j; // optimize: less memory copies
+ double dotp_xf_xf; // double to avoid loss of precision
+ float delta; // noise floor to stabilize NLMS
+
+ // AES
+ float aes_y2; // not in use!
+
+ // w vector visualization
+ REAL ws[DUMP_LEN]; // tap weights sums
+ int fdwdisplay; // TCP file descriptor
+ int dumpcnt; // wdisplay output counter
+
+ // variables are public for visualization
+ int hangover;
+ float stepsize;
+
+ // vfuncs that are picked based on processor features available
+ REAL (*dotp) (REAL[], REAL[]);
+};
+
+/* Double-Talk Detector
+ *
+ * in d: microphone sample (PCM as REALing point value)
+ * in x: loudspeaker sample (PCM as REALing point value)
+ * return: from 0 for doubletalk to 1.0 for single talk
+ */
+static float AEC_dtd(AEC *a, REAL d, REAL x);
+
+static void AEC_leaky(AEC *a);
+
+/* Normalized Least Mean Square Algorithm pre-whitening (NLMS-pw)
+ * The LMS algorithm was developed by Bernard Widrow
+ * book: Haykin, Adaptive Filter Theory, 4. edition, Prentice Hall, 2002
+ *
+ * in d: microphone sample (16bit PCM value)
+ * in x_: loudspeaker sample (16bit PCM value)
+ * in stepsize: NLMS adaptation variable
+ * return: echo cancelled microphone sample
+ */
+static REAL AEC_nlms_pw(AEC *a, REAL d, REAL x_, float stepsize);
+
+ AEC* AEC_init(int RATE, int have_vector);
+
+/* Acoustic Echo Cancellation and Suppression of one sample
+ * in d: microphone signal with echo
+ * in x: loudspeaker signal
+ * return: echo cancelled microphone signal
+ */
+ int AEC_doAEC(AEC *a, int d_, int x_);
+
+PA_GCC_UNUSED static float AEC_getambient(AEC *a) {
+ return a->dfast;
+ };
+static void AEC_setambient(AEC *a, float Min_xf) {
+ a->dotp_xf_xf -= a->delta; // subtract old delta
+ a->delta = (NLMS_LEN-1) * Min_xf * Min_xf;
+ a->dotp_xf_xf += a->delta; // add new delta
+ };
+PA_GCC_UNUSED static void AEC_setgain(AEC *a, float gain_) {
+ a->gain = gain_;
+ };
+#if 0
+ void AEC_openwdisplay(AEC *a);
+#endif
+PA_GCC_UNUSED static void AEC_setaes(AEC *a, float aes_y2_) {
+ a->aes_y2 = aes_y2_;
+ };
+
+#define _AEC_H
+#endif
diff --git a/src/modules/echo-cancel/adrian-aec.orc b/src/modules/echo-cancel/adrian-aec.orc
new file mode 100644
index 00000000..80547723
--- /dev/null
+++ b/src/modules/echo-cancel/adrian-aec.orc
@@ -0,0 +1,8 @@
+.function update_tap_weights
+.dest 4 w float
+.source 4 xf float
+.floatparam 4 mikro_ef
+.temp 4 tmp float
+
+mulf tmp, mikro_ef, xf
+addf w, w, tmp
diff --git a/src/modules/echo-cancel/adrian-license.txt b/src/modules/echo-cancel/adrian-license.txt
new file mode 100644
index 00000000..7c06efd0
--- /dev/null
+++ b/src/modules/echo-cancel/adrian-license.txt
@@ -0,0 +1,17 @@
+ Copyright (C) DFS Deutsche Flugsicherung (2004). All Rights Reserved.
+
+ You are allowed to use this source code in any open source or closed
+ source software you want. You are allowed to use the algorithms for a
+ hardware solution. You are allowed to modify the source code.
+ You are not allowed to remove the name of the author from this memo or
+ from the source code files. You are not allowed to monopolize the
+ source code or the algorithms behind the source code as your
+ intellectual property. This source code is free of royalty and comes
+ with no warranty.
+
+--- The following does not apply to the PulseAudio module ---
+
+ Please see g711/gen-lic.txt for the ITU-T G.711 codec copyright.
+ Please see gsm/gen-lic.txt for the ITU-T GSM codec copyright.
+ Please see ilbc/COPYRIGHT and ilbc/NOTICE for the IETF iLBC codec
+ copyright.
diff --git a/src/modules/echo-cancel/adrian.c b/src/modules/echo-cancel/adrian.c
new file mode 100644
index 00000000..ab3858a4
--- /dev/null
+++ b/src/modules/echo-cancel/adrian.c
@@ -0,0 +1,117 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ Contributor: Wim Taymans <wim.taymans@gmail.com>
+
+ The actual implementation is taken from the sources at
+ http://andreadrian.de/intercom/ - for the license, look for
+ adrian-license.txt in the same directory as this file.
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/modargs.h>
+
+#include "echo-cancel.h"
+
+/* should be between 10-20 ms */
+#define DEFAULT_FRAME_SIZE_MS 20
+
+static const char* const valid_modargs[] = {
+ "frame_size_ms",
+ NULL
+};
+
+static void pa_adrian_ec_fixate_spec(pa_sample_spec *source_ss, pa_channel_map *source_map,
+ pa_sample_spec *sink_ss, pa_channel_map *sink_map)
+{
+ source_ss->format = PA_SAMPLE_S16NE;
+ source_ss->channels = 1;
+ pa_channel_map_init_mono(source_map);
+
+ *sink_ss = *source_ss;
+ *sink_map = *source_map;
+}
+
+pa_bool_t pa_adrian_ec_init(pa_core *c, pa_echo_canceller *ec,
+ pa_sample_spec *source_ss, pa_channel_map *source_map,
+ pa_sample_spec *sink_ss, pa_channel_map *sink_map,
+ uint32_t *blocksize, const char *args)
+{
+ int framelen, rate, have_vector = 0;
+ uint32_t frame_size_ms;
+ pa_modargs *ma;
+
+ if (!(ma = pa_modargs_new(args, valid_modargs))) {
+ pa_log("Failed to parse submodule arguments.");
+ goto fail;
+ }
+
+ frame_size_ms = DEFAULT_FRAME_SIZE_MS;
+ if (pa_modargs_get_value_u32(ma, "frame_size_ms", &frame_size_ms) < 0 || frame_size_ms < 1 || frame_size_ms > 200) {
+ pa_log("Invalid frame_size_ms specification");
+ goto fail;
+ }
+
+ pa_adrian_ec_fixate_spec(source_ss, source_map, sink_ss, sink_map);
+
+ rate = source_ss->rate;
+ framelen = (rate * frame_size_ms) / 1000;
+
+ *blocksize = ec->params.priv.adrian.blocksize = framelen * pa_frame_size (source_ss);
+
+ pa_log_debug ("Using framelen %d, blocksize %u, channels %d, rate %d", framelen, ec->params.priv.adrian.blocksize, source_ss->channels, source_ss->rate);
+
+ /* For now we only support SSE */
+ if (c->cpu_info.cpu_type == PA_CPU_X86 && (c->cpu_info.flags.x86 & PA_CPU_X86_SSE))
+ have_vector = 1;
+
+ ec->params.priv.adrian.aec = AEC_init(rate, have_vector);
+ if (!ec->params.priv.adrian.aec)
+ goto fail;
+
+ pa_modargs_free(ma);
+ return TRUE;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+ return FALSE;
+}
+
+void pa_adrian_ec_run(pa_echo_canceller *ec, const uint8_t *rec, const uint8_t *play, uint8_t *out) {
+ unsigned int i;
+
+ for (i = 0; i < ec->params.priv.adrian.blocksize; i += 2) {
+ /* We know it's S16NE mono data */
+ int r = *(int16_t *)(rec + i);
+ int p = *(int16_t *)(play + i);
+ *(int16_t *)(out + i) = (int16_t) AEC_doAEC(ec->params.priv.adrian.aec, r, p);
+ }
+}
+
+void pa_adrian_ec_done(pa_echo_canceller *ec) {
+ pa_xfree(ec->params.priv.adrian.aec);
+ ec->params.priv.adrian.aec = NULL;
+}
diff --git a/src/modules/echo-cancel/adrian.h b/src/modules/echo-cancel/adrian.h
new file mode 100644
index 00000000..639fa9ec
--- /dev/null
+++ b/src/modules/echo-cancel/adrian.h
@@ -0,0 +1,31 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ The actual implementation is taken from the sources at
+ http://andreadrian.de/intercom/ - for the license, look for
+ adrian-license.txt in the same directory as this file.
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* Forward declarations */
+
+typedef struct AEC AEC;
+
+AEC* AEC_init(int RATE, int have_vector);
+int AEC_doAEC(AEC *a, int d_, int x_);
diff --git a/src/modules/echo-cancel/echo-cancel.h b/src/modules/echo-cancel/echo-cancel.h
new file mode 100644
index 00000000..aa40adce
--- /dev/null
+++ b/src/modules/echo-cancel/echo-cancel.h
@@ -0,0 +1,90 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/sample.h>
+#include <pulse/channelmap.h>
+#include <pulsecore/core.h>
+#include <pulsecore/macro.h>
+
+#include <speex/speex_echo.h>
+#include <speex/speex_preprocess.h>
+#include "adrian.h"
+
+/* Common data structures */
+
+typedef struct pa_echo_canceller_params pa_echo_canceller_params;
+
+struct pa_echo_canceller_params {
+ union {
+ struct {
+ SpeexEchoState *state;
+ } speex;
+ struct {
+ uint32_t blocksize;
+ AEC *aec;
+ } adrian;
+ /* each canceller-specific structure goes here */
+ } priv;
+};
+
+typedef struct pa_echo_canceller pa_echo_canceller;
+
+struct pa_echo_canceller {
+ pa_bool_t (*init) (pa_core *c,
+ pa_echo_canceller *ec,
+ pa_sample_spec *source_ss,
+ pa_channel_map *source_map,
+ pa_sample_spec *sink_ss,
+ pa_channel_map *sink_map,
+ uint32_t *blocksize,
+ const char *args);
+ void (*run) (pa_echo_canceller *ec, const uint8_t *rec, const uint8_t *play, uint8_t *out);
+ void (*done) (pa_echo_canceller *ec);
+
+ pa_echo_canceller_params params;
+
+ pa_bool_t agc;
+ pa_bool_t denoise;
+ pa_bool_t echo_suppress;
+ int32_t echo_suppress_attenuation;
+ int32_t echo_suppress_attenuation_active;
+ SpeexPreprocessState *pp_state;
+};
+
+/* Speex canceller functions */
+pa_bool_t pa_speex_ec_init(pa_core *c, pa_echo_canceller *ec,
+ pa_sample_spec *source_ss, pa_channel_map *source_map,
+ pa_sample_spec *sink_ss, pa_channel_map *sink_map,
+ uint32_t *blocksize, const char *args);
+void pa_speex_ec_run(pa_echo_canceller *ec, const uint8_t *rec, const uint8_t *play, uint8_t *out);
+void pa_speex_ec_done(pa_echo_canceller *ec);
+
+/* Adrian Andre's echo canceller */
+pa_bool_t pa_adrian_ec_init(pa_core *c, pa_echo_canceller *ec,
+ pa_sample_spec *source_ss, pa_channel_map *source_map,
+ pa_sample_spec *sink_ss, pa_channel_map *sink_map,
+ uint32_t *blocksize, const char *args);
+void pa_adrian_ec_run(pa_echo_canceller *ec, const uint8_t *rec, const uint8_t *play, uint8_t *out);
+void pa_adrian_ec_done(pa_echo_canceller *ec);
diff --git a/src/modules/echo-cancel/module-echo-cancel.c b/src/modules/echo-cancel/module-echo-cancel.c
new file mode 100644
index 00000000..b84bf1db
--- /dev/null
+++ b/src/modules/echo-cancel/module-echo-cancel.c
@@ -0,0 +1,1778 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Wim Taymans <wim.taymans@gmail.com>
+
+ Based on module-virtual-sink.c
+ module-virtual-source.c
+ module-loopback.c
+
+ Copyright 2010 Intel Corporation
+ Contributor: Pierre-Louis Bossart <pierre-louis.bossart@intel.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdio.h>
+
+#include "echo-cancel.h"
+
+#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
+#include <pulse/timeval.h>
+#include <pulse/rtclock.h>
+
+#include <pulsecore/atomic.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/module.h>
+#include <pulsecore/core-rtclock.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/rtpoll.h>
+#include <pulsecore/sample-util.h>
+#include <pulsecore/ltdl-helper.h>
+
+#include "module-echo-cancel-symdef.h"
+
+PA_MODULE_AUTHOR("Wim Taymans");
+PA_MODULE_DESCRIPTION("Echo Cancelation");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE(
+ _("source_name=<name for the source> "
+ "source_properties=<properties for the source> "
+ "source_master=<name of source to filter> "
+ "sink_name=<name for the sink> "
+ "sink_properties=<properties for the sink> "
+ "sink_master=<name of sink to filter> "
+ "adjust_time=<how often to readjust rates in s> "
+ "format=<sample format> "
+ "rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<channel map> "
+ "aec_method=<implementation to use> "
+ "aec_args=<parameters for the AEC engine> "
+ "agc=<perform automagic gain control?> "
+ "denoise=<apply denoising?> "
+ "echo_suppress=<perform residual echo suppression? (only with the speex canceller)> "
+ "echo_suppress_attenuation=<dB value of residual echo attenuation> "
+ "echo_suppress_attenuation_active=<dB value of residual echo attenuation when near end is active> "
+ "save_aec=<save AEC data in /tmp> "
+ "autoloaded=<set if this module is being loaded automatically> "
+ ));
+
+/* NOTE: Make sure the enum and ec_table are maintained in the correct order */
+typedef enum {
+ PA_ECHO_CANCELLER_INVALID = -1,
+ PA_ECHO_CANCELLER_SPEEX = 0,
+ PA_ECHO_CANCELLER_ADRIAN,
+} pa_echo_canceller_method_t;
+
+#define DEFAULT_ECHO_CANCELLER "speex"
+
+static const pa_echo_canceller ec_table[] = {
+ {
+ /* Speex */
+ .init = pa_speex_ec_init,
+ .run = pa_speex_ec_run,
+ .done = pa_speex_ec_done,
+ },
+ {
+ /* Adrian Andre's NLMS implementation */
+ .init = pa_adrian_ec_init,
+ .run = pa_adrian_ec_run,
+ .done = pa_adrian_ec_done,
+ },
+};
+
+#define DEFAULT_ADJUST_TIME_USEC (1*PA_USEC_PER_SEC)
+#define DEFAULT_AGC_ENABLED FALSE
+#define DEFAULT_DENOISE_ENABLED FALSE
+#define DEFAULT_ECHO_SUPPRESS_ENABLED FALSE
+#define DEFAULT_ECHO_SUPPRESS_ATTENUATION 0
+#define DEFAULT_SAVE_AEC 0
+#define DEFAULT_AUTOLOADED FALSE
+
+#define MEMBLOCKQ_MAXLENGTH (16*1024*1024)
+
+/* This module creates a new (virtual) source and sink.
+ *
+ * The data sent to the new sink is kept in a memblockq before being
+ * forwarded to the real sink_master.
+ *
+ * Data read from source_master is matched against the saved sink data and
+ * echo canceled data is then pushed onto the new source.
+ *
+ * Both source and sink masters have their own threads to push/pull data
+ * respectively. We however perform all our actions in the source IO thread.
+ * To do this we send all played samples to the source IO thread where they
+ * are then pushed into the memblockq.
+ *
+ * Alignment is performed in two steps:
+ *
+ * 1) when something happens that requires quick adjustement of the alignment of
+ * capture and playback samples, we perform a resync. This adjusts the
+ * position in the playback memblock to the requested sample. Quick
+ * adjustements include moving the playback samples before the capture
+ * samples (because else the echo canceler does not work) or when the
+ * playback pointer drifts too far away.
+ *
+ * 2) periodically check the difference between capture and playback. we use a
+ * low and high watermark for adjusting the alignment. playback should always
+ * be before capture and the difference should not be bigger than one frame
+ * size. We would ideally like to resample the sink_input but most driver
+ * don't give enough accuracy to be able to do that right now.
+ */
+
+struct snapshot {
+ pa_usec_t sink_now;
+ pa_usec_t sink_latency;
+ size_t sink_delay;
+ int64_t send_counter;
+
+ pa_usec_t source_now;
+ pa_usec_t source_latency;
+ size_t source_delay;
+ int64_t recv_counter;
+ size_t rlen;
+ size_t plen;
+};
+
+struct userdata {
+ pa_core *core;
+ pa_module *module;
+
+ pa_bool_t autoloaded;
+ uint32_t save_aec;
+
+ pa_echo_canceller *ec;
+ uint32_t blocksize;
+
+ pa_bool_t need_realign;
+
+ /* to wakeup the source I/O thread */
+ pa_bool_t in_push;
+ pa_asyncmsgq *asyncmsgq;
+ pa_rtpoll_item *rtpoll_item_read, *rtpoll_item_write;
+
+ pa_source *source;
+ pa_bool_t source_auto_desc;
+ pa_source_output *source_output;
+ pa_memblockq *source_memblockq; /* echo canceler needs fixed sized chunks */
+ size_t source_skip;
+
+ pa_sink *sink;
+ pa_bool_t sink_auto_desc;
+ pa_sink_input *sink_input;
+ pa_memblockq *sink_memblockq;
+ int64_t send_counter; /* updated in sink IO thread */
+ int64_t recv_counter;
+ size_t sink_skip;
+
+ pa_atomic_t request_resync;
+
+ int active_mask;
+ pa_time_event *time_event;
+ pa_usec_t adjust_time;
+
+ FILE *captured_file;
+ FILE *played_file;
+ FILE *canceled_file;
+};
+
+static void source_output_snapshot_within_thread(struct userdata *u, struct snapshot *snapshot);
+
+static const char* const valid_modargs[] = {
+ "source_name",
+ "source_properties",
+ "source_master",
+ "sink_name",
+ "sink_properties",
+ "sink_master",
+ "adjust_time",
+ "format",
+ "rate",
+ "channels",
+ "channel_map",
+ "aec_method",
+ "aec_args",
+ "agc",
+ "denoise",
+ "echo_suppress",
+ "echo_suppress_attenuation",
+ "echo_suppress_attenuation_active",
+ "save_aec",
+ "autoloaded",
+ NULL
+};
+
+enum {
+ SOURCE_OUTPUT_MESSAGE_POST = PA_SOURCE_OUTPUT_MESSAGE_MAX,
+ SOURCE_OUTPUT_MESSAGE_REWIND,
+ SOURCE_OUTPUT_MESSAGE_LATENCY_SNAPSHOT,
+ SOURCE_OUTPUT_MESSAGE_APPLY_DIFF_TIME
+};
+
+enum {
+ SINK_INPUT_MESSAGE_LATENCY_SNAPSHOT
+};
+
+static int64_t calc_diff(struct userdata *u, struct snapshot *snapshot) {
+ int64_t buffer, diff_time, buffer_latency;
+
+ /* get the number of samples between capture and playback */
+ if (snapshot->plen > snapshot->rlen)
+ buffer = snapshot->plen - snapshot->rlen;
+ else
+ buffer = 0;
+
+ buffer += snapshot->source_delay + snapshot->sink_delay;
+
+ /* add the amount of samples not yet transfered to the source context */
+ if (snapshot->recv_counter <= snapshot->send_counter)
+ buffer += (int64_t) (snapshot->send_counter - snapshot->recv_counter);
+ else
+ buffer += PA_CLIP_SUB(buffer, (int64_t) (snapshot->recv_counter - snapshot->send_counter));
+
+ /* convert to time */
+ buffer_latency = pa_bytes_to_usec(buffer, &u->source_output->sample_spec);
+
+ /* capture and playback samples are perfectly aligned when diff_time is 0 */
+ diff_time = (snapshot->sink_now + snapshot->sink_latency - buffer_latency) -
+ (snapshot->source_now - snapshot->source_latency);
+
+ pa_log_debug("diff %lld (%lld - %lld + %lld) %lld %lld %lld %lld", (long long) diff_time,
+ (long long) snapshot->sink_latency,
+ (long long) buffer_latency, (long long) snapshot->source_latency,
+ (long long) snapshot->source_delay, (long long) snapshot->sink_delay,
+ (long long) (snapshot->send_counter - snapshot->recv_counter),
+ (long long) (snapshot->sink_now - snapshot->source_now));
+
+ return diff_time;
+}
+
+/* Called from main context */
+static void time_callback(pa_mainloop_api *a, pa_time_event *e, const struct timeval *t, void *userdata) {
+ struct userdata *u = userdata;
+ uint32_t old_rate, base_rate, new_rate;
+ int64_t diff_time;
+ /*size_t fs*/
+ struct snapshot latency_snapshot;
+
+ pa_assert(u);
+ pa_assert(a);
+ pa_assert(u->time_event == e);
+ pa_assert_ctl_context();
+
+ if (u->active_mask != 3)
+ return;
+
+ /* update our snapshots */
+ pa_asyncmsgq_send(u->source_output->source->asyncmsgq, PA_MSGOBJECT(u->source_output), SOURCE_OUTPUT_MESSAGE_LATENCY_SNAPSHOT, &latency_snapshot, 0, NULL);
+ pa_asyncmsgq_send(u->sink_input->sink->asyncmsgq, PA_MSGOBJECT(u->sink_input), SINK_INPUT_MESSAGE_LATENCY_SNAPSHOT, &latency_snapshot, 0, NULL);
+
+ /* calculate drift between capture and playback */
+ diff_time = calc_diff(u, &latency_snapshot);
+
+ /*fs = pa_frame_size(&u->source_output->sample_spec);*/
+ old_rate = u->sink_input->sample_spec.rate;
+ base_rate = u->source_output->sample_spec.rate;
+
+ if (diff_time < 0) {
+ /* recording before playback, we need to adjust quickly. The echo
+ * canceler does not work in this case. */
+ pa_asyncmsgq_post(u->asyncmsgq, PA_MSGOBJECT(u->source_output), SOURCE_OUTPUT_MESSAGE_APPLY_DIFF_TIME,
+ NULL, diff_time, NULL, NULL);
+ /*new_rate = base_rate - ((pa_usec_to_bytes(-diff_time, &u->source_output->sample_spec) / fs) * PA_USEC_PER_SEC) / u->adjust_time;*/
+ new_rate = base_rate;
+ }
+ else {
+ if (diff_time > 1000) {
+ /* diff too big, quickly adjust */
+ pa_asyncmsgq_post(u->asyncmsgq, PA_MSGOBJECT(u->source_output), SOURCE_OUTPUT_MESSAGE_APPLY_DIFF_TIME,
+ NULL, diff_time, NULL, NULL);
+ }
+
+ /* recording behind playback, we need to slowly adjust the rate to match */
+ /*new_rate = base_rate + ((pa_usec_to_bytes(diff_time, &u->source_output->sample_spec) / fs) * PA_USEC_PER_SEC) / u->adjust_time;*/
+
+ /* assume equal samplerates for now */
+ new_rate = base_rate;
+ }
+
+ /* make sure we don't make too big adjustements because that sounds horrible */
+ if (new_rate > base_rate * 1.1 || new_rate < base_rate * 0.9)
+ new_rate = base_rate;
+
+ if (new_rate != old_rate) {
+ pa_log_info("Old rate %lu Hz, new rate %lu Hz", (unsigned long) old_rate, (unsigned long) new_rate);
+
+ pa_sink_input_set_rate(u->sink_input, new_rate);
+ }
+
+ pa_core_rttime_restart(u->core, u->time_event, pa_rtclock_now() + u->adjust_time);
+}
+
+/* Called from source I/O thread context */
+static int source_process_msg_cb(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SOURCE(o)->userdata;
+
+ switch (code) {
+
+ case PA_SOURCE_MESSAGE_GET_LATENCY:
+
+ /* The source is _put() before the source output is, so let's
+ * make sure we don't access it in that time. Also, the
+ * source output is first shut down, the source second. */
+ if (!PA_SOURCE_IS_LINKED(u->source->thread_info.state) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(u->source_output->thread_info.state)) {
+ *((pa_usec_t*) data) = 0;
+ return 0;
+ }
+
+ *((pa_usec_t*) data) =
+
+ /* Get the latency of the master source */
+ pa_source_get_latency_within_thread(u->source_output->source) +
+ /* Add the latency internal to our source output on top */
+ pa_bytes_to_usec(pa_memblockq_get_length(u->source_output->thread_info.delay_memblockq), &u->source_output->source->sample_spec) +
+ /* and the buffering we do on the source */
+ pa_bytes_to_usec(u->blocksize, &u->source_output->source->sample_spec);
+
+ return 0;
+
+ }
+
+ return pa_source_process_msg(o, code, data, offset, chunk);
+}
+
+/* Called from sink I/O thread context */
+static int sink_process_msg_cb(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SINK(o)->userdata;
+
+ switch (code) {
+
+ case PA_SINK_MESSAGE_GET_LATENCY:
+
+ /* The sink is _put() before the sink input is, so let's
+ * make sure we don't access it in that time. Also, the
+ * sink input is first shut down, the sink second. */
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state)) {
+ *((pa_usec_t*) data) = 0;
+ return 0;
+ }
+
+ *((pa_usec_t*) data) =
+
+ /* Get the latency of the master sink */
+ pa_sink_get_latency_within_thread(u->sink_input->sink) +
+
+ /* Add the latency internal to our sink input on top */
+ pa_bytes_to_usec(pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq), &u->sink_input->sink->sample_spec);
+
+ return 0;
+ }
+
+ return pa_sink_process_msg(o, code, data, offset, chunk);
+}
+
+
+/* Called from main context */
+static int source_set_state_cb(pa_source *s, pa_source_state_t state) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(state) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return 0;
+
+ pa_log_debug("Source state %d %d", state, u->active_mask);
+
+ if (state == PA_SOURCE_RUNNING) {
+ /* restart timer when both sink and source are active */
+ u->active_mask |= 1;
+ if (u->active_mask == 3)
+ pa_core_rttime_restart(u->core, u->time_event, pa_rtclock_now() + u->adjust_time);
+
+ pa_atomic_store(&u->request_resync, 1);
+ pa_source_output_cork(u->source_output, FALSE);
+ } else if (state == PA_SOURCE_SUSPENDED) {
+ u->active_mask &= ~1;
+ pa_source_output_cork(u->source_output, TRUE);
+ }
+ return 0;
+}
+
+/* Called from main context */
+static int sink_set_state_cb(pa_sink *s, pa_sink_state_t state) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(state) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return 0;
+
+ pa_log_debug("Sink state %d %d", state, u->active_mask);
+
+ if (state == PA_SINK_RUNNING) {
+ /* restart timer when both sink and source are active */
+ u->active_mask |= 2;
+ if (u->active_mask == 3)
+ pa_core_rttime_restart(u->core, u->time_event, pa_rtclock_now() + u->adjust_time);
+
+ pa_atomic_store(&u->request_resync, 1);
+ pa_sink_input_cork(u->sink_input, FALSE);
+ } else if (state == PA_SINK_SUSPENDED) {
+ u->active_mask &= ~2;
+ pa_sink_input_cork(u->sink_input, TRUE);
+ }
+ return 0;
+}
+
+/* Called from I/O thread context */
+static void source_update_requested_latency_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(u->source->thread_info.state) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(u->source_output->thread_info.state))
+ return;
+
+ pa_log_debug("Source update requested latency");
+
+ /* Just hand this one over to the master source */
+ pa_source_output_set_requested_latency_within_thread(
+ u->source_output,
+ pa_source_get_requested_latency_within_thread(s));
+}
+
+/* Called from I/O thread context */
+static void sink_update_requested_latency_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
+ pa_log_debug("Sink update requested latency");
+
+ /* Just hand this one over to the master sink */
+ pa_sink_input_set_requested_latency_within_thread(
+ u->sink_input,
+ pa_sink_get_requested_latency_within_thread(s));
+}
+
+/* Called from I/O thread context */
+static void sink_request_rewind_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
+ pa_log_debug("Sink request rewind %lld", (long long) s->thread_info.rewind_nbytes);
+
+ /* Just hand this one over to the master sink */
+ pa_sink_input_request_rewind(u->sink_input,
+ s->thread_info.rewind_nbytes, TRUE, FALSE, FALSE);
+}
+
+/* Called from main context */
+static void source_set_volume_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(s)) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return;
+
+ pa_source_output_set_volume(u->source_output, &s->real_volume, s->save_volume, TRUE);
+}
+
+/* Called from main context */
+static void sink_set_volume_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_volume(u->sink_input, &s->real_volume, s->save_volume, TRUE);
+}
+
+static void source_get_volume_cb(pa_source *s) {
+ struct userdata *u;
+ pa_cvolume v;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(s)) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return;
+
+ pa_source_output_get_volume(u->source_output, &v, TRUE);
+
+ if (pa_cvolume_equal(&s->real_volume, &v))
+ /* no change */
+ return;
+
+ s->real_volume = v;
+ pa_source_set_soft_volume(s, NULL);
+}
+
+/* Called from main context */
+static void source_set_mute_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(s)) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return;
+
+ pa_source_output_set_mute(u->source_output, s->muted, s->save_muted);
+}
+
+/* Called from main context */
+static void sink_set_mute_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_mute(u->sink_input, s->muted, s->save_muted);
+}
+
+/* Called from main context */
+static void source_get_mute_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(s)) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return;
+
+ pa_source_output_get_mute(u->source_output);
+}
+
+/* must be called from the input thread context */
+static void apply_diff_time(struct userdata *u, int64_t diff_time) {
+ int64_t diff;
+
+ if (diff_time < 0) {
+ diff = pa_usec_to_bytes(-diff_time, &u->source_output->sample_spec);
+
+ if (diff > 0) {
+ /* add some extra safety samples to compensate for jitter in the
+ * timings */
+ diff += 10 * pa_frame_size (&u->source_output->sample_spec);
+
+ pa_log("Playback after capture (%lld), drop sink %lld", (long long) diff_time, (long long) diff);
+
+ u->sink_skip = diff;
+ u->source_skip = 0;
+ }
+ } else if (diff_time > 0) {
+ diff = pa_usec_to_bytes(diff_time, &u->source_output->sample_spec);
+
+ if (diff > 0) {
+ pa_log("playback too far ahead (%lld), drop source %lld", (long long) diff_time, (long long) diff);
+
+ u->source_skip = diff;
+ u->sink_skip = 0;
+ }
+ }
+}
+
+/* must be called from the input thread */
+static void do_resync(struct userdata *u) {
+ int64_t diff_time;
+ struct snapshot latency_snapshot;
+
+ pa_log("Doing resync");
+
+ /* update our snapshot */
+ source_output_snapshot_within_thread(u, &latency_snapshot);
+ pa_asyncmsgq_send(u->sink_input->sink->asyncmsgq, PA_MSGOBJECT(u->sink_input), SINK_INPUT_MESSAGE_LATENCY_SNAPSHOT, &latency_snapshot, 0, NULL);
+
+ /* calculate drift between capture and playback */
+ diff_time = calc_diff(u, &latency_snapshot);
+
+ /* and adjust for the drift */
+ apply_diff_time(u, diff_time);
+}
+
+/* Called from input thread context */
+static void source_output_push_cb(pa_source_output *o, const pa_memchunk *chunk) {
+ struct userdata *u;
+ size_t rlen, plen;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ if (!PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output))) {
+ pa_log("push when no link?");
+ return;
+ }
+
+ /* handle queued messages */
+ u->in_push = TRUE;
+ while (pa_asyncmsgq_process_one(u->asyncmsgq) > 0)
+ ;
+ u->in_push = FALSE;
+
+ if (pa_atomic_cmpxchg (&u->request_resync, 1, 0)) {
+ do_resync(u);
+ }
+
+ pa_memblockq_push_align(u->source_memblockq, chunk);
+
+ rlen = pa_memblockq_get_length(u->source_memblockq);
+ plen = pa_memblockq_get_length(u->sink_memblockq);
+
+ while (rlen >= u->blocksize) {
+ pa_memchunk rchunk, pchunk;
+
+ /* take fixed block from recorded samples */
+ pa_memblockq_peek_fixed_size(u->source_memblockq, u->blocksize, &rchunk);
+
+ if (plen > u->blocksize && u->source_skip == 0) {
+ uint8_t *rdata, *pdata, *cdata;
+ pa_memchunk cchunk;
+
+ if (u->sink_skip) {
+ size_t to_skip;
+
+ if (u->sink_skip > plen)
+ to_skip = plen;
+ else
+ to_skip = u->sink_skip;
+
+ pa_memblockq_drop(u->sink_memblockq, to_skip);
+ plen -= to_skip;
+
+ u->sink_skip -= to_skip;
+ }
+
+ if (plen > u->blocksize && u->sink_skip == 0) {
+ /* take fixed block from played samples */
+ pa_memblockq_peek_fixed_size(u->sink_memblockq, u->blocksize, &pchunk);
+
+ rdata = pa_memblock_acquire(rchunk.memblock);
+ rdata += rchunk.index;
+ pdata = pa_memblock_acquire(pchunk.memblock);
+ pdata += pchunk.index;
+
+ cchunk.index = 0;
+ cchunk.length = u->blocksize;
+ cchunk.memblock = pa_memblock_new(u->source->core->mempool, cchunk.length);
+ cdata = pa_memblock_acquire(cchunk.memblock);
+
+ if (u->save_aec) {
+ if (u->captured_file)
+ fwrite(rdata, 1, u->blocksize, u->captured_file);
+ if (u->played_file)
+ fwrite(pdata, 1, u->blocksize, u->played_file);
+ }
+
+ /* perform echo cancelation */
+ u->ec->run(u->ec, rdata, pdata, cdata);
+
+ /* preprecessor is run after AEC. This is not a mistake! */
+ if (u->ec->pp_state)
+ speex_preprocess_run(u->ec->pp_state, (spx_int16_t *) cdata);
+
+ if (u->save_aec) {
+ if (u->canceled_file)
+ fwrite(cdata, 1, u->blocksize, u->canceled_file);
+ }
+
+ pa_memblock_release(cchunk.memblock);
+ pa_memblock_release(pchunk.memblock);
+ pa_memblock_release(rchunk.memblock);
+
+ /* drop consumed sink samples */
+ pa_memblockq_drop(u->sink_memblockq, u->blocksize);
+ pa_memblock_unref(pchunk.memblock);
+
+ pa_memblock_unref(rchunk.memblock);
+ /* the filtered samples now become the samples from our
+ * source */
+ rchunk = cchunk;
+
+ plen -= u->blocksize;
+ }
+ }
+
+ /* forward the (echo-canceled) data to the virtual source */
+ pa_source_post(u->source, &rchunk);
+ pa_memblock_unref(rchunk.memblock);
+
+ pa_memblockq_drop(u->source_memblockq, u->blocksize);
+ rlen -= u->blocksize;
+
+ if (u->source_skip) {
+ if (u->source_skip > u->blocksize) {
+ u->source_skip -= u->blocksize;
+ }
+ else {
+ u->sink_skip += (u->blocksize - u->source_skip);
+ u->source_skip = 0;
+ }
+ }
+ }
+}
+
+/* Called from I/O thread context */
+static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert(chunk);
+ pa_assert_se(u = i->userdata);
+
+ if (u->sink->thread_info.rewind_requested)
+ pa_sink_process_rewind(u->sink, 0);
+
+ pa_sink_render_full(u->sink, nbytes, chunk);
+
+ if (i->thread_info.underrun_for > 0) {
+ pa_log_debug("Handling end of underrun.");
+ pa_atomic_store(&u->request_resync, 1);
+ }
+
+ /* let source thread handle the chunk. pass the sample count as well so that
+ * the source IO thread can update the right variables. */
+ pa_asyncmsgq_post(u->asyncmsgq, PA_MSGOBJECT(u->source_output), SOURCE_OUTPUT_MESSAGE_POST,
+ NULL, 0, chunk, NULL);
+ u->send_counter += chunk->length;
+
+ return 0;
+}
+
+/* Called from input thread context */
+static void source_output_process_rewind_cb(pa_source_output *o, size_t nbytes) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_source_process_rewind(u->source, nbytes);
+
+ /* go back on read side, we need to use older sink data for this */
+ pa_memblockq_rewind(u->sink_memblockq, nbytes);
+
+ /* manipulate write index */
+ pa_memblockq_seek(u->source_memblockq, -nbytes, PA_SEEK_RELATIVE, TRUE);
+
+ pa_log_debug("Source rewind (%lld) %lld", (long long) nbytes,
+ (long long) pa_memblockq_get_length (u->source_memblockq));
+}
+
+/* Called from I/O thread context */
+static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_log_debug("Sink process rewind %lld", (long long) nbytes);
+
+ pa_sink_process_rewind(u->sink, nbytes);
+
+ pa_asyncmsgq_post(u->asyncmsgq, PA_MSGOBJECT(u->source_output), SOURCE_OUTPUT_MESSAGE_REWIND, NULL, (int64_t) nbytes, NULL, NULL);
+ u->send_counter -= nbytes;
+}
+
+static void source_output_snapshot_within_thread(struct userdata *u, struct snapshot *snapshot) {
+ size_t delay, rlen, plen;
+ pa_usec_t now, latency;
+
+ now = pa_rtclock_now();
+ latency = pa_source_get_latency_within_thread(u->source_output->source);
+ delay = pa_memblockq_get_length(u->source_output->thread_info.delay_memblockq);
+
+ delay = (u->source_output->thread_info.resampler ? pa_resampler_request(u->source_output->thread_info.resampler, delay) : delay);
+ rlen = pa_memblockq_get_length(u->source_memblockq);
+ plen = pa_memblockq_get_length(u->sink_memblockq);
+
+ snapshot->source_now = now;
+ snapshot->source_latency = latency;
+ snapshot->source_delay = delay;
+ snapshot->recv_counter = u->recv_counter;
+ snapshot->rlen = rlen + u->sink_skip;
+ snapshot->plen = plen + u->source_skip;
+}
+
+
+/* Called from output thread context */
+static int source_output_process_msg_cb(pa_msgobject *obj, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SOURCE_OUTPUT(obj)->userdata;
+
+ switch (code) {
+
+ case SOURCE_OUTPUT_MESSAGE_POST:
+
+ pa_source_output_assert_io_context(u->source_output);
+
+ if (PA_SOURCE_IS_OPENED(u->source_output->source->thread_info.state))
+ pa_memblockq_push_align(u->sink_memblockq, chunk);
+ else
+ pa_memblockq_flush_write(u->sink_memblockq, TRUE);
+
+ u->recv_counter += (int64_t) chunk->length;
+
+ return 0;
+
+ case SOURCE_OUTPUT_MESSAGE_REWIND:
+ pa_source_output_assert_io_context(u->source_output);
+
+ /* manipulate write index, never go past what we have */
+ if (PA_SOURCE_IS_OPENED(u->source_output->source->thread_info.state))
+ pa_memblockq_seek(u->sink_memblockq, -offset, PA_SEEK_RELATIVE, TRUE);
+ else
+ pa_memblockq_flush_write(u->sink_memblockq, TRUE);
+
+ pa_log_debug("Sink rewind (%lld)", (long long) offset);
+
+ u->recv_counter -= offset;
+
+ return 0;
+
+ case SOURCE_OUTPUT_MESSAGE_LATENCY_SNAPSHOT: {
+ struct snapshot *snapshot = (struct snapshot *) data;
+
+ source_output_snapshot_within_thread(u, snapshot);
+ return 0;
+ }
+
+ case SOURCE_OUTPUT_MESSAGE_APPLY_DIFF_TIME:
+ apply_diff_time(u, offset);
+ return 0;
+
+ }
+
+ return pa_source_output_process_msg(obj, code, data, offset, chunk);
+}
+
+static int sink_input_process_msg_cb(pa_msgobject *obj, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SINK_INPUT(obj)->userdata;
+
+ switch (code) {
+
+ case SINK_INPUT_MESSAGE_LATENCY_SNAPSHOT: {
+ size_t delay;
+ pa_usec_t now, latency;
+ struct snapshot *snapshot = (struct snapshot *) data;
+
+ pa_sink_input_assert_io_context(u->sink_input);
+
+ now = pa_rtclock_now();
+ latency = pa_sink_get_latency_within_thread(u->sink_input->sink);
+ delay = pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq);
+
+ delay = (u->sink_input->thread_info.resampler ? pa_resampler_request(u->sink_input->thread_info.resampler, delay) : delay);
+
+ snapshot->sink_now = now;
+ snapshot->sink_latency = latency;
+ snapshot->sink_delay = delay;
+ snapshot->send_counter = u->send_counter;
+ return 0;
+ }
+ }
+
+ return pa_sink_input_process_msg(obj, code, data, offset, chunk);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_log_debug("Sink input update max rewind %lld", (long long) nbytes);
+
+ pa_memblockq_set_maxrewind(u->sink_memblockq, nbytes);
+ pa_sink_set_max_rewind_within_thread(u->sink, nbytes);
+}
+
+/* Called from I/O thread context */
+static void source_output_update_max_rewind_cb(pa_source_output *o, size_t nbytes) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_log_debug("Source output update max rewind %lld", (long long) nbytes);
+
+ pa_source_set_max_rewind_within_thread(u->source, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_log_debug("Sink input update max request %lld", (long long) nbytes);
+
+ pa_sink_set_max_request_within_thread(u->sink, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_sink_requested_latency_cb(pa_sink_input *i) {
+ struct userdata *u;
+ pa_usec_t latency;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ latency = pa_sink_get_requested_latency_within_thread(i->sink);
+
+ pa_log_debug("Sink input update requested latency %lld", (long long) latency);
+}
+
+/* Called from I/O thread context */
+static void source_output_update_source_requested_latency_cb(pa_source_output *o) {
+ struct userdata *u;
+ pa_usec_t latency;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_se(u = o->userdata);
+
+ latency = pa_source_get_requested_latency_within_thread(o->source);
+
+ pa_log_debug("source output update requested latency %lld", (long long) latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_sink_latency_range_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_log_debug("Sink input update latency range %lld %lld",
+ (long long) i->sink->thread_info.min_latency,
+ (long long) i->sink->thread_info.max_latency);
+
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+}
+
+/* Called from I/O thread context */
+static void source_output_update_source_latency_range_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_log_debug("Source output update latency range %lld %lld",
+ (long long) o->source->thread_info.min_latency,
+ (long long) o->source->thread_info.max_latency);
+
+ pa_source_set_latency_range_within_thread(u->source, o->source->thread_info.min_latency, o->source->thread_info.max_latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_sink_fixed_latency_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_log_debug("Sink input update fixed latency %lld",
+ (long long) i->sink->thread_info.fixed_latency);
+
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+}
+
+/* Called from I/O thread context */
+static void source_output_update_source_fixed_latency_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_log_debug("Source output update fixed latency %lld",
+ (long long) o->source->thread_info.fixed_latency);
+
+ pa_source_set_fixed_latency_within_thread(u->source, o->source->thread_info.fixed_latency);
+}
+
+/* Called from output thread context */
+static void source_output_attach_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_source_set_rtpoll(u->source, o->source->thread_info.rtpoll);
+ pa_source_set_latency_range_within_thread(u->source, o->source->thread_info.min_latency, o->source->thread_info.max_latency);
+ pa_source_set_fixed_latency_within_thread(u->source, o->source->thread_info.fixed_latency);
+ pa_source_set_max_rewind_within_thread(u->source, pa_source_output_get_max_rewind(o));
+
+ pa_log_debug("Source output %p attach", o);
+
+ pa_source_attach_within_thread(u->source);
+
+ u->rtpoll_item_read = pa_rtpoll_item_new_asyncmsgq_read(
+ o->source->thread_info.rtpoll,
+ PA_RTPOLL_LATE,
+ u->asyncmsgq);
+}
+
+/* Called from I/O thread context */
+static void sink_input_attach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_set_rtpoll(u->sink, i->sink->thread_info.rtpoll);
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+
+ /* (8.1) IF YOU NEED A FIXED BLOCK SIZE ADD THE LATENCY FOR ONE
+ * BLOCK MINUS ONE SAMPLE HERE. SEE (7) */
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+
+ /* (8.2) IF YOU NEED A FIXED BLOCK SIZE ROUND
+ * pa_sink_input_get_max_request(i) UP TO MULTIPLES OF IT
+ * HERE. SEE (6) */
+ pa_sink_set_max_request_within_thread(u->sink, pa_sink_input_get_max_request(i));
+ pa_sink_set_max_rewind_within_thread(u->sink, pa_sink_input_get_max_rewind(i));
+
+ pa_log_debug("Sink input %p attach", i);
+
+ u->rtpoll_item_write = pa_rtpoll_item_new_asyncmsgq_write(
+ i->sink->thread_info.rtpoll,
+ PA_RTPOLL_LATE,
+ u->asyncmsgq);
+
+ pa_sink_attach_within_thread(u->sink);
+}
+
+
+/* Called from output thread context */
+static void source_output_detach_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_source_detach_within_thread(u->source);
+ pa_source_set_rtpoll(u->source, NULL);
+
+ pa_log_debug("Source output %p detach", o);
+
+ if (u->rtpoll_item_read) {
+ pa_rtpoll_item_free(u->rtpoll_item_read);
+ u->rtpoll_item_read = NULL;
+ }
+}
+
+/* Called from I/O thread context */
+static void sink_input_detach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_detach_within_thread(u->sink);
+
+ pa_sink_set_rtpoll(u->sink, NULL);
+
+ pa_log_debug("Sink input %p detach", i);
+
+ if (u->rtpoll_item_write) {
+ pa_rtpoll_item_free(u->rtpoll_item_write);
+ u->rtpoll_item_write = NULL;
+ }
+}
+
+/* Called from output thread context */
+static void source_output_state_change_cb(pa_source_output *o, pa_source_output_state_t state) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_log_debug("Source output %p state %d", o, state);
+}
+
+/* Called from IO thread context */
+static void sink_input_state_change_cb(pa_sink_input *i, pa_sink_input_state_t state) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_log_debug("Sink input %p state %d", i, state);
+
+ /* If we are added for the first time, ask for a rewinding so that
+ * we are heard right-away. */
+ if (PA_SINK_INPUT_IS_LINKED(state) &&
+ i->thread_info.state == PA_SINK_INPUT_INIT) {
+ pa_log_debug("Requesting rewind due to state change.");
+ pa_sink_input_request_rewind(i, 0, FALSE, TRUE, TRUE);
+ }
+}
+
+/* Called from main thread */
+static void source_output_kill_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ /* The order here matters! We first kill the source output, followed
+ * by the source. That means the source callbacks must be protected
+ * against an unconnected source output! */
+ pa_source_output_unlink(u->source_output);
+ pa_source_unlink(u->source);
+
+ pa_source_output_unref(u->source_output);
+ u->source_output = NULL;
+
+ pa_source_unref(u->source);
+ u->source = NULL;
+
+ pa_log_debug("Source output kill %p", o);
+
+ pa_module_unload_request(u->module, TRUE);
+}
+
+/* Called from main context */
+static void sink_input_kill_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ /* The order here matters! We first kill the sink input, followed
+ * by the sink. That means the sink callbacks must be protected
+ * against an unconnected sink input! */
+ pa_sink_input_unlink(u->sink_input);
+ pa_sink_unlink(u->sink);
+
+ pa_sink_input_unref(u->sink_input);
+ u->sink_input = NULL;
+
+ pa_sink_unref(u->sink);
+ u->sink = NULL;
+
+ pa_log_debug("Sink input kill %p", i);
+
+ pa_module_unload_request(u->module, TRUE);
+}
+
+/* Called from main thread */
+static pa_bool_t source_output_may_move_to_cb(pa_source_output *o, pa_source *dest) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ return (u->source != dest) && (u->sink != dest->monitor_of);
+}
+
+/* Called from main context */
+static pa_bool_t sink_input_may_move_to_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ return u->sink != dest;
+}
+
+/* Called from main thread */
+static void source_output_moving_cb(pa_source_output *o, pa_source *dest) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ if (dest) {
+ pa_source_set_asyncmsgq(u->source, dest->asyncmsgq);
+ pa_source_update_flags(u->source, PA_SOURCE_LATENCY|PA_SOURCE_DYNAMIC_LATENCY, dest->flags);
+ } else
+ pa_source_set_asyncmsgq(u->source, NULL);
+
+ if (u->source_auto_desc && dest) {
+ const char *z;
+ pa_proplist *pl;
+
+ pl = pa_proplist_new();
+ z = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(pl, PA_PROP_DEVICE_DESCRIPTION, "Echo-Cancel Source %s on %s",
+ pa_proplist_gets(u->source->proplist, "device.echo-cancel.name"), z ? z : dest->name);
+
+ pa_source_update_proplist(u->source, PA_UPDATE_REPLACE, pl);
+ pa_proplist_free(pl);
+ }
+}
+
+/* Called from main context */
+static void sink_input_moving_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ if (dest) {
+ pa_sink_set_asyncmsgq(u->sink, dest->asyncmsgq);
+ pa_sink_update_flags(u->sink, PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY, dest->flags);
+ } else
+ pa_sink_set_asyncmsgq(u->sink, NULL);
+
+ if (u->sink_auto_desc && dest) {
+ const char *z;
+ pa_proplist *pl;
+
+ pl = pa_proplist_new();
+ z = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(pl, PA_PROP_DEVICE_DESCRIPTION, "Echo-Cancel Sink %s on %s",
+ pa_proplist_gets(u->sink->proplist, "device.echo-cancel.name"), z ? z : dest->name);
+
+ pa_sink_update_proplist(u->sink, PA_UPDATE_REPLACE, pl);
+ pa_proplist_free(pl);
+ }
+}
+
+/* Called from main context */
+static void sink_input_volume_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_volume_changed(u->sink, &i->volume);
+}
+
+/* Called from main context */
+static void sink_input_mute_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_mute_changed(u->sink, i->muted);
+}
+
+static pa_echo_canceller_method_t get_ec_method_from_string(const char *method) {
+ if (strcmp(method, "speex") == 0)
+ return PA_ECHO_CANCELLER_SPEEX;
+ else if (strcmp(method, "adrian") == 0)
+ return PA_ECHO_CANCELLER_ADRIAN;
+ else
+ return PA_ECHO_CANCELLER_INVALID;
+}
+
+int pa__init(pa_module*m) {
+ struct userdata *u;
+ pa_sample_spec source_ss, sink_ss;
+ pa_channel_map source_map, sink_map;
+ pa_modargs *ma;
+ pa_source *source_master=NULL;
+ pa_sink *sink_master=NULL;
+ pa_source_output_new_data source_output_data;
+ pa_sink_input_new_data sink_input_data;
+ pa_source_new_data source_data;
+ pa_sink_new_data sink_data;
+ pa_memchunk silence;
+ pa_echo_canceller_method_t ec_method;
+ uint32_t adjust_time_sec;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ if (!(source_master = pa_namereg_get(m->core, pa_modargs_get_value(ma, "source_master", NULL), PA_NAMEREG_SOURCE))) {
+ pa_log("Master source not found");
+ goto fail;
+ }
+ pa_assert(source_master);
+
+ if (!(sink_master = pa_namereg_get(m->core, pa_modargs_get_value(ma, "sink_master", NULL), PA_NAMEREG_SINK))) {
+ pa_log("Master sink not found");
+ goto fail;
+ }
+ pa_assert(sink_master);
+
+ source_ss = source_master->sample_spec;
+ source_map = source_master->channel_map;
+ if (pa_modargs_get_sample_spec_and_channel_map(ma, &source_ss, &source_map, PA_CHANNEL_MAP_DEFAULT) < 0) {
+ pa_log("Invalid sample format specification or channel map");
+ goto fail;
+ }
+
+ sink_ss = sink_master->sample_spec;
+ sink_map = sink_master->channel_map;
+
+ u = pa_xnew0(struct userdata, 1);
+ if (!u) {
+ pa_log("Failed to alloc userdata");
+ goto fail;
+ }
+ u->core = m->core;
+ u->module = m;
+ m->userdata = u;
+
+ u->ec = pa_xnew0(pa_echo_canceller, 1);
+ if (!u->ec) {
+ pa_log("Failed to alloc echo canceller");
+ goto fail;
+ }
+
+ if ((ec_method = get_ec_method_from_string(pa_modargs_get_value(ma, "aec_method", DEFAULT_ECHO_CANCELLER))) < 0) {
+ pa_log("Invalid echo canceller implementation");
+ goto fail;
+ }
+
+ u->ec->init = ec_table[ec_method].init;
+ u->ec->run = ec_table[ec_method].run;
+ u->ec->done = ec_table[ec_method].done;
+
+ adjust_time_sec = DEFAULT_ADJUST_TIME_USEC / PA_USEC_PER_SEC;
+ if (pa_modargs_get_value_u32(ma, "adjust_time", &adjust_time_sec) < 0) {
+ pa_log("Failed to parse adjust_time value");
+ goto fail;
+ }
+
+ if (adjust_time_sec != DEFAULT_ADJUST_TIME_USEC / PA_USEC_PER_SEC)
+ u->adjust_time = adjust_time_sec * PA_USEC_PER_SEC;
+ else
+ u->adjust_time = DEFAULT_ADJUST_TIME_USEC;
+
+ u->ec->agc = DEFAULT_AGC_ENABLED;
+ if (pa_modargs_get_value_boolean(ma, "agc", &u->ec->agc) < 0) {
+ pa_log("Failed to parse agc value");
+ goto fail;
+ }
+
+ u->ec->denoise = DEFAULT_DENOISE_ENABLED;
+ if (pa_modargs_get_value_boolean(ma, "denoise", &u->ec->denoise) < 0) {
+ pa_log("Failed to parse denoise value");
+ goto fail;
+ }
+
+ u->ec->echo_suppress = DEFAULT_ECHO_SUPPRESS_ENABLED;
+ if (pa_modargs_get_value_boolean(ma, "echo_suppress", &u->ec->echo_suppress) < 0) {
+ pa_log("Failed to parse echo_suppress value");
+ goto fail;
+ }
+ if (u->ec->echo_suppress && ec_method != PA_ECHO_CANCELLER_SPEEX) {
+ pa_log("Echo suppression is only useful with the speex canceller");
+ goto fail;
+ }
+
+ u->ec->echo_suppress_attenuation = DEFAULT_ECHO_SUPPRESS_ATTENUATION;
+ if (pa_modargs_get_value_s32(ma, "echo_suppress_attenuation", &u->ec->echo_suppress_attenuation) < 0) {
+ pa_log("Failed to parse echo_suppress_attenuation value");
+ goto fail;
+ }
+ if (u->ec->echo_suppress_attenuation > 0) {
+ pa_log("echo_suppress_attenuation should be a negative dB value");
+ goto fail;
+ }
+
+ u->ec->echo_suppress_attenuation_active = DEFAULT_ECHO_SUPPRESS_ATTENUATION;
+ if (pa_modargs_get_value_s32(ma, "echo_suppress_attenuation_active", &u->ec->echo_suppress_attenuation_active) < 0) {
+ pa_log("Failed to parse echo_supress_attenuation_active value");
+ goto fail;
+ }
+ if (u->ec->echo_suppress_attenuation_active > 0) {
+ pa_log("echo_suppress_attenuation_active should be a negative dB value");
+ goto fail;
+ }
+
+ u->save_aec = DEFAULT_SAVE_AEC;
+ if (pa_modargs_get_value_u32(ma, "save_aec", &u->save_aec) < 0) {
+ pa_log("Failed to parse save_aec value");
+ goto fail;
+ }
+
+ u->autoloaded = DEFAULT_AUTOLOADED;
+ if (pa_modargs_get_value_boolean(ma, "autoloaded", &u->autoloaded) < 0) {
+ pa_log("Failed to parse autoloaded value");
+ goto fail;
+ }
+
+ u->asyncmsgq = pa_asyncmsgq_new(0);
+ u->need_realign = TRUE;
+ if (u->ec->init) {
+ if (!u->ec->init(u->core, u->ec, &source_ss, &source_map, &sink_ss, &sink_map, &u->blocksize, pa_modargs_get_value(ma, "aec_args", NULL))) {
+ pa_log("Failed to init AEC engine");
+ goto fail;
+ }
+ }
+
+ if (u->ec->agc || u->ec->denoise || u->ec->echo_suppress) {
+ spx_int32_t tmp;
+
+ if (source_ss.channels != 1) {
+ pa_log("AGC, denoising and echo suppression only work with channels=1");
+ goto fail;
+ }
+
+ u->ec->pp_state = speex_preprocess_state_init(u->blocksize / pa_frame_size(&source_ss), source_ss.rate);
+
+ tmp = u->ec->agc;
+ speex_preprocess_ctl(u->ec->pp_state, SPEEX_PREPROCESS_SET_AGC, &tmp);
+ tmp = u->ec->denoise;
+ speex_preprocess_ctl(u->ec->pp_state, SPEEX_PREPROCESS_SET_DENOISE, &tmp);
+ if (u->ec->echo_suppress) {
+ if (u->ec->echo_suppress_attenuation)
+ speex_preprocess_ctl(u->ec->pp_state, SPEEX_PREPROCESS_SET_ECHO_SUPPRESS, &u->ec->echo_suppress_attenuation);
+ if (u->ec->echo_suppress_attenuation_active) {
+ speex_preprocess_ctl(u->ec->pp_state, SPEEX_PREPROCESS_SET_ECHO_SUPPRESS_ACTIVE,
+ &u->ec->echo_suppress_attenuation_active);
+ }
+ speex_preprocess_ctl(u->ec->pp_state, SPEEX_PREPROCESS_SET_ECHO_STATE, u->ec->params.priv.speex.state);
+ }
+ }
+
+ /* Create source */
+ pa_source_new_data_init(&source_data);
+ source_data.driver = __FILE__;
+ source_data.module = m;
+ if (!(source_data.name = pa_xstrdup(pa_modargs_get_value(ma, "source_name", NULL))))
+ source_data.name = pa_sprintf_malloc("%s.echo-cancel", source_master->name);
+ pa_source_new_data_set_sample_spec(&source_data, &source_ss);
+ pa_source_new_data_set_channel_map(&source_data, &source_map);
+ pa_proplist_sets(source_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, source_master->name);
+ pa_proplist_sets(source_data.proplist, PA_PROP_DEVICE_CLASS, "filter");
+ if (!u->autoloaded)
+ pa_proplist_sets(source_data.proplist, PA_PROP_DEVICE_INTENDED_ROLES, "phone");
+ pa_proplist_sets(source_data.proplist, "device.echo-cancel.name", source_data.name);
+
+ if (pa_modargs_get_proplist(ma, "source_properties", source_data.proplist, PA_UPDATE_REPLACE) < 0) {
+ pa_log("Invalid properties");
+ pa_source_new_data_done(&source_data);
+ goto fail;
+ }
+
+ if ((u->source_auto_desc = !pa_proplist_contains(source_data.proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ const char *z;
+
+ z = pa_proplist_gets(source_master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(source_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Echo-Cancel Source %s on %s", source_data.name, z ? z : source_master->name);
+ }
+
+ u->source = pa_source_new(m->core, &source_data,
+ PA_SOURCE_HW_MUTE_CTRL|PA_SOURCE_HW_VOLUME_CTRL|PA_SOURCE_DECIBEL_VOLUME|
+ (source_master->flags & (PA_SOURCE_LATENCY|PA_SOURCE_DYNAMIC_LATENCY)));
+ pa_source_new_data_done(&source_data);
+
+ if (!u->source) {
+ pa_log("Failed to create source.");
+ goto fail;
+ }
+
+ u->source->parent.process_msg = source_process_msg_cb;
+ u->source->set_state = source_set_state_cb;
+ u->source->update_requested_latency = source_update_requested_latency_cb;
+ u->source->set_volume = source_set_volume_cb;
+ u->source->set_mute = source_set_mute_cb;
+ u->source->get_volume = source_get_volume_cb;
+ u->source->get_mute = source_get_mute_cb;
+ u->source->userdata = u;
+
+ pa_source_set_asyncmsgq(u->source, source_master->asyncmsgq);
+
+ /* Create sink */
+ pa_sink_new_data_init(&sink_data);
+ sink_data.driver = __FILE__;
+ sink_data.module = m;
+ if (!(sink_data.name = pa_xstrdup(pa_modargs_get_value(ma, "sink_name", NULL))))
+ sink_data.name = pa_sprintf_malloc("%s.echo-cancel", sink_master->name);
+ pa_sink_new_data_set_sample_spec(&sink_data, &sink_ss);
+ pa_sink_new_data_set_channel_map(&sink_data, &sink_map);
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, sink_master->name);
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_CLASS, "filter");
+ if (!u->autoloaded)
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_INTENDED_ROLES, "phone");
+ pa_proplist_sets(sink_data.proplist, "device.echo-cancel.name", sink_data.name);
+
+ if (pa_modargs_get_proplist(ma, "sink_properties", sink_data.proplist, PA_UPDATE_REPLACE) < 0) {
+ pa_log("Invalid properties");
+ pa_sink_new_data_done(&sink_data);
+ goto fail;
+ }
+
+ if ((u->sink_auto_desc = !pa_proplist_contains(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ const char *z;
+
+ z = pa_proplist_gets(sink_master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Echo-Cancel Sink %s on %s", sink_data.name, z ? z : sink_master->name);
+ }
+
+ u->sink = pa_sink_new(m->core, &sink_data,
+ PA_SINK_HW_MUTE_CTRL|PA_SINK_HW_VOLUME_CTRL|PA_SINK_DECIBEL_VOLUME|
+ (sink_master->flags & (PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY)));
+ pa_sink_new_data_done(&sink_data);
+
+ if (!u->sink) {
+ pa_log("Failed to create sink.");
+ goto fail;
+ }
+
+ u->sink->parent.process_msg = sink_process_msg_cb;
+ u->sink->set_state = sink_set_state_cb;
+ u->sink->update_requested_latency = sink_update_requested_latency_cb;
+ u->sink->request_rewind = sink_request_rewind_cb;
+ u->sink->set_volume = sink_set_volume_cb;
+ u->sink->set_mute = sink_set_mute_cb;
+ u->sink->userdata = u;
+
+ pa_sink_set_asyncmsgq(u->sink, sink_master->asyncmsgq);
+
+ /* Create source output */
+ pa_source_output_new_data_init(&source_output_data);
+ source_output_data.driver = __FILE__;
+ source_output_data.module = m;
+ pa_source_output_new_data_set_source(&source_output_data, source_master, FALSE);
+ source_output_data.destination_source = u->source;
+ /* FIXME
+ source_output_data.flags = PA_SOURCE_OUTPUT_DONT_INHIBIT_AUTO_SUSPEND; */
+
+ pa_proplist_sets(source_output_data.proplist, PA_PROP_MEDIA_NAME, "Echo-Cancel Source Stream");
+ pa_proplist_sets(source_output_data.proplist, PA_PROP_MEDIA_ROLE, "filter");
+ pa_source_output_new_data_set_sample_spec(&source_output_data, &source_ss);
+ pa_source_output_new_data_set_channel_map(&source_output_data, &source_map);
+
+ pa_source_output_new(&u->source_output, m->core, &source_output_data);
+ pa_source_output_new_data_done(&source_output_data);
+
+ if (!u->source_output)
+ goto fail;
+
+ u->source_output->parent.process_msg = source_output_process_msg_cb;
+ u->source_output->push = source_output_push_cb;
+ u->source_output->process_rewind = source_output_process_rewind_cb;
+ u->source_output->update_max_rewind = source_output_update_max_rewind_cb;
+ u->source_output->update_source_requested_latency = source_output_update_source_requested_latency_cb;
+ u->source_output->update_source_latency_range = source_output_update_source_latency_range_cb;
+ u->source_output->update_source_fixed_latency = source_output_update_source_fixed_latency_cb;
+ u->source_output->kill = source_output_kill_cb;
+ u->source_output->attach = source_output_attach_cb;
+ u->source_output->detach = source_output_detach_cb;
+ u->source_output->state_change = source_output_state_change_cb;
+ u->source_output->may_move_to = source_output_may_move_to_cb;
+ u->source_output->moving = source_output_moving_cb;
+ u->source_output->userdata = u;
+
+ u->source->output_from_master = u->source_output;
+
+ /* Create sink input */
+ pa_sink_input_new_data_init(&sink_input_data);
+ sink_input_data.driver = __FILE__;
+ sink_input_data.module = m;
+ pa_sink_input_new_data_set_sink(&sink_input_data, sink_master, FALSE);
+ sink_input_data.origin_sink = u->sink;
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_NAME, "Echo-Cancel Sink Stream");
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ROLE, "filter");
+ pa_sink_input_new_data_set_sample_spec(&sink_input_data, &sink_ss);
+ pa_sink_input_new_data_set_channel_map(&sink_input_data, &sink_map);
+ sink_input_data.flags = PA_SINK_INPUT_VARIABLE_RATE;
+
+ pa_sink_input_new(&u->sink_input, m->core, &sink_input_data);
+ pa_sink_input_new_data_done(&sink_input_data);
+
+ if (!u->sink_input)
+ goto fail;
+
+ u->sink_input->parent.process_msg = sink_input_process_msg_cb;
+ u->sink_input->pop = sink_input_pop_cb;
+ u->sink_input->process_rewind = sink_input_process_rewind_cb;
+ u->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
+ u->sink_input->update_max_request = sink_input_update_max_request_cb;
+ u->sink_input->update_sink_requested_latency = sink_input_update_sink_requested_latency_cb;
+ u->sink_input->update_sink_latency_range = sink_input_update_sink_latency_range_cb;
+ u->sink_input->update_sink_fixed_latency = sink_input_update_sink_fixed_latency_cb;
+ u->sink_input->kill = sink_input_kill_cb;
+ u->sink_input->attach = sink_input_attach_cb;
+ u->sink_input->detach = sink_input_detach_cb;
+ u->sink_input->state_change = sink_input_state_change_cb;
+ u->sink_input->may_move_to = sink_input_may_move_to_cb;
+ u->sink_input->moving = sink_input_moving_cb;
+ u->sink_input->volume_changed = sink_input_volume_changed_cb;
+ u->sink_input->mute_changed = sink_input_mute_changed_cb;
+ u->sink_input->userdata = u;
+
+ u->sink->input_to_master = u->sink_input;
+
+ pa_sink_input_get_silence(u->sink_input, &silence);
+
+ u->source_memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0,
+ pa_frame_size(&source_ss), 1, 1, 0, &silence);
+ u->sink_memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0,
+ pa_frame_size(&sink_ss), 1, 1, 0, &silence);
+
+ pa_memblock_unref(silence.memblock);
+
+ if (!u->source_memblockq || !u->sink_memblockq) {
+ pa_log("Failed to create memblockq.");
+ goto fail;
+ }
+
+ /* our source and sink are not suspended when we create them */
+ u->active_mask = 3;
+
+ if (u->adjust_time > 0)
+ u->time_event = pa_core_rttime_new(m->core, pa_rtclock_now() + u->adjust_time, time_callback, u);
+
+ if (u->save_aec) {
+ pa_log("Creating AEC files in /tmp");
+ u->captured_file = fopen("/tmp/aec_rec.sw", "wb");
+ if (u->captured_file == NULL)
+ perror ("fopen failed");
+ u->played_file = fopen("/tmp/aec_play.sw", "wb");
+ if (u->played_file == NULL)
+ perror ("fopen failed");
+ u->canceled_file = fopen("/tmp/aec_out.sw", "wb");
+ if (u->canceled_file == NULL)
+ perror ("fopen failed");
+ }
+
+ pa_sink_put(u->sink);
+ pa_source_put(u->source);
+
+ pa_sink_input_put(u->sink_input);
+ pa_source_output_put(u->source_output);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+int pa__get_n_used(pa_module *m) {
+ struct userdata *u;
+
+ pa_assert(m);
+ pa_assert_se(u = m->userdata);
+
+ return pa_sink_linked_by(u->sink) + pa_source_linked_by(u->source);
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ /* See comments in source_output_kill_cb() above regarding
+ * destruction order! */
+
+ if (u->time_event)
+ u->core->mainloop->time_free(u->time_event);
+
+ if (u->source_output)
+ pa_source_output_unlink(u->source_output);
+ if (u->sink_input)
+ pa_sink_input_unlink(u->sink_input);
+
+ if (u->source)
+ pa_source_unlink(u->source);
+ if (u->sink)
+ pa_sink_unlink(u->sink);
+
+ if (u->source_output)
+ pa_source_output_unref(u->source_output);
+ if (u->sink_input)
+ pa_sink_input_unref(u->sink_input);
+
+ if (u->source)
+ pa_source_unref(u->source);
+ if (u->sink)
+ pa_sink_unref(u->sink);
+
+ if (u->source_memblockq)
+ pa_memblockq_free(u->source_memblockq);
+ if (u->sink_memblockq)
+ pa_memblockq_free(u->sink_memblockq);
+
+ if (u->ec->pp_state)
+ speex_preprocess_state_destroy(u->ec->pp_state);
+
+ if (u->ec) {
+ if (u->ec->done)
+ u->ec->done(u->ec);
+
+ pa_xfree(u->ec);
+ }
+
+ if (u->asyncmsgq)
+ pa_asyncmsgq_unref(u->asyncmsgq);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/echo-cancel/speex.c b/src/modules/echo-cancel/speex.c
new file mode 100644
index 00000000..72c52680
--- /dev/null
+++ b/src/modules/echo-cancel/speex.c
@@ -0,0 +1,115 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Wim Taymans <wim.taymans@gmail.com>
+
+ Contributor: Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulsecore/modargs.h>
+#include "echo-cancel.h"
+
+/* should be between 10-20 ms */
+#define DEFAULT_FRAME_SIZE_MS 20
+/* should be between 100-500 ms */
+#define DEFAULT_FILTER_SIZE_MS 200
+
+static const char* const valid_modargs[] = {
+ "frame_size_ms",
+ "filter_size_ms",
+ NULL
+};
+
+static void pa_speex_ec_fixate_spec(pa_sample_spec *source_ss, pa_channel_map *source_map,
+ pa_sample_spec *sink_ss, pa_channel_map *sink_map)
+{
+ source_ss->format = PA_SAMPLE_S16NE;
+
+ *sink_ss = *source_ss;
+ *sink_map = *source_map;
+}
+
+pa_bool_t pa_speex_ec_init(pa_core *c, pa_echo_canceller *ec,
+ pa_sample_spec *source_ss, pa_channel_map *source_map,
+ pa_sample_spec *sink_ss, pa_channel_map *sink_map,
+ uint32_t *blocksize, const char *args)
+{
+ int framelen, y, rate;
+ uint32_t frame_size_ms, filter_size_ms;
+ pa_modargs *ma;
+
+ if (!(ma = pa_modargs_new(args, valid_modargs))) {
+ pa_log("Failed to parse submodule arguments.");
+ goto fail;
+ }
+
+ filter_size_ms = DEFAULT_FILTER_SIZE_MS;
+ if (pa_modargs_get_value_u32(ma, "filter_size_ms", &filter_size_ms) < 0 || filter_size_ms < 1 || filter_size_ms > 2000) {
+ pa_log("Invalid filter_size_ms specification");
+ goto fail;
+ }
+
+ frame_size_ms = DEFAULT_FRAME_SIZE_MS;
+ if (pa_modargs_get_value_u32(ma, "frame_size_ms", &frame_size_ms) < 0 || frame_size_ms < 1 || frame_size_ms > 200) {
+ pa_log("Invalid frame_size_ms specification");
+ goto fail;
+ }
+
+ pa_speex_ec_fixate_spec(source_ss, source_map, sink_ss, sink_map);
+
+ rate = source_ss->rate;
+ framelen = (rate * frame_size_ms) / 1000;
+ /* framelen should be a power of 2, round down to nearest power of two */
+ y = 1 << ((8 * sizeof (int)) - 2);
+ while (y > framelen)
+ y >>= 1;
+ framelen = y;
+
+ *blocksize = framelen * pa_frame_size (source_ss);
+
+ pa_log_debug ("Using framelen %d, blocksize %u, channels %d, rate %d", framelen, *blocksize, source_ss->channels, source_ss->rate);
+
+ ec->params.priv.speex.state = speex_echo_state_init_mc (framelen, (rate * filter_size_ms) / 1000, source_ss->channels, source_ss->channels);
+
+ if (!ec->params.priv.speex.state)
+ goto fail;
+
+ speex_echo_ctl(ec->params.priv.speex.state, SPEEX_ECHO_SET_SAMPLING_RATE, &rate);
+
+ pa_modargs_free(ma);
+ return TRUE;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+ return FALSE;
+}
+
+void pa_speex_ec_run(pa_echo_canceller *ec, const uint8_t *rec, const uint8_t *play, uint8_t *out) {
+ speex_echo_cancellation(ec->params.priv.speex.state, (const spx_int16_t *) rec, (const spx_int16_t *) play, (spx_int16_t *) out);
+}
+
+void pa_speex_ec_done(pa_echo_canceller *ec) {
+ if (ec->params.priv.speex.state)
+ speex_echo_state_destroy(ec->params.priv.speex.state);
+ ec->params.priv.speex.state = NULL;
+}
diff --git a/src/modules/gconf/Makefile b/src/modules/gconf/Makefile
deleted file mode 120000
index efe5a336..00000000
--- a/src/modules/gconf/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../../pulse/Makefile \ No newline at end of file
diff --git a/src/modules/gconf/module-gconf.c b/src/modules/gconf/module-gconf.c
index c01ebbf6..3bad9113 100644
--- a/src/modules/gconf/module-gconf.c
+++ b/src/modules/gconf/module-gconf.c
@@ -30,12 +30,10 @@
#include <signal.h>
#include <sys/types.h>
#include <sys/wait.h>
-#include <fcntl.h>
#include <pulse/xmalloc.h>
#include <pulsecore/module.h>
#include <pulsecore/core.h>
-#include <pulsecore/llist.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulse/mainloop-api.h>
@@ -52,9 +50,6 @@ PA_MODULE_LOAD_ONCE(TRUE);
#define MAX_MODULES 10
#define BUF_MAX 2048
-/* #undef PA_GCONF_HELPER */
-/* #define PA_GCONF_HELPER "/home/lennart/projects/pulseaudio/src/gconf-helper" */
-
struct module_item {
char *name;
char *args;
@@ -343,7 +338,11 @@ int pa__init(pa_module*m) {
u->io_event = NULL;
u->buf_fill = 0;
- if ((u->fd = pa_start_child_for_read(PA_GCONF_HELPER, NULL, &u->pid)) < 0)
+ if ((u->fd = pa_start_child_for_read(
+#if defined(__linux__) && !defined(__OPTIMIZE__)
+ pa_run_from_build_tree() ? PA_BUILDDIR "/gconf-helper" :
+#endif
+ PA_GCONF_HELPER, NULL, &u->pid)) < 0)
goto fail;
u->io_event = m->core->mainloop->io_new(
diff --git a/src/modules/hal-util.c b/src/modules/hal-util.c
index e2a2d8d7..2d59f51d 100644
--- a/src/modules/hal-util.c
+++ b/src/modules/hal-util.c
@@ -65,7 +65,7 @@ int pa_hal_get_info(pa_core *core, pa_proplist *p, int card) {
goto finish;
}
- if (!(udis = libhal_find_device_by_capability(hal, "sound", &n, &error)) < 0) {
+ if (!(udis = libhal_find_device_by_capability(hal, "sound", &n, &error))) {
pa_log_error("Couldn't find devices: %s: %s", error.name, error.message);
goto finish;
}
diff --git a/src/modules/jack/module-jack-sink.c b/src/modules/jack/module-jack-sink.c
index 290038e7..35b0385d 100644
--- a/src/modules/jack/module-jack-sink.c
+++ b/src/modules/jack/module-jack-sink.c
@@ -24,19 +24,15 @@
#endif
#include <stdlib.h>
-#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
#include <string.h>
-#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
#include <jack/jack.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/sink.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
@@ -68,7 +64,7 @@ PA_MODULE_LOAD_ONCE(TRUE);
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_USAGE(
"sink_name=<name for the sink> "
- "sink_properties=<properties for the card> "
+ "sink_properties=<properties for the card> "
"server_name=<jack server name> "
"client_name=<jack client name> "
"channels=<number of channels> "
@@ -147,6 +143,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
pa_sample_spec ss;
/* Humm, we're not RUNNING, hence let's write some silence */
+ /* This can happen if we're paused, or during shutdown (when we're unlinked but jack is still running). */
ss = u->sink->sample_spec;
ss.channels = 1;
@@ -197,6 +194,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
return pa_sink_process_msg(o, code, data, offset, memchunk);
}
+/* JACK Callback: This is called when JACK needs some data */
static int jack_process(jack_nframes_t nframes, void *arg) {
struct userdata *u = arg;
unsigned c;
@@ -225,7 +223,6 @@ static void thread_func(void *userdata) {
pa_make_realtime(u->core->realtime_priority);
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
int ret;
@@ -251,6 +248,7 @@ finish:
pa_log_debug("Thread shutting down");
}
+/* JACK Callback: This is called when JACK triggers an error */
static void jack_error_func(const char*t) {
char *s;
@@ -259,6 +257,7 @@ static void jack_error_func(const char*t) {
pa_xfree(s);
}
+/* JACK Callback: This is called when JACK is set up */
static void jack_init(void *arg) {
struct userdata *u = arg;
@@ -268,6 +267,7 @@ static void jack_init(void *arg) {
pa_make_realtime(u->core->realtime_priority+4);
}
+/* JACK Callback: This is called when JACK kicks us */
static void jack_shutdown(void* arg) {
struct userdata *u = arg;
@@ -275,6 +275,7 @@ static void jack_shutdown(void* arg) {
pa_asyncmsgq_post(u->jack_msgq, PA_MSGOBJECT(u->sink), SINK_MESSAGE_ON_SHUTDOWN, NULL, 0, NULL, NULL);
}
+/* JACK Callback: This is called when JACK changes the buffer size */
static int jack_buffer_size(jack_nframes_t nframes, void *arg) {
struct userdata *u = arg;
@@ -335,11 +336,12 @@ int pa__init(pa_module*m) {
goto fail;
}
- ports = jack_get_ports(u->client, NULL, NULL, JackPortIsPhysical|JackPortIsInput);
+ ports = jack_get_ports(u->client, NULL, JACK_DEFAULT_AUDIO_TYPE, JackPortIsPhysical|JackPortIsInput);
channels = 0;
- for (p = ports; *p; p++)
- channels++;
+ if (ports)
+ for (p = ports; *p; p++)
+ channels++;
if (!channels)
channels = m->core->default_sample_spec.channels;
@@ -414,7 +416,7 @@ int pa__init(pa_module*m) {
jack_set_thread_init_callback(u->client, jack_init, u);
jack_set_buffer_size_callback(u->client, jack_buffer_size, u);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("jack-sink", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
@@ -427,7 +429,7 @@ int pa__init(pa_module*m) {
if (do_connect) {
for (i = 0, p = ports; i < ss.channels; i++, p++) {
- if (!*p) {
+ if (!p || !*p) {
pa_log("Not enough physical output ports, leaving unconnected.");
break;
}
@@ -443,7 +445,8 @@ int pa__init(pa_module*m) {
pa_sink_put(u->sink);
- free(ports);
+ if (ports)
+ jack_free(ports);
pa_modargs_free(ma);
return 0;
@@ -452,7 +455,8 @@ fail:
if (ma)
pa_modargs_free(ma);
- free(ports);
+ if (ports)
+ jack_free(ports);
pa__done(m);
@@ -476,12 +480,12 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
- if (u->client)
- jack_client_close(u->client);
-
if (u->sink)
pa_sink_unlink(u->sink);
+ if (u->client)
+ jack_client_close(u->client);
+
if (u->thread) {
pa_asyncmsgq_send(u->thread_mq.inq, NULL, PA_MESSAGE_SHUTDOWN, NULL, 0, NULL);
pa_thread_free(u->thread);
diff --git a/src/modules/jack/module-jack-source.c b/src/modules/jack/module-jack-source.c
index ef89a98e..13109f3e 100644
--- a/src/modules/jack/module-jack-source.c
+++ b/src/modules/jack/module-jack-source.c
@@ -24,19 +24,15 @@
#endif
#include <stdlib.h>
-#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
#include <string.h>
-#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
#include <jack/jack.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/source.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
@@ -196,7 +192,6 @@ static void thread_func(void *userdata) {
pa_make_realtime(u->core->realtime_priority);
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
int ret;
@@ -287,11 +282,12 @@ int pa__init(pa_module*m) {
goto fail;
}
- ports = jack_get_ports(u->client, NULL, NULL, JackPortIsPhysical|JackPortIsOutput);
+ ports = jack_get_ports(u->client, NULL, JACK_DEFAULT_AUDIO_TYPE, JackPortIsPhysical|JackPortIsOutput);
channels = 0;
- for (p = ports; *p; p++)
- channels++;
+ if (ports)
+ for (p = ports; *p; p++)
+ channels++;
if (!channels)
channels = m->core->default_sample_spec.channels;
@@ -364,7 +360,7 @@ int pa__init(pa_module*m) {
jack_on_shutdown(u->client, jack_shutdown, u);
jack_set_thread_init_callback(u->client, jack_init, u);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("jack-source", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
@@ -377,7 +373,7 @@ int pa__init(pa_module*m) {
if (do_connect) {
for (i = 0, p = ports; i < ss.channels; i++, p++) {
- if (!*p) {
+ if (!p || !*p) {
pa_log("Not enough physical output ports, leaving unconnected.");
break;
}
@@ -394,7 +390,8 @@ int pa__init(pa_module*m) {
pa_source_put(u->source);
- free(ports);
+ if (ports)
+ jack_free(ports);
pa_modargs_free(ma);
return 0;
@@ -403,7 +400,8 @@ fail:
if (ma)
pa_modargs_free(ma);
- free(ports);
+ if (ports)
+ jack_free(ports);
pa__done(m);
@@ -426,12 +424,12 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
- if (u->client)
- jack_client_close(u->client);
-
if (u->source)
pa_source_unlink(u->source);
+ if (u->client)
+ jack_client_close(u->client);
+
if (u->thread) {
pa_asyncmsgq_send(u->thread_mq.inq, NULL, PA_MESSAGE_SHUTDOWN, NULL, 0, NULL);
pa_thread_free(u->thread);
diff --git a/src/modules/jack/module-jackdbus-detect.c b/src/modules/jack/module-jackdbus-detect.c
new file mode 100644
index 00000000..864f96b1
--- /dev/null
+++ b/src/modules/jack/module-jackdbus-detect.c
@@ -0,0 +1,298 @@
+/***
+ This file is part of PulseAudio.
+
+ Written by David Henningsson <david.henningsson@canonical.com>
+ Copyright 2010 Canonical Ltd.
+
+ Some code taken from other parts of PulseAudio, these are
+ Copyright 2006-2009 Lennart Poettering
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/log.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-shared.h>
+
+#include "module-jackdbus-detect-symdef.h"
+
+PA_MODULE_AUTHOR("David Henningsson");
+PA_MODULE_DESCRIPTION("Adds JACK sink/source ports when JACK is started");
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_USAGE("connect=<connect ports?>");
+
+#define JACK_SERVICE_NAME "org.jackaudio.service"
+#define JACK_INTERFACE_NAME "org.jackaudio.JackControl"
+#define JACK_INTERFACE_PATH "/org/jackaudio/Controller"
+
+#define SERVICE_FILTER \
+ "type='signal'," \
+ "sender='" DBUS_SERVICE_DBUS "'," \
+ "interface='" DBUS_INTERFACE_DBUS "'," \
+ "member='NameOwnerChanged'," \
+ "arg0='" JACK_SERVICE_NAME "'"
+
+#define RUNNING_FILTER(_a) \
+ "type='signal'," \
+ "sender='" JACK_SERVICE_NAME "'," \
+ "interface='" JACK_INTERFACE_NAME "'," \
+ "member='" _a "'"
+
+static const char* const valid_modargs[] = {
+ "connect",
+ NULL
+};
+
+#define JACK_SS_SINK 0
+#define JACK_SS_SOURCE 1
+#define JACK_SS_COUNT 2
+
+static const char* const modnames[JACK_SS_COUNT] = {
+ "module-jack-sink",
+ "module-jack-source"
+};
+
+
+struct userdata {
+ pa_module *module;
+ pa_core *core;
+ pa_dbus_connection *connection;
+ pa_bool_t filter_added, match_added;
+ pa_bool_t is_service_started;
+ pa_bool_t autoconnect_ports;
+ /* Using index here protects us from module unloading without us knowing */
+ int jack_module_index[JACK_SS_COUNT];
+};
+
+
+static void ensure_ports_stopped(struct userdata* u) {
+ int i;
+ pa_assert(u);
+
+ for (i = 0; i < JACK_SS_COUNT; i++)
+ if (u->jack_module_index[i]) {
+ pa_module_unload_request_by_index(u->core, u->jack_module_index[i], TRUE);
+ u->jack_module_index[i] = 0;
+ pa_log_info("Stopped %s.", modnames[i]);
+ }
+}
+
+static void ensure_ports_started(struct userdata* u) {
+ int i;
+ pa_assert(u);
+
+ for (i = 0; i < JACK_SS_COUNT; i++)
+ if (!u->jack_module_index[i]) {
+ char* args;
+ pa_module* m;
+ args = pa_sprintf_malloc("connect=%s", pa_yes_no(u->autoconnect_ports));
+ m = pa_module_load(u->core, modnames[i], args);
+ pa_xfree(args);
+
+ if (m) {
+ pa_log_info("Successfully started %s.", modnames[i]);
+ u->jack_module_index[i] = m->index;
+ }
+ else
+ pa_log_info("Failed to start %s.", modnames[i]);
+ }
+}
+
+
+static pa_bool_t check_service_started(struct userdata* u) {
+ DBusError error;
+ DBusMessage *m = NULL, *reply = NULL;
+ pa_bool_t new_status = FALSE;
+ dbus_bool_t call_result;
+ pa_assert(u);
+
+ dbus_error_init(&error);
+
+ /* Just a safety check; it isn't such a big deal if the name disappears just after the call. */
+ if (!dbus_bus_name_has_owner(pa_dbus_connection_get(u->connection),
+ JACK_SERVICE_NAME, &error)) {
+ pa_log_debug("jackdbus isn't running.");
+ goto finish;
+ }
+
+ if (!(m = dbus_message_new_method_call(JACK_SERVICE_NAME, JACK_INTERFACE_PATH, JACK_INTERFACE_NAME, "IsStarted"))) {
+ pa_log("Failed to allocate IsStarted() method call.");
+ goto finish;
+ }
+
+ if (!(reply = dbus_connection_send_with_reply_and_block(pa_dbus_connection_get(u->connection), m, -1, &error))) {
+ pa_log("IsStarted() call failed: %s: %s", error.name, error.message);
+ goto finish;
+ }
+
+ if (!dbus_message_get_args(reply, &error, DBUS_TYPE_BOOLEAN, &call_result, DBUS_TYPE_INVALID)) {
+ pa_log("IsStarted() call return failed: %s: %s", error.name, error.message);
+ goto finish;
+ }
+
+ new_status = call_result;
+
+finish:
+ if (m)
+ dbus_message_unref(m);
+ if (reply)
+ dbus_message_unref(reply);
+
+ dbus_error_free(&error);
+ if (new_status)
+ ensure_ports_started(u);
+ else
+ ensure_ports_stopped(u);
+ u->is_service_started = new_status;
+ return new_status;
+}
+
+static DBusHandlerResult dbus_filter_handler(DBusConnection *c, DBusMessage *s, void *userdata) {
+ struct userdata *u = NULL;
+ DBusError error;
+
+ pa_assert(userdata);
+ u = ((pa_module*) userdata)->userdata;
+ pa_assert(u);
+
+ dbus_error_init(&error);
+
+ if (dbus_message_is_signal(s, DBUS_INTERFACE_DBUS, "NameOwnerChanged")) {
+ const char *name, *old, *new;
+ if (!dbus_message_get_args(s, &error,
+ DBUS_TYPE_STRING, &name,
+ DBUS_TYPE_STRING, &old,
+ DBUS_TYPE_STRING, &new,
+ DBUS_TYPE_INVALID))
+ goto finish;
+ if (strcmp(name, JACK_SERVICE_NAME))
+ goto finish;
+
+ ensure_ports_stopped(u);
+ check_service_started(u);
+ }
+
+ else if (dbus_message_is_signal(s, JACK_INTERFACE_NAME, "ServerStarted")) {
+ ensure_ports_stopped(u);
+ check_service_started(u);
+ }
+
+ else if (dbus_message_is_signal(s, JACK_INTERFACE_NAME, "ServerStopped")) {
+ ensure_ports_stopped(u);
+ }
+
+finish:
+ dbus_error_free(&error);
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+}
+
+int pa__init(pa_module *m) {
+ DBusError error;
+ pa_dbus_connection *connection = NULL;
+ struct userdata *u = NULL;
+ pa_modargs *ma;
+
+ pa_assert(m);
+
+ dbus_error_init(&error);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->module = m;
+ u->autoconnect_ports = TRUE;
+
+ if (pa_modargs_get_value_boolean(ma, "connect", &u->autoconnect_ports) < 0) {
+ pa_log("Failed to parse connect= argument.");
+ goto fail;
+ }
+
+ if (!(connection = pa_dbus_bus_get(m->core, DBUS_BUS_SESSION, &error)) || dbus_error_is_set(&error)) {
+
+ if (connection)
+ pa_dbus_connection_unref(connection);
+
+ pa_log_error("Unable to contact D-Bus session bus: %s: %s", error.name, error.message);
+ goto fail;
+ }
+ u->connection = connection;
+
+ if (!dbus_connection_add_filter(pa_dbus_connection_get(connection), dbus_filter_handler, m, NULL)) {
+ pa_log_error("Unable to add D-Bus filter");
+ goto fail;
+ }
+ u->filter_added = 1;
+
+ if (pa_dbus_add_matches(
+ pa_dbus_connection_get(connection), &error, SERVICE_FILTER,
+ RUNNING_FILTER("ServerStarted"), RUNNING_FILTER("ServerStopped"), NULL) < 0) {
+ pa_log_error("Unable to subscribe to signals: %s: %s", error.name, error.message);
+ goto fail;
+ }
+ u->match_added = 1;
+
+ check_service_started(u);
+
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ dbus_error_free(&error);
+ pa__done(m);
+
+ return -1;
+}
+
+void pa__done(pa_module *m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ ensure_ports_stopped(u);
+
+ if (u->match_added) {
+ pa_dbus_remove_matches(
+ pa_dbus_connection_get(u->connection), SERVICE_FILTER,
+ RUNNING_FILTER("ServerStarted"), RUNNING_FILTER("ServerStopped"), NULL);
+ }
+
+ if (u->filter_added) {
+ dbus_connection_remove_filter(pa_dbus_connection_get(u->connection), dbus_filter_handler, m);
+ }
+
+ if (u->connection) {
+ pa_dbus_connection_unref(u->connection);
+ }
+
+ pa_xfree(u);
+}
diff --git a/src/modules/macosx/module-bonjour-publish.c b/src/modules/macosx/module-bonjour-publish.c
new file mode 100644
index 00000000..667b6b73
--- /dev/null
+++ b/src/modules/macosx/module-bonjour-publish.c
@@ -0,0 +1,513 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Daniel Mack
+ based on module-zeroconf-publish.c
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of the
+ License, or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <dns_sd.h>
+
+#include <CoreFoundation/CoreFoundation.h>
+
+#include <pulse/xmalloc.h>
+#include <pulse/util.h>
+
+#include <pulsecore/parseaddr.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/source.h>
+#include <pulsecore/native-common.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/log.h>
+#include <pulsecore/dynarray.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/protocol-native.h>
+
+#include "module-bonjour-publish-symdef.h"
+
+PA_MODULE_AUTHOR("Daniel Mack");
+PA_MODULE_DESCRIPTION("Mac OS X Bonjour Service Publisher");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+
+#define SERVICE_TYPE_SINK "_pulse-sink._tcp"
+#define SERVICE_TYPE_SOURCE "_pulse-source._tcp"
+#define SERVICE_TYPE_SERVER "_pulse-server._tcp"
+
+static const char* const valid_modargs[] = {
+ NULL
+};
+
+enum service_subtype {
+ SUBTYPE_HARDWARE,
+ SUBTYPE_VIRTUAL,
+ SUBTYPE_MONITOR
+};
+
+struct service {
+ struct userdata *userdata;
+ DNSServiceRef service;
+ DNSRecordRef rec, rec2;
+ char *service_name;
+ pa_object *device;
+ enum service_subtype subtype;
+};
+
+struct userdata {
+ pa_core *core;
+ pa_module *module;
+
+ pa_hashmap *services;
+ char *service_name;
+
+ pa_hook_slot *sink_new_slot, *source_new_slot, *sink_unlink_slot, *source_unlink_slot, *sink_changed_slot, *source_changed_slot;
+
+ pa_native_protocol *native;
+ DNSServiceRef main_service;
+};
+
+static void get_service_data(struct service *s, pa_sample_spec *ret_ss, pa_channel_map *ret_map, const char **ret_name, pa_proplist **ret_proplist, enum service_subtype *ret_subtype) {
+ pa_assert(s);
+ pa_assert(ret_ss);
+ pa_assert(ret_proplist);
+ pa_assert(ret_subtype);
+
+ if (pa_sink_isinstance(s->device)) {
+ pa_sink *sink = PA_SINK(s->device);
+
+ *ret_ss = sink->sample_spec;
+ *ret_map = sink->channel_map;
+ *ret_name = sink->name;
+ *ret_proplist = sink->proplist;
+ *ret_subtype = sink->flags & PA_SINK_HARDWARE ? SUBTYPE_HARDWARE : SUBTYPE_VIRTUAL;
+
+ } else if (pa_source_isinstance(s->device)) {
+ pa_source *source = PA_SOURCE(s->device);
+
+ *ret_ss = source->sample_spec;
+ *ret_map = source->channel_map;
+ *ret_name = source->name;
+ *ret_proplist = source->proplist;
+ *ret_subtype = source->monitor_of ? SUBTYPE_MONITOR : (source->flags & PA_SOURCE_HARDWARE ? SUBTYPE_HARDWARE : SUBTYPE_VIRTUAL);
+
+ } else
+ pa_assert_not_reached();
+}
+
+static void txt_record_server_data(pa_core *c, TXTRecordRef *txt) {
+ char s[128];
+ char *t;
+
+ pa_assert(c);
+
+ TXTRecordSetValue(txt, "server-version", strlen(PACKAGE_NAME" "PACKAGE_VERSION), PACKAGE_NAME" "PACKAGE_VERSION);
+
+ t = pa_get_user_name_malloc();
+ TXTRecordSetValue(txt, "user-name", strlen(t), t);
+ pa_xfree(t);
+
+ t = pa_machine_id();
+ TXTRecordSetValue(txt, "machine-id", strlen(t), t);
+ pa_xfree(t);
+
+ t = pa_uname_string();
+ TXTRecordSetValue(txt, "uname", strlen(t), t);
+ pa_xfree(t);
+
+ t = pa_get_fqdn(s, sizeof(s));
+ TXTRecordSetValue(txt, "fqdn", strlen(t), t);
+
+ snprintf(s, sizeof(s), "0x%08x", c->cookie);
+ TXTRecordSetValue(txt, "cookie", strlen(s), s);
+}
+
+static void service_free(struct service *s);
+
+static void dns_service_register_reply(DNSServiceRef sdRef,
+ DNSServiceFlags flags,
+ DNSServiceErrorType errorCode,
+ const char *name,
+ const char *regtype,
+ const char *domain,
+ void *context) {
+ struct service *s = context;
+
+ pa_assert(s);
+
+ switch (errorCode) {
+ case kDNSServiceErr_NameConflict:
+ pa_log("DNS service reported kDNSServiceErr_NameConflict\n");
+ service_free(s);
+ break;
+
+ case kDNSServiceErr_NoError:
+ default:
+ break;
+ }
+}
+
+static uint16_t compute_port(struct userdata *u) {
+ pa_strlist *i;
+
+ pa_assert(u);
+
+ for (i = pa_native_protocol_servers(u->native); i; i = pa_strlist_next(i)) {
+ pa_parsed_address a;
+
+ if (pa_parse_address(pa_strlist_data(i), &a) >= 0 &&
+ (a.type == PA_PARSED_ADDRESS_TCP4 ||
+ a.type == PA_PARSED_ADDRESS_TCP6 ||
+ a.type == PA_PARSED_ADDRESS_TCP_AUTO) &&
+ a.port > 0) {
+
+ pa_xfree(a.path_or_host);
+ return a.port;
+ }
+
+ pa_xfree(a.path_or_host);
+ }
+
+ return PA_NATIVE_DEFAULT_PORT;
+}
+
+static int publish_service(struct service *s) {
+ int r = -1;
+ TXTRecordRef txt;
+ DNSServiceErrorType err;
+ const char *name = NULL, *t;
+ pa_proplist *proplist = NULL;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ char cm[PA_CHANNEL_MAP_SNPRINT_MAX], tmp[64];
+ enum service_subtype subtype;
+
+ const char * const subtype_text[] = {
+ [SUBTYPE_HARDWARE] = "hardware",
+ [SUBTYPE_VIRTUAL] = "virtual",
+ [SUBTYPE_MONITOR] = "monitor"
+ };
+
+ pa_assert(s);
+
+ if (s->service) {
+ DNSServiceRefDeallocate(s->service);
+ s->service = NULL;
+ }
+
+ TXTRecordCreate(&txt, 0, NULL);
+
+ txt_record_server_data(s->userdata->core, &txt);
+
+ get_service_data(s, &ss, &map, &name, &proplist, &subtype);
+ TXTRecordSetValue(&txt, "device", strlen(name), name);
+
+ snprintf(tmp, sizeof(tmp), "%u", ss.rate);
+ TXTRecordSetValue(&txt, "rate", strlen(tmp), tmp);
+
+ snprintf(tmp, sizeof(tmp), "%u", ss.channels);
+ TXTRecordSetValue(&txt, "channels", strlen(tmp), tmp);
+
+ t = pa_sample_format_to_string(ss.format);
+ TXTRecordSetValue(&txt, "format", strlen(t), t);
+
+ t = pa_channel_map_snprint(cm, sizeof(cm), &map);
+ TXTRecordSetValue(&txt, "channel_map", strlen(t), t);
+
+ t = subtype_text[subtype];
+ TXTRecordSetValue(&txt, "subtype", strlen(t), t);
+
+ if ((t = pa_proplist_gets(proplist, PA_PROP_DEVICE_DESCRIPTION)))
+ TXTRecordSetValue(&txt, "description", strlen(t), t);
+ if ((t = pa_proplist_gets(proplist, PA_PROP_DEVICE_ICON_NAME)))
+ TXTRecordSetValue(&txt, "icon-name", strlen(t), t);
+ if ((t = pa_proplist_gets(proplist, PA_PROP_DEVICE_VENDOR_NAME)))
+ TXTRecordSetValue(&txt, "vendor-name", strlen(t), t);
+ if ((t = pa_proplist_gets(proplist, PA_PROP_DEVICE_PRODUCT_NAME)))
+ TXTRecordSetValue(&txt, "product-name", strlen(t), t);
+ if ((t = pa_proplist_gets(proplist, PA_PROP_DEVICE_CLASS)))
+ TXTRecordSetValue(&txt, "class", strlen(t), t);
+ if ((t = pa_proplist_gets(proplist, PA_PROP_DEVICE_FORM_FACTOR)))
+ TXTRecordSetValue(&txt, "form-factor", strlen(t), t);
+
+ err = DNSServiceRegister(&s->service,
+ 0, /* flags */
+ kDNSServiceInterfaceIndexAny,
+ s->service_name,
+ pa_sink_isinstance(s->device) ? SERVICE_TYPE_SINK : SERVICE_TYPE_SOURCE,
+ NULL, /* domain */
+ NULL, /* host */
+ compute_port(s->userdata),
+ TXTRecordGetLength(&txt),
+ TXTRecordGetBytesPtr(&txt),
+ dns_service_register_reply, s);
+
+ if (err != kDNSServiceErr_NoError) {
+ pa_log("DNSServiceRegister() returned err %d", err);
+ goto finish;
+ }
+
+ pa_log_debug("Successfully registered Bonjour services for >%s<.", s->service_name);
+ return 0;
+
+finish:
+
+ /* Remove this service */
+ if (r < 0)
+ service_free(s);
+
+ TXTRecordDeallocate(&txt);
+
+ return r;
+}
+
+static struct service *get_service(struct userdata *u, pa_object *device) {
+ struct service *s;
+ char *hn, *un;
+ const char *n;
+
+ pa_assert(u);
+ pa_object_assert_ref(device);
+
+ if ((s = pa_hashmap_get(u->services, device)))
+ return s;
+
+ s = pa_xnew0(struct service, 1);
+ s->userdata = u;
+ s->device = device;
+
+ if (pa_sink_isinstance(device)) {
+ if (!(n = pa_proplist_gets(PA_SINK(device)->proplist, PA_PROP_DEVICE_DESCRIPTION)))
+ n = PA_SINK(device)->name;
+ } else {
+ if (!(n = pa_proplist_gets(PA_SOURCE(device)->proplist, PA_PROP_DEVICE_DESCRIPTION)))
+ n = PA_SOURCE(device)->name;
+ }
+
+ hn = pa_get_host_name_malloc();
+ un = pa_get_user_name_malloc();
+
+ s->service_name = pa_truncate_utf8(pa_sprintf_malloc("%s@%s: %s", un, hn, n), kDNSServiceMaxDomainName-1);
+
+ pa_xfree(un);
+ pa_xfree(hn);
+
+ pa_hashmap_put(u->services, s->device, s);
+
+ return s;
+}
+
+static void service_free(struct service *s) {
+ pa_assert(s);
+
+ pa_hashmap_remove(s->userdata->services, s->device);
+
+ if (s->service)
+ DNSServiceRefDeallocate(s->service);
+
+ pa_xfree(s->service_name);
+ pa_xfree(s);
+}
+
+static pa_bool_t shall_ignore(pa_object *o) {
+ pa_object_assert_ref(o);
+
+ if (pa_sink_isinstance(o))
+ return !!(PA_SINK(o)->flags & PA_SINK_NETWORK);
+
+ if (pa_source_isinstance(o))
+ return PA_SOURCE(o)->monitor_of || (PA_SOURCE(o)->flags & PA_SOURCE_NETWORK);
+
+ pa_assert_not_reached();
+}
+
+static pa_hook_result_t device_new_or_changed_cb(pa_core *c, pa_object *o, struct userdata *u) {
+ pa_assert(c);
+ pa_object_assert_ref(o);
+
+ if (!shall_ignore(o))
+ publish_service(get_service(u, o));
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t device_unlink_cb(pa_core *c, pa_object *o, struct userdata *u) {
+ struct service *s;
+
+ pa_assert(c);
+ pa_object_assert_ref(o);
+
+ if ((s = pa_hashmap_get(u->services, o)))
+ service_free(s);
+
+ return PA_HOOK_OK;
+}
+
+static int publish_main_service(struct userdata *u) {
+ DNSServiceErrorType err;
+ TXTRecordRef txt;
+
+ pa_assert(u);
+
+ if (u->main_service) {
+ DNSServiceRefDeallocate(u->main_service);
+ u->main_service = NULL;
+ }
+
+ TXTRecordCreate(&txt, 0, NULL);
+ txt_record_server_data(u->core, &txt);
+
+ err = DNSServiceRegister(&u->main_service,
+ 0, /* flags */
+ kDNSServiceInterfaceIndexAny,
+ u->service_name,
+ SERVICE_TYPE_SERVER,
+ NULL, /* domain */
+ NULL, /* host */
+ compute_port(u),
+ TXTRecordGetLength(&txt),
+ TXTRecordGetBytesPtr(&txt),
+ NULL, NULL);
+
+ if (err != kDNSServiceErr_NoError) {
+ pa_log("%s(): DNSServiceRegister() returned err %d", __func__, err);
+ return err;
+ }
+
+ TXTRecordDeallocate(&txt);
+
+ return 0;
+}
+
+static int publish_all_services(struct userdata *u) {
+ pa_sink *sink;
+ pa_source *source;
+ uint32_t idx;
+
+ pa_assert(u);
+
+ pa_log_debug("Publishing services in Bonjour");
+
+ for (sink = PA_SINK(pa_idxset_first(u->core->sinks, &idx)); sink; sink = PA_SINK(pa_idxset_next(u->core->sinks, &idx)))
+ if (!shall_ignore(PA_OBJECT(sink)))
+ publish_service(get_service(u, PA_OBJECT(sink)));
+
+ for (source = PA_SOURCE(pa_idxset_first(u->core->sources, &idx)); source; source = PA_SOURCE(pa_idxset_next(u->core->sources, &idx)))
+ if (!shall_ignore(PA_OBJECT(source)))
+ publish_service(get_service(u, PA_OBJECT(source)));
+
+ return publish_main_service(u);
+}
+
+static void unpublish_all_services(struct userdata *u) {
+ void *state = NULL;
+ struct service *s;
+
+ pa_assert(u);
+
+ pa_log_debug("Unpublishing services in Bonjour");
+
+ while ((s = pa_hashmap_iterate(u->services, &state, NULL)))
+ service_free(s);
+
+ if (u->main_service)
+ DNSServiceRefDeallocate(u->main_service);
+}
+
+int pa__init(pa_module*m) {
+
+ struct userdata *u;
+ pa_modargs *ma = NULL;
+ char *hn, *un;
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->module = m;
+ u->native = pa_native_protocol_get(u->core);
+
+ u->services = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+
+ u->sink_new_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_LATE, (pa_hook_cb_t) device_new_or_changed_cb, u);
+ u->sink_changed_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PROPLIST_CHANGED], PA_HOOK_LATE, (pa_hook_cb_t) device_new_or_changed_cb, u);
+ u->sink_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) device_unlink_cb, u);
+ u->source_new_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_PUT], PA_HOOK_LATE, (pa_hook_cb_t) device_new_or_changed_cb, u);
+ u->source_changed_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_PROPLIST_CHANGED], PA_HOOK_LATE, (pa_hook_cb_t) device_new_or_changed_cb, u);
+ u->source_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) device_unlink_cb, u);
+
+ un = pa_get_user_name_malloc();
+ hn = pa_get_host_name_malloc();
+ u->service_name = pa_truncate_utf8(pa_sprintf_malloc("%s@%s", un, hn), kDNSServiceMaxDomainName-1);
+ pa_xfree(un);
+ pa_xfree(hn);
+
+ publish_all_services(u);
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ pa__done(m);
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ return -1;
+}
+
+void pa__done(pa_module*m) {
+ struct userdata*u;
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ unpublish_all_services(u);
+
+ if (u->services)
+ pa_hashmap_free(u->services, NULL, NULL);
+
+ if (u->sink_new_slot)
+ pa_hook_slot_free(u->sink_new_slot);
+ if (u->source_new_slot)
+ pa_hook_slot_free(u->source_new_slot);
+ if (u->sink_changed_slot)
+ pa_hook_slot_free(u->sink_changed_slot);
+ if (u->source_changed_slot)
+ pa_hook_slot_free(u->source_changed_slot);
+ if (u->sink_unlink_slot)
+ pa_hook_slot_free(u->sink_unlink_slot);
+ if (u->source_unlink_slot)
+ pa_hook_slot_free(u->source_unlink_slot);
+
+ if (u->native)
+ pa_native_protocol_unref(u->native);
+
+ pa_xfree(u->service_name);
+ pa_xfree(u);
+}
diff --git a/src/modules/macosx/module-coreaudio-detect.c b/src/modules/macosx/module-coreaudio-detect.c
new file mode 100644
index 00000000..f4f2ee28
--- /dev/null
+++ b/src/modules/macosx/module-coreaudio-detect.c
@@ -0,0 +1,285 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009,2010 Daniel Mack <daniel@caiaq.de>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/module.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/llist.h>
+
+#include <CoreAudio/CoreAudio.h>
+
+#include "module-coreaudio-detect-symdef.h"
+
+#define DEVICE_MODULE_NAME "module-coreaudio-device"
+
+PA_MODULE_AUTHOR("Daniel Mack");
+PA_MODULE_DESCRIPTION("CoreAudio device detection");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_USAGE("ioproc_frames=<passed on to module-coreaudio-device> ");
+
+static const char* const valid_modargs[] = {
+ "ioproc_frames",
+ NULL
+};
+
+typedef struct ca_device ca_device;
+
+struct ca_device {
+ AudioObjectID id;
+ unsigned int module_index;
+ PA_LLIST_FIELDS(ca_device);
+};
+
+struct userdata {
+ int detect_fds[2];
+ pa_io_event *detect_io;
+ unsigned int ioproc_frames;
+ PA_LLIST_HEAD(ca_device, devices);
+};
+
+static int ca_device_added(struct pa_module *m, AudioObjectID id) {
+ AudioObjectPropertyAddress property_address;
+ OSStatus err;
+ pa_module *mod;
+ struct userdata *u;
+ struct ca_device *dev;
+ char *args, tmp[64];
+ UInt32 size;
+
+ pa_assert(m);
+ pa_assert_se(u = m->userdata);
+
+ /* To prevent generating a black hole that will suck us in,
+ don't create sources/sinks for PulseAudio virtual devices */
+
+ property_address.mSelector = kAudioDevicePropertyDeviceManufacturer;
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ size = sizeof(tmp);
+ err = AudioObjectGetPropertyData(id, &property_address, 0, NULL, &size, tmp);
+
+ if (!err && strcmp(tmp, "pulseaudio.org") == 0)
+ return 0;
+
+ if (u->ioproc_frames)
+ args = pa_sprintf_malloc("object_id=%d ioproc_frames=%d", (int) id, u->ioproc_frames);
+ else
+ args = pa_sprintf_malloc("object_id=%d", (int) id);
+
+ pa_log_debug("Loading %s with arguments '%s'", DEVICE_MODULE_NAME, args);
+ mod = pa_module_load(m->core, DEVICE_MODULE_NAME, args);
+ pa_xfree(args);
+
+ if (!mod) {
+ pa_log_info("Failed to load module %s with arguments '%s'", DEVICE_MODULE_NAME, args);
+ return -1;
+ }
+
+ dev = pa_xnew0(ca_device, 1);
+ dev->module_index = mod->index;
+ dev->id = id;
+
+ PA_LLIST_INIT(ca_device, dev);
+ PA_LLIST_PREPEND(ca_device, u->devices, dev);
+
+ return 0;
+}
+
+static int ca_update_device_list(struct pa_module *m) {
+ AudioObjectPropertyAddress property_address;
+ OSStatus err;
+ UInt32 i, size, num_devices;
+ AudioDeviceID *device_id;
+ struct ca_device *dev;
+ struct userdata *u;
+
+ pa_assert(m);
+ pa_assert_se(u = m->userdata);
+
+ property_address.mSelector = kAudioHardwarePropertyDevices;
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ /* get the number of currently available audio devices */
+ err = AudioObjectGetPropertyDataSize(kAudioObjectSystemObject, &property_address, 0, NULL, &size);
+ if (err) {
+ pa_log("Unable to get data size for kAudioHardwarePropertyDevices.");
+ return -1;
+ }
+
+ num_devices = size / sizeof(AudioDeviceID);
+ device_id = pa_xnew(AudioDeviceID, num_devices);
+
+ err = AudioObjectGetPropertyData(kAudioObjectSystemObject, &property_address, 0, NULL, &size, device_id);
+ if (err) {
+ pa_log("Unable to get kAudioHardwarePropertyDevices.");
+ pa_xfree(device_id);
+ return -1;
+ }
+
+ /* scan for devices which are reported but not in our cached list */
+ for (i = 0; i < num_devices; i++) {
+ bool found = FALSE;
+
+ PA_LLIST_FOREACH(dev, u->devices)
+ if (dev->id == device_id[i]) {
+ found = TRUE;
+ break;
+ }
+
+ if (!found)
+ ca_device_added(m, device_id[i]);
+ }
+
+ /* scan for devices which are in our cached list but are not reported */
+scan_removed:
+
+ PA_LLIST_FOREACH(dev, u->devices) {
+ bool found = FALSE;
+
+ for (i = 0; i < num_devices; i++)
+ if (dev->id == device_id[i]) {
+ found = TRUE;
+ break;
+ }
+
+ if (!found) {
+ pa_log_debug("object id %d has been removed (module index %d) %p", (unsigned int) dev->id, dev->module_index, dev);
+ pa_module_unload_request_by_index(m->core, dev->module_index, TRUE);
+ PA_LLIST_REMOVE(ca_device, u->devices, dev);
+ pa_xfree(dev);
+ /* the current list item pointer is not valid anymore, so start over. */
+ goto scan_removed;
+ }
+ }
+
+ pa_xfree(device_id);
+ return 0;
+}
+
+static OSStatus property_listener_proc(AudioObjectID objectID, UInt32 numberAddresses,
+ const AudioObjectPropertyAddress inAddresses[],
+ void *clientData)
+{
+ struct userdata *u = clientData;
+ char dummy = 1;
+
+ pa_assert(u);
+
+ /* dispatch module load/unload operations in main thread */
+ write(u->detect_fds[1], &dummy, 1);
+
+ return 0;
+}
+
+static void detect_handle(pa_mainloop_api *a, pa_io_event *e, int fd, pa_io_event_flags_t events, void *userdata) {
+ pa_module *m = userdata;
+ char dummy;
+
+ pa_assert(m);
+
+ read(fd, &dummy, 1);
+ ca_update_device_list(m);
+}
+
+int pa__init(pa_module *m) {
+ struct userdata *u = pa_xnew0(struct userdata, 1);
+ AudioObjectPropertyAddress property_address;
+ pa_modargs *ma;
+
+ pa_assert(m);
+
+ m->userdata = u;
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ pa_modargs_get_value_u32(ma, "ioproc_frames", &u->ioproc_frames);
+
+ property_address.mSelector = kAudioHardwarePropertyDevices;
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ if (AudioObjectAddPropertyListener(kAudioObjectSystemObject, &property_address, property_listener_proc, u)) {
+ pa_log("AudioObjectAddPropertyListener() failed.");
+ goto fail;
+ }
+
+ if (ca_update_device_list(m))
+ goto fail;
+
+ pa_assert_se(pipe(u->detect_fds) == 0);
+ pa_assert_se(u->detect_io = m->core->mainloop->io_new(m->core->mainloop, u->detect_fds[0], PA_IO_EVENT_INPUT, detect_handle, m));
+
+ return 0;
+
+fail:
+ pa_xfree(u);
+ return -1;
+}
+
+void pa__done(pa_module *m) {
+ struct userdata *u;
+ struct ca_device *dev;
+ AudioObjectPropertyAddress property_address;
+
+ pa_assert(m);
+ pa_assert_se(u = m->userdata);
+
+ dev = u->devices;
+
+ property_address.mSelector = kAudioHardwarePropertyDevices;
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ AudioObjectRemovePropertyListener(kAudioObjectSystemObject, &property_address, property_listener_proc, u);
+
+ while (dev) {
+ struct ca_device *next = dev->next;
+
+ pa_module_unload_request_by_index(m->core, dev->module_index, TRUE);
+ pa_xfree(dev);
+
+ dev = next;
+ }
+
+ if (u->detect_fds[0] >= 0)
+ close(u->detect_fds[0]);
+
+ if (u->detect_fds[1] >= 0)
+ close(u->detect_fds[1]);
+
+ if (u->detect_io)
+ m->core->mainloop->io_free(u->detect_io);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/macosx/module-coreaudio-device.c b/src/modules/macosx/module-coreaudio-device.c
new file mode 100644
index 00000000..d2762819
--- /dev/null
+++ b/src/modules/macosx/module-coreaudio-device.c
@@ -0,0 +1,876 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009,2010 Daniel Mack <daniel@caiaq.de>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* TODO:
+ - implement hardware volume controls
+ - handle audio device stream format changes (will require changes to the core)
+*/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/sink.h>
+#include <pulsecore/source.h>
+#include <pulsecore/module.h>
+#include <pulsecore/sample-util.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/llist.h>
+#include <pulsecore/card.h>
+#include <pulsecore/strbuf.h>
+#include <pulsecore/thread.h>
+#include <pulsecore/thread-mq.h>
+
+#include <CoreAudio/CoreAudio.h>
+#include <CoreAudio/CoreAudioTypes.h>
+#include <CoreAudio/AudioHardware.h>
+
+#include "module-coreaudio-device-symdef.h"
+
+#define DEFAULT_FRAMES_PER_IOPROC 512
+
+PA_MODULE_AUTHOR("Daniel Mack");
+PA_MODULE_DESCRIPTION("CoreAudio device");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE("object_id=<the CoreAudio device id> "
+ "ioproc_frames=<audio frames per IOProc call> ");
+
+static const char* const valid_modargs[] = {
+ "object_id",
+ "ioproc_frames",
+ NULL
+};
+
+enum {
+ CA_MESSAGE_RENDER = PA_SINK_MESSAGE_MAX,
+};
+
+typedef struct coreaudio_sink coreaudio_sink;
+typedef struct coreaudio_source coreaudio_source;
+
+struct userdata {
+ AudioObjectID object_id;
+ AudioDeviceIOProcID proc_id;
+
+ pa_thread_mq thread_mq;
+ pa_asyncmsgq *async_msgq;
+
+ pa_rtpoll *rtpoll;
+ pa_thread *thread;
+
+ pa_module *module;
+ pa_card *card;
+ pa_bool_t running;
+
+ char *device_name, *vendor_name;
+
+ const AudioBufferList *render_input_data;
+ AudioBufferList *render_output_data;
+
+ AudioStreamBasicDescription stream_description;
+
+ PA_LLIST_HEAD(coreaudio_sink, sinks);
+ PA_LLIST_HEAD(coreaudio_source, sources);
+};
+
+struct coreaudio_sink {
+ pa_sink *pa_sink;
+ struct userdata *userdata;
+
+ char *name;
+ unsigned int channel_idx;
+ pa_bool_t active;
+
+ pa_channel_map map;
+ pa_sample_spec ss;
+
+ PA_LLIST_FIELDS(coreaudio_sink);
+};
+
+struct coreaudio_source {
+ pa_source *pa_source;
+ struct userdata *userdata;
+
+ char *name;
+ unsigned int channel_idx;
+ pa_bool_t active;
+
+ pa_channel_map map;
+ pa_sample_spec ss;
+
+ PA_LLIST_FIELDS(coreaudio_source);
+};
+
+static OSStatus io_render_proc (AudioDeviceID device,
+ const AudioTimeStamp *now,
+ const AudioBufferList *inputData,
+ const AudioTimeStamp *inputTime,
+ AudioBufferList *outputData,
+ const AudioTimeStamp *outputTime,
+ void *clientData)
+{
+ struct userdata *u = clientData;
+
+ pa_assert(u);
+ pa_assert(device == u->object_id);
+
+ u->render_input_data = inputData;
+ u->render_output_data = outputData;
+
+ if (u->sinks)
+ pa_assert_se(pa_asyncmsgq_send(u->async_msgq, PA_MSGOBJECT(u->sinks->pa_sink),
+ CA_MESSAGE_RENDER, NULL, 0, NULL) == 0);
+
+ if (u->sources)
+ pa_assert_se(pa_asyncmsgq_send(u->async_msgq, PA_MSGOBJECT(u->sources->pa_source),
+ CA_MESSAGE_RENDER, NULL, 0, NULL) == 0);
+
+ return 0;
+}
+
+static OSStatus ca_stream_format_changed(AudioObjectID objectID,
+ UInt32 numberAddresses,
+ const AudioObjectPropertyAddress addresses[],
+ void *clientData)
+{
+ struct userdata *u = clientData;
+ UInt32 i;
+
+ pa_assert(u);
+
+ /* REVISIT: PA can't currently handle external format change requests.
+ * Hence, we set the original format back in this callback to avoid horrible audio artefacts.
+ * The device settings will appear to be 'locked' for any application as long as the PA daemon is running.
+ * Once we're able to propagate such events up in the core, this needs to be changed. */
+
+ for (i = 0; i < numberAddresses; i++)
+ AudioObjectSetPropertyData(objectID, addresses + i, 0, NULL, sizeof(u->stream_description), &u->stream_description);
+
+ return 0;
+}
+
+static pa_usec_t get_latency_us(pa_object *o) {
+ struct userdata *u;
+ pa_sample_spec *ss;
+ bool is_source;
+ UInt32 v, total = 0;
+ UInt32 err, size = sizeof(v);
+ AudioObjectPropertyAddress property_address;
+ AudioObjectID stream_id;
+
+ if (pa_sink_isinstance(o)) {
+ coreaudio_sink *sink = PA_SINK(o)->userdata;
+
+ u = sink->userdata;
+ ss = &sink->ss;
+ is_source = FALSE;
+ } else if (pa_source_isinstance(o)) {
+ coreaudio_source *source = PA_SOURCE(o)->userdata;
+
+ u = source->userdata;
+ ss = &source->ss;
+ is_source = TRUE;
+ } else
+ pa_assert_not_reached();
+
+ pa_assert(u);
+
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ /* get the device latency */
+ property_address.mSelector = kAudioDevicePropertyLatency;
+ size = sizeof(total);
+ AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, &total);
+ total += v;
+
+ /* the the IOProc buffer size */
+ property_address.mSelector = kAudioDevicePropertyBufferFrameSize;
+ size = sizeof(v);
+ AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, &v);
+ total += v;
+
+ /* IOProc safety offset - this value is the same for both directions, hence we divide it by 2 */
+ property_address.mSelector = kAudioDevicePropertySafetyOffset;
+ size = sizeof(v);
+ AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, &v);
+ total += v / 2;
+
+ /* get the stream latency.
+ * FIXME: this assumes the stream latency is the same for all streams */
+ property_address.mSelector = kAudioDevicePropertyStreams;
+ size = sizeof(stream_id);
+ err = AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, &stream_id);
+ if (!err) {
+ property_address.mSelector = kAudioStreamPropertyLatency;
+ size = sizeof(v);
+ err = AudioObjectGetPropertyData(stream_id, &property_address, 0, NULL, &size, &v);
+ if (!err)
+ total += v;
+ }
+
+ return pa_bytes_to_usec(total * pa_frame_size(ss), ss);
+}
+
+static void ca_device_check_device_state(struct userdata *u) {
+ coreaudio_sink *ca_sink;
+ coreaudio_source *ca_source;
+ pa_bool_t active = FALSE;
+
+ pa_assert(u);
+
+ for (ca_sink = u->sinks; ca_sink; ca_sink = ca_sink->next)
+ if (ca_sink->active)
+ active = TRUE;
+
+ for (ca_source = u->sources; ca_source; ca_source = ca_source->next)
+ if (ca_source->active)
+ active = TRUE;
+
+ if (active && !u->running)
+ AudioDeviceStart(u->object_id, u->proc_id);
+ else if (!active && u->running)
+ AudioDeviceStop(u->object_id, u->proc_id);
+
+ u->running = active;
+}
+
+static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ coreaudio_sink *sink = PA_SINK(o)->userdata;
+ struct userdata *u = sink->userdata;
+ unsigned int i;
+ pa_memchunk audio_chunk;
+
+ switch (code) {
+ case CA_MESSAGE_RENDER: {
+ /* audio out */
+ for (i = 0; i < u->render_output_data->mNumberBuffers; i++) {
+ AudioBuffer *buf = u->render_output_data->mBuffers + i;
+
+ pa_assert(sink);
+
+ if (PA_SINK_IS_OPENED(sink->pa_sink->thread_info.state)) {
+ if (sink->pa_sink->thread_info.rewind_requested)
+ pa_sink_process_rewind(sink->pa_sink, 0);
+
+ audio_chunk.memblock = pa_memblock_new_fixed(u->module->core->mempool, buf->mData, buf->mDataByteSize, FALSE);
+ audio_chunk.length = buf->mDataByteSize;
+ audio_chunk.index = 0;
+
+ pa_sink_render_into_full(sink->pa_sink, &audio_chunk);
+ pa_memblock_unref_fixed(audio_chunk.memblock);
+ }
+
+ sink = sink->next;
+ }
+
+ return 0;
+ }
+
+ case PA_SINK_MESSAGE_GET_LATENCY: {
+ *((pa_usec_t *) data) = get_latency_us(PA_OBJECT(o));
+ return 0;
+ }
+ }
+
+ return pa_sink_process_msg(o, code, data, offset, chunk);
+}
+
+static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ coreaudio_source *source = PA_SOURCE(o)->userdata;
+ struct userdata *u = source->userdata;
+ unsigned int i;
+ pa_memchunk audio_chunk;
+
+ switch (code) {
+ case CA_MESSAGE_RENDER: {
+ /* audio in */
+ for (i = 0; i < u->render_input_data->mNumberBuffers; i++) {
+ const AudioBuffer *buf = u->render_input_data->mBuffers + i;
+
+ pa_assert(source);
+
+ if (PA_SOURCE_IS_OPENED(source->pa_source->thread_info.state)) {
+ audio_chunk.memblock = pa_memblock_new_fixed(u->module->core->mempool, buf->mData, buf->mDataByteSize, TRUE);
+ audio_chunk.length = buf->mDataByteSize;
+ audio_chunk.index = 0;
+
+ pa_source_post(source->pa_source, &audio_chunk);
+ pa_memblock_unref_fixed(audio_chunk.memblock);
+ }
+
+ source = source->next;
+ }
+
+ return 0;
+ }
+
+ case PA_SOURCE_MESSAGE_GET_LATENCY: {
+ *((pa_usec_t *) data) = get_latency_us(PA_OBJECT(o));
+ return 0;
+ }
+ }
+
+ return pa_source_process_msg(o, code, data, offset, chunk);;
+}
+
+static int ca_sink_set_state(pa_sink *s, pa_sink_state_t state)
+{
+ coreaudio_sink *sink = s->userdata;
+
+ switch (state) {
+ case PA_SINK_SUSPENDED:
+ case PA_SINK_IDLE:
+ sink->active = FALSE;
+ break;
+
+ case PA_SINK_RUNNING:
+ sink->active = TRUE;
+ break;
+
+ case PA_SINK_UNLINKED:
+ case PA_SINK_INIT:
+ case PA_SINK_INVALID_STATE:
+ ;
+ }
+
+ ca_device_check_device_state(sink->userdata);
+
+ return 0;
+}
+
+static int ca_device_create_sink(pa_module *m, AudioBuffer *buf, int channel_idx) {
+ OSStatus err;
+ UInt32 size;
+ struct userdata *u = m->userdata;
+ pa_sink_new_data new_data;
+ pa_sink_flags_t flags = PA_SINK_LATENCY | PA_SINK_HARDWARE;
+ coreaudio_sink *ca_sink;
+ pa_sink *sink;
+ unsigned int i;
+ char tmp[255];
+ pa_strbuf *strbuf;
+ AudioObjectPropertyAddress property_address;
+
+ ca_sink = pa_xnew0(coreaudio_sink, 1);
+ ca_sink->map.channels = buf->mNumberChannels;
+ ca_sink->ss.channels = buf->mNumberChannels;
+ ca_sink->channel_idx = channel_idx;
+
+ /* build a name for this stream */
+ strbuf = pa_strbuf_new();
+
+ for (i = 0; i < buf->mNumberChannels; i++) {
+ property_address.mSelector = kAudioObjectPropertyElementName;
+ property_address.mScope = kAudioDevicePropertyScopeOutput;
+ property_address.mElement = channel_idx + i + 1;
+ size = sizeof(tmp);
+ err = AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, tmp);
+ if (err || !strlen(tmp))
+ snprintf(tmp, sizeof(tmp), "Channel %d", (int) property_address.mElement);
+
+ if (i > 0)
+ pa_strbuf_puts(strbuf, ", ");
+
+ pa_strbuf_puts(strbuf, tmp);
+ }
+
+ ca_sink->name = pa_strbuf_tostring_free(strbuf);
+
+ pa_log_debug("Stream name is >%s<", ca_sink->name);
+
+ /* default to mono streams */
+ for (i = 0; i < ca_sink->map.channels; i++)
+ ca_sink->map.map[i] = PA_CHANNEL_POSITION_MONO;
+
+ if (buf->mNumberChannels == 2) {
+ ca_sink->map.map[0] = PA_CHANNEL_POSITION_LEFT;
+ ca_sink->map.map[1] = PA_CHANNEL_POSITION_RIGHT;
+ }
+
+ ca_sink->ss.rate = u->stream_description.mSampleRate;
+ ca_sink->ss.format = PA_SAMPLE_FLOAT32LE;
+
+ pa_sink_new_data_init(&new_data);
+ new_data.card = u->card;
+ new_data.driver = __FILE__;
+ new_data.module = u->module;
+ new_data.namereg_fail = FALSE;
+ pa_sink_new_data_set_name(&new_data, ca_sink->name);
+ pa_sink_new_data_set_channel_map(&new_data, &ca_sink->map);
+ pa_sink_new_data_set_sample_spec(&new_data, &ca_sink->ss);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_STRING, u->device_name);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_PRODUCT_NAME, u->device_name);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_DESCRIPTION, u->device_name);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_ACCESS_MODE, "mmap");
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_CLASS, "sound");
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_API, "CoreAudio");
+ pa_proplist_setf(new_data.proplist, PA_PROP_DEVICE_BUFFERING_BUFFER_SIZE, "%lu", (unsigned long) buf->mDataByteSize);
+
+ if (u->vendor_name)
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_VENDOR_NAME, u->vendor_name);
+
+ sink = pa_sink_new(m->core, &new_data, flags);
+ pa_sink_new_data_done(&new_data);
+
+ if (!sink) {
+ pa_log("unable to create sink.");
+ return -1;
+ }
+
+ sink->parent.process_msg = sink_process_msg;
+ sink->userdata = ca_sink;
+ sink->set_state = ca_sink_set_state;
+
+ pa_sink_set_asyncmsgq(sink, u->thread_mq.inq);
+ pa_sink_set_rtpoll(sink, u->rtpoll);
+
+ ca_sink->pa_sink = sink;
+ ca_sink->userdata = u;
+
+ PA_LLIST_PREPEND(coreaudio_sink, u->sinks, ca_sink);
+
+ return 0;
+}
+
+static int ca_source_set_state(pa_source *s, pa_source_state_t state)
+{
+ coreaudio_source *source = s->userdata;
+
+ switch (state) {
+ case PA_SOURCE_SUSPENDED:
+ case PA_SOURCE_IDLE:
+ source->active = FALSE;
+ break;
+
+ case PA_SOURCE_RUNNING:
+ source->active = TRUE;
+ break;
+
+ case PA_SOURCE_UNLINKED:
+ case PA_SOURCE_INIT:
+ case PA_SOURCE_INVALID_STATE:
+ ;
+ }
+
+ ca_device_check_device_state(source->userdata);
+
+ return 0;
+}
+
+static int ca_device_create_source(pa_module *m, AudioBuffer *buf, int channel_idx) {
+ OSStatus err;
+ UInt32 size;
+ struct userdata *u = m->userdata;
+ pa_source_new_data new_data;
+ pa_source_flags_t flags = PA_SOURCE_LATENCY | PA_SOURCE_HARDWARE;
+ coreaudio_source *ca_source;
+ pa_source *source;
+ unsigned int i;
+ char tmp[255];
+ pa_strbuf *strbuf;
+ AudioObjectPropertyAddress property_address;
+
+ ca_source = pa_xnew0(coreaudio_source, 1);
+ ca_source->map.channels = buf->mNumberChannels;
+ ca_source->ss.channels = buf->mNumberChannels;
+ ca_source->channel_idx = channel_idx;
+
+ /* build a name for this stream */
+ strbuf = pa_strbuf_new();
+
+ for (i = 0; i < buf->mNumberChannels; i++) {
+ property_address.mSelector = kAudioObjectPropertyElementName;
+ property_address.mScope = kAudioDevicePropertyScopeInput;
+ property_address.mElement = channel_idx + i + 1;
+ size = sizeof(tmp);
+ err = AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, tmp);
+ if (err || !strlen(tmp))
+ snprintf(tmp, sizeof(tmp), "Channel %d", (int) property_address.mElement);
+
+ if (i > 0)
+ pa_strbuf_puts(strbuf, ", ");
+
+ pa_strbuf_puts(strbuf, tmp);
+ }
+
+ ca_source->name = pa_strbuf_tostring_free(strbuf);
+
+ pa_log_debug("Stream name is >%s<", ca_source->name);
+
+ /* default to mono streams */
+ for (i = 0; i < ca_source->map.channels; i++)
+ ca_source->map.map[i] = PA_CHANNEL_POSITION_MONO;
+
+ if (buf->mNumberChannels == 2) {
+ ca_source->map.map[0] = PA_CHANNEL_POSITION_LEFT;
+ ca_source->map.map[1] = PA_CHANNEL_POSITION_RIGHT;
+ }
+
+ ca_source->ss.rate = u->stream_description.mSampleRate;
+ ca_source->ss.format = PA_SAMPLE_FLOAT32LE;
+
+ pa_source_new_data_init(&new_data);
+ new_data.card = u->card;
+ new_data.driver = __FILE__;
+ new_data.module = u->module;
+ new_data.namereg_fail = FALSE;
+ pa_source_new_data_set_name(&new_data, ca_source->name);
+ pa_source_new_data_set_channel_map(&new_data, &ca_source->map);
+ pa_source_new_data_set_sample_spec(&new_data, &ca_source->ss);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_STRING, u->device_name);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_PRODUCT_NAME, u->device_name);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_DESCRIPTION, u->device_name);
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_ACCESS_MODE, "mmap");
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_CLASS, "sound");
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_API, "CoreAudio");
+ pa_proplist_setf(new_data.proplist, PA_PROP_DEVICE_BUFFERING_BUFFER_SIZE, "%lu", (unsigned long) buf->mDataByteSize);
+
+ if (u->vendor_name)
+ pa_proplist_sets(new_data.proplist, PA_PROP_DEVICE_VENDOR_NAME, u->vendor_name);
+
+ source = pa_source_new(m->core, &new_data, flags);
+ pa_source_new_data_done(&new_data);
+
+ if (!source) {
+ pa_log("unable to create source.");
+ return -1;
+ }
+
+ source->parent.process_msg = source_process_msg;
+ source->userdata = ca_source;
+ source->set_state = ca_source_set_state;
+
+ pa_source_set_asyncmsgq(source, u->thread_mq.inq);
+ pa_source_set_rtpoll(source, u->rtpoll);
+
+ ca_source->pa_source = source;
+ ca_source->userdata = u;
+
+ PA_LLIST_PREPEND(coreaudio_source, u->sources, ca_source);
+
+ return 0;
+}
+
+static int ca_device_create_streams(pa_module *m, bool direction_in) {
+ OSStatus err;
+ UInt32 size, i, channel_idx;
+ struct userdata *u = m->userdata;
+ AudioBufferList *buffer_list;
+ AudioObjectPropertyAddress property_address;
+
+ property_address.mScope = direction_in ? kAudioDevicePropertyScopeInput : kAudioDevicePropertyScopeOutput;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ /* get current stream format */
+ size = sizeof(AudioStreamBasicDescription);
+ property_address.mSelector = kAudioDevicePropertyStreamFormat;
+ err = AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, &u->stream_description);
+ if (err) {
+ /* no appropriate streams found - silently bail. */
+ return -1;
+ }
+
+ if (u->stream_description.mFormatID != kAudioFormatLinearPCM) {
+ pa_log("Unsupported audio format '%c%c%c%c'",
+ (char) (u->stream_description.mFormatID >> 24),
+ (char) (u->stream_description.mFormatID >> 16) & 0xff,
+ (char) (u->stream_description.mFormatID >> 8) & 0xff,
+ (char) (u->stream_description.mFormatID & 0xff));
+ return -1;
+ }
+
+ /* get stream configuration */
+ size = 0;
+ property_address.mSelector = kAudioDevicePropertyStreamConfiguration;
+ err = AudioObjectGetPropertyDataSize(u->object_id, &property_address, 0, NULL, &size);
+ if (err) {
+ pa_log("Failed to get kAudioDevicePropertyStreamConfiguration (%s).", direction_in ? "input" : "output");
+ return -1;
+ }
+
+ if (!size)
+ return 0;
+
+ buffer_list = (AudioBufferList *) pa_xmalloc(size);
+ err = AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, buffer_list);
+
+ if (!err) {
+ pa_log_debug("Sample rate: %f", u->stream_description.mSampleRate);
+ pa_log_debug("%d bytes per packet", (unsigned int) u->stream_description.mBytesPerPacket);
+ pa_log_debug("%d frames per packet", (unsigned int) u->stream_description.mFramesPerPacket);
+ pa_log_debug("%d bytes per frame", (unsigned int) u->stream_description.mBytesPerFrame);
+ pa_log_debug("%d channels per frame", (unsigned int) u->stream_description.mChannelsPerFrame);
+ pa_log_debug("%d bits per channel", (unsigned int) u->stream_description.mBitsPerChannel);
+
+ for (channel_idx = 0, i = 0; i < buffer_list->mNumberBuffers; i++) {
+ AudioBuffer *buf = buffer_list->mBuffers + i;
+
+ if (direction_in)
+ ca_device_create_source(m, buf, channel_idx);
+ else
+ ca_device_create_sink(m, buf, channel_idx);
+
+ channel_idx += buf->mNumberChannels;
+ }
+ }
+
+ pa_xfree(buffer_list);
+ return 0;
+}
+
+static void thread_func(void *userdata) {
+ struct userdata *u = userdata;
+
+ pa_assert(u);
+ pa_assert(u->module);
+ pa_assert(u->module->core);
+
+ pa_log_debug("Thread starting up");
+
+ if (u->module->core->realtime_scheduling)
+ pa_make_realtime(u->module->core->realtime_priority);
+
+ pa_thread_mq_install(&u->thread_mq);
+
+ for (;;) {
+ int ret;
+
+ ret = pa_rtpoll_run(u->rtpoll, TRUE);
+
+ if (ret < 0)
+ goto fail;
+
+ if (ret == 0)
+ goto finish;
+ }
+
+fail:
+ /* If this was no regular exit from the loop we have to continue
+ * processing messages until we received PA_MESSAGE_SHUTDOWN */
+ pa_asyncmsgq_post(u->thread_mq.outq, PA_MSGOBJECT(u->module->core), PA_CORE_MESSAGE_UNLOAD_MODULE, u->module, 0, NULL, NULL);
+ pa_asyncmsgq_wait_for(u->thread_mq.inq, PA_MESSAGE_SHUTDOWN);
+
+finish:
+ pa_log_debug("Thread shutting down");
+}
+
+int pa__init(pa_module *m) {
+ OSStatus err;
+ UInt32 size, frames;
+ struct userdata *u = NULL;
+ pa_modargs *ma = NULL;
+ char tmp[64];
+ pa_card_new_data card_new_data;
+ coreaudio_sink *ca_sink;
+ coreaudio_source *ca_source;
+ AudioObjectPropertyAddress property_address;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ u = pa_xnew0(struct userdata, 1);
+ u->module = m;
+ m->userdata = u;
+
+ if (pa_modargs_get_value_u32(ma, "object_id", (unsigned int *) &u->object_id) != 0) {
+ pa_log("Failed to parse object_id argument.");
+ goto fail;
+ }
+
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ /* get device product name */
+ property_address.mSelector = kAudioDevicePropertyDeviceName;
+ size = sizeof(tmp);
+ err = AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, tmp);
+ if (err) {
+ pa_log("Failed to get kAudioDevicePropertyDeviceName (err = %08x).", (int) err);
+ goto fail;
+ }
+
+ u->device_name = pa_xstrdup(tmp);
+
+ pa_card_new_data_init(&card_new_data);
+ pa_proplist_sets(card_new_data.proplist, PA_PROP_DEVICE_STRING, tmp);
+ card_new_data.driver = __FILE__;
+ pa_card_new_data_set_name(&card_new_data, tmp);
+ pa_log_info("Initializing module for CoreAudio device '%s' (id %d)", tmp, (unsigned int) u->object_id);
+
+ /* get device vendor name (may fail) */
+ property_address.mSelector = kAudioDevicePropertyDeviceManufacturer;
+ size = sizeof(tmp);
+ err = AudioObjectGetPropertyData(u->object_id, &property_address, 0, NULL, &size, tmp);
+ if (!err)
+ u->vendor_name = pa_xstrdup(tmp);
+
+ /* create the card object */
+ u->card = pa_card_new(m->core, &card_new_data);
+ if (!u->card) {
+ pa_log("Unable to create card.\n");
+ goto fail;
+ }
+
+ pa_card_new_data_done(&card_new_data);
+ u->card->userdata = u;
+
+ u->rtpoll = pa_rtpoll_new();
+ pa_thread_mq_init(&u->thread_mq, m->core->mainloop, u->rtpoll);
+ u->async_msgq = pa_asyncmsgq_new(0);
+ pa_rtpoll_item_new_asyncmsgq_read(u->rtpoll, PA_RTPOLL_EARLY-1, u->async_msgq);
+
+ PA_LLIST_HEAD_INIT(coreaudio_sink, u->sinks);
+
+ /* create sinks */
+ ca_device_create_streams(m, FALSE);
+
+ /* create sources */
+ ca_device_create_streams(m, TRUE);
+
+ /* create the message thread */
+ if (!(u->thread = pa_thread_new(u->device_name, thread_func, u))) {
+ pa_log("Failed to create thread.");
+ goto fail;
+ }
+
+ /* register notification callback for stream format changes */
+ property_address.mSelector = kAudioDevicePropertyStreamFormat;
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ AudioObjectAddPropertyListener(u->object_id, &property_address, ca_stream_format_changed, u);
+
+ /* set number of frames in IOProc */
+ frames = DEFAULT_FRAMES_PER_IOPROC;
+ pa_modargs_get_value_u32(ma, "ioproc_frames", (unsigned int *) &frames);
+
+ property_address.mSelector = kAudioDevicePropertyBufferFrameSize;
+ AudioObjectSetPropertyData(u->object_id, &property_address, 0, NULL, sizeof(frames), &frames);
+ pa_log_debug("%u frames per IOProc\n", (unsigned int) frames);
+
+ /* create one ioproc for both directions */
+ err = AudioDeviceCreateIOProcID(u->object_id, io_render_proc, u, &u->proc_id);
+ if (err) {
+ pa_log("AudioDeviceCreateIOProcID() failed (err = %08x\n).", (int) err);
+ goto fail;
+ }
+
+ for (ca_sink = u->sinks; ca_sink; ca_sink = ca_sink->next)
+ pa_sink_put(ca_sink->pa_sink);
+
+ for (ca_source = u->sources; ca_source; ca_source = ca_source->next)
+ pa_source_put(ca_source->pa_source);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ if (u)
+ pa__done(m);
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ return -1;
+}
+
+void pa__done(pa_module *m) {
+ struct userdata *u;
+ coreaudio_sink *ca_sink;
+ coreaudio_source *ca_source;
+ AudioObjectPropertyAddress property_address;
+
+ pa_assert(m);
+
+ u = m->userdata;
+ pa_assert(u);
+
+ /* unlink sinks */
+ for (ca_sink = u->sinks; ca_sink; ca_sink = ca_sink->next)
+ if (ca_sink->pa_sink)
+ pa_sink_unlink(ca_sink->pa_sink);
+
+ /* unlink sources */
+ for (ca_source = u->sources; ca_source; ca_source = ca_source->next)
+ if (ca_source->pa_source)
+ pa_source_unlink(ca_source->pa_source);
+
+ if (u->thread) {
+ pa_asyncmsgq_send(u->thread_mq.inq, NULL, PA_MESSAGE_SHUTDOWN, NULL, 0, NULL);
+ pa_thread_free(u->thread);
+ pa_thread_mq_done(&u->thread_mq);
+ pa_asyncmsgq_unref(u->async_msgq);
+ }
+
+ /* free sinks */
+ for (ca_sink = u->sinks; ca_sink;) {
+ coreaudio_sink *next = ca_sink->next;
+
+ if (ca_sink->pa_sink)
+ pa_sink_unref(ca_sink->pa_sink);
+
+ pa_xfree(ca_sink->name);
+ pa_xfree(ca_sink);
+ ca_sink = next;
+ }
+
+ /* free sources */
+ for (ca_source = u->sources; ca_source;) {
+ coreaudio_source *next = ca_source->next;
+
+ if (ca_source->pa_source)
+ pa_source_unref(ca_source->pa_source);
+
+ pa_xfree(ca_source->name);
+ pa_xfree(ca_source);
+ ca_source = next;
+ }
+
+ if (u->proc_id) {
+ AudioDeviceStop(u->object_id, u->proc_id);
+ AudioDeviceDestroyIOProcID(u->object_id, u->proc_id);
+ }
+
+ property_address.mSelector = kAudioDevicePropertyStreamFormat;
+ property_address.mScope = kAudioObjectPropertyScopeGlobal;
+ property_address.mElement = kAudioObjectPropertyElementMaster;
+
+ AudioObjectRemovePropertyListener(kAudioObjectSystemObject, &property_address, ca_stream_format_changed, u);
+
+ pa_xfree(u->device_name);
+ pa_xfree(u->vendor_name);
+ pa_rtpoll_free(u->rtpoll);
+ pa_card_free(u->card);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-always-sink.c b/src/modules/module-always-sink.c
index aee1c650..4c871da4 100644
--- a/src/modules/module-always-sink.c
+++ b/src/modules/module-always-sink.c
@@ -24,18 +24,18 @@
#endif
#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
#include <pulsecore/core.h>
-#include <pulsecore/sink-input.h>
+#include <pulsecore/sink.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
-#include <pulsecore/namereg.h>
#include <pulsecore/core-util.h>
#include "module-always-sink-symdef.h"
PA_MODULE_AUTHOR("Colin Guthrie");
-PA_MODULE_DESCRIPTION("Always keeps at least one sink loaded even if it's a null one");
+PA_MODULE_DESCRIPTION(_("Always keeps at least one sink loaded even if it's a null one"));
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
PA_MODULE_USAGE(
@@ -78,7 +78,8 @@ static void load_null_sink_if_needed(pa_core *c, pa_sink *sink, struct userdata*
u->ignore = TRUE;
- t = pa_sprintf_malloc("sink_name=%s", u->sink_name);
+ t = pa_sprintf_malloc("sink_name=%s sink_properties='device.description=\"%s\"'", u->sink_name,
+ _("Dummy Output"));
m = pa_module_load(c, "module-null-sink", t);
u->null_module = m ? m->index : PA_INVALID_INDEX;
pa_xfree(t);
diff --git a/src/modules/module-augment-properties.c b/src/modules/module-augment-properties.c
index c3e5997a..05f6f0a4 100644
--- a/src/modules/module-augment-properties.c
+++ b/src/modules/module-augment-properties.c
@@ -24,12 +24,11 @@
#endif
#include <sys/stat.h>
+#include <dirent.h>
+#include <time.h>
#include <pulse/xmalloc.h>
-#include <pulse/volume.h>
-#include <pulse/channelmap.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
@@ -58,6 +57,7 @@ struct rule {
char *process_name;
char *application_name;
char *icon_name;
+ char *role;
pa_proplist *proplist;
};
@@ -72,12 +72,21 @@ static void rule_free(struct rule *r) {
pa_xfree(r->process_name);
pa_xfree(r->application_name);
pa_xfree(r->icon_name);
+ pa_xfree(r->role);
if (r->proplist)
pa_proplist_free(r->proplist);
pa_xfree(r);
}
-static int parse_properties(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
+static int parse_properties(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
struct rule *r = userdata;
pa_proplist *n;
@@ -93,11 +102,56 @@ static int parse_properties(const char *filename, unsigned line, const char *sec
return 0;
}
-static int check_type(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
+static int parse_categories(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
+ struct rule *r = userdata;
+ const char *state = NULL;
+ char *c;
+
+ while ((c = pa_split(rvalue, ";", &state))) {
+
+ if (pa_streq(c, "Game")) {
+ pa_xfree(r->role);
+ r->role = pa_xstrdup("game");
+ } else if (pa_streq(c, "Telephony")) {
+ pa_xfree(r->role);
+ r->role = pa_xstrdup("phone");
+ }
+
+ pa_xfree(c);
+ }
+
+ return 0;
+}
+
+static int check_type(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
return pa_streq(rvalue, "Application") ? 0 : -1;
}
-static int catch_all(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
+static int catch_all(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const char *lvalue,
+ const char *rvalue,
+ void *data,
+ void *userdata) {
+
return 0;
}
@@ -109,29 +163,65 @@ static void update_rule(struct rule *r) {
{ "Icon", pa_config_parse_string, NULL, "Desktop Entry" },
{ "Type", check_type, NULL, "Desktop Entry" },
{ "X-PulseAudio-Properties", parse_properties, NULL, "Desktop Entry" },
+ { "Categories", parse_categories, NULL, "Desktop Entry" },
{ NULL, catch_all, NULL, NULL },
{ NULL, NULL, NULL, NULL },
};
+ pa_bool_t found = FALSE;
pa_assert(r);
fn = pa_sprintf_malloc(DESKTOPFILEDIR PA_PATH_SEP "%s.desktop", r->process_name);
- if (stat(fn, &st) < 0) {
+ if (stat(fn, &st) == 0)
+ found = TRUE;
+ else {
+#ifdef DT_DIR
+ DIR *desktopfiles_dir;
+ struct dirent *dir;
+
+ /* Let's try a more aggressive search, but only one level */
+ if ((desktopfiles_dir = opendir(DESKTOPFILEDIR))) {
+ while ((dir = readdir(desktopfiles_dir))) {
+ if (dir->d_type != DT_DIR
+ || strcmp(dir->d_name, ".") == 0
+ || strcmp(dir->d_name, "..") == 0)
+ continue;
+
+ pa_xfree(fn);
+ fn = pa_sprintf_malloc(DESKTOPFILEDIR PA_PATH_SEP "%s" PA_PATH_SEP "%s.desktop", dir->d_name, r->process_name);
+
+ if (stat(fn, &st) == 0) {
+ found = TRUE;
+ break;
+ }
+ }
+ closedir(desktopfiles_dir);
+ }
+#endif
+ }
+ if (!found) {
r->good = FALSE;
pa_xfree(fn);
return;
}
- if (r->good && st.st_mtime == r->mtime) {
- pa_xfree(fn);
- return;
- }
+ if (r->good) {
+ if (st.st_mtime == r->mtime) {
+ /* Theoretically the filename could have changed, but if so
+ having the same mtime is very unlikely so not worth tracking it in r */
+ pa_xfree(fn);
+ return;
+ }
+ pa_log_debug("Found %s (which has been updated since we last checked).", fn);
+ } else
+ pa_log_debug("Found %s.", fn);
r->good = TRUE;
r->mtime = st.st_mtime;
pa_xfree(r->application_name);
pa_xfree(r->icon_name);
- r->application_name = r->icon_name = NULL;
+ pa_xfree(r->role);
+ r->application_name = r->icon_name = r->role = NULL;
if (r->proplist)
pa_proplist_clear(r->proplist);
@@ -151,6 +241,9 @@ static void apply_rule(struct rule *r, pa_proplist *p) {
if (!r->good)
return;
+ if (r->proplist)
+ pa_proplist_update(p, PA_UPDATE_MERGE, r->proplist);
+
if (r->icon_name)
if (!pa_proplist_contains(p, PA_PROP_APPLICATION_ICON_NAME))
pa_proplist_sets(p, PA_PROP_APPLICATION_ICON_NAME, r->icon_name);
@@ -164,8 +257,9 @@ static void apply_rule(struct rule *r, pa_proplist *p) {
pa_proplist_sets(p, PA_PROP_APPLICATION_NAME, r->application_name);
}
- if (r->proplist)
- pa_proplist_update(p, PA_UPDATE_MERGE, r->proplist);
+ if (r->role)
+ if (!pa_proplist_contains(p, PA_PROP_MEDIA_ROLE))
+ pa_proplist_sets(p, PA_PROP_MEDIA_ROLE, r->role);
}
static void make_room(pa_hashmap *cache) {
@@ -259,7 +353,7 @@ fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
}
void pa__done(pa_module *m) {
diff --git a/src/modules/module-card-restore.c b/src/modules/module-card-restore.c
index 85478d12..fc5df5f6 100644
--- a/src/modules/module-card-restore.c
+++ b/src/modules/module-card-restore.c
@@ -29,12 +29,11 @@
#include <sys/types.h>
#include <stdio.h>
#include <stdlib.h>
-#include <ctype.h>
+#include <pulse/gccmacro.h>
#include <pulse/xmalloc.h>
-#include <pulse/volume.h>
#include <pulse/timeval.h>
-#include <pulse/util.h>
+#include <pulse/rtclock.h>
#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
@@ -45,6 +44,7 @@
#include <pulsecore/card.h>
#include <pulsecore/namereg.h>
#include <pulsecore/database.h>
+#include <pulsecore/tagstruct.h>
#include "module-card-restore-symdef.h"
@@ -53,7 +53,7 @@ PA_MODULE_DESCRIPTION("Automatically restore profile of cards");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
-#define SAVE_INTERVAL 10
+#define SAVE_INTERVAL (10 * PA_USEC_PER_SEC)
static const char* const valid_modargs[] = {
NULL
@@ -72,15 +72,14 @@ struct userdata {
struct entry {
uint8_t version;
- char profile[PA_NAME_MAX];
-} PA_GCC_PACKED ;
+ char *profile;
+};
-static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *tv, void *userdata) {
+static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *t, void *userdata) {
struct userdata *u = userdata;
pa_assert(a);
pa_assert(e);
- pa_assert(tv);
pa_assert(u);
pa_assert(e == u->save_time_event);
@@ -91,11 +90,95 @@ static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct
pa_log_info("Synced.");
}
-static struct entry* read_entry(struct userdata *u, const char *name) {
+static void trigger_save(struct userdata *u) {
+ if (u->save_time_event)
+ return;
+
+ u->save_time_event = pa_core_rttime_new(u->core, pa_rtclock_now() + SAVE_INTERVAL, save_time_callback, u);
+}
+
+static struct entry* entry_new(void) {
+ struct entry *r = pa_xnew0(struct entry, 1);
+ r->version = ENTRY_VERSION;
+ return r;
+}
+
+static void entry_free(struct entry* e) {
+ pa_assert(e);
+
+ pa_xfree(e->profile);
+ pa_xfree(e);
+}
+
+static pa_bool_t entry_write(struct userdata *u, const char *name, const struct entry *e) {
+ pa_tagstruct *t;
pa_datum key, data;
+ pa_bool_t r;
+
+ pa_assert(u);
+ pa_assert(name);
+ pa_assert(e);
+
+ t = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu8(t, e->version);
+ pa_tagstruct_puts(t, e->profile);
+
+ key.data = (char *) name;
+ key.size = strlen(name);
+
+ data.data = (void*)pa_tagstruct_data(t, &data.size);
+
+ r = (pa_database_set(u->database, &key, &data, TRUE) == 0);
+
+ pa_tagstruct_free(t);
+
+ return r;
+}
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+
+#define LEGACY_ENTRY_VERSION 1
+static struct entry* legacy_entry_read(struct userdata *u, pa_datum *data) {
+ struct legacy_entry {
+ uint8_t version;
+ char profile[PA_NAME_MAX];
+ } PA_GCC_PACKED ;
+ struct legacy_entry *le;
struct entry *e;
pa_assert(u);
+ pa_assert(data);
+
+ if (data->size != sizeof(struct legacy_entry)) {
+ pa_log_debug("Size does not match.");
+ return NULL;
+ }
+
+ le = (struct legacy_entry*)data->data;
+
+ if (le->version != LEGACY_ENTRY_VERSION) {
+ pa_log_debug("Version mismatch.");
+ return NULL;
+ }
+
+ if (!memchr(le->profile, 0, sizeof(le->profile))) {
+ pa_log_warn("Profile has missing NUL byte.");
+ return NULL;
+ }
+
+ e = entry_new();
+ e->profile = pa_xstrdup(le->profile);
+ return e;
+}
+#endif
+
+static struct entry* entry_read(struct userdata *u, const char *name) {
+ pa_datum key, data;
+ struct entry *e = NULL;
+ pa_tagstruct *t = NULL;
+ const char* profile;
+
+ pa_assert(u);
pa_assert(name);
key.data = (char*) name;
@@ -106,46 +189,54 @@ static struct entry* read_entry(struct userdata *u, const char *name) {
if (!pa_database_get(u->database, &key, &data))
goto fail;
- if (data.size != sizeof(struct entry)) {
- pa_log_debug("Database contains entry for card %s of wrong size %lu != %lu. Probably due to upgrade, ignoring.", name, (unsigned long) data.size, (unsigned long) sizeof(struct entry));
- goto fail;
- }
+ t = pa_tagstruct_new(data.data, data.size);
+ e = entry_new();
- e = (struct entry*) data.data;
+ if (pa_tagstruct_getu8(t, &e->version) < 0 ||
+ e->version > ENTRY_VERSION ||
+ pa_tagstruct_gets(t, &profile) < 0) {
- if (e->version != ENTRY_VERSION) {
- pa_log_debug("Version of database entry for card %s doesn't match our version. Probably due to upgrade, ignoring.", name);
goto fail;
}
- if (!memchr(e->profile, 0, sizeof(e->profile))) {
- pa_log_warn("Database contains entry for card %s with missing NUL byte in profile name", name);
+ e->profile = pa_xstrdup(profile);
+
+ if (!pa_tagstruct_eof(t))
goto fail;
- }
+
+ pa_tagstruct_free(t);
+ pa_datum_free(&data);
return e;
fail:
+ pa_log_debug("Database contains invalid data for key: %s (probably pre-v1.0 data)", name);
+
+ if (e)
+ entry_free(e);
+ if (t)
+ pa_tagstruct_free(t);
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+ pa_log_debug("Attempting to load legacy (pre-v1.0) data for key: %s", name);
+ if ((e = legacy_entry_read(u, &data))) {
+ pa_log_debug("Success. Saving new format for key: %s", name);
+ if (entry_write(u, name, e))
+ trigger_save(u);
+ pa_datum_free(&data);
+ return e;
+ } else
+ pa_log_debug("Unable to load legacy (pre-v1.0) data for key: %s. Ignoring.", name);
+#endif
+
pa_datum_free(&data);
return NULL;
}
-static void trigger_save(struct userdata *u) {
- struct timeval tv;
-
- if (u->save_time_event)
- return;
-
- pa_gettimeofday(&tv);
- tv.tv_sec += SAVE_INTERVAL;
- u->save_time_event = u->core->mainloop->time_new(u->core->mainloop, &tv, save_time_callback, u);
-}
-
static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
struct userdata *u = userdata;
- struct entry entry, *old;
- pa_datum key, data;
+ struct entry *entry, *old;
pa_card *card;
pa_assert(c);
@@ -155,8 +246,7 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
t != (PA_SUBSCRIPTION_EVENT_CARD|PA_SUBSCRIPTION_EVENT_CHANGE))
return;
- pa_zero(entry);
- entry.version = ENTRY_VERSION;
+ entry = entry_new();
if (!(card = pa_idxset_get_by_index(c->cards, idx)))
return;
@@ -164,29 +254,25 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
if (!card->save_profile)
return;
- pa_strlcpy(entry.profile, card->active_profile ? card->active_profile->name : "", sizeof(entry.profile));
+ entry->profile = pa_xstrdup(card->active_profile ? card->active_profile->name : "");
- if ((old = read_entry(u, card->name))) {
+ if ((old = entry_read(u, card->name))) {
- if (strncmp(old->profile, entry.profile, sizeof(entry.profile)) == 0) {
- pa_xfree(old);
+ if (pa_streq(old->profile, entry->profile)) {
+ entry_free(old);
+ entry_free(entry);
return;
}
- pa_xfree(old);
+ entry_free(old);
}
- key.data = card->name;
- key.size = strlen(card->name);
-
- data.data = &entry;
- data.size = sizeof(entry);
-
pa_log_info("Storing profile for card %s.", card->name);
- pa_database_set(u->database, &key, &data, TRUE);
+ if (entry_write(u, card->name, entry))
+ trigger_save(u);
- trigger_save(u);
+ entry_free(entry);
}
static pa_hook_result_t card_new_hook_callback(pa_core *c, pa_card_new_data *new_data, struct userdata *u) {
@@ -194,15 +280,16 @@ static pa_hook_result_t card_new_hook_callback(pa_core *c, pa_card_new_data *new
pa_assert(new_data);
- if ((e = read_entry(u, new_data->name)) && e->profile[0]) {
+ if ((e = entry_read(u, new_data->name)) && e->profile[0]) {
if (!new_data->active_profile) {
- pa_card_new_data_set_profile(new_data, e->profile);
pa_log_info("Restoring profile for card %s.", new_data->name);
+ pa_card_new_data_set_profile(new_data, e->profile);
+ new_data->save_profile = TRUE;
} else
pa_log_debug("Not restoring profile for card %s, because already set.", new_data->name);
- pa_xfree(e);
+ entry_free(e);
}
return PA_HOOK_OK;
@@ -222,11 +309,9 @@ int pa__init(pa_module*m) {
goto fail;
}
- m->userdata = u = pa_xnew(struct userdata, 1);
+ m->userdata = u = pa_xnew0(struct userdata, 1);
u->core = m->core;
u->module = m;
- u->save_time_event = NULL;
- u->database = NULL;
u->subscription = pa_subscription_new(m->core, PA_SUBSCRIPTION_MASK_CARD, subscribe_callback, u);
@@ -241,7 +326,7 @@ int pa__init(pa_module*m) {
goto fail;
}
- pa_log_info("Sucessfully opened database file '%s'.", fname);
+ pa_log_info("Successfully opened database file '%s'.", fname);
pa_xfree(fname);
for (card = pa_idxset_first(m->core->cards, &idx); card; card = pa_idxset_next(m->core->cards, &idx))
@@ -256,7 +341,7 @@ fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
}
void pa__done(pa_module*m) {
diff --git a/src/modules/module-cli.c b/src/modules/module-cli.c
index fd9452b4..2a1d1751 100644
--- a/src/modules/module-cli.c
+++ b/src/modules/module-cli.c
@@ -25,6 +25,8 @@
#include <stdio.h>
#include <unistd.h>
+#include <fcntl.h>
+#include <errno.h>
#include <pulsecore/module.h>
#include <pulsecore/iochannel.h>
@@ -33,6 +35,7 @@
#include <pulsecore/log.h>
#include <pulsecore/modargs.h>
#include <pulsecore/macro.h>
+#include <pulsecore/core-util.h>
#include "module-cli-symdef.h"
@@ -69,6 +72,9 @@ int pa__init(pa_module*m) {
pa_iochannel *io;
pa_modargs *ma;
pa_bool_t exit_on_eof = FALSE;
+#ifndef OS_IS_WIN32
+ int fd;
+#endif
pa_assert(m);
@@ -88,15 +94,32 @@ int pa__init(pa_module*m) {
}
if (pa_stdio_acquire() < 0) {
- pa_log("STDIN/STDUSE already in use.");
+ pa_log("STDIN/STDOUT already in use.");
goto fail;
}
- io = pa_iochannel_new(m->core->mainloop, STDIN_FILENO, STDOUT_FILENO);
- pa_iochannel_set_noclose(io, 1);
+ /* We try to open the controlling tty anew here. This has the
+ * benefit of giving us a new fd that doesn't share the O_NDELAY
+ * flag with fds 0, 1, or 2. Since pa_iochannel_xxx needs O_NDELAY
+ * on its fd using those fds directly could set O_NDELAY which
+ * fprintf() doesn't really like, resulting in truncated output
+ * of log messages, particularly because if stdout and stderr are
+ * dup'ed they share the same O_NDELAY, too. */
+
+#ifndef OS_IS_WIN32
+ if ((fd = pa_open_cloexec("/dev/tty", O_RDWR|O_NONBLOCK, 0)) >= 0) {
+ io = pa_iochannel_new(m->core->mainloop, fd, fd);
+ pa_log_debug("Managed to open /dev/tty.");
+ }
+ else
+#endif
+ {
+ io = pa_iochannel_new(m->core->mainloop, STDIN_FILENO, STDOUT_FILENO);
+ pa_iochannel_set_noclose(io, TRUE);
+ pa_log_debug("Failed to open /dev/tty, using stdin/stdout fds instead.");
+ }
m->userdata = pa_cli_new(m->core, io, m);
-
pa_cli_set_eof_callback(m->userdata, exit_on_eof ? eof_and_exit_cb : eof_and_unload_cb, m);
pa_modargs_free(ma);
@@ -114,7 +137,7 @@ fail:
void pa__done(pa_module*m) {
pa_assert(m);
- if (m->core->running_as_daemon == 0) {
+ if (m->userdata) {
pa_cli_free(m->userdata);
pa_stdio_release();
}
diff --git a/src/modules/module-combine-sink.c b/src/modules/module-combine-sink.c
new file mode 100644
index 00000000..5d29af4b
--- /dev/null
+++ b/src/modules/module-combine-sink.c
@@ -0,0 +1,1414 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2008 Lennart Poettering
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdio.h>
+#include <errno.h>
+
+#include <pulse/rtclock.h>
+#include <pulse/timeval.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/macro.h>
+#include <pulsecore/module.h>
+#include <pulsecore/llist.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/sink-input.h>
+#include <pulsecore/memblockq.h>
+#include <pulsecore/log.h>
+#include <pulsecore/core-rtclock.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/thread.h>
+#include <pulsecore/thread-mq.h>
+#include <pulsecore/rtpoll.h>
+#include <pulsecore/time-smoother.h>
+#include <pulsecore/strlist.h>
+
+#include "module-combine-sink-symdef.h"
+
+PA_MODULE_AUTHOR("Lennart Poettering");
+PA_MODULE_DESCRIPTION("Combine multiple sinks to one");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE(
+ "sink_name=<name for the sink> "
+ "sink_properties=<properties for the sink> "
+ "slaves=<slave sinks> "
+ "adjust_time=<how often to readjust rates in s> "
+ "resample_method=<method> "
+ "format=<sample format> "
+ "rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<channel map>");
+
+#define DEFAULT_SINK_NAME "combined"
+
+#define MEMBLOCKQ_MAXLENGTH (1024*1024*16)
+
+#define DEFAULT_ADJUST_TIME_USEC (10*PA_USEC_PER_SEC)
+
+#define BLOCK_USEC (PA_USEC_PER_MSEC * 200)
+
+static const char* const valid_modargs[] = {
+ "sink_name",
+ "sink_properties",
+ "slaves",
+ "adjust_time",
+ "resample_method",
+ "format",
+ "rate",
+ "channels",
+ "channel_map",
+ NULL
+};
+
+struct output {
+ struct userdata *userdata;
+
+ pa_sink *sink;
+ pa_sink_input *sink_input;
+ pa_bool_t ignore_state_change;
+
+ pa_asyncmsgq *inq, /* Message queue from the sink thread to this sink input */
+ *outq; /* Message queue from this sink input to the sink thread */
+ pa_rtpoll_item *inq_rtpoll_item_read, *inq_rtpoll_item_write;
+ pa_rtpoll_item *outq_rtpoll_item_read, *outq_rtpoll_item_write;
+
+ pa_memblockq *memblockq;
+
+ /* For communication of the stream latencies to the main thread */
+ pa_usec_t total_latency;
+
+ /* For coomunication of the stream parameters to the sink thread */
+ pa_atomic_t max_request;
+ pa_atomic_t requested_latency;
+
+ PA_LLIST_FIELDS(struct output);
+};
+
+struct userdata {
+ pa_core *core;
+ pa_module *module;
+ pa_sink *sink;
+
+ pa_thread *thread;
+ pa_thread_mq thread_mq;
+ pa_rtpoll *rtpoll;
+
+ pa_time_event *time_event;
+ pa_usec_t adjust_time;
+
+ pa_bool_t automatic;
+ pa_bool_t auto_desc;
+
+ pa_strlist *unlinked_slaves;
+
+ pa_hook_slot *sink_put_slot, *sink_unlink_slot, *sink_state_changed_slot;
+
+ pa_resample_method_t resample_method;
+
+ pa_usec_t block_usec;
+
+ pa_idxset* outputs; /* managed in main context */
+
+ struct {
+ PA_LLIST_HEAD(struct output, active_outputs); /* managed in IO thread context */
+ pa_atomic_t running; /* we cache that value here, so that every thread can query it cheaply */
+ pa_usec_t timestamp;
+ pa_bool_t in_null_mode;
+ pa_smoother *smoother;
+ uint64_t counter;
+ } thread_info;
+};
+
+enum {
+ SINK_MESSAGE_ADD_OUTPUT = PA_SINK_MESSAGE_MAX,
+ SINK_MESSAGE_REMOVE_OUTPUT,
+ SINK_MESSAGE_NEED,
+ SINK_MESSAGE_UPDATE_LATENCY,
+ SINK_MESSAGE_UPDATE_MAX_REQUEST,
+ SINK_MESSAGE_UPDATE_REQUESTED_LATENCY
+};
+
+enum {
+ SINK_INPUT_MESSAGE_POST = PA_SINK_INPUT_MESSAGE_MAX,
+};
+
+static void output_disable(struct output *o);
+static void output_enable(struct output *o);
+static void output_free(struct output *o);
+static int output_create_sink_input(struct output *o);
+
+static void adjust_rates(struct userdata *u) {
+ struct output *o;
+ pa_usec_t max_sink_latency = 0, min_total_latency = (pa_usec_t) -1, target_latency, avg_total_latency = 0;
+ uint32_t base_rate;
+ uint32_t idx;
+ unsigned n = 0;
+
+ pa_assert(u);
+ pa_sink_assert_ref(u->sink);
+
+ if (pa_idxset_size(u->outputs) <= 0)
+ return;
+
+ if (!PA_SINK_IS_OPENED(pa_sink_get_state(u->sink)))
+ return;
+
+ PA_IDXSET_FOREACH(o, u->outputs, idx) {
+ pa_usec_t sink_latency;
+
+ if (!o->sink_input || !PA_SINK_IS_OPENED(pa_sink_get_state(o->sink)))
+ continue;
+
+ o->total_latency = pa_sink_input_get_latency(o->sink_input, &sink_latency);
+ o->total_latency += sink_latency;
+
+ if (sink_latency > max_sink_latency)
+ max_sink_latency = sink_latency;
+
+ if (min_total_latency == (pa_usec_t) -1 || o->total_latency < min_total_latency)
+ min_total_latency = o->total_latency;
+
+ avg_total_latency += o->total_latency;
+ n++;
+
+ pa_log_debug("[%s] total=%0.2fms sink=%0.2fms ", o->sink->name, (double) o->total_latency / PA_USEC_PER_MSEC, (double) sink_latency / PA_USEC_PER_MSEC);
+
+ if (o->total_latency > 10*PA_USEC_PER_SEC)
+ pa_log_warn("[%s] Total latency of output is very high (%0.2fms), most likely the audio timing in one of your drivers is broken.", o->sink->name, (double) o->total_latency / PA_USEC_PER_MSEC);
+ }
+
+ if (min_total_latency == (pa_usec_t) -1)
+ return;
+
+ avg_total_latency /= n;
+
+ target_latency = max_sink_latency > min_total_latency ? max_sink_latency : min_total_latency;
+
+ pa_log_info("[%s] avg total latency is %0.2f msec.", u->sink->name, (double) avg_total_latency / PA_USEC_PER_MSEC);
+ pa_log_info("[%s] target latency is %0.2f msec.", u->sink->name, (double) target_latency / PA_USEC_PER_MSEC);
+
+ base_rate = u->sink->sample_spec.rate;
+
+ PA_IDXSET_FOREACH(o, u->outputs, idx) {
+ uint32_t new_rate = base_rate;
+ uint32_t current_rate = o->sink_input->sample_spec.rate;
+
+ if (!o->sink_input || !PA_SINK_IS_OPENED(pa_sink_get_state(o->sink)))
+ continue;
+
+ if (o->total_latency != target_latency)
+ new_rate += (uint32_t) (((double) o->total_latency - (double) target_latency) / (double) u->adjust_time * (double) new_rate);
+
+ if (new_rate < (uint32_t) (base_rate*0.8) || new_rate > (uint32_t) (base_rate*1.25)) {
+ pa_log_warn("[%s] sample rates too different, not adjusting (%u vs. %u).", o->sink_input->sink->name, base_rate, new_rate);
+ new_rate = base_rate;
+ } else {
+ if (base_rate < new_rate + 20 && new_rate < base_rate + 20)
+ new_rate = base_rate;
+ /* Do the adjustment in small steps; 2‰ can be considered inaudible */
+ if (new_rate < (uint32_t) (current_rate*0.998) || new_rate > (uint32_t) (current_rate*1.002)) {
+ pa_log_info("[%s] new rate of %u Hz not within 2‰ of %u Hz, forcing smaller adjustment", o->sink_input->sink->name, new_rate, current_rate);
+ new_rate = PA_CLAMP(new_rate, (uint32_t) (current_rate*0.998), (uint32_t) (current_rate*1.002));
+ }
+ pa_log_info("[%s] new rate is %u Hz; ratio is %0.3f; latency is %0.2f msec.", o->sink_input->sink->name, new_rate, (double) new_rate / base_rate, (double) o->total_latency / PA_USEC_PER_MSEC);
+ }
+ pa_sink_input_set_rate(o->sink_input, new_rate);
+ }
+
+ pa_asyncmsgq_send(u->sink->asyncmsgq, PA_MSGOBJECT(u->sink), SINK_MESSAGE_UPDATE_LATENCY, NULL, (int64_t) avg_total_latency, NULL);
+}
+
+static void time_callback(pa_mainloop_api *a, pa_time_event *e, const struct timeval *t, void *userdata) {
+ struct userdata *u = userdata;
+
+ pa_assert(u);
+ pa_assert(a);
+ pa_assert(u->time_event == e);
+
+ adjust_rates(u);
+
+ pa_core_rttime_restart(u->core, e, pa_rtclock_now() + u->adjust_time);
+}
+
+static void process_render_null(struct userdata *u, pa_usec_t now) {
+ size_t ate = 0;
+ pa_assert(u);
+
+ /* If we are not running, we cannot produce any data */
+ if (!pa_atomic_load(&u->thread_info.running))
+ return;
+
+ if (u->thread_info.in_null_mode)
+ u->thread_info.timestamp = now;
+
+ while (u->thread_info.timestamp < now + u->block_usec) {
+ pa_memchunk chunk;
+
+ pa_sink_render(u->sink, u->sink->thread_info.max_request, &chunk);
+ pa_memblock_unref(chunk.memblock);
+
+ u->thread_info.counter += chunk.length;
+
+/* pa_log_debug("Ate %lu bytes.", (unsigned long) chunk.length); */
+ u->thread_info.timestamp += pa_bytes_to_usec(chunk.length, &u->sink->sample_spec);
+
+ ate += chunk.length;
+
+ if (ate >= u->sink->thread_info.max_request)
+ break;
+ }
+
+/* pa_log_debug("Ate in sum %lu bytes (of %lu)", (unsigned long) ate, (unsigned long) nbytes); */
+
+ pa_smoother_put(u->thread_info.smoother, now,
+ pa_bytes_to_usec(u->thread_info.counter, &u->sink->sample_spec) - (u->thread_info.timestamp - now));
+}
+
+static void thread_func(void *userdata) {
+ struct userdata *u = userdata;
+
+ pa_assert(u);
+
+ pa_log_debug("Thread starting up");
+
+ if (u->core->realtime_scheduling)
+ pa_make_realtime(u->core->realtime_priority+1);
+
+ pa_thread_mq_install(&u->thread_mq);
+
+ u->thread_info.timestamp = pa_rtclock_now();
+ u->thread_info.in_null_mode = FALSE;
+
+ for (;;) {
+ int ret;
+
+ if (PA_SINK_IS_OPENED(u->sink->thread_info.state))
+ if (u->sink->thread_info.rewind_requested)
+ pa_sink_process_rewind(u->sink, 0);
+
+ /* If no outputs are connected, render some data and drop it immediately. */
+ if (PA_SINK_IS_OPENED(u->sink->thread_info.state) && !u->thread_info.active_outputs) {
+ pa_usec_t now;
+
+ now = pa_rtclock_now();
+
+ if (!u->thread_info.in_null_mode || u->thread_info.timestamp <= now)
+ process_render_null(u, now);
+
+ pa_rtpoll_set_timer_absolute(u->rtpoll, u->thread_info.timestamp);
+ u->thread_info.in_null_mode = TRUE;
+ } else {
+ pa_rtpoll_set_timer_disabled(u->rtpoll);
+ u->thread_info.in_null_mode = FALSE;
+ }
+
+ /* Hmm, nothing to do. Let's sleep */
+ if ((ret = pa_rtpoll_run(u->rtpoll, TRUE)) < 0) {
+ pa_log_info("pa_rtpoll_run() = %i", ret);
+ goto fail;
+ }
+
+ if (ret == 0)
+ goto finish;
+ }
+
+fail:
+ /* If this was no regular exit from the loop we have to continue
+ * processing messages until we received PA_MESSAGE_SHUTDOWN */
+ pa_asyncmsgq_post(u->thread_mq.outq, PA_MSGOBJECT(u->core), PA_CORE_MESSAGE_UNLOAD_MODULE, u->module, 0, NULL, NULL);
+ pa_asyncmsgq_wait_for(u->thread_mq.inq, PA_MESSAGE_SHUTDOWN);
+
+finish:
+ pa_log_debug("Thread shutting down");
+}
+
+/* Called from I/O thread context */
+static void render_memblock(struct userdata *u, struct output *o, size_t length) {
+ pa_assert(u);
+ pa_assert(o);
+
+ /* We are run by the sink thread, on behalf of an output (o). The
+ * output is waiting for us, hence it is safe to access its
+ * mainblockq and asyncmsgq directly. */
+
+ /* If we are not running, we cannot produce any data */
+ if (!pa_atomic_load(&u->thread_info.running))
+ return;
+
+ /* Maybe there's some data in the requesting output's queue
+ * now? */
+ while (pa_asyncmsgq_process_one(o->inq) > 0)
+ ;
+
+ /* Ok, now let's prepare some data if we really have to */
+ while (!pa_memblockq_is_readable(o->memblockq)) {
+ struct output *j;
+ pa_memchunk chunk;
+
+ /* Render data! */
+ pa_sink_render(u->sink, length, &chunk);
+
+ u->thread_info.counter += chunk.length;
+
+ /* OK, let's send this data to the other threads */
+ PA_LLIST_FOREACH(j, u->thread_info.active_outputs) {
+ if (j == o)
+ continue;
+
+ pa_asyncmsgq_post(j->inq, PA_MSGOBJECT(j->sink_input), SINK_INPUT_MESSAGE_POST, NULL, 0, &chunk, NULL);
+ }
+
+ /* And place it directly into the requesting output's queue */
+ pa_memblockq_push_align(o->memblockq, &chunk);
+ pa_memblock_unref(chunk.memblock);
+ }
+}
+
+/* Called from I/O thread context */
+static void request_memblock(struct output *o, size_t length) {
+ pa_assert(o);
+ pa_sink_input_assert_ref(o->sink_input);
+ pa_sink_assert_ref(o->userdata->sink);
+
+ /* If another thread already prepared some data we received
+ * the data over the asyncmsgq, hence let's first process
+ * it. */
+ while (pa_asyncmsgq_process_one(o->inq) > 0)
+ ;
+
+ /* Check whether we're now readable */
+ if (pa_memblockq_is_readable(o->memblockq))
+ return;
+
+ /* OK, we need to prepare new data, but only if the sink is actually running */
+ if (pa_atomic_load(&o->userdata->thread_info.running))
+ pa_asyncmsgq_send(o->outq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_NEED, o, (int64_t) length, NULL);
+}
+
+/* Called from I/O thread context */
+static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk) {
+ struct output *o;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ /* If necessary, get some new data */
+ request_memblock(o, nbytes);
+
+ /* pa_log("%s q size is %u + %u (%u/%u)", */
+ /* i->sink->name, */
+ /* pa_memblockq_get_nblocks(o->memblockq), */
+ /* pa_memblockq_get_nblocks(i->thread_info.render_memblockq), */
+ /* pa_memblockq_get_maxrewind(o->memblockq), */
+ /* pa_memblockq_get_maxrewind(i->thread_info.render_memblockq)); */
+
+ if (pa_memblockq_peek(o->memblockq, chunk) < 0)
+ return -1;
+
+ pa_memblockq_drop(o->memblockq, chunk->length);
+
+ return 0;
+}
+
+/* Called from I/O thread context */
+static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct output *o;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ pa_memblockq_rewind(o->memblockq, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct output *o;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ pa_memblockq_set_maxrewind(o->memblockq, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
+ struct output *o;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ if (pa_atomic_load(&o->max_request) == (int) nbytes)
+ return;
+
+ pa_atomic_store(&o->max_request, (int) nbytes);
+ pa_asyncmsgq_post(o->outq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_UPDATE_MAX_REQUEST, NULL, 0, NULL, NULL);
+}
+
+/* Called from thread context */
+static void sink_input_update_sink_requested_latency_cb(pa_sink_input *i) {
+ struct output *o;
+ pa_usec_t c;
+
+ pa_assert(i);
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ c = pa_sink_get_requested_latency_within_thread(i->sink);
+
+ if (c == (pa_usec_t) -1)
+ c = i->sink->thread_info.max_latency;
+
+ if (pa_atomic_load(&o->requested_latency) == (int) c)
+ return;
+
+ pa_atomic_store(&o->requested_latency, (int) c);
+ pa_asyncmsgq_post(o->outq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_UPDATE_REQUESTED_LATENCY, NULL, 0, NULL, NULL);
+}
+
+/* Called from I/O thread context */
+static void sink_input_attach_cb(pa_sink_input *i) {
+ struct output *o;
+ pa_usec_t c;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ /* Set up the queue from the sink thread to us */
+ pa_assert(!o->inq_rtpoll_item_read && !o->outq_rtpoll_item_write);
+
+ o->inq_rtpoll_item_read = pa_rtpoll_item_new_asyncmsgq_read(
+ i->sink->thread_info.rtpoll,
+ PA_RTPOLL_LATE, /* This one is not that important, since we check for data in _peek() anyway. */
+ o->inq);
+
+ o->outq_rtpoll_item_write = pa_rtpoll_item_new_asyncmsgq_write(
+ i->sink->thread_info.rtpoll,
+ PA_RTPOLL_EARLY,
+ o->outq);
+
+ pa_sink_input_request_rewind(i, 0, FALSE, TRUE, TRUE);
+
+ pa_atomic_store(&o->max_request, (int) pa_sink_input_get_max_request(i));
+
+ c = pa_sink_get_requested_latency_within_thread(i->sink);
+ pa_atomic_store(&o->requested_latency, (int) (c == (pa_usec_t) -1 ? 0 : c));
+
+ pa_asyncmsgq_post(o->outq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_UPDATE_MAX_REQUEST, NULL, 0, NULL, NULL);
+ pa_asyncmsgq_post(o->outq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_UPDATE_REQUESTED_LATENCY, NULL, 0, NULL, NULL);
+}
+
+/* Called from I/O thread context */
+static void sink_input_detach_cb(pa_sink_input *i) {
+ struct output *o;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ if (o->inq_rtpoll_item_read) {
+ pa_rtpoll_item_free(o->inq_rtpoll_item_read);
+ o->inq_rtpoll_item_read = NULL;
+ }
+
+ if (o->outq_rtpoll_item_write) {
+ pa_rtpoll_item_free(o->outq_rtpoll_item_write);
+ o->outq_rtpoll_item_write = NULL;
+ }
+}
+
+/* Called from main context */
+static void sink_input_kill_cb(pa_sink_input *i) {
+ struct output *o;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(o = i->userdata);
+
+ pa_module_unload_request(o->userdata->module, TRUE);
+ output_free(o);
+}
+
+/* Called from thread context */
+static int sink_input_process_msg(pa_msgobject *obj, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct output *o = PA_SINK_INPUT(obj)->userdata;
+
+ switch (code) {
+
+ case PA_SINK_INPUT_MESSAGE_GET_LATENCY: {
+ pa_usec_t *r = data;
+
+ *r = pa_bytes_to_usec(pa_memblockq_get_length(o->memblockq), &o->sink_input->sample_spec);
+
+ /* Fall through, the default handler will add in the extra
+ * latency added by the resampler */
+ break;
+ }
+
+ case SINK_INPUT_MESSAGE_POST:
+
+ if (PA_SINK_IS_OPENED(o->sink_input->sink->thread_info.state))
+ pa_memblockq_push_align(o->memblockq, chunk);
+ else
+ pa_memblockq_flush_write(o->memblockq, TRUE);
+
+ return 0;
+ }
+
+ return pa_sink_input_process_msg(obj, code, data, offset, chunk);
+}
+
+/* Called from main context */
+static void suspend(struct userdata *u) {
+ struct output *o;
+ uint32_t idx;
+
+ pa_assert(u);
+
+ /* Let's suspend by unlinking all streams */
+ PA_IDXSET_FOREACH(o, u->outputs, idx)
+ output_disable(o);
+
+ pa_log_info("Device suspended...");
+}
+
+/* Called from main context */
+static void unsuspend(struct userdata *u) {
+ struct output *o;
+ uint32_t idx;
+
+ pa_assert(u);
+
+ /* Let's resume */
+ PA_IDXSET_FOREACH(o, u->outputs, idx)
+ output_enable(o);
+
+ pa_log_info("Resumed successfully...");
+}
+
+/* Called from main context */
+static int sink_set_state(pa_sink *sink, pa_sink_state_t state) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(sink);
+ pa_assert_se(u = sink->userdata);
+
+ /* Please note that in contrast to the ALSA modules we call
+ * suspend/unsuspend from main context here! */
+
+ switch (state) {
+ case PA_SINK_SUSPENDED:
+ pa_assert(PA_SINK_IS_OPENED(pa_sink_get_state(u->sink)));
+
+ suspend(u);
+ break;
+
+ case PA_SINK_IDLE:
+ case PA_SINK_RUNNING:
+
+ if (pa_sink_get_state(u->sink) == PA_SINK_SUSPENDED)
+ unsuspend(u);
+
+ break;
+
+ case PA_SINK_UNLINKED:
+ case PA_SINK_INIT:
+ case PA_SINK_INVALID_STATE:
+ ;
+ }
+
+ return 0;
+}
+
+/* Called from IO context */
+static void update_max_request(struct userdata *u) {
+ size_t max_request = 0;
+ struct output *o;
+
+ pa_assert(u);
+ pa_sink_assert_io_context(u->sink);
+
+ /* Collects the max_request values of all streams and sets the
+ * largest one locally */
+
+ PA_LLIST_FOREACH(o, u->thread_info.active_outputs) {
+ size_t mr = (size_t) pa_atomic_load(&o->max_request);
+
+ if (mr > max_request)
+ max_request = mr;
+ }
+
+ if (max_request <= 0)
+ max_request = pa_usec_to_bytes(u->block_usec, &u->sink->sample_spec);
+
+ pa_sink_set_max_request_within_thread(u->sink, max_request);
+}
+
+/* Called from IO context */
+static void update_fixed_latency(struct userdata *u) {
+ pa_usec_t fixed_latency = 0;
+ struct output *o;
+
+ pa_assert(u);
+ pa_sink_assert_io_context(u->sink);
+
+ /* Collects the requested_latency values of all streams and sets
+ * the largest one as fixed_latency locally */
+
+ PA_LLIST_FOREACH(o, u->thread_info.active_outputs) {
+ pa_usec_t rl = (size_t) pa_atomic_load(&o->requested_latency);
+
+ if (rl > fixed_latency)
+ fixed_latency = rl;
+ }
+
+ if (fixed_latency <= 0)
+ fixed_latency = u->block_usec;
+
+ pa_sink_set_fixed_latency_within_thread(u->sink, fixed_latency);
+}
+
+/* Called from thread context of the io thread */
+static void output_add_within_thread(struct output *o) {
+ pa_assert(o);
+ pa_sink_assert_io_context(o->sink);
+
+ PA_LLIST_PREPEND(struct output, o->userdata->thread_info.active_outputs, o);
+
+ pa_assert(!o->outq_rtpoll_item_read && !o->inq_rtpoll_item_write);
+
+ o->outq_rtpoll_item_read = pa_rtpoll_item_new_asyncmsgq_read(
+ o->userdata->rtpoll,
+ PA_RTPOLL_EARLY-1, /* This item is very important */
+ o->outq);
+ o->inq_rtpoll_item_write = pa_rtpoll_item_new_asyncmsgq_write(
+ o->userdata->rtpoll,
+ PA_RTPOLL_EARLY,
+ o->inq);
+}
+
+/* Called from thread context of the io thread */
+static void output_remove_within_thread(struct output *o) {
+ pa_assert(o);
+ pa_sink_assert_io_context(o->sink);
+
+ PA_LLIST_REMOVE(struct output, o->userdata->thread_info.active_outputs, o);
+
+ if (o->outq_rtpoll_item_read) {
+ pa_rtpoll_item_free(o->outq_rtpoll_item_read);
+ o->outq_rtpoll_item_read = NULL;
+ }
+
+ if (o->inq_rtpoll_item_write) {
+ pa_rtpoll_item_free(o->inq_rtpoll_item_write);
+ o->inq_rtpoll_item_write = NULL;
+ }
+}
+
+/* Called from thread context of the io thread */
+static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SINK(o)->userdata;
+
+ switch (code) {
+
+ case PA_SINK_MESSAGE_SET_STATE: {
+ pa_bool_t running = (PA_PTR_TO_UINT(data) == PA_SINK_RUNNING);
+
+ pa_atomic_store(&u->thread_info.running, running);
+
+ if (running)
+ pa_smoother_resume(u->thread_info.smoother, pa_rtclock_now(), TRUE);
+ else
+ pa_smoother_pause(u->thread_info.smoother, pa_rtclock_now());
+
+ break;
+ }
+
+ case PA_SINK_MESSAGE_GET_LATENCY: {
+ pa_usec_t x, y, c, *delay = data;
+
+ x = pa_rtclock_now();
+ y = pa_smoother_get(u->thread_info.smoother, x);
+
+ c = pa_bytes_to_usec(u->thread_info.counter, &u->sink->sample_spec);
+
+ if (y < c)
+ *delay = c - y;
+ else
+ *delay = 0;
+
+ return 0;
+ }
+
+ case SINK_MESSAGE_ADD_OUTPUT:
+ output_add_within_thread(data);
+ update_max_request(u);
+ update_fixed_latency(u);
+ return 0;
+
+ case SINK_MESSAGE_REMOVE_OUTPUT:
+ output_remove_within_thread(data);
+ update_max_request(u);
+ update_fixed_latency(u);
+ return 0;
+
+ case SINK_MESSAGE_NEED:
+ render_memblock(u, (struct output*) data, (size_t) offset);
+ return 0;
+
+ case SINK_MESSAGE_UPDATE_LATENCY: {
+ pa_usec_t x, y, latency = (pa_usec_t) offset;
+
+ x = pa_rtclock_now();
+ y = pa_bytes_to_usec(u->thread_info.counter, &u->sink->sample_spec);
+
+ if (y > latency)
+ y -= latency;
+ else
+ y = 0;
+
+ pa_smoother_put(u->thread_info.smoother, x, y);
+ return 0;
+ }
+
+ case SINK_MESSAGE_UPDATE_MAX_REQUEST:
+ update_max_request(u);
+ break;
+
+ case SINK_MESSAGE_UPDATE_REQUESTED_LATENCY:
+ update_fixed_latency(u);
+ break;
+}
+
+ return pa_sink_process_msg(o, code, data, offset, chunk);
+}
+
+static void update_description(struct userdata *u) {
+ pa_bool_t first = TRUE;
+ char *t;
+ struct output *o;
+ uint32_t idx;
+
+ pa_assert(u);
+
+ if (!u->auto_desc)
+ return;
+
+ if (pa_idxset_isempty(u->outputs)) {
+ pa_sink_set_description(u->sink, "Simultaneous output");
+ return;
+ }
+
+ t = pa_xstrdup("Simultaneous output to");
+
+ PA_IDXSET_FOREACH(o, u->outputs, idx) {
+ char *e;
+
+ if (first) {
+ e = pa_sprintf_malloc("%s %s", t, pa_strnull(pa_proplist_gets(o->sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
+ first = FALSE;
+ } else
+ e = pa_sprintf_malloc("%s, %s", t, pa_strnull(pa_proplist_gets(o->sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
+
+ pa_xfree(t);
+ t = e;
+ }
+
+ pa_sink_set_description(u->sink, t);
+ pa_xfree(t);
+}
+
+static int output_create_sink_input(struct output *o) {
+ pa_sink_input_new_data data;
+
+ pa_assert(o);
+
+ if (o->sink_input)
+ return 0;
+
+ pa_sink_input_new_data_init(&data);
+ pa_sink_input_new_data_set_sink(&data, o->sink, FALSE);
+ data.driver = __FILE__;
+ pa_proplist_setf(data.proplist, PA_PROP_MEDIA_NAME, "Simultaneous output on %s", pa_strnull(pa_proplist_gets(o->sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
+ pa_proplist_sets(data.proplist, PA_PROP_MEDIA_ROLE, "filter");
+ pa_sink_input_new_data_set_sample_spec(&data, &o->userdata->sink->sample_spec);
+ pa_sink_input_new_data_set_channel_map(&data, &o->userdata->sink->channel_map);
+ data.module = o->userdata->module;
+ data.resample_method = o->userdata->resample_method;
+ data.flags = PA_SINK_INPUT_VARIABLE_RATE|PA_SINK_INPUT_DONT_MOVE|PA_SINK_INPUT_NO_CREATE_ON_SUSPEND;
+
+ pa_sink_input_new(&o->sink_input, o->userdata->core, &data);
+
+ pa_sink_input_new_data_done(&data);
+
+ if (!o->sink_input)
+ return -1;
+
+ o->sink_input->parent.process_msg = sink_input_process_msg;
+ o->sink_input->pop = sink_input_pop_cb;
+ o->sink_input->process_rewind = sink_input_process_rewind_cb;
+ o->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
+ o->sink_input->update_max_request = sink_input_update_max_request_cb;
+ o->sink_input->update_sink_requested_latency = sink_input_update_sink_requested_latency_cb;
+ o->sink_input->attach = sink_input_attach_cb;
+ o->sink_input->detach = sink_input_detach_cb;
+ o->sink_input->kill = sink_input_kill_cb;
+ o->sink_input->userdata = o;
+
+ pa_sink_input_set_requested_latency(o->sink_input, BLOCK_USEC);
+
+ return 0;
+}
+
+/* Called from main context */
+static struct output *output_new(struct userdata *u, pa_sink *sink) {
+ struct output *o;
+
+ pa_assert(u);
+ pa_assert(sink);
+ pa_assert(u->sink);
+
+ o = pa_xnew0(struct output, 1);
+ o->userdata = u;
+ o->inq = pa_asyncmsgq_new(0);
+ o->outq = pa_asyncmsgq_new(0);
+ o->sink = sink;
+ o->memblockq = pa_memblockq_new(
+ 0,
+ MEMBLOCKQ_MAXLENGTH,
+ MEMBLOCKQ_MAXLENGTH,
+ pa_frame_size(&u->sink->sample_spec),
+ 1,
+ 0,
+ 0,
+ &u->sink->silence);
+
+ pa_assert_se(pa_idxset_put(u->outputs, o, NULL) == 0);
+ update_description(u);
+
+ return o;
+}
+
+/* Called from main context */
+static void output_free(struct output *o) {
+ pa_assert(o);
+
+ output_disable(o);
+
+ pa_assert_se(pa_idxset_remove_by_data(o->userdata->outputs, o, NULL));
+ update_description(o->userdata);
+
+ if (o->inq_rtpoll_item_read)
+ pa_rtpoll_item_free(o->inq_rtpoll_item_read);
+ if (o->inq_rtpoll_item_write)
+ pa_rtpoll_item_free(o->inq_rtpoll_item_write);
+
+ if (o->outq_rtpoll_item_read)
+ pa_rtpoll_item_free(o->outq_rtpoll_item_read);
+ if (o->outq_rtpoll_item_write)
+ pa_rtpoll_item_free(o->outq_rtpoll_item_write);
+
+ if (o->inq)
+ pa_asyncmsgq_unref(o->inq);
+
+ if (o->outq)
+ pa_asyncmsgq_unref(o->outq);
+
+ if (o->memblockq)
+ pa_memblockq_free(o->memblockq);
+
+ pa_xfree(o);
+}
+
+/* Called from main context */
+static void output_enable(struct output *o) {
+ pa_assert(o);
+
+ if (o->sink_input)
+ return;
+
+ /* This might cause the sink to be resumed. The state change hook
+ * of the sink might hence be called from here, which might then
+ * cause us to be called in a loop. Make sure that state changes
+ * for this output don't cause this loop by setting a flag here */
+ o->ignore_state_change = TRUE;
+
+ if (output_create_sink_input(o) >= 0) {
+
+ if (pa_sink_get_state(o->sink) != PA_SINK_INIT) {
+
+ /* First we register the output. That means that the sink
+ * will start to pass data to this output. */
+ pa_asyncmsgq_send(o->userdata->sink->asyncmsgq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_ADD_OUTPUT, o, 0, NULL);
+
+ /* Then we enable the sink input. That means that the sink
+ * is now asked for new data. */
+ pa_sink_input_put(o->sink_input);
+
+ } else
+ /* Hmm the sink is not yet started, do things right here */
+ output_add_within_thread(o);
+ }
+
+ o->ignore_state_change = FALSE;
+}
+
+/* Called from main context */
+static void output_disable(struct output *o) {
+ pa_assert(o);
+
+ if (!o->sink_input)
+ return;
+
+ /* First we disable the sink input. That means that the sink is
+ * not asked for new data anymore */
+ pa_sink_input_unlink(o->sink_input);
+
+ /* Then we unregister the output. That means that the sink doesn't
+ * pass any further data to this output */
+ pa_asyncmsgq_send(o->userdata->sink->asyncmsgq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_REMOVE_OUTPUT, o, 0, NULL);
+
+ /* Now dellocate the stream */
+ pa_sink_input_unref(o->sink_input);
+ o->sink_input = NULL;
+
+ /* Finally, drop all queued data */
+ pa_memblockq_flush_write(o->memblockq, TRUE);
+ pa_asyncmsgq_flush(o->inq, FALSE);
+ pa_asyncmsgq_flush(o->outq, FALSE);
+}
+
+/* Called from main context */
+static void output_verify(struct output *o) {
+ pa_assert(o);
+
+ if (PA_SINK_IS_OPENED(pa_sink_get_state(o->userdata->sink)))
+ output_enable(o);
+ else
+ output_disable(o);
+}
+
+/* Called from main context */
+static pa_bool_t is_suitable_sink(struct userdata *u, pa_sink *s) {
+ const char *t;
+
+ pa_sink_assert_ref(s);
+
+ if (s == u->sink)
+ return FALSE;
+
+ if (!(s->flags & PA_SINK_HARDWARE))
+ return FALSE;
+
+ if (!(s->flags & PA_SINK_LATENCY))
+ return FALSE;
+
+ if ((t = pa_proplist_gets(s->proplist, PA_PROP_DEVICE_CLASS)))
+ if (!pa_streq(t, "sound"))
+ return FALSE;
+
+ return TRUE;
+}
+
+/* Called from main context */
+static pa_hook_result_t sink_put_hook_cb(pa_core *c, pa_sink *s, struct userdata* u) {
+ struct output *o;
+
+ pa_core_assert_ref(c);
+ pa_sink_assert_ref(s);
+ pa_assert(u);
+
+ if (u->automatic) {
+ if (!is_suitable_sink(u, s))
+ return PA_HOOK_OK;
+ } else {
+ /* Check if the sink is a previously unlinked slave (non-automatic mode) */
+ pa_strlist *l = u->unlinked_slaves;
+
+ while (l && !pa_streq(pa_strlist_data(l), s->name))
+ l = pa_strlist_next(l);
+
+ if (!l)
+ return PA_HOOK_OK;
+
+ u->unlinked_slaves = pa_strlist_remove(u->unlinked_slaves, s->name);
+ }
+
+ pa_log_info("Configuring new sink: %s", s->name);
+ if (!(o = output_new(u, s))) {
+ pa_log("Failed to create sink input on sink '%s'.", s->name);
+ return PA_HOOK_OK;
+ }
+
+ output_verify(o);
+
+ return PA_HOOK_OK;
+}
+
+/* Called from main context */
+static struct output* find_output(struct userdata *u, pa_sink *s) {
+ struct output *o;
+ uint32_t idx;
+
+ pa_assert(u);
+ pa_assert(s);
+
+ if (u->sink == s)
+ return NULL;
+
+ PA_IDXSET_FOREACH(o, u->outputs, idx)
+ if (o->sink == s)
+ return o;
+
+ return NULL;
+}
+
+/* Called from main context */
+static pa_hook_result_t sink_unlink_hook_cb(pa_core *c, pa_sink *s, struct userdata* u) {
+ struct output *o;
+
+ pa_assert(c);
+ pa_sink_assert_ref(s);
+ pa_assert(u);
+
+ if (!(o = find_output(u, s)))
+ return PA_HOOK_OK;
+
+ pa_log_info("Unconfiguring sink: %s", s->name);
+
+ if (!u->automatic)
+ u->unlinked_slaves = pa_strlist_prepend(u->unlinked_slaves, s->name);
+
+ output_free(o);
+
+ return PA_HOOK_OK;
+}
+
+/* Called from main context */
+static pa_hook_result_t sink_state_changed_hook_cb(pa_core *c, pa_sink *s, struct userdata* u) {
+ struct output *o;
+
+ if (!(o = find_output(u, s)))
+ return PA_HOOK_OK;
+
+ /* This state change might be triggered because we are creating a
+ * stream here, in that case we don't want to create it a second
+ * time here and enter a loop */
+ if (o->ignore_state_change)
+ return PA_HOOK_OK;
+
+ output_verify(o);
+
+ return PA_HOOK_OK;
+}
+
+int pa__init(pa_module*m) {
+ struct userdata *u;
+ pa_modargs *ma = NULL;
+ const char *slaves, *rm;
+ int resample_method = PA_RESAMPLER_TRIVIAL;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ struct output *o;
+ uint32_t idx;
+ pa_sink_new_data data;
+ uint32_t adjust_time_sec;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("failed to parse module arguments");
+ goto fail;
+ }
+
+ if ((rm = pa_modargs_get_value(ma, "resample_method", NULL))) {
+ if ((resample_method = pa_parse_resample_method(rm)) < 0) {
+ pa_log("invalid resample method '%s'", rm);
+ goto fail;
+ }
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->module = m;
+ u->rtpoll = pa_rtpoll_new();
+ pa_thread_mq_init(&u->thread_mq, m->core->mainloop, u->rtpoll);
+ u->resample_method = resample_method;
+ u->outputs = pa_idxset_new(NULL, NULL);
+ u->thread_info.smoother = pa_smoother_new(
+ PA_USEC_PER_SEC,
+ PA_USEC_PER_SEC*2,
+ TRUE,
+ TRUE,
+ 10,
+ pa_rtclock_now(),
+ TRUE);
+
+ adjust_time_sec = DEFAULT_ADJUST_TIME_USEC / PA_USEC_PER_SEC;
+ if (pa_modargs_get_value_u32(ma, "adjust_time", &adjust_time_sec) < 0) {
+ pa_log("Failed to parse adjust_time value");
+ goto fail;
+ }
+
+ if (adjust_time_sec != DEFAULT_ADJUST_TIME_USEC / PA_USEC_PER_SEC)
+ u->adjust_time = adjust_time_sec * PA_USEC_PER_SEC;
+ else
+ u->adjust_time = DEFAULT_ADJUST_TIME_USEC;
+
+ slaves = pa_modargs_get_value(ma, "slaves", NULL);
+ u->automatic = !slaves;
+
+ ss = m->core->default_sample_spec;
+ map = m->core->default_channel_map;
+
+ /* Check the specified slave sinks for sample_spec and channel_map to use for the combined sink */
+ if (!u->automatic) {
+ const char*split_state = NULL;
+ char *n = NULL;
+ pa_sample_spec slaves_spec;
+ pa_channel_map slaves_map;
+ pa_bool_t is_first_slave = TRUE;
+
+ pa_sample_spec_init(&slaves_spec);
+
+ while ((n = pa_split(slaves, ",", &split_state))) {
+ pa_sink *slave_sink;
+
+ if (!(slave_sink = pa_namereg_get(m->core, n, PA_NAMEREG_SINK))) {
+ pa_log("Invalid slave sink '%s'", n);
+ pa_xfree(n);
+ goto fail;
+ }
+
+ pa_xfree(n);
+
+ if (is_first_slave) {
+ slaves_spec = slave_sink->sample_spec;
+ slaves_map = slave_sink->channel_map;
+ is_first_slave = FALSE;
+ } else {
+ if (slaves_spec.format != slave_sink->sample_spec.format)
+ slaves_spec.format = PA_SAMPLE_INVALID;
+
+ if (slaves_spec.rate < slave_sink->sample_spec.rate)
+ slaves_spec.rate = slave_sink->sample_spec.rate;
+
+ if (!pa_channel_map_equal(&slaves_map, &slave_sink->channel_map))
+ slaves_spec.channels = 0;
+ }
+ }
+
+ if (!is_first_slave) {
+ if (slaves_spec.format != PA_SAMPLE_INVALID)
+ ss.format = slaves_spec.format;
+
+ ss.rate = slaves_spec.rate;
+
+ if (slaves_spec.channels > 0) {
+ map = slaves_map;
+ ss.channels = slaves_map.channels;
+ }
+ }
+ }
+
+ if ((pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_DEFAULT) < 0)) {
+ pa_log("Invalid sample specification.");
+ goto fail;
+ }
+
+ pa_sink_new_data_init(&data);
+ data.namereg_fail = FALSE;
+ data.driver = __FILE__;
+ data.module = m;
+ pa_sink_new_data_set_name(&data, pa_modargs_get_value(ma, "sink_name", DEFAULT_SINK_NAME));
+ pa_sink_new_data_set_sample_spec(&data, &ss);
+ pa_sink_new_data_set_channel_map(&data, &map);
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_CLASS, "filter");
+
+ if (slaves)
+ pa_proplist_sets(data.proplist, "combine.slaves", slaves);
+
+ if (pa_modargs_get_proplist(ma, "sink_properties", data.proplist, PA_UPDATE_REPLACE) < 0) {
+ pa_log("Invalid properties");
+ pa_sink_new_data_done(&data);
+ goto fail;
+ }
+
+ /* Check proplist for a description & fill in a default value if not */
+ u->auto_desc = FALSE;
+ if (NULL == pa_proplist_gets(data.proplist, PA_PROP_DEVICE_DESCRIPTION)) {
+ u->auto_desc = TRUE;
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Simultaneous Output");
+ }
+
+ u->sink = pa_sink_new(m->core, &data, PA_SINK_LATENCY);
+ pa_sink_new_data_done(&data);
+
+ if (!u->sink) {
+ pa_log("Failed to create sink");
+ goto fail;
+ }
+
+ u->sink->parent.process_msg = sink_process_msg;
+ u->sink->set_state = sink_set_state;
+ u->sink->userdata = u;
+
+ pa_sink_set_rtpoll(u->sink, u->rtpoll);
+ pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
+
+ u->block_usec = BLOCK_USEC;
+ pa_sink_set_max_request(u->sink, pa_usec_to_bytes(u->block_usec, &u->sink->sample_spec));
+
+ if (!u->automatic) {
+ const char*split_state;
+ char *n = NULL;
+ pa_assert(slaves);
+
+ /* The slaves have been specified manually */
+
+ split_state = NULL;
+ while ((n = pa_split(slaves, ",", &split_state))) {
+ pa_sink *slave_sink;
+
+ if (!(slave_sink = pa_namereg_get(m->core, n, PA_NAMEREG_SINK)) || slave_sink == u->sink) {
+ pa_log("Invalid slave sink '%s'", n);
+ pa_xfree(n);
+ goto fail;
+ }
+
+ pa_xfree(n);
+
+ if (!output_new(u, slave_sink)) {
+ pa_log("Failed to create slave sink input on sink '%s'.", slave_sink->name);
+ goto fail;
+ }
+ }
+
+ if (pa_idxset_size(u->outputs) <= 1)
+ pa_log_warn("No slave sinks specified.");
+
+ u->sink_put_slot = NULL;
+
+ } else {
+ pa_sink *s;
+
+ /* We're in automatic mode, we add every sink that matches our needs */
+
+ PA_IDXSET_FOREACH(s, m->core->sinks, idx) {
+
+ if (!is_suitable_sink(u, s))
+ continue;
+
+ if (!output_new(u, s)) {
+ pa_log("Failed to create sink input on sink '%s'.", s->name);
+ goto fail;
+ }
+ }
+ }
+
+ u->sink_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_LATE, (pa_hook_cb_t) sink_put_hook_cb, u);
+ u->sink_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_EARLY, (pa_hook_cb_t) sink_unlink_hook_cb, u);
+ u->sink_state_changed_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_STATE_CHANGED], PA_HOOK_NORMAL, (pa_hook_cb_t) sink_state_changed_hook_cb, u);
+
+ if (!(u->thread = pa_thread_new("combine", thread_func, u))) {
+ pa_log("Failed to create thread.");
+ goto fail;
+ }
+
+ /* Activate the sink and the sink inputs */
+ pa_sink_put(u->sink);
+
+ PA_IDXSET_FOREACH(o, u->outputs, idx)
+ output_verify(o);
+
+ if (u->adjust_time > 0)
+ u->time_event = pa_core_rttime_new(m->core, pa_rtclock_now() + u->adjust_time, time_callback, u);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+ struct output *o;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ pa_strlist_free(u->unlinked_slaves);
+
+ if (u->sink_put_slot)
+ pa_hook_slot_free(u->sink_put_slot);
+
+ if (u->sink_unlink_slot)
+ pa_hook_slot_free(u->sink_unlink_slot);
+
+ if (u->sink_state_changed_slot)
+ pa_hook_slot_free(u->sink_state_changed_slot);
+
+ if (u->outputs) {
+ while ((o = pa_idxset_first(u->outputs, NULL)))
+ output_free(o);
+
+ pa_idxset_free(u->outputs, NULL, NULL);
+ }
+
+ if (u->sink)
+ pa_sink_unlink(u->sink);
+
+ if (u->thread) {
+ pa_asyncmsgq_send(u->thread_mq.inq, NULL, PA_MESSAGE_SHUTDOWN, NULL, 0, NULL);
+ pa_thread_free(u->thread);
+ }
+
+ pa_thread_mq_done(&u->thread_mq);
+
+ if (u->sink)
+ pa_sink_unref(u->sink);
+
+ if (u->rtpoll)
+ pa_rtpoll_free(u->rtpoll);
+
+ if (u->time_event)
+ u->core->mainloop->time_free(u->time_event);
+
+ if (u->thread_info.smoother)
+ pa_smoother_free(u->thread_info.smoother);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-combine.c b/src/modules/module-combine.c
index 02a7e1ff..251df494 100644
--- a/src/modules/module-combine.c
+++ b/src/modules/module-combine.c
@@ -1,7 +1,8 @@
/***
This file is part of PulseAudio.
- Copyright 2004-2008 Lennart Poettering
+ Copyright 2009 Lennart Poettering
+ Copyright 2011 Colin Guthrie
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
@@ -23,1251 +24,49 @@
#include <config.h>
#endif
-#include <stdio.h>
-#include <errno.h>
-
-#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/macro.h>
#include <pulsecore/module.h>
-#include <pulsecore/llist.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/sink-input.h>
-#include <pulsecore/memblockq.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
-#include <pulsecore/modargs.h>
-#include <pulsecore/namereg.h>
-#include <pulsecore/mutex.h>
-#include <pulsecore/thread.h>
-#include <pulsecore/thread-mq.h>
-#include <pulsecore/rtpoll.h>
-#include <pulsecore/rtclock.h>
-#include <pulsecore/core-error.h>
-#include <pulsecore/time-smoother.h>
#include "module-combine-symdef.h"
-PA_MODULE_AUTHOR("Lennart Poettering");
-PA_MODULE_DESCRIPTION("Combine multiple sinks to one");
+PA_MODULE_AUTHOR("Colin Guthrie");
+PA_MODULE_DESCRIPTION("Compatibility module (module-combine rename)");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(FALSE);
-PA_MODULE_USAGE(
- "sink_name=<name for the sink> "
- "sink_properties=<properties for the sink> "
- "slaves=<slave sinks> "
- "adjust_time=<seconds> "
- "resample_method=<method> "
- "format=<sample format> "
- "rate=<sample rate> "
- "channels=<number of channels> "
- "channel_map=<channel map>");
-
-#define DEFAULT_SINK_NAME "combined"
-
-#define MEMBLOCKQ_MAXLENGTH (1024*1024*16)
-
-#define DEFAULT_ADJUST_TIME 10
-
-#define BLOCK_USEC (PA_USEC_PER_MSEC * 200)
-
-static const char* const valid_modargs[] = {
- "sink_name",
- "sink_properties",
- "slaves",
- "adjust_time",
- "resample_method",
- "format",
- "rate",
- "channels",
- "channel_map",
- NULL
-};
-
-struct output {
- struct userdata *userdata;
-
- pa_sink *sink;
- pa_sink_input *sink_input;
-
- pa_asyncmsgq *inq, /* Message queue from the sink thread to this sink input */
- *outq; /* Message queue from this sink input to the sink thread */
- pa_rtpoll_item *inq_rtpoll_item_read, *inq_rtpoll_item_write;
- pa_rtpoll_item *outq_rtpoll_item_read, *outq_rtpoll_item_write;
-
- pa_memblockq *memblockq;
-
- pa_usec_t total_latency;
-
- pa_atomic_t max_request;
-
- PA_LLIST_FIELDS(struct output);
-};
+PA_MODULE_DEPRECATED("Please use module-combine-sink instead of module-combine!");
struct userdata {
- pa_core *core;
- pa_module *module;
- pa_sink *sink;
-
- pa_thread *thread;
- pa_thread_mq thread_mq;
- pa_rtpoll *rtpoll;
-
- pa_time_event *time_event;
- uint32_t adjust_time;
-
- pa_bool_t automatic;
-
- pa_hook_slot *sink_put_slot, *sink_unlink_slot, *sink_state_changed_slot;
-
- pa_resample_method_t resample_method;
-
- struct timeval adjust_timestamp;
-
- pa_usec_t block_usec;
-
- pa_idxset* outputs; /* managed in main context */
-
- struct {
- PA_LLIST_HEAD(struct output, active_outputs); /* managed in IO thread context */
- pa_atomic_t running; /* we cache that value here, so that every thread can query it cheaply */
- pa_usec_t timestamp;
- pa_bool_t in_null_mode;
- pa_smoother *smoother;
- uint64_t counter;
- } thread_info;
-};
-
-enum {
- SINK_MESSAGE_ADD_OUTPUT = PA_SINK_MESSAGE_MAX,
- SINK_MESSAGE_REMOVE_OUTPUT,
- SINK_MESSAGE_NEED,
- SINK_MESSAGE_UPDATE_LATENCY,
- SINK_MESSAGE_UPDATE_MAX_REQUEST
-};
-
-enum {
- SINK_INPUT_MESSAGE_POST = PA_SINK_INPUT_MESSAGE_MAX,
+ uint32_t module_index;
};
-static void output_free(struct output *o);
-static int output_create_sink_input(struct output *o);
-
-static void adjust_rates(struct userdata *u) {
- struct output *o;
- pa_usec_t max_sink_latency = 0, min_total_latency = (pa_usec_t) -1, target_latency, avg_total_latency = 0;
- uint32_t base_rate;
- uint32_t idx;
- unsigned n = 0;
-
- pa_assert(u);
- pa_sink_assert_ref(u->sink);
-
- if (pa_idxset_size(u->outputs) <= 0)
- return;
-
- if (!PA_SINK_IS_OPENED(pa_sink_get_state(u->sink)))
- return;
-
- for (o = pa_idxset_first(u->outputs, &idx); o; o = pa_idxset_next(u->outputs, &idx)) {
- pa_usec_t sink_latency;
-
- if (!o->sink_input || !PA_SINK_IS_OPENED(pa_sink_get_state(o->sink)))
- continue;
-
- o->total_latency = pa_sink_input_get_latency(o->sink_input, &sink_latency);
- o->total_latency += sink_latency;
-
- if (sink_latency > max_sink_latency)
- max_sink_latency = sink_latency;
-
- if (min_total_latency == (pa_usec_t) -1 || o->total_latency < min_total_latency)
- min_total_latency = o->total_latency;
-
- avg_total_latency += o->total_latency;
- n++;
- }
-
- if (min_total_latency == (pa_usec_t) -1)
- return;
-
- avg_total_latency /= n;
-
- target_latency = max_sink_latency > min_total_latency ? max_sink_latency : min_total_latency;
-
- pa_log_info("[%s] avg total latency is %0.2f msec.", u->sink->name, (double) avg_total_latency / PA_USEC_PER_MSEC);
- pa_log_info("[%s] target latency is %0.2f msec.", u->sink->name, (double) target_latency / PA_USEC_PER_MSEC);
-
- base_rate = u->sink->sample_spec.rate;
-
- for (o = pa_idxset_first(u->outputs, &idx); o; o = pa_idxset_next(u->outputs, &idx)) {
- uint32_t r = base_rate;
-
- if (!o->sink_input || !PA_SINK_IS_OPENED(pa_sink_get_state(o->sink)))
- continue;
-
- if (o->total_latency < target_latency)
- r -= (uint32_t) ((((double) (target_latency - o->total_latency))/(double)u->adjust_time)*(double)r/PA_USEC_PER_SEC);
- else if (o->total_latency > target_latency)
- r += (uint32_t) ((((double) (o->total_latency - target_latency))/(double)u->adjust_time)*(double)r/PA_USEC_PER_SEC);
-
- if (r < (uint32_t) (base_rate*0.9) || r > (uint32_t) (base_rate*1.1)) {
- pa_log_warn("[%s] sample rates too different, not adjusting (%u vs. %u).", pa_proplist_gets(o->sink_input->proplist, PA_PROP_MEDIA_NAME), base_rate, r);
- pa_sink_input_set_rate(o->sink_input, base_rate);
- } else {
- pa_log_info("[%s] new rate is %u Hz; ratio is %0.3f; latency is %0.0f usec.", pa_proplist_gets(o->sink_input->proplist, PA_PROP_MEDIA_NAME), r, (double) r / base_rate, (float) o->total_latency);
- pa_sink_input_set_rate(o->sink_input, r);
- }
- }
-
- pa_asyncmsgq_send(u->sink->asyncmsgq, PA_MSGOBJECT(u->sink), SINK_MESSAGE_UPDATE_LATENCY, NULL, (int64_t) avg_total_latency, NULL);
-}
-
-static void time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *tv, void *userdata) {
- struct userdata *u = userdata;
- struct timeval n;
-
- pa_assert(u);
- pa_assert(a);
- pa_assert(u->time_event == e);
-
- adjust_rates(u);
-
- pa_gettimeofday(&n);
- n.tv_sec += (time_t) u->adjust_time;
- u->sink->core->mainloop->time_restart(e, &n);
-}
-
-static void process_render_null(struct userdata *u, pa_usec_t now) {
- size_t ate = 0;
- pa_assert(u);
-
- if (u->thread_info.in_null_mode)
- u->thread_info.timestamp = now;
-
- while (u->thread_info.timestamp < now + u->block_usec) {
- pa_memchunk chunk;
-
- pa_sink_render(u->sink, u->sink->thread_info.max_request, &chunk);
- pa_memblock_unref(chunk.memblock);
-
- u->thread_info.counter += chunk.length;
-
-/* pa_log_debug("Ate %lu bytes.", (unsigned long) chunk.length); */
- u->thread_info.timestamp += pa_bytes_to_usec(chunk.length, &u->sink->sample_spec);
-
- ate += chunk.length;
-
- if (ate >= u->sink->thread_info.max_request)
- break;
- }
-
-/* pa_log_debug("Ate in sum %lu bytes (of %lu)", (unsigned long) ate, (unsigned long) nbytes); */
-
- pa_smoother_put(u->thread_info.smoother, now,
- pa_bytes_to_usec(u->thread_info.counter, &u->sink->sample_spec) - (u->thread_info.timestamp - now));
-}
-
-static void thread_func(void *userdata) {
- struct userdata *u = userdata;
-
- pa_assert(u);
-
- pa_log_debug("Thread starting up");
-
- if (u->core->realtime_scheduling)
- pa_make_realtime(u->core->realtime_priority+1);
-
- pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
-
- u->thread_info.timestamp = pa_rtclock_usec();
- u->thread_info.in_null_mode = FALSE;
-
- for (;;) {
- int ret;
-
- if (PA_SINK_IS_OPENED(u->sink->thread_info.state))
- if (u->sink->thread_info.rewind_requested)
- pa_sink_process_rewind(u->sink, 0);
-
- /* If no outputs are connected, render some data and drop it immediately. */
- if (PA_SINK_IS_OPENED(u->sink->thread_info.state) && !u->thread_info.active_outputs) {
- pa_usec_t now;
-
- now = pa_rtclock_usec();
-
- if (!u->thread_info.in_null_mode || u->thread_info.timestamp <= now)
- process_render_null(u, now);
-
- pa_rtpoll_set_timer_absolute(u->rtpoll, u->thread_info.timestamp);
- u->thread_info.in_null_mode = TRUE;
- } else {
- pa_rtpoll_set_timer_disabled(u->rtpoll);
- u->thread_info.in_null_mode = FALSE;
- }
-
- /* Hmm, nothing to do. Let's sleep */
- if ((ret = pa_rtpoll_run(u->rtpoll, TRUE)) < 0) {
- pa_log_info("pa_rtpoll_run() = %i", ret);
- goto fail;
- }
-
- if (ret == 0)
- goto finish;
- }
-
-fail:
- /* If this was no regular exit from the loop we have to continue
- * processing messages until we received PA_MESSAGE_SHUTDOWN */
- pa_asyncmsgq_post(u->thread_mq.outq, PA_MSGOBJECT(u->core), PA_CORE_MESSAGE_UNLOAD_MODULE, u->module, 0, NULL, NULL);
- pa_asyncmsgq_wait_for(u->thread_mq.inq, PA_MESSAGE_SHUTDOWN);
-
-finish:
- pa_log_debug("Thread shutting down");
-}
-
-/* Called from I/O thread context */
-static void render_memblock(struct userdata *u, struct output *o, size_t length) {
- pa_assert(u);
- pa_assert(o);
-
- /* We are run by the sink thread, on behalf of an output (o). The
- * output is waiting for us, hence it is safe to access its
- * mainblockq and asyncmsgq directly. */
-
- /* If we are not running, we cannot produce any data */
- if (!pa_atomic_load(&u->thread_info.running))
- return;
-
- /* Maybe there's some data in the requesting output's queue
- * now? */
- while (pa_asyncmsgq_process_one(o->inq) > 0)
- ;
-
- /* Ok, now let's prepare some data if we really have to */
- while (!pa_memblockq_is_readable(o->memblockq)) {
- struct output *j;
- pa_memchunk chunk;
-
- /* Render data! */
- pa_sink_render(u->sink, length, &chunk);
-
- u->thread_info.counter += chunk.length;
-
- /* OK, let's send this data to the other threads */
- for (j = u->thread_info.active_outputs; j; j = j->next)
-
- /* Send to other outputs, which are not the requesting
- * one */
-
- if (j != o)
- pa_asyncmsgq_post(j->inq, PA_MSGOBJECT(j->sink_input), SINK_INPUT_MESSAGE_POST, NULL, 0, &chunk, NULL);
-
- /* And place it directly into the requesting output's queue */
- if (o)
- pa_memblockq_push_align(o->memblockq, &chunk);
-
- pa_memblock_unref(chunk.memblock);
- }
-}
-
-/* Called from I/O thread context */
-static void request_memblock(struct output *o, size_t length) {
- pa_assert(o);
- pa_sink_input_assert_ref(o->sink_input);
- pa_sink_assert_ref(o->userdata->sink);
-
- /* If another thread already prepared some data we received
- * the data over the asyncmsgq, hence let's first process
- * it. */
- while (pa_asyncmsgq_process_one(o->inq) > 0)
- ;
-
- /* Check whether we're now readable */
- if (pa_memblockq_is_readable(o->memblockq))
- return;
-
- /* OK, we need to prepare new data, but only if the sink is actually running */
- if (pa_atomic_load(&o->userdata->thread_info.running))
- pa_asyncmsgq_send(o->outq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_NEED, o, (int64_t) length, NULL);
-}
-
-/* Called from I/O thread context */
-static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk) {
- struct output *o;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(o = i->userdata);
-
- /* If necessary, get some new data */
- request_memblock(o, nbytes);
-
- if (pa_memblockq_peek(o->memblockq, chunk) < 0)
- return -1;
-
- pa_memblockq_drop(o->memblockq, chunk->length);
- return 0;
-}
-
-/* Called from I/O thread context */
-static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
- struct output *o;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(o = i->userdata);
-
- pa_memblockq_rewind(o->memblockq, nbytes);
-}
-
-/* Called from I/O thread context */
-static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
- struct output *o;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(o = i->userdata);
-
- pa_memblockq_set_maxrewind(o->memblockq, nbytes);
-}
-
-/* Called from I/O thread context */
-static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
- struct output *o;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(o = i->userdata);
-
- if (pa_atomic_load(&o->max_request) == (int) nbytes)
- return;
-
- pa_atomic_store(&o->max_request, (int) nbytes);
-
- pa_asyncmsgq_post(o->outq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_UPDATE_MAX_REQUEST, NULL, 0, NULL, NULL);
-}
-
-/* Called from I/O thread context */
-static void sink_input_attach_cb(pa_sink_input *i) {
- struct output *o;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(o = i->userdata);
-
- /* Set up the queue from the sink thread to us */
- pa_assert(!o->inq_rtpoll_item_read && !o->outq_rtpoll_item_write);
-
- o->inq_rtpoll_item_read = pa_rtpoll_item_new_asyncmsgq_read(
- i->sink->rtpoll,
- PA_RTPOLL_LATE, /* This one is not that important, since we check for data in _peek() anyway. */
- o->inq);
-
- o->outq_rtpoll_item_write = pa_rtpoll_item_new_asyncmsgq_write(
- i->sink->rtpoll,
- PA_RTPOLL_EARLY,
- o->outq);
-}
-
-/* Called from I/O thread context */
-static void sink_input_detach_cb(pa_sink_input *i) {
- struct output *o;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(o = i->userdata);
-
- /* Shut down the queue from the sink thread to us */
- pa_assert(o->inq_rtpoll_item_read && o->outq_rtpoll_item_write);
-
- pa_rtpoll_item_free(o->inq_rtpoll_item_read);
- o->inq_rtpoll_item_read = NULL;
-
- pa_rtpoll_item_free(o->outq_rtpoll_item_write);
- o->outq_rtpoll_item_write = NULL;
-}
-
-/* Called from main context */
-static void sink_input_kill_cb(pa_sink_input *i) {
- struct output *o;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(o = i->userdata);
-
- pa_module_unload_request(o->userdata->module, TRUE);
- output_free(o);
-}
-
-/* Called from IO thread context */
-static void sink_input_state_change_cb(pa_sink_input *i, pa_sink_input_state_t state) {
- struct userdata *u;
-
- pa_sink_input_assert_ref(i);
- pa_assert_se(u = i->userdata);
-
- /* If we are added for the first time, ask for a rewinding so that
- * we are heard right-away. */
- if (PA_SINK_INPUT_IS_LINKED(state) &&
- i->thread_info.state == PA_SINK_INPUT_INIT)
- pa_sink_input_request_rewind(i, 0, FALSE, TRUE, TRUE);
-}
-
-/* Called from thread context */
-static int sink_input_process_msg(pa_msgobject *obj, int code, void *data, int64_t offset, pa_memchunk *chunk) {
- struct output *o = PA_SINK_INPUT(obj)->userdata;
-
- switch (code) {
-
- case PA_SINK_INPUT_MESSAGE_GET_LATENCY: {
- pa_usec_t *r = data;
-
- *r = pa_bytes_to_usec(pa_memblockq_get_length(o->memblockq), &o->sink_input->sample_spec);
-
- /* Fall through, the default handler will add in the extra
- * latency added by the resampler */
- break;
- }
-
- case SINK_INPUT_MESSAGE_POST:
-
- if (PA_SINK_IS_OPENED(o->sink_input->sink->thread_info.state))
- pa_memblockq_push_align(o->memblockq, chunk);
- else
- pa_memblockq_flush_write(o->memblockq);
-
- return 0;
- }
-
- return pa_sink_input_process_msg(obj, code, data, offset, chunk);
-}
-
-/* Called from main context */
-static void disable_output(struct output *o) {
- pa_assert(o);
-
- if (!o->sink_input)
- return;
-
- pa_sink_input_unlink(o->sink_input);
- pa_asyncmsgq_send(o->userdata->sink->asyncmsgq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_REMOVE_OUTPUT, o, 0, NULL);
- pa_sink_input_unref(o->sink_input);
- o->sink_input = NULL;
-}
-
-/* Called from main context */
-static void enable_output(struct output *o) {
- pa_assert(o);
-
- if (o->sink_input)
- return;
-
- if (output_create_sink_input(o) >= 0) {
-
- pa_memblockq_flush_write(o->memblockq);
-
- pa_sink_input_put(o->sink_input);
-
- if (o->userdata->sink && PA_SINK_IS_LINKED(pa_sink_get_state(o->userdata->sink)))
- pa_asyncmsgq_send(o->userdata->sink->asyncmsgq, PA_MSGOBJECT(o->userdata->sink), SINK_MESSAGE_ADD_OUTPUT, o, 0, NULL);
- }
-}
-
-/* Called from main context */
-static void suspend(struct userdata *u) {
- struct output *o;
- uint32_t idx;
-
- pa_assert(u);
-
- /* Let's suspend by unlinking all streams */
- for (o = pa_idxset_first(u->outputs, &idx); o; o = pa_idxset_next(u->outputs, &idx))
- disable_output(o);
-
- pa_log_info("Device suspended...");
-}
-
-/* Called from main context */
-static void unsuspend(struct userdata *u) {
- struct output *o;
- uint32_t idx;
-
- pa_assert(u);
-
- /* Let's resume */
- for (o = pa_idxset_first(u->outputs, &idx); o; o = pa_idxset_next(u->outputs, &idx)) {
-
- pa_sink_suspend(o->sink, FALSE);
-
- if (PA_SINK_IS_OPENED(pa_sink_get_state(o->sink)))
- enable_output(o);
- }
-
- pa_log_info("Resumed successfully...");
-}
-
-/* Called from main context */
-static int sink_set_state(pa_sink *sink, pa_sink_state_t state) {
- struct userdata *u;
-
- pa_sink_assert_ref(sink);
- pa_assert_se(u = sink->userdata);
-
- /* Please note that in contrast to the ALSA modules we call
- * suspend/unsuspend from main context here! */
-
- switch (state) {
- case PA_SINK_SUSPENDED:
- pa_assert(PA_SINK_IS_OPENED(pa_sink_get_state(u->sink)));
-
- suspend(u);
- break;
-
- case PA_SINK_IDLE:
- case PA_SINK_RUNNING:
-
- if (pa_sink_get_state(u->sink) == PA_SINK_SUSPENDED)
- unsuspend(u);
-
- break;
-
- case PA_SINK_UNLINKED:
- case PA_SINK_INIT:
- case PA_SINK_INVALID_STATE:
- ;
- }
-
- return 0;
-}
-
-/* Called from IO context */
-static void update_max_request(struct userdata *u) {
- size_t max_request = 0;
- struct output *o;
-
- for (o = u->thread_info.active_outputs; o; o = o->next) {
- size_t mr = (size_t) pa_atomic_load(&o->max_request);
-
- if (mr > max_request)
- max_request = mr;
- }
-
- if (max_request <= 0)
- max_request = pa_usec_to_bytes(u->block_usec, &u->sink->sample_spec);
-
- pa_sink_set_max_request_within_thread(u->sink, max_request);
-}
-
-/* Called from thread context of the io thread */
-static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
- struct userdata *u = PA_SINK(o)->userdata;
-
- switch (code) {
-
- case PA_SINK_MESSAGE_SET_STATE:
- pa_atomic_store(&u->thread_info.running, PA_PTR_TO_UINT(data) == PA_SINK_RUNNING);
-
- if (PA_PTR_TO_UINT(data) == PA_SINK_SUSPENDED)
- pa_smoother_pause(u->thread_info.smoother, pa_rtclock_usec());
- else
- pa_smoother_resume(u->thread_info.smoother, pa_rtclock_usec(), TRUE);
-
- break;
-
- case PA_SINK_MESSAGE_GET_LATENCY: {
- pa_usec_t x, y, c, *delay = data;
-
- x = pa_rtclock_usec();
- y = pa_smoother_get(u->thread_info.smoother, x);
-
- c = pa_bytes_to_usec(u->thread_info.counter, &u->sink->sample_spec);
-
- if (y < c)
- *delay = c - y;
- else
- *delay = 0;
-
- return 0;
- }
-
- case SINK_MESSAGE_ADD_OUTPUT: {
- struct output *op = data;
-
- PA_LLIST_PREPEND(struct output, u->thread_info.active_outputs, op);
-
- pa_assert(!op->outq_rtpoll_item_read && !op->inq_rtpoll_item_write);
-
- op->outq_rtpoll_item_read = pa_rtpoll_item_new_asyncmsgq_read(
- u->rtpoll,
- PA_RTPOLL_EARLY-1, /* This item is very important */
- op->outq);
- op->inq_rtpoll_item_write = pa_rtpoll_item_new_asyncmsgq_write(
- u->rtpoll,
- PA_RTPOLL_EARLY,
- op->inq);
-
- update_max_request(u);
- return 0;
- }
-
- case SINK_MESSAGE_REMOVE_OUTPUT: {
- struct output *op = data;
-
- PA_LLIST_REMOVE(struct output, u->thread_info.active_outputs, op);
-
- pa_assert(op->outq_rtpoll_item_read && op->inq_rtpoll_item_write);
-
- pa_rtpoll_item_free(op->outq_rtpoll_item_read);
- op->outq_rtpoll_item_read = NULL;
-
- pa_rtpoll_item_free(op->inq_rtpoll_item_write);
- op->inq_rtpoll_item_write = NULL;
-
- update_max_request(u);
- return 0;
- }
-
- case SINK_MESSAGE_NEED:
- render_memblock(u, (struct output*) data, (size_t) offset);
- return 0;
-
- case SINK_MESSAGE_UPDATE_LATENCY: {
- pa_usec_t x, y, latency = (pa_usec_t) offset;
-
- x = pa_rtclock_usec();
- y = pa_bytes_to_usec(u->thread_info.counter, &u->sink->sample_spec);
-
- if (y > latency)
- y -= latency;
- else
- y = 0;
-
- pa_smoother_put(u->thread_info.smoother, x, y);
- return 0;
- }
-
- case SINK_MESSAGE_UPDATE_MAX_REQUEST:
-
- update_max_request(u);
- break;
- }
-
- return pa_sink_process_msg(o, code, data, offset, chunk);
-}
-
-static void update_description(struct userdata *u) {
- pa_bool_t first = TRUE;
- char *t;
- struct output *o;
- uint32_t idx;
-
- pa_assert(u);
-
- if (pa_idxset_isempty(u->outputs)) {
- pa_sink_set_description(u->sink, "Simultaneous output");
- return;
- }
-
- t = pa_xstrdup("Simultaneous output to");
-
- for (o = pa_idxset_first(u->outputs, &idx); o; o = pa_idxset_next(u->outputs, &idx)) {
- char *e;
-
- if (first) {
- e = pa_sprintf_malloc("%s %s", t, pa_strnull(pa_proplist_gets(o->sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
- first = FALSE;
- } else
- e = pa_sprintf_malloc("%s, %s", t, pa_strnull(pa_proplist_gets(o->sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
-
- pa_xfree(t);
- t = e;
- }
-
- pa_sink_set_description(u->sink, t);
- pa_xfree(t);
-}
-
-static int output_create_sink_input(struct output *o) {
- pa_sink_input_new_data data;
-
- pa_assert(o);
-
- if (o->sink_input)
- return 0;
-
- pa_sink_input_new_data_init(&data);
- data.sink = o->sink;
- data.driver = __FILE__;
- pa_proplist_setf(data.proplist, PA_PROP_MEDIA_NAME, "Simultaneous output on %s", pa_strnull(pa_proplist_gets(o->sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
- pa_proplist_sets(data.proplist, PA_PROP_MEDIA_ROLE, "filter");
- pa_sink_input_new_data_set_sample_spec(&data, &o->userdata->sink->sample_spec);
- pa_sink_input_new_data_set_channel_map(&data, &o->userdata->sink->channel_map);
- data.module = o->userdata->module;
- data.resample_method = o->userdata->resample_method;
-
- pa_sink_input_new(&o->sink_input, o->userdata->core, &data, PA_SINK_INPUT_VARIABLE_RATE|PA_SINK_INPUT_DONT_MOVE);
-
- pa_sink_input_new_data_done(&data);
-
- if (!o->sink_input)
- return -1;
-
- o->sink_input->parent.process_msg = sink_input_process_msg;
- o->sink_input->pop = sink_input_pop_cb;
- o->sink_input->process_rewind = sink_input_process_rewind_cb;
- o->sink_input->state_change = sink_input_state_change_cb;
- o->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
- o->sink_input->update_max_request = sink_input_update_max_request_cb;
- o->sink_input->attach = sink_input_attach_cb;
- o->sink_input->detach = sink_input_detach_cb;
- o->sink_input->kill = sink_input_kill_cb;
- o->sink_input->userdata = o;
-
- pa_sink_input_set_requested_latency(o->sink_input, BLOCK_USEC);
-
- return 0;
-}
-
-static struct output *output_new(struct userdata *u, pa_sink *sink) {
- struct output *o;
- pa_sink_state_t state;
-
- pa_assert(u);
- pa_assert(sink);
- pa_assert(u->sink);
-
- o = pa_xnew(struct output, 1);
- o->userdata = u;
- o->inq = pa_asyncmsgq_new(0);
- o->outq = pa_asyncmsgq_new(0);
- o->inq_rtpoll_item_write = o->inq_rtpoll_item_read = NULL;
- o->outq_rtpoll_item_write = o->outq_rtpoll_item_read = NULL;
- o->sink = sink;
- o->sink_input = NULL;
- o->memblockq = pa_memblockq_new(
- 0,
- MEMBLOCKQ_MAXLENGTH,
- MEMBLOCKQ_MAXLENGTH,
- pa_frame_size(&u->sink->sample_spec),
- 1,
- 0,
- 0,
- NULL);
- pa_atomic_store(&o->max_request, 0);
- PA_LLIST_INIT(struct output, o);
-
- pa_assert_se(pa_idxset_put(u->outputs, o, NULL) == 0);
-
- state = pa_sink_get_state(u->sink);
-
- if (state != PA_SINK_INIT)
- pa_asyncmsgq_send(u->sink->asyncmsgq, PA_MSGOBJECT(u->sink), SINK_MESSAGE_ADD_OUTPUT, o, 0, NULL);
- else {
- /* If the sink is not yet started, we need to do the activation ourselves */
- PA_LLIST_PREPEND(struct output, u->thread_info.active_outputs, o);
-
- o->outq_rtpoll_item_read = pa_rtpoll_item_new_asyncmsgq_read(
- u->rtpoll,
- PA_RTPOLL_EARLY-1, /* This item is very important */
- o->outq);
- o->inq_rtpoll_item_write = pa_rtpoll_item_new_asyncmsgq_write(
- u->rtpoll,
- PA_RTPOLL_EARLY,
- o->inq);
- }
-
- if (PA_SINK_IS_OPENED(state) || state == PA_SINK_INIT) {
- pa_sink_suspend(sink, FALSE);
-
- if (PA_SINK_IS_OPENED(pa_sink_get_state(sink)))
- if (output_create_sink_input(o) < 0)
- goto fail;
- }
-
- update_description(u);
-
- return o;
-
-fail:
-
- if (o) {
- pa_idxset_remove_by_data(u->outputs, o, NULL);
-
- if (o->sink_input) {
- pa_sink_input_unlink(o->sink_input);
- pa_sink_input_unref(o->sink_input);
- }
-
- if (o->memblockq)
- pa_memblockq_free(o->memblockq);
-
- if (o->inq)
- pa_asyncmsgq_unref(o->inq);
-
- if (o->outq)
- pa_asyncmsgq_unref(o->outq);
-
- pa_xfree(o);
- }
-
- return NULL;
-}
-
-static pa_bool_t is_suitable_sink(struct userdata *u, pa_sink *s) {
- const char *t;
-
- pa_sink_assert_ref(s);
-
- if (!(s->flags & PA_SINK_HARDWARE))
- return FALSE;
-
- if (s == u->sink)
- return FALSE;
-
- if ((t = pa_proplist_gets(s->proplist, PA_PROP_DEVICE_CLASS)))
- if (strcmp(t, "sound"))
- return FALSE;
-
- return TRUE;
-}
-
-static pa_hook_result_t sink_put_hook_cb(pa_core *c, pa_sink *s, struct userdata* u) {
- struct output *o;
-
- pa_core_assert_ref(c);
- pa_sink_assert_ref(s);
- pa_assert(u);
- pa_assert(u->automatic);
-
- if (!is_suitable_sink(u, s))
- return PA_HOOK_OK;
-
- pa_log_info("Configuring new sink: %s", s->name);
-
- if (!(o = output_new(u, s))) {
- pa_log("Failed to create sink input on sink '%s'.", s->name);
- return PA_HOOK_OK;
- }
-
- if (o->sink_input)
- pa_sink_input_put(o->sink_input);
-
- return PA_HOOK_OK;
-}
-
-static struct output* find_output(struct userdata *u, pa_sink *s) {
- struct output *o;
- uint32_t idx;
-
- pa_assert(u);
- pa_assert(s);
-
- if (u->sink == s)
- return NULL;
-
- for (o = pa_idxset_first(u->outputs, &idx); o; o = pa_idxset_next(u->outputs, &idx))
- if (o->sink == s)
- return o;
-
- return NULL;
-}
-
-static pa_hook_result_t sink_unlink_hook_cb(pa_core *c, pa_sink *s, struct userdata* u) {
- struct output *o;
-
- pa_assert(c);
- pa_sink_assert_ref(s);
- pa_assert(u);
-
- if (!(o = find_output(u, s)))
- return PA_HOOK_OK;
-
- pa_log_info("Unconfiguring sink: %s", s->name);
-
- output_free(o);
-
- return PA_HOOK_OK;
-}
-
-static pa_hook_result_t sink_state_changed_hook_cb(pa_core *c, pa_sink *s, struct userdata* u) {
- struct output *o;
- pa_sink_state_t state;
-
- if (!(o = find_output(u, s)))
- return PA_HOOK_OK;
-
- state = pa_sink_get_state(s);
-
- if (PA_SINK_IS_OPENED(state) && PA_SINK_IS_OPENED(pa_sink_get_state(u->sink)) && !o->sink_input)
- enable_output(o);
-
- if (state == PA_SINK_SUSPENDED && o->sink_input)
- disable_output(o);
-
- return PA_HOOK_OK;
-}
-
int pa__init(pa_module*m) {
struct userdata *u;
- pa_modargs *ma = NULL;
- const char *slaves, *rm;
- int resample_method = PA_RESAMPLER_TRIVIAL;
- pa_sample_spec ss;
- pa_channel_map map;
- struct output *o;
- uint32_t idx;
- pa_sink_new_data data;
+ pa_module *module;
pa_assert(m);
+ pa_assert_se(m->userdata = u = pa_xnew0(struct userdata, 1));
- if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
- pa_log("failed to parse module arguments");
- goto fail;
- }
-
- if ((rm = pa_modargs_get_value(ma, "resample_method", NULL))) {
- if ((resample_method = pa_parse_resample_method(rm)) < 0) {
- pa_log("invalid resample method '%s'", rm);
- goto fail;
- }
- }
-
- m->userdata = u = pa_xnew(struct userdata, 1);
- u->core = m->core;
- u->module = m;
- u->sink = NULL;
- u->time_event = NULL;
- u->adjust_time = DEFAULT_ADJUST_TIME;
- u->rtpoll = pa_rtpoll_new();
- pa_thread_mq_init(&u->thread_mq, m->core->mainloop, u->rtpoll);
- u->thread = NULL;
- u->resample_method = resample_method;
- u->outputs = pa_idxset_new(NULL, NULL);
- memset(&u->adjust_timestamp, 0, sizeof(u->adjust_timestamp));
- u->sink_put_slot = u->sink_unlink_slot = u->sink_state_changed_slot = NULL;
- PA_LLIST_HEAD_INIT(struct output, u->thread_info.active_outputs);
- pa_atomic_store(&u->thread_info.running, FALSE);
- u->thread_info.in_null_mode = FALSE;
- u->thread_info.counter = 0;
- u->thread_info.smoother = pa_smoother_new(
- PA_USEC_PER_SEC,
- PA_USEC_PER_SEC*2,
- TRUE,
- TRUE,
- 10,
- 0,
- FALSE);
-
- if (pa_modargs_get_value_u32(ma, "adjust_time", &u->adjust_time) < 0) {
- pa_log("Failed to parse adjust_time value");
- goto fail;
- }
-
- slaves = pa_modargs_get_value(ma, "slaves", NULL);
- u->automatic = !slaves;
-
- ss = m->core->default_sample_spec;
- map = m->core->default_channel_map;
- if ((pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_DEFAULT) < 0)) {
- pa_log("Invalid sample specification.");
- goto fail;
- }
-
- pa_sink_new_data_init(&data);
- data.namereg_fail = FALSE;
- data.driver = __FILE__;
- data.module = m;
- pa_sink_new_data_set_name(&data, pa_modargs_get_value(ma, "sink_name", DEFAULT_SINK_NAME));
- pa_sink_new_data_set_sample_spec(&data, &ss);
- pa_sink_new_data_set_channel_map(&data, &map);
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Simultaneous Output");
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_CLASS, "filter");
-
- if (slaves)
- pa_proplist_sets(data.proplist, "combine.slaves", slaves);
-
- if (pa_modargs_get_proplist(ma, "sink_properties", data.proplist, PA_UPDATE_REPLACE) < 0) {
- pa_log("Invalid properties");
- pa_sink_new_data_done(&data);
- goto fail;
- }
-
- u->sink = pa_sink_new(m->core, &data, PA_SINK_LATENCY);
- pa_sink_new_data_done(&data);
-
- if (!u->sink) {
- pa_log("Failed to create sink");
- goto fail;
- }
-
- u->sink->parent.process_msg = sink_process_msg;
- u->sink->set_state = sink_set_state;
- u->sink->userdata = u;
-
- pa_sink_set_rtpoll(u->sink, u->rtpoll);
- pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
-
- u->block_usec = BLOCK_USEC;
- pa_sink_set_max_request(u->sink, pa_usec_to_bytes(u->block_usec, &u->sink->sample_spec));
+ pa_log_warn("We will now load module-combine-sink. Please make sure to remove module-combine from your configuration.");
- if (!u->automatic) {
- const char*split_state;
- char *n = NULL;
- pa_assert(slaves);
+ module = pa_module_load(m->core, "module-combine-sink", m->argument);
+ u->module_index = module ? module->index : PA_INVALID_INDEX;
- /* The slaves have been specified manually */
-
- split_state = NULL;
- while ((n = pa_split(slaves, ",", &split_state))) {
- pa_sink *slave_sink;
-
- if (!(slave_sink = pa_namereg_get(m->core, n, PA_NAMEREG_SINK)) || slave_sink == u->sink) {
- pa_log("Invalid slave sink '%s'", n);
- pa_xfree(n);
- goto fail;
- }
-
- pa_xfree(n);
-
- if (!output_new(u, slave_sink)) {
- pa_log("Failed to create slave sink input on sink '%s'.", slave_sink->name);
- goto fail;
- }
- }
-
- if (pa_idxset_size(u->outputs) <= 1)
- pa_log_warn("No slave sinks specified.");
-
- u->sink_put_slot = NULL;
-
- } else {
- pa_sink *s;
-
- /* We're in automatic mode, we add every sink that matches our needs */
-
- for (s = pa_idxset_first(m->core->sinks, &idx); s; s = pa_idxset_next(m->core->sinks, &idx)) {
-
- if (!is_suitable_sink(u, s))
- continue;
-
- if (!output_new(u, s)) {
- pa_log("Failed to create sink input on sink '%s'.", s->name);
- goto fail;
- }
- }
-
- u->sink_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_LATE, (pa_hook_cb_t) sink_put_hook_cb, u);
- }
-
- u->sink_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_EARLY, (pa_hook_cb_t) sink_unlink_hook_cb, u);
- u->sink_state_changed_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_STATE_CHANGED], PA_HOOK_NORMAL, (pa_hook_cb_t) sink_state_changed_hook_cb, u);
-
- if (!(u->thread = pa_thread_new(thread_func, u))) {
- pa_log("Failed to create thread.");
- goto fail;
- }
-
- /* Activate the sink and the sink inputs */
- pa_sink_put(u->sink);
-
- for (o = pa_idxset_first(u->outputs, &idx); o; o = pa_idxset_next(u->outputs, &idx))
- if (o->sink_input)
- pa_sink_input_put(o->sink_input);
-
- if (u->adjust_time > 0) {
- struct timeval tv;
- pa_gettimeofday(&tv);
- tv.tv_sec += (time_t) u->adjust_time;
- u->time_event = m->core->mainloop->time_new(m->core->mainloop, &tv, time_callback, u);
- }
-
- pa_modargs_free(ma);
-
- return 0;
-
-fail:
-
- if (ma)
- pa_modargs_free(ma);
-
- pa__done(m);
-
- return -1;
+ return module ? 0 : -1;
}
-static void output_free(struct output *o) {
- pa_assert(o);
-
- disable_output(o);
-
- pa_assert_se(pa_idxset_remove_by_data(o->userdata->outputs, o, NULL));
-
- update_description(o->userdata);
-
- if (o->inq_rtpoll_item_read)
- pa_rtpoll_item_free(o->inq_rtpoll_item_read);
- if (o->inq_rtpoll_item_write)
- pa_rtpoll_item_free(o->inq_rtpoll_item_write);
-
- if (o->outq_rtpoll_item_read)
- pa_rtpoll_item_free(o->outq_rtpoll_item_read);
- if (o->outq_rtpoll_item_write)
- pa_rtpoll_item_free(o->outq_rtpoll_item_write);
-
- if (o->inq)
- pa_asyncmsgq_unref(o->inq);
-
- if (o->outq)
- pa_asyncmsgq_unref(o->outq);
-
- if (o->memblockq)
- pa_memblockq_free(o->memblockq);
-
- pa_xfree(o);
-}
void pa__done(pa_module*m) {
struct userdata *u;
- struct output *o;
pa_assert(m);
+ pa_assert(m->userdata);
- if (!(u = m->userdata))
- return;
-
- if (u->sink_put_slot)
- pa_hook_slot_free(u->sink_put_slot);
-
- if (u->sink_unlink_slot)
- pa_hook_slot_free(u->sink_unlink_slot);
-
- if (u->sink_state_changed_slot)
- pa_hook_slot_free(u->sink_state_changed_slot);
-
- if (u->outputs) {
- while ((o = pa_idxset_first(u->outputs, NULL)))
- output_free(o);
-
- pa_idxset_free(u->outputs, NULL, NULL);
- }
-
- if (u->sink)
- pa_sink_unlink(u->sink);
-
- if (u->thread) {
- pa_asyncmsgq_send(u->thread_mq.inq, NULL, PA_MESSAGE_SHUTDOWN, NULL, 0, NULL);
- pa_thread_free(u->thread);
- }
-
- pa_thread_mq_done(&u->thread_mq);
-
- if (u->sink)
- pa_sink_unref(u->sink);
-
- if (u->rtpoll)
- pa_rtpoll_free(u->rtpoll);
-
- if (u->time_event)
- u->core->mainloop->time_free(u->time_event);
+ u = m->userdata;
- if (u->thread_info.smoother)
- pa_smoother_free(u->thread_info.smoother);
+ if (u && PA_INVALID_INDEX != u->module_index)
+ pa_module_unload_by_index(m->core, u->module_index, TRUE);
pa_xfree(u);
}
diff --git a/src/modules/module-console-kit.c b/src/modules/module-console-kit.c
index a666073c..4c5857cf 100644
--- a/src/modules/module-console-kit.c
+++ b/src/modules/module-console-kit.c
@@ -25,24 +25,17 @@
#include <stdio.h>
#include <unistd.h>
-#include <string.h>
#include <stdlib.h>
#include <errno.h>
#include <stdlib.h>
#include <sys/types.h>
-#include <sys/stat.h>
#include <pulse/xmalloc.h>
-#include <pulse/timeval.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
#include <pulsecore/log.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/idxset.h>
-#include <pulsecore/core-util.h>
-#include <pulsecore/namereg.h>
-#include <pulsecore/core-scache.h>
#include <pulsecore/modargs.h>
#include <pulsecore/dbus-shared.h>
@@ -67,6 +60,7 @@ struct userdata {
pa_core *core;
pa_dbus_connection *connection;
pa_hashmap *sessions;
+ pa_bool_t filter_added;
};
static void add_session(struct userdata *u, const char *id) {
@@ -76,7 +70,7 @@ static void add_session(struct userdata *u, const char *id) {
struct session *session;
pa_client_new_data data;
- dbus_error_init (&error);
+ dbus_error_init(&error);
if (pa_hashmap_get(u->sessions, id)) {
pa_log_warn("Duplicate session %s, ignoring.", id);
@@ -187,7 +181,6 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
}
add_session(u, path);
- return DBUS_HANDLER_RESULT_HANDLED;
} else if (dbus_message_is_signal(message, "org.freedesktop.ConsoleKit.Seat", "SessionRemoved")) {
@@ -202,7 +195,6 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
}
remove_session(u, path);
- return DBUS_HANDLER_RESULT_HANDLED;
}
finish:
@@ -302,7 +294,7 @@ int pa__init(pa_module*m) {
goto fail;
}
- m->userdata = u = pa_xnew(struct userdata, 1);
+ m->userdata = u = pa_xnew0(struct userdata, 1);
u->core = m->core;
u->module = m;
u->connection = connection;
@@ -313,6 +305,8 @@ int pa__init(pa_module*m) {
goto fail;
}
+ u->filter_added = TRUE;
+
if (pa_dbus_add_matches(
pa_dbus_connection_get(connection), &error,
"type='signal',sender='org.freedesktop.ConsoleKit',interface='org.freedesktop.ConsoleKit.Seat',member='SessionAdded'",
@@ -361,7 +355,9 @@ void pa__done(pa_module *m) {
"type='signal',sender='org.freedesktop.ConsoleKit',interface='org.freedesktop.ConsoleKit.Seat',member='SessionAdded'",
"type='signal',sender='org.freedesktop.ConsoleKit',interface='org.freedesktop.ConsoleKit.Seat',member='SessionRemoved'", NULL);
- dbus_connection_remove_filter(pa_dbus_connection_get(u->connection), filter_cb, u);
+ if (u->filter_added)
+ dbus_connection_remove_filter(pa_dbus_connection_get(u->connection), filter_cb, u);
+
pa_dbus_connection_unref(u->connection);
}
diff --git a/src/modules/module-cork-music-on-phone.c b/src/modules/module-cork-music-on-phone.c
index d3a2b00e..4c9c1788 100644
--- a/src/modules/module-cork-music-on-phone.c
+++ b/src/modules/module-cork-music-on-phone.c
@@ -23,6 +23,8 @@
#include <config.h>
#endif
+#include <pulse/xmalloc.h>
+
#include <pulsecore/macro.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/hook-list.h>
@@ -66,8 +68,10 @@ static pa_bool_t shall_cork(pa_sink *s, pa_sink_input *ignore) {
if (!(role = pa_proplist_gets(j->proplist, PA_PROP_MEDIA_ROLE)))
continue;
- if (pa_streq(role, "phone"))
+ if (pa_streq(role, "phone")) {
+ pa_log_debug("Found a phone stream that will trigger the auto-cork.");
return TRUE;
+ }
}
return FALSE;
@@ -81,7 +85,7 @@ static void apply_cork(struct userdata *u, pa_sink *s, pa_sink_input *ignore, pa
pa_sink_assert_ref(s);
for (j = PA_SINK_INPUT(pa_idxset_first(s->inputs, &idx)); j; j = PA_SINK_INPUT(pa_idxset_next(s->inputs, &idx))) {
- pa_bool_t corked;
+ pa_bool_t corked, muted, corked_here;
const char *role;
if (j == ignore)
@@ -94,18 +98,25 @@ static void apply_cork(struct userdata *u, pa_sink *s, pa_sink_input *ignore, pa
!pa_streq(role, "music"))
continue;
- corked = !!pa_hashmap_get(u->cork_state, j);
+ corked = (pa_sink_input_get_state(j) == PA_SINK_INPUT_CORKED);
+ muted = pa_sink_input_get_mute(j);
+ corked_here = !!pa_hashmap_get(u->cork_state, j);
- if (cork && !corked) {
- pa_hashmap_put(u->cork_state, j, PA_INT_TO_PTR(1));
+ if (cork && !corked && !muted) {
+ pa_log_debug("Found a music/video stream that should be corked/muted.");
+ if (!corked_here)
+ pa_hashmap_put(u->cork_state, j, PA_INT_TO_PTR(1));
pa_sink_input_set_mute(j, TRUE, FALSE);
pa_sink_input_send_event(j, PA_STREAM_EVENT_REQUEST_CORK, NULL);
} else if (!cork) {
pa_hashmap_remove(u->cork_state, j);
- if (corked) {
- pa_sink_input_set_mute(j, FALSE, FALSE);
- pa_sink_input_send_event(j, PA_STREAM_EVENT_REQUEST_UNCORK, NULL);
+ if (corked_here && (corked || muted)) {
+ pa_log_debug("Found a music/video stream that should be uncorked/unmuted.");
+ if (muted)
+ pa_sink_input_set_mute(j, FALSE, FALSE);
+ if (corked)
+ pa_sink_input_send_event(j, PA_STREAM_EVENT_REQUEST_UNCORK, NULL);
}
}
}
@@ -129,6 +140,9 @@ static pa_hook_result_t process(struct userdata *u, pa_sink_input *i, pa_bool_t
!pa_streq(role, "video"))
return PA_HOOK_OK;
+ if (!i->sink)
+ return PA_HOOK_OK;
+
cork = shall_cork(i->sink, create ? NULL : i);
apply_cork(u, i->sink, create ? NULL : i, cork);
@@ -193,7 +207,7 @@ fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
}
diff --git a/src/modules/module-default-device-restore.c b/src/modules/module-default-device-restore.c
index 0092d1c7..f28bddb7 100644
--- a/src/modules/module-default-device-restore.c
+++ b/src/modules/module-default-device-restore.c
@@ -26,8 +26,9 @@
#include <errno.h>
#include <stdio.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
-#include <pulse/util.h>
+#include <pulse/xmalloc.h>
#include <pulsecore/core-util.h>
#include <pulsecore/module.h>
@@ -42,7 +43,7 @@ PA_MODULE_DESCRIPTION("Automatically restore the default sink and source");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
-#define DEFAULT_SAVE_INTERVAL 5
+#define SAVE_INTERVAL (5 * PA_USEC_PER_SEC)
struct userdata {
pa_core *core;
@@ -59,12 +60,12 @@ static void load(struct userdata *u) {
if (u->core->default_sink)
pa_log_info("Manually configured default sink, not overwriting.");
- else if ((f = fopen(u->sink_filename, "r"))) {
+ else if ((f = pa_fopen_cloexec(u->sink_filename, "r"))) {
char ln[256] = "";
pa_sink *s;
- (void) fgets(ln, sizeof(ln)-1, f);
- pa_strip_nl(ln);
+ if (fgets(ln, sizeof(ln)-1, f))
+ pa_strip_nl(ln);
fclose(f);
if (!ln[0])
@@ -80,12 +81,12 @@ static void load(struct userdata *u) {
if (u->core->default_source)
pa_log_info("Manually configured default source, not overwriting.");
- else if ((f = fopen(u->source_filename, "r"))) {
+ else if ((f = pa_fopen_cloexec(u->source_filename, "r"))) {
char ln[256] = "";
pa_source *s;
- (void) fgets(ln, sizeof(ln)-1, f);
- pa_strip_nl(ln);
+ if (fgets(ln, sizeof(ln)-1, f))
+ pa_strip_nl(ln);
fclose(f);
if (!ln[0])
@@ -107,7 +108,7 @@ static void save(struct userdata *u) {
return;
if (u->sink_filename) {
- if ((f = fopen(u->sink_filename, "w"))) {
+ if ((f = pa_fopen_cloexec(u->sink_filename, "w"))) {
pa_sink *s = pa_namereg_get_default_sink(u->core);
fprintf(f, "%s\n", s ? s->name : "");
fclose(f);
@@ -116,7 +117,7 @@ static void save(struct userdata *u) {
}
if (u->source_filename) {
- if ((f = fopen(u->source_filename, "w"))) {
+ if ((f = pa_fopen_cloexec(u->source_filename, "w"))) {
pa_source *s = pa_namereg_get_default_source(u->core);
fprintf(f, "%s\n", s ? s->name : "");
fclose(f);
@@ -127,7 +128,7 @@ static void save(struct userdata *u) {
u->modified = FALSE;
}
-static void time_cb(pa_mainloop_api *a, pa_time_event *e, const struct timeval *tv, void *userdata) {
+static void time_cb(pa_mainloop_api *a, pa_time_event *e, const struct timeval *t, void *userdata) {
struct userdata *u = userdata;
pa_assert(u);
@@ -146,12 +147,8 @@ static void subscribe_cb(pa_core *c, pa_subscription_event_type_t t, uint32_t id
u->modified = TRUE;
- if (!u->time_event) {
- struct timeval tv;
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, DEFAULT_SAVE_INTERVAL*PA_USEC_PER_SEC);
- u->time_event = u->core->mainloop->time_new(u->core->mainloop, &tv, time_cb, u);
- }
+ if (!u->time_event)
+ u->time_event = pa_core_rttime_new(u->core, pa_rtclock_now() + SAVE_INTERVAL, time_cb, u);
}
int pa__init(pa_module *m) {
diff --git a/src/modules/module-detect.c b/src/modules/module-detect.c
index 18479df3..bb4994c6 100644
--- a/src/modules/module-detect.c
+++ b/src/modules/module-detect.c
@@ -34,8 +34,6 @@
#include <sys/types.h>
#include <sys/stat.h>
-#include <pulse/xmalloc.h>
-
#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
#include <pulsecore/modargs.h>
@@ -50,7 +48,7 @@ PA_MODULE_DESCRIPTION("Detect available audio hardware and load matching drivers
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
PA_MODULE_USAGE("just-one=<boolean>");
-PA_MODULE_DEPRECATED("Please use module-hal-detect instead of module-detect!");
+PA_MODULE_DEPRECATED("Please use module-udev-detect instead of module-detect!");
static const char* const valid_modargs[] = {
"just-one",
@@ -63,7 +61,7 @@ static int detect_alsa(pa_core *c, int just_one) {
FILE *f;
int n = 0, n_sink = 0, n_source = 0;
- if (!(f = fopen("/proc/asound/devices", "r"))) {
+ if (!(f = pa_fopen_cloexec("/proc/asound/devices", "r"))) {
if (errno != ENOENT)
pa_log_error("open(\"/proc/asound/devices\") failed: %s", pa_cstrerror(errno));
@@ -119,14 +117,14 @@ static int detect_alsa(pa_core *c, int just_one) {
}
#endif
-#ifdef HAVE_OSS
+#ifdef HAVE_OSS_OUTPUT
static int detect_oss(pa_core *c, int just_one) {
FILE *f;
int n = 0, b = 0;
- if (!(f = fopen("/dev/sndstat", "r")) &&
- !(f = fopen("/proc/sndstat", "r")) &&
- !(f = fopen("/proc/asound/oss/sndstat", "r"))) {
+ if (!(f = pa_fopen_cloexec("/dev/sndstat", "r")) &&
+ !(f = pa_fopen_cloexec("/proc/sndstat", "r")) &&
+ !(f = pa_fopen_cloexec("/proc/asound/oss/sndstat", "r"))) {
if (errno != ENOENT)
pa_log_error("failed to open OSS sndstat device: %s", pa_cstrerror(errno));
@@ -144,7 +142,7 @@ static int detect_oss(pa_core *c, int just_one) {
line[strcspn(line, "\r\n")] = 0;
if (!b) {
- b = strcmp(line, "Audio devices:") == 0 || strcmp(line, "Installed devices:") == 0;
+ b = strcmp(line, "Audio devices:") == 0 || strcmp(line, "Installed devices:") == 0;
continue;
}
@@ -240,7 +238,7 @@ int pa__init(pa_module*m) {
#ifdef HAVE_ALSA
if ((n = detect_alsa(m->core, just_one)) <= 0)
#endif
-#ifdef HAVE_OSS
+#ifdef HAVE_OSS_OUTPUT
if ((n = detect_oss(m->core, just_one)) <= 0)
#endif
#ifdef HAVE_SOLARIS
diff --git a/src/modules/module-device-manager.c b/src/modules/module-device-manager.c
new file mode 100644
index 00000000..67baef31
--- /dev/null
+++ b/src/modules/module-device-manager.c
@@ -0,0 +1,1700 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2006-2008 Lennart Poettering
+ Copyright 2009 Colin Guthrie
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <unistd.h>
+#include <string.h>
+#include <errno.h>
+#include <sys/types.h>
+#include <stdio.h>
+#include <stdlib.h>
+
+#include <pulse/gccmacro.h>
+#include <pulse/xmalloc.h>
+#include <pulse/timeval.h>
+#include <pulse/rtclock.h>
+
+#include <pulsecore/core-error.h>
+#include <pulsecore/module.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/core-subscribe.h>
+#include <pulsecore/sink-input.h>
+#include <pulsecore/source-output.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/protocol-native.h>
+#include <pulsecore/pstream.h>
+#include <pulsecore/pstream-util.h>
+#include <pulsecore/database.h>
+#include <pulsecore/tagstruct.h>
+
+#include "module-device-manager-symdef.h"
+
+PA_MODULE_AUTHOR("Colin Guthrie");
+PA_MODULE_DESCRIPTION("Keep track of devices (and their descriptions) both past and present and prioritise by role");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_USAGE(
+ "do_routing=<Automatically route streams based on a priority list (unique per-role)?> "
+ "on_hotplug=<When new device becomes available, recheck streams?> "
+ "on_rescue=<When device becomes unavailable, recheck streams?>");
+
+#define SAVE_INTERVAL (10 * PA_USEC_PER_SEC)
+#define DUMP_DATABASE
+
+static const char* const valid_modargs[] = {
+ "do_routing",
+ "on_hotplug",
+ "on_rescue",
+ NULL
+};
+
+#define NUM_ROLES 9
+enum {
+ ROLE_NONE,
+ ROLE_VIDEO,
+ ROLE_MUSIC,
+ ROLE_GAME,
+ ROLE_EVENT,
+ ROLE_PHONE,
+ ROLE_ANIMATION,
+ ROLE_PRODUCTION,
+ ROLE_A11Y,
+ ROLE_MAX
+};
+
+typedef uint32_t role_indexes_t[NUM_ROLES];
+
+static const char* role_names[NUM_ROLES] = {
+ "none",
+ "video",
+ "music",
+ "game",
+ "event",
+ "phone",
+ "animation",
+ "production",
+ "a11y",
+};
+
+struct userdata {
+ pa_core *core;
+ pa_module *module;
+ pa_subscription *subscription;
+ pa_hook_slot
+ *sink_new_hook_slot,
+ *source_new_hook_slot,
+ *sink_input_new_hook_slot,
+ *source_output_new_hook_slot,
+ *sink_put_hook_slot,
+ *source_put_hook_slot,
+ *sink_unlink_hook_slot,
+ *source_unlink_hook_slot,
+ *connection_unlink_hook_slot;
+ pa_time_event *save_time_event;
+ pa_database *database;
+
+ pa_native_protocol *protocol;
+ pa_idxset *subscribed;
+
+ pa_bool_t on_hotplug;
+ pa_bool_t on_rescue;
+ pa_bool_t do_routing;
+
+ role_indexes_t preferred_sinks;
+ role_indexes_t preferred_sources;
+};
+
+#define ENTRY_VERSION 1
+
+struct entry {
+ uint8_t version;
+ char *description;
+ pa_bool_t user_set_description;
+ char *icon;
+ role_indexes_t priority;
+};
+
+enum {
+ SUBCOMMAND_TEST,
+ SUBCOMMAND_READ,
+ SUBCOMMAND_RENAME,
+ SUBCOMMAND_DELETE,
+ SUBCOMMAND_ROLE_DEVICE_PRIORITY_ROUTING,
+ SUBCOMMAND_REORDER,
+ SUBCOMMAND_SUBSCRIBE,
+ SUBCOMMAND_EVENT
+};
+
+
+/* Forward declarations */
+#ifdef DUMP_DATABASE
+static void dump_database(struct userdata *);
+#endif
+static void notify_subscribers(struct userdata *);
+
+
+static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *t, void *userdata) {
+ struct userdata *u = userdata;
+
+ pa_assert(a);
+ pa_assert(e);
+ pa_assert(u);
+
+ pa_assert(e == u->save_time_event);
+ u->core->mainloop->time_free(u->save_time_event);
+ u->save_time_event = NULL;
+
+ pa_database_sync(u->database);
+ pa_log_info("Synced.");
+
+#ifdef DUMP_DATABASE
+ dump_database(u);
+#endif
+}
+
+static void trigger_save(struct userdata *u) {
+
+ pa_assert(u);
+
+ notify_subscribers(u);
+
+ if (u->save_time_event)
+ return;
+
+ u->save_time_event = pa_core_rttime_new(u->core, pa_rtclock_now() + SAVE_INTERVAL, save_time_callback, u);
+}
+
+static struct entry* entry_new(void) {
+ struct entry *r = pa_xnew0(struct entry, 1);
+ r->version = ENTRY_VERSION;
+ return r;
+}
+
+static void entry_free(struct entry* e) {
+ pa_assert(e);
+
+ pa_xfree(e->description);
+ pa_xfree(e->icon);
+}
+
+static pa_bool_t entry_write(struct userdata *u, const char *name, const struct entry *e) {
+ pa_tagstruct *t;
+ pa_datum key, data;
+ pa_bool_t r;
+
+ pa_assert(u);
+ pa_assert(name);
+ pa_assert(e);
+
+ t = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu8(t, e->version);
+ pa_tagstruct_puts(t, e->description);
+ pa_tagstruct_put_boolean(t, e->user_set_description);
+ pa_tagstruct_puts(t, e->icon);
+ for (uint8_t i=0; i<ROLE_MAX; ++i)
+ pa_tagstruct_putu32(t, e->priority[i]);
+
+ key.data = (char *) name;
+ key.size = strlen(name);
+
+ data.data = (void*)pa_tagstruct_data(t, &data.size);
+
+ r = (pa_database_set(u->database, &key, &data, TRUE) == 0);
+
+ pa_tagstruct_free(t);
+
+ return r;
+}
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+
+#define LEGACY_ENTRY_VERSION 1
+static struct entry* legacy_entry_read(struct userdata *u, pa_datum *data) {
+ struct legacy_entry {
+ uint8_t version;
+ char description[PA_NAME_MAX];
+ pa_bool_t user_set_description;
+ char icon[PA_NAME_MAX];
+ role_indexes_t priority;
+ } PA_GCC_PACKED;
+ struct legacy_entry *le;
+ struct entry *e;
+
+ pa_assert(u);
+ pa_assert(data);
+
+ if (data->size != sizeof(struct legacy_entry)) {
+ pa_log_debug("Size does not match.");
+ return NULL;
+ }
+
+ le = (struct legacy_entry*)data->data;
+
+ if (le->version != LEGACY_ENTRY_VERSION) {
+ pa_log_debug("Version mismatch.");
+ return NULL;
+ }
+
+ if (!memchr(le->description, 0, sizeof(le->description))) {
+ pa_log_warn("Description has missing NUL byte.");
+ return NULL;
+ }
+
+ if (!memchr(le->icon, 0, sizeof(le->icon))) {
+ pa_log_warn("Icon has missing NUL byte.");
+ return NULL;
+ }
+
+ e = entry_new();
+ e->description = pa_xstrdup(le->description);
+ e->icon = pa_xstrdup(le->icon);
+ return e;
+}
+#endif
+
+static struct entry* entry_read(struct userdata *u, const char *name) {
+ pa_datum key, data;
+ struct entry *e = NULL;
+ pa_tagstruct *t = NULL;
+ const char *description, *icon;
+
+ pa_assert(u);
+ pa_assert(name);
+
+ key.data = (char*) name;
+ key.size = strlen(name);
+
+ pa_zero(data);
+
+ if (!pa_database_get(u->database, &key, &data))
+ goto fail;
+
+ t = pa_tagstruct_new(data.data, data.size);
+ e = entry_new();
+
+ if (pa_tagstruct_getu8(t, &e->version) < 0 ||
+ e->version > ENTRY_VERSION ||
+ pa_tagstruct_gets(t, &description) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->user_set_description) < 0 ||
+ pa_tagstruct_gets(t, &icon) < 0) {
+
+ goto fail;
+ }
+
+ e->description = pa_xstrdup(description);
+ e->icon = pa_xstrdup(icon);
+
+ for (uint8_t i=0; i<ROLE_MAX; ++i) {
+ if (pa_tagstruct_getu32(t, &e->priority[i]) < 0)
+ goto fail;
+ }
+
+ if (!pa_tagstruct_eof(t))
+ goto fail;
+
+ pa_tagstruct_free(t);
+ pa_datum_free(&data);
+
+ return e;
+
+fail:
+ pa_log_debug("Database contains invalid data for key: %s (probably pre-v1.0 data)", name);
+
+ if (e)
+ entry_free(e);
+ if (t)
+ pa_tagstruct_free(t);
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+ pa_log_debug("Attempting to load legacy (pre-v1.0) data for key: %s", name);
+ if ((e = legacy_entry_read(u, &data))) {
+ pa_log_debug("Success. Saving new format for key: %s", name);
+ if (entry_write(u, name, e))
+ trigger_save(u);
+ pa_datum_free(&data);
+ return e;
+ } else
+ pa_log_debug("Unable to load legacy (pre-v1.0) data for key: %s. Ignoring.", name);
+#endif
+
+ pa_datum_free(&data);
+ return NULL;
+}
+
+#ifdef DUMP_DATABASE
+static void dump_database_helper(struct userdata *u, uint32_t role_index, const char* human, pa_bool_t sink_mode) {
+ pa_assert(u);
+ pa_assert(human);
+
+ if (sink_mode) {
+ pa_sink *s;
+ if (PA_INVALID_INDEX != u->preferred_sinks[role_index] && (s = pa_idxset_get_by_index(u->core->sinks, u->preferred_sinks[role_index])))
+ pa_log_debug(" %s %s (%s)", human, pa_strnull(pa_proplist_gets(s->proplist, PA_PROP_DEVICE_DESCRIPTION)), s->name);
+ else
+ pa_log_debug(" %s No sink specified", human);
+ } else {
+ pa_source *s;
+ if (PA_INVALID_INDEX != u->preferred_sources[role_index] && (s = pa_idxset_get_by_index(u->core->sources, u->preferred_sources[role_index])))
+ pa_log_debug(" %s %s (%s)", human, pa_strnull(pa_proplist_gets(s->proplist, PA_PROP_DEVICE_DESCRIPTION)), s->name);
+ else
+ pa_log_debug(" %s No source specified", human);
+ }
+}
+
+static void dump_database(struct userdata *u) {
+ pa_datum key;
+ pa_bool_t done;
+
+ pa_assert(u);
+
+ done = !pa_database_first(u->database, &key, NULL);
+
+ pa_log_debug("Dumping database");
+ while (!done) {
+ char *name;
+ struct entry *e;
+ pa_datum next_key;
+
+ done = !pa_database_next(u->database, &key, &next_key, NULL);
+
+ name = pa_xstrndup(key.data, key.size);
+
+ if ((e = entry_read(u, name))) {
+ pa_log_debug(" Got entry: %s", name);
+ pa_log_debug(" Description: %s", e->description);
+ pa_log_debug(" Priorities: None: %3u, Video: %3u, Music: %3u, Game: %3u, Event: %3u",
+ e->priority[ROLE_NONE], e->priority[ROLE_VIDEO], e->priority[ROLE_MUSIC], e->priority[ROLE_GAME], e->priority[ROLE_EVENT]);
+ pa_log_debug(" Phone: %3u, Anim: %3u, Prodtn: %3u, A11y: %3u",
+ e->priority[ROLE_PHONE], e->priority[ROLE_ANIMATION], e->priority[ROLE_PRODUCTION], e->priority[ROLE_A11Y]);
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+
+ pa_datum_free(&key);
+ key = next_key;
+ }
+
+ if (u->do_routing) {
+ pa_log_debug(" Highest priority devices per-role:");
+
+ pa_log_debug(" Sinks:");
+ for (uint32_t role = ROLE_NONE; role < NUM_ROLES; ++role) {
+ char name[13];
+ uint32_t len = PA_MIN(12u, strlen(role_names[role]));
+ strncpy(name, role_names[role], len);
+ for (int i = len+1; i < 12; ++i) name[i] = ' ';
+ name[len] = ':'; name[0] -= 32; name[12] = '\0';
+ dump_database_helper(u, role, name, TRUE);
+ }
+
+ pa_log_debug(" Sources:");
+ for (uint32_t role = ROLE_NONE; role < NUM_ROLES; ++role) {
+ char name[13];
+ uint32_t len = PA_MIN(12u, strlen(role_names[role]));
+ strncpy(name, role_names[role], len);
+ for (int i = len+1; i < 12; ++i) name[i] = ' ';
+ name[len] = ':'; name[0] -= 32; name[12] = '\0';
+ dump_database_helper(u, role, name, FALSE);
+ }
+ }
+
+ pa_log_debug("Completed database dump");
+}
+#endif
+
+static void notify_subscribers(struct userdata *u) {
+
+ pa_native_connection *c;
+ uint32_t idx;
+
+ pa_assert(u);
+
+ for (c = pa_idxset_first(u->subscribed, &idx); c; c = pa_idxset_next(u->subscribed, &idx)) {
+ pa_tagstruct *t;
+
+ t = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu32(t, PA_COMMAND_EXTENSION);
+ pa_tagstruct_putu32(t, 0);
+ pa_tagstruct_putu32(t, u->module->index);
+ pa_tagstruct_puts(t, u->module->name);
+ pa_tagstruct_putu32(t, SUBCOMMAND_EVENT);
+
+ pa_pstream_send_tagstruct(pa_native_connection_get_pstream(c), t);
+ }
+}
+
+static pa_bool_t entries_equal(const struct entry *a, const struct entry *b) {
+
+ pa_assert(a);
+ pa_assert(b);
+
+ if (!pa_streq(a->description, b->description)
+ || a->user_set_description != b->user_set_description
+ || !pa_streq(a->icon, b->icon))
+ return FALSE;
+
+ for (int i=0; i < NUM_ROLES; ++i)
+ if (a->priority[i] != b->priority[i])
+ return FALSE;
+
+ return TRUE;
+}
+
+static char *get_name(const char *key, const char *prefix) {
+ char *t;
+
+ if (strncmp(key, prefix, strlen(prefix)))
+ return NULL;
+
+ t = pa_xstrdup(key + strlen(prefix));
+ return t;
+}
+
+static inline struct entry *load_or_initialize_entry(struct userdata *u, struct entry *entry, const char *name, const char *prefix) {
+ struct entry *old;
+
+ pa_assert(u);
+ pa_assert(entry);
+ pa_assert(name);
+ pa_assert(prefix);
+
+ if ((old = entry_read(u, name))) {
+ *entry = *old;
+ entry->description = pa_xstrdup(old->description);
+ entry->icon = pa_xstrdup(old->icon);
+ } else {
+ /* This is a new device, so make sure we write it's priority list correctly */
+ role_indexes_t max_priority;
+ pa_datum key;
+ pa_bool_t done;
+
+ pa_zero(max_priority);
+ done = !pa_database_first(u->database, &key, NULL);
+
+ /* Find all existing devices with the same prefix so we calculate the current max priority for each role */
+ while (!done) {
+ pa_datum next_key;
+
+ done = !pa_database_next(u->database, &key, &next_key, NULL);
+
+ if (key.size > strlen(prefix) && strncmp(key.data, prefix, strlen(prefix)) == 0) {
+ char *name2;
+ struct entry *e;
+
+ name2 = pa_xstrndup(key.data, key.size);
+
+ if ((e = entry_read(u, name2))) {
+ for (uint32_t i = 0; i < NUM_ROLES; ++i) {
+ max_priority[i] = PA_MAX(max_priority[i], e->priority[i]);
+ }
+
+ entry_free(e);
+ }
+
+ pa_xfree(name2);
+ }
+ pa_datum_free(&key);
+ key = next_key;
+ }
+
+ /* Actually initialise our entry now we've calculated it */
+ for (uint32_t i = 0; i < NUM_ROLES; ++i) {
+ entry->priority[i] = max_priority[i] + 1;
+ }
+ entry->user_set_description = FALSE;
+ }
+
+ return old;
+}
+
+static uint32_t get_role_index(const char* role) {
+ pa_assert(role);
+
+ for (uint32_t i = ROLE_NONE; i < NUM_ROLES; ++i)
+ if (strcmp(role, role_names[i]) == 0)
+ return i;
+
+ return PA_INVALID_INDEX;
+}
+
+static void update_highest_priority_device_indexes(struct userdata *u, const char *prefix, void *ignore_device) {
+ role_indexes_t *indexes, highest_priority_available;
+ pa_datum key;
+ pa_bool_t done, sink_mode;
+
+ pa_assert(u);
+ pa_assert(prefix);
+
+ sink_mode = (strcmp(prefix, "sink:") == 0);
+
+ if (sink_mode)
+ indexes = &u->preferred_sinks;
+ else
+ indexes = &u->preferred_sources;
+
+ for (uint32_t i = 0; i < NUM_ROLES; ++i) {
+ (*indexes)[i] = PA_INVALID_INDEX;
+ }
+ pa_zero(highest_priority_available);
+
+ done = !pa_database_first(u->database, &key, NULL);
+
+ /* Find all existing devices with the same prefix so we find the highest priority device for each role */
+ while (!done) {
+ pa_datum next_key;
+
+ done = !pa_database_next(u->database, &key, &next_key, NULL);
+
+ if (key.size > strlen(prefix) && strncmp(key.data, prefix, strlen(prefix)) == 0) {
+ char *name, *device_name;
+ struct entry *e;
+
+ name = pa_xstrndup(key.data, key.size);
+ device_name = get_name(name, prefix);
+
+ if ((e = entry_read(u, name))) {
+ for (uint32_t i = 0; i < NUM_ROLES; ++i) {
+ if (!highest_priority_available[i] || e->priority[i] < highest_priority_available[i]) {
+ /* We've found a device with a higher priority than that we've currently got,
+ so see if it is currently available or not and update our list */
+ uint32_t idx;
+ pa_bool_t found = FALSE;
+
+ if (sink_mode) {
+ pa_sink *sink;
+
+ PA_IDXSET_FOREACH(sink, u->core->sinks, idx) {
+ if ((pa_sink*) ignore_device == sink)
+ continue;
+ if (strcmp(sink->name, device_name) == 0) {
+ found = TRUE;
+ idx = sink->index; /* Is this needed? */
+ break;
+ }
+ }
+ } else {
+ pa_source *source;
+
+ PA_IDXSET_FOREACH(source, u->core->sources, idx) {
+ if ((pa_source*) ignore_device == source)
+ continue;
+ if (strcmp(source->name, device_name) == 0) {
+ found = TRUE;
+ idx = source->index; /* Is this needed? */
+ break;
+ }
+ }
+ }
+ if (found) {
+ highest_priority_available[i] = e->priority[i];
+ (*indexes)[i] = idx;
+ }
+
+ }
+ }
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+ pa_xfree(device_name);
+ }
+
+ pa_datum_free(&key);
+ key = next_key;
+ }
+}
+
+
+static void route_sink_input(struct userdata *u, pa_sink_input *si) {
+ const char *role;
+ uint32_t role_index, device_index;
+ pa_sink *sink;
+
+ pa_assert(u);
+ pa_assert(u->do_routing);
+
+ if (si->save_sink)
+ return;
+
+ /* Skip this if it is already in the process of being moved anyway */
+ if (!si->sink)
+ return;
+
+ /* It might happen that a stream and a sink are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (!PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(si)))
+ return;
+
+ if (!(role = pa_proplist_gets(si->proplist, PA_PROP_MEDIA_ROLE)))
+ role_index = get_role_index("none");
+ else
+ role_index = get_role_index(role);
+
+ if (PA_INVALID_INDEX == role_index)
+ return;
+
+ device_index = u->preferred_sinks[role_index];
+ if (PA_INVALID_INDEX == device_index)
+ return;
+
+ if (!(sink = pa_idxset_get_by_index(u->core->sinks, device_index)))
+ return;
+
+ if (si->sink != sink)
+ pa_sink_input_move_to(si, sink, FALSE);
+}
+
+static pa_hook_result_t route_sink_inputs(struct userdata *u, pa_sink *ignore_sink) {
+ pa_sink_input *si;
+ uint32_t idx;
+
+ pa_assert(u);
+
+ if (!u->do_routing)
+ return PA_HOOK_OK;
+
+ update_highest_priority_device_indexes(u, "sink:", ignore_sink);
+
+ PA_IDXSET_FOREACH(si, u->core->sink_inputs, idx) {
+ route_sink_input(u, si);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static void route_source_output(struct userdata *u, pa_source_output *so) {
+ const char *role;
+ uint32_t role_index, device_index;
+ pa_source *source;
+
+ pa_assert(u);
+ pa_assert(u->do_routing);
+
+ if (so->save_source)
+ return;
+
+ if (so->direct_on_input)
+ return;
+
+ /* Skip this if it is already in the process of being moved anyway */
+ if (!so->source)
+ return;
+
+ /* It might happen that a stream and a source are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (!PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(so)))
+ return;
+
+ if (!(role = pa_proplist_gets(so->proplist, PA_PROP_MEDIA_ROLE)))
+ role_index = get_role_index("none");
+ else
+ role_index = get_role_index(role);
+
+ if (PA_INVALID_INDEX == role_index)
+ return;
+
+ device_index = u->preferred_sources[role_index];
+ if (PA_INVALID_INDEX == device_index)
+ return;
+
+ if (!(source = pa_idxset_get_by_index(u->core->sources, device_index)))
+ return;
+
+ if (so->source != source)
+ pa_source_output_move_to(so, source, FALSE);
+}
+
+static pa_hook_result_t route_source_outputs(struct userdata *u, pa_source* ignore_source) {
+ pa_source_output *so;
+ uint32_t idx;
+
+ pa_assert(u);
+
+ if (!u->do_routing)
+ return PA_HOOK_OK;
+
+ update_highest_priority_device_indexes(u, "source:", ignore_source);
+
+ PA_IDXSET_FOREACH(so, u->core->source_outputs, idx) {
+ route_source_output(u, so);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
+ struct userdata *u = userdata;
+ struct entry *entry, *old = NULL;
+ char *name = NULL;
+
+ pa_assert(c);
+ pa_assert(u);
+
+ if (t != (PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_NEW) &&
+ t != (PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE) &&
+ t != (PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_NEW) &&
+ t != (PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE) &&
+
+ /*t != (PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_NEW) &&*/
+ t != (PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE) &&
+ /*t != (PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_NEW) &&*/
+ t != (PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE))
+ return;
+
+ entry = entry_new();
+
+ if ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SINK_INPUT) {
+ pa_sink_input *si;
+
+ if (!u->do_routing)
+ return;
+ if (!(si = pa_idxset_get_by_index(c->sink_inputs, idx)))
+ return;
+
+ /* The role may change mid-stream, so we reroute */
+ route_sink_input(u, si);
+
+ return;
+ } else if ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT) {
+ pa_source_output *so;
+
+ if (!u->do_routing)
+ return;
+ if (!(so = pa_idxset_get_by_index(c->source_outputs, idx)))
+ return;
+
+ /* The role may change mid-stream, so we reroute */
+ route_source_output(u, so);
+
+ return;
+ } else if ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SINK) {
+ pa_sink *sink;
+
+ if (!(sink = pa_idxset_get_by_index(c->sinks, idx)))
+ return;
+
+ name = pa_sprintf_malloc("sink:%s", sink->name);
+
+ old = load_or_initialize_entry(u, entry, name, "sink:");
+
+ if (!entry->user_set_description) {
+ pa_xfree(entry->description);
+ entry->description = pa_xstrdup(pa_proplist_gets(sink->proplist, PA_PROP_DEVICE_DESCRIPTION));
+ } else if (!pa_streq(entry->description, pa_proplist_gets(sink->proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ /* Warning: If two modules fight over the description, this could cause an infinite loop.
+ by changing the description here, we retrigger this subscription callback. The only thing stopping us from
+ looping is the fact that the string comparison will fail on the second iteration. If another module tries to manage
+ the description, this will fail... */
+ pa_sink_set_description(sink, entry->description);
+ }
+
+ pa_xfree(entry->icon);
+ entry->icon = pa_xstrdup(pa_proplist_gets(sink->proplist, PA_PROP_DEVICE_ICON_NAME));
+
+ } else if ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SOURCE) {
+ pa_source *source;
+
+ pa_assert((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SOURCE);
+
+ if (!(source = pa_idxset_get_by_index(c->sources, idx)))
+ return;
+
+ if (source->monitor_of)
+ return;
+
+ name = pa_sprintf_malloc("source:%s", source->name);
+
+ old = load_or_initialize_entry(u, entry, name, "source:");
+
+ if (!entry->user_set_description) {
+ pa_xfree(entry->description);
+ entry->description = pa_xstrdup(pa_proplist_gets(source->proplist, PA_PROP_DEVICE_DESCRIPTION));
+ } else if (!pa_streq(entry->description, pa_proplist_gets(source->proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ /* Warning: If two modules fight over the description, this could cause an infinite loop.
+ by changing the description here, we retrigger this subscription callback. The only thing stopping us from
+ looping is the fact that the string comparison will fail on the second iteration. If another module tries to manage
+ the description, this will fail... */
+ pa_source_set_description(source, entry->description);
+ }
+
+ pa_xfree(entry->icon);
+ entry->icon = pa_xstrdup(pa_proplist_gets(source->proplist, PA_PROP_DEVICE_ICON_NAME));
+ }
+
+ pa_assert(name);
+
+ if (old) {
+
+ if (entries_equal(old, entry)) {
+ entry_free(old);
+ entry_free(entry);
+ pa_xfree(name);
+
+ return;
+ }
+
+ entry_free(old);
+ }
+
+ pa_log_info("Storing device %s.", name);
+
+ if (entry_write(u, name, entry))
+ trigger_save(u);
+ else
+ pa_log_warn("Could not save device");;
+
+ entry_free(entry);
+ pa_xfree(name);
+}
+
+static pa_hook_result_t sink_new_hook_callback(pa_core *c, pa_sink_new_data *new_data, struct userdata *u) {
+ char *name;
+ struct entry *e;
+
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+
+ name = pa_sprintf_malloc("sink:%s", new_data->name);
+
+ if ((e = entry_read(u, name))) {
+ if (e->user_set_description && strncmp(e->description, pa_proplist_gets(new_data->proplist, PA_PROP_DEVICE_DESCRIPTION), sizeof(e->description)) != 0) {
+ pa_log_info("Restoring description for sink %s.", new_data->name);
+ pa_proplist_sets(new_data->proplist, PA_PROP_DEVICE_DESCRIPTION, e->description);
+ }
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_new_hook_callback(pa_core *c, pa_source_new_data *new_data, struct userdata *u) {
+ char *name;
+ struct entry *e;
+
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+
+ name = pa_sprintf_malloc("source:%s", new_data->name);
+
+ if ((e = entry_read(u, name))) {
+ if (e->user_set_description && strncmp(e->description, pa_proplist_gets(new_data->proplist, PA_PROP_DEVICE_DESCRIPTION), sizeof(e->description)) != 0) {
+ /* NB, We cannot detect if we are a monitor here... this could mess things up a bit... */
+ pa_log_info("Restoring description for source %s.", new_data->name);
+ pa_proplist_sets(new_data->proplist, PA_PROP_DEVICE_DESCRIPTION, e->description);
+ }
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_input_new_hook_callback(pa_core *c, pa_sink_input_new_data *new_data, struct userdata *u) {
+ const char *role;
+ uint32_t role_index;
+
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+
+ if (!u->do_routing)
+ return PA_HOOK_OK;
+
+ if (new_data->sink)
+ pa_log_debug("Not restoring device for stream because already set.");
+ else {
+ if (!(role = pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_ROLE)))
+ role_index = get_role_index("none");
+ else
+ role_index = get_role_index(role);
+
+ if (PA_INVALID_INDEX != role_index) {
+ uint32_t device_index;
+
+ device_index = u->preferred_sinks[role_index];
+ if (PA_INVALID_INDEX != device_index) {
+ pa_sink *sink;
+
+ if ((sink = pa_idxset_get_by_index(u->core->sinks, device_index))) {
+ if (!pa_sink_input_new_data_set_sink(new_data, sink, FALSE))
+ pa_log_debug("Not restoring device for stream because no supported format was found");
+ }
+ }
+ }
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_output_new_hook_callback(pa_core *c, pa_source_output_new_data *new_data, struct userdata *u) {
+ const char *role;
+ uint32_t role_index;
+
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+
+ if (!u->do_routing)
+ return PA_HOOK_OK;
+
+ if (new_data->direct_on_input)
+ return PA_HOOK_OK;
+
+ if (new_data->source)
+ pa_log_debug("Not restoring device for stream because already set.");
+ else {
+ if (!(role = pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_ROLE)))
+ role_index = get_role_index("none");
+ else
+ role_index = get_role_index(role);
+
+ if (PA_INVALID_INDEX != role_index) {
+ uint32_t device_index;
+
+ device_index = u->preferred_sources[role_index];
+ if (PA_INVALID_INDEX != device_index) {
+ pa_source *source;
+
+ if ((source = pa_idxset_get_by_index(u->core->sources, device_index)))
+ if (!pa_source_output_new_data_set_source(new_data, source, FALSE))
+ pa_log_debug("Not restoring device for stream because no supported format was found");
+ }
+ }
+ }
+
+ return PA_HOOK_OK;
+}
+
+
+static pa_hook_result_t sink_put_hook_callback(pa_core *c, PA_GCC_UNUSED pa_sink *sink, struct userdata *u) {
+ pa_assert(c);
+ pa_assert(u);
+ pa_assert(u->core == c);
+ pa_assert(u->on_hotplug);
+
+ notify_subscribers(u);
+
+ return route_sink_inputs(u, NULL);
+}
+
+static pa_hook_result_t source_put_hook_callback(pa_core *c, PA_GCC_UNUSED pa_source *source, struct userdata *u) {
+ pa_assert(c);
+ pa_assert(u);
+ pa_assert(u->core == c);
+ pa_assert(u->on_hotplug);
+
+ notify_subscribers(u);
+
+ return route_source_outputs(u, NULL);
+}
+
+static pa_hook_result_t sink_unlink_hook_callback(pa_core *c, pa_sink *sink, struct userdata *u) {
+ pa_assert(c);
+ pa_assert(sink);
+ pa_assert(u);
+ pa_assert(u->core == c);
+ pa_assert(u->on_rescue);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ notify_subscribers(u);
+
+ return route_sink_inputs(u, sink);
+}
+
+static pa_hook_result_t source_unlink_hook_callback(pa_core *c, pa_source *source, struct userdata *u) {
+ pa_assert(c);
+ pa_assert(source);
+ pa_assert(u);
+ pa_assert(u->core == c);
+ pa_assert(u->on_rescue);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ notify_subscribers(u);
+
+ return route_source_outputs(u, source);
+}
+
+
+static void apply_entry(struct userdata *u, const char *name, struct entry *e) {
+ uint32_t idx;
+ char *n;
+
+ pa_assert(u);
+ pa_assert(name);
+ pa_assert(e);
+
+ if (!e->user_set_description)
+ return;
+
+ if ((n = get_name(name, "sink:"))) {
+ pa_sink *s;
+ PA_IDXSET_FOREACH(s, u->core->sinks, idx) {
+ if (!pa_streq(s->name, n)) {
+ continue;
+ }
+
+ pa_log_info("Setting description for sink %s to '%s'", s->name, e->description);
+ pa_sink_set_description(s, e->description);
+ }
+ pa_xfree(n);
+ }
+ else if ((n = get_name(name, "source:"))) {
+ pa_source *s;
+ PA_IDXSET_FOREACH(s, u->core->sources, idx) {
+ if (!pa_streq(s->name, n)) {
+ continue;
+ }
+
+ if (s->monitor_of) {
+ pa_log_warn("Cowardly refusing to set the description for monitor source %s.", s->name);
+ continue;
+ }
+
+ pa_log_info("Setting description for source %s to '%s'", s->name, e->description);
+ pa_source_set_description(s, e->description);
+ }
+ pa_xfree(n);
+ }
+}
+
+
+#define EXT_VERSION 1
+
+static int extension_cb(pa_native_protocol *p, pa_module *m, pa_native_connection *c, uint32_t tag, pa_tagstruct *t) {
+ struct userdata *u;
+ uint32_t command;
+ pa_tagstruct *reply = NULL;
+
+ pa_assert(p);
+ pa_assert(m);
+ pa_assert(c);
+ pa_assert(t);
+
+ u = m->userdata;
+
+ if (pa_tagstruct_getu32(t, &command) < 0)
+ goto fail;
+
+ reply = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu32(reply, PA_COMMAND_REPLY);
+ pa_tagstruct_putu32(reply, tag);
+
+ switch (command) {
+ case SUBCOMMAND_TEST: {
+ if (!pa_tagstruct_eof(t))
+ goto fail;
+
+ pa_tagstruct_putu32(reply, EXT_VERSION);
+ break;
+ }
+
+ case SUBCOMMAND_READ: {
+ pa_datum key;
+ pa_bool_t done;
+
+ if (!pa_tagstruct_eof(t))
+ goto fail;
+
+ done = !pa_database_first(u->database, &key, NULL);
+
+ while (!done) {
+ pa_datum next_key;
+ struct entry *e;
+ char *name;
+
+ done = !pa_database_next(u->database, &key, &next_key, NULL);
+
+ name = pa_xstrndup(key.data, key.size);
+ pa_datum_free(&key);
+
+ if ((e = entry_read(u, name))) {
+ uint32_t idx;
+ char *device_name;
+ uint32_t found_index = PA_INVALID_INDEX;
+
+ if ((device_name = get_name(name, "sink:"))) {
+ pa_sink* s;
+ PA_IDXSET_FOREACH(s, u->core->sinks, idx) {
+ if (strcmp(s->name, device_name) == 0) {
+ found_index = s->index;
+ break;
+ }
+ }
+ pa_xfree(device_name);
+ } else if ((device_name = get_name(name, "source:"))) {
+ pa_source* s;
+ PA_IDXSET_FOREACH(s, u->core->sources, idx) {
+ if (strcmp(s->name, device_name) == 0) {
+ found_index = s->index;
+ break;
+ }
+ }
+ pa_xfree(device_name);
+ }
+
+ pa_tagstruct_puts(reply, name);
+ pa_tagstruct_puts(reply, e->description);
+ pa_tagstruct_puts(reply, e->icon);
+ pa_tagstruct_putu32(reply, found_index);
+ pa_tagstruct_putu32(reply, NUM_ROLES);
+
+ for (uint32_t i = ROLE_NONE; i < NUM_ROLES; ++i) {
+ pa_tagstruct_puts(reply, role_names[i]);
+ pa_tagstruct_putu32(reply, e->priority[i]);
+ }
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+
+ key = next_key;
+ }
+
+ break;
+ }
+
+ case SUBCOMMAND_RENAME: {
+
+ struct entry *e;
+ const char *device, *description;
+
+ if (pa_tagstruct_gets(t, &device) < 0 ||
+ pa_tagstruct_gets(t, &description) < 0)
+ goto fail;
+
+ if (!device || !*device || !description || !*description)
+ goto fail;
+
+ if ((e = entry_read(u, device))) {
+ pa_xfree(e->description);
+ e->description = pa_xstrdup(description);
+ e->user_set_description = TRUE;
+
+ if (entry_write(u, (char *)device, e)) {
+ apply_entry(u, device, e);
+
+ trigger_save(u);
+ }
+ else
+ pa_log_warn("Could not save device");
+
+ entry_free(e);
+ }
+ else
+ pa_log_warn("Could not rename device %s, no entry in database", device);
+
+ break;
+ }
+
+ case SUBCOMMAND_DELETE:
+
+ while (!pa_tagstruct_eof(t)) {
+ const char *name;
+ pa_datum key;
+
+ if (pa_tagstruct_gets(t, &name) < 0)
+ goto fail;
+
+ key.data = (char*) name;
+ key.size = strlen(name);
+
+ /** @todo: Reindex the priorities */
+ pa_database_unset(u->database, &key);
+ }
+
+ trigger_save(u);
+
+ break;
+
+ case SUBCOMMAND_ROLE_DEVICE_PRIORITY_ROUTING: {
+
+ pa_bool_t enable;
+
+ if (pa_tagstruct_get_boolean(t, &enable) < 0)
+ goto fail;
+
+ if ((u->do_routing = enable)) {
+ /* Update our caches */
+ update_highest_priority_device_indexes(u, "sink:", NULL);
+ update_highest_priority_device_indexes(u, "source:", NULL);
+ }
+
+ break;
+ }
+
+ case SUBCOMMAND_REORDER: {
+
+ const char *role;
+ struct entry *e;
+ uint32_t role_index, n_devices;
+ pa_datum key;
+ pa_bool_t done, sink_mode = TRUE;
+ struct device_t { uint32_t prio; char *device; };
+ struct device_t *device;
+ struct device_t **devices;
+ uint32_t i, idx, offset;
+ pa_hashmap *h;
+ /*void *state;*/
+ pa_bool_t first;
+
+ if (pa_tagstruct_gets(t, &role) < 0 ||
+ pa_tagstruct_getu32(t, &n_devices) < 0 ||
+ n_devices < 1)
+ goto fail;
+
+ if (PA_INVALID_INDEX == (role_index = get_role_index(role)))
+ goto fail;
+
+ /* Cycle through the devices given and make sure they exist */
+ h = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ first = TRUE;
+ idx = 0;
+ for (i = 0; i < n_devices; ++i) {
+ const char *s;
+ if (pa_tagstruct_gets(t, &s) < 0) {
+ while ((device = pa_hashmap_steal_first(h))) {
+ pa_xfree(device->device);
+ pa_xfree(device);
+ }
+
+ pa_hashmap_free(h, NULL, NULL);
+ pa_log_error("Protocol error on reorder");
+ goto fail;
+ }
+
+ /* Ensure this is a valid entry */
+ if (!(e = entry_read(u, s))) {
+ while ((device = pa_hashmap_steal_first(h))) {
+ pa_xfree(device->device);
+ pa_xfree(device);
+ }
+
+ pa_hashmap_free(h, NULL, NULL);
+ pa_log_error("Client specified an unknown device in it's reorder list.");
+ goto fail;
+ }
+ entry_free(e);
+
+ if (first) {
+ first = FALSE;
+ sink_mode = (0 == strncmp("sink:", s, 5));
+ } else if ((sink_mode && 0 != strncmp("sink:", s, 5)) || (!sink_mode && 0 != strncmp("source:", s, 7))) {
+ while ((device = pa_hashmap_steal_first(h))) {
+ pa_xfree(device->device);
+ pa_xfree(device);
+ }
+
+ pa_hashmap_free(h, NULL, NULL);
+ pa_log_error("Attempted to reorder mixed devices (sinks and sources)");
+ goto fail;
+ }
+
+ /* Add the device to our hashmap. If it's alredy in it, free it now and carry on */
+ device = pa_xnew(struct device_t, 1);
+ device->device = pa_xstrdup(s);
+ if (pa_hashmap_put(h, device->device, device) == 0) {
+ device->prio = idx;
+ idx++;
+ } else {
+ pa_xfree(device->device);
+ pa_xfree(device);
+ }
+ }
+
+ /*pa_log_debug("Hashmap contents (received from client)");
+ PA_HASHMAP_FOREACH(device, h, state) {
+ pa_log_debug(" - %s (%d)", device->device, device->prio);
+ }*/
+
+ /* Now cycle through our list and add all the devices.
+ This has the effect of addign in any in our DB,
+ not specified in the device list (and thus will be
+ tacked on at the end) */
+ offset = idx;
+ done = !pa_database_first(u->database, &key, NULL);
+
+ while (!done && idx < 256) {
+ pa_datum next_key;
+
+ done = !pa_database_next(u->database, &key, &next_key, NULL);
+
+ device = pa_xnew(struct device_t, 1);
+ device->device = pa_xstrndup(key.data, key.size);
+ if ((sink_mode && 0 == strncmp("sink:", device->device, 5))
+ || (!sink_mode && 0 == strncmp("source:", device->device, 7))) {
+
+ /* Add the device to our hashmap. If it's alredy in it, free it now and carry on */
+ if (pa_hashmap_put(h, device->device, device) == 0
+ && (e = entry_read(u, device->device))) {
+ /* We add offset on to the existing priorirty so that when we order, the
+ existing entries are always lower priority than the new ones. */
+ device->prio = (offset + e->priority[role_index]);
+ pa_xfree(e);
+ }
+ else {
+ pa_xfree(device->device);
+ pa_xfree(device);
+ }
+ } else {
+ pa_xfree(device->device);
+ pa_xfree(device);
+ }
+
+ pa_datum_free(&key);
+
+ key = next_key;
+ }
+
+ /*pa_log_debug("Hashmap contents (combined with database)");
+ PA_HASHMAP_FOREACH(device, h, state) {
+ pa_log_debug(" - %s (%d)", device->device, device->prio);
+ }*/
+
+ /* Now we put all the entries in a simple list for sorting it. */
+ n_devices = pa_hashmap_size(h);
+ devices = pa_xnew(struct device_t *, n_devices);
+ idx = 0;
+ while ((device = pa_hashmap_steal_first(h))) {
+ devices[idx++] = device;
+ }
+ pa_hashmap_free(h, NULL, NULL);
+
+ /* Simple bubble sort */
+ for (i = 0; i < n_devices; ++i) {
+ for (uint32_t j = i; j < n_devices; ++j) {
+ if (devices[i]->prio > devices[j]->prio) {
+ struct device_t *tmp;
+ tmp = devices[i];
+ devices[i] = devices[j];
+ devices[j] = tmp;
+ }
+ }
+ }
+
+ /*pa_log_debug("Sorted device list");
+ for (i = 0; i < n_devices; ++i) {
+ pa_log_debug(" - %s (%d)", devices[i]->device, devices[i]->prio);
+ }*/
+
+ /* Go through in order and write the new entry and cleanup our own list */
+ idx = 1;
+ first = TRUE;
+ for (i = 0; i < n_devices; ++i) {
+ if ((e = entry_read(u, devices[i]->device))) {
+ if (e->priority[role_index] == idx)
+ idx++;
+ else {
+ e->priority[role_index] = idx;
+
+ if (entry_write(u, (char *) devices[i]->device, e)) {
+ first = FALSE;
+ idx++;
+ }
+ }
+
+ pa_xfree(e);
+ }
+ pa_xfree(devices[i]->device);
+ pa_xfree(devices[i]);
+ }
+
+ if (!first) {
+ trigger_save(u);
+
+ if (sink_mode)
+ route_sink_inputs(u, NULL);
+ else
+ route_source_outputs(u, NULL);
+ }
+
+ break;
+ }
+
+ case SUBCOMMAND_SUBSCRIBE: {
+
+ pa_bool_t enabled;
+
+ if (pa_tagstruct_get_boolean(t, &enabled) < 0 ||
+ !pa_tagstruct_eof(t))
+ goto fail;
+
+ if (enabled)
+ pa_idxset_put(u->subscribed, c, NULL);
+ else
+ pa_idxset_remove_by_data(u->subscribed, c, NULL);
+
+ break;
+ }
+
+ default:
+ goto fail;
+ }
+
+ pa_pstream_send_tagstruct(pa_native_connection_get_pstream(c), reply);
+ return 0;
+
+ fail:
+
+ if (reply)
+ pa_tagstruct_free(reply);
+
+ return -1;
+}
+
+static pa_hook_result_t connection_unlink_hook_cb(pa_native_protocol *p, pa_native_connection *c, struct userdata *u) {
+ pa_assert(p);
+ pa_assert(c);
+ pa_assert(u);
+
+ pa_idxset_remove_by_data(u->subscribed, c, NULL);
+ return PA_HOOK_OK;
+}
+
+struct prioritised_indexes {
+ uint32_t index;
+ int32_t priority;
+};
+
+int pa__init(pa_module*m) {
+ pa_modargs *ma = NULL;
+ struct userdata *u;
+ char *fname;
+ pa_sink *sink;
+ pa_source *source;
+ uint32_t idx;
+ pa_bool_t do_routing = FALSE, on_hotplug = TRUE, on_rescue = TRUE;
+ uint32_t total_devices;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "do_routing", &do_routing) < 0 ||
+ pa_modargs_get_value_boolean(ma, "on_hotplug", &on_hotplug) < 0 ||
+ pa_modargs_get_value_boolean(ma, "on_rescue", &on_rescue) < 0) {
+ pa_log("on_hotplug= and on_rescue= expect boolean arguments");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->module = m;
+ u->do_routing = do_routing;
+ u->on_hotplug = on_hotplug;
+ u->on_rescue = on_rescue;
+ u->subscribed = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+
+ u->protocol = pa_native_protocol_get(m->core);
+ pa_native_protocol_install_ext(u->protocol, m, extension_cb);
+
+ u->connection_unlink_hook_slot = pa_hook_connect(&pa_native_protocol_hooks(u->protocol)[PA_NATIVE_HOOK_CONNECTION_UNLINK], PA_HOOK_NORMAL, (pa_hook_cb_t) connection_unlink_hook_cb, u);
+
+ u->subscription = pa_subscription_new(m->core, PA_SUBSCRIPTION_MASK_SINK|PA_SUBSCRIPTION_MASK_SOURCE|PA_SUBSCRIPTION_MASK_SINK_INPUT|PA_SUBSCRIPTION_MASK_SOURCE_OUTPUT, subscribe_callback, u);
+
+ /* Used to handle device description management */
+ u->sink_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_NEW], PA_HOOK_EARLY, (pa_hook_cb_t) sink_new_hook_callback, u);
+ u->source_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_NEW], PA_HOOK_EARLY, (pa_hook_cb_t) source_new_hook_callback, u);
+
+ /* The following slots are used to deal with routing */
+ /* A little bit later than module-stream-restore, but before module-intended-roles */
+ u->sink_input_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_NEW], PA_HOOK_EARLY+5, (pa_hook_cb_t) sink_input_new_hook_callback, u);
+ u->source_output_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_NEW], PA_HOOK_EARLY+5, (pa_hook_cb_t) source_output_new_hook_callback, u);
+
+ if (on_hotplug) {
+ /* A little bit later than module-stream-restore, but before module-intended-roles */
+ u->sink_put_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_LATE+5, (pa_hook_cb_t) sink_put_hook_callback, u);
+ u->source_put_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_PUT], PA_HOOK_LATE+5, (pa_hook_cb_t) source_put_hook_callback, u);
+ }
+
+ if (on_rescue) {
+ /* A little bit later than module-stream-restore, a little bit earlier than module-intended-roles, module-rescue-streams, ... */
+ u->sink_unlink_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_LATE+5, (pa_hook_cb_t) sink_unlink_hook_callback, u);
+ u->source_unlink_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_LATE+5, (pa_hook_cb_t) source_unlink_hook_callback, u);
+ }
+
+ if (!(fname = pa_state_path("device-manager", TRUE)))
+ goto fail;
+
+ if (!(u->database = pa_database_open(fname, TRUE))) {
+ pa_log("Failed to open volume database '%s': %s", fname, pa_cstrerror(errno));
+ pa_xfree(fname);
+ goto fail;
+ }
+
+ pa_log_info("Successfully opened database file '%s'.", fname);
+ pa_xfree(fname);
+
+ /* Attempt to inject the devices into the list in priority order */
+ total_devices = PA_MAX(pa_idxset_size(m->core->sinks), pa_idxset_size(m->core->sources));
+ if (total_devices > 0 && total_devices < 128) {
+ uint32_t i;
+ struct prioritised_indexes p_i[128];
+
+ /* We cycle over all the available sinks so that they are added to our database if they are not in it yet */
+ i = 0;
+ PA_IDXSET_FOREACH(sink, m->core->sinks, idx) {
+ pa_log_debug("Found sink index %u", sink->index);
+ p_i[i ].index = sink->index;
+ p_i[i++].priority = sink->priority;
+ }
+ /* Bubble sort it (only really useful for first time creation) */
+ if (i > 1)
+ for (uint32_t j = 0; j < i; ++j)
+ for (uint32_t k = 0; k < i; ++k)
+ if (p_i[j].priority > p_i[k].priority) {
+ struct prioritised_indexes tmp_pi = p_i[k];
+ p_i[k] = p_i[j];
+ p_i[j] = tmp_pi;
+ }
+ /* Register it */
+ for (uint32_t j = 0; j < i; ++j)
+ subscribe_callback(m->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_NEW, p_i[j].index, u);
+
+
+ /* We cycle over all the available sources so that they are added to our database if they are not in it yet */
+ i = 0;
+ PA_IDXSET_FOREACH(source, m->core->sources, idx) {
+ p_i[i ].index = source->index;
+ p_i[i++].priority = source->priority;
+ }
+ /* Bubble sort it (only really useful for first time creation) */
+ if (i > 1)
+ for (uint32_t j = 0; j < i; ++j)
+ for (uint32_t k = 0; k < i; ++k)
+ if (p_i[j].priority > p_i[k].priority) {
+ struct prioritised_indexes tmp_pi = p_i[k];
+ p_i[k] = p_i[j];
+ p_i[j] = tmp_pi;
+ }
+ /* Register it */
+ for (uint32_t j = 0; j < i; ++j)
+ subscribe_callback(m->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_NEW, p_i[j].index, u);
+ }
+ else if (total_devices > 0) {
+ /* This user has a *lot* of devices... */
+ PA_IDXSET_FOREACH(sink, m->core->sinks, idx)
+ subscribe_callback(m->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_NEW, sink->index, u);
+
+ PA_IDXSET_FOREACH(source, m->core->sources, idx)
+ subscribe_callback(m->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_NEW, source->index, u);
+ }
+
+ /* Perform the routing (if it's enabled) which will update our priority list cache too */
+ for (uint32_t i = 0; i < NUM_ROLES; ++i) {
+ u->preferred_sinks[i] = u->preferred_sources[i] = PA_INVALID_INDEX;
+ }
+
+ route_sink_inputs(u, NULL);
+ route_source_outputs(u, NULL);
+
+#ifdef DUMP_DATABASE
+ dump_database(u);
+#endif
+
+ pa_modargs_free(ma);
+ return 0;
+
+fail:
+ pa__done(m);
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ return -1;
+}
+
+void pa__done(pa_module*m) {
+ struct userdata* u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->subscription)
+ pa_subscription_free(u->subscription);
+
+ if (u->sink_new_hook_slot)
+ pa_hook_slot_free(u->sink_new_hook_slot);
+ if (u->source_new_hook_slot)
+ pa_hook_slot_free(u->source_new_hook_slot);
+
+ if (u->sink_input_new_hook_slot)
+ pa_hook_slot_free(u->sink_input_new_hook_slot);
+ if (u->source_output_new_hook_slot)
+ pa_hook_slot_free(u->source_output_new_hook_slot);
+
+ if (u->sink_put_hook_slot)
+ pa_hook_slot_free(u->sink_put_hook_slot);
+ if (u->source_put_hook_slot)
+ pa_hook_slot_free(u->source_put_hook_slot);
+
+ if (u->sink_unlink_hook_slot)
+ pa_hook_slot_free(u->sink_unlink_hook_slot);
+ if (u->source_unlink_hook_slot)
+ pa_hook_slot_free(u->source_unlink_hook_slot);
+
+ if (u->connection_unlink_hook_slot)
+ pa_hook_slot_free(u->connection_unlink_hook_slot);
+
+ if (u->save_time_event)
+ u->core->mainloop->time_free(u->save_time_event);
+
+ if (u->database)
+ pa_database_close(u->database);
+
+ if (u->protocol) {
+ pa_native_protocol_remove_ext(u->protocol, m);
+ pa_native_protocol_unref(u->protocol);
+ }
+
+ if (u->subscribed)
+ pa_idxset_free(u->subscribed, NULL, NULL);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-device-restore.c b/src/modules/module-device-restore.c
index ae21acd5..7d94ffa4 100644
--- a/src/modules/module-device-restore.c
+++ b/src/modules/module-device-restore.c
@@ -2,6 +2,7 @@
This file is part of PulseAudio.
Copyright 2006-2008 Lennart Poettering
+ Copyright 2011 Colin Guthrie
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
@@ -29,12 +30,14 @@
#include <sys/types.h>
#include <stdio.h>
#include <stdlib.h>
-#include <ctype.h>
+#include <pulse/gccmacro.h>
#include <pulse/xmalloc.h>
#include <pulse/volume.h>
#include <pulse/timeval.h>
-#include <pulse/util.h>
+#include <pulse/rtclock.h>
+#include <pulse/format.h>
+#include <pulse/internal.h>
#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
@@ -42,10 +45,14 @@
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
#include <pulsecore/core-subscribe.h>
-#include <pulsecore/sink-input.h>
-#include <pulsecore/source-output.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/source.h>
#include <pulsecore/namereg.h>
+#include <pulsecore/protocol-native.h>
+#include <pulsecore/pstream.h>
+#include <pulsecore/pstream-util.h>
#include <pulsecore/database.h>
+#include <pulsecore/tagstruct.h>
#include "module-device-restore-symdef.h"
@@ -54,14 +61,16 @@ PA_MODULE_DESCRIPTION("Automatically restore the volume/mute state of devices");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
PA_MODULE_USAGE(
+ "restore_port=<Save/restore port?> "
"restore_volume=<Save/restore volumes?> "
"restore_muted=<Save/restore muted states?>");
-#define SAVE_INTERVAL 10
+#define SAVE_INTERVAL (10 * PA_USEC_PER_SEC)
static const char* const valid_modargs[] = {
"restore_volume",
"restore_muted",
+ "restore_port",
NULL
};
@@ -70,30 +79,50 @@ struct userdata {
pa_module *module;
pa_subscription *subscription;
pa_hook_slot
+ *sink_new_hook_slot,
*sink_fixate_hook_slot,
- *source_fixate_hook_slot;
+ *source_new_hook_slot,
+ *source_fixate_hook_slot,
+ *connection_unlink_hook_slot;
pa_time_event *save_time_event;
pa_database *database;
+ pa_native_protocol *protocol;
+ pa_idxset *subscribed;
+
pa_bool_t restore_volume:1;
pa_bool_t restore_muted:1;
+ pa_bool_t restore_port:1;
+};
+
+/* Protocol extention commands */
+enum {
+ SUBCOMMAND_TEST,
+ SUBCOMMAND_SUBSCRIBE,
+ SUBCOMMAND_EVENT,
+ SUBCOMMAND_READ_SINK_FORMATS_ALL,
+ SUBCOMMAND_READ_SINK_FORMATS,
+ SUBCOMMAND_SAVE_SINK_FORMATS
};
+
#define ENTRY_VERSION 1
struct entry {
uint8_t version;
- pa_bool_t muted:1;
+ pa_bool_t muted_valid, volume_valid, port_valid;
+ pa_bool_t muted;
pa_channel_map channel_map;
pa_cvolume volume;
-} PA_GCC_PACKED;
+ char *port;
+ pa_idxset *formats;
+};
-static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *tv, void *userdata) {
+static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *t, void *userdata) {
struct userdata *u = userdata;
pa_assert(a);
pa_assert(e);
- pa_assert(tv);
pa_assert(u);
pa_assert(e == u->save_time_event);
@@ -104,11 +133,140 @@ static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct
pa_log_info("Synced.");
}
-static struct entry* read_entry(struct userdata *u, const char *name) {
+static void trigger_save(struct userdata *u) {
+ if (u->save_time_event)
+ return;
+
+ u->save_time_event = pa_core_rttime_new(u->core, pa_rtclock_now() + SAVE_INTERVAL, save_time_callback, u);
+}
+
+static struct entry* entry_new(pa_bool_t add_pcm_format) {
+ struct entry *r = pa_xnew0(struct entry, 1);
+ r->version = ENTRY_VERSION;
+ r->formats = pa_idxset_new(NULL, NULL);
+ if (add_pcm_format) {
+ pa_format_info *f = pa_format_info_new();
+ f->encoding = PA_ENCODING_PCM;
+ pa_idxset_put(r->formats, f, NULL);
+ }
+ return r;
+}
+
+static void entry_free(struct entry* e) {
+ pa_assert(e);
+
+ pa_idxset_free(e->formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ pa_xfree(e->port);
+ pa_xfree(e);
+}
+
+static pa_bool_t entry_write(struct userdata *u, const char *name, const struct entry *e) {
+ pa_tagstruct *t;
pa_datum key, data;
+ pa_bool_t r;
+ uint32_t i;
+ pa_format_info *f;
+ uint8_t n_formats;
+
+ pa_assert(u);
+ pa_assert(name);
+ pa_assert(e);
+
+ n_formats = pa_idxset_size(e->formats);
+ pa_assert(n_formats > 0);
+
+ t = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu8(t, e->version);
+ pa_tagstruct_put_boolean(t, e->volume_valid);
+ pa_tagstruct_put_channel_map(t, &e->channel_map);
+ pa_tagstruct_put_cvolume(t, &e->volume);
+ pa_tagstruct_put_boolean(t, e->muted_valid);
+ pa_tagstruct_put_boolean(t, e->muted);
+ pa_tagstruct_put_boolean(t, e->port_valid);
+ pa_tagstruct_puts(t, e->port);
+ pa_tagstruct_putu8(t, n_formats);
+
+ PA_IDXSET_FOREACH(f, e->formats, i) {
+ pa_tagstruct_put_format_info(t, f);
+ }
+
+ key.data = (char *) name;
+ key.size = strlen(name);
+
+ data.data = (void*)pa_tagstruct_data(t, &data.size);
+
+ r = (pa_database_set(u->database, &key, &data, TRUE) == 0);
+
+ pa_tagstruct_free(t);
+
+ return r;
+}
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+
+#define LEGACY_ENTRY_VERSION 2
+static struct entry* legacy_entry_read(struct userdata *u, pa_datum *data) {
+ struct legacy_entry {
+ uint8_t version;
+ pa_bool_t muted_valid:1, volume_valid:1, port_valid:1;
+ pa_bool_t muted:1;
+ pa_channel_map channel_map;
+ pa_cvolume volume;
+ char port[PA_NAME_MAX];
+ } PA_GCC_PACKED;
+ struct legacy_entry *le;
struct entry *e;
pa_assert(u);
+ pa_assert(data);
+
+ if (data->size != sizeof(struct legacy_entry)) {
+ pa_log_debug("Size does not match.");
+ return NULL;
+ }
+
+ le = (struct legacy_entry*)data->data;
+
+ if (le->version != LEGACY_ENTRY_VERSION) {
+ pa_log_debug("Version mismatch.");
+ return NULL;
+ }
+
+ if (!memchr(le->port, 0, sizeof(le->port))) {
+ pa_log_warn("Port has missing NUL byte.");
+ return NULL;
+ }
+
+ if (le->volume_valid && !pa_channel_map_valid(&le->channel_map)) {
+ pa_log_warn("Invalid channel map.");
+ return NULL;
+ }
+
+ if (le->volume_valid && (!pa_cvolume_valid(&le->volume) || !pa_cvolume_compatible_with_channel_map(&le->volume, &le->channel_map))) {
+ pa_log_warn("Volume and channel map don't match.");
+ return NULL;
+ }
+
+ e = entry_new(TRUE);
+ e->muted_valid = le->muted_valid;
+ e->volume_valid = le->volume_valid;
+ e->port_valid = le->port_valid;
+ e->muted = le->muted;
+ e->channel_map = le->channel_map;
+ e->volume = le->volume;
+ e->port = pa_xstrdup(le->port);
+ return e;
+}
+#endif
+
+static struct entry* entry_read(struct userdata *u, const char *name) {
+ pa_datum key, data;
+ struct entry *e = NULL;
+ pa_tagstruct *t = NULL;
+ const char* port;
+ uint8_t i, n_formats;
+
+ pa_assert(u);
pa_assert(name);
key.data = (char*) name;
@@ -119,57 +277,127 @@ static struct entry* read_entry(struct userdata *u, const char *name) {
if (!pa_database_get(u->database, &key, &data))
goto fail;
- if (data.size != sizeof(struct entry)) {
- pa_log_debug("Database contains entry for device %s of wrong size %lu != %lu. Probably due to upgrade, ignoring.", name, (unsigned long) data.size, (unsigned long) sizeof(struct entry));
+ t = pa_tagstruct_new(data.data, data.size);
+ e = entry_new(FALSE);
+
+ if (pa_tagstruct_getu8(t, &e->version) < 0 ||
+ e->version > ENTRY_VERSION ||
+ pa_tagstruct_get_boolean(t, &e->volume_valid) < 0 ||
+ pa_tagstruct_get_channel_map(t, &e->channel_map) < 0 ||
+ pa_tagstruct_get_cvolume(t, &e->volume) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->muted_valid) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->muted) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->port_valid) < 0 ||
+ pa_tagstruct_gets(t, &port) < 0 ||
+ pa_tagstruct_getu8(t, &n_formats) < 0 || n_formats < 1) {
+
goto fail;
}
- e = (struct entry*) data.data;
+ e->port = pa_xstrdup(port);
- if (e->version != ENTRY_VERSION) {
- pa_log_debug("Version of database entry for device %s doesn't match our version. Probably due to upgrade, ignoring.", name);
- goto fail;
+ for (i = 0; i < n_formats; ++i) {
+ pa_format_info *f = pa_format_info_new();
+ if (pa_tagstruct_get_format_info(t, f) < 0) {
+ pa_format_info_free(f);
+ goto fail;
+ }
+ pa_idxset_put(e->formats, f, NULL);
}
- if (!(pa_cvolume_valid(&e->volume))) {
- pa_log_warn("Invalid volume stored in database for device %s", name);
+ if (!pa_tagstruct_eof(t))
goto fail;
- }
- if (!(pa_channel_map_valid(&e->channel_map))) {
+ if (e->volume_valid && !pa_channel_map_valid(&e->channel_map)) {
pa_log_warn("Invalid channel map stored in database for device %s", name);
goto fail;
}
- if (e->volume.channels != e->channel_map.channels) {
+ if (e->volume_valid && (!pa_cvolume_valid(&e->volume) || !pa_cvolume_compatible_with_channel_map(&e->volume, &e->channel_map))) {
pa_log_warn("Volume and channel map don't match in database entry for device %s", name);
goto fail;
}
+ pa_tagstruct_free(t);
+ pa_datum_free(&data);
+
return e;
fail:
+ pa_log_debug("Database contains invalid data for key: %s (probably pre-v1.0 data)", name);
+
+ if (e)
+ entry_free(e);
+ if (t)
+ pa_tagstruct_free(t);
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+ pa_log_debug("Attempting to load legacy (pre-v1.0) data for key: %s", name);
+ if ((e = legacy_entry_read(u, &data))) {
+ pa_log_debug("Success. Saving new format for key: %s", name);
+ if (entry_write(u, name, e))
+ trigger_save(u);
+ pa_datum_free(&data);
+ return e;
+ } else
+ pa_log_debug("Unable to load legacy (pre-v1.0) data for key: %s. Ignoring.", name);
+#endif
+
pa_datum_free(&data);
return NULL;
}
-static void trigger_save(struct userdata *u) {
- struct timeval tv;
+static struct entry* entry_copy(const struct entry *e) {
+ struct entry* r;
+ uint32_t idx;
+ pa_format_info *f;
- if (u->save_time_event)
- return;
+ pa_assert(e);
+ r = entry_new(FALSE);
+ r->version = e->version;
+ r->muted_valid = e->muted_valid;
+ r->volume_valid = e->volume_valid;
+ r->port_valid = e->port_valid;
+ r->muted = e->muted;
+ r->channel_map = e->channel_map;
+ r->volume = e->volume;
+ r->port = pa_xstrdup(e->port);
+
+ PA_IDXSET_FOREACH(f, e->formats, idx) {
+ pa_idxset_put(r->formats, pa_format_info_copy(f), NULL);
+ }
+ return r;
+}
+
+static pa_bool_t entries_equal(const struct entry *a, const struct entry *b) {
+ pa_cvolume t;
- pa_gettimeofday(&tv);
- tv.tv_sec += SAVE_INTERVAL;
- u->save_time_event = u->core->mainloop->time_new(u->core->mainloop, &tv, save_time_callback, u);
+ if (a->port_valid != b->port_valid ||
+ (a->port_valid && !pa_streq(a->port, b->port)))
+ return FALSE;
+
+ if (a->muted_valid != b->muted_valid ||
+ (a->muted_valid && (a->muted != b->muted)))
+ return FALSE;
+
+ t = b->volume;
+ if (a->volume_valid != b->volume_valid ||
+ (a->volume_valid && !pa_cvolume_equal(pa_cvolume_remap(&t, &b->channel_map, &a->channel_map), &a->volume)))
+ return FALSE;
+
+ if (pa_idxset_size(a->formats) != pa_idxset_size(b->formats))
+ return FALSE;
+
+ /** TODO: Compare a bit better */
+
+ return TRUE;
}
static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
struct userdata *u = userdata;
- struct entry entry, *old;
+ struct entry *entry, *old;
char *name;
- pa_datum key, data;
pa_assert(c);
pa_assert(u);
@@ -180,9 +408,6 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
t != (PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE))
return;
- pa_zero(entry);
- entry.version = ENTRY_VERSION;
-
if ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SINK) {
pa_sink *sink;
@@ -190,9 +415,28 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
return;
name = pa_sprintf_malloc("sink:%s", sink->name);
- entry.channel_map = sink->channel_map;
- entry.volume = *pa_sink_get_volume(sink, FALSE, TRUE);
- entry.muted = pa_sink_get_mute(sink, FALSE);
+
+ if ((old = entry_read(u, name)))
+ entry = entry_copy(old);
+ else
+ entry = entry_new(TRUE);
+
+ if (sink->save_volume) {
+ entry->channel_map = sink->channel_map;
+ entry->volume = *pa_sink_get_volume(sink, FALSE);
+ entry->volume_valid = TRUE;
+ }
+
+ if (sink->save_muted) {
+ entry->muted = pa_sink_get_mute(sink, FALSE);
+ entry->muted_valid = TRUE;
+ }
+
+ if (sink->save_port) {
+ pa_xfree(entry->port);
+ entry->port = pa_xstrdup(sink->active_port ? sink->active_port->name : "");
+ entry->port_valid = TRUE;
+ }
} else {
pa_source *source;
@@ -203,69 +447,153 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
return;
name = pa_sprintf_malloc("source:%s", source->name);
- entry.channel_map = source->channel_map;
- entry.volume = *pa_source_get_volume(source, FALSE);
- entry.muted = pa_source_get_mute(source, FALSE);
+
+ if ((old = entry_read(u, name)))
+ entry = entry_copy(old);
+ else
+ entry = entry_new(TRUE);
+
+ if (source->save_volume) {
+ entry->channel_map = source->channel_map;
+ entry->volume = *pa_source_get_volume(source, FALSE);
+ entry->volume_valid = TRUE;
+ }
+
+ if (source->save_muted) {
+ entry->muted = pa_source_get_mute(source, FALSE);
+ entry->muted_valid = TRUE;
+ }
+
+ if (source->save_port) {
+ pa_xfree(entry->port);
+ entry->port = pa_xstrdup(source->active_port ? source->active_port->name : "");
+ entry->port_valid = TRUE;
+ }
}
- if ((old = read_entry(u, name))) {
+ pa_assert(entry);
- if (pa_cvolume_equal(pa_cvolume_remap(&old->volume, &old->channel_map, &entry.channel_map), &entry.volume) &&
- !old->muted == !entry.muted) {
+ if (old) {
- pa_xfree(old);
+ if (entries_equal(old, entry)) {
+ entry_free(old);
+ entry_free(entry);
pa_xfree(name);
return;
}
- pa_xfree(old);
+ entry_free(old);
}
- key.data = name;
- key.size = strlen(name);
+ pa_log_info("Storing volume/mute/port for device %s.", name);
+
+ if (entry_write(u, name, entry))
+ trigger_save(u);
+
+ entry_free(entry);
+ pa_xfree(name);
+}
- data.data = &entry;
- data.size = sizeof(entry);
+static pa_hook_result_t sink_new_hook_callback(pa_core *c, pa_sink_new_data *new_data, struct userdata *u) {
+ char *name;
+ struct entry *e;
- pa_log_info("Storing volume/mute for device %s.", name);
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+ pa_assert(u->restore_port);
+
+ name = pa_sprintf_malloc("sink:%s", new_data->name);
- pa_database_set(u->database, &key, &data, TRUE);
+ if ((e = entry_read(u, name))) {
+
+ if (e->port_valid) {
+ if (!new_data->active_port) {
+ pa_log_info("Restoring port for sink %s.", name);
+ pa_sink_new_data_set_port(new_data, e->port);
+ new_data->save_port = TRUE;
+ } else
+ pa_log_debug("Not restoring port for sink %s, because already set.", name);
+ }
+
+ entry_free(e);
+ }
pa_xfree(name);
- trigger_save(u);
+ return PA_HOOK_OK;
}
static pa_hook_result_t sink_fixate_hook_callback(pa_core *c, pa_sink_new_data *new_data, struct userdata *u) {
char *name;
struct entry *e;
+ pa_assert(c);
pa_assert(new_data);
+ pa_assert(u);
+ pa_assert(u->restore_volume || u->restore_muted);
name = pa_sprintf_malloc("sink:%s", new_data->name);
- if ((e = read_entry(u, name))) {
+ if ((e = entry_read(u, name))) {
- if (u->restore_volume) {
+ if (u->restore_volume && e->volume_valid) {
if (!new_data->volume_is_set) {
+ pa_cvolume v;
+
pa_log_info("Restoring volume for sink %s.", new_data->name);
- pa_sink_new_data_set_volume(new_data, pa_cvolume_remap(&e->volume, &e->channel_map, &new_data->channel_map));
+
+ v = e->volume;
+ pa_cvolume_remap(&v, &e->channel_map, &new_data->channel_map);
+ pa_sink_new_data_set_volume(new_data, &v);
+
+ new_data->save_volume = TRUE;
} else
pa_log_debug("Not restoring volume for sink %s, because already set.", new_data->name);
-
}
- if (u->restore_muted) {
+ if (u->restore_muted && e->muted_valid) {
if (!new_data->muted_is_set) {
pa_log_info("Restoring mute state for sink %s.", new_data->name);
pa_sink_new_data_set_muted(new_data, e->muted);
+ new_data->save_muted = TRUE;
} else
pa_log_debug("Not restoring mute state for sink %s, because already set.", new_data->name);
}
- pa_xfree(e);
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_new_hook_callback(pa_core *c, pa_source_new_data *new_data, struct userdata *u) {
+ char *name;
+ struct entry *e;
+
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+ pa_assert(u->restore_port);
+
+ name = pa_sprintf_malloc("source:%s", new_data->name);
+
+ if ((e = entry_read(u, name))) {
+
+ if (e->port_valid) {
+ if (!new_data->active_port) {
+ pa_log_info("Restoring port for source %s.", name);
+ pa_source_new_data_set_port(new_data, e->port);
+ new_data->save_port = TRUE;
+ } else
+ pa_log_debug("Not restoring port for source %s, because already set.", name);
+ }
+
+ entry_free(e);
}
pa_xfree(name);
@@ -277,31 +605,42 @@ static pa_hook_result_t source_fixate_hook_callback(pa_core *c, pa_source_new_da
char *name;
struct entry *e;
+ pa_assert(c);
pa_assert(new_data);
+ pa_assert(u);
+ pa_assert(u->restore_volume || u->restore_muted);
name = pa_sprintf_malloc("source:%s", new_data->name);
- if ((e = read_entry(u, name))) {
+ if ((e = entry_read(u, name))) {
- if (u->restore_volume) {
+ if (u->restore_volume && e->volume_valid) {
if (!new_data->volume_is_set) {
+ pa_cvolume v;
+
pa_log_info("Restoring volume for source %s.", new_data->name);
- pa_source_new_data_set_volume(new_data, pa_cvolume_remap(&e->volume, &e->channel_map, &new_data->channel_map));
+
+ v = e->volume;
+ pa_cvolume_remap(&v, &e->channel_map, &new_data->channel_map);
+ pa_source_new_data_set_volume(new_data, &v);
+
+ new_data->save_volume = TRUE;
} else
pa_log_debug("Not restoring volume for source %s, because already set.", new_data->name);
}
- if (u->restore_muted) {
+ if (u->restore_muted && e->muted_valid) {
if (!new_data->muted_is_set) {
pa_log_info("Restoring mute state for source %s.", new_data->name);
pa_source_new_data_set_muted(new_data, e->muted);
+ new_data->save_muted = TRUE;
} else
pa_log_debug("Not restoring mute state for source %s, because already set.", new_data->name);
}
- pa_xfree(e);
+ entry_free(e);
}
pa_xfree(name);
@@ -309,6 +648,197 @@ static pa_hook_result_t source_fixate_hook_callback(pa_core *c, pa_source_new_da
return PA_HOOK_OK;
}
+#define EXT_VERSION 1
+
+static void read_sink_format_reply(struct userdata *u, pa_tagstruct *reply, pa_sink *sink) {
+ struct entry *e;
+ char *name;
+
+ pa_assert(u);
+ pa_assert(reply);
+ pa_assert(sink);
+
+ pa_tagstruct_putu32(reply, sink->index);
+
+ /* Read or create an entry */
+ name = pa_sprintf_malloc("sink:%s", sink->name);
+ if (!(e = entry_read(u, name))) {
+ /* Fake a reply with PCM encoding supported */
+ pa_format_info *f = pa_format_info_new();
+
+ pa_tagstruct_putu8(reply, 1);
+ f->encoding = PA_ENCODING_PCM;
+ pa_tagstruct_put_format_info(reply, f);
+
+ pa_format_info_free(f);
+ } else {
+ uint32_t idx;
+ pa_format_info *f;
+
+ /* Write all the formats from the entry to the reply */
+ pa_tagstruct_putu8(reply, pa_idxset_size(e->formats));
+ PA_IDXSET_FOREACH(f, e->formats, idx) {
+ pa_tagstruct_put_format_info(reply, f);
+ }
+ }
+ pa_xfree(name);
+}
+
+static int extension_cb(pa_native_protocol *p, pa_module *m, pa_native_connection *c, uint32_t tag, pa_tagstruct *t) {
+ struct userdata *u;
+ uint32_t command;
+ pa_tagstruct *reply = NULL;
+
+ pa_assert(p);
+ pa_assert(m);
+ pa_assert(c);
+ pa_assert(t);
+
+ u = m->userdata;
+
+ if (pa_tagstruct_getu32(t, &command) < 0)
+ goto fail;
+
+ reply = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu32(reply, PA_COMMAND_REPLY);
+ pa_tagstruct_putu32(reply, tag);
+
+ switch (command) {
+ case SUBCOMMAND_TEST: {
+ if (!pa_tagstruct_eof(t))
+ goto fail;
+
+ pa_tagstruct_putu32(reply, EXT_VERSION);
+ break;
+ }
+
+ case SUBCOMMAND_SUBSCRIBE: {
+
+ pa_bool_t enabled;
+
+ if (pa_tagstruct_get_boolean(t, &enabled) < 0 ||
+ !pa_tagstruct_eof(t))
+ goto fail;
+
+ if (enabled)
+ pa_idxset_put(u->subscribed, c, NULL);
+ else
+ pa_idxset_remove_by_data(u->subscribed, c, NULL);
+
+ break;
+ }
+
+ case SUBCOMMAND_READ_SINK_FORMATS_ALL: {
+ pa_sink *sink;
+ uint32_t idx;
+
+ if (!pa_tagstruct_eof(t))
+ goto fail;
+
+ PA_IDXSET_FOREACH(sink, u->core->sinks, idx) {
+ read_sink_format_reply(u, reply, sink);
+ }
+
+ break;
+ }
+ case SUBCOMMAND_READ_SINK_FORMATS: {
+ uint32_t sink_index;
+ pa_sink *sink;
+
+ pa_assert(reply);
+
+ /* Get the sink index and the number of formats from the tagstruct */
+ if (pa_tagstruct_getu32(t, &sink_index) < 0)
+ goto fail;
+
+ if (!pa_tagstruct_eof(t))
+ goto fail;
+
+ /* Now find our sink */
+ if (!(sink = pa_idxset_get_by_index(u->core->sinks, sink_index)))
+ goto fail;
+
+ read_sink_format_reply(u, reply, sink);
+
+ break;
+ }
+
+ case SUBCOMMAND_SAVE_SINK_FORMATS: {
+
+ struct entry *e;
+ uint32_t sink_index;
+ char *name;
+ pa_sink *sink;
+ uint8_t i, n_formats;
+
+ /* Get the sink index and the number of formats from the tagstruct */
+ if (pa_tagstruct_getu32(t, &sink_index) < 0 ||
+ pa_tagstruct_getu8(t, &n_formats) < 0 || n_formats < 1) {
+
+ goto fail;
+ }
+
+ /* Now find our sink */
+ if (!(sink = pa_idxset_get_by_index(u->core->sinks, sink_index)))
+ goto fail;
+
+ /* Read or create an entry */
+ name = pa_sprintf_malloc("sink:%s", sink->name);
+ if (!(e = entry_read(u, name)))
+ e = entry_new(FALSE);
+
+ /* Read all the formats from our tagstruct */
+ for (i = 0; i < n_formats; ++i) {
+ pa_format_info *f = pa_format_info_new();
+ if (pa_tagstruct_get_format_info(t, f) < 0) {
+ pa_format_info_free(f);
+ pa_xfree(name);
+ goto fail;
+ }
+ pa_idxset_put(e->formats, f, NULL);
+ }
+
+ if (!pa_tagstruct_eof(t)) {
+ entry_free(e);
+ pa_xfree(name);
+ goto fail;
+ }
+
+ if (entry_write(u, name, e))
+ trigger_save(u);
+ else
+ pa_log_warn("Could not save format info for sink %s", sink->name);
+
+ pa_xfree(name);
+ entry_free(e);
+
+ break;
+ }
+
+ default:
+ goto fail;
+ }
+
+ pa_pstream_send_tagstruct(pa_native_connection_get_pstream(c), reply);
+ return 0;
+
+fail:
+
+ if (reply)
+ pa_tagstruct_free(reply);
+
+ return -1;
+}
+
+static pa_hook_result_t connection_unlink_hook_cb(pa_native_protocol *p, pa_native_connection *c, struct userdata *u) {
+ pa_assert(p);
+ pa_assert(c);
+ pa_assert(u);
+
+ pa_idxset_remove_by_data(u->subscribed, c, NULL);
+ return PA_HOOK_OK;
+}
+
int pa__init(pa_module*m) {
pa_modargs *ma = NULL;
struct userdata *u;
@@ -316,7 +846,7 @@ int pa__init(pa_module*m) {
pa_sink *sink;
pa_source *source;
uint32_t idx;
- pa_bool_t restore_volume = TRUE, restore_muted = TRUE;
+ pa_bool_t restore_volume = TRUE, restore_muted = TRUE, restore_port = TRUE;
pa_assert(m);
@@ -326,24 +856,36 @@ int pa__init(pa_module*m) {
}
if (pa_modargs_get_value_boolean(ma, "restore_volume", &restore_volume) < 0 ||
- pa_modargs_get_value_boolean(ma, "restore_muted", &restore_muted) < 0) {
- pa_log("restore_volume= and restore_muted= expect boolean arguments");
+ pa_modargs_get_value_boolean(ma, "restore_muted", &restore_muted) < 0 ||
+ pa_modargs_get_value_boolean(ma, "restore_port", &restore_port) < 0) {
+ pa_log("restore_port=, restore_volume= and restore_muted= expect boolean arguments");
goto fail;
}
- if (!restore_muted && !restore_volume)
- pa_log_warn("Neither restoring volume nor restoring muted enabled!");
+ if (!restore_muted && !restore_volume && !restore_port)
+ pa_log_warn("Neither restoring volume, nor restoring muted, nor restoring port enabled!");
- m->userdata = u = pa_xnew(struct userdata, 1);
+ m->userdata = u = pa_xnew0(struct userdata, 1);
u->core = m->core;
u->module = m;
- u->save_time_event = NULL;
u->restore_volume = restore_volume;
u->restore_muted = restore_muted;
- u->database = NULL;
+ u->restore_port = restore_port;
+
+ u->subscribed = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+
+ u->protocol = pa_native_protocol_get(m->core);
+ pa_native_protocol_install_ext(u->protocol, m, extension_cb);
+
+ u->connection_unlink_hook_slot = pa_hook_connect(&pa_native_protocol_hooks(u->protocol)[PA_NATIVE_HOOK_CONNECTION_UNLINK], PA_HOOK_NORMAL, (pa_hook_cb_t) connection_unlink_hook_cb, u);
u->subscription = pa_subscription_new(m->core, PA_SUBSCRIPTION_MASK_SINK|PA_SUBSCRIPTION_MASK_SOURCE, subscribe_callback, u);
+ if (restore_port) {
+ u->sink_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_NEW], PA_HOOK_EARLY, (pa_hook_cb_t) sink_new_hook_callback, u);
+ u->source_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_NEW], PA_HOOK_EARLY, (pa_hook_cb_t) source_new_hook_callback, u);
+ }
+
if (restore_muted || restore_volume) {
u->sink_fixate_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_FIXATE], PA_HOOK_EARLY, (pa_hook_cb_t) sink_fixate_hook_callback, u);
u->source_fixate_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_FIXATE], PA_HOOK_EARLY, (pa_hook_cb_t) source_fixate_hook_callback, u);
@@ -358,7 +900,7 @@ int pa__init(pa_module*m) {
goto fail;
}
- pa_log_info("Sucessfully opened database file '%s'.", fname);
+ pa_log_info("Successfully opened database file '%s'.", fname);
pa_xfree(fname);
for (sink = pa_idxset_first(m->core->sinks, &idx); sink; sink = pa_idxset_next(m->core->sinks, &idx))
@@ -376,7 +918,7 @@ fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
}
void pa__done(pa_module*m) {
@@ -394,6 +936,13 @@ void pa__done(pa_module*m) {
pa_hook_slot_free(u->sink_fixate_hook_slot);
if (u->source_fixate_hook_slot)
pa_hook_slot_free(u->source_fixate_hook_slot);
+ if (u->sink_new_hook_slot)
+ pa_hook_slot_free(u->sink_new_hook_slot);
+ if (u->source_new_hook_slot)
+ pa_hook_slot_free(u->source_new_hook_slot);
+
+ if (u->connection_unlink_hook_slot)
+ pa_hook_slot_free(u->connection_unlink_hook_slot);
if (u->save_time_event)
u->core->mainloop->time_free(u->save_time_event);
@@ -401,5 +950,13 @@ void pa__done(pa_module*m) {
if (u->database)
pa_database_close(u->database);
+ if (u->protocol) {
+ pa_native_protocol_remove_ext(u->protocol, m);
+ pa_native_protocol_unref(u->protocol);
+ }
+
+ if (u->subscribed)
+ pa_idxset_free(u->subscribed, NULL, NULL);
+
pa_xfree(u);
}
diff --git a/src/modules/module-equalizer-sink.c b/src/modules/module-equalizer-sink.c
new file mode 100644
index 00000000..e7d8790a
--- /dev/null
+++ b/src/modules/module-equalizer-sink.c
@@ -0,0 +1,2221 @@
+/***
+ This file is part of PulseAudio.
+
+ This module is based off Lennart Poettering's LADSPA sink and swaps out
+ LADSPA functionality for a dbus-aware STFT OLA based digital equalizer.
+ All new work is published under Pulseaudio's original license.
+
+ Copyright 2009 Jason Newton <nevion@gmail.com>
+
+ Original Author:
+ Copyright 2004-2008 Lennart Poettering
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of the
+ License, or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <float.h>
+#include <math.h>
+#include <string.h>
+#include <stdint.h>
+
+//#undef __SSE2__
+#ifdef __SSE2__
+#include <xmmintrin.h>
+#include <emmintrin.h>
+#endif
+
+#include <fftw3.h>
+
+#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
+#include <pulse/timeval.h>
+
+#include <pulsecore/core-rtclock.h>
+#include <pulsecore/aupdate.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/module.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/rtpoll.h>
+#include <pulsecore/sample-util.h>
+#include <pulsecore/shared.h>
+#include <pulsecore/idxset.h>
+#include <pulsecore/strlist.h>
+#include <pulsecore/database.h>
+#include <pulsecore/protocol-dbus.h>
+#include <pulsecore/dbus-util.h>
+
+#include "module-equalizer-sink-symdef.h"
+
+PA_MODULE_AUTHOR("Jason Newton");
+PA_MODULE_DESCRIPTION(_("General Purpose Equalizer"));
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE(
+ _("sink_name=<name of the sink> "
+ "sink_properties=<properties for the sink> "
+ "sink_master=<sink to connect to> "
+ "format=<sample format> "
+ "rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<channel map> "
+ "autoloaded=<set if this module is being loaded automatically> "
+ ));
+
+#define MEMBLOCKQ_MAXLENGTH (16*1024*1024)
+#define DEFAULT_AUTOLOADED FALSE
+
+struct userdata {
+ pa_module *module;
+ pa_sink *sink;
+ pa_sink_input *sink_input;
+ pa_bool_t autoloaded;
+
+ size_t channels;
+ size_t fft_size;//length (res) of fft
+ size_t window_size;/*
+ *sliding window size
+ *effectively chooses R
+ */
+ size_t R;/* the hop size between overlapping windows
+ * the latency of the filter, calculated from window_size
+ * based on constraints of COLA and window function
+ */
+ //for twiddling with pulseaudio
+ size_t overlap_size;//window_size-R
+ size_t samples_gathered;
+ size_t input_buffer_max;
+ //message
+ float *W;//windowing function (time domain)
+ float *work_buffer, **input, **overlap_accum;
+ fftwf_complex *output_window;
+ fftwf_plan forward_plan, inverse_plan;
+ //size_t samplings;
+
+ float **Xs;
+ float ***Hs;//thread updatable copies of the freq response filters (magintude based)
+ pa_aupdate **a_H;
+ pa_memblockq *input_q;
+ char *output_buffer;
+ size_t output_buffer_length;
+ size_t output_buffer_max_length;
+ pa_memblockq *output_q;
+ pa_bool_t first_iteration;
+
+ pa_dbus_protocol *dbus_protocol;
+ char *dbus_path;
+
+ pa_database *database;
+ char **base_profiles;
+};
+
+static const char* const valid_modargs[] = {
+ "sink_name",
+ "sink_properties",
+ "sink_master",
+ "format",
+ "rate",
+ "channels",
+ "channel_map",
+ "autoloaded",
+ NULL
+};
+
+#define v_size 4
+#define SINKLIST "equalized_sinklist"
+#define EQDB "equalizer_db"
+#define EQ_STATE_DB "equalizer-state"
+#define FILTER_SIZE(u) ((u)->fft_size / 2 + 1)
+#define CHANNEL_PROFILE_SIZE(u) (FILTER_SIZE(u) + 1)
+#define FILTER_STATE_SIZE(u) (CHANNEL_PROFILE_SIZE(u) * (u)->channels)
+
+static void dbus_init(struct userdata *u);
+static void dbus_done(struct userdata *u);
+
+static void hanning_window(float *W, size_t window_size){
+ /* h=.5*(1-cos(2*pi*j/(window_size+1)), COLA for R=(M+1)/2 */
+ for (size_t i = 0; i < window_size; ++i)
+ W[i] = (float).5 * (1 - cos(2*M_PI*i / (window_size+1)));
+}
+
+static void fix_filter(float *H, size_t fft_size){
+ /* divide out the fft gain */
+ for (size_t i = 0; i < fft_size / 2 + 1; ++i)
+ H[i] /= fft_size;
+}
+
+static void interpolate(float *signal, size_t length, uint32_t *xs, float *ys, size_t n_points){
+ /* Note that xs must be monotonically increasing! */
+ float x_range_lower, x_range_upper, c0;
+
+ pa_assert(n_points >= 2);
+ pa_assert(xs[0] == 0);
+ pa_assert(xs[n_points - 1] == length - 1);
+
+ for (size_t x = 0, x_range_lower_i = 0; x < length-1; ++x) {
+ pa_assert(x_range_lower_i < n_points-1);
+
+ x_range_lower = (float) xs[x_range_lower_i];
+ x_range_upper = (float) xs[x_range_lower_i+1];
+
+ pa_assert_se(x_range_lower < x_range_upper);
+ pa_assert_se(x >= x_range_lower);
+ pa_assert_se(x <= x_range_upper);
+
+ /* bilinear-interpolation of coefficients specified */
+ c0 = (x-x_range_lower) / (x_range_upper-x_range_lower);
+ pa_assert(c0 >= 0 && c0 <= 1.0);
+
+ signal[x] = ((1.0f - c0) * ys[x_range_lower_i] + c0 * ys[x_range_lower_i + 1]);
+ while(x >= xs[x_range_lower_i + 1])
+ x_range_lower_i++;
+ }
+
+ signal[length-1] = ys[n_points-1];
+}
+
+static pa_bool_t is_monotonic(const uint32_t *xs, size_t length) {
+ pa_assert(xs);
+
+ if (length < 2)
+ return TRUE;
+
+ for(size_t i = 1; i < length; ++i)
+ if (xs[i] <= xs[i-1])
+ return FALSE;
+
+ return TRUE;
+}
+
+/* ensures memory allocated is a multiple of v_size and aligned */
+static void * alloc(size_t x, size_t s){
+ size_t f;
+ float *t;
+
+ f = PA_ROUND_UP(x*s, sizeof(float)*v_size);
+ pa_assert_se(t = fftwf_malloc(f));
+ pa_memzero(t, f);
+
+ return t;
+}
+
+static void alloc_input_buffers(struct userdata *u, size_t min_buffer_length){
+ if (min_buffer_length <= u->input_buffer_max)
+ return;
+
+ pa_assert(min_buffer_length >= u->window_size);
+ for (size_t c = 0; c < u->channels; ++c) {
+ float *tmp = alloc(min_buffer_length, sizeof(float));
+ if (u->input[c]) {
+ if (!u->first_iteration)
+ memcpy(tmp, u->input[c], u->overlap_size * sizeof(float));
+ free(u->input[c]);
+ }
+ u->input[c] = tmp;
+ }
+ u->input_buffer_max = min_buffer_length;
+}
+
+/* Called from I/O thread context */
+static int sink_process_msg_cb(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SINK(o)->userdata;
+
+ switch (code) {
+
+ case PA_SINK_MESSAGE_GET_LATENCY: {
+ //size_t fs=pa_frame_size(&u->sink->sample_spec);
+
+ /* The sink is _put() before the sink input is, so let's
+ * make sure we don't access it in that time. Also, the
+ * sink input is first shut down, the sink second. */
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state)) {
+ *((pa_usec_t*) data) = 0;
+ return 0;
+ }
+
+ *((pa_usec_t*) data) =
+ /* Get the latency of the master sink */
+ pa_sink_get_latency_within_thread(u->sink_input->sink) +
+
+ /* Add the latency internal to our sink input on top */
+ pa_bytes_to_usec(pa_memblockq_get_length(u->output_q) +
+ pa_memblockq_get_length(u->input_q), &u->sink_input->sink->sample_spec) +
+ pa_bytes_to_usec(pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq), &u->sink_input->sink->sample_spec);
+ // pa_bytes_to_usec(u->samples_gathered * fs, &u->sink->sample_spec);
+ //+ pa_bytes_to_usec(u->latency * fs, ss)
+ return 0;
+ }
+ }
+
+ return pa_sink_process_msg(o, code, data, offset, chunk);
+}
+
+
+/* Called from main context */
+static int sink_set_state_cb(pa_sink *s, pa_sink_state_t state) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(state) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return 0;
+
+ pa_sink_input_cork(u->sink_input, state == PA_SINK_SUSPENDED);
+ return 0;
+}
+
+/* Called from I/O thread context */
+static void sink_request_rewind_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
+ /* Just hand this one over to the master sink */
+ pa_sink_input_request_rewind(u->sink_input, s->thread_info.rewind_nbytes+pa_memblockq_get_length(u->input_q), TRUE, FALSE, FALSE);
+}
+
+/* Called from I/O thread context */
+static void sink_update_requested_latency_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
+ /* Just hand this one over to the master sink */
+ pa_sink_input_set_requested_latency_within_thread(
+ u->sink_input,
+ pa_sink_get_requested_latency_within_thread(s));
+}
+
+/* Called from main context */
+static void sink_set_volume_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_volume(u->sink_input, &s->real_volume, s->save_volume, TRUE);
+}
+
+/* Called from main context */
+static void sink_set_mute_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_mute(u->sink_input, s->muted, s->save_muted);
+}
+
+#if 1
+//reference implementation
+static void dsp_logic(
+ float * restrict dst,//used as a temp array too, needs to be fft_length!
+ float * restrict src,/*input data w/ overlap at start,
+ *automatically cycled in routine
+ */
+ float * restrict overlap,
+ const float X,//multipliar
+ const float * restrict H,//The freq. magnitude scalers filter
+ const float * restrict W,//The windowing function
+ fftwf_complex * restrict output_window,//The transformed window'd src
+ struct userdata *u){
+
+ //use a linear-phase sliding STFT and overlap-add method (for each channel)
+ //window the data
+ for(size_t j = 0; j < u->window_size; ++j){
+ dst[j] = X * W[j] * src[j];
+ }
+ //zero padd the the remaining fft window
+ memset(dst + u->window_size, 0, (u->fft_size - u->window_size) * sizeof(float));
+ //Processing is done here!
+ //do fft
+ fftwf_execute_dft_r2c(u->forward_plan, dst, output_window);
+ //perform filtering
+ for(size_t j = 0; j < FILTER_SIZE(u); ++j){
+ u->output_window[j][0] *= H[j];
+ u->output_window[j][1] *= H[j];
+ }
+ //inverse fft
+ fftwf_execute_dft_c2r(u->inverse_plan, output_window, dst);
+ ////debug: tests overlaping add
+ ////and negates ALL PREVIOUS processing
+ ////yields a perfect reconstruction if COLA is held
+ //for(size_t j = 0; j < u->window_size; ++j){
+ // u->work_buffer[j] = u->W[j] * u->input[c][j];
+ //}
+
+ //overlap add and preserve overlap component from this window (linear phase)
+ for(size_t j = 0; j < u->overlap_size; ++j){
+ u->work_buffer[j] += overlap[j];
+ overlap[j] = dst[u->R + j];
+ }
+ ////debug: tests if basic buffering works
+ ////shouldn't modify the signal AT ALL (beyond roundoff)
+ //for(size_t j = 0; j < u->window_size;++j){
+ // u->work_buffer[j] = u->input[c][j];
+ //}
+
+ //preseve the needed input for the next window's overlap
+ memmove(src, src + u->R,
+ (u->samples_gathered - u->R) * sizeof(float)
+ );
+}
+#else
+typedef float v4sf __attribute__ ((__aligned__(v_size * sizeof(float))));
+typedef union float_vector {
+ float f[v_size];
+ v4sf v;
+ __m128 m;
+} float_vector_t;
+
+//regardless of sse enabled, the loops in here assume
+//16 byte aligned addresses and memory allocations divisible by v_size
+static void dsp_logic(
+ float * restrict dst,//used as a temp array too, needs to be fft_length!
+ float * restrict src,/*input data w/ overlap at start,
+ *automatically cycled in routine
+ */
+ float * restrict overlap,//The size of the overlap
+ const float X,//multipliar
+ const float * restrict H,//The freq. magnitude scalers filter
+ const float * restrict W,//The windowing function
+ fftwf_complex * restrict output_window,//The transformed window'd src
+ struct userdata *u){//Collection of constants
+ const size_t overlap_size = PA_ROUND_UP(u->overlap_size, v_size);
+ float_vector_t x;
+ x.f[0] = x.f[1] = x.f[2] = x.f[3] = X;
+
+ //assert(u->samples_gathered >= u->R);
+ //use a linear-phase sliding STFT and overlap-add method
+ for(size_t j = 0; j < u->window_size; j += v_size){
+ //dst[j] = W[j] * src[j];
+ float_vector_t *d = (float_vector_t*) (dst + j);
+ float_vector_t *w = (float_vector_t*) (W + j);
+ float_vector_t *s = (float_vector_t*) (src + j);
+//#if __SSE2__
+ d->m = _mm_mul_ps(x.m, _mm_mul_ps(w->m, s->m));
+// d->v = x->v * w->v * s->v;
+//#endif
+ }
+ //zero padd the the remaining fft window
+ memset(dst + u->window_size, 0, (u->fft_size - u->window_size) * sizeof(float));
+
+ //Processing is done here!
+ //do fft
+ fftwf_execute_dft_r2c(u->forward_plan, dst, output_window);
+ //perform filtering - purely magnitude based
+ for(size_t j = 0; j < FILTER_SIZE; j += v_size / 2){
+ //output_window[j][0]*=H[j];
+ //output_window[j][1]*=H[j];
+ float_vector_t *d = (float_vector_t*)( ((float *) output_window) + 2 * j);
+ float_vector_t h;
+ h.f[0] = h.f[1] = H[j];
+ h.f[2] = h.f[3] = H[j + 1];
+//#if __SSE2__
+ d->m = _mm_mul_ps(d->m, h.m);
+//#else
+// d->v = d->v * h.v;
+//#endif
+ }
+
+ //inverse fft
+ fftwf_execute_dft_c2r(u->inverse_plan, output_window, dst);
+
+ ////debug: tests overlaping add
+ ////and negates ALL PREVIOUS processing
+ ////yields a perfect reconstruction if COLA is held
+ //for(size_t j = 0; j < u->window_size; ++j){
+ // dst[j] = W[j] * src[j];
+ //}
+
+ //overlap add and preserve overlap component from this window (linear phase)
+ for(size_t j = 0; j < overlap_size; j += v_size){
+ //dst[j]+=overlap[j];
+ //overlap[j]+=dst[j+R];
+ float_vector_t *d = (float_vector_t*)(dst + j);
+ float_vector_t *o = (float_vector_t*)(overlap + j);
+//#if __SSE2__
+ d->m = _mm_add_ps(d->m, o->m);
+ o->m = ((float_vector_t*)(dst + u->R + j))->m;
+//#else
+// d->v = d->v + o->v;
+// o->v = ((float_vector_t*)(dst + u->R + j))->v;
+//#endif
+ }
+ //memcpy(overlap, dst+u->R, u->overlap_size * sizeof(float)); //overlap preserve (debug)
+ //zero out the bit beyond the real overlap so we don't add garbage next iteration
+ memset(overlap + u->overlap_size, 0, overlap_size - u->overlap_size);
+
+ ////debug: tests if basic buffering works
+ ////shouldn't modify the signal AT ALL (beyond roundoff)
+ //for(size_t j = 0; j < u->window_size; ++j){
+ // dst[j] = src[j];
+ //}
+
+ //preseve the needed input for the next window's overlap
+ memmove(src, src + u->R,
+ (u->samples_gathered - u->R) * sizeof(float)
+ );
+}
+#endif
+
+static void flatten_to_memblockq(struct userdata *u){
+ size_t mbs = pa_mempool_block_size_max(u->sink->core->mempool);
+ pa_memchunk tchunk;
+ char *dst;
+ size_t i = 0;
+ while(i < u->output_buffer_length){
+ tchunk.index = 0;
+ tchunk.length = PA_MIN((u->output_buffer_length - i), mbs);
+ tchunk.memblock = pa_memblock_new(u->sink->core->mempool, tchunk.length);
+ //pa_log_debug("pushing %ld into the q", tchunk.length);
+ dst = pa_memblock_acquire(tchunk.memblock);
+ memcpy(dst, u->output_buffer + i, tchunk.length);
+ pa_memblock_release(tchunk.memblock);
+ pa_memblockq_push(u->output_q, &tchunk);
+ pa_memblock_unref(tchunk.memblock);
+ i += tchunk.length;
+ }
+}
+
+static void process_samples(struct userdata *u){
+ size_t fs = pa_frame_size(&(u->sink->sample_spec));
+ unsigned a_i;
+ float *H, X;
+ size_t iterations, offset;
+ pa_assert(u->samples_gathered >= u->window_size);
+ iterations = (u->samples_gathered - u->overlap_size) / u->R;
+ //make sure there is enough buffer memory allocated
+ if(iterations * u->R * fs > u->output_buffer_max_length){
+ u->output_buffer_max_length = iterations * u->R * fs;
+ pa_xfree(u->output_buffer);
+ u->output_buffer = pa_xmalloc(u->output_buffer_max_length);
+ }
+ u->output_buffer_length = iterations * u->R * fs;
+
+ for(size_t iter = 0; iter < iterations; ++iter){
+ offset = iter * u->R * fs;
+ for(size_t c = 0;c < u->channels; c++) {
+ a_i = pa_aupdate_read_begin(u->a_H[c]);
+ X = u->Xs[c][a_i];
+ H = u->Hs[c][a_i];
+ dsp_logic(
+ u->work_buffer,
+ u->input[c],
+ u->overlap_accum[c],
+ X,
+ H,
+ u->W,
+ u->output_window,
+ u
+ );
+ pa_aupdate_read_end(u->a_H[c]);
+ if(u->first_iteration){
+ /* The windowing function will make the audio ramped in, as a cheap fix we can
+ * undo the windowing (for non-zero window values)
+ */
+ for(size_t i = 0; i < u->overlap_size; ++i){
+ u->work_buffer[i] = u->W[i] <= FLT_EPSILON ? u->work_buffer[i] : u->work_buffer[i] / u->W[i];
+ }
+ }
+ pa_sample_clamp(PA_SAMPLE_FLOAT32NE, (uint8_t *) (((float *)u->output_buffer) + c) + offset, fs, u->work_buffer, sizeof(float), u->R);
+ }
+ if(u->first_iteration){
+ u->first_iteration = FALSE;
+ }
+ u->samples_gathered -= u->R;
+ }
+ flatten_to_memblockq(u);
+}
+
+static void input_buffer(struct userdata *u, pa_memchunk *in){
+ size_t fs = pa_frame_size(&(u->sink->sample_spec));
+ size_t samples = in->length/fs;
+ float *src = (float*) ((uint8_t*) pa_memblock_acquire(in->memblock) + in->index);
+ pa_assert(u->samples_gathered + samples <= u->input_buffer_max);
+ for(size_t c = 0; c < u->channels; c++) {
+ //buffer with an offset after the overlap from previous
+ //iterations
+ pa_assert_se(
+ u->input[c] + u->samples_gathered + samples <= u->input[c] + u->input_buffer_max
+ );
+ pa_sample_clamp(PA_SAMPLE_FLOAT32NE, u->input[c] + u->samples_gathered, sizeof(float), src + c, fs, samples);
+ }
+ u->samples_gathered += samples;
+ pa_memblock_release(in->memblock);
+}
+
+/* Called from I/O thread context */
+static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk) {
+ struct userdata *u;
+ size_t fs, target_samples;
+ size_t mbs;
+ //struct timeval start, end;
+ pa_memchunk tchunk;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+ pa_assert(chunk);
+ pa_assert(u->sink);
+
+ /* FIXME: Please clean this up. I see more commented code lines
+ * than uncommented code lines. I am sorry, but I am too dumb to
+ * understand this. */
+
+ fs = pa_frame_size(&(u->sink->sample_spec));
+ mbs = pa_mempool_block_size_max(u->sink->core->mempool);
+ if(pa_memblockq_get_length(u->output_q) > 0){
+ //pa_log_debug("qsize is %ld", pa_memblockq_get_length(u->output_q));
+ goto END;
+ }
+ //nbytes = PA_MIN(nbytes, pa_mempool_block_size_max(u->sink->core->mempool));
+ target_samples = PA_ROUND_UP(nbytes / fs, u->R);
+ ////pa_log_debug("vanilla mbs = %ld",mbs);
+ //mbs = PA_ROUND_DOWN(mbs / fs, u->R);
+ //mbs = PA_MAX(mbs, u->R);
+ //target_samples = PA_MAX(target_samples, mbs);
+ //pa_log_debug("target samples: %ld", target_samples);
+ if(u->first_iteration){
+ //allocate request_size
+ target_samples = PA_MAX(target_samples, u->window_size);
+ }else{
+ //allocate request_size + overlap
+ target_samples += u->overlap_size;
+ }
+ alloc_input_buffers(u, target_samples);
+ //pa_log_debug("post target samples: %ld", target_samples);
+ chunk->memblock = NULL;
+
+ /* Hmm, process any rewind request that might be queued up */
+ pa_sink_process_rewind(u->sink, 0);
+
+ //pa_log_debug("start output-buffered %ld, input-buffered %ld, requested %ld",buffered_samples,u->samples_gathered,samples_requested);
+ //pa_rtclock_get(&start);
+ do{
+ size_t input_remaining = target_samples - u->samples_gathered;
+ // pa_log_debug("input remaining %ld samples", input_remaining);
+ pa_assert(input_remaining > 0);
+ while (pa_memblockq_peek(u->input_q, &tchunk) < 0) {
+ //pa_sink_render(u->sink, input_remaining * fs, &tchunk);
+ pa_sink_render_full(u->sink, PA_MIN(input_remaining * fs, mbs), &tchunk);
+ pa_memblockq_push(u->input_q, &tchunk);
+ pa_memblock_unref(tchunk.memblock);
+ }
+ pa_assert(tchunk.memblock);
+
+ tchunk.length = PA_MIN(input_remaining * fs, tchunk.length);
+
+ pa_memblockq_drop(u->input_q, tchunk.length);
+ //pa_log_debug("asked for %ld input samples, got %ld samples",input_remaining,buffer->length/fs);
+ /* copy new input */
+ //pa_rtclock_get(start);
+ // pa_log_debug("buffering %ld bytes", tchunk.length);
+ input_buffer(u, &tchunk);
+ //pa_rtclock_get(&end);
+ //pa_log_debug("Took %0.5f seconds to setup", pa_timeval_diff(end, start) / (double) PA_USEC_PER_SEC);
+ pa_memblock_unref(tchunk.memblock);
+ } while(u->samples_gathered < target_samples);
+
+ //pa_rtclock_get(&end);
+ //pa_log_debug("Took %0.6f seconds to get data", (double) pa_timeval_diff(&end, &start) / PA_USEC_PER_SEC);
+
+ pa_assert(u->fft_size >= u->window_size);
+ pa_assert(u->R < u->window_size);
+ //pa_rtclock_get(&start);
+ /* process a block */
+ process_samples(u);
+ //pa_rtclock_get(&end);
+ //pa_log_debug("Took %0.6f seconds to process", (double) pa_timeval_diff(&end, &start) / PA_USEC_PER_SEC);
+END:
+ pa_assert_se(pa_memblockq_peek(u->output_q, chunk) >= 0);
+ pa_assert(chunk->memblock);
+ pa_memblockq_drop(u->output_q, chunk->length);
+
+ /** FIXME: Uh? you need to unref the chunk here! */
+
+ //pa_log_debug("gave %ld", chunk->length/fs);
+ //pa_log_debug("end pop");
+ return 0;
+}
+
+/* Called from main context */
+static void sink_input_volume_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_volume_changed(u->sink, &i->volume);
+}
+
+/* Called from main context */
+static void sink_input_mute_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_mute_changed(u->sink, i->muted);
+}
+
+static void reset_filter(struct userdata *u){
+ size_t fs = pa_frame_size(&u->sink->sample_spec);
+ size_t max_request;
+
+ u->samples_gathered = 0;
+
+ for(size_t i = 0; i < u->channels; ++i)
+ pa_memzero(u->overlap_accum[i], u->overlap_size * sizeof(float));
+
+ u->first_iteration = TRUE;
+ //set buffer size to max request, no overlap copy
+ max_request = PA_ROUND_UP(pa_sink_input_get_max_request(u->sink_input) / fs , u->R);
+ max_request = PA_MAX(max_request, u->window_size);
+ pa_sink_set_max_request_within_thread(u->sink, max_request * fs);
+}
+
+/* Called from I/O thread context */
+static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+ size_t amount = 0;
+
+ pa_log_debug("Rewind callback!");
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ if (u->sink->thread_info.rewind_nbytes > 0) {
+ size_t max_rewrite;
+
+ //max_rewrite = nbytes;
+ max_rewrite = nbytes + pa_memblockq_get_length(u->input_q);
+ //PA_MIN(pa_memblockq_get_length(u->input_q), nbytes);
+ amount = PA_MIN(u->sink->thread_info.rewind_nbytes, max_rewrite);
+ u->sink->thread_info.rewind_nbytes = 0;
+
+ if (amount > 0) {
+ //invalidate the output q
+ pa_memblockq_seek(u->input_q, - (int64_t) amount, PA_SEEK_RELATIVE, TRUE);
+ pa_log("Resetting filter");
+ //reset_filter(u); //this is the "proper" thing to do...
+ }
+ }
+
+ pa_sink_process_rewind(u->sink, amount);
+ pa_memblockq_rewind(u->input_q, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_memblockq_set_maxrewind(u->input_q, nbytes);
+ pa_sink_set_max_rewind_within_thread(u->sink, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+ size_t fs;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ fs = pa_frame_size(&u->sink_input->sample_spec);
+ pa_sink_set_max_request_within_thread(u->sink, PA_ROUND_UP(nbytes / fs, u->R) * fs);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_sink_latency_range_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_sink_fixed_latency_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_detach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_detach_within_thread(u->sink);
+
+ pa_sink_set_rtpoll(u->sink, NULL);
+}
+
+/* Called from I/O thread context */
+static void sink_input_attach_cb(pa_sink_input *i) {
+ struct userdata *u;
+ size_t fs, max_request;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_set_rtpoll(u->sink, i->sink->thread_info.rtpoll);
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+
+ fs = pa_frame_size(&u->sink_input->sample_spec);
+ /* set buffer size to max request, no overlap copy */
+ max_request = PA_ROUND_UP(pa_sink_input_get_max_request(u->sink_input) / fs, u->R);
+ max_request = PA_MAX(max_request, u->window_size);
+
+ pa_sink_set_max_request_within_thread(u->sink, max_request * fs);
+ pa_sink_set_max_rewind_within_thread(u->sink, pa_sink_input_get_max_rewind(i));
+
+ pa_sink_attach_within_thread(u->sink);
+}
+
+/* Called from main context */
+static void sink_input_kill_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ /* The order here matters! We first kill the sink input, followed
+ * by the sink. That means the sink callbacks must be protected
+ * against an unconnected sink input! */
+ pa_sink_input_unlink(u->sink_input);
+ pa_sink_unlink(u->sink);
+
+ pa_sink_input_unref(u->sink_input);
+ u->sink_input = NULL;
+
+ pa_sink_unref(u->sink);
+ u->sink = NULL;
+
+ pa_module_unload_request(u->module, TRUE);
+}
+
+/* Called from IO thread context */
+static void sink_input_state_change_cb(pa_sink_input *i, pa_sink_input_state_t state) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ /* If we are added for the first time, ask for a rewinding so that
+ * we are heard right-away. */
+ if (PA_SINK_INPUT_IS_LINKED(state) &&
+ i->thread_info.state == PA_SINK_INPUT_INIT) {
+ pa_log_debug("Requesting rewind due to state change.");
+ pa_sink_input_request_rewind(i, 0, FALSE, TRUE, TRUE);
+ }
+}
+
+static void pack(char **strs, size_t len, char **packed, size_t *length){
+ size_t t_len = 0;
+ size_t headers = (1+len) * sizeof(uint16_t);
+ char *p;
+ for(size_t i = 0; i < len; ++i){
+ t_len += strlen(strs[i]);
+ }
+ *length = headers + t_len;
+ p = *packed = pa_xmalloc0(*length);
+ *((uint16_t *) p) = (uint16_t) len;
+ p += sizeof(uint16_t);
+ for(size_t i = 0; i < len; ++i){
+ uint16_t l = strlen(strs[i]);
+ *((uint16_t *) p) = (uint16_t) l;
+ p += sizeof(uint16_t);
+ memcpy(p, strs[i], l);
+ p += l;
+ }
+}
+static void unpack(char *str, size_t length, char ***strs, size_t *len){
+ char *p = str;
+ *len = *((uint16_t *) p);
+ p += sizeof(uint16_t);
+ *strs = pa_xnew(char *, *len);
+
+ for(size_t i = 0; i < *len; ++i){
+ size_t l = *((uint16_t *) p);
+ p += sizeof(uint16_t);
+ (*strs)[i] = pa_xnew(char, l + 1);
+ memcpy((*strs)[i], p, l);
+ (*strs)[i][l] = '\0';
+ p += l;
+ }
+}
+static void save_profile(struct userdata *u, size_t channel, char *name){
+ unsigned a_i;
+ const size_t profile_size = CHANNEL_PROFILE_SIZE(u) * sizeof(float);
+ float *H_n, *profile;
+ const float *H;
+ pa_datum key, data;
+ profile = pa_xnew0(float, profile_size);
+ a_i = pa_aupdate_read_begin(u->a_H[channel]);
+ profile[0] = u->Xs[a_i][channel];
+ H = u->Hs[channel][a_i];
+ H_n = profile + 1;
+ for(size_t i = 0 ; i <= FILTER_SIZE(u); ++i){
+ H_n[i] = H[i] * u->fft_size;
+ //H_n[i] = H[i];
+ }
+ pa_aupdate_read_end(u->a_H[channel]);
+ key.data=name;
+ key.size = strlen(key.data);
+ data.data = profile;
+ data.size = profile_size;
+ pa_database_set(u->database, &key, &data, TRUE);
+ pa_database_sync(u->database);
+ if(u->base_profiles[channel]){
+ pa_xfree(u->base_profiles[channel]);
+ }
+ u->base_profiles[channel] = pa_xstrdup(name);
+}
+
+static void save_state(struct userdata *u){
+ unsigned a_i;
+ const size_t filter_state_size = FILTER_STATE_SIZE(u) * sizeof(float);
+ float *H_n, *state;
+ float *H;
+ pa_datum key, data;
+ pa_database *database;
+ char *dbname;
+ char *packed;
+ size_t packed_length;
+
+ pack(u->base_profiles, u->channels, &packed, &packed_length);
+ state = (float *) pa_xmalloc0(filter_state_size + packed_length);
+ memcpy(state + FILTER_STATE_SIZE(u), packed, packed_length);
+ pa_xfree(packed);
+
+ for(size_t c = 0; c < u->channels; ++c){
+ a_i = pa_aupdate_read_begin(u->a_H[c]);
+ state[c * CHANNEL_PROFILE_SIZE(u)] = u->Xs[c][a_i];
+ H = u->Hs[c][a_i];
+ H_n = &state[c * CHANNEL_PROFILE_SIZE(u) + 1];
+ memcpy(H_n, H, FILTER_SIZE(u) * sizeof(float));
+ pa_aupdate_read_end(u->a_H[c]);
+ }
+
+ key.data = u->sink->name;
+ key.size = strlen(key.data);
+ data.data = state;
+ data.size = filter_state_size + packed_length;
+ //thread safety for 0.9.17?
+ pa_assert_se(dbname = pa_state_path(EQ_STATE_DB, FALSE));
+ pa_assert_se(database = pa_database_open(dbname, TRUE));
+ pa_xfree(dbname);
+
+ pa_database_set(database, &key, &data, TRUE);
+ pa_database_sync(database);
+ pa_database_close(database);
+ pa_xfree(state);
+}
+
+static void remove_profile(pa_core *c, char *name){
+ pa_datum key;
+ pa_database *database;
+ key.data = name;
+ key.size = strlen(key.data);
+ pa_assert_se(database = pa_shared_get(c, EQDB));
+ pa_database_unset(database, &key);
+ pa_database_sync(database);
+}
+
+static const char* load_profile(struct userdata *u, size_t channel, char *name){
+ unsigned a_i;
+ pa_datum key, value;
+ const size_t profile_size = CHANNEL_PROFILE_SIZE(u) * sizeof(float);
+ key.data = name;
+ key.size = strlen(key.data);
+ if(pa_database_get(u->database, &key, &value) != NULL){
+ if(value.size == profile_size){
+ float *profile = (float *) value.data;
+ a_i = pa_aupdate_write_begin(u->a_H[channel]);
+ u->Xs[channel][a_i] = profile[0];
+ memcpy(u->Hs[channel][a_i], profile + 1, FILTER_SIZE(u) * sizeof(float));
+ fix_filter(u->Hs[channel][a_i], u->fft_size);
+ pa_aupdate_write_end(u->a_H[channel]);
+ pa_xfree(u->base_profiles[channel]);
+ u->base_profiles[channel] = pa_xstrdup(name);
+ }else{
+ return "incompatible size";
+ }
+ pa_datum_free(&value);
+ }else{
+ return "profile doesn't exist";
+ }
+ return NULL;
+}
+
+static void load_state(struct userdata *u){
+ unsigned a_i;
+ float *H;
+ pa_datum key, value;
+ pa_database *database;
+ char *dbname;
+ pa_assert_se(dbname = pa_state_path(EQ_STATE_DB, FALSE));
+ database = pa_database_open(dbname, FALSE);
+ pa_xfree(dbname);
+ if(!database){
+ pa_log("No resume state");
+ return;
+ }
+
+ key.data = u->sink->name;
+ key.size = strlen(key.data);
+
+ if(pa_database_get(database, &key, &value) != NULL){
+ if(value.size > FILTER_STATE_SIZE(u) * sizeof(float) + sizeof(uint16_t)){
+ float *state = (float *) value.data;
+ size_t n_profs;
+ char **names;
+ for(size_t c = 0; c < u->channels; ++c){
+ a_i = pa_aupdate_write_begin(u->a_H[c]);
+ H = state + c * CHANNEL_PROFILE_SIZE(u) + 1;
+ u->Xs[c][a_i] = state[c * CHANNEL_PROFILE_SIZE(u)];
+ memcpy(u->Hs[c][a_i], H, FILTER_SIZE(u) * sizeof(float));
+ pa_aupdate_write_end(u->a_H[c]);
+ }
+ unpack(((char *)value.data) + FILTER_STATE_SIZE(u) * sizeof(float), value.size - FILTER_STATE_SIZE(u) * sizeof(float), &names, &n_profs);
+ n_profs = PA_MIN(n_profs, u->channels);
+ for(size_t c = 0; c < n_profs; ++c){
+ pa_xfree(u->base_profiles[c]);
+ u->base_profiles[c] = names[c];
+ }
+ pa_xfree(names);
+ }
+ pa_datum_free(&value);
+ }else{
+ pa_log("resume state exists but is wrong size!");
+ }
+ pa_database_close(database);
+}
+
+/* Called from main context */
+static pa_bool_t sink_input_may_move_to_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ return u->sink != dest;
+}
+
+/* Called from main context */
+static void sink_input_moving_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ if (dest) {
+ pa_sink_set_asyncmsgq(u->sink, dest->asyncmsgq);
+ pa_sink_update_flags(u->sink, PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY, dest->flags);
+ } else
+ pa_sink_set_asyncmsgq(u->sink, NULL);
+}
+
+int pa__init(pa_module*m) {
+ struct userdata *u;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ pa_modargs *ma;
+ const char *z;
+ pa_sink *master;
+ pa_sink_input_new_data sink_input_data;
+ pa_sink_new_data sink_data;
+ size_t fs, i;
+ unsigned c;
+ float *H;
+ unsigned a_i;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ if (!(master = pa_namereg_get(m->core, pa_modargs_get_value(ma, "sink_master", NULL), PA_NAMEREG_SINK))) {
+ pa_log("Master sink not found");
+ goto fail;
+ }
+
+ ss = master->sample_spec;
+ ss.format = PA_SAMPLE_FLOAT32;
+ map = master->channel_map;
+ if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_DEFAULT) < 0) {
+ pa_log("Invalid sample format specification or channel map");
+ goto fail;
+ }
+
+ fs = pa_frame_size(&ss);
+
+ u = pa_xnew0(struct userdata, 1);
+ u->module = m;
+ m->userdata = u;
+
+ u->channels = ss.channels;
+ u->fft_size = pow(2, ceil(log(ss.rate) / log(2)));//probably unstable near corner cases of powers of 2
+ pa_log_debug("fft size: %ld", u->fft_size);
+ u->window_size = 15999;
+ if (u->window_size % 2 == 0)
+ u->window_size--;
+ u->R = (u->window_size + 1) / 2;
+ u->overlap_size = u->window_size - u->R;
+ u->samples_gathered = 0;
+ u->input_buffer_max = 0;
+
+ u->a_H = pa_xnew0(pa_aupdate *, u->channels);
+ u->Xs = pa_xnew0(float *, u->channels);
+ u->Hs = pa_xnew0(float **, u->channels);
+
+ for (c = 0; c < u->channels; ++c) {
+ u->Xs[c] = pa_xnew0(float, 2);
+ u->Hs[c] = pa_xnew0(float *, 2);
+ for (i = 0; i < 2; ++i)
+ u->Hs[c][i] = alloc(FILTER_SIZE(u), sizeof(float));
+ }
+
+ u->W = alloc(u->window_size, sizeof(float));
+ u->work_buffer = alloc(u->fft_size, sizeof(float));
+ u->input = pa_xnew0(float *, u->channels);
+ u->overlap_accum = pa_xnew0(float *, u->channels);
+ for (c = 0; c < u->channels; ++c) {
+ u->a_H[c] = pa_aupdate_new();
+ u->input[c] = NULL;
+ u->overlap_accum[c] = alloc(u->overlap_size, sizeof(float));
+ }
+ u->output_window = alloc(FILTER_SIZE(u), sizeof(fftwf_complex));
+ u->forward_plan = fftwf_plan_dft_r2c_1d(u->fft_size, u->work_buffer, u->output_window, FFTW_ESTIMATE);
+ u->inverse_plan = fftwf_plan_dft_c2r_1d(u->fft_size, u->output_window, u->work_buffer, FFTW_ESTIMATE);
+
+ hanning_window(u->W, u->window_size);
+ u->first_iteration = TRUE;
+
+ u->base_profiles = pa_xnew0(char *, u->channels);
+ for (c = 0; c < u->channels; ++c)
+ u->base_profiles[c] = pa_xstrdup("default");
+
+ /* Create sink */
+ pa_sink_new_data_init(&sink_data);
+ sink_data.driver = __FILE__;
+ sink_data.module = m;
+ if (!(sink_data.name = pa_xstrdup(pa_modargs_get_value(ma, "sink_name", NULL))))
+ sink_data.name = pa_sprintf_malloc("%s.equalizer", master->name);
+ pa_sink_new_data_set_sample_spec(&sink_data, &ss);
+ pa_sink_new_data_set_channel_map(&sink_data, &map);
+
+ z = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "FFT based equalizer on %s", z ? z : master->name);
+
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, master->name);
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_CLASS, "filter");
+
+ if (pa_modargs_get_proplist(ma, "sink_properties", sink_data.proplist, PA_UPDATE_REPLACE) < 0) {
+ pa_log("Invalid properties");
+ pa_sink_new_data_done(&sink_data);
+ goto fail;
+ }
+
+ u->autoloaded = DEFAULT_AUTOLOADED;
+ if (pa_modargs_get_value_boolean(ma, "autoloaded", &u->autoloaded) < 0) {
+ pa_log("Failed to parse autoloaded value");
+ goto fail;
+ }
+
+ u->sink = pa_sink_new(m->core, &sink_data,
+ PA_SINK_HW_MUTE_CTRL|PA_SINK_HW_VOLUME_CTRL|PA_SINK_DECIBEL_VOLUME|
+ (master->flags & (PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY)));
+ pa_sink_new_data_done(&sink_data);
+
+ if (!u->sink) {
+ pa_log("Failed to create sink.");
+ goto fail;
+ }
+
+ u->sink->parent.process_msg = sink_process_msg_cb;
+ u->sink->set_state = sink_set_state_cb;
+ u->sink->update_requested_latency = sink_update_requested_latency_cb;
+ u->sink->request_rewind = sink_request_rewind_cb;
+ u->sink->set_volume = sink_set_volume_cb;
+ u->sink->set_mute = sink_set_mute_cb;
+ u->sink->userdata = u;
+
+ u->input_q = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, fs, 1, 1, 0, &u->sink->silence);
+ u->output_q = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, fs, 1, 1, 0, NULL);
+ u->output_buffer = NULL;
+ u->output_buffer_length = 0;
+ u->output_buffer_max_length = 0;
+
+ pa_sink_set_asyncmsgq(u->sink, master->asyncmsgq);
+ //pa_sink_set_fixed_latency(u->sink, pa_bytes_to_usec(u->R*fs, &ss));
+
+ /* Create sink input */
+ pa_sink_input_new_data_init(&sink_input_data);
+ sink_input_data.driver = __FILE__;
+ sink_input_data.module = m;
+ pa_sink_input_new_data_set_sink(&sink_input_data, master, FALSE);
+ sink_input_data.origin_sink = u->sink;
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_NAME, "Equalized Stream");
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ROLE, "filter");
+ pa_sink_input_new_data_set_sample_spec(&sink_input_data, &ss);
+ pa_sink_input_new_data_set_channel_map(&sink_input_data, &map);
+
+ pa_sink_input_new(&u->sink_input, m->core, &sink_input_data);
+ pa_sink_input_new_data_done(&sink_input_data);
+
+ if (!u->sink_input)
+ goto fail;
+
+ u->sink_input->pop = sink_input_pop_cb;
+ u->sink_input->process_rewind = sink_input_process_rewind_cb;
+ u->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
+ u->sink_input->update_max_request = sink_input_update_max_request_cb;
+ u->sink_input->update_sink_latency_range = sink_input_update_sink_latency_range_cb;
+ u->sink_input->update_sink_fixed_latency = sink_input_update_sink_fixed_latency_cb;
+ u->sink_input->kill = sink_input_kill_cb;
+ u->sink_input->attach = sink_input_attach_cb;
+ u->sink_input->detach = sink_input_detach_cb;
+ u->sink_input->state_change = sink_input_state_change_cb;
+ u->sink_input->may_move_to = sink_input_may_move_to_cb;
+ u->sink_input->moving = sink_input_moving_cb;
+ u->sink_input->volume_changed = sink_input_volume_changed_cb;
+ u->sink_input->mute_changed = sink_input_mute_changed_cb;
+ u->sink_input->userdata = u;
+
+ u->sink->input_to_master = u->sink_input;
+
+ dbus_init(u);
+
+ /* default filter to these */
+ for (c = 0; c< u->channels; ++c) {
+ a_i = pa_aupdate_write_begin(u->a_H[c]);
+ H = u->Hs[c][a_i];
+ u->Xs[c][a_i] = 1.0f;
+
+ for(i = 0; i < FILTER_SIZE(u); ++i)
+ H[i] = 1.0 / sqrtf(2.0f);
+
+ fix_filter(H, u->fft_size);
+ pa_aupdate_write_end(u->a_H[c]);
+ }
+
+ /* load old parameters */
+ load_state(u);
+
+ pa_sink_put(u->sink);
+ pa_sink_input_put(u->sink_input);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+int pa__get_n_used(pa_module *m) {
+ struct userdata *u;
+
+ pa_assert(m);
+ pa_assert_se(u = m->userdata);
+
+ return pa_sink_linked_by(u->sink);
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+ unsigned c;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ save_state(u);
+
+ dbus_done(u);
+
+ for(c = 0; c < u->channels; ++c)
+ pa_xfree(u->base_profiles[c]);
+ pa_xfree(u->base_profiles);
+
+ /* See comments in sink_input_kill_cb() above regarding
+ * destruction order! */
+
+ if (u->sink_input)
+ pa_sink_input_unlink(u->sink_input);
+
+ if (u->sink)
+ pa_sink_unlink(u->sink);
+
+ if (u->sink_input)
+ pa_sink_input_unref(u->sink_input);
+
+ if (u->sink)
+ pa_sink_unref(u->sink);
+
+ pa_xfree(u->output_buffer);
+ pa_memblockq_free(u->output_q);
+ pa_memblockq_free(u->input_q);
+
+ fftwf_destroy_plan(u->inverse_plan);
+ fftwf_destroy_plan(u->forward_plan);
+ pa_xfree(u->output_window);
+ for (c = 0; c < u->channels; ++c) {
+ pa_aupdate_free(u->a_H[c]);
+ pa_xfree(u->overlap_accum[c]);
+ pa_xfree(u->input[c]);
+ }
+ pa_xfree(u->a_H);
+ pa_xfree(u->overlap_accum);
+ pa_xfree(u->input);
+ pa_xfree(u->work_buffer);
+ pa_xfree(u->W);
+ for (c = 0; c < u->channels; ++c) {
+ pa_xfree(u->Xs[c]);
+ for (size_t i = 0; i < 2; ++i)
+ pa_xfree(u->Hs[c][i]);
+ pa_xfree(u->Hs[c]);
+ }
+ pa_xfree(u->Xs);
+ pa_xfree(u->Hs);
+
+ pa_xfree(u);
+}
+
+/*
+ * DBus Routines and Callbacks
+ */
+#define EXTNAME "org.PulseAudio.Ext.Equalizing1"
+#define MANAGER_PATH "/org/pulseaudio/equalizing1"
+#define MANAGER_IFACE EXTNAME ".Manager"
+#define EQUALIZER_IFACE EXTNAME ".Equalizer"
+static void manager_get_revision(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void manager_get_sinks(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void manager_get_profiles(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void manager_get_all(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void manager_handle_remove_profile(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_get_revision(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_get_filter_rate(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_get_n_coefs(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_get_n_channels(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_get_all(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_seed_filter(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_get_filter_points(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_get_filter(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_set_filter(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_save_profile(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_load_profile(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_save_state(DBusConnection *conn, DBusMessage *msg, void *_u);
+static void equalizer_handle_get_profile_name(DBusConnection *conn, DBusMessage *msg, void *_u);
+enum manager_method_index {
+ MANAGER_METHOD_REMOVE_PROFILE,
+ MANAGER_METHOD_MAX
+};
+
+pa_dbus_arg_info remove_profile_args[]={
+ {"name", "s","in"},
+};
+
+static pa_dbus_method_handler manager_methods[MANAGER_METHOD_MAX]={
+ [MANAGER_METHOD_REMOVE_PROFILE]{
+ .method_name="RemoveProfile",
+ .arguments=remove_profile_args,
+ .n_arguments=sizeof(remove_profile_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=manager_handle_remove_profile}
+};
+
+enum manager_handler_index {
+ MANAGER_HANDLER_REVISION,
+ MANAGER_HANDLER_EQUALIZED_SINKS,
+ MANAGER_HANDLER_PROFILES,
+ MANAGER_HANDLER_MAX
+};
+
+static pa_dbus_property_handler manager_handlers[MANAGER_HANDLER_MAX]={
+ [MANAGER_HANDLER_REVISION]={.property_name="InterfaceRevision",.type="u",.get_cb=manager_get_revision,.set_cb=NULL},
+ [MANAGER_HANDLER_EQUALIZED_SINKS]={.property_name="EqualizedSinks",.type="ao",.get_cb=manager_get_sinks,.set_cb=NULL},
+ [MANAGER_HANDLER_PROFILES]={.property_name="Profiles",.type="as",.get_cb=manager_get_profiles,.set_cb=NULL}
+};
+
+pa_dbus_arg_info sink_args[]={
+ {"sink", "o", NULL}
+};
+
+enum manager_signal_index{
+ MANAGER_SIGNAL_SINK_ADDED,
+ MANAGER_SIGNAL_SINK_REMOVED,
+ MANAGER_SIGNAL_PROFILES_CHANGED,
+ MANAGER_SIGNAL_MAX
+};
+
+static pa_dbus_signal_info manager_signals[MANAGER_SIGNAL_MAX]={
+ [MANAGER_SIGNAL_SINK_ADDED]={.name="SinkAdded", .arguments=sink_args, .n_arguments=sizeof(sink_args)/sizeof(pa_dbus_arg_info)},
+ [MANAGER_SIGNAL_SINK_REMOVED]={.name="SinkRemoved", .arguments=sink_args, .n_arguments=sizeof(sink_args)/sizeof(pa_dbus_arg_info)},
+ [MANAGER_SIGNAL_PROFILES_CHANGED]={.name="ProfilesChanged", .arguments=NULL, .n_arguments=0}
+};
+
+static pa_dbus_interface_info manager_info={
+ .name=MANAGER_IFACE,
+ .method_handlers=manager_methods,
+ .n_method_handlers=MANAGER_METHOD_MAX,
+ .property_handlers=manager_handlers,
+ .n_property_handlers=MANAGER_HANDLER_MAX,
+ .get_all_properties_cb=manager_get_all,
+ .signals=manager_signals,
+ .n_signals=MANAGER_SIGNAL_MAX
+};
+
+enum equalizer_method_index {
+ EQUALIZER_METHOD_FILTER_POINTS,
+ EQUALIZER_METHOD_SEED_FILTER,
+ EQUALIZER_METHOD_SAVE_PROFILE,
+ EQUALIZER_METHOD_LOAD_PROFILE,
+ EQUALIZER_METHOD_SET_FILTER,
+ EQUALIZER_METHOD_GET_FILTER,
+ EQUALIZER_METHOD_SAVE_STATE,
+ EQUALIZER_METHOD_GET_PROFILE_NAME,
+ EQUALIZER_METHOD_MAX
+};
+
+enum equalizer_handler_index {
+ EQUALIZER_HANDLER_REVISION,
+ EQUALIZER_HANDLER_SAMPLERATE,
+ EQUALIZER_HANDLER_FILTERSAMPLERATE,
+ EQUALIZER_HANDLER_N_COEFS,
+ EQUALIZER_HANDLER_N_CHANNELS,
+ EQUALIZER_HANDLER_MAX
+};
+
+pa_dbus_arg_info filter_points_args[]={
+ {"channel", "u","in"},
+ {"xs", "au","in"},
+ {"ys", "ad","out"},
+ {"preamp", "d","out"}
+};
+pa_dbus_arg_info seed_filter_args[]={
+ {"channel", "u","in"},
+ {"xs", "au","in"},
+ {"ys", "ad","in"},
+ {"preamp", "d","in"}
+};
+
+pa_dbus_arg_info set_filter_args[]={
+ {"channel", "u","in"},
+ {"ys", "ad","in"},
+ {"preamp", "d","in"}
+};
+pa_dbus_arg_info get_filter_args[]={
+ {"channel", "u","in"},
+ {"ys", "ad","out"},
+ {"preamp", "d","out"}
+};
+
+pa_dbus_arg_info save_profile_args[]={
+ {"channel", "u","in"},
+ {"name", "s","in"}
+};
+pa_dbus_arg_info load_profile_args[]={
+ {"channel", "u","in"},
+ {"name", "s","in"}
+};
+pa_dbus_arg_info base_profile_name_args[]={
+ {"channel", "u","in"},
+ {"name", "s","out"}
+};
+
+static pa_dbus_method_handler equalizer_methods[EQUALIZER_METHOD_MAX]={
+ [EQUALIZER_METHOD_SEED_FILTER]{
+ .method_name="SeedFilter",
+ .arguments=seed_filter_args,
+ .n_arguments=sizeof(seed_filter_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=equalizer_handle_seed_filter},
+ [EQUALIZER_METHOD_FILTER_POINTS]{
+ .method_name="FilterAtPoints",
+ .arguments=filter_points_args,
+ .n_arguments=sizeof(filter_points_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=equalizer_handle_get_filter_points},
+ [EQUALIZER_METHOD_SET_FILTER]{
+ .method_name="SetFilter",
+ .arguments=set_filter_args,
+ .n_arguments=sizeof(set_filter_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=equalizer_handle_set_filter},
+ [EQUALIZER_METHOD_GET_FILTER]{
+ .method_name="GetFilter",
+ .arguments=get_filter_args,
+ .n_arguments=sizeof(get_filter_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=equalizer_handle_get_filter},
+ [EQUALIZER_METHOD_SAVE_PROFILE]{
+ .method_name="SaveProfile",
+ .arguments=save_profile_args,
+ .n_arguments=sizeof(save_profile_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=equalizer_handle_save_profile},
+ [EQUALIZER_METHOD_LOAD_PROFILE]{
+ .method_name="LoadProfile",
+ .arguments=load_profile_args,
+ .n_arguments=sizeof(load_profile_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=equalizer_handle_load_profile},
+ [EQUALIZER_METHOD_SAVE_STATE]{
+ .method_name="SaveState",
+ .arguments=NULL,
+ .n_arguments=0,
+ .receive_cb=equalizer_handle_save_state},
+ [EQUALIZER_METHOD_GET_PROFILE_NAME]{
+ .method_name="BaseProfile",
+ .arguments=base_profile_name_args,
+ .n_arguments=sizeof(base_profile_name_args)/sizeof(pa_dbus_arg_info),
+ .receive_cb=equalizer_handle_get_profile_name}
+};
+
+static pa_dbus_property_handler equalizer_handlers[EQUALIZER_HANDLER_MAX]={
+ [EQUALIZER_HANDLER_REVISION]={.property_name="InterfaceRevision",.type="u",.get_cb=equalizer_get_revision,.set_cb=NULL},
+ [EQUALIZER_HANDLER_SAMPLERATE]{.property_name="SampleRate",.type="u",.get_cb=equalizer_get_sample_rate,.set_cb=NULL},
+ [EQUALIZER_HANDLER_FILTERSAMPLERATE]{.property_name="FilterSampleRate",.type="u",.get_cb=equalizer_get_filter_rate,.set_cb=NULL},
+ [EQUALIZER_HANDLER_N_COEFS]{.property_name="NFilterCoefficients",.type="u",.get_cb=equalizer_get_n_coefs,.set_cb=NULL},
+ [EQUALIZER_HANDLER_N_CHANNELS]{.property_name="NChannels",.type="u",.get_cb=equalizer_get_n_channels,.set_cb=NULL},
+};
+
+enum equalizer_signal_index{
+ EQUALIZER_SIGNAL_FILTER_CHANGED,
+ EQUALIZER_SIGNAL_SINK_RECONFIGURED,
+ EQUALIZER_SIGNAL_MAX
+};
+
+static pa_dbus_signal_info equalizer_signals[EQUALIZER_SIGNAL_MAX]={
+ [EQUALIZER_SIGNAL_FILTER_CHANGED]={.name="FilterChanged", .arguments=NULL, .n_arguments=0},
+ [EQUALIZER_SIGNAL_SINK_RECONFIGURED]={.name="SinkReconfigured", .arguments=NULL, .n_arguments=0},
+};
+
+static pa_dbus_interface_info equalizer_info={
+ .name=EQUALIZER_IFACE,
+ .method_handlers=equalizer_methods,
+ .n_method_handlers=EQUALIZER_METHOD_MAX,
+ .property_handlers=equalizer_handlers,
+ .n_property_handlers=EQUALIZER_HANDLER_MAX,
+ .get_all_properties_cb=equalizer_get_all,
+ .signals=equalizer_signals,
+ .n_signals=EQUALIZER_SIGNAL_MAX
+};
+
+void dbus_init(struct userdata *u){
+ uint32_t dummy;
+ DBusMessage *signal = NULL;
+ pa_idxset *sink_list = NULL;
+ u->dbus_protocol=pa_dbus_protocol_get(u->sink->core);
+ u->dbus_path=pa_sprintf_malloc("/org/pulseaudio/core1/sink%d", u->sink->index);
+
+ pa_dbus_protocol_add_interface(u->dbus_protocol, u->dbus_path, &equalizer_info, u);
+ sink_list = pa_shared_get(u->sink->core, SINKLIST);
+ u->database = pa_shared_get(u->sink->core, EQDB);
+ if(sink_list == NULL){
+ char *dbname;
+ sink_list=pa_idxset_new(&pa_idxset_trivial_hash_func, &pa_idxset_trivial_compare_func);
+ pa_shared_set(u->sink->core, SINKLIST, sink_list);
+ pa_assert_se(dbname = pa_state_path("equalizer-presets", FALSE));
+ pa_assert_se(u->database = pa_database_open(dbname, TRUE));
+ pa_xfree(dbname);
+ pa_shared_set(u->sink->core, EQDB, u->database);
+ pa_dbus_protocol_add_interface(u->dbus_protocol, MANAGER_PATH, &manager_info, u->sink->core);
+ pa_dbus_protocol_register_extension(u->dbus_protocol, EXTNAME);
+ }
+ pa_idxset_put(sink_list, u, &dummy);
+
+ pa_assert_se((signal = dbus_message_new_signal(MANAGER_PATH, MANAGER_IFACE, manager_signals[MANAGER_SIGNAL_SINK_ADDED].name)));
+ dbus_message_append_args(signal, DBUS_TYPE_OBJECT_PATH, &u->dbus_path, DBUS_TYPE_INVALID);
+ pa_dbus_protocol_send_signal(u->dbus_protocol, signal);
+ dbus_message_unref(signal);
+}
+
+void dbus_done(struct userdata *u){
+ pa_idxset *sink_list;
+ uint32_t dummy;
+
+ DBusMessage *signal = NULL;
+ pa_assert_se((signal = dbus_message_new_signal(MANAGER_PATH, MANAGER_IFACE, manager_signals[MANAGER_SIGNAL_SINK_REMOVED].name)));
+ dbus_message_append_args(signal, DBUS_TYPE_OBJECT_PATH, &u->dbus_path, DBUS_TYPE_INVALID);
+ pa_dbus_protocol_send_signal(u->dbus_protocol, signal);
+ dbus_message_unref(signal);
+
+ pa_assert_se(sink_list=pa_shared_get(u->sink->core,SINKLIST));
+ pa_idxset_remove_by_data(sink_list,u,&dummy);
+ if(pa_idxset_size(sink_list)==0){
+ pa_dbus_protocol_unregister_extension(u->dbus_protocol, EXTNAME);
+ pa_dbus_protocol_remove_interface(u->dbus_protocol, MANAGER_PATH, manager_info.name);
+ pa_shared_remove(u->sink->core, EQDB);
+ pa_database_close(u->database);
+ pa_shared_remove(u->sink->core, SINKLIST);
+ pa_xfree(sink_list);
+ }
+ pa_dbus_protocol_remove_interface(u->dbus_protocol, u->dbus_path, equalizer_info.name);
+ pa_xfree(u->dbus_path);
+ pa_dbus_protocol_unref(u->dbus_protocol);
+}
+
+void manager_handle_remove_profile(DBusConnection *conn, DBusMessage *msg, void *_u) {
+ DBusError error;
+ pa_core *c = (pa_core *)_u;
+ DBusMessage *signal = NULL;
+ pa_dbus_protocol *dbus_protocol;
+ char *name;
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(c);
+ dbus_error_init(&error);
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_STRING, &name,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ remove_profile(c,name);
+ pa_dbus_send_empty_reply(conn, msg);
+
+ pa_assert_se((signal = dbus_message_new_signal(MANAGER_PATH, MANAGER_IFACE, manager_signals[MANAGER_SIGNAL_PROFILES_CHANGED].name)));
+ dbus_protocol = pa_dbus_protocol_get(c);
+ pa_dbus_protocol_send_signal(dbus_protocol, signal);
+ pa_dbus_protocol_unref(dbus_protocol);
+ dbus_message_unref(signal);
+}
+
+void manager_get_revision(DBusConnection *conn, DBusMessage *msg, void *_u){
+ uint32_t rev=1;
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_UINT32, &rev);
+}
+
+static void get_sinks(pa_core *u, char ***names, unsigned *n_sinks){
+ void *iter = NULL;
+ struct userdata *sink_u = NULL;
+ uint32_t dummy;
+ pa_idxset *sink_list;
+ pa_assert(u);
+ pa_assert(names);
+ pa_assert(n_sinks);
+
+ pa_assert_se(sink_list = pa_shared_get(u, SINKLIST));
+ *n_sinks = (unsigned) pa_idxset_size(sink_list);
+ *names = *n_sinks > 0 ? pa_xnew0(char *,*n_sinks) : NULL;
+ for(uint32_t i = 0; i < *n_sinks; ++i){
+ sink_u = (struct userdata *) pa_idxset_iterate(sink_list, &iter, &dummy);
+ (*names)[i] = pa_xstrdup(sink_u->dbus_path);
+ }
+}
+
+void manager_get_sinks(DBusConnection *conn, DBusMessage *msg, void *_u){
+ unsigned n;
+ char **names = NULL;
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(_u);
+
+ get_sinks((pa_core *) _u, &names, &n);
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, names, n);
+ for(unsigned i = 0; i < n; ++i){
+ pa_xfree(names[i]);
+ }
+ pa_xfree(names);
+}
+
+static void get_profiles(pa_core *c, char ***names, unsigned *n){
+ char *name;
+ pa_database *database;
+ pa_datum key, next_key;
+ pa_strlist *head=NULL, *iter;
+ pa_bool_t done;
+ pa_assert_se(database = pa_shared_get(c, EQDB));
+
+ pa_assert(c);
+ pa_assert(names);
+ pa_assert(n);
+ done = !pa_database_first(database, &key, NULL);
+ *n = 0;
+ while(!done){
+ done = !pa_database_next(database, &key, &next_key, NULL);
+ name=pa_xmalloc(key.size + 1);
+ memcpy(name, key.data, key.size);
+ name[key.size] = '\0';
+ pa_datum_free(&key);
+ head = pa_strlist_prepend(head, name);
+ pa_xfree(name);
+ key = next_key;
+ (*n)++;
+ }
+ (*names) = *n > 0 ? pa_xnew0(char *, *n) : NULL;
+ iter=head;
+ for(unsigned i = 0; i < *n; ++i){
+ (*names)[*n - 1 - i] = pa_xstrdup(pa_strlist_data(iter));
+ iter = pa_strlist_next(iter);
+ }
+ pa_strlist_free(head);
+}
+
+void manager_get_profiles(DBusConnection *conn, DBusMessage *msg, void *_u){
+ char **names;
+ unsigned n;
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(_u);
+
+ get_profiles((pa_core *)_u, &names, &n);
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_STRING, names, n);
+ for(unsigned i = 0; i < n; ++i){
+ pa_xfree(names[i]);
+ }
+ pa_xfree(names);
+}
+
+void manager_get_all(DBusConnection *conn, DBusMessage *msg, void *_u){
+ pa_core *c;
+ char **names = NULL;
+ unsigned n;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter, dict_iter;
+ uint32_t rev;
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert_se(c = _u);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ rev = 1;
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, manager_handlers[MANAGER_HANDLER_REVISION].property_name, DBUS_TYPE_UINT32, &rev);
+
+ get_sinks(c, &names, &n);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter,manager_handlers[MANAGER_HANDLER_EQUALIZED_SINKS].property_name, DBUS_TYPE_OBJECT_PATH, names, n);
+ for(unsigned i = 0; i < n; ++i){
+ pa_xfree(names[i]);
+ }
+ pa_xfree(names);
+
+ get_profiles(c, &names, &n);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, manager_handlers[MANAGER_HANDLER_PROFILES].property_name, DBUS_TYPE_STRING, names, n);
+ for(unsigned i = 0; i < n; ++i){
+ pa_xfree(names[i]);
+ }
+ pa_xfree(names);
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+void equalizer_handle_seed_filter(DBusConnection *conn, DBusMessage *msg, void *_u) {
+ struct userdata *u = _u;
+ DBusError error;
+ DBusMessage *signal = NULL;
+ float *ys;
+ uint32_t *xs, channel, r_channel;
+ double *_ys, preamp;
+ unsigned x_npoints, y_npoints, a_i;
+ float *H;
+ pa_bool_t points_good = TRUE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+
+ dbus_error_init(&error);
+
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_UINT32, &channel,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_UINT32, &xs, &x_npoints,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_DOUBLE, &_ys, &y_npoints,
+ DBUS_TYPE_DOUBLE, &preamp,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel > u->channels){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "invalid channel: %d", channel);
+ dbus_error_free(&error);
+ return;
+ }
+ for(size_t i = 0; i < x_npoints; ++i){
+ if(xs[i] >= FILTER_SIZE(u)){
+ points_good = FALSE;
+ break;
+ }
+ }
+ if(!is_monotonic(xs, x_npoints) || !points_good){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "xs must be monotonic and 0<=x<=%ld", u->fft_size / 2);
+ dbus_error_free(&error);
+ return;
+ }else if(x_npoints != y_npoints || x_npoints < 2 || x_npoints > FILTER_SIZE(u)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "xs and ys must be the same length and 2<=l<=%ld!", FILTER_SIZE(u));
+ dbus_error_free(&error);
+ return;
+ }else if(xs[0] != 0 || xs[x_npoints - 1] != u->fft_size / 2){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "xs[0] must be 0 and xs[-1]=fft_size/2");
+ dbus_error_free(&error);
+ return;
+ }
+
+ ys = pa_xmalloc(x_npoints * sizeof(float));
+ for(uint32_t i = 0; i < x_npoints; ++i){
+ ys[i] = (float) _ys[i];
+ }
+ r_channel = channel == u->channels ? 0 : channel;
+ a_i = pa_aupdate_write_begin(u->a_H[r_channel]);
+ H = u->Hs[r_channel][a_i];
+ u->Xs[r_channel][a_i] = preamp;
+ interpolate(H, FILTER_SIZE(u), xs, ys, x_npoints);
+ fix_filter(H, u->fft_size);
+ if(channel == u->channels){
+ for(size_t c = 1; c < u->channels; ++c){
+ unsigned b_i = pa_aupdate_write_begin(u->a_H[c]);
+ float *H_p = u->Hs[c][b_i];
+ u->Xs[c][b_i] = preamp;
+ memcpy(H_p, H, FILTER_SIZE(u) * sizeof(float));
+ pa_aupdate_write_end(u->a_H[c]);
+ }
+ }
+ pa_aupdate_write_end(u->a_H[r_channel]);
+ pa_xfree(ys);
+
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ pa_assert_se((signal = dbus_message_new_signal(u->dbus_path, EQUALIZER_IFACE, equalizer_signals[EQUALIZER_SIGNAL_FILTER_CHANGED].name)));
+ pa_dbus_protocol_send_signal(u->dbus_protocol, signal);
+ dbus_message_unref(signal);
+}
+
+void equalizer_handle_get_filter_points(DBusConnection *conn, DBusMessage *msg, void *_u) {
+ struct userdata *u = (struct userdata *) _u;
+ uint32_t *xs, channel, r_channel;
+ double *ys, preamp;
+ unsigned x_npoints, a_i;
+ float *H;
+ pa_bool_t points_good=TRUE;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusError error;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+
+ dbus_error_init(&error);
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_UINT32, &channel,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_UINT32, &xs, &x_npoints,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel > u->channels){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "invalid channel: %d", channel);
+ dbus_error_free(&error);
+ return;
+ }
+
+ for(size_t i = 0; i < x_npoints; ++i){
+ if(xs[i] >= FILTER_SIZE(u)){
+ points_good=FALSE;
+ break;
+ }
+ }
+
+ if(x_npoints > FILTER_SIZE(u) || !points_good){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "xs indices/length must be <= %ld!", FILTER_SIZE(u));
+ dbus_error_free(&error);
+ return;
+ }
+
+ r_channel = channel == u->channels ? 0 : channel;
+ ys = pa_xmalloc(x_npoints * sizeof(double));
+ a_i = pa_aupdate_read_begin(u->a_H[r_channel]);
+ H = u->Hs[r_channel][a_i];
+ preamp = u->Xs[r_channel][a_i];
+ for(uint32_t i = 0; i < x_npoints; ++i){
+ ys[i] = H[xs[i]] * u->fft_size;
+ }
+ pa_aupdate_read_end(u->a_H[r_channel]);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+ dbus_message_iter_init_append(reply, &msg_iter);
+
+ pa_dbus_append_basic_array(&msg_iter, DBUS_TYPE_DOUBLE, ys, x_npoints);
+ pa_dbus_append_basic_variant(&msg_iter, DBUS_TYPE_DOUBLE, &preamp);
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+ pa_xfree(ys);
+}
+
+static void get_filter(struct userdata *u, size_t channel, double **H_, double *preamp){
+ float *H;
+ unsigned a_i;
+ size_t r_channel = channel == u->channels ? 0 : channel;
+ *H_ = pa_xnew0(double, FILTER_SIZE(u));
+ a_i = pa_aupdate_read_begin(u->a_H[r_channel]);
+ H = u->Hs[r_channel][a_i];
+ for(size_t i = 0;i < FILTER_SIZE(u); ++i){
+ (*H_)[i] = H[i] * u->fft_size;
+ }
+ *preamp = u->Xs[r_channel][a_i];
+
+ pa_aupdate_read_end(u->a_H[r_channel]);
+}
+
+void equalizer_handle_get_filter(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u;
+ unsigned n_coefs;
+ uint32_t channel;
+ double *H_, preamp;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusError error;
+ pa_assert_se(u = (struct userdata *) _u);
+ pa_assert(conn);
+ pa_assert(msg);
+
+ dbus_error_init(&error);
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_UINT32, &channel,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel > u->channels){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "invalid channel: %d", channel);
+ dbus_error_free(&error);
+ return;
+ }
+
+ n_coefs = CHANNEL_PROFILE_SIZE(u);
+ pa_assert(conn);
+ pa_assert(msg);
+ get_filter(u, channel, &H_, &preamp);
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+ dbus_message_iter_init_append(reply, &msg_iter);
+
+ pa_dbus_append_basic_array(&msg_iter, DBUS_TYPE_DOUBLE, H_, n_coefs);
+ pa_dbus_append_basic_variant(&msg_iter, DBUS_TYPE_DOUBLE, &preamp);
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+ pa_xfree(H_);
+}
+
+static void set_filter(struct userdata *u, size_t channel, double *H_, double preamp){
+ unsigned a_i;
+ size_t r_channel = channel == u->channels ? 0 : channel;
+ float *H;
+ //all channels
+ a_i = pa_aupdate_write_begin(u->a_H[r_channel]);
+ u->Xs[r_channel][a_i] = (float) preamp;
+ H = u->Hs[r_channel][a_i];
+ for(size_t i = 0; i < FILTER_SIZE(u); ++i){
+ H[i] = (float) H_[i];
+ }
+ fix_filter(H, u->fft_size);
+ if(channel == u->channels){
+ for(size_t c = 1; c < u->channels; ++c){
+ unsigned b_i = pa_aupdate_write_begin(u->a_H[c]);
+ u->Xs[c][b_i] = u->Xs[r_channel][a_i];
+ memcpy(u->Hs[c][b_i], u->Hs[r_channel][a_i], FILTER_SIZE(u) * sizeof(float));
+ pa_aupdate_write_end(u->a_H[c]);
+ }
+ }
+ pa_aupdate_write_end(u->a_H[r_channel]);
+}
+
+void equalizer_handle_set_filter(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u;
+ double *H, preamp;
+ uint32_t channel;
+ unsigned _n_coefs;
+ DBusMessage *signal = NULL;
+ DBusError error;
+ pa_assert_se(u = (struct userdata *) _u);
+ pa_assert(conn);
+ pa_assert(msg);
+
+ dbus_error_init(&error);
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_UINT32, &channel,
+ DBUS_TYPE_ARRAY, DBUS_TYPE_DOUBLE, &H, &_n_coefs,
+ DBUS_TYPE_DOUBLE, &preamp,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel > u->channels){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "invalid channel: %d", channel);
+ dbus_error_free(&error);
+ return;
+ }
+ if(_n_coefs != FILTER_SIZE(u)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "This filter takes exactly %ld coefficients, you gave %d", FILTER_SIZE(u), _n_coefs);
+ return;
+ }
+ set_filter(u, channel, H, preamp);
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ pa_assert_se((signal = dbus_message_new_signal(u->dbus_path, EQUALIZER_IFACE, equalizer_signals[EQUALIZER_SIGNAL_FILTER_CHANGED].name)));
+ pa_dbus_protocol_send_signal(u->dbus_protocol, signal);
+ dbus_message_unref(signal);
+}
+
+void equalizer_handle_save_profile(DBusConnection *conn, DBusMessage *msg, void *_u) {
+ struct userdata *u = (struct userdata *) _u;
+ char *name;
+ uint32_t channel, r_channel;
+ DBusMessage *signal = NULL;
+ DBusError error;
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+ dbus_error_init(&error);
+
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_UINT32, &channel,
+ DBUS_TYPE_STRING, &name,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel > u->channels){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "invalid channel: %d", channel);
+ dbus_error_free(&error);
+ return;
+ }
+ r_channel = channel == u->channels ? 0 : channel;
+ save_profile(u, r_channel, name);
+ pa_dbus_send_empty_reply(conn, msg);
+
+ pa_assert_se((signal = dbus_message_new_signal(MANAGER_PATH, MANAGER_IFACE, manager_signals[MANAGER_SIGNAL_PROFILES_CHANGED].name)));
+ pa_dbus_protocol_send_signal(u->dbus_protocol, signal);
+ dbus_message_unref(signal);
+}
+
+void equalizer_handle_load_profile(DBusConnection *conn, DBusMessage *msg, void *_u) {
+ struct userdata *u = (struct userdata *) _u;
+ char *name;
+ DBusError error;
+ uint32_t channel, r_channel;
+ const char *err_msg = NULL;
+ DBusMessage *signal = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+ dbus_error_init(&error);
+
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_UINT32, &channel,
+ DBUS_TYPE_STRING, &name,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel > u->channels){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "invalid channel: %d", channel);
+ dbus_error_free(&error);
+ return;
+ }
+ r_channel = channel == u->channels ? 0 : channel;
+
+ err_msg = load_profile(u, r_channel, name);
+ if(err_msg != NULL){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_FAILED, "error loading profile %s: %s", name, err_msg);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel == u->channels){
+ for(uint32_t c = 1; c < u->channels; ++c){
+ load_profile(u, c, name);
+ }
+ }
+ pa_dbus_send_empty_reply(conn, msg);
+
+ pa_assert_se((signal = dbus_message_new_signal(u->dbus_path, EQUALIZER_IFACE, equalizer_signals[EQUALIZER_SIGNAL_FILTER_CHANGED].name)));
+ pa_dbus_protocol_send_signal(u->dbus_protocol, signal);
+ dbus_message_unref(signal);
+}
+
+void equalizer_handle_save_state(DBusConnection *conn, DBusMessage *msg, void *_u) {
+ struct userdata *u = (struct userdata *) _u;
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+
+ save_state(u);
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+void equalizer_handle_get_profile_name(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u = (struct userdata *) _u;
+ DBusError error;
+ uint32_t channel, r_channel;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+ dbus_error_init(&error);
+
+ if(!dbus_message_get_args(msg, &error,
+ DBUS_TYPE_UINT32, &channel,
+ DBUS_TYPE_INVALID)){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "%s", error.message);
+ dbus_error_free(&error);
+ return;
+ }
+ if(channel > u->channels){
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "invalid channel: %d", channel);
+ dbus_error_free(&error);
+ return;
+ }
+ r_channel = channel == u->channels ? 0 : channel;
+ pa_assert(u->base_profiles[r_channel]);
+ pa_dbus_send_basic_value_reply(conn,msg, DBUS_TYPE_STRING, &u->base_profiles[r_channel]);
+}
+
+void equalizer_get_revision(DBusConnection *conn, DBusMessage *msg, void *_u){
+ uint32_t rev=1;
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_UINT32, &rev);
+}
+
+void equalizer_get_n_channels(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u;
+ uint32_t channels;
+ pa_assert_se(u = (struct userdata *) _u);
+ pa_assert(conn);
+ pa_assert(msg);
+
+ channels = (uint32_t) u->channels;
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &channels);
+}
+
+void equalizer_get_n_coefs(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u;
+ uint32_t n_coefs;
+ pa_assert_se(u = (struct userdata *) _u);
+ pa_assert(conn);
+ pa_assert(msg);
+
+ n_coefs = (uint32_t) CHANNEL_PROFILE_SIZE(u);
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &n_coefs);
+}
+
+void equalizer_get_sample_rate(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u;
+ uint32_t rate;
+ pa_assert_se(u = (struct userdata *) _u);
+ pa_assert(conn);
+ pa_assert(msg);
+
+ rate = (uint32_t) u->sink->sample_spec.rate;
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &rate);
+}
+
+void equalizer_get_filter_rate(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u;
+ uint32_t fft_size;
+ pa_assert_se(u = (struct userdata *) _u);
+ pa_assert(conn);
+ pa_assert(msg);
+
+ fft_size = (uint32_t) u->fft_size;
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &fft_size);
+}
+
+void equalizer_get_all(DBusConnection *conn, DBusMessage *msg, void *_u){
+ struct userdata *u;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter, dict_iter;
+ uint32_t rev, n_coefs, rate, fft_size, channels;
+
+ pa_assert_se(u = _u);
+ pa_assert(msg);
+
+ rev = 1;
+ n_coefs = (uint32_t) CHANNEL_PROFILE_SIZE(u);
+ rate = (uint32_t) u->sink->sample_spec.rate;
+ fft_size = (uint32_t) u->fft_size;
+ channels = (uint32_t) u->channels;
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, equalizer_handlers[EQUALIZER_HANDLER_REVISION].property_name, DBUS_TYPE_UINT32, &rev);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, equalizer_handlers[EQUALIZER_HANDLER_SAMPLERATE].property_name, DBUS_TYPE_UINT32, &rate);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, equalizer_handlers[EQUALIZER_HANDLER_FILTERSAMPLERATE].property_name, DBUS_TYPE_UINT32, &fft_size);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, equalizer_handlers[EQUALIZER_HANDLER_N_COEFS].property_name, DBUS_TYPE_UINT32, &n_coefs);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, equalizer_handlers[EQUALIZER_HANDLER_N_CHANNELS].property_name, DBUS_TYPE_UINT32, &channels);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+ dbus_message_unref(reply);
+}
diff --git a/src/modules/module-esound-compat-spawnfd.c b/src/modules/module-esound-compat-spawnfd.c
index 56cda4df..617d5a14 100644
--- a/src/modules/module-esound-compat-spawnfd.c
+++ b/src/modules/module-esound-compat-spawnfd.c
@@ -24,7 +24,6 @@
#endif
#include <unistd.h>
-#include <string.h>
#include <errno.h>
#include <pulsecore/core-error.h>
diff --git a/src/modules/module-esound-compat-spawnpid.c b/src/modules/module-esound-compat-spawnpid.c
index 5925f591..94ebdaad 100644
--- a/src/modules/module-esound-compat-spawnpid.c
+++ b/src/modules/module-esound-compat-spawnpid.c
@@ -25,13 +25,11 @@
#endif
#include <unistd.h>
-#include <string.h>
#include <errno.h>
#include <signal.h>
#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
-#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
diff --git a/src/modules/module-esound-sink.c b/src/modules/module-esound-sink.c
index 8cb25c51..d79054f8 100644
--- a/src/modules/module-esound-sink.c
+++ b/src/modules/module-esound-sink.c
@@ -24,26 +24,32 @@
#endif
#include <stdlib.h>
-#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
#include <string.h>
-#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
-#include <poll.h>
-#include <sys/socket.h>
+
+#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
+#endif
+
+#ifdef HAVE_NETINET_TCP_H
#include <netinet/tcp.h>
+#endif
+
+#ifdef HAVE_SYS_IOCTL_H
#include <sys/ioctl.h>
+#endif
#ifdef HAVE_LINUX_SOCKIOS_H
#include <linux/sockios.h>
#endif
-#include <pulse/xmalloc.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
+#include <pulse/xmalloc.h>
+#include <pulsecore/socket.h>
#include <pulsecore/core-error.h>
#include <pulsecore/iochannel.h>
#include <pulsecore/sink.h>
@@ -57,8 +63,9 @@
#include <pulsecore/thread-mq.h>
#include <pulsecore/thread.h>
#include <pulsecore/time-smoother.h>
-#include <pulsecore/rtclock.h>
#include <pulsecore/socket-util.h>
+#include <pulsecore/rtpoll.h>
+#include <pulsecore/poll.h>
#include "module-esound-sink-symdef.h"
@@ -145,14 +152,14 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
case PA_SINK_SUSPENDED:
pa_assert(PA_SINK_IS_OPENED(u->sink->thread_info.state));
- pa_smoother_pause(u->smoother, pa_rtclock_usec());
+ pa_smoother_pause(u->smoother, pa_rtclock_now());
break;
case PA_SINK_IDLE:
case PA_SINK_RUNNING:
if (u->sink->thread_info.state == PA_SINK_SUSPENDED)
- pa_smoother_resume(u->smoother, pa_rtclock_usec(), TRUE);
+ pa_smoother_resume(u->smoother, pa_rtclock_now(), TRUE);
break;
@@ -167,7 +174,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
case PA_SINK_MESSAGE_GET_LATENCY: {
pa_usec_t w, r;
- r = pa_smoother_get(u->smoother, pa_rtclock_usec());
+ r = pa_smoother_get(u->smoother, pa_rtclock_now());
w = pa_bytes_to_usec((uint64_t) u->offset + u->memchunk.length, &u->sink->sample_spec);
*((pa_usec_t*) data) = w > r ? w - r : 0;
@@ -200,9 +207,8 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
- pa_smoother_set_time_offset(u->smoother, pa_rtclock_usec());
+ pa_smoother_set_time_offset(u->smoother, pa_rtclock_now());
for (;;) {
int ret;
@@ -295,7 +301,7 @@ static void thread_func(void *userdata) {
else
usec = 0;
- pa_smoother_put(u->smoother, pa_rtclock_usec(), usec);
+ pa_smoother_put(u->smoother, pa_rtclock_now(), usec);
}
/* Hmm, nothing to do. Let's sleep */
@@ -608,7 +614,7 @@ int pa__init(pa_module*m) {
pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
pa_sink_set_rtpoll(u->sink, u->rtpoll);
- if (!(u->client = pa_socket_client_new_string(u->core->mainloop, espeaker, ESD_DEFAULT_PORT))) {
+ if (!(u->client = pa_socket_client_new_string(u->core->mainloop, TRUE, espeaker, ESD_DEFAULT_PORT))) {
pa_log("Failed to connect to server.");
goto fail;
}
@@ -628,7 +634,7 @@ int pa__init(pa_module*m) {
/* Reserve space for the response */
u->read_data = pa_xmalloc(u->read_length = sizeof(int32_t));
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("esound-sink", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
diff --git a/src/modules/module-filter-apply.c b/src/modules/module-filter-apply.c
new file mode 100644
index 00000000..c742373a
--- /dev/null
+++ b/src/modules/module-filter-apply.c
@@ -0,0 +1,600 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2011 Colin Guthrie
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/timeval.h>
+#include <pulse/rtclock.h>
+#include <pulse/i18n.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/macro.h>
+#include <pulsecore/hashmap.h>
+#include <pulsecore/hook-list.h>
+#include <pulsecore/core.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/sink-input.h>
+#include <pulsecore/modargs.h>
+
+#include "module-filter-apply-symdef.h"
+
+#define PA_PROP_FILTER_APPLY_MOVING "filter.apply.moving"
+
+PA_MODULE_AUTHOR("Colin Guthrie");
+PA_MODULE_DESCRIPTION("Load filter sinks automatically when needed");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_USAGE(_("autoclean=<automatically unload unused filters?>"));
+
+static const char* const valid_modargs[] = {
+ "autoclean",
+ NULL
+};
+
+#define DEFAULT_AUTOCLEAN TRUE
+#define HOUSEKEEPING_INTERVAL (10 * PA_USEC_PER_SEC)
+
+struct filter {
+ char *name;
+ uint32_t module_index;
+ pa_bool_t is_sink;
+ pa_object *parent_obj; /* source or sink that the filter is connected to */
+ pa_object *obj; /* source or sink of the filter */
+};
+
+struct userdata {
+ pa_core *core;
+ pa_hashmap *filters;
+ pa_hook_slot
+ *sink_input_put_slot,
+ *sink_input_move_finish_slot,
+ *sink_input_proplist_slot,
+ *sink_input_unlink_slot,
+ *sink_unlink_slot,
+ *source_output_put_slot,
+ *source_output_move_finish_slot,
+ *source_output_proplist_slot,
+ *source_output_unlink_slot,
+ *source_unlink_slot;
+ pa_bool_t autoclean;
+ pa_time_event *housekeeping_time_event;
+};
+
+static unsigned filter_hash(const void *p) {
+ const struct filter *f = p;
+
+ if (f->is_sink)
+ return (unsigned) (PA_SINK(f->parent_obj)->index + pa_idxset_string_hash_func(f->name));
+ else
+ return (unsigned) ((PA_SOURCE(f->parent_obj)->index << 16) + pa_idxset_string_hash_func(f->name));
+}
+
+static int filter_compare(const void *a, const void *b) {
+ const struct filter *fa = a, *fb = b;
+ int r;
+
+ if (fa->parent_obj != fb->parent_obj)
+ return 1;
+ if ((r = strcmp(fa->name, fb->name)))
+ return r;
+
+ return 0;
+}
+
+static struct filter *filter_new(const char *name, pa_object* parent_obj, pa_bool_t is_sink) {
+ struct filter *f;
+
+ f = pa_xnew(struct filter, 1);
+ f->name = pa_xstrdup(name);
+ pa_assert_se(f->parent_obj = parent_obj);
+ f->is_sink = is_sink;
+ f->module_index = PA_INVALID_INDEX;
+ f->obj = NULL;
+ return f;
+}
+
+static void filter_free(struct filter *f) {
+ pa_assert(f);
+
+ pa_xfree(f->name);
+ pa_xfree(f);
+}
+
+static const char* should_filter(pa_object *o, pa_bool_t is_sink_input) {
+ const char *apply;
+ pa_proplist *pl;
+
+ if (is_sink_input)
+ pl = PA_SINK_INPUT(o)->proplist;
+ else
+ pl = PA_SOURCE_OUTPUT(o)->proplist;
+
+ /* If the stream doesn't what any filter, then let it be. */
+ if ((apply = pa_proplist_gets(pl, PA_PROP_FILTER_APPLY)) && !pa_streq(apply, "")) {
+ const char* suppress = pa_proplist_gets(pl, PA_PROP_FILTER_SUPPRESS);
+
+ if (!suppress || !pa_streq(suppress, apply))
+ return apply;
+ }
+
+ return NULL;
+}
+
+static pa_bool_t nothing_attached(pa_object *obj, pa_bool_t is_sink)
+{
+ if (is_sink)
+ return pa_idxset_isempty(PA_SINK(obj)->inputs);
+ else
+ return pa_idxset_isempty(PA_SOURCE(obj)->outputs);
+}
+
+static void housekeeping_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *t, void *userdata) {
+ struct userdata *u = userdata;
+ struct filter *filter;
+ void *state;
+
+ pa_assert(a);
+ pa_assert(e);
+ pa_assert(u);
+
+ pa_assert(e == u->housekeeping_time_event);
+ u->core->mainloop->time_free(u->housekeeping_time_event);
+ u->housekeeping_time_event = NULL;
+
+ PA_HASHMAP_FOREACH(filter, u->filters, state) {
+ if (filter->obj && nothing_attached(filter->obj, filter->is_sink)) {
+ uint32_t idx;
+
+ pa_log_debug("Detected filter %s as no longer used. Unloading.", filter->name);
+ idx = filter->module_index;
+ pa_hashmap_remove(u->filters, filter);
+ filter_free(filter);
+ pa_module_unload_request_by_index(u->core, idx, TRUE);
+ }
+ }
+
+ pa_log_info("Housekeeping Done.");
+}
+
+static void trigger_housekeeping(struct userdata *u) {
+ pa_assert(u);
+
+ if (!u->autoclean)
+ return;
+
+ if (u->housekeeping_time_event)
+ return;
+
+ u->housekeeping_time_event = pa_core_rttime_new(u->core, pa_rtclock_now() + HOUSEKEEPING_INTERVAL, housekeeping_time_callback, u);
+}
+
+static int do_move(pa_object *obj, pa_object *parent, pa_bool_t restore, pa_bool_t is_input) {
+ if (is_input)
+ return pa_sink_input_move_to(PA_SINK_INPUT(obj), PA_SINK(parent), restore);
+ else
+ return pa_source_output_move_to(PA_SOURCE_OUTPUT(obj), PA_SOURCE(parent), restore);
+}
+
+static void move_object_for_filter(pa_object *o, struct filter* filter, pa_bool_t restore, pa_bool_t is_sink_input) {
+ pa_object *parent;
+ pa_proplist *pl;
+ const char *name;
+
+ pa_assert(o);
+ pa_assert(filter);
+
+ pa_assert_se(parent = (restore ? filter->parent_obj : filter->obj));
+
+ if (is_sink_input) {
+ pl = PA_SINK_INPUT(o)->proplist;
+ name = PA_SINK(parent)->name;
+ } else {
+ pl = PA_SOURCE_OUTPUT(o)->proplist;
+ name = PA_SOURCE(parent)->name;
+ }
+
+ pa_proplist_sets(pl, PA_PROP_FILTER_APPLY_MOVING, "1");
+
+ if (do_move(o, parent, FALSE, is_sink_input) < 0)
+ pa_log_info("Failed to move %s for \"%s\" to <%s>.", is_sink_input ? "sink-input" : "source-output",
+ pa_strnull(pa_proplist_gets(pl, PA_PROP_APPLICATION_NAME)), name);
+ else
+ pa_log_info("Sucessfully moved %s for \"%s\" to <%s>.", is_sink_input ? "sink-input" : "source-output",
+ pa_strnull(pa_proplist_gets(pl, PA_PROP_APPLICATION_NAME)), name);
+
+ pa_proplist_unset(pl, PA_PROP_FILTER_APPLY_MOVING);
+}
+
+static void find_filters_for_module(struct userdata *u, pa_module *m, const char *name) {
+ uint32_t idx;
+ pa_sink *sink;
+ pa_source *source;
+ struct filter *fltr;
+
+ PA_IDXSET_FOREACH(sink, u->core->sinks, idx) {
+ if (sink->module == m) {
+ pa_assert(sink->input_to_master != NULL);
+
+ fltr = filter_new(name, PA_OBJECT(sink->input_to_master->sink), TRUE);
+ fltr->module_index = m->index;
+ fltr->obj = PA_OBJECT(sink);
+
+ pa_hashmap_put(u->filters, fltr, fltr);
+ }
+ }
+
+ PA_IDXSET_FOREACH(source, u->core->sources, idx) {
+ if (source->module == m && !source->monitor_of) {
+ pa_assert(source->output_from_master != NULL);
+
+ fltr = filter_new(name, PA_OBJECT(source->output_from_master->source), FALSE);
+ fltr->module_index = m->index;
+ fltr->obj = PA_OBJECT(source);
+
+ pa_hashmap_put(u->filters, fltr, fltr);
+ }
+ }
+}
+
+static pa_bool_t can_unload_module(struct userdata *u, uint32_t idx) {
+ void *state;
+ struct filter *filter;
+
+ /* Check if any other struct filters point to the same module */
+ PA_HASHMAP_FOREACH(filter, u->filters, state) {
+ if (filter->module_index == idx && !nothing_attached(filter->obj, pa_sink_isinstance(filter->obj)))
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+static pa_hook_result_t process(struct userdata *u, pa_object *o, pa_bool_t is_sink_input) {
+ const char *want;
+ pa_bool_t done_something = FALSE;
+
+ pa_object *parent; /* source/sink of the given source-output/sink-input */
+ const char *parent_name;
+ pa_module *module;
+
+ if (is_sink_input) {
+ parent = PA_OBJECT(PA_SINK_INPUT(o)->sink);
+ parent_name = PA_SINK_INPUT(o)->sink->name;
+ module = PA_SINK_INPUT(o)->sink->module;
+ } else {
+ parent = PA_OBJECT(PA_SOURCE_OUTPUT(o)->source);
+ parent_name = PA_SOURCE_OUTPUT(o)->source->name;
+ module = PA_SOURCE_OUTPUT(o)->source->module;
+ }
+
+ /* If there is no sink yet, we can't do much */
+ if (!parent)
+ return PA_HOOK_OK;
+
+ /* If the stream doesn't what any filter, then let it be. */
+ if ((want = should_filter(o, is_sink_input))) {
+ char *module_name;
+ struct filter *fltr, *filter;
+
+ /* We need to ensure the SI is playing on a sink of this type
+ * attached to the sink it's "officially" playing on */
+
+ if (!module)
+ return PA_HOOK_OK;
+
+ module_name = pa_sprintf_malloc("module-%s", want);
+ if (pa_streq(module->name, module_name)) {
+ pa_log_debug("Stream appears to be playing on an appropriate sink already. Ignoring.");
+ pa_xfree(module_name);
+ return PA_HOOK_OK;
+ }
+
+ fltr = filter_new(want, parent, is_sink_input);
+
+ if (!(filter = pa_hashmap_get(u->filters, fltr))) {
+ char *args;
+ pa_module *m;
+
+ args = pa_sprintf_malloc("autoloaded=1 %s_master=%s", is_sink_input ? "sink" : "source", parent_name);
+ pa_log_debug("Loading %s with arguments '%s'", module_name, args);
+
+ if ((m = pa_module_load(u->core, module_name, args))) {
+ find_filters_for_module(u, m, want);
+ filter = pa_hashmap_get(u->filters, fltr);
+ done_something = TRUE;
+ }
+ pa_xfree(args);
+ }
+
+ pa_xfree(fltr);
+
+ if (!filter) {
+ pa_log("Unable to load %s for <%s>", module_name, parent_name);
+ pa_xfree(module_name);
+ return PA_HOOK_OK;
+ }
+ pa_xfree(module_name);
+
+ if (filter->obj) {
+ /* We can move the sink_input now as the know the destination.
+ * If this isn't true, we will do it later when the sink appears. */
+ move_object_for_filter(o, filter, FALSE, is_sink_input);
+ done_something = TRUE;
+ }
+ } else {
+ void *state;
+ struct filter *filter = NULL;
+
+ /* We do not want to filter... but are we already filtered?
+ * This can happen if an input's proplist changes */
+ PA_HASHMAP_FOREACH(filter, u->filters, state) {
+ if (parent == filter->obj) {
+ move_object_for_filter(o, filter, TRUE, is_sink_input);
+ done_something = TRUE;
+ break;
+ }
+ }
+ }
+
+ if (done_something)
+ trigger_housekeeping(u);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_input_put_cb(pa_core *core, pa_sink_input *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_sink_input_assert_ref(i);
+
+ return process(u, PA_OBJECT(i), TRUE);
+}
+
+static pa_hook_result_t sink_input_move_finish_cb(pa_core *core, pa_sink_input *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_sink_input_assert_ref(i);
+
+ if (pa_proplist_gets(i->proplist, PA_PROP_FILTER_APPLY_MOVING))
+ return PA_HOOK_OK;
+
+ return process(u, PA_OBJECT(i), TRUE);
+}
+
+static pa_hook_result_t sink_input_proplist_cb(pa_core *core, pa_sink_input *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_sink_input_assert_ref(i);
+
+ return process(u, PA_OBJECT(i), TRUE);
+}
+
+static pa_hook_result_t sink_input_unlink_cb(pa_core *core, pa_sink_input *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_sink_input_assert_ref(i);
+
+ pa_assert(u);
+
+ if (pa_hashmap_size(u->filters) > 0)
+ trigger_housekeeping(u);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_unlink_cb(pa_core *core, pa_sink *sink, struct userdata *u) {
+ void *state;
+ struct filter *filter = NULL;
+
+ pa_core_assert_ref(core);
+ pa_sink_assert_ref(sink);
+ pa_assert(u);
+
+ /* If either the parent or the sink we've loaded disappears,
+ * we should remove it from our hashmap */
+ PA_HASHMAP_FOREACH(filter, u->filters, state) {
+ if (filter->parent_obj == PA_OBJECT(sink) || filter->obj == PA_OBJECT(sink)) {
+ uint32_t idx;
+
+ /* Attempt to rescue any streams to the parent sink as this is likely
+ * the best course of action (as opposed to a generic rescue via
+ * module-rescue-streams */
+ if (filter->obj == PA_OBJECT(sink)) {
+ pa_sink_input *i;
+
+ PA_IDXSET_FOREACH(i, sink->inputs, idx)
+ move_object_for_filter(PA_OBJECT(i), filter, TRUE, TRUE);
+ }
+
+ idx = filter->module_index;
+ pa_hashmap_remove(u->filters, filter);
+ filter_free(filter);
+
+ if (can_unload_module(u, idx))
+ pa_module_unload_request_by_index(u->core, idx, TRUE);
+ }
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_output_put_cb(pa_core *core, pa_source_output *o, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_source_output_assert_ref(o);
+
+ return process(u, PA_OBJECT(o), FALSE);
+}
+
+static pa_hook_result_t source_output_move_finish_cb(pa_core *core, pa_source_output *o, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_source_output_assert_ref(o);
+
+ if (pa_proplist_gets(o->proplist, PA_PROP_FILTER_APPLY_MOVING))
+ return PA_HOOK_OK;
+
+ return process(u, PA_OBJECT(o), FALSE);
+}
+
+static pa_hook_result_t source_output_proplist_cb(pa_core *core, pa_source_output *o, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_source_output_assert_ref(o);
+
+ return process(u, PA_OBJECT(o), FALSE);
+}
+
+static pa_hook_result_t source_output_unlink_cb(pa_core *core, pa_source_output *o, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_source_output_assert_ref(o);
+
+ pa_assert(u);
+
+ if (pa_hashmap_size(u->filters) > 0)
+ trigger_housekeeping(u);
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_unlink_cb(pa_core *core, pa_source *source, struct userdata *u) {
+ void *state;
+ struct filter *filter = NULL;
+
+ pa_core_assert_ref(core);
+ pa_source_assert_ref(source);
+ pa_assert(u);
+
+ /* If either the parent or the source we've loaded disappears,
+ * we should remove it from our hashmap */
+ PA_HASHMAP_FOREACH(filter, u->filters, state) {
+ if (filter->parent_obj == PA_OBJECT(source) || filter->obj == PA_OBJECT(source)) {
+ uint32_t idx;
+
+ /* Attempt to rescue any streams to the parent source as this is likely
+ * the best course of action (as opposed to a generic rescue via
+ * module-rescue-streams */
+ if (filter->obj == PA_OBJECT(source)) {
+ pa_source_output *o;
+
+ PA_IDXSET_FOREACH(o, source->outputs, idx)
+ move_object_for_filter(PA_OBJECT(o), filter, TRUE, FALSE);
+ }
+
+ idx = filter->module_index;
+ pa_hashmap_remove(u->filters, filter);
+ filter_free(filter);
+
+ if (can_unload_module(u, idx))
+ pa_module_unload_request_by_index(u->core, idx, TRUE);
+ }
+ }
+
+ return PA_HOOK_OK;
+}
+
+int pa__init(pa_module *m) {
+ pa_modargs *ma = NULL;
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+
+ u->core = m->core;
+
+ u->autoclean = DEFAULT_AUTOCLEAN;
+ if (pa_modargs_get_value_boolean(ma, "autoclean", &u->autoclean) < 0) {
+ pa_log("Failed to parse autoclean value");
+ goto fail;
+ }
+
+ u->filters = pa_hashmap_new(filter_hash, filter_compare);
+
+ u->sink_input_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_PUT], PA_HOOK_LATE, (pa_hook_cb_t) sink_input_put_cb, u);
+ u->sink_input_move_finish_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_MOVE_FINISH], PA_HOOK_LATE, (pa_hook_cb_t) sink_input_move_finish_cb, u);
+ u->sink_input_proplist_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_PROPLIST_CHANGED], PA_HOOK_LATE, (pa_hook_cb_t) sink_input_proplist_cb, u);
+ u->sink_input_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) sink_input_unlink_cb, u);
+ u->sink_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) sink_unlink_cb, u);
+ u->source_output_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_PUT], PA_HOOK_LATE, (pa_hook_cb_t) source_output_put_cb, u);
+ u->source_output_move_finish_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_MOVE_FINISH], PA_HOOK_LATE, (pa_hook_cb_t) source_output_move_finish_cb, u);
+ u->source_output_proplist_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_PROPLIST_CHANGED], PA_HOOK_LATE, (pa_hook_cb_t) source_output_proplist_cb, u);
+ u->source_output_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) source_output_unlink_cb, u);
+ u->source_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) source_unlink_cb, u);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ pa__done(m);
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ return -1;
+}
+
+void pa__done(pa_module *m) {
+ struct userdata* u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->sink_input_put_slot)
+ pa_hook_slot_free(u->sink_input_put_slot);
+ if (u->sink_input_move_finish_slot)
+ pa_hook_slot_free(u->sink_input_move_finish_slot);
+ if (u->sink_input_proplist_slot)
+ pa_hook_slot_free(u->sink_input_proplist_slot);
+ if (u->sink_input_unlink_slot)
+ pa_hook_slot_free(u->sink_input_unlink_slot);
+ if (u->sink_unlink_slot)
+ pa_hook_slot_free(u->sink_unlink_slot);
+ if (u->source_output_put_slot)
+ pa_hook_slot_free(u->source_output_put_slot);
+ if (u->source_output_move_finish_slot)
+ pa_hook_slot_free(u->source_output_move_finish_slot);
+ if (u->source_output_proplist_slot)
+ pa_hook_slot_free(u->source_output_proplist_slot);
+ if (u->source_output_unlink_slot)
+ pa_hook_slot_free(u->source_output_unlink_slot);
+ if (u->source_unlink_slot)
+ pa_hook_slot_free(u->source_unlink_slot);
+
+ if (u->housekeeping_time_event)
+ u->core->mainloop->time_free(u->housekeeping_time_event);
+
+ if (u->filters) {
+ struct filter *f;
+
+ while ((f = pa_hashmap_steal_first(u->filters))) {
+ pa_module_unload_request_by_index(u->core, f->module_index, TRUE);
+ filter_free(f);
+ }
+
+ pa_hashmap_free(u->filters, NULL, NULL);
+ }
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-filter-heuristics.c b/src/modules/module-filter-heuristics.c
new file mode 100644
index 00000000..222787fc
--- /dev/null
+++ b/src/modules/module-filter-heuristics.c
@@ -0,0 +1,217 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2011 Colin Guthrie
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/macro.h>
+#include <pulsecore/hook-list.h>
+#include <pulsecore/core.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/sink-input.h>
+#include <pulsecore/modargs.h>
+
+#include "module-filter-heuristics-symdef.h"
+
+#define PA_PROP_FILTER_APPLY_MOVING "filter.apply.moving"
+#define PA_PROP_FILTER_HEURISTICS "filter.heuristics"
+
+PA_MODULE_AUTHOR("Colin Guthrie");
+PA_MODULE_DESCRIPTION("Detect when various filters are desirable");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+
+static const char* const valid_modargs[] = {
+ NULL
+};
+
+struct userdata {
+ pa_core *core;
+ pa_hook_slot
+ *sink_input_put_slot,
+ *sink_input_move_finish_slot,
+ *source_output_put_slot,
+ *source_output_move_finish_slot;
+};
+
+static pa_bool_t role_match(pa_proplist *proplist, const char *role) {
+ const char *ir;
+ char *r;
+ const char *state = NULL;
+
+ if (!(ir = pa_proplist_gets(proplist, PA_PROP_DEVICE_INTENDED_ROLES)))
+ return FALSE;
+
+ while ((r = pa_split_spaces(ir, &state))) {
+
+ if (pa_streq(role, r)) {
+ pa_xfree(r);
+ return TRUE;
+ }
+
+ pa_xfree(r);
+ }
+
+ return FALSE;
+}
+
+static pa_hook_result_t process(struct userdata *u, pa_object *o, pa_bool_t is_sink_input) {
+ const char *want, *stream_role;
+ pa_proplist *pl, *parent_pl;
+
+ if (is_sink_input) {
+ pl = PA_SINK_INPUT(o)->proplist;
+ parent_pl = PA_SINK_INPUT(o)->sink->proplist;
+ } else {
+ pl = PA_SOURCE_OUTPUT(o)->proplist;
+ parent_pl = PA_SOURCE_OUTPUT(o)->source->proplist;
+ }
+
+ /* If the stream already specifies what it must have, then let it be. */
+ if (!pa_proplist_gets(pl, PA_PROP_FILTER_HEURISTICS) && pa_proplist_gets(pl, PA_PROP_FILTER_APPLY))
+ return PA_HOOK_OK;
+
+ want = pa_proplist_gets(pl, PA_PROP_FILTER_WANT);
+ if (!want) {
+ /* This is a phone stream, maybe we want echo cancellation */
+ if ((stream_role = pa_proplist_gets(pl, PA_PROP_MEDIA_ROLE)) && pa_streq(stream_role, "phone"))
+ want = "echo-cancel";
+ }
+
+ /* On phone sinks, make sure we're not applying echo cancellation */
+ if (role_match(parent_pl, "phone")) {
+ const char *apply = pa_proplist_gets(pl, PA_PROP_FILTER_APPLY);
+
+ if (apply && pa_streq(apply, "echo-cancel")) {
+ pa_proplist_unset(pl, PA_PROP_FILTER_APPLY);
+ pa_proplist_unset(pl, PA_PROP_FILTER_HEURISTICS);
+ }
+
+ return PA_HOOK_OK;
+ }
+
+ if (want) {
+ /* There's a filter that we want, ask module-filter-apply to apply it, and remember that we're managing filter.apply */
+ pa_proplist_sets(pl, PA_PROP_FILTER_APPLY, want);
+ pa_proplist_sets(pl, PA_PROP_FILTER_HEURISTICS, "1");
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_input_put_cb(pa_core *core, pa_sink_input *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_sink_input_assert_ref(i);
+ pa_assert(u);
+
+ return process(u, PA_OBJECT(i), TRUE);
+}
+
+static pa_hook_result_t sink_input_move_finish_cb(pa_core *core, pa_sink_input *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_sink_input_assert_ref(i);
+ pa_assert(u);
+
+ /* module-filter-apply triggered this move, ignore */
+ if (pa_proplist_gets(i->proplist, PA_PROP_FILTER_APPLY_MOVING))
+ return PA_HOOK_OK;
+
+ return process(u, PA_OBJECT(i), TRUE);
+}
+
+static pa_hook_result_t source_output_put_cb(pa_core *core, pa_source_output *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_source_output_assert_ref(i);
+ pa_assert(u);
+
+ return process(u, PA_OBJECT(i), FALSE);
+}
+
+static pa_hook_result_t source_output_move_finish_cb(pa_core *core, pa_source_output *i, struct userdata *u) {
+ pa_core_assert_ref(core);
+ pa_source_output_assert_ref(i);
+ pa_assert(u);
+
+ /* module-filter-apply triggered this move, ignore */
+ if (pa_proplist_gets(i->proplist, PA_PROP_FILTER_APPLY_MOVING))
+ return PA_HOOK_OK;
+
+ return process(u, PA_OBJECT(i), FALSE);
+}
+
+int pa__init(pa_module *m) {
+ pa_modargs *ma = NULL;
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew(struct userdata, 1);
+
+ u->core = m->core;
+
+ u->sink_input_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_PUT], PA_HOOK_LATE-1, (pa_hook_cb_t) sink_input_put_cb, u);
+ u->sink_input_move_finish_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_MOVE_FINISH], PA_HOOK_LATE-1, (pa_hook_cb_t) sink_input_move_finish_cb, u);
+ u->source_output_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_PUT], PA_HOOK_LATE-1, (pa_hook_cb_t) source_output_put_cb, u);
+ u->source_output_move_finish_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_MOVE_FINISH], PA_HOOK_LATE-1, (pa_hook_cb_t) source_output_move_finish_cb, u);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ pa__done(m);
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ return -1;
+
+
+}
+
+void pa__done(pa_module *m) {
+ struct userdata* u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->sink_input_put_slot)
+ pa_hook_slot_free(u->sink_input_put_slot);
+ if (u->sink_input_move_finish_slot)
+ pa_hook_slot_free(u->sink_input_move_finish_slot);
+ if (u->source_output_put_slot)
+ pa_hook_slot_free(u->source_output_put_slot);
+ if (u->source_output_move_finish_slot)
+ pa_hook_slot_free(u->source_output_move_finish_slot);
+
+ pa_xfree(u);
+
+}
diff --git a/src/modules/module-hal-detect-compat.c b/src/modules/module-hal-detect-compat.c
new file mode 100644
index 00000000..14cf8143
--- /dev/null
+++ b/src/modules/module-hal-detect-compat.c
@@ -0,0 +1,84 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Lennart Poettering
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/module.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/core-util.h>
+
+#include "module-hal-detect-symdef.h"
+
+PA_MODULE_AUTHOR("Lennart Poettering");
+PA_MODULE_DESCRIPTION("Compatibility module");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_DEPRECATED("Please use module-udev-detect instead of module-hal-detect!");
+
+static const char* const valid_modargs[] = {
+ "api",
+ "tsched",
+ "subdevices",
+ NULL,
+};
+
+int pa__init(pa_module*m) {
+ pa_modargs *ma = NULL;
+ pa_bool_t tsched = TRUE;
+ pa_module *n;
+ char *t;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "tsched", &tsched) < 0) {
+ pa_log("tsched= expects boolean arguments");
+ goto fail;
+ }
+
+ pa_log_warn("We will now load module-udev-detect. Please make sure to remove module-hal-detect from your configuration.");
+
+ t = pa_sprintf_malloc("tsched=%s", pa_yes_no(tsched));
+ n = pa_module_load(m->core, "module-udev-detect", t);
+ pa_xfree(t);
+
+ if (n)
+ pa_module_unload_request(m, TRUE);
+
+ pa_modargs_free(ma);
+
+ return n ? 0 : -1;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ return -1;
+}
diff --git a/src/modules/module-hal-detect.c b/src/modules/module-hal-detect.c
index b6139e43..62f0f203 100644
--- a/src/modules/module-hal-detect.c
+++ b/src/modules/module-hal-detect.c
@@ -31,19 +31,15 @@
#include <errno.h>
#include <stdlib.h>
#include <sys/types.h>
-#include <sys/stat.h>
#include <pulse/xmalloc.h>
-#include <pulse/timeval.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
#include <pulsecore/log.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/idxset.h>
#include <pulsecore/core-util.h>
#include <pulsecore/namereg.h>
-#include <pulsecore/core-scache.h>
#include <pulsecore/modargs.h>
#include <pulsecore/dbus-shared.h>
@@ -55,15 +51,18 @@ PA_MODULE_AUTHOR("Shahms King");
PA_MODULE_DESCRIPTION("Detect available audio hardware and load matching drivers");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
-#if defined(HAVE_ALSA) && defined(HAVE_OSS)
+#if defined(HAVE_ALSA) && defined(HAVE_OSS_OUTPUT)
PA_MODULE_USAGE("api=<alsa or oss> "
- "tsched=<enable system timer based scheduling mode?>");
+ "tsched=<enable system timer based scheduling mode?> "
+ "subdevices=<init all subdevices>");
#elif defined(HAVE_ALSA)
PA_MODULE_USAGE("api=<alsa> "
"tsched=<enable system timer based scheduling mode?>");
-#elif defined(HAVE_OSS)
-PA_MODULE_USAGE("api=<oss>");
+#elif defined(HAVE_OSS_OUTPUT)
+PA_MODULE_USAGE("api=<oss> "
+ "subdevices=<init all subdevices>");
#endif
+PA_MODULE_DEPRECATED("Please use module-udev-detect instead of module-hal-detect!");
struct device {
char *udi, *originating_udi;
@@ -81,6 +80,10 @@ struct userdata {
#ifdef HAVE_ALSA
pa_bool_t use_tsched;
#endif
+#ifdef HAVE_OSS_OUTPUT
+ pa_bool_t init_subdevs;
+#endif
+ pa_bool_t filter_added:1;
};
#define CAPABILITY_ALSA "alsa"
@@ -91,6 +94,9 @@ static const char* const valid_modargs[] = {
#ifdef HAVE_ALSA
"tsched",
#endif
+#ifdef HAVE_OSS_OUTPUT
+ "subdevices",
+#endif
NULL
};
@@ -232,7 +238,7 @@ static int hal_device_load_alsa(struct userdata *u, const char *udi, struct devi
goto fail;
card_name = pa_sprintf_malloc("alsa_card.%s", strip_udi(originating_udi));
- args = pa_sprintf_malloc("device_id=%u name=%s card_name=%s tsched=%i", card, strip_udi(originating_udi), card_name, (int) u->use_tsched);
+ args = pa_sprintf_malloc("device_id=%u name=\"%s\" card_name=\"%s\" tsched=%i card_properties=\"module-hal-detect.discovered=1\"", card, strip_udi(originating_udi), card_name, (int) u->use_tsched);
pa_log_debug("Loading module-alsa-card with arguments '%s'", args);
m = pa_module_load(u->core, "module-alsa-card", args);
@@ -261,9 +267,9 @@ fail:
#endif
-#ifdef HAVE_OSS
+#ifdef HAVE_OSS_OUTPUT
-static pa_bool_t hal_oss_device_is_pcm(LibHalContext *context, const char *udi) {
+static pa_bool_t hal_oss_device_is_pcm(LibHalContext *context, const char *udi, pa_bool_t init_subdevices) {
char *class = NULL, *dev = NULL, *e;
int device;
pa_bool_t r = FALSE;
@@ -293,7 +299,7 @@ static pa_bool_t hal_oss_device_is_pcm(LibHalContext *context, const char *udi)
/* We only care for the main device */
device = libhal_device_get_property_int(context, udi, "oss.device", &error);
- if (dbus_error_is_set(&error) || device != 0)
+ if (dbus_error_is_set(&error) || (device != 0 && init_subdevices == FALSE))
goto finish;
r = TRUE;
@@ -323,7 +329,7 @@ static int hal_device_load_oss(struct userdata *u, const char *udi, struct devic
pa_assert(d);
/* We only care for OSS PCM devices */
- if (!hal_oss_device_is_pcm(u->context, udi))
+ if (!hal_oss_device_is_pcm(u->context, udi, u->init_subdevs))
goto fail;
/* We store only one entry per card, hence we look for the originating device */
@@ -393,7 +399,7 @@ static struct device* hal_device_add(struct userdata *u, const char *udi) {
if (pa_streq(u->capability, CAPABILITY_ALSA))
r = hal_device_load_alsa(u, udi, d);
#endif
-#ifdef HAVE_OSS
+#ifdef HAVE_OSS_OUTPUT
if (pa_streq(u->capability, CAPABILITY_OSS))
r = hal_device_load_oss(u, udi, d);
#endif
@@ -426,9 +432,7 @@ static int hal_device_add_all(struct userdata *u) {
int i;
for (i = 0; i < n; i++) {
- struct device *d;
-
- if ((d = hal_device_add(u, udis[i]))) {
+ if (hal_device_add(u, udis[i])) {
count++;
pa_log_debug("Loaded device %s", udis[i]);
} else
@@ -567,7 +571,7 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
pa_sink *sink;
if ((sink = pa_namereg_get(u->core, d->sink_name, PA_NAMEREG_SINK))) {
- pa_bool_t success = pa_sink_suspend(sink, suspend) >= 0;
+ pa_bool_t success = pa_sink_suspend(sink, suspend, PA_SUSPEND_SESSION) >= 0;
if (!success && !suspend)
d->acl_race_fix = TRUE; /* resume failed, let's try again */
@@ -580,7 +584,7 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
pa_source *source;
if ((source = pa_namereg_get(u->core, d->source_name, PA_NAMEREG_SOURCE))) {
- pa_bool_t success = pa_source_suspend(source, suspend) >= 0;
+ pa_bool_t success = pa_source_suspend(source, suspend, PA_SUSPEND_SESSION) >= 0;
if (!success && !suspend)
d->acl_race_fix = TRUE; /* resume failed, let's try again */
@@ -593,7 +597,7 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
pa_card *card;
if ((card = pa_namereg_get(u->core, d->card_name, PA_NAMEREG_CARD))) {
- pa_bool_t success = pa_card_suspend(card, suspend) >= 0;
+ pa_bool_t success = pa_card_suspend(card, suspend, PA_SUSPEND_SESSION) >= 0;
if (!success && !suspend)
d->acl_race_fix = TRUE; /* resume failed, let's try again */
@@ -614,8 +618,6 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
}
- return DBUS_HANDLER_RESULT_HANDLED;
-
} else if (dbus_message_is_signal(message, "org.pulseaudio.Server", "DirtyGiveUpMessage")) {
/* We use this message to avoid a dirty race condition when we
get an ACLAdded message before the previously owning PA
@@ -637,21 +639,21 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
pa_sink *sink;
if ((sink = pa_namereg_get(u->core, d->sink_name, PA_NAMEREG_SINK)))
- pa_sink_suspend(sink, FALSE);
+ pa_sink_suspend(sink, FALSE, PA_SUSPEND_SESSION);
}
if (d->source_name) {
pa_source *source;
if ((source = pa_namereg_get(u->core, d->source_name, PA_NAMEREG_SOURCE)))
- pa_source_suspend(source, FALSE);
+ pa_source_suspend(source, FALSE, PA_SUSPEND_SESSION);
}
if (d->card_name) {
pa_card *card;
if ((card = pa_namereg_get(u->core, d->source_name, PA_NAMEREG_CARD)))
- pa_card_suspend(card, FALSE);
+ pa_card_suspend(card, FALSE, PA_SUSPEND_SESSION);
}
}
@@ -659,7 +661,6 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
/* Yes, we don't check the UDI for validity, but hopefully HAL will */
device_added_cb(u->context, udi);
- return DBUS_HANDLER_RESULT_HANDLED;
}
finish:
@@ -729,12 +730,9 @@ int pa__init(pa_module*m) {
goto fail;
}
- m->userdata = u = pa_xnew(struct userdata, 1);
+ m->userdata = u = pa_xnew0(struct userdata, 1);
u->core = m->core;
- u->context = NULL;
- u->connection = NULL;
u->devices = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
- u->capability = NULL;
#ifdef HAVE_ALSA
u->use_tsched = TRUE;
@@ -752,7 +750,7 @@ int pa__init(pa_module*m) {
api = pa_modargs_get_value(ma, "api", "oss");
#endif
-#ifdef HAVE_OSS
+#ifdef HAVE_OSS_OUTPUT
if (pa_streq(api, "oss"))
u->capability = CAPABILITY_OSS;
#endif
@@ -762,6 +760,13 @@ int pa__init(pa_module*m) {
goto fail;
}
+#ifdef HAVE_OSS_OUTPUT
+ if (pa_modargs_get_value_boolean(ma, "subdevices", &u->init_subdevs) < 0) {
+ pa_log("Failed to parse subdevices= argument.");
+ goto fail;
+ }
+#endif
+
if (!(u->connection = pa_dbus_bus_get(m->core, DBUS_BUS_SYSTEM, &error)) || dbus_error_is_set(&error)) {
pa_log_error("Unable to contact DBUS system bus: %s: %s", error.name, error.message);
goto fail;
@@ -789,6 +794,7 @@ int pa__init(pa_module*m) {
pa_log_error("Failed to add filter function");
goto fail;
}
+ u->filter_added = TRUE;
if (pa_dbus_add_matches(
pa_dbus_connection_get(u->connection), &error,
@@ -845,7 +851,8 @@ void pa__done(pa_module *m) {
"type='signal',sender='org.freedesktop.Hal',interface='org.freedesktop.Hal.Device.AccessControl',member='ACLRemoved'",
"type='signal',interface='org.pulseaudio.Server',member='DirtyGiveUpMessage'", NULL);
- dbus_connection_remove_filter(pa_dbus_connection_get(u->connection), filter_cb, u);
+ if (u->filter_added)
+ dbus_connection_remove_filter(pa_dbus_connection_get(u->connection), filter_cb, u);
pa_dbus_connection_unref(u->connection);
}
diff --git a/src/modules/module-intended-roles.c b/src/modules/module-intended-roles.c
new file mode 100644
index 00000000..9ba893b2
--- /dev/null
+++ b/src/modules/module-intended-roles.c
@@ -0,0 +1,464 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Lennart Poettering
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/module.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/sink-input.h>
+#include <pulsecore/source-output.h>
+#include <pulsecore/namereg.h>
+
+#include "module-intended-roles-symdef.h"
+
+PA_MODULE_AUTHOR("Lennart Poettering");
+PA_MODULE_DESCRIPTION("Automatically set device of streams based of intended roles of devices");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_USAGE(
+ "on_hotplug=<When new device becomes available, recheck streams?> "
+ "on_rescue=<When device becomes unavailable, recheck streams?>");
+
+static const char* const valid_modargs[] = {
+ "on_hotplug",
+ "on_rescue",
+ NULL
+};
+
+struct userdata {
+ pa_core *core;
+ pa_module *module;
+
+ pa_hook_slot
+ *sink_input_new_hook_slot,
+ *source_output_new_hook_slot,
+ *sink_put_hook_slot,
+ *source_put_hook_slot,
+ *sink_unlink_hook_slot,
+ *source_unlink_hook_slot;
+
+ pa_bool_t on_hotplug:1;
+ pa_bool_t on_rescue:1;
+};
+
+static pa_bool_t role_match(pa_proplist *proplist, const char *role) {
+ const char *ir;
+ char *r;
+ const char *state = NULL;
+
+ if (!(ir = pa_proplist_gets(proplist, PA_PROP_DEVICE_INTENDED_ROLES)))
+ return FALSE;
+
+ while ((r = pa_split_spaces(ir, &state))) {
+
+ if (pa_streq(role, r)) {
+ pa_xfree(r);
+ return TRUE;
+ }
+
+ pa_xfree(r);
+ }
+
+ return FALSE;
+}
+
+static pa_hook_result_t sink_input_new_hook_callback(pa_core *c, pa_sink_input_new_data *new_data, struct userdata *u) {
+ const char *role;
+ pa_sink *s, *def;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+
+ if (!new_data->proplist) {
+ pa_log_debug("New stream lacks property data.");
+ return PA_HOOK_OK;
+ }
+
+ if (new_data->sink) {
+ pa_log_debug("Not setting device for stream %s, because already set.", pa_strnull(pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_NAME)));
+ return PA_HOOK_OK;
+ }
+
+ if (!(role = pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_ROLE))) {
+ pa_log_debug("Not setting device for stream %s, because it lacks role.", pa_strnull(pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_NAME)));
+ return PA_HOOK_OK;
+ }
+
+ /* Prefer the default sink over any other sink, just in case... */
+ if ((def = pa_namereg_get_default_sink(c)))
+ if (role_match(def->proplist, role) && pa_sink_input_new_data_set_sink(new_data, def, FALSE))
+ return PA_HOOK_OK;
+
+ /* @todo: favour the highest priority device, not the first one we find? */
+ PA_IDXSET_FOREACH(s, c->sinks, idx) {
+ if (s == def)
+ continue;
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)))
+ continue;
+
+ if (role_match(s->proplist, role) && pa_sink_input_new_data_set_sink(new_data, s, FALSE))
+ return PA_HOOK_OK;
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_output_new_hook_callback(pa_core *c, pa_source_output_new_data *new_data, struct userdata *u) {
+ const char *role;
+ pa_source *s, *def;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(new_data);
+ pa_assert(u);
+
+ if (!new_data->proplist) {
+ pa_log_debug("New stream lacks property data.");
+ return PA_HOOK_OK;
+ }
+
+ if (new_data->source) {
+ pa_log_debug("Not setting device for stream %s, because already set.", pa_strnull(pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_NAME)));
+ return PA_HOOK_OK;
+ }
+
+ if (!(role = pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_ROLE))) {
+ pa_log_debug("Not setting device for stream %s, because it lacks role.", pa_strnull(pa_proplist_gets(new_data->proplist, PA_PROP_MEDIA_NAME)));
+ return PA_HOOK_OK;
+ }
+
+ /* Prefer the default source over any other source, just in case... */
+ if ((def = pa_namereg_get_default_source(c)))
+ if (role_match(def->proplist, role)) {
+ pa_source_output_new_data_set_source(new_data, def, FALSE);
+ return PA_HOOK_OK;
+ }
+
+ PA_IDXSET_FOREACH(s, c->sources, idx) {
+ if (s->monitor_of)
+ continue;
+
+ if (s == def)
+ continue;
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(s)))
+ continue;
+
+ /* @todo: favour the highest priority device, not the first one we find? */
+ if (role_match(s->proplist, role)) {
+ pa_source_output_new_data_set_source(new_data, s, FALSE);
+ return PA_HOOK_OK;
+ }
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_put_hook_callback(pa_core *c, pa_sink *sink, struct userdata *u) {
+ pa_sink_input *si;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(sink);
+ pa_assert(u);
+ pa_assert(u->on_hotplug);
+
+ PA_IDXSET_FOREACH(si, c->sink_inputs, idx) {
+ const char *role;
+
+ if (si->sink == sink)
+ continue;
+
+ if (si->save_sink)
+ continue;
+
+ /* Skip this if it is already in the process of being moved
+ * anyway */
+ if (!si->sink)
+ continue;
+
+ /* It might happen that a stream and a sink are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (!PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(si)))
+ continue;
+
+ if (!(role = pa_proplist_gets(si->proplist, PA_PROP_MEDIA_ROLE)))
+ continue;
+
+ if (role_match(si->sink->proplist, role))
+ continue;
+
+ if (!role_match(sink->proplist, role))
+ continue;
+
+ pa_sink_input_move_to(si, sink, FALSE);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_put_hook_callback(pa_core *c, pa_source *source, struct userdata *u) {
+ pa_source_output *so;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(source);
+ pa_assert(u);
+ pa_assert(u->on_hotplug);
+
+ if (source->monitor_of)
+ return PA_HOOK_OK;
+
+ PA_IDXSET_FOREACH(so, c->source_outputs, idx) {
+ const char *role;
+
+ if (so->source == source)
+ continue;
+
+ if (so->save_source)
+ continue;
+
+ if (so->direct_on_input)
+ continue;
+
+ /* Skip this if it is already in the process of being moved
+ * anyway */
+ if (!so->source)
+ continue;
+
+ /* It might happen that a stream and a source are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (!PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(so)))
+ continue;
+
+ if (!(role = pa_proplist_gets(so->proplist, PA_PROP_MEDIA_ROLE)))
+ continue;
+
+ if (role_match(so->source->proplist, role))
+ continue;
+
+ if (!role_match(source->proplist, role))
+ continue;
+
+ pa_source_output_move_to(so, source, FALSE);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_unlink_hook_callback(pa_core *c, pa_sink *sink, struct userdata *u) {
+ pa_sink_input *si;
+ uint32_t idx;
+ pa_sink *def;
+
+ pa_assert(c);
+ pa_assert(sink);
+ pa_assert(u);
+ pa_assert(u->on_rescue);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ /* If there not default sink, then there is no sink at all */
+ if (!(def = pa_namereg_get_default_sink(c)))
+ return PA_HOOK_OK;
+
+ PA_IDXSET_FOREACH(si, sink->inputs, idx) {
+ const char *role;
+ uint32_t jdx;
+ pa_sink *d;
+
+ if (!si->sink)
+ continue;
+
+ if (!(role = pa_proplist_gets(si->proplist, PA_PROP_MEDIA_ROLE)))
+ continue;
+
+ /* Would the default sink fit? If so, let's use it */
+ if (def != sink && role_match(def->proplist, role))
+ if (pa_sink_input_move_to(si, def, FALSE) >= 0)
+ continue;
+
+ /* Try to find some other fitting sink */
+ /* @todo: favour the highest priority device, not the first one we find? */
+ PA_IDXSET_FOREACH(d, c->sinks, jdx) {
+ if (d == def || d == sink)
+ continue;
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(d)))
+ continue;
+
+ if (role_match(d->proplist, role))
+ if (pa_sink_input_move_to(si, d, FALSE) >= 0)
+ break;
+ }
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_unlink_hook_callback(pa_core *c, pa_source *source, struct userdata *u) {
+ pa_source_output *so;
+ uint32_t idx;
+ pa_source *def;
+
+ pa_assert(c);
+ pa_assert(source);
+ pa_assert(u);
+ pa_assert(u->on_rescue);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ /* If there not default source, then there is no source at all */
+ if (!(def = pa_namereg_get_default_source(c)))
+ return PA_HOOK_OK;
+
+ PA_IDXSET_FOREACH(so, source->outputs, idx) {
+ const char *role;
+ uint32_t jdx;
+ pa_source *d;
+
+ if (so->direct_on_input)
+ continue;
+
+ if (!so->source)
+ continue;
+
+ if (!(role = pa_proplist_gets(so->proplist, PA_PROP_MEDIA_ROLE)))
+ continue;
+
+ /* Would the default source fit? If so, let's use it */
+ if (def != source && role_match(def->proplist, role) && !source->monitor_of == !def->monitor_of) {
+ pa_source_output_move_to(so, def, FALSE);
+ continue;
+ }
+
+ /* Try to find some other fitting source */
+ /* @todo: favour the highest priority device, not the first one we find? */
+ PA_IDXSET_FOREACH(d, c->sources, jdx) {
+ if (d == def || d == source)
+ continue;
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(d)))
+ continue;
+
+ /* If moving from a monitor, move to another monitor */
+ if (!source->monitor_of == !d->monitor_of && role_match(d->proplist, role)) {
+ pa_source_output_move_to(so, d, FALSE);
+ break;
+ }
+ }
+ }
+
+ return PA_HOOK_OK;
+}
+
+int pa__init(pa_module*m) {
+ pa_modargs *ma = NULL;
+ struct userdata *u;
+ pa_bool_t on_hotplug = TRUE, on_rescue = TRUE;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "on_hotplug", &on_hotplug) < 0 ||
+ pa_modargs_get_value_boolean(ma, "on_rescue", &on_rescue) < 0) {
+ pa_log("on_hotplug= and on_rescue= expect boolean arguments");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->module = m;
+ u->on_hotplug = on_hotplug;
+ u->on_rescue = on_rescue;
+
+ /* A little bit later than module-stream-restore */
+ u->sink_input_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_NEW], PA_HOOK_EARLY+10, (pa_hook_cb_t) sink_input_new_hook_callback, u);
+ u->source_output_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_NEW], PA_HOOK_EARLY+10, (pa_hook_cb_t) source_output_new_hook_callback, u);
+
+ if (on_hotplug) {
+ /* A little bit later than module-stream-restore */
+ u->sink_put_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_LATE+10, (pa_hook_cb_t) sink_put_hook_callback, u);
+ u->source_put_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_PUT], PA_HOOK_LATE+10, (pa_hook_cb_t) source_put_hook_callback, u);
+ }
+
+ if (on_rescue) {
+ /* A little bit later than module-stream-restore, a little bit earlier than module-rescue-streams, ... */
+ u->sink_unlink_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_LATE+10, (pa_hook_cb_t) sink_unlink_hook_callback, u);
+ u->source_unlink_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_LATE+10, (pa_hook_cb_t) source_unlink_hook_callback, u);
+ }
+
+ pa_modargs_free(ma);
+ return 0;
+
+fail:
+ pa__done(m);
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ return -1;
+}
+
+void pa__done(pa_module*m) {
+ struct userdata* u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->sink_input_new_hook_slot)
+ pa_hook_slot_free(u->sink_input_new_hook_slot);
+ if (u->source_output_new_hook_slot)
+ pa_hook_slot_free(u->source_output_new_hook_slot);
+
+ if (u->sink_put_hook_slot)
+ pa_hook_slot_free(u->sink_put_hook_slot);
+ if (u->source_put_hook_slot)
+ pa_hook_slot_free(u->source_put_hook_slot);
+
+ if (u->sink_unlink_hook_slot)
+ pa_hook_slot_free(u->sink_unlink_hook_slot);
+ if (u->source_unlink_hook_slot)
+ pa_hook_slot_free(u->source_unlink_hook_slot);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-ladspa-sink.c b/src/modules/module-ladspa-sink.c
index 15af74a6..9cce269d 100644
--- a/src/modules/module-ladspa-sink.c
+++ b/src/modules/module-ladspa-sink.c
@@ -26,17 +26,17 @@
#include <config.h>
#endif
+#include <math.h>
+
#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/namereg.h>
#include <pulsecore/sink.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
-#include <pulsecore/thread.h>
-#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
#include <pulsecore/sample-util.h>
#include <pulsecore/ltdl-helper.h>
@@ -45,43 +45,48 @@
#include "ladspa.h"
PA_MODULE_AUTHOR("Lennart Poettering");
-PA_MODULE_DESCRIPTION("Virtual LADSPA sink");
+PA_MODULE_DESCRIPTION(_("Virtual LADSPA sink"));
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(FALSE);
PA_MODULE_USAGE(
- "sink_name=<name for the sink> "
- "sink_properties=<properties for the sink> "
- "master=<name of sink to remap> "
- "format=<sample format> "
- "rate=<sample rate> "
- "channels=<number of channels> "
- "channel_map=<channel map> "
- "plugin=<ladspa plugin name> "
- "label=<ladspa plugin label> "
- "control=<comma seperated list of input control values>");
+ _("sink_name=<name for the sink> "
+ "sink_properties=<properties for the sink> "
+ "master=<name of sink to filter> "
+ "format=<sample format> "
+ "rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<input channel map> "
+ "plugin=<ladspa plugin name> "
+ "label=<ladspa plugin label> "
+ "control=<comma seperated list of input control values> "
+ "input_ladspaport_map=<comma separated list of input LADSPA port names> "
+ "output_ladspaport_map=<comma separated list of output LADSPA port names> "));
#define MEMBLOCKQ_MAXLENGTH (16*1024*1024)
+/* PLEASE NOTICE: The PortAudio ports and the LADSPA ports are two different concepts.
+They are not related and where possible the names of the LADSPA port variables contains "ladspa" to avoid confusion */
+
struct userdata {
- pa_core *core;
pa_module *module;
- pa_sink *sink, *master;
+ pa_sink *sink;
pa_sink_input *sink_input;
const LADSPA_Descriptor *descriptor;
- unsigned channels;
LADSPA_Handle handle[PA_CHANNELS_MAX];
- LADSPA_Data *input, *output;
+ unsigned long max_ladspaport_count, input_count, output_count, channels;
+ LADSPA_Data **input, **output;
size_t block_size;
- unsigned long input_port, output_port;
LADSPA_Data *control;
/* This is a dummy buffer. Every port must be connected, but we don't care
- about control out ports. We connect them all to this single buffer. */
+ about control out ports. We connect them all to this single buffer. */
LADSPA_Data control_out;
pa_memblockq *memblockq;
+
+ pa_bool_t auto_desc;
};
static const char* const valid_modargs[] = {
@@ -95,71 +100,117 @@ static const char* const valid_modargs[] = {
"plugin",
"label",
"control",
+ "input_ladspaport_map",
+ "output_ladspaport_map",
NULL
};
/* Called from I/O thread context */
-static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+static int sink_process_msg_cb(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
struct userdata *u = PA_SINK(o)->userdata;
switch (code) {
- case PA_SINK_MESSAGE_GET_LATENCY: {
- pa_usec_t usec = 0;
+ case PA_SINK_MESSAGE_GET_LATENCY:
+
+ /* The sink is _put() before the sink input is, so let's
+ * make sure we don't access it in that time. Also, the
+ * sink input is first shut down, the sink second. */
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state)) {
+ *((pa_usec_t*) data) = 0;
+ return 0;
+ }
+
+ *((pa_usec_t*) data) =
/* Get the latency of the master sink */
- if (PA_MSGOBJECT(u->master)->process_msg(PA_MSGOBJECT(u->master), PA_SINK_MESSAGE_GET_LATENCY, &usec, 0, NULL) < 0)
- usec = 0;
+ pa_sink_get_latency_within_thread(u->sink_input->sink) +
/* Add the latency internal to our sink input on top */
- usec += pa_bytes_to_usec(pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq), &u->master->sample_spec);
+ pa_bytes_to_usec(pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq), &u->sink_input->sink->sample_spec);
- *((pa_usec_t*) data) = usec;
- return 0;
- }
+ return 0;
}
return pa_sink_process_msg(o, code, data, offset, chunk);
}
/* Called from main context */
-static int sink_set_state(pa_sink *s, pa_sink_state_t state) {
+static int sink_set_state_cb(pa_sink *s, pa_sink_state_t state) {
struct userdata *u;
pa_sink_assert_ref(s);
pa_assert_se(u = s->userdata);
- if (PA_SINK_IS_LINKED(state) &&
- u->sink_input &&
- PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
-
- pa_sink_input_cork(u->sink_input, state == PA_SINK_SUSPENDED);
+ if (!PA_SINK_IS_LINKED(state) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return 0;
+ pa_sink_input_cork(u->sink_input, state == PA_SINK_SUSPENDED);
return 0;
}
/* Called from I/O thread context */
-static void sink_request_rewind(pa_sink *s) {
+static void sink_request_rewind_cb(pa_sink *s) {
struct userdata *u;
pa_sink_assert_ref(s);
pa_assert_se(u = s->userdata);
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
/* Just hand this one over to the master sink */
- pa_sink_input_request_rewind(u->sink_input, s->thread_info.rewind_nbytes + pa_memblockq_get_length(u->memblockq), TRUE, FALSE, FALSE);
+ pa_sink_input_request_rewind(u->sink_input,
+ s->thread_info.rewind_nbytes +
+ pa_memblockq_get_length(u->memblockq), TRUE, FALSE, FALSE);
}
/* Called from I/O thread context */
-static void sink_update_requested_latency(pa_sink *s) {
+static void sink_update_requested_latency_cb(pa_sink *s) {
struct userdata *u;
pa_sink_assert_ref(s);
pa_assert_se(u = s->userdata);
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
/* Just hand this one over to the master sink */
pa_sink_input_set_requested_latency_within_thread(
- u->sink_input,
- pa_sink_get_requested_latency_within_thread(s));
+ u->sink_input,
+ pa_sink_get_requested_latency_within_thread(s));
+}
+
+/* Called from main context */
+static void sink_set_volume_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_volume(u->sink_input, &s->real_volume, s->save_volume, TRUE);
+}
+
+/* Called from main context */
+static void sink_set_mute_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_mute(u->sink_input, s->muted, s->save_muted);
}
/* Called from I/O thread context */
@@ -167,15 +218,15 @@ static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk
struct userdata *u;
float *src, *dst;
size_t fs;
- unsigned n, c;
+ unsigned n, h, c;
pa_memchunk tchunk;
pa_sink_input_assert_ref(i);
pa_assert(chunk);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_OPENED(u->sink->thread_info.state))
- return -1;
+ /* Hmm, process any rewind request that might be queued up */
+ pa_sink_process_rewind(u->sink, 0);
while (pa_memblockq_peek(u->memblockq, &tchunk) < 0) {
pa_memchunk nchunk;
@@ -202,10 +253,12 @@ static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk
src = (float*) ((uint8_t*) pa_memblock_acquire(tchunk.memblock) + tchunk.index);
dst = (float*) pa_memblock_acquire(chunk->memblock);
- for (c = 0; c < u->channels; c++) {
- pa_sample_clamp(PA_SAMPLE_FLOAT32NE, u->input, sizeof(float), src+c, u->channels*sizeof(float), n);
- u->descriptor->run(u->handle[c], n);
- pa_sample_clamp(PA_SAMPLE_FLOAT32NE, dst+c, u->channels*sizeof(float), u->output, sizeof(float), n);
+ for (h = 0; h < (u->channels / u->max_ladspaport_count); h++) {
+ for (c = 0; c < u->input_count; c++)
+ pa_sample_clamp(PA_SAMPLE_FLOAT32NE, u->input[c], sizeof(float), src+ h*u->max_ladspaport_count + c, u->channels*sizeof(float), n);
+ u->descriptor->run(u->handle[h], n);
+ for (c = 0; c < u->output_count; c++)
+ pa_sample_clamp(PA_SAMPLE_FLOAT32NE, dst + h*u->max_ladspaport_count + c, u->channels*sizeof(float), u->output[c], sizeof(float), n);
}
pa_memblock_release(tchunk.memblock);
@@ -224,9 +277,6 @@ static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_OPENED(u->sink->thread_info.state))
- return;
-
if (u->sink->thread_info.rewind_nbytes > 0) {
size_t max_rewrite;
@@ -243,10 +293,10 @@ static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
/* Reset the plugin */
if (u->descriptor->deactivate)
- for (c = 0; c < u->channels; c++)
+ for (c = 0; c < (u->channels / u->max_ladspaport_count); c++)
u->descriptor->deactivate(u->handle[c]);
if (u->descriptor->activate)
- for (c = 0; c < u->channels; c++)
+ for (c = 0; c < (u->channels / u->max_ladspaport_count); c++)
u->descriptor->activate(u->handle[c]);
}
}
@@ -262,9 +312,6 @@ static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
-
pa_memblockq_set_maxrewind(u->memblockq, nbytes);
pa_sink_set_max_rewind_within_thread(u->sink, nbytes);
}
@@ -276,9 +323,6 @@ static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
-
pa_sink_set_max_request_within_thread(u->sink, nbytes);
}
@@ -289,24 +333,28 @@ static void sink_input_update_sink_latency_range_cb(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
-
pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
}
/* Called from I/O thread context */
-static void sink_input_detach_cb(pa_sink_input *i) {
+static void sink_input_update_sink_fixed_latency_cb(pa_sink_input *i) {
struct userdata *u;
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_detach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
pa_sink_detach_within_thread(u->sink);
- pa_sink_set_asyncmsgq(u->sink, NULL);
+
pa_sink_set_rtpoll(u->sink, NULL);
}
@@ -317,14 +365,13 @@ static void sink_input_attach_cb(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
+ pa_sink_set_rtpoll(u->sink, i->sink->thread_info.rtpoll);
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+ pa_sink_set_max_request_within_thread(u->sink, pa_sink_input_get_max_request(i));
+ pa_sink_set_max_rewind_within_thread(u->sink, pa_sink_input_get_max_rewind(i));
- pa_sink_set_asyncmsgq(u->sink, i->sink->asyncmsgq);
- pa_sink_set_rtpoll(u->sink, i->sink->rtpoll);
pa_sink_attach_within_thread(u->sink);
-
- pa_sink_set_latency_range_within_thread(u->sink, u->master->thread_info.min_latency, u->master->thread_info.max_latency);
}
/* Called from main context */
@@ -334,14 +381,18 @@ static void sink_input_kill_cb(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- pa_sink_unlink(u->sink);
+ /* The order here matters! We first kill the sink input, followed
+ * by the sink. That means the sink callbacks must be protected
+ * against an unconnected sink input! */
pa_sink_input_unlink(u->sink_input);
+ pa_sink_unlink(u->sink);
- pa_sink_unref(u->sink);
- u->sink = NULL;
pa_sink_input_unref(u->sink_input);
u->sink_input = NULL;
+ pa_sink_unref(u->sink);
+ u->sink = NULL;
+
pa_module_unload_request(u->module, TRUE);
}
@@ -355,7 +406,7 @@ static void sink_input_state_change_cb(pa_sink_input *i, pa_sink_input_state_t s
/* If we are added for the first time, ask for a rewinding so that
* we are heard right-away. */
if (PA_SINK_INPUT_IS_LINKED(state) &&
- i->thread_info.state == PA_SINK_INPUT_INIT) {
+ i->thread_info.state == PA_SINK_INPUT_INIT) {
pa_log_debug("Requesting rewind due to state change.");
pa_sink_input_request_rewind(i, 0, FALSE, TRUE, TRUE);
}
@@ -371,27 +422,73 @@ static pa_bool_t sink_input_may_move_to_cb(pa_sink_input *i, pa_sink *dest) {
return u->sink != dest;
}
+/* Called from main context */
+static void sink_input_moving_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ if (dest) {
+ pa_sink_set_asyncmsgq(u->sink, dest->asyncmsgq);
+ pa_sink_update_flags(u->sink, PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY, dest->flags);
+ } else
+ pa_sink_set_asyncmsgq(u->sink, NULL);
+
+ if (u->auto_desc && dest) {
+ const char *z;
+ pa_proplist *pl;
+
+ pl = pa_proplist_new();
+ z = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(pl, PA_PROP_DEVICE_DESCRIPTION, "LADSPA Plugin %s on %s",
+ pa_proplist_gets(u->sink->proplist, "device.ladspa.name"), z ? z : dest->name);
+
+ pa_sink_update_proplist(u->sink, PA_UPDATE_REPLACE, pl);
+ pa_proplist_free(pl);
+ }
+}
+
+/* Called from main context */
+static void sink_input_volume_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_volume_changed(u->sink, &i->volume);
+}
+
+/* Called from main context */
+static void sink_input_mute_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_mute_changed(u->sink, i->muted);
+}
+
int pa__init(pa_module*m) {
struct userdata *u;
pa_sample_spec ss;
pa_channel_map map;
pa_modargs *ma;
char *t;
- const char *z;
pa_sink *master;
pa_sink_input_new_data sink_input_data;
pa_sink_new_data sink_data;
- const char *plugin, *label;
+ const char *plugin, *label, *input_ladspaport_map, *output_ladspaport_map;
LADSPA_Descriptor_Function descriptor_func;
+ unsigned long input_ladspaport[PA_CHANNELS_MAX], output_ladspaport[PA_CHANNELS_MAX];
const char *e, *cdata;
const LADSPA_Descriptor *d;
- unsigned long input_port, output_port, p, j, n_control;
- unsigned c;
+ unsigned long p, h, j, n_control, c;
pa_bool_t *use_default = NULL;
pa_assert(m);
- pa_assert(sizeof(LADSPA_Data) == sizeof(float));
+ pa_assert_cc(sizeof(LADSPA_Data) == sizeof(float));
if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
pa_log("Failed to parse module arguments.");
@@ -421,16 +518,22 @@ int pa__init(pa_module*m) {
goto fail;
}
+ if (!(input_ladspaport_map = pa_modargs_get_value(ma, "input_ladspaport_map", NULL)))
+ pa_log_debug("Using default input ladspa port mapping");
+
+ if (!(output_ladspaport_map = pa_modargs_get_value(ma, "output_ladspaport_map", NULL)))
+ pa_log_debug("Using default output ladspa port mapping");
+
cdata = pa_modargs_get_value(ma, "control", NULL);
u = pa_xnew0(struct userdata, 1);
- u->core = m->core;
u->module = m;
m->userdata = u;
- u->master = master;
- u->sink = NULL;
- u->sink_input = NULL;
u->memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, pa_frame_size(&ss), 1, 1, 0, NULL);
+ u->max_ladspaport_count = 1; /*to avoid division by zero etc. in pa__done when failing before this value has been set*/
+ u->channels = 0;
+ u->input = NULL;
+ u->output = NULL;
if (!(e = getenv("LADSPA_PATH")))
e = LADSPA_PATH;
@@ -472,64 +575,127 @@ int pa__init(pa_module*m) {
pa_log_debug("Maker: %s", d->Maker);
pa_log_debug("Copyright: %s", d->Copyright);
- input_port = output_port = (unsigned long) -1;
n_control = 0;
+ u->channels = ss.channels;
+ /*
+ * Enumerate ladspa ports
+ * Default mapping is in order given by the plugin
+ */
for (p = 0; p < d->PortCount; p++) {
+ if (LADSPA_IS_PORT_AUDIO(d->PortDescriptors[p])) {
+ if (LADSPA_IS_PORT_INPUT(d->PortDescriptors[p])) {
+ pa_log_debug("Port %lu is input: %s", p, d->PortNames[p]);
+ input_ladspaport[u->input_count] = p;
+ u->input_count++;
+ } else if (LADSPA_IS_PORT_OUTPUT(d->PortDescriptors[p])) {
+ pa_log_debug("Port %lu is output: %s", p, d->PortNames[p]);
+ output_ladspaport[u->output_count] = p;
+ u->output_count++;
+ }
+ } else if (LADSPA_IS_PORT_CONTROL(d->PortDescriptors[p]) && LADSPA_IS_PORT_INPUT(d->PortDescriptors[p])) {
+ pa_log_debug("Port %lu is control: %s", p, d->PortNames[p]);
+ n_control++;
+ } else
+ pa_log_debug("Ignored port %s", d->PortNames[p]);
+ /* XXX: Has anyone ever seen an in-place plugin with non-equal number of input and output ports? */
+ /* Could be if the plugin is for up-mixing stereo to 5.1 channels */
+ /* Or if the plugin is down-mixing 5.1 to two channel stereo or binaural encoded signal */
+ if (u->input_count > u->max_ladspaport_count)
+ u->max_ladspaport_count = u->input_count;
+ else
+ u->max_ladspaport_count = u->output_count;
+ }
+
+ if (u->channels % u->max_ladspaport_count) {
+ pa_log("Cannot handle non-integral number of plugins required for given number of channels");
+ goto fail;
+ }
- if (LADSPA_IS_PORT_INPUT(d->PortDescriptors[p]) && LADSPA_IS_PORT_AUDIO(d->PortDescriptors[p])) {
+ pa_log_debug("Will run %lu plugin instances", u->channels / u->max_ladspaport_count);
- if (strcmp(d->PortNames[p], "Input") == 0) {
- pa_assert(input_port == (unsigned long) -1);
- input_port = p;
- } else {
- pa_log("Found audio input port on plugin we cannot handle: %s", d->PortNames[p]);
+ /* Parse data for input ladspa port map */
+ if (input_ladspaport_map) {
+ const char *state = NULL;
+ char *pname;
+ c = 0;
+ while ((pname = pa_split(input_ladspaport_map, ",", &state))) {
+ if (c == u->input_count) {
+ pa_log("Too many ports in input ladspa port map");
goto fail;
}
- } else if (LADSPA_IS_PORT_OUTPUT(d->PortDescriptors[p]) && LADSPA_IS_PORT_AUDIO(d->PortDescriptors[p])) {
- if (strcmp(d->PortNames[p], "Output") == 0) {
- pa_assert(output_port == (unsigned long) -1);
- output_port = p;
- } else {
- pa_log("Found audio output port on plugin we cannot handle: %s", d->PortNames[p]);
- goto fail;
+ for (p = 0; p < d->PortCount; p++) {
+ if (strcmp(d->PortNames[p], pname) == 0) {
+ if (LADSPA_IS_PORT_AUDIO(d->PortDescriptors[p]) && LADSPA_IS_PORT_INPUT(d->PortDescriptors[p])) {
+ input_ladspaport[c] = p;
+ } else {
+ pa_log("Port %s is not an audio input ladspa port", pname);
+ pa_xfree(pname);
+ goto fail;
+ }
+ }
}
-
- } else if (LADSPA_IS_PORT_INPUT(d->PortDescriptors[p]) && LADSPA_IS_PORT_CONTROL(d->PortDescriptors[p]))
- n_control++;
- else {
- pa_assert(LADSPA_IS_PORT_OUTPUT(d->PortDescriptors[p]) && LADSPA_IS_PORT_CONTROL(d->PortDescriptors[p]));
- pa_log_debug("Ignored control output port \"%s\".", d->PortNames[p]);
+ c++;
+ pa_xfree(pname);
}
}
- if ((input_port == (unsigned long) -1) || (output_port == (unsigned long) -1)) {
- pa_log("Failed to identify input and output ports. "
- "Right now this module can only deal with plugins which provide an 'Input' and an 'Output' audio port. "
- "Patches welcome!");
- goto fail;
+ /* Parse data for output port map */
+ if (output_ladspaport_map) {
+ const char *state = NULL;
+ char *pname;
+ c = 0;
+ while ((pname = pa_split(output_ladspaport_map, ",", &state))) {
+ if (c == u->output_count) {
+ pa_log("Too many ports in output ladspa port map");
+ goto fail;
+ }
+ for (p = 0; p < d->PortCount; p++) {
+ if (strcmp(d->PortNames[p], pname) == 0) {
+ if (LADSPA_IS_PORT_AUDIO(d->PortDescriptors[p]) && LADSPA_IS_PORT_OUTPUT(d->PortDescriptors[p])) {
+ output_ladspaport[c] = p;
+ } else {
+ pa_log("Port %s is not an output ladspa port", pname);
+ pa_xfree(pname);
+ goto fail;
+ }
+ }
+ }
+ c++;
+ pa_xfree(pname);
+ }
}
+
u->block_size = pa_frame_align(pa_mempool_block_size_max(m->core->mempool), &ss);
- u->input = (LADSPA_Data*) pa_xnew(uint8_t, (unsigned) u->block_size);
- if (LADSPA_IS_INPLACE_BROKEN(d->Properties))
- u->output = (LADSPA_Data*) pa_xnew(uint8_t, (unsigned) u->block_size);
- else
+ /* Create buffers */
+ if (LADSPA_IS_INPLACE_BROKEN(d->Properties)) {
+ u->input = (LADSPA_Data**) pa_xnew(LADSPA_Data*, (unsigned) u->input_count);
+ for (c = 0; c < u->input_count; c++)
+ u->input[c] = (LADSPA_Data*) pa_xnew(uint8_t, (unsigned) u->block_size);
+ u->output = (LADSPA_Data**) pa_xnew(LADSPA_Data*, (unsigned) u->output_count);
+ for (c = 0; c < u->output_count; c++)
+ u->output[c] = (LADSPA_Data*) pa_xnew(uint8_t, (unsigned) u->block_size);
+ } else {
+ u->input = (LADSPA_Data**) pa_xnew(LADSPA_Data*, (unsigned) u->max_ladspaport_count);
+ for (c = 0; c < u->max_ladspaport_count; c++)
+ u->input[c] = (LADSPA_Data*) pa_xnew(uint8_t, (unsigned) u->block_size);
u->output = u->input;
-
- u->channels = ss.channels;
-
- for (c = 0; c < ss.channels; c++) {
- if (!(u->handle[c] = d->instantiate(d, ss.rate))) {
- pa_log("Failed to instantiate plugin %s with label %s for channel %i", plugin, d->Label, c);
+ }
+ /* Initialize plugin instances */
+ for (h = 0; h < (u->channels / u->max_ladspaport_count); h++) {
+ if (!(u->handle[h] = d->instantiate(d, ss.rate))) {
+ pa_log("Failed to instantiate plugin %s with label %s", plugin, d->Label);
goto fail;
}
- d->connect_port(u->handle[c], input_port, u->input);
- d->connect_port(u->handle[c], output_port, u->output);
+ for (c = 0; c < u->input_count; c++)
+ d->connect_port(u->handle[h], input_ladspaport[c], u->input[c]);
+ for (c = 0; c < u->output_count; c++)
+ d->connect_port(u->handle[h], output_ladspaport[c], u->output[c]);
}
if (!cdata && n_control > 0) {
@@ -540,7 +706,6 @@ int pa__init(pa_module*m) {
if (n_control > 0) {
const char *state = NULL;
char *k;
- unsigned long h;
u->control = pa_xnew(LADSPA_Data, (unsigned) n_control);
use_default = pa_xnew(pa_bool_t, (unsigned) n_control);
@@ -568,7 +733,7 @@ int pa__init(pa_module*m) {
}
/* The previous loop doesn't take the last control value into account
- if it is left empty, so we do it here. */
+ if it is left empty, so we do it here. */
if (*cdata == 0 || cdata[strlen(cdata) - 1] == ',') {
if (p < n_control)
use_default[p] = TRUE;
@@ -594,7 +759,7 @@ int pa__init(pa_module*m) {
continue;
if (LADSPA_IS_PORT_OUTPUT(d->PortDescriptors[p])) {
- for (c = 0; c < ss.channels; c++)
+ for (c = 0; c < (u->channels / u->max_ladspaport_count); c++)
d->connect_port(u->handle[c], p, &u->control_out);
continue;
}
@@ -619,53 +784,53 @@ int pa__init(pa_module*m) {
switch (hint & LADSPA_HINT_DEFAULT_MASK) {
- case LADSPA_HINT_DEFAULT_MINIMUM:
- u->control[h] = lower;
- break;
-
- case LADSPA_HINT_DEFAULT_MAXIMUM:
- u->control[h] = upper;
- break;
-
- case LADSPA_HINT_DEFAULT_LOW:
- if (LADSPA_IS_HINT_LOGARITHMIC(hint))
- u->control[h] = (LADSPA_Data) exp(log(lower) * 0.75 + log(upper) * 0.25);
- else
- u->control[h] = (LADSPA_Data) (lower * 0.75 + upper * 0.25);
- break;
-
- case LADSPA_HINT_DEFAULT_MIDDLE:
- if (LADSPA_IS_HINT_LOGARITHMIC(hint))
- u->control[h] = (LADSPA_Data) exp(log(lower) * 0.5 + log(upper) * 0.5);
- else
- u->control[h] = (LADSPA_Data) (lower * 0.5 + upper * 0.5);
- break;
-
- case LADSPA_HINT_DEFAULT_HIGH:
- if (LADSPA_IS_HINT_LOGARITHMIC(hint))
- u->control[h] = (LADSPA_Data) exp(log(lower) * 0.25 + log(upper) * 0.75);
- else
- u->control[h] = (LADSPA_Data) (lower * 0.25 + upper * 0.75);
- break;
-
- case LADSPA_HINT_DEFAULT_0:
- u->control[h] = 0;
- break;
-
- case LADSPA_HINT_DEFAULT_1:
- u->control[h] = 1;
- break;
-
- case LADSPA_HINT_DEFAULT_100:
- u->control[h] = 100;
- break;
-
- case LADSPA_HINT_DEFAULT_440:
- u->control[h] = 440;
- break;
-
- default:
- pa_assert_not_reached();
+ case LADSPA_HINT_DEFAULT_MINIMUM:
+ u->control[h] = lower;
+ break;
+
+ case LADSPA_HINT_DEFAULT_MAXIMUM:
+ u->control[h] = upper;
+ break;
+
+ case LADSPA_HINT_DEFAULT_LOW:
+ if (LADSPA_IS_HINT_LOGARITHMIC(hint))
+ u->control[h] = (LADSPA_Data) exp(log(lower) * 0.75 + log(upper) * 0.25);
+ else
+ u->control[h] = (LADSPA_Data) (lower * 0.75 + upper * 0.25);
+ break;
+
+ case LADSPA_HINT_DEFAULT_MIDDLE:
+ if (LADSPA_IS_HINT_LOGARITHMIC(hint))
+ u->control[h] = (LADSPA_Data) exp(log(lower) * 0.5 + log(upper) * 0.5);
+ else
+ u->control[h] = (LADSPA_Data) (lower * 0.5 + upper * 0.5);
+ break;
+
+ case LADSPA_HINT_DEFAULT_HIGH:
+ if (LADSPA_IS_HINT_LOGARITHMIC(hint))
+ u->control[h] = (LADSPA_Data) exp(log(lower) * 0.25 + log(upper) * 0.75);
+ else
+ u->control[h] = (LADSPA_Data) (lower * 0.25 + upper * 0.75);
+ break;
+
+ case LADSPA_HINT_DEFAULT_0:
+ u->control[h] = 0;
+ break;
+
+ case LADSPA_HINT_DEFAULT_1:
+ u->control[h] = 1;
+ break;
+
+ case LADSPA_HINT_DEFAULT_100:
+ u->control[h] = 100;
+ break;
+
+ case LADSPA_HINT_DEFAULT_440:
+ u->control[h] = 440;
+ break;
+
+ default:
+ pa_assert_not_reached();
}
}
@@ -674,7 +839,7 @@ int pa__init(pa_module*m) {
pa_log_debug("Binding %f to port %s", u->control[h], d->PortNames[p]);
- for (c = 0; c < ss.channels; c++)
+ for (c = 0; c < (u->channels / u->max_ladspaport_count); c++)
d->connect_port(u->handle[c], p, &u->control[h]);
h++;
@@ -684,7 +849,7 @@ int pa__init(pa_module*m) {
}
if (d->activate)
- for (c = 0; c < u->channels; c++)
+ for (c = 0; c < (u->channels / u->max_ladspaport_count); c++)
d->activate(u->handle[c]);
/* Create sink */
@@ -693,11 +858,8 @@ int pa__init(pa_module*m) {
sink_data.module = m;
if (!(sink_data.name = pa_xstrdup(pa_modargs_get_value(ma, "sink_name", NULL))))
sink_data.name = pa_sprintf_malloc("%s.ladspa", master->name);
- sink_data.namereg_fail = FALSE;
pa_sink_new_data_set_sample_spec(&sink_data, &ss);
pa_sink_new_data_set_channel_map(&sink_data, &map);
- z = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
- pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "LADSPA Plugin %s on %s", label, z ? z : master->name);
pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, master->name);
pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_CLASS, "filter");
pa_proplist_sets(sink_data.proplist, "device.ladspa.module", plugin);
@@ -713,7 +875,16 @@ int pa__init(pa_module*m) {
goto fail;
}
- u->sink = pa_sink_new(m->core, &sink_data, PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY);
+ if ((u->auto_desc = !pa_proplist_contains(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ const char *z;
+
+ z = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "LADSPA Plugin %s on %s", d->Name, z ? z : master->name);
+ }
+
+ u->sink = pa_sink_new(m->core, &sink_data,
+ PA_SINK_HW_MUTE_CTRL|PA_SINK_HW_VOLUME_CTRL|PA_SINK_DECIBEL_VOLUME|
+ (master->flags & (PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY)));
pa_sink_new_data_done(&sink_data);
if (!u->sink) {
@@ -721,26 +892,28 @@ int pa__init(pa_module*m) {
goto fail;
}
- u->sink->parent.process_msg = sink_process_msg;
- u->sink->set_state = sink_set_state;
- u->sink->update_requested_latency = sink_update_requested_latency;
- u->sink->request_rewind = sink_request_rewind;
+ u->sink->parent.process_msg = sink_process_msg_cb;
+ u->sink->set_state = sink_set_state_cb;
+ u->sink->update_requested_latency = sink_update_requested_latency_cb;
+ u->sink->request_rewind = sink_request_rewind_cb;
+ u->sink->set_volume = sink_set_volume_cb;
+ u->sink->set_mute = sink_set_mute_cb;
u->sink->userdata = u;
pa_sink_set_asyncmsgq(u->sink, master->asyncmsgq);
- pa_sink_set_rtpoll(u->sink, master->rtpoll);
/* Create sink input */
pa_sink_input_new_data_init(&sink_input_data);
sink_input_data.driver = __FILE__;
sink_input_data.module = m;
- sink_input_data.sink = u->master;
+ pa_sink_input_new_data_set_sink(&sink_input_data, master, FALSE);
+ sink_input_data.origin_sink = u->sink;
pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_NAME, "LADSPA Stream");
pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ROLE, "filter");
pa_sink_input_new_data_set_sample_spec(&sink_input_data, &ss);
pa_sink_input_new_data_set_channel_map(&sink_input_data, &map);
- pa_sink_input_new(&u->sink_input, m->core, &sink_input_data, PA_SINK_INPUT_DONT_MOVE);
+ pa_sink_input_new(&u->sink_input, m->core, &sink_input_data);
pa_sink_input_new_data_done(&sink_input_data);
if (!u->sink_input)
@@ -751,18 +924,23 @@ int pa__init(pa_module*m) {
u->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
u->sink_input->update_max_request = sink_input_update_max_request_cb;
u->sink_input->update_sink_latency_range = sink_input_update_sink_latency_range_cb;
+ u->sink_input->update_sink_fixed_latency = sink_input_update_sink_fixed_latency_cb;
u->sink_input->kill = sink_input_kill_cb;
u->sink_input->attach = sink_input_attach_cb;
u->sink_input->detach = sink_input_detach_cb;
u->sink_input->state_change = sink_input_state_change_cb;
u->sink_input->may_move_to = sink_input_may_move_to_cb;
+ u->sink_input->moving = sink_input_moving_cb;
+ u->sink_input->volume_changed = sink_input_volume_changed_cb;
+ u->sink_input->mute_changed = sink_input_mute_changed_cb;
u->sink_input->userdata = u;
+ u->sink->input_to_master = u->sink_input;
+
pa_sink_put(u->sink);
pa_sink_input_put(u->sink_input);
pa_modargs_free(ma);
-
pa_xfree(use_default);
return 0;
@@ -796,32 +974,51 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
- if (u->sink) {
- pa_sink_unlink(u->sink);
- pa_sink_unref(u->sink);
- }
+ /* See comments in sink_input_kill_cb() above regarding
+ * destruction order! */
- if (u->sink_input) {
+ if (u->sink_input)
pa_sink_input_unlink(u->sink_input);
+
+ if (u->sink)
+ pa_sink_unlink(u->sink);
+
+ if (u->sink_input)
pa_sink_input_unref(u->sink_input);
- }
- for (c = 0; c < u->channels; c++)
+ if (u->sink)
+ pa_sink_unref(u->sink);
+
+ for (c = 0; c < (u->channels / u->max_ladspaport_count); c++) {
if (u->handle[c]) {
if (u->descriptor->deactivate)
u->descriptor->deactivate(u->handle[c]);
u->descriptor->cleanup(u->handle[c]);
}
+ }
- if (u->output != u->input)
- pa_xfree(u->output);
+ if (u->output == u->input) {
+ if (u->input != NULL) {
+ for (c = 0; c < u->max_ladspaport_count; c++)
+ pa_xfree(u->input[c]);
+ pa_xfree(u->input);
+ }
+ } else {
+ if (u->input != NULL) {
+ for (c = 0; c < u->input_count; c++)
+ pa_xfree(u->input[c]);
+ pa_xfree(u->input);
+ }
+ if (u->output != NULL) {
+ for (c = 0; c < u->output_count; c++)
+ pa_xfree(u->output[c]);
+ pa_xfree(u->output);
+ }
+ }
if (u->memblockq)
pa_memblockq_free(u->memblockq);
- pa_xfree(u->input);
-
pa_xfree(u->control);
-
pa_xfree(u);
}
diff --git a/src/modules/module-lirc.c b/src/modules/module-lirc.c
index a1a8726f..15f3442d 100644
--- a/src/modules/module-lirc.c
+++ b/src/modules/module-lirc.c
@@ -45,12 +45,14 @@ PA_MODULE_AUTHOR("Lennart Poettering");
PA_MODULE_DESCRIPTION("LIRC volume control");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
-PA_MODULE_USAGE("config=<config file> sink=<sink name> appname=<lirc application name>");
+PA_MODULE_USAGE("config=<config file> sink=<sink name> appname=<lirc application name> volume_limit=<volume limit> volume_step=<volume change step>");
static const char* const valid_modargs[] = {
"config",
"sink",
"appname",
+ "volume_limit",
+ "volume_step",
NULL,
};
@@ -61,6 +63,8 @@ struct userdata {
char *sink_name;
pa_module *module;
float mute_toggle_save;
+ pa_volume_t volume_limit;
+ pa_volume_t volume_step;
};
static void io_callback(pa_mainloop_api *io, pa_io_event *e, int fd, pa_io_event_flags_t events, void*userdata) {
@@ -112,52 +116,36 @@ static void io_callback(pa_mainloop_api *io, pa_io_event *e, int fd, pa_io_event
volchange = RESET;
if (volchange == INVALID)
- pa_log_warn("Recieved unknown IR code '%s'", name);
+ pa_log_warn("Received unknown IR code '%s'", name);
else {
pa_sink *s;
if (!(s = pa_namereg_get(u->module->core, u->sink_name, PA_NAMEREG_SINK)))
pa_log("Failed to get sink '%s'", u->sink_name);
else {
- int i;
- pa_cvolume cv = *pa_sink_get_volume(s, FALSE, FALSE);
-
-#define DELTA (PA_VOLUME_NORM/20)
+ pa_cvolume cv = *pa_sink_get_volume(s, FALSE);
switch (volchange) {
case UP:
- for (i = 0; i < cv.channels; i++) {
- if (cv.values[i] < PA_VOLUME_MAX - DELTA)
- cv.values[i] += DELTA;
- else
- cv.values[i] = PA_VOLUME_MAX;
- }
-
- pa_sink_set_volume(s, &cv, TRUE, TRUE, TRUE);
+ pa_cvolume_inc_clamp(&cv, u->volume_step, u->volume_limit);
+ pa_sink_set_volume(s, &cv, TRUE, TRUE);
break;
case DOWN:
- for (i = 0; i < cv.channels; i++) {
- if (cv.values[i] > DELTA)
- cv.values[i] -= DELTA;
- else
- cv.values[i] = PA_VOLUME_MUTED;
- }
-
- pa_sink_set_volume(s, &cv, TRUE, TRUE, TRUE);
+ pa_cvolume_dec(&cv, u->volume_step);
+ pa_sink_set_volume(s, &cv, TRUE, TRUE);
break;
case MUTE:
- pa_sink_set_mute(s, TRUE);
+ pa_sink_set_mute(s, TRUE, TRUE);
break;
case RESET:
- pa_sink_set_mute(s, FALSE);
+ pa_sink_set_mute(s, FALSE, TRUE);
break;
case MUTE_TOGGLE:
-
- pa_sink_set_mute(s, !pa_sink_get_mute(s, FALSE));
+ pa_sink_set_mute(s, !pa_sink_get_mute(s, FALSE), TRUE);
break;
case INVALID:
@@ -184,6 +172,8 @@ fail:
int pa__init(pa_module*m) {
pa_modargs *ma = NULL;
struct userdata *u;
+ pa_volume_t volume_limit = PA_CLAMP_VOLUME(PA_VOLUME_NORM*3/2);
+ pa_volume_t volume_step = PA_VOLUME_NORM/20;
pa_assert(m);
@@ -192,6 +182,16 @@ int pa__init(pa_module*m) {
goto fail;
}
+ if (pa_modargs_get_value_u32(ma, "volume_limit", &volume_limit) < 0) {
+ pa_log("Failed to parse volume limit");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_u32(ma, "volume_step", &volume_step) < 0) {
+ pa_log("Failed to parse volume step");
+ goto fail;
+ }
+
m->userdata = u = pa_xnew(struct userdata, 1);
u->module = m;
u->io = NULL;
@@ -199,6 +199,8 @@ int pa__init(pa_module*m) {
u->sink_name = pa_xstrdup(pa_modargs_get_value(ma, "sink", NULL));
u->lirc_fd = -1;
u->mute_toggle_save = 0;
+ u->volume_limit = PA_CLAMP_VOLUME(volume_limit);
+ u->volume_step = PA_CLAMP_VOLUME(volume_step);
if ((u->lirc_fd = lirc_init((char*) pa_modargs_get_value(ma, "appname", "pulseaudio"), 1)) < 0) {
pa_log("lirc_init() failed.");
diff --git a/src/modules/module-loopback.c b/src/modules/module-loopback.c
new file mode 100644
index 00000000..cf88267d
--- /dev/null
+++ b/src/modules/module-loopback.c
@@ -0,0 +1,857 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Intel Corporation
+ Contributor: Pierre-Louis Bossart <pierre-louis.bossart@intel.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdio.h>
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/sink-input.h>
+#include <pulsecore/module.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/log.h>
+#include <pulsecore/core-util.h>
+
+#include <pulse/rtclock.h>
+#include <pulse/timeval.h>
+
+#include "module-loopback-symdef.h"
+
+PA_MODULE_AUTHOR("Pierre-Louis Bossart");
+PA_MODULE_DESCRIPTION("Loopback from source to sink");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE(
+ "source=<source to connect to> "
+ "sink=<sink to connect to> "
+ "adjust_time=<how often to readjust rates in s> "
+ "latency_msec=<latency in ms> "
+ "format=<sample format> "
+ "rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<channel map> "
+ "sink_input_name=<custom name for the sink input> "
+ "source_output_name=<custom name for the source output> "
+ "sink_input_role=<media.role for the sink input> "
+ "source_output_role=<media.role for the source output> "
+ "source_dont_move=<boolean> "
+ "sink_dont_move=<boolean> "
+ "remix=<remix channels?> ");
+
+#define DEFAULT_LATENCY_MSEC 200
+
+#define MEMBLOCKQ_MAXLENGTH (1024*1024*16)
+
+#define DEFAULT_ADJUST_TIME_USEC (10*PA_USEC_PER_SEC)
+
+struct userdata {
+ pa_core *core;
+ pa_module *module;
+
+ pa_sink_input *sink_input;
+ pa_source_output *source_output;
+
+ pa_asyncmsgq *asyncmsgq;
+ pa_memblockq *memblockq;
+
+ pa_rtpoll_item *rtpoll_item_read, *rtpoll_item_write;
+
+ pa_time_event *time_event;
+ pa_usec_t adjust_time;
+
+ int64_t recv_counter;
+ int64_t send_counter;
+
+ size_t skip;
+ pa_usec_t latency;
+
+ pa_bool_t in_pop;
+ size_t min_memblockq_length;
+
+ struct {
+ int64_t send_counter;
+ size_t source_output_buffer;
+ pa_usec_t source_latency;
+
+ int64_t recv_counter;
+ size_t sink_input_buffer;
+ pa_usec_t sink_latency;
+
+ size_t min_memblockq_length;
+ size_t max_request;
+ } latency_snapshot;
+};
+
+static const char* const valid_modargs[] = {
+ "source",
+ "sink",
+ "adjust_time",
+ "latency_msec",
+ "format",
+ "rate",
+ "channels",
+ "channel_map",
+ "sink_input_name",
+ "source_output_name",
+ "sink_input_role",
+ "source_output_role",
+ "source_dont_move",
+ "sink_dont_move",
+ "remix",
+ NULL,
+};
+
+enum {
+ SINK_INPUT_MESSAGE_POST = PA_SINK_INPUT_MESSAGE_MAX,
+ SINK_INPUT_MESSAGE_REWIND,
+ SINK_INPUT_MESSAGE_LATENCY_SNAPSHOT,
+ SINK_INPUT_MESSAGE_MAX_REQUEST_CHANGED
+};
+
+enum {
+ SOURCE_OUTPUT_MESSAGE_LATENCY_SNAPSHOT
+};
+
+/* Called from main context */
+static void teardown(struct userdata *u) {
+ pa_assert(u);
+ pa_assert_ctl_context();
+
+ if (u->sink_input)
+ pa_sink_input_unlink(u->sink_input);
+
+ if (u->source_output)
+ pa_source_output_unlink(u->source_output);
+
+ if (u->sink_input) {
+ pa_sink_input_unref(u->sink_input);
+ u->sink_input = NULL;
+ }
+
+ if (u->source_output) {
+ pa_source_output_unref(u->source_output);
+ u->source_output = NULL;
+ }
+}
+
+/* Called from main context */
+static void adjust_rates(struct userdata *u) {
+ size_t buffer, fs;
+ uint32_t old_rate, base_rate, new_rate;
+ pa_usec_t buffer_latency;
+
+ pa_assert(u);
+ pa_assert_ctl_context();
+
+ pa_asyncmsgq_send(u->source_output->source->asyncmsgq, PA_MSGOBJECT(u->source_output), SOURCE_OUTPUT_MESSAGE_LATENCY_SNAPSHOT, NULL, 0, NULL);
+ pa_asyncmsgq_send(u->sink_input->sink->asyncmsgq, PA_MSGOBJECT(u->sink_input), SINK_INPUT_MESSAGE_LATENCY_SNAPSHOT, NULL, 0, NULL);
+
+ buffer =
+ u->latency_snapshot.sink_input_buffer +
+ u->latency_snapshot.source_output_buffer;
+
+ if (u->latency_snapshot.recv_counter <= u->latency_snapshot.send_counter)
+ buffer += (size_t) (u->latency_snapshot.send_counter - u->latency_snapshot.recv_counter);
+ else
+ buffer += PA_CLIP_SUB(buffer, (size_t) (u->latency_snapshot.recv_counter - u->latency_snapshot.send_counter));
+
+ buffer_latency = pa_bytes_to_usec(buffer, &u->sink_input->sample_spec);
+
+ pa_log_debug("Loopback overall latency is %0.2f ms + %0.2f ms + %0.2f ms = %0.2f ms",
+ (double) u->latency_snapshot.sink_latency / PA_USEC_PER_MSEC,
+ (double) buffer_latency / PA_USEC_PER_MSEC,
+ (double) u->latency_snapshot.source_latency / PA_USEC_PER_MSEC,
+ ((double) u->latency_snapshot.sink_latency + buffer_latency + u->latency_snapshot.source_latency) / PA_USEC_PER_MSEC);
+
+ pa_log_debug("Should buffer %zu bytes, buffered at minimum %zu bytes",
+ u->latency_snapshot.max_request*2,
+ u->latency_snapshot.min_memblockq_length);
+
+ fs = pa_frame_size(&u->sink_input->sample_spec);
+ old_rate = u->sink_input->sample_spec.rate;
+ base_rate = u->source_output->sample_spec.rate;
+
+ if (u->latency_snapshot.min_memblockq_length < u->latency_snapshot.max_request*2)
+ new_rate = base_rate - (((u->latency_snapshot.max_request*2 - u->latency_snapshot.min_memblockq_length) / fs) *PA_USEC_PER_SEC)/u->adjust_time;
+ else
+ new_rate = base_rate + (((u->latency_snapshot.min_memblockq_length - u->latency_snapshot.max_request*2) / fs) *PA_USEC_PER_SEC)/u->adjust_time;
+
+ if (new_rate < (uint32_t) (base_rate*0.8) || new_rate > (uint32_t) (base_rate*1.25)) {
+ pa_log_warn("Sample rates too different, not adjusting (%u vs. %u).", base_rate, new_rate);
+ new_rate = base_rate;
+ } else {
+ if (base_rate < new_rate + 20 && new_rate < base_rate + 20)
+ new_rate = base_rate;
+ /* Do the adjustment in small steps; 2‰ can be considered inaudible */
+ if (new_rate < (uint32_t) (old_rate*0.998) || new_rate > (uint32_t) (old_rate*1.002)) {
+ pa_log_info("New rate of %u Hz not within 2‰ of %u Hz, forcing smaller adjustment", new_rate, old_rate);
+ new_rate = PA_CLAMP(new_rate, (uint32_t) (old_rate*0.998), (uint32_t) (old_rate*1.002));
+ }
+ }
+
+ pa_sink_input_set_rate(u->sink_input, new_rate);
+ pa_log_debug("[%s] Updated sampling rate to %lu Hz.", u->sink_input->sink->name, (unsigned long) new_rate);
+
+ pa_core_rttime_restart(u->core, u->time_event, pa_rtclock_now() + u->adjust_time);
+}
+
+/* Called from main context */
+static void time_callback(pa_mainloop_api *a, pa_time_event *e, const struct timeval *t, void *userdata) {
+ struct userdata *u = userdata;
+
+ pa_assert(u);
+ pa_assert(a);
+ pa_assert(u->time_event == e);
+
+ adjust_rates(u);
+}
+
+/* Called from input thread context */
+static void source_output_push_cb(pa_source_output *o, const pa_memchunk *chunk) {
+ struct userdata *u;
+ pa_memchunk copy;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ if (u->skip > chunk->length) {
+ u->skip -= chunk->length;
+ return;
+ }
+
+ if (u->skip > 0) {
+ copy = *chunk;
+ copy.index += u->skip;
+ copy.length -= u->skip;
+ u->skip = 0;
+
+ chunk = &copy;
+ }
+
+ pa_asyncmsgq_post(u->asyncmsgq, PA_MSGOBJECT(u->sink_input), SINK_INPUT_MESSAGE_POST, NULL, 0, chunk, NULL);
+ u->send_counter += (int64_t) chunk->length;
+}
+
+/* Called from input thread context */
+static void source_output_process_rewind_cb(pa_source_output *o, size_t nbytes) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_asyncmsgq_post(u->asyncmsgq, PA_MSGOBJECT(u->sink_input), SINK_INPUT_MESSAGE_REWIND, NULL, (int64_t) nbytes, NULL, NULL);
+ u->send_counter -= (int64_t) nbytes;
+}
+
+/* Called from output thread context */
+static int source_output_process_msg_cb(pa_msgobject *obj, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SOURCE_OUTPUT(obj)->userdata;
+
+ switch (code) {
+
+ case SOURCE_OUTPUT_MESSAGE_LATENCY_SNAPSHOT: {
+ size_t length;
+
+ length = pa_memblockq_get_length(u->source_output->thread_info.delay_memblockq);
+
+ u->latency_snapshot.send_counter = u->send_counter;
+ u->latency_snapshot.source_output_buffer = u->source_output->thread_info.resampler ? pa_resampler_result(u->source_output->thread_info.resampler, length) : length;
+ u->latency_snapshot.source_latency = pa_source_get_latency_within_thread(u->source_output->source);
+
+ return 0;
+ }
+ }
+
+ return pa_source_output_process_msg(obj, code, data, offset, chunk);
+}
+
+/* Called from output thread context */
+static void source_output_attach_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ u->rtpoll_item_write = pa_rtpoll_item_new_asyncmsgq_write(
+ o->source->thread_info.rtpoll,
+ PA_RTPOLL_LATE,
+ u->asyncmsgq);
+}
+
+/* Called from output thread context */
+static void source_output_detach_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ if (u->rtpoll_item_write) {
+ pa_rtpoll_item_free(u->rtpoll_item_write);
+ u->rtpoll_item_write = NULL;
+ }
+}
+
+/* Called from output thread context */
+static void source_output_state_change_cb(pa_source_output *o, pa_source_output_state_t state) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ if (PA_SOURCE_OUTPUT_IS_LINKED(state) && o->thread_info.state == PA_SOURCE_OUTPUT_INIT) {
+
+ u->skip = pa_usec_to_bytes(PA_CLIP_SUB(pa_source_get_latency_within_thread(o->source),
+ u->latency),
+ &o->sample_spec);
+
+ pa_log_info("Skipping %lu bytes", (unsigned long) u->skip);
+ }
+}
+
+/* Called from main thread */
+static void source_output_kill_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ teardown(u);
+ pa_module_unload_request(u->module, TRUE);
+}
+
+/* Called from main thread */
+static pa_bool_t source_output_may_move_to_cb(pa_source_output *o, pa_source *dest) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ return dest != u->sink_input->sink->monitor_source;
+}
+
+/* Called from main thread */
+static void source_output_moving_cb(pa_source_output *o, pa_source *dest) {
+ pa_proplist *p;
+ const char *n;
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ p = pa_proplist_new();
+ pa_proplist_setf(p, PA_PROP_MEDIA_NAME, "Loopback of %s", pa_strnull(pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION)));
+
+ if ((n = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_ICON_NAME)))
+ pa_proplist_sets(p, PA_PROP_MEDIA_ICON_NAME, n);
+
+ pa_sink_input_update_proplist(u->sink_input, PA_UPDATE_REPLACE, p);
+ pa_proplist_free(p);
+}
+
+/* Called from output thread context */
+static void update_min_memblockq_length(struct userdata *u) {
+ size_t length;
+
+ pa_assert(u);
+ pa_sink_input_assert_io_context(u->sink_input);
+
+ length = pa_memblockq_get_length(u->memblockq);
+
+ if (u->min_memblockq_length == (size_t) -1 ||
+ length < u->min_memblockq_length)
+ u->min_memblockq_length = length;
+}
+
+/* Called from output thread context */
+static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+ pa_assert_se(u = i->userdata);
+ pa_assert(chunk);
+
+ u->in_pop = TRUE;
+ while (pa_asyncmsgq_process_one(u->asyncmsgq) > 0)
+ ;
+ u->in_pop = FALSE;
+
+ if (pa_memblockq_peek(u->memblockq, chunk) < 0) {
+ pa_log_info("Could not peek into queue");
+ return -1;
+ }
+
+ chunk->length = PA_MIN(chunk->length, nbytes);
+ pa_memblockq_drop(u->memblockq, chunk->length);
+
+ update_min_memblockq_length(u);
+
+ return 0;
+}
+
+/* Called from output thread context */
+static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_memblockq_rewind(u->memblockq, nbytes);
+}
+
+/* Called from output thread context */
+static int sink_input_process_msg_cb(pa_msgobject *obj, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SINK_INPUT(obj)->userdata;
+
+ switch (code) {
+
+ case PA_SINK_INPUT_MESSAGE_GET_LATENCY: {
+ pa_usec_t *r = data;
+
+ pa_sink_input_assert_io_context(u->sink_input);
+
+ *r = pa_bytes_to_usec(pa_memblockq_get_length(u->memblockq), &u->sink_input->sample_spec);
+
+ /* Fall through, the default handler will add in the extra
+ * latency added by the resampler */
+ break;
+ }
+
+ case SINK_INPUT_MESSAGE_POST:
+
+ pa_sink_input_assert_io_context(u->sink_input);
+
+ if (PA_SINK_IS_OPENED(u->sink_input->sink->thread_info.state))
+ pa_memblockq_push_align(u->memblockq, chunk);
+ else
+ pa_memblockq_flush_write(u->memblockq, TRUE);
+
+ update_min_memblockq_length(u);
+
+ /* Is this the end of an underrun? Then let's start things
+ * right-away */
+ if (!u->in_pop &&
+ u->sink_input->thread_info.underrun_for > 0 &&
+ pa_memblockq_is_readable(u->memblockq)) {
+
+ pa_log_debug("Requesting rewind due to end of underrun.");
+ pa_sink_input_request_rewind(u->sink_input,
+ (size_t) (u->sink_input->thread_info.underrun_for == (size_t) -1 ? 0 : u->sink_input->thread_info.underrun_for),
+ FALSE, TRUE, FALSE);
+ }
+
+ u->recv_counter += (int64_t) chunk->length;
+
+ return 0;
+
+ case SINK_INPUT_MESSAGE_REWIND:
+
+ pa_sink_input_assert_io_context(u->sink_input);
+
+ if (PA_SINK_IS_OPENED(u->sink_input->sink->thread_info.state))
+ pa_memblockq_seek(u->memblockq, -offset, PA_SEEK_RELATIVE, TRUE);
+ else
+ pa_memblockq_flush_write(u->memblockq, TRUE);
+
+ u->recv_counter -= offset;
+
+ update_min_memblockq_length(u);
+
+ return 0;
+
+ case SINK_INPUT_MESSAGE_LATENCY_SNAPSHOT: {
+ size_t length;
+
+ update_min_memblockq_length(u);
+
+ length = pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq);
+
+ u->latency_snapshot.recv_counter = u->recv_counter;
+ u->latency_snapshot.sink_input_buffer =
+ pa_memblockq_get_length(u->memblockq) +
+ (u->sink_input->thread_info.resampler ? pa_resampler_request(u->sink_input->thread_info.resampler, length) : length);
+ u->latency_snapshot.sink_latency = pa_sink_get_latency_within_thread(u->sink_input->sink);
+
+ u->latency_snapshot.max_request = pa_sink_input_get_max_request(u->sink_input);
+
+ u->latency_snapshot.min_memblockq_length = u->min_memblockq_length;
+ u->min_memblockq_length = (size_t) -1;
+
+ return 0;
+ }
+
+ case SINK_INPUT_MESSAGE_MAX_REQUEST_CHANGED: {
+ /* This message is sent from the IO thread to the main
+ * thread! So don't be confused. All the user cases above
+ * are executed in thread context, but this one is not! */
+
+ pa_assert_ctl_context();
+
+ if (u->adjust_time > 0)
+ adjust_rates(u);
+ return 0;
+ }
+ }
+
+ return pa_sink_input_process_msg(obj, code, data, offset, chunk);
+}
+
+/* Called from output thread context */
+static void sink_input_attach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+ pa_assert_se(u = i->userdata);
+
+ u->rtpoll_item_read = pa_rtpoll_item_new_asyncmsgq_read(
+ i->sink->thread_info.rtpoll,
+ PA_RTPOLL_LATE,
+ u->asyncmsgq);
+
+ pa_memblockq_set_prebuf(u->memblockq, pa_sink_input_get_max_request(i)*2);
+ pa_memblockq_set_maxrewind(u->memblockq, pa_sink_input_get_max_rewind(i));
+
+ u->min_memblockq_length = (size_t) -1;
+}
+
+/* Called from output thread context */
+static void sink_input_detach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+ pa_assert_se(u = i->userdata);
+
+ if (u->rtpoll_item_read) {
+ pa_rtpoll_item_free(u->rtpoll_item_read);
+ u->rtpoll_item_read = NULL;
+ }
+}
+
+/* Called from output thread context */
+static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_memblockq_set_maxrewind(u->memblockq, nbytes);
+}
+
+/* Called from output thread context */
+static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_memblockq_set_prebuf(u->memblockq, nbytes*2);
+ pa_log_info("Max request changed");
+ pa_asyncmsgq_post(pa_thread_mq_get()->outq, PA_MSGOBJECT(u->sink_input), SINK_INPUT_MESSAGE_MAX_REQUEST_CHANGED, NULL, 0, NULL, NULL);
+}
+
+/* Called from main thread */
+static void sink_input_kill_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
+ pa_assert_se(u = i->userdata);
+
+ teardown(u);
+ pa_module_unload_request(u->module, TRUE);
+}
+
+/* Called from main thread */
+static void sink_input_moving_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+ pa_proplist *p;
+ const char *n;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
+ pa_assert_se(u = i->userdata);
+
+ p = pa_proplist_new();
+ pa_proplist_setf(p, PA_PROP_MEDIA_NAME, "Loopback to %s", pa_strnull(pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION)));
+
+ if ((n = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_ICON_NAME)))
+ pa_proplist_sets(p, PA_PROP_MEDIA_ICON_NAME, n);
+
+ pa_source_output_update_proplist(u->source_output, PA_UPDATE_REPLACE, p);
+ pa_proplist_free(p);
+}
+
+/* Called from main thread */
+static pa_bool_t sink_input_may_move_to_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
+ pa_assert_se(u = i->userdata);
+
+ if (!u->source_output->source->monitor_of)
+ return TRUE;
+
+ return dest != u->source_output->source->monitor_of;
+}
+
+int pa__init(pa_module *m) {
+ pa_modargs *ma = NULL;
+ struct userdata *u;
+ pa_sink *sink;
+ pa_sink_input_new_data sink_input_data;
+ pa_bool_t sink_dont_move;
+ pa_source *source;
+ pa_source_output_new_data source_output_data;
+ pa_bool_t source_dont_move;
+ uint32_t latency_msec;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ pa_memchunk silence;
+ uint32_t adjust_time_sec;
+ const char *n;
+ pa_bool_t remix = TRUE;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ if (!(source = pa_namereg_get(m->core, pa_modargs_get_value(ma, "source", NULL), PA_NAMEREG_SOURCE))) {
+ pa_log("No such source.");
+ goto fail;
+ }
+
+ if (!(sink = pa_namereg_get(m->core, pa_modargs_get_value(ma, "sink", NULL), PA_NAMEREG_SINK))) {
+ pa_log("No such sink.");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "remix", &remix) < 0) {
+ pa_log("Invalid boolean remix parameter");
+ goto fail;
+ }
+
+ ss = sink->sample_spec;
+ map = sink->channel_map;
+ if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_DEFAULT) < 0) {
+ pa_log("Invalid sample format specification or channel map");
+ goto fail;
+ }
+
+ latency_msec = DEFAULT_LATENCY_MSEC;
+ if (pa_modargs_get_value_u32(ma, "latency_msec", &latency_msec) < 0 || latency_msec < 1 || latency_msec > 2000) {
+ pa_log("Invalid latency specification");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->module = m;
+ u->latency = (pa_usec_t) latency_msec * PA_USEC_PER_MSEC;
+
+ adjust_time_sec = DEFAULT_ADJUST_TIME_USEC / PA_USEC_PER_SEC;
+ if (pa_modargs_get_value_u32(ma, "adjust_time", &adjust_time_sec) < 0) {
+ pa_log("Failed to parse adjust_time value");
+ goto fail;
+ }
+
+ if (adjust_time_sec != DEFAULT_ADJUST_TIME_USEC / PA_USEC_PER_SEC)
+ u->adjust_time = adjust_time_sec * PA_USEC_PER_SEC;
+ else
+ u->adjust_time = DEFAULT_ADJUST_TIME_USEC;
+
+ pa_sink_input_new_data_init(&sink_input_data);
+ sink_input_data.driver = __FILE__;
+ sink_input_data.module = m;
+ pa_sink_input_new_data_set_sink(&sink_input_data, sink, FALSE);
+
+ if ((n = pa_modargs_get_value(ma, "sink_input_name", NULL)))
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_NAME, n);
+ else
+ pa_proplist_setf(sink_input_data.proplist, PA_PROP_MEDIA_NAME, "Loopback from %s",
+ pa_strnull(pa_proplist_gets(source->proplist, PA_PROP_DEVICE_DESCRIPTION)));
+
+ if ((n = pa_modargs_get_value(ma, "sink_input_role", NULL)))
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ROLE, n);
+ else
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ROLE, "abstract");
+
+ if ((n = pa_proplist_gets(source->proplist, PA_PROP_DEVICE_ICON_NAME)))
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ICON_NAME, n);
+
+ pa_sink_input_new_data_set_sample_spec(&sink_input_data, &ss);
+ pa_sink_input_new_data_set_channel_map(&sink_input_data, &map);
+ sink_input_data.flags = PA_SINK_INPUT_VARIABLE_RATE | (remix ? 0 : PA_SINK_INPUT_NO_REMIX);
+
+ sink_dont_move = FALSE;
+ if (pa_modargs_get_value_boolean(ma, "sink_dont_move", &sink_dont_move) < 0) {
+ pa_log("sink_dont_move= expects a boolean argument.");
+ goto fail;
+ }
+
+ if (sink_dont_move)
+ sink_input_data.flags |= PA_SINK_INPUT_DONT_MOVE;
+
+ pa_sink_input_new(&u->sink_input, m->core, &sink_input_data);
+ pa_sink_input_new_data_done(&sink_input_data);
+
+ if (!u->sink_input)
+ goto fail;
+
+ u->sink_input->parent.process_msg = sink_input_process_msg_cb;
+ u->sink_input->pop = sink_input_pop_cb;
+ u->sink_input->process_rewind = sink_input_process_rewind_cb;
+ u->sink_input->kill = sink_input_kill_cb;
+ u->sink_input->attach = sink_input_attach_cb;
+ u->sink_input->detach = sink_input_detach_cb;
+ u->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
+ u->sink_input->update_max_request = sink_input_update_max_request_cb;
+ u->sink_input->may_move_to = sink_input_may_move_to_cb;
+ u->sink_input->moving = sink_input_moving_cb;
+ u->sink_input->userdata = u;
+
+ pa_sink_input_set_requested_latency(u->sink_input, u->latency/3);
+
+ pa_source_output_new_data_init(&source_output_data);
+ source_output_data.driver = __FILE__;
+ source_output_data.module = m;
+ pa_source_output_new_data_set_source(&source_output_data, source, FALSE);
+
+ if ((n = pa_modargs_get_value(ma, "source_output_name", NULL)))
+ pa_proplist_sets(source_output_data.proplist, PA_PROP_MEDIA_NAME, n);
+ else
+ pa_proplist_setf(source_output_data.proplist, PA_PROP_MEDIA_NAME, "Loopback to %s",
+ pa_strnull(pa_proplist_gets(sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
+
+ if ((n = pa_modargs_get_value(ma, "source_output_role", NULL)))
+ pa_proplist_sets(source_output_data.proplist, PA_PROP_MEDIA_ROLE, n);
+ else
+ pa_proplist_sets(source_output_data.proplist, PA_PROP_MEDIA_ROLE, "abstract");
+
+ if ((n = pa_proplist_gets(sink->proplist, PA_PROP_DEVICE_ICON_NAME)))
+ pa_proplist_sets(source_output_data.proplist, PA_PROP_MEDIA_ICON_NAME, n);
+
+ pa_source_output_new_data_set_sample_spec(&source_output_data, &ss);
+ pa_source_output_new_data_set_channel_map(&source_output_data, &map);
+ source_output_data.flags = (remix ? 0 : PA_SOURCE_OUTPUT_NO_REMIX);
+
+ source_dont_move = FALSE;
+ if (pa_modargs_get_value_boolean(ma, "source_dont_move", &source_dont_move) < 0) {
+ pa_log("source_dont_move= expects a boolean argument.");
+ goto fail;
+ }
+
+ if (source_dont_move)
+ source_output_data.flags |= PA_SOURCE_OUTPUT_DONT_MOVE;
+
+ pa_source_output_new(&u->source_output, m->core, &source_output_data);
+ pa_source_output_new_data_done(&source_output_data);
+
+ if (!u->source_output)
+ goto fail;
+
+ u->source_output->parent.process_msg = source_output_process_msg_cb;
+ u->source_output->push = source_output_push_cb;
+ u->source_output->process_rewind = source_output_process_rewind_cb;
+ u->source_output->kill = source_output_kill_cb;
+ u->source_output->attach = source_output_attach_cb;
+ u->source_output->detach = source_output_detach_cb;
+ u->source_output->state_change = source_output_state_change_cb;
+ u->source_output->may_move_to = source_output_may_move_to_cb;
+ u->source_output->moving = source_output_moving_cb;
+ u->source_output->userdata = u;
+
+ pa_source_output_set_requested_latency(u->source_output, u->latency/3);
+
+ pa_sink_input_get_silence(u->sink_input, &silence);
+ u->memblockq = pa_memblockq_new(
+ 0, /* idx */
+ MEMBLOCKQ_MAXLENGTH, /* maxlength */
+ MEMBLOCKQ_MAXLENGTH, /* tlength */
+ pa_frame_size(&ss), /* base */
+ 0, /* prebuf */
+ 0, /* minreq */
+ 0, /* maxrewind */
+ &silence); /* silence frame */
+ pa_memblock_unref(silence.memblock);
+
+ u->asyncmsgq = pa_asyncmsgq_new(0);
+
+ pa_sink_input_put(u->sink_input);
+ pa_source_output_put(u->source_output);
+
+ if (u->adjust_time > 0)
+ u->time_event = pa_core_rttime_new(m->core, pa_rtclock_now() + u->adjust_time, time_callback, u);
+
+ pa_modargs_free(ma);
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ teardown(u);
+
+ if (u->memblockq)
+ pa_memblockq_free(u->memblockq);
+
+ if (u->asyncmsgq)
+ pa_asyncmsgq_unref(u->asyncmsgq);
+
+ if (u->time_event)
+ u->core->mainloop->time_free(u->time_event);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-match.c b/src/modules/module-match.c
index 625f2a8b..c94ef790 100644
--- a/src/modules/module-match.c
+++ b/src/modules/module-match.c
@@ -27,10 +27,15 @@
#include <string.h>
#include <errno.h>
#include <sys/types.h>
-#include <regex.h>
#include <stdio.h>
#include <stdlib.h>
+#if defined(HAVE_REGEX_H)
+#include <regex.h>
+#elif defined(HAVE_PCREPOSIX_H)
+#include <pcreposix.h>
+#endif
+
#include <pulse/xmalloc.h>
#include <pulsecore/core-error.h>
@@ -38,7 +43,6 @@
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-subscribe.h>
#include <pulsecore/sink-input.h>
#include <pulsecore/core-util.h>
@@ -56,6 +60,9 @@ PA_MODULE_USAGE("table=<filename> "
#define DEFAULT_MATCH_TABLE_FILE PA_DEFAULT_CONFIG_DIR"/match.table"
#define DEFAULT_MATCH_TABLE_FILE_USER "match.table"
+#define UPDATE_REPLACE "replace"
+#define UPDATE_MERGE "merge"
+
static const char* const valid_modargs[] = {
"table",
"key",
@@ -66,13 +73,14 @@ struct rule {
regex_t regex;
pa_volume_t volume;
pa_proplist *proplist;
+ pa_update_mode_t mode;
struct rule *next;
};
struct userdata {
struct rule *rules;
char *property_key;
- pa_subscription *subscription;
+ pa_hook_slot *sink_input_new_hook_slot;
};
static int load_rules(struct userdata *u, const char *filename) {
@@ -85,12 +93,11 @@ static int load_rules(struct userdata *u, const char *filename) {
pa_assert(u);
if (filename)
- f = fopen(fn = pa_xstrdup(filename), "r");
+ f = pa_fopen_cloexec(fn = pa_xstrdup(filename), "r");
else
f = pa_open_config_file(DEFAULT_MATCH_TABLE_FILE, DEFAULT_MATCH_TABLE_FILE_USER, NULL, &fn);
if (!f) {
- pa_xfree(fn);
pa_log("Failed to open file config file: %s", pa_cstrerror(errno));
goto finish;
}
@@ -98,13 +105,14 @@ static int load_rules(struct userdata *u, const char *filename) {
pa_lock_fd(fileno(f), 1);
while (!feof(f)) {
- char *d, *v;
+ char *token_end, *value_str;
pa_volume_t volume = PA_VOLUME_NORM;
uint32_t k;
regex_t regex;
char ln[256];
struct rule *rule;
pa_proplist *proplist = NULL;
+ pa_update_mode_t mode = (pa_update_mode_t) -1;
if (!fgets(ln, sizeof(ln), f))
break;
@@ -116,51 +124,72 @@ static int load_rules(struct userdata *u, const char *filename) {
if (ln[0] == '#' || !*ln )
continue;
- d = ln+strcspn(ln, WHITESPACE);
- v = d+strspn(d, WHITESPACE);
+ token_end = ln + strcspn(ln, WHITESPACE);
+ value_str = token_end + strspn(token_end, WHITESPACE);
+ *token_end = 0;
+ if (!*ln) {
+ pa_log("[%s:%u] failed to parse line - missing regexp", fn, n);
+ goto finish;
+ }
- if (!*v) {
- pa_log(__FILE__ ": [%s:%u] failed to parse line - too few words", filename, n);
+ if (!*value_str) {
+ pa_log("[%s:%u] failed to parse line - too few words", fn, n);
goto finish;
}
- *d = 0;
- if (pa_atou(v, &k) >= 0) {
- volume = (pa_volume_t) k;
- } else if (*v == '"') {
- char *e;
-
- e = strchr(v+1, '"');
- if (!e) {
- pa_log(__FILE__ ": [%s:%u] failed to parse line - missing role closing quote", filename, n);
- goto finish;
- }
-
- *e = '\0';
- e = pa_sprintf_malloc("media.role=\"%s\"", v+1);
- proplist = pa_proplist_from_string(e);
- pa_xfree(e);
- } else {
- char *e;
-
- e = v+strspn(v, WHITESPACE);
- if (!*e) {
- pa_log(__FILE__ ": [%s:%u] failed to parse line - missing end of property list", filename, n);
- goto finish;
- }
- *e = '\0';
- proplist = pa_proplist_from_string(v);
+ if (pa_atou(value_str, &k) >= 0)
+ volume = (pa_volume_t) PA_CLAMP_VOLUME(k);
+ else {
+ size_t len;
+
+ token_end = value_str + strcspn(value_str, WHITESPACE);
+
+ len = token_end - value_str;
+ if (len == (sizeof(UPDATE_REPLACE) - 1) && !strncmp(value_str, UPDATE_REPLACE, len))
+ mode = PA_UPDATE_REPLACE;
+ else if (len == (sizeof(UPDATE_MERGE) - 1) && !strncmp(value_str, UPDATE_MERGE, len))
+ mode = PA_UPDATE_MERGE;
+
+ if (mode != (pa_update_mode_t) -1) {
+ value_str = token_end + strspn(token_end, WHITESPACE);
+
+ if (!*value_str) {
+ pa_log("[%s:%u] failed to parse line - too few words", fn, n);
+ goto finish;
+ }
+ } else
+ mode = PA_UPDATE_MERGE;
+
+ if (*value_str == '"') {
+ value_str++;
+
+ token_end = strchr(value_str, '"');
+ if (!token_end) {
+ pa_log("[%s:%u] failed to parse line - missing role closing quote", fn, n);
+ goto finish;
+ }
+ } else
+ token_end = value_str + strcspn(value_str, WHITESPACE);
+
+ *token_end = 0;
+
+ value_str = pa_sprintf_malloc("media.role=\"%s\"", value_str);
+ proplist = pa_proplist_from_string(value_str);
+ pa_xfree(value_str);
}
if (regcomp(&regex, ln, REG_EXTENDED|REG_NOSUB) != 0) {
- pa_log("[%s:%u] invalid regular expression", filename, n);
+ pa_log("[%s:%u] invalid regular expression", fn, n);
+ if (proplist)
+ pa_proplist_free(proplist);
goto finish;
}
rule = pa_xnew(struct rule, 1);
rule->regex = regex;
rule->proplist = proplist;
+ rule->mode = mode;
rule->volume = volume;
rule->next = NULL;
@@ -169,8 +198,6 @@ static int load_rules(struct userdata *u, const char *filename) {
else
u->rules = rule;
end = rule;
-
- *d = 0;
}
ret = 0;
@@ -181,29 +208,20 @@ finish:
fclose(f);
}
- if (fn)
- pa_xfree(fn);
+ pa_xfree(fn);
return ret;
}
-static void callback(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
- struct userdata *u = userdata;
- pa_sink_input *si;
+static pa_hook_result_t sink_input_new_hook_callback(pa_core *c, pa_sink_input_new_data *si, struct userdata *u) {
struct rule *r;
const char *n;
pa_assert(c);
pa_assert(u);
- if (t != (PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_NEW))
- return;
-
- if (!(si = pa_idxset_get_by_index(c->sink_inputs, idx)))
- return;
-
if (!(n = pa_proplist_gets(si->proplist, u->property_key)))
- return;
+ return PA_HOOK_OK;
pa_log_debug("Matching with %s", n);
@@ -211,15 +229,18 @@ static void callback(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, v
if (!regexec(&r->regex, n, 0, NULL, 0)) {
if (r->proplist) {
pa_log_debug("updating proplist of sink input '%s'", n);
- pa_proplist_update(si->proplist, PA_UPDATE_MERGE, r->proplist);
- } else {
+ pa_proplist_update(si->proplist, r->mode, r->proplist);
+ } else if (si->volume_writable) {
pa_cvolume cv;
pa_log_debug("changing volume of sink input '%s' to 0x%03x", n, r->volume);
pa_cvolume_set(&cv, si->sample_spec.channels, r->volume);
- pa_sink_input_set_volume(si, &cv, TRUE, TRUE);
- }
+ pa_sink_input_new_data_set_volume(si, &cv);
+ } else
+ pa_log_debug("the volume of sink input '%s' is not writable, can't change it", n);
}
}
+
+ return PA_HOOK_OK;
}
int pa__init(pa_module*m) {
@@ -233,9 +254,8 @@ int pa__init(pa_module*m) {
goto fail;
}
- u = pa_xnew(struct userdata, 1);
+ u = pa_xnew0(struct userdata, 1);
u->rules = NULL;
- u->subscription = NULL;
m->userdata = u;
u->property_key = pa_xstrdup(pa_modargs_get_value(ma, "key", PA_PROP_MEDIA_NAME));
@@ -243,7 +263,8 @@ int pa__init(pa_module*m) {
if (load_rules(u, pa_modargs_get_value(ma, "table", NULL)) < 0)
goto fail;
- u->subscription = pa_subscription_new(m->core, PA_SUBSCRIPTION_MASK_SINK_INPUT, callback, u);
+ /* hook EARLY - 1, to match before stream-restore */
+ u->sink_input_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_NEW], PA_HOOK_EARLY - 1, (pa_hook_cb_t) sink_input_new_hook_callback, u);
pa_modargs_free(ma);
return 0;
@@ -253,7 +274,7 @@ fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
}
void pa__done(pa_module*m) {
@@ -265,8 +286,8 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
- if (u->subscription)
- pa_subscription_free(u->subscription);
+ if (u->sink_input_new_hook_slot)
+ pa_hook_slot_free(u->sink_input_new_hook_slot);
if (u->property_key)
pa_xfree(u->property_key);
diff --git a/src/modules/module-mmkbd-evdev.c b/src/modules/module-mmkbd-evdev.c
index d8b9c79e..4e89aed9 100644
--- a/src/modules/module-mmkbd-evdev.c
+++ b/src/modules/module-mmkbd-evdev.c
@@ -48,13 +48,15 @@ PA_MODULE_AUTHOR("Lennart Poettering");
PA_MODULE_DESCRIPTION("Multimedia keyboard support via Linux evdev");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(FALSE);
-PA_MODULE_USAGE("device=<evdev device> sink=<sink name>");
+PA_MODULE_USAGE("device=<evdev device> sink=<sink name> volume_limit=<volume limit> volume_step=<volume change step>");
#define DEFAULT_DEVICE "/dev/input/event0"
static const char* const valid_modargs[] = {
"device",
"sink",
+ "volume_limit",
+ "volume_step",
NULL,
};
@@ -63,6 +65,8 @@ struct userdata {
pa_io_event *io;
char *sink_name;
pa_module *module;
+ pa_volume_t volume_limit;
+ pa_volume_t volume_step;
};
static void io_callback(pa_mainloop_api *io, pa_io_event *e, int fd, pa_io_event_flags_t events, void*userdata) {
@@ -85,14 +89,27 @@ static void io_callback(pa_mainloop_api *io, pa_io_event *e, int fd, pa_io_event
}
if (ev.type == EV_KEY && (ev.value == 1 || ev.value == 2)) {
- enum { INVALID, UP, DOWN, MUTE_TOGGLE } volchange = INVALID;
+ enum {
+ INVALID,
+ UP,
+ DOWN,
+ MUTE_TOGGLE
+ } volchange = INVALID;
pa_log_debug("Key code=%u, value=%u", ev.code, ev.value);
switch (ev.code) {
- case KEY_VOLUMEDOWN: volchange = DOWN; break;
- case KEY_VOLUMEUP: volchange = UP; break;
- case KEY_MUTE: volchange = MUTE_TOGGLE; break;
+ case KEY_VOLUMEDOWN:
+ volchange = DOWN;
+ break;
+
+ case KEY_VOLUMEUP:
+ volchange = UP;
+ break;
+
+ case KEY_MUTE:
+ volchange = MUTE_TOGGLE;
+ break;
}
if (volchange != INVALID) {
@@ -101,37 +118,21 @@ static void io_callback(pa_mainloop_api *io, pa_io_event *e, int fd, pa_io_event
if (!(s = pa_namereg_get(u->module->core, u->sink_name, PA_NAMEREG_SINK)))
pa_log("Failed to get sink '%s'", u->sink_name);
else {
- int i;
- pa_cvolume cv = *pa_sink_get_volume(s, FALSE, FALSE);
-
-#define DELTA (PA_VOLUME_NORM/20)
+ pa_cvolume cv = *pa_sink_get_volume(s, FALSE);
switch (volchange) {
case UP:
- for (i = 0; i < cv.channels; i++) {
- if (cv.values[i] < PA_VOLUME_MAX - DELTA)
- cv.values[i] += DELTA;
- else
- cv.values[i] = PA_VOLUME_MAX;
- }
-
- pa_sink_set_volume(s, &cv, TRUE, TRUE, TRUE);
+ pa_cvolume_inc_clamp(&cv, u->volume_step, u->volume_limit);
+ pa_sink_set_volume(s, &cv, TRUE, TRUE);
break;
case DOWN:
- for (i = 0; i < cv.channels; i++) {
- if (cv.values[i] > DELTA)
- cv.values[i] -= DELTA;
- else
- cv.values[i] = PA_VOLUME_MUTED;
- }
-
- pa_sink_set_volume(s, &cv, TRUE, TRUE, TRUE);
+ pa_cvolume_dec(&cv, u->volume_step);
+ pa_sink_set_volume(s, &cv, TRUE, TRUE);
break;
case MUTE_TOGGLE:
-
- pa_sink_set_mute(s, !pa_sink_get_mute(s, FALSE));
+ pa_sink_set_mute(s, !pa_sink_get_mute(s, FALSE), TRUE);
break;
case INVALID:
@@ -161,6 +162,8 @@ int pa__init(pa_module*m) {
struct input_id input_id;
char name[256];
uint8_t evtype_bitmask[EV_MAX/8 + 1];
+ pa_volume_t volume_limit = PA_VOLUME_NORM*3/2;
+ pa_volume_t volume_step = PA_VOLUME_NORM/20;
pa_assert(m);
@@ -169,14 +172,26 @@ int pa__init(pa_module*m) {
goto fail;
}
+ if (pa_modargs_get_value_u32(ma, "volume_limit", &volume_limit) < 0) {
+ pa_log("Failed to parse volume limit");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_u32(ma, "volume_step", &volume_step) < 0) {
+ pa_log("Failed to parse volume step");
+ goto fail;
+ }
+
m->userdata = u = pa_xnew(struct userdata, 1);
u->module = m;
u->io = NULL;
u->sink_name = pa_xstrdup(pa_modargs_get_value(ma, "sink", NULL));
u->fd = -1;
u->fd_type = 0;
+ u->volume_limit = PA_CLAMP_VOLUME(volume_limit);
+ u->volume_step = PA_CLAMP_VOLUME(volume_step);
- if ((u->fd = open(pa_modargs_get_value(ma, "device", DEFAULT_DEVICE), O_RDONLY|O_NOCTTY)) < 0) {
+ if ((u->fd = pa_open_cloexec(pa_modargs_get_value(ma, "device", DEFAULT_DEVICE), O_RDONLY, 0)) < 0) {
pa_log("Failed to open evdev device: %s", pa_cstrerror(errno));
goto fail;
}
diff --git a/src/modules/module-null-sink.c b/src/modules/module-null-sink.c
index 30a99ca7..bedd6efc 100644
--- a/src/modules/module-null-sink.c
+++ b/src/modules/module-null-sink.c
@@ -24,33 +24,29 @@
#endif
#include <stdlib.h>
-#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
-#include <string.h>
-#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
#include <pulsecore/macro.h>
#include <pulsecore/sink.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
#include <pulsecore/thread.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
-#include <pulsecore/rtclock.h>
#include "module-null-sink-symdef.h"
PA_MODULE_AUTHOR("Lennart Poettering");
-PA_MODULE_DESCRIPTION("Clocked NULL sink");
+PA_MODULE_DESCRIPTION(_("Clocked NULL sink"));
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(FALSE);
PA_MODULE_USAGE(
@@ -84,7 +80,6 @@ static const char* const valid_modargs[] = {
"rate",
"channels",
"channel_map",
- "description", /* supported for compatibility reasons, made redundant by sink_properties= */
NULL
};
@@ -101,14 +96,14 @@ static int sink_process_msg(
case PA_SINK_MESSAGE_SET_STATE:
if (PA_PTR_TO_UINT(data) == PA_SINK_RUNNING)
- u->timestamp = pa_rtclock_usec();
+ u->timestamp = pa_rtclock_now();
break;
case PA_SINK_MESSAGE_GET_LATENCY: {
pa_usec_t now;
- now = pa_rtclock_usec();
+ now = pa_rtclock_now();
*((pa_usec_t*) data) = u->timestamp > now ? u->timestamp - now : 0ULL;
return 0;
@@ -208,9 +203,8 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
- u->timestamp = pa_rtclock_usec();
+ u->timestamp = pa_rtclock_now();
for (;;) {
int ret;
@@ -219,7 +213,7 @@ static void thread_func(void *userdata) {
if (PA_SINK_IS_OPENED(u->sink->thread_info.state)) {
pa_usec_t now;
- now = pa_rtclock_usec();
+ now = pa_rtclock_now();
if (u->sink->thread_info.rewind_requested) {
if (u->sink->thread_info.rewind_nbytes > 0)
@@ -287,7 +281,7 @@ int pa__init(pa_module*m) {
pa_sink_new_data_set_name(&data, pa_modargs_get_value(ma, "sink_name", DEFAULT_SINK_NAME));
pa_sink_new_data_set_sample_spec(&data, &ss);
pa_sink_new_data_set_channel_map(&data, &map);
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_DESCRIPTION, pa_modargs_get_value(ma, "description", "Null Output"));
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_DESCRIPTION, _("Null Output"));
pa_proplist_sets(data.proplist, PA_PROP_DEVICE_CLASS, "abstract");
if (pa_modargs_get_proplist(ma, "sink_properties", data.proplist, PA_UPDATE_REPLACE) < 0) {
@@ -316,7 +310,7 @@ int pa__init(pa_module*m) {
pa_sink_set_max_rewind(u->sink, nbytes);
pa_sink_set_max_request(u->sink, nbytes);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("null-sink", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
diff --git a/src/modules/module-null-source.c b/src/modules/module-null-source.c
new file mode 100644
index 00000000..b2981c34
--- /dev/null
+++ b/src/modules/module-null-source.c
@@ -0,0 +1,288 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2008 Lennart Poettering
+ Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies).
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <errno.h>
+#include <unistd.h>
+
+#include <pulse/rtclock.h>
+#include <pulse/timeval.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/log.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/module.h>
+#include <pulsecore/rtpoll.h>
+#include <pulsecore/source.h>
+#include <pulsecore/thread-mq.h>
+#include <pulsecore/thread.h>
+
+#include "module-null-source-symdef.h"
+
+PA_MODULE_AUTHOR("Lennart Poettering & Marc-Andre Lureau");
+PA_MODULE_DESCRIPTION("Clocked NULL source");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE(
+ "format=<sample format> "
+ "channels=<number of channels> "
+ "rate=<sample rate> "
+ "source_name=<name of source> "
+ "channel_map=<channel map> "
+ "description=<description for the source> "
+ "latency_time=<latency time in ms>");
+
+#define DEFAULT_SOURCE_NAME "source.null"
+#define DEFAULT_LATENCY_TIME 20
+#define MAX_LATENCY_USEC (PA_USEC_PER_SEC * 2)
+
+struct userdata {
+ pa_core *core;
+ pa_module *module;
+ pa_source *source;
+
+ pa_thread *thread;
+ pa_thread_mq thread_mq;
+ pa_rtpoll *rtpoll;
+
+ size_t block_size;
+
+ pa_usec_t block_usec;
+ pa_usec_t timestamp;
+ pa_usec_t latency_time;
+};
+
+static const char* const valid_modargs[] = {
+ "rate",
+ "format",
+ "channels",
+ "source_name",
+ "channel_map",
+ "description",
+ "latency_time",
+ NULL
+};
+
+static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SOURCE(o)->userdata;
+
+ switch (code) {
+ case PA_SOURCE_MESSAGE_SET_STATE:
+
+ if (PA_PTR_TO_UINT(data) == PA_SOURCE_RUNNING)
+ u->timestamp = pa_rtclock_now();
+
+ break;
+
+ case PA_SOURCE_MESSAGE_GET_LATENCY: {
+ pa_usec_t now;
+
+ now = pa_rtclock_now();
+ *((pa_usec_t*) data) = u->timestamp > now ? u->timestamp - now : 0;
+
+ return 0;
+ }
+ }
+
+ return pa_source_process_msg(o, code, data, offset, chunk);
+}
+
+static void source_update_requested_latency_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ u = s->userdata;
+ pa_assert(u);
+
+ u->block_usec = pa_source_get_requested_latency_within_thread(s);
+}
+
+static void thread_func(void *userdata) {
+ struct userdata *u = userdata;
+
+ pa_assert(u);
+
+ pa_log_debug("Thread starting up");
+
+ pa_thread_mq_install(&u->thread_mq);
+
+ u->timestamp = pa_rtclock_now();
+
+ for (;;) {
+ int ret;
+
+ /* Generate some null data */
+ if (PA_SOURCE_IS_OPENED(u->source->thread_info.state)) {
+ pa_usec_t now;
+ pa_memchunk chunk;
+
+ now = pa_rtclock_now();
+
+ if ((chunk.length = pa_usec_to_bytes(now - u->timestamp, &u->source->sample_spec)) > 0) {
+
+ chunk.memblock = pa_memblock_new(u->core->mempool, (size_t) -1); /* or chunk.length? */
+ chunk.index = 0;
+ pa_source_post(u->source, &chunk);
+ pa_memblock_unref(chunk.memblock);
+
+ u->timestamp = now;
+ }
+
+ pa_rtpoll_set_timer_absolute(u->rtpoll, u->timestamp + u->latency_time * PA_USEC_PER_MSEC);
+ } else
+ pa_rtpoll_set_timer_disabled(u->rtpoll);
+
+ /* Hmm, nothing to do. Let's sleep */
+ if ((ret = pa_rtpoll_run(u->rtpoll, TRUE)) < 0)
+ goto fail;
+
+ if (ret == 0)
+ goto finish;
+ }
+
+fail:
+ /* If this was no regular exit from the loop we have to continue
+ * processing messages until we received PA_MESSAGE_SHUTDOWN */
+ pa_asyncmsgq_post(u->thread_mq.outq, PA_MSGOBJECT(u->core), PA_CORE_MESSAGE_UNLOAD_MODULE, u->module, 0, NULL, NULL);
+ pa_asyncmsgq_wait_for(u->thread_mq.inq, PA_MESSAGE_SHUTDOWN);
+
+finish:
+ pa_log_debug("Thread shutting down");
+}
+
+int pa__init(pa_module*m) {
+ struct userdata *u = NULL;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ pa_modargs *ma = NULL;
+ pa_source_new_data data;
+ uint32_t latency_time = DEFAULT_LATENCY_TIME;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ ss = m->core->default_sample_spec;
+ if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_DEFAULT) < 0) {
+ pa_log("Invalid sample format specification or channel map");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->module = m;
+ u->rtpoll = pa_rtpoll_new();
+ pa_thread_mq_init(&u->thread_mq, m->core->mainloop, u->rtpoll);
+
+ pa_source_new_data_init(&data);
+ data.driver = __FILE__;
+ data.module = m;
+ pa_source_new_data_set_name(&data, pa_modargs_get_value(ma, "source_name", DEFAULT_SOURCE_NAME));
+ pa_source_new_data_set_sample_spec(&data, &ss);
+ pa_source_new_data_set_channel_map(&data, &map);
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_DESCRIPTION, pa_modargs_get_value(ma, "description", "Null Input"));
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_CLASS, "abstract");
+
+ u->source = pa_source_new(m->core, &data, PA_SOURCE_LATENCY | PA_SOURCE_DYNAMIC_LATENCY);
+ pa_source_new_data_done(&data);
+
+ if (!u->source) {
+ pa_log("Failed to create source object.");
+ goto fail;
+ }
+
+ u->latency_time = DEFAULT_LATENCY_TIME;
+ if (pa_modargs_get_value_u32(ma, "latency_time", &latency_time) < 0) {
+ pa_log("Failed to parse latency_time value.");
+ goto fail;
+ }
+ u->latency_time = latency_time;
+
+ u->source->parent.process_msg = source_process_msg;
+ u->source->update_requested_latency = source_update_requested_latency_cb;
+ u->source->userdata = u;
+
+ pa_source_set_asyncmsgq(u->source, u->thread_mq.inq);
+ pa_source_set_rtpoll(u->source, u->rtpoll);
+
+ pa_source_set_latency_range(u->source, 0, MAX_LATENCY_USEC);
+ u->block_usec = u->source->thread_info.max_latency;
+
+ u->source->thread_info.max_rewind =
+ pa_usec_to_bytes(u->block_usec, &u->source->sample_spec);
+
+ if (!(u->thread = pa_thread_new("null-source", thread_func, u))) {
+ pa_log("Failed to create thread.");
+ goto fail;
+ }
+
+ pa_source_put(u->source);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->source)
+ pa_source_unlink(u->source);
+
+ if (u->thread) {
+ pa_asyncmsgq_send(u->thread_mq.inq, NULL, PA_MESSAGE_SHUTDOWN, NULL, 0, NULL);
+ pa_thread_free(u->thread);
+ }
+
+ pa_thread_mq_done(&u->thread_mq);
+
+ if (u->source)
+ pa_source_unref(u->source);
+
+ if (u->rtpoll)
+ pa_rtpoll_free(u->rtpoll);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-pipe-sink.c b/src/modules/module-pipe-sink.c
index 5b0f6414..91e01f99 100644
--- a/src/modules/module-pipe-sink.c
+++ b/src/modules/module-pipe-sink.c
@@ -27,12 +27,13 @@
#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
-#include <string.h>
#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
#include <sys/ioctl.h>
-#include <poll.h>
+
+#ifdef HAVE_SYS_FILIO_H
+#include <sys/filio.h>
+#endif
#include <pulse/xmalloc.h>
@@ -45,6 +46,7 @@
#include <pulsecore/thread.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
+#include <pulsecore/poll.h>
#include "module-pipe-sink-symdef.h"
@@ -57,7 +59,7 @@ PA_MODULE_USAGE(
"sink_properties=<properties for the sink> "
"file=<path of the FIFO> "
"format=<sample format> "
- "rate=<sample rate>"
+ "rate=<sample rate> "
"channels=<number of channels> "
"channel_map=<channel map>");
@@ -101,9 +103,10 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
case PA_SINK_MESSAGE_GET_LATENCY: {
size_t n = 0;
- int l;
#ifdef FIONREAD
+ int l;
+
if (ioctl(u->fd, FIONREAD, &l) >= 0 && l > 0)
n = (size_t) l;
#endif
@@ -122,7 +125,7 @@ static int process_render(struct userdata *u) {
pa_assert(u);
if (u->memchunk.length <= 0)
- pa_sink_render(u->sink, PIPE_BUF, &u->memchunk);
+ pa_sink_render(u->sink, pa_pipe_buf(u->fd), &u->memchunk);
pa_assert(u->memchunk.length > 0);
@@ -170,7 +173,6 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
struct pollfd *pollfd;
@@ -254,12 +256,11 @@ int pa__init(pa_module*m) {
u->filename = pa_runtime_path(pa_modargs_get_value(ma, "file", DEFAULT_FILE_NAME));
mkfifo(u->filename, 0666);
- if ((u->fd = open(u->filename, O_RDWR|O_NOCTTY)) < 0) {
+ if ((u->fd = pa_open_cloexec(u->filename, O_RDWR, 0)) < 0) {
pa_log("open('%s'): %s", u->filename, pa_cstrerror(errno));
goto fail;
}
- pa_make_fd_cloexec(u->fd);
pa_make_fd_nonblock(u->fd);
if (fstat(u->fd, &st) < 0) {
@@ -300,15 +301,15 @@ int pa__init(pa_module*m) {
pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
pa_sink_set_rtpoll(u->sink, u->rtpoll);
- pa_sink_set_max_request(u->sink, PIPE_BUF);
- pa_sink_set_fixed_latency(u->sink, pa_bytes_to_usec(PIPE_BUF, &u->sink->sample_spec));
+ pa_sink_set_max_request(u->sink, pa_pipe_buf(u->fd));
+ pa_sink_set_fixed_latency(u->sink, pa_bytes_to_usec(pa_pipe_buf(u->fd), &u->sink->sample_spec));
u->rtpoll_item = pa_rtpoll_item_new(u->rtpoll, PA_RTPOLL_NEVER, 1);
pollfd = pa_rtpoll_item_get_pollfd(u->rtpoll_item, NULL);
pollfd->fd = u->fd;
pollfd->events = pollfd->revents = 0;
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("pipe-sink", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
@@ -359,7 +360,7 @@ void pa__done(pa_module*m) {
pa_sink_unref(u->sink);
if (u->memchunk.memblock)
- pa_memblock_unref(u->memchunk.memblock);
+ pa_memblock_unref(u->memchunk.memblock);
if (u->rtpoll_item)
pa_rtpoll_item_free(u->rtpoll_item);
diff --git a/src/modules/module-pipe-source.c b/src/modules/module-pipe-source.c
index 61c9fc0e..a941f088 100644
--- a/src/modules/module-pipe-source.c
+++ b/src/modules/module-pipe-source.c
@@ -27,12 +27,13 @@
#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
-#include <string.h>
#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
#include <sys/ioctl.h>
-#include <sys/poll.h>
+
+#ifdef HAVE_SYS_FILIO_H
+#include <sys/filio.h>
+#endif
#include <pulse/xmalloc.h>
@@ -45,6 +46,7 @@
#include <pulsecore/thread.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
+#include <pulsecore/poll.h>
#include "module-pipe-source-symdef.h"
@@ -105,9 +107,10 @@ static int source_process_msg(
case PA_SOURCE_MESSAGE_GET_LATENCY: {
size_t n = 0;
- int l;
#ifdef FIONREAD
+ int l;
+
if (ioctl(u->fd, FIONREAD, &l) >= 0 && l > 0)
n = (size_t) l;
#endif
@@ -129,7 +132,6 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
int ret;
@@ -143,7 +145,7 @@ static void thread_func(void *userdata) {
void *p;
if (!u->memchunk.memblock) {
- u->memchunk.memblock = pa_memblock_new(u->core->mempool, PIPE_BUF);
+ u->memchunk.memblock = pa_memblock_new(u->core->mempool, pa_pipe_buf(u->fd));
u->memchunk.index = u->memchunk.length = 0;
}
@@ -160,7 +162,7 @@ static void thread_func(void *userdata) {
if (errno == EINTR)
continue;
else if (errno != EAGAIN) {
- pa_log("Faile to read data from FIFO: %s", pa_cstrerror(errno));
+ pa_log("Failed to read data from FIFO: %s", pa_cstrerror(errno));
goto fail;
}
@@ -239,12 +241,11 @@ int pa__init(pa_module*m) {
u->filename = pa_runtime_path(pa_modargs_get_value(ma, "file", DEFAULT_FILE_NAME));
mkfifo(u->filename, 0666);
- if ((u->fd = open(u->filename, O_RDWR|O_NOCTTY)) < 0) {
+ if ((u->fd = pa_open_cloexec(u->filename, O_RDWR, 0)) < 0) {
pa_log("open('%s'): %s", u->filename, pa_cstrerror(errno));
goto fail;
}
- pa_make_fd_cloexec(u->fd);
pa_make_fd_nonblock(u->fd);
if (fstat(u->fd, &st) < 0) {
@@ -292,7 +293,7 @@ int pa__init(pa_module*m) {
pollfd->fd = u->fd;
pollfd->events = pollfd->revents = 0;
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("pipe-source", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
diff --git a/src/modules/module-position-event-sounds.c b/src/modules/module-position-event-sounds.c
index e191ec33..091453a4 100644
--- a/src/modules/module-position-event-sounds.c
+++ b/src/modules/module-position-event-sounds.c
@@ -24,18 +24,15 @@
#endif
#include <unistd.h>
-#include <string.h>
#include <errno.h>
#include <sys/types.h>
#include <stdio.h>
#include <stdlib.h>
-#include <ctype.h>
#include <pulse/xmalloc.h>
#include <pulse/volume.h>
#include <pulse/channelmap.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
@@ -57,35 +54,85 @@ struct userdata {
pa_hook_slot *sink_input_fixate_hook_slot;
};
+static int parse_pos(const char *pos, double *f) {
+
+ if (pa_atod(pos, f) < 0) {
+ pa_log_warn("Failed to parse hpos/vpos property '%s'.", pos);
+ return -1;
+ }
+
+ if (*f < 0.0 || *f > 1.0) {
+ pa_log_debug("Property hpos/vpos out of range %0.2f", *f);
+
+ *f = PA_CLAMP(*f, 0.0, 1.0);
+ }
+
+ return 0;
+}
+
static pa_hook_result_t sink_input_fixate_hook_callback(pa_core *core, pa_sink_input_new_data *data, struct userdata *u) {
- const char *hpos;
+ const char *hpos, *vpos, *role, *id;
double f;
char t[PA_CVOLUME_SNPRINT_MAX];
pa_cvolume v;
pa_assert(data);
- if (!(hpos = pa_proplist_gets(data->proplist, PA_PROP_EVENT_MOUSE_HPOS)))
+ if (!(role = pa_proplist_gets(data->proplist, PA_PROP_MEDIA_ROLE)))
return PA_HOOK_OK;
- if (pa_atod(hpos, &f) < 0) {
- pa_log_warn("Failed to parse "PA_PROP_EVENT_MOUSE_HPOS" property '%s'.", hpos);
+ if (!pa_streq(role, "event"))
return PA_HOOK_OK;
+
+ if ((id = pa_proplist_gets(data->proplist, PA_PROP_EVENT_ID))) {
+
+ /* The test sounds should never be positioned in space, since
+ * they might be trigered themselves to configure the speakers
+ * in space, which we don't want to mess up. */
+
+ if (pa_startswith(id, "audio-channel-"))
+ return PA_HOOK_OK;
+
+ if (pa_streq(id, "audio-volume-change"))
+ return PA_HOOK_OK;
+
+ if (pa_streq(id, "audio-test-signal"))
+ return PA_HOOK_OK;
}
- if (f < 0.0 || f > 1.0) {
- pa_log_warn("Property "PA_PROP_EVENT_MOUSE_HPOS" out of range %0.2f", f);
+ if (!(hpos = pa_proplist_gets(data->proplist, PA_PROP_EVENT_MOUSE_HPOS)))
+ hpos = pa_proplist_gets(data->proplist, PA_PROP_WINDOW_HPOS);
+
+ if (!(vpos = pa_proplist_gets(data->proplist, PA_PROP_EVENT_MOUSE_VPOS)))
+ vpos = pa_proplist_gets(data->proplist, PA_PROP_WINDOW_VPOS);
+
+ if (!hpos && !vpos)
return PA_HOOK_OK;
+
+ pa_cvolume_reset(&v, data->sink->sample_spec.channels);
+
+ if (hpos) {
+ if (parse_pos(hpos, &f) < 0)
+ return PA_HOOK_OK;
+
+ if (pa_channel_map_can_balance(&data->sink->channel_map)) {
+ pa_log_debug("Positioning event sound '%s' horizontally at %0.2f.", pa_strnull(pa_proplist_gets(data->proplist, PA_PROP_EVENT_ID)), f);
+ pa_cvolume_set_balance(&v, &data->sink->channel_map, f*2.0-1.0);
+ }
}
- pa_log_debug("Positioning event sound '%s' at %0.2f.", pa_strnull(pa_proplist_gets(data->proplist, PA_PROP_EVENT_ID)), f);
+ if (vpos) {
+ if (parse_pos(vpos, &f) < 0)
+ return PA_HOOK_OK;
- pa_cvolume_reset(&v, data->sample_spec.channels);
- pa_cvolume_set_balance(&v, &data->channel_map, f*2.0-1.0);
+ if (pa_channel_map_can_fade(&data->sink->channel_map)) {
+ pa_log_debug("Positioning event sound '%s' vertically at %0.2f.", pa_strnull(pa_proplist_gets(data->proplist, PA_PROP_EVENT_ID)), f);
+ pa_cvolume_set_fade(&v, &data->sink->channel_map, f*2.0-1.0);
+ }
+ }
pa_log_debug("Final volume factor %s.", pa_cvolume_snprint(t, sizeof(t), &v));
-
- pa_sink_input_new_data_apply_volume_factor(data, &v);
+ pa_sink_input_new_data_apply_volume_factor_sink(data, &v);
return PA_HOOK_OK;
}
@@ -114,7 +161,7 @@ fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
}
void pa__done(pa_module*m) {
diff --git a/src/modules/module-protocol-stub.c b/src/modules/module-protocol-stub.c
index 5b351d19..e1bf3977 100644
--- a/src/modules/module-protocol-stub.c
+++ b/src/modules/module-protocol-stub.c
@@ -24,27 +24,19 @@
#include <config.h>
#endif
-#include <string.h>
#include <errno.h>
#include <stdio.h>
#include <unistd.h>
-#include <limits.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
#include <pulse/xmalloc.h>
-#include <pulsecore/winsock.h>
#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
+#include <pulsecore/socket.h>
#include <pulsecore/socket-server.h>
#include <pulsecore/socket-util.h>
#include <pulsecore/core-util.h>
@@ -52,6 +44,7 @@
#include <pulsecore/log.h>
#include <pulsecore/native-common.h>
#include <pulsecore/creds.h>
+#include <pulsecore/arpa-inet.h>
#ifdef USE_TCP_SOCKETS
#define SOCKET_DESCRIPTION "(TCP sockets)"
@@ -140,7 +133,7 @@
PA_MODULE_DESCRIPTION("Native protocol "SOCKET_DESCRIPTION);
PA_MODULE_USAGE("auth-anonymous=<don't check for cookies?> "
"auth-cookie=<path to cookie file> "
- "auth-cookie-enabled=<enable cookie authentification? "
+ "auth-cookie-enabled=<enable cookie authentification?> "
AUTH_USAGE
SOCKET_USAGE);
#elif defined(USE_PROTOCOL_ESOUND)
@@ -169,7 +162,7 @@
"source=<source to connect to> "
"auth-anonymous=<don't verify cookies?> "
"auth-cookie=<path to cookie file> "
- "auth-cookie-enabled=<enable cookie authentification? "
+ "auth-cookie-enabled=<enable cookie authentification?> "
AUTH_USAGE
SOCKET_USAGE);
#else
@@ -246,6 +239,7 @@ int pa__init(pa_module*m) {
#if defined(USE_TCP_SOCKETS)
uint32_t port = IPV4_PORT;
+ pa_bool_t port_fallback = TRUE;
const char *listen_on;
#else
int r;
@@ -293,6 +287,10 @@ int pa__init(pa_module*m) {
#endif
#if defined(USE_TCP_SOCKETS)
+
+ if (pa_in_system_mode() || pa_modargs_get_value(ma, "port", NULL))
+ port_fallback = FALSE;
+
if (pa_modargs_get_value_u32(ma, "port", &port) < 0 || port < 1 || port > 0xFFFF) {
pa_log("port= expects a numerical argument between 1 and 65535.");
goto fail;
@@ -302,14 +300,14 @@ int pa__init(pa_module*m) {
if (listen_on) {
# ifdef HAVE_IPV6
- u->socket_server_ipv6 = pa_socket_server_new_ipv6_string(m->core->mainloop, listen_on, (uint16_t) port, TCPWRAP_SERVICE);
+ u->socket_server_ipv6 = pa_socket_server_new_ipv6_string(m->core->mainloop, listen_on, (uint16_t) port, port_fallback, TCPWRAP_SERVICE);
# endif
- u->socket_server_ipv4 = pa_socket_server_new_ipv4_string(m->core->mainloop, listen_on, (uint16_t) port, TCPWRAP_SERVICE);
+ u->socket_server_ipv4 = pa_socket_server_new_ipv4_string(m->core->mainloop, listen_on, (uint16_t) port, port_fallback, TCPWRAP_SERVICE);
} else {
# ifdef HAVE_IPV6
- u->socket_server_ipv6 = pa_socket_server_new_ipv6_any(m->core->mainloop, (uint16_t) port, TCPWRAP_SERVICE);
+ u->socket_server_ipv6 = pa_socket_server_new_ipv6_any(m->core->mainloop, (uint16_t) port, port_fallback, TCPWRAP_SERVICE);
# endif
- u->socket_server_ipv4 = pa_socket_server_new_ipv4_any(m->core->mainloop, (uint16_t) port, TCPWRAP_SERVICE);
+ u->socket_server_ipv4 = pa_socket_server_new_ipv4_any(m->core->mainloop, (uint16_t) port, port_fallback, TCPWRAP_SERVICE);
}
# ifdef HAVE_IPV6
diff --git a/src/modules/module-remap-sink.c b/src/modules/module-remap-sink.c
index 119f5b9f..2822a7fc 100644
--- a/src/modules/module-remap-sink.c
+++ b/src/modules/module-remap-sink.c
@@ -1,7 +1,7 @@
/***
This file is part of PulseAudio.
- Copyright 2004-2008 Lennart Poettering
+ Copyright 2004-2009 Lennart Poettering
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
@@ -25,15 +25,12 @@
#include <pulse/xmalloc.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/namereg.h>
#include <pulsecore/sink.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
-#include <pulsecore/thread.h>
-#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
#include "module-remap-sink-symdef.h"
@@ -48,17 +45,18 @@ PA_MODULE_USAGE(
"master=<name of sink to remap> "
"master_channel_map=<channel map> "
"format=<sample format> "
- "channels=<number of channels> "
"rate=<sample rate> "
+ "channels=<number of channels> "
"channel_map=<channel map> "
"remix=<remix channels?>");
struct userdata {
- pa_core *core;
pa_module *module;
- pa_sink *sink, *master;
+ pa_sink *sink;
pa_sink_input *sink_input;
+
+ pa_bool_t auto_desc;
};
static const char* const valid_modargs[] = {
@@ -80,19 +78,24 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
switch (code) {
- case PA_SINK_MESSAGE_GET_LATENCY: {
- pa_usec_t usec = 0;
+ case PA_SINK_MESSAGE_GET_LATENCY:
- /* Get the latency of the master sink */
- if (PA_MSGOBJECT(u->master)->process_msg(PA_MSGOBJECT(u->master), PA_SINK_MESSAGE_GET_LATENCY, &usec, 0, NULL) < 0)
- usec = 0;
+ /* The sink is _put() before the sink input is, so let's
+ * make sure we don't access it yet */
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state)) {
+ *((pa_usec_t*) data) = 0;
+ return 0;
+ }
- /* Add the latency internal to our sink input on top */
- usec += pa_bytes_to_usec(pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq), &u->master->sample_spec);
+ *((pa_usec_t*) data) =
+ /* Get the latency of the master sink */
+ pa_sink_get_latency_within_thread(u->sink_input->sink) +
+
+ /* Add the latency internal to our sink input on top */
+ pa_bytes_to_usec(pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq), &u->sink_input->sink->sample_spec);
- *((pa_usec_t*) data) = usec;
return 0;
- }
}
return pa_sink_process_msg(o, code, data, offset, chunk);
@@ -105,12 +108,11 @@ static int sink_set_state(pa_sink *s, pa_sink_state_t state) {
pa_sink_assert_ref(s);
pa_assert_se(u = s->userdata);
- if (PA_SINK_IS_LINKED(state) &&
- u->sink_input &&
- PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
-
- pa_sink_input_cork(u->sink_input, state == PA_SINK_SUSPENDED);
+ if (!PA_SINK_IS_LINKED(state) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return 0;
+ pa_sink_input_cork(u->sink_input, state == PA_SINK_SUSPENDED);
return 0;
}
@@ -121,6 +123,10 @@ static void sink_request_rewind(pa_sink *s) {
pa_sink_assert_ref(s);
pa_assert_se(u = s->userdata);
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
pa_sink_input_request_rewind(u->sink_input, s->thread_info.rewind_nbytes, TRUE, FALSE, FALSE);
}
@@ -131,6 +137,10 @@ static void sink_update_requested_latency(pa_sink *s) {
pa_sink_assert_ref(s);
pa_assert_se(u = s->userdata);
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
/* Just hand this one over to the master sink */
pa_sink_input_set_requested_latency_within_thread(
u->sink_input,
@@ -145,8 +155,8 @@ static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk
pa_assert(chunk);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_OPENED(u->sink->thread_info.state))
- return -1;
+ /* Hmm, process any rewind request that might be queued up */
+ pa_sink_process_rewind(u->sink, 0);
pa_sink_render(u->sink, nbytes, chunk);
return 0;
@@ -160,9 +170,6 @@ static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_OPENED(u->sink->thread_info.state))
- return;
-
if (u->sink->thread_info.rewind_nbytes > 0) {
amount = PA_MIN(u->sink->thread_info.rewind_nbytes, nbytes);
u->sink->thread_info.rewind_nbytes = 0;
@@ -178,9 +185,6 @@ static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
-
pa_sink_set_max_rewind_within_thread(u->sink, nbytes);
}
@@ -191,9 +195,6 @@ static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
-
pa_sink_set_max_request_within_thread(u->sink, nbytes);
}
@@ -204,24 +205,28 @@ static void sink_input_update_sink_latency_range_cb(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
-
pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
}
/* Called from I/O thread context */
-static void sink_input_detach_cb(pa_sink_input *i) {
+static void sink_input_update_sink_fixed_latency_cb(pa_sink_input *i) {
struct userdata *u;
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_detach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
pa_sink_detach_within_thread(u->sink);
- pa_sink_set_asyncmsgq(u->sink, NULL);
+
pa_sink_set_rtpoll(u->sink, NULL);
}
@@ -232,14 +237,13 @@ static void sink_input_attach_cb(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- if (!u->sink || !PA_SINK_IS_LINKED(u->sink->thread_info.state))
- return;
+ pa_sink_set_rtpoll(u->sink, i->sink->thread_info.rtpoll);
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+ pa_sink_set_max_request_within_thread(u->sink, pa_sink_input_get_max_request(i));
+ pa_sink_set_max_rewind_within_thread(u->sink, pa_sink_input_get_max_rewind(i));
- pa_sink_set_asyncmsgq(u->sink, i->sink->asyncmsgq);
- pa_sink_set_rtpoll(u->sink, i->sink->rtpoll);
pa_sink_attach_within_thread(u->sink);
-
- pa_sink_set_latency_range_within_thread(u->sink, u->master->thread_info.min_latency, u->master->thread_info.max_latency);
}
/* Called from main context */
@@ -249,14 +253,18 @@ static void sink_input_kill_cb(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
pa_assert_se(u = i->userdata);
- pa_sink_unlink(u->sink);
+ /* The order here matters! We first kill the sink input, followed
+ * by the sink. That means the sink callbacks must be protected
+ * against an unconnected sink input! */
pa_sink_input_unlink(u->sink_input);
+ pa_sink_unlink(u->sink);
- pa_sink_unref(u->sink);
- u->sink = NULL;
pa_sink_input_unref(u->sink_input);
u->sink_input = NULL;
+ pa_sink_unref(u->sink);
+ u->sink = NULL;
+
pa_module_unload_request(u->module, TRUE);
}
@@ -286,12 +294,37 @@ static pa_bool_t sink_input_may_move_to_cb(pa_sink_input *i, pa_sink *dest) {
return u->sink != dest;
}
+/* Called from main context */
+static void sink_input_moving_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ if (dest) {
+ pa_sink_set_asyncmsgq(u->sink, dest->asyncmsgq);
+ pa_sink_update_flags(u->sink, PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY, dest->flags);
+ } else
+ pa_sink_set_asyncmsgq(u->sink, NULL);
+
+ if (u->auto_desc && dest) {
+ const char *k;
+ pa_proplist *pl;
+
+ pl = pa_proplist_new();
+ k = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(pl, PA_PROP_DEVICE_DESCRIPTION, "Remapped %s", k ? k : dest->name);
+
+ pa_sink_update_proplist(u->sink, PA_UPDATE_REPLACE, pl);
+ pa_proplist_free(pl);
+ }
+}
+
int pa__init(pa_module*m) {
struct userdata *u;
pa_sample_spec ss;
pa_channel_map sink_map, stream_map;
pa_modargs *ma;
- const char *k;
pa_sink *master;
pa_sink_input_new_data sink_input_data;
pa_sink_new_data sink_data;
@@ -336,12 +369,8 @@ int pa__init(pa_module*m) {
}
u = pa_xnew0(struct userdata, 1);
- u->core = m->core;
u->module = m;
m->userdata = u;
- u->master = master;
- u->sink = NULL;
- u->sink_input = NULL;
/* Create sink */
pa_sink_new_data_init(&sink_data);
@@ -351,8 +380,6 @@ int pa__init(pa_module*m) {
sink_data.name = pa_sprintf_malloc("%s.remapped", master->name);
pa_sink_new_data_set_sample_spec(&sink_data, &ss);
pa_sink_new_data_set_channel_map(&sink_data, &sink_map);
- k = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
- pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Remapped %s", k ? k : master->name);
pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, master->name);
pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_CLASS, "filter");
@@ -362,7 +389,14 @@ int pa__init(pa_module*m) {
goto fail;
}
- u->sink = pa_sink_new(m->core, &sink_data, PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY);
+ if ((u->auto_desc = !pa_proplist_contains(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ const char *k;
+
+ k = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Remapped %s", k ? k : master->name);
+ }
+
+ u->sink = pa_sink_new(m->core, &sink_data, master->flags & (PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY));
pa_sink_new_data_done(&sink_data);
if (!u->sink) {
@@ -377,19 +411,20 @@ int pa__init(pa_module*m) {
u->sink->userdata = u;
pa_sink_set_asyncmsgq(u->sink, master->asyncmsgq);
- pa_sink_set_rtpoll(u->sink, master->rtpoll);
/* Create sink input */
pa_sink_input_new_data_init(&sink_input_data);
sink_input_data.driver = __FILE__;
sink_input_data.module = m;
- sink_input_data.sink = u->master;
+ pa_sink_input_new_data_set_sink(&sink_input_data, master, FALSE);
+ sink_input_data.origin_sink = u->sink;
pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_NAME, "Remapped Stream");
pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ROLE, "filter");
pa_sink_input_new_data_set_sample_spec(&sink_input_data, &ss);
pa_sink_input_new_data_set_channel_map(&sink_input_data, &stream_map);
+ sink_input_data.flags = (remix ? 0 : PA_SINK_INPUT_NO_REMIX);
- pa_sink_input_new(&u->sink_input, m->core, &sink_input_data, PA_SINK_INPUT_DONT_MOVE | (remix ? 0 : PA_SINK_INPUT_NO_REMIX));
+ pa_sink_input_new(&u->sink_input, m->core, &sink_input_data);
pa_sink_input_new_data_done(&sink_input_data);
if (!u->sink_input)
@@ -400,13 +435,17 @@ int pa__init(pa_module*m) {
u->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
u->sink_input->update_max_request = sink_input_update_max_request_cb;
u->sink_input->update_sink_latency_range = sink_input_update_sink_latency_range_cb;
+ u->sink_input->update_sink_fixed_latency = sink_input_update_sink_fixed_latency_cb;
u->sink_input->attach = sink_input_attach_cb;
u->sink_input->detach = sink_input_detach_cb;
u->sink_input->kill = sink_input_kill_cb;
u->sink_input->state_change = sink_input_state_change_cb;
u->sink_input->may_move_to = sink_input_may_move_to_cb;
+ u->sink_input->moving = sink_input_moving_cb;
u->sink_input->userdata = u;
+ u->sink->input_to_master = u->sink_input;
+
pa_sink_put(u->sink);
pa_sink_input_put(u->sink_input);
@@ -440,15 +479,20 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
- if (u->sink) {
- pa_sink_unlink(u->sink);
- pa_sink_unref(u->sink);
- }
+ /* See comments in sink_input_kill_cb() above regarding
+ * destruction order! */
- if (u->sink_input) {
+ if (u->sink_input)
pa_sink_input_unlink(u->sink_input);
+
+ if (u->sink)
+ pa_sink_unlink(u->sink);
+
+ if (u->sink_input)
pa_sink_input_unref(u->sink_input);
- }
+
+ if (u->sink)
+ pa_sink_unref(u->sink);
pa_xfree(u);
}
diff --git a/src/modules/module-rescue-streams.c b/src/modules/module-rescue-streams.c
index c22711ae..8b35809a 100644
--- a/src/modules/module-rescue-streams.c
+++ b/src/modules/module-rescue-streams.c
@@ -45,13 +45,46 @@ static const char* const valid_modargs[] = {
};
struct userdata {
- pa_hook_slot *sink_slot, *source_slot;
+ pa_hook_slot
+ *sink_unlink_slot,
+ *source_unlink_slot,
+ *sink_input_move_fail_slot,
+ *source_output_move_fail_slot;
};
-static pa_hook_result_t sink_hook_callback(pa_core *c, pa_sink *sink, void* userdata) {
+static pa_sink* find_evacuation_sink(pa_core *c, pa_sink_input *i, pa_sink *skip) {
+ pa_sink *target, *def;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(i);
+
+ def = pa_namereg_get_default_sink(c);
+
+ if (def && def != skip && pa_sink_input_may_move_to(i, def))
+ return def;
+
+ PA_IDXSET_FOREACH(target, c->sinks, idx) {
+ if (target == def)
+ continue;
+
+ if (target == skip)
+ continue;
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(target)))
+ continue;
+
+ if (pa_sink_input_may_move_to(i, target))
+ return target;
+ }
+
+ pa_log_debug("No evacuation sink found.");
+ return NULL;
+}
+
+static pa_hook_result_t sink_unlink_hook_callback(pa_core *c, pa_sink *sink, void* userdata) {
pa_sink_input *i;
uint32_t idx;
- pa_sink *target;
pa_assert(c);
pa_assert(sink);
@@ -65,35 +98,83 @@ static pa_hook_result_t sink_hook_callback(pa_core *c, pa_sink *sink, void* user
return PA_HOOK_OK;
}
- if (!(target = pa_namereg_get(c, NULL, PA_NAMEREG_SINK)) || target == sink) {
-
- PA_IDXSET_FOREACH(target, c->sinks, idx)
- if (target != sink)
- break;
-
- if (!target) {
- pa_log_info("No evacuation sink found.");
- return PA_HOOK_OK;
- }
- }
+ PA_IDXSET_FOREACH(i, sink->inputs, idx) {
+ pa_sink *target;
- pa_assert(target != sink);
+ if (!(target = find_evacuation_sink(c, i, sink)))
+ continue;
- PA_IDXSET_FOREACH(i, sink->inputs, idx) {
if (pa_sink_input_move_to(i, target, FALSE) < 0)
pa_log_info("Failed to move sink input %u \"%s\" to %s.", i->index,
pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name);
else
- pa_log_info("Sucessfully moved sink input %u \"%s\" to %s.", i->index,
+ pa_log_info("Successfully moved sink input %u \"%s\" to %s.", i->index,
pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name);
}
return PA_HOOK_OK;
}
-static pa_hook_result_t source_hook_callback(pa_core *c, pa_source *source, void* userdata) {
+static pa_hook_result_t sink_input_move_fail_hook_callback(pa_core *c, pa_sink_input *i, void *userdata) {
+ pa_sink *target;
+
+ pa_assert(c);
+ pa_assert(i);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ if (!(target = find_evacuation_sink(c, i, NULL)))
+ return PA_HOOK_OK;
+
+ if (pa_sink_input_finish_move(i, target, FALSE) < 0) {
+ pa_log_info("Failed to move sink input %u \"%s\" to %s.", i->index,
+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name);
+ return PA_HOOK_OK;
+
+ } else {
+ pa_log_info("Successfully moved sink input %u \"%s\" to %s.", i->index,
+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name);
+ return PA_HOOK_STOP;
+ }
+}
+
+static pa_source* find_evacuation_source(pa_core *c, pa_source_output *o, pa_source *skip) {
+ pa_source *target, *def;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(o);
+
+ def = pa_namereg_get_default_source(c);
+
+ if (def && def != skip && pa_source_output_may_move_to(o, def))
+ return def;
+
+ PA_IDXSET_FOREACH(target, c->sources, idx) {
+ if (target == def)
+ continue;
+
+ if (target == skip)
+ continue;
+
+ if (skip && !target->monitor_of != !skip->monitor_of)
+ continue;
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(target)))
+ continue;
+
+ if (pa_source_output_may_move_to(o, target))
+ return target;
+ }
+
+ pa_log_debug("No evacuation source found.");
+ return NULL;
+}
+
+static pa_hook_result_t source_unlink_hook_callback(pa_core *c, pa_source *source, void* userdata) {
pa_source_output *o;
- pa_source *target;
uint32_t idx;
pa_assert(c);
@@ -108,32 +189,48 @@ static pa_hook_result_t source_hook_callback(pa_core *c, pa_source *source, void
return PA_HOOK_OK;
}
- if (!(target = pa_namereg_get(c, NULL, PA_NAMEREG_SOURCE)) || target == source) {
-
- PA_IDXSET_FOREACH(target, c->sources, idx)
- if (target != source && !target->monitor_of == !source->monitor_of)
- break;
-
- if (!target) {
- pa_log_info("No evacuation source found.");
- return PA_HOOK_OK;
- }
- }
+ PA_IDXSET_FOREACH(o, source->outputs, idx) {
+ pa_source *target;
- pa_assert(target != source);
+ if (!(target = find_evacuation_source(c, o, source)))
+ continue;
- PA_IDXSET_FOREACH(o, source->outputs, idx) {
if (pa_source_output_move_to(o, target, FALSE) < 0)
pa_log_info("Failed to move source output %u \"%s\" to %s.", o->index,
pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME)), target->name);
else
- pa_log_info("Sucessfully moved source output %u \"%s\" to %s.", o->index,
+ pa_log_info("Successfully moved source output %u \"%s\" to %s.", o->index,
pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME)), target->name);
}
return PA_HOOK_OK;
}
+static pa_hook_result_t source_output_move_fail_hook_callback(pa_core *c, pa_source_output *i, void *userdata) {
+ pa_source *target;
+
+ pa_assert(c);
+ pa_assert(i);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ if (!(target = find_evacuation_source(c, i, NULL)))
+ return PA_HOOK_OK;
+
+ if (pa_source_output_finish_move(i, target, FALSE) < 0) {
+ pa_log_info("Failed to move source input %u \"%s\" to %s.", i->index,
+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name);
+ return PA_HOOK_OK;
+
+ } else {
+ pa_log_info("Successfully moved source input %u \"%s\" to %s.", i->index,
+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name);
+ return PA_HOOK_STOP;
+ }
+}
+
int pa__init(pa_module*m) {
pa_modargs *ma;
struct userdata *u;
@@ -146,8 +243,13 @@ int pa__init(pa_module*m) {
}
m->userdata = u = pa_xnew(struct userdata, 1);
- u->sink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) sink_hook_callback, NULL);
- u->source_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) source_hook_callback, NULL);
+
+ /* A little bit later than module-stream-restore, module-intended-roles... */
+ u->sink_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_LATE+20, (pa_hook_cb_t) sink_unlink_hook_callback, u);
+ u->source_unlink_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_LATE+20, (pa_hook_cb_t) source_unlink_hook_callback, u);
+
+ u->sink_input_move_fail_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_MOVE_FAIL], PA_HOOK_LATE+20, (pa_hook_cb_t) sink_input_move_fail_hook_callback, u);
+ u->source_output_move_fail_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_MOVE_FAIL], PA_HOOK_LATE+20, (pa_hook_cb_t) source_output_move_fail_hook_callback, u);
pa_modargs_free(ma);
return 0;
@@ -161,10 +263,15 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
- if (u->sink_slot)
- pa_hook_slot_free(u->sink_slot);
- if (u->source_slot)
- pa_hook_slot_free(u->source_slot);
+ if (u->sink_unlink_slot)
+ pa_hook_slot_free(u->sink_unlink_slot);
+ if (u->source_unlink_slot)
+ pa_hook_slot_free(u->source_unlink_slot);
+
+ if (u->sink_input_move_fail_slot)
+ pa_hook_slot_free(u->sink_input_move_fail_slot);
+ if (u->source_output_move_fail_slot)
+ pa_hook_slot_free(u->source_output_move_fail_slot);
pa_xfree(u);
}
diff --git a/src/modules/module-rygel-media-server.c b/src/modules/module-rygel-media-server.c
index 4c02e958..22930749 100644
--- a/src/modules/module-rygel-media-server.c
+++ b/src/modules/module-rygel-media-server.c
@@ -28,8 +28,8 @@
#include <string.h>
#include <unistd.h>
+#include <pulse/gccmacro.h>
#include <pulse/xmalloc.h>
-#include <pulse/util.h>
#include <pulse/i18n.h>
#include <pulse/utf8.h>
@@ -39,7 +39,6 @@
#include <pulsecore/log.h>
#include <pulsecore/modargs.h>
#include <pulsecore/dbus-shared.h>
-#include <pulsecore/endianmacros.h>
#include <pulsecore/namereg.h>
#include <pulsecore/mime-type.h>
#include <pulsecore/strbuf.h>
@@ -52,33 +51,52 @@ PA_MODULE_AUTHOR("Lennart Poettering");
PA_MODULE_DESCRIPTION("UPnP MediaServer Plugin for Rygel");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
-PA_MODULE_USAGE(
- "display_name=<UPnP Media Server name>");
+PA_MODULE_USAGE("display_name=<UPnP Media Server name>");
-/* This implements http://live.gnome.org/Rygel/MediaServerSpec */
+/* This implements http://live.gnome.org/Rygel/MediaServer2Spec */
-#define SERVICE_NAME "org.gnome.UPnP.MediaServer1.PulseAudio"
+#define SERVICE_NAME "org.gnome.UPnP.MediaServer2.PulseAudio"
-#define OBJECT_ROOT "/org/gnome/UPnP/MediaServer1/PulseAudio"
-#define OBJECT_SINKS "/org/gnome/UPnP/MediaServer1/PulseAudio/Sinks"
-#define OBJECT_SOURCES "/org/gnome/UPnP/MediaServer1/PulseAudio/Sources"
+#define OBJECT_ROOT "/org/gnome/UPnP/MediaServer2/PulseAudio"
+#define OBJECT_SINKS "/org/gnome/UPnP/MediaServer2/PulseAudio/Sinks"
+#define OBJECT_SOURCES "/org/gnome/UPnP/MediaServer2/PulseAudio/Sources"
#define CONTAINER_INTROSPECT_XML_PREFIX \
DBUS_INTROSPECT_1_0_XML_DOCTYPE_DECL_NODE \
"<node>" \
" <!-- If you are looking for documentation make sure to check out" \
- " http://live.gnome.org/Rygel/MediaServerSpec -->" \
- " <interface name=\"org.gnome.UPnP.MediaContainer1\">" \
+ " http://live.gnome.org/Rygel/MediaServer2Spec -->" \
+ " <interface name=\"org.gnome.UPnP.MediaContainer2\">" \
+ " <method name='ListChildren'>" \
+ " <arg direction='in' name='offset' type='u' />" \
+ " <arg direction='in' name='max' type='u' />" \
+ " <arg direction='in' name='filter' type='as' />" \
+ " <arg direction='out' type='aa{sv}' />" \
+ " </method>" \
+ " <method name='ListContainers'>" \
+ " <arg direction='in' name='offset' type='u' />" \
+ " <arg direction='in' name='max' type='u' />" \
+ " <arg direction='in' name='filter' type='as' />" \
+ " <arg direction='out' type='aa{sv}' />" \
+ " </method>" \
+ " <method name='ListItems'>" \
+ " <arg direction='in' name='offset' type='u' />" \
+ " <arg direction='in' name='max' type='u' />" \
+ " <arg direction='in' name='filter' type='as' />" \
+ " <arg direction='out' type='aa{sv}' />" \
+ " </method>" \
" <signal name=\"Updated\">" \
" <arg name=\"path\" type=\"o\"/>" \
" </signal>" \
- " <property name=\"Items\" type=\"ao\" access=\"read\"/>" \
+ " <property name=\"ChildCount\" type=\"u\" access=\"read\"/>" \
" <property name=\"ItemCount\" type=\"u\" access=\"read\"/>" \
- " <property name=\"Containers\" type=\"ao\" access=\"read\"/>" \
" <property name=\"ContainerCount\" type=\"u\" access=\"read\"/>" \
+ " <property name=\"Searchable\" type=\"b\" access=\"read\"/>" \
" </interface>" \
- " <interface name=\"org.gnome.UPnP.MediaObject1\">" \
+ " <interface name=\"org.gnome.UPnP.MediaObject2\">" \
" <property name=\"Parent\" type=\"s\" access=\"read\"/>" \
+ " <property name=\"Type\" type=\"s\" access=\"read\"/>" \
+ " <property name=\"Path\" type=\"s\" access=\"read\"/>" \
" <property name=\"DisplayName\" type=\"s\" access=\"read\"/>" \
" </interface>" \
" <interface name=\"org.freedesktop.DBus.Properties\">" \
@@ -111,14 +129,14 @@ PA_MODULE_USAGE(
DBUS_INTROSPECT_1_0_XML_DOCTYPE_DECL_NODE \
"<node>" \
" <!-- If you are looking for documentation make sure to check out" \
- " http://live.gnome.org/Rygel/MediaProviderSpec -->" \
- " <interface name=\"org.gnome.UPnP.MediaItem1\">" \
+ " http://live.gnome.org/Rygel/MediaProvider2Spec -->" \
+ " <interface name=\"org.gnome.UPnP.MediaItem2\">" \
" <property name=\"URLs\" type=\"as\" access=\"read\"/>" \
" <property name=\"MIMEType\" type=\"s\" access=\"read\"/>" \
- " <property name=\"Type\" type=\"s\" access=\"read\"/>" \
- " </interface>" \
- " <interface name=\"org.gnome.UPnP.MediaObject1\">" \
+ " <interface name=\"org.gnome.UPnP.MediaObject2\">" \
" <property name=\"Parent\" type=\"s\" access=\"read\"/>" \
+ " <property name=\"Type\" type=\"s\" access=\"read\"/>" \
+ " <property name=\"Path\" type=\"s\" access=\"read\"/>" \
" <property name=\"DisplayName\" type=\"s\" access=\"read\"/>" \
" </interface>" \
" <interface name=\"org.freedesktop.DBus.Properties\">" \
@@ -159,6 +177,8 @@ struct userdata {
pa_http_protocol *http;
};
+static char *compute_url(const struct userdata *u, const char *name);
+
static void send_signal(struct userdata *u, pa_source *s) {
DBusMessage *m;
const char *parent;
@@ -174,7 +194,7 @@ static void send_signal(struct userdata *u, pa_source *s) {
else
parent = OBJECT_SOURCES;
- pa_assert_se(m = dbus_message_new_signal(parent, "org.gnome.UPnP.MediaContainer1", "Updated"));
+ pa_assert_se(m = dbus_message_new_signal(parent, "org.gnome.UPnP.MediaContainer2", "Updated"));
pa_assert_se(dbus_connection_send(pa_dbus_connection_get(u->bus), m, NULL));
dbus_message_unref(m);
@@ -296,6 +316,70 @@ static void append_variant_unsigned(DBusMessage *m, DBusMessageIter *iter, unsig
pa_assert_se(dbus_message_iter_close_container(iter, &sub));
}
+static void append_variant_boolean(DBusMessage *m, DBusMessageIter *iter, dbus_bool_t b) {
+ DBusMessageIter _iter, sub;
+
+ pa_assert(m);
+
+ if (!iter) {
+ dbus_message_iter_init_append(m, &_iter);
+ iter = &_iter;
+ }
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_VARIANT, "b", &sub));
+ pa_assert_se(dbus_message_iter_append_basic(&sub, DBUS_TYPE_BOOLEAN, &b));
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+}
+
+static void append_variant_urls(DBusMessage *m, DBusMessageIter *iter, const struct userdata *u, pa_sink *sink, pa_source *source) {
+ DBusMessageIter _iter, sub, array;
+ char *url;
+
+ pa_assert(m);
+ pa_assert(u);
+ pa_assert(sink || source);
+
+ if (!iter) {
+ dbus_message_iter_init_append(m, &_iter);
+ iter = &_iter;
+ }
+
+ url = compute_url(u, sink ? sink->monitor_source->name : source->name);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_VARIANT, "as", &sub));
+ pa_assert_se(dbus_message_iter_open_container(&sub, DBUS_TYPE_ARRAY, "s", &array));
+ pa_assert_se(dbus_message_iter_append_basic(&array, DBUS_TYPE_STRING, &url));
+ pa_assert_se(dbus_message_iter_close_container(&sub, &array));
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+
+ pa_xfree(url);
+}
+
+static void append_variant_mime_type(DBusMessage *m, DBusMessageIter *iter, pa_sink *sink, pa_source *source) {
+ char *mime_type;
+
+ pa_assert(sink || source);
+
+ if (sink)
+ mime_type = pa_sample_spec_to_mime_type_mimefy(&sink->sample_spec, &sink->channel_map);
+ else
+ mime_type = pa_sample_spec_to_mime_type_mimefy(&source->sample_spec, &source->channel_map);
+
+ append_variant_string(m, iter, mime_type);
+
+ pa_xfree(mime_type);
+}
+
+static void append_variant_item_display_name(DBusMessage *m, DBusMessageIter *iter, pa_sink *sink, pa_source *source) {
+ const char *display_name;
+
+ pa_assert(sink || source);
+
+ display_name = pa_strna(pa_proplist_gets(sink ? sink->proplist : source->proplist, PA_PROP_DEVICE_DESCRIPTION));
+ append_variant_string(m, iter, display_name);
+}
+
+PA_GCC_UNUSED
static void append_property_dict_entry_object_array(DBusMessage *m, DBusMessageIter *iter, const char *name, const char *path[], unsigned n) {
DBusMessageIter sub;
@@ -340,6 +424,195 @@ static void append_property_dict_entry_unsigned(DBusMessage *m, DBusMessageIter
pa_assert_se(dbus_message_iter_close_container(iter, &sub));
}
+static void append_property_dict_entry_boolean(DBusMessage *m, DBusMessageIter *iter, const char *name, dbus_bool_t b) {
+ DBusMessageIter sub;
+
+ pa_assert(iter);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_DICT_ENTRY, NULL, &sub));
+ pa_assert_se(dbus_message_iter_append_basic(&sub, DBUS_TYPE_STRING, &name));
+ append_variant_boolean(m, &sub, b);
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+}
+
+static void append_property_dict_entry_urls(DBusMessage *m, DBusMessageIter *iter, const struct userdata *u, pa_sink *sink, pa_source *source) {
+ DBusMessageIter sub;
+ const char *property_name = "URLs";
+
+ pa_assert(iter);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_DICT_ENTRY, NULL, &sub));
+ pa_assert_se(dbus_message_iter_append_basic(&sub, DBUS_TYPE_STRING, &property_name));
+ append_variant_urls(m, &sub, u, sink, source);
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+}
+
+static void append_property_dict_entry_mime_type(DBusMessage *m, DBusMessageIter *iter, pa_sink *sink, pa_source *source) {
+ DBusMessageIter sub;
+ const char *property_name = "MIMEType";
+
+ pa_assert(iter);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_DICT_ENTRY, NULL, &sub));
+ pa_assert_se(dbus_message_iter_append_basic(&sub, DBUS_TYPE_STRING, &property_name));
+ append_variant_mime_type(m, &sub, sink, source);
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+}
+
+static void append_property_dict_entry_item_display_name(DBusMessage *m, DBusMessageIter *iter, pa_sink *sink, pa_source *source) {
+ DBusMessageIter sub;
+ const char *property_name = "DisplayName";
+
+ pa_assert(iter);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_DICT_ENTRY, NULL, &sub));
+ pa_assert_se(dbus_message_iter_append_basic(&sub, DBUS_TYPE_STRING, &property_name));
+ append_variant_item_display_name(m, &sub, sink, source);
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+}
+
+static pa_bool_t get_mediacontainer2_list_args(DBusMessage *m, unsigned *offset, unsigned *max_entries, char ***filter, int *filter_len) {
+ DBusError error;
+
+ dbus_error_init(&error);
+
+ pa_assert(m);
+ pa_assert(offset);
+ pa_assert(max_entries);
+ pa_assert(filter);
+
+ if (!dbus_message_get_args(m, &error, DBUS_TYPE_UINT32, offset, DBUS_TYPE_UINT32, max_entries, DBUS_TYPE_ARRAY, DBUS_TYPE_STRING, filter, filter_len, DBUS_TYPE_INVALID) || dbus_error_is_set(&error)) {
+ dbus_error_free(&error);
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+static unsigned get_sinks_or_sources_count(const char *path, const struct userdata *u) {
+ unsigned n, k;
+
+ n = pa_idxset_size(u->core->sinks);
+ k = pa_idxset_size(u->core->sources);
+ pa_assert(k >= n);
+
+ return pa_streq(path, OBJECT_SINKS) ? n : k - n;
+}
+
+static void append_sink_or_source_container_mediaobject2_properties(DBusMessage *r, DBusMessageIter *sub, const char *path) {
+ append_property_dict_entry_object(r, sub, "Parent", OBJECT_ROOT);
+ append_property_dict_entry_string(r, sub, "Type", "container");
+ append_property_dict_entry_object(r, sub, "Path", path);
+ append_property_dict_entry_string(r, sub, "DisplayName",
+ pa_streq(path, OBJECT_SINKS) ?
+ _("Output Devices") :
+ _("Input Devices"));
+}
+
+static void append_sink_or_source_container_properties(
+ DBusMessage *r, DBusMessageIter *iter,
+ const char *path, const struct userdata *user_data,
+ char * const * filter, int filter_len) {
+
+ DBusMessageIter sub;
+
+ pa_assert(r);
+ pa_assert(iter);
+ pa_assert(path);
+ pa_assert(filter);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
+
+ if (filter_len == 1 && (*filter)[0] == '*' && (*filter)[1] == '\0') {
+ append_sink_or_source_container_mediaobject2_properties(r, &sub, path);
+ append_property_dict_entry_unsigned(r, &sub, "ChildCount", get_sinks_or_sources_count(path, user_data));
+ append_property_dict_entry_boolean(r, &sub, "Searchable", FALSE);
+ }
+ else {
+ for (int i = 0; i < filter_len; ++i) {
+ const char *property_name = filter[i];
+ if (pa_streq(property_name, "Parent")) {
+ append_property_dict_entry_object(r, &sub, "Parent", OBJECT_ROOT);
+ }
+ else if (pa_streq(property_name, "Type")) {
+ append_property_dict_entry_string(r, &sub, "Type", "container");
+ }
+ else if (pa_streq(property_name, "Path")) {
+ append_property_dict_entry_object(r, &sub, "Path", path);
+ }
+ else if (pa_streq(property_name, "DisplayName")) {
+ append_property_dict_entry_string(r, &sub, "DisplayName",
+ pa_streq(path, OBJECT_SINKS) ?
+ _("Output Devices") :
+ _("Input Devices"));
+ }
+ else if (pa_streq(property_name, "ChildCount")) {
+ append_property_dict_entry_unsigned(r, &sub, "ChildCount", get_sinks_or_sources_count(path, user_data));
+ }
+ else if (pa_streq(property_name, "Searchable")) {
+ append_property_dict_entry_boolean(r, &sub, "Searchable", FALSE);
+ }
+ }
+ }
+
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+}
+
+static void append_sink_or_source_item_mediaobject2_properties(DBusMessage *r, DBusMessageIter *sub, const char *path, pa_sink *sink, pa_source *source) {
+ append_property_dict_entry_object(r, sub, "Parent", sink ? OBJECT_SINKS : OBJECT_SOURCES);
+ append_property_dict_entry_string(r, sub, "Type", "audio");
+ append_property_dict_entry_object(r, sub, "Path", path);
+ append_property_dict_entry_item_display_name(r, sub, sink, source);
+}
+
+static void append_sink_or_source_item_properties(
+ DBusMessage *r, DBusMessageIter *iter,
+ const char *path, const struct userdata *user_data,
+ pa_sink *sink, pa_source *source,
+ char * const * filter, int filter_len) {
+
+ DBusMessageIter sub;
+
+ pa_assert(r);
+ pa_assert(iter);
+ pa_assert(path);
+ pa_assert(filter);
+ pa_assert(sink || source);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
+
+ if (filter_len == 1 && (*filter)[0] == '*' && (*filter)[1] == '\0') {
+ append_sink_or_source_item_mediaobject2_properties(r, &sub, path, sink, source);
+ append_property_dict_entry_urls(r, &sub, user_data, sink, source);
+ append_property_dict_entry_mime_type(r, &sub, sink, source);
+ }
+ else {
+ for (int i = 0; i < filter_len; ++i) {
+ const char *property_name = filter[i];
+ if (pa_streq(property_name, "Parent")) {
+ append_property_dict_entry_object(r, &sub, "Parent", sink ? OBJECT_SINKS : OBJECT_SOURCES);
+ }
+ else if (pa_streq(property_name, "Type")) {
+ append_property_dict_entry_string(r, &sub, "Type", "audio");
+ }
+ else if (pa_streq(property_name, "Path")) {
+ append_property_dict_entry_object(r, &sub, "Path", path);
+ }
+ else if (pa_streq(property_name, "DisplayName")) {
+ append_property_dict_entry_item_display_name(r, &sub, sink, source);
+ }
+ else if (pa_streq(property_name, "URLs")) {
+ append_property_dict_entry_urls(r, &sub, user_data, sink, source);
+ }
+ else if (pa_streq(property_name, "MIMEType")) {
+ append_property_dict_entry_mime_type(r, &sub, sink, source);
+ }
+ }
+ }
+
+ pa_assert_se(dbus_message_iter_close_container(iter, &sub));
+}
+
static const char *array_root_containers[] = { OBJECT_SINKS, OBJECT_SOURCES };
static const char *array_no_children[] = { };
@@ -349,50 +622,100 @@ static DBusHandlerResult root_handler(DBusConnection *c, DBusMessage *m, void *u
pa_assert(u);
- if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "Containers")) {
+ if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "ChildCount")) {
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_object_array(r, NULL, (const char**) array_root_containers, PA_ELEMENTSOF(array_root_containers));
+ append_variant_unsigned(r, NULL, PA_ELEMENTSOF(array_root_containers));
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "ContainerCount")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "ItemCount")) {
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_unsigned(r, NULL, PA_ELEMENTSOF(array_root_containers));
+ append_variant_unsigned(r, NULL, PA_ELEMENTSOF(array_no_children));
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "Items")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "ContainerCount")) {
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_object_array(r, NULL, array_no_children, PA_ELEMENTSOF(array_no_children));
+ append_variant_unsigned(r, NULL, PA_ELEMENTSOF(array_root_containers));
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "ItemCount")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "Searchable")) {
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_unsigned(r, NULL, PA_ELEMENTSOF(array_no_children));
+ append_variant_boolean(r, NULL, FALSE);
- } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaContainer1")) {
+ } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaContainer2")) {
DBusMessageIter iter, sub;
pa_assert_se(r = dbus_message_new_method_return(m));
dbus_message_iter_init_append(r, &iter);
pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
- append_property_dict_entry_object_array(r, &sub, "Containers", array_root_containers, PA_ELEMENTSOF(array_root_containers));
- append_property_dict_entry_unsigned(r, &sub, "ContainerCount", PA_ELEMENTSOF(array_root_containers));
- append_property_dict_entry_object_array(r, &sub, "Items", array_no_children, PA_ELEMENTSOF(array_no_children));
+ append_property_dict_entry_unsigned(r, &sub, "ChildCount", PA_ELEMENTSOF(array_root_containers));
append_property_dict_entry_unsigned(r, &sub, "ItemCount", PA_ELEMENTSOF(array_no_children));
+ append_property_dict_entry_unsigned(r, &sub, "ContainerCount", PA_ELEMENTSOF(array_root_containers));
+ append_property_dict_entry_boolean(r, &sub, "Searchable", FALSE);
+ pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
+
+ } else if (dbus_message_is_method_call(m, "org.gnome.UPnP.MediaContainer2", "ListChildren")
+ || dbus_message_is_method_call(m, "org.gnome.UPnP.MediaContainer2", "ListContainers")) {
+ DBusMessageIter iter, sub;
+ unsigned offset, max;
+ char ** filter;
+ int filter_len;
+
+ pa_assert_se(r = dbus_message_new_method_return(m));
+
+ dbus_message_iter_init_append(r, &iter);
+ pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "a{sv}", &sub));
+
+ if (get_mediacontainer2_list_args(m, &offset, &max, &filter, &filter_len)) {
+ unsigned end = (max != 0 && offset + max < PA_ELEMENTSOF(array_root_containers))
+ ? max + offset
+ : PA_ELEMENTSOF(array_root_containers);
+
+ for (unsigned i = offset; i < end; ++i) {
+ const char *container_path = array_root_containers[i];
+ append_sink_or_source_container_properties(r, &sub, container_path, u, filter, filter_len);
+ }
+
+ dbus_free_string_array(filter);
+ }
+
+ pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
+
+ } else if (dbus_message_is_method_call(m, "org.gnome.UPnP.MediaContainer2", "ListItems")) {
+ DBusMessageIter iter, sub;
+
+ pa_assert_se(r = dbus_message_new_method_return(m));
+
+ dbus_message_iter_init_append(r, &iter);
+ pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "a{sv}", &sub));
pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject1", "Parent")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Parent")) {
pa_assert_se(r = dbus_message_new_method_return(m));
append_variant_object(r, NULL, OBJECT_ROOT);
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject1", "DisplayName")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Type")) {
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_string(r, NULL, "container");
+
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Path")) {
+ const char *path = dbus_message_get_path(m);
+
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_object(r, NULL, path);
+
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "DisplayName")) {
pa_assert_se(r = dbus_message_new_method_return(m));
append_variant_string(r, NULL, u->display_name);
- } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaObject1")) {
+ } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaObject2")) {
DBusMessageIter iter, sub;
+ const char *path = dbus_message_get_path(m);
pa_assert_se(r = dbus_message_new_method_return(m));
dbus_message_iter_init_append(r, &iter);
pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
+ append_property_dict_entry_object(r, &sub, "Parent", OBJECT_ROOT);
+ append_property_dict_entry_string(r, &sub, "Type", "container");
+ append_property_dict_entry_object(r, &sub, "Path", path);
append_property_dict_entry_string(r, &sub, "DisplayName", u->display_name);
pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
@@ -400,10 +723,7 @@ static DBusHandlerResult root_handler(DBusConnection *c, DBusMessage *m, void *u
const char *xml = ROOT_INTROSPECT_XML;
pa_assert_se(r = dbus_message_new_method_return(m));
- pa_assert_se(dbus_message_append_args(
- r,
- DBUS_TYPE_STRING, &xml,
- DBUS_TYPE_INVALID));
+ pa_assert_se(dbus_message_append_args(r, DBUS_TYPE_STRING, &xml, DBUS_TYPE_INVALID));
} else
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
@@ -416,7 +736,7 @@ static DBusHandlerResult root_handler(DBusConnection *c, DBusMessage *m, void *u
return DBUS_HANDLER_RESULT_HANDLED;
}
-static char *compute_url(struct userdata *u, const char *name) {
+static char *compute_url(const struct userdata *u, const char *name) {
pa_strlist *i;
pa_assert(u);
@@ -453,49 +773,6 @@ static char *compute_url(struct userdata *u, const char *name) {
return pa_sprintf_malloc("http://@ADDRESS@:4714/listen/source/%s", name);
}
-static char **child_array(struct userdata *u, const char *path, unsigned *n) {
- unsigned m;
- uint32_t idx;
- char **array;
-
- pa_assert(u);
- pa_assert(path);
- pa_assert(n);
-
- if (pa_streq(path, OBJECT_SINKS))
- m = pa_idxset_size(u->core->sinks);
- else
- m = pa_idxset_size(u->core->sources);
-
- array = pa_xnew(char*, m);
- *n = 0;
-
- if (pa_streq(path, OBJECT_SINKS)) {
- pa_sink *sink;
-
- PA_IDXSET_FOREACH(sink, u->core->sinks, idx)
- array[(*n)++] = pa_sprintf_malloc(OBJECT_SINKS "/%u", sink->index);
- } else {
- pa_source *source;
-
- PA_IDXSET_FOREACH(source, u->core->sources, idx)
- if (!source->monitor_of)
- array[(*n)++] = pa_sprintf_malloc(OBJECT_SOURCES "/%u", source->index);
- }
-
- pa_assert((*n) <= m);
-
- return array;
-}
-
-static void free_child_array(char **array, unsigned n) {
-
- for (; n >= 1; n--)
- pa_xfree(array[n-1]);
-
- pa_xfree(array);
-}
-
static DBusHandlerResult sinks_and_sources_handler(DBusConnection *c, DBusMessage *m, void *userdata) {
struct userdata *u = userdata;
DBusMessage *r = NULL;
@@ -509,59 +786,114 @@ static DBusHandlerResult sinks_and_sources_handler(DBusConnection *c, DBusMessag
/* Container nodes */
- if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "Containers")) {
+ if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "ChildCount")
+ || message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "ItemCount")) {
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_object_array(r, NULL, array_no_children, PA_ELEMENTSOF(array_no_children));
+ append_variant_unsigned(r, NULL, get_sinks_or_sources_count(path, u));
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "ContainerCount")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "ContainerCount")) {
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_unsigned(r, NULL, PA_ELEMENTSOF(array_no_children));
+ append_variant_unsigned(r, NULL, 0);
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "Items")) {
- char ** array;
- unsigned n;
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer2", "Searchable")) {
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_boolean(r, NULL, FALSE);
- array = child_array(u, path, &n);
+ } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaContainer2")) {
+ DBusMessageIter iter, sub;
+ unsigned item_count;
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_object_array(r, NULL, (const char**) array, n);
+ dbus_message_iter_init_append(r, &iter);
- free_child_array(array, n);
+ pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaContainer1", "ItemCount")) {
- pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_unsigned(r, NULL,
- pa_streq(path, OBJECT_SINKS) ?
- pa_idxset_size(u->core->sinks) :
- pa_idxset_size(u->core->sources));
+ item_count = get_sinks_or_sources_count(path, u);
+
+ append_property_dict_entry_unsigned(r, &sub, "ChildCount", item_count);
+ append_property_dict_entry_unsigned(r, &sub, "ItemCount", item_count);
+ append_property_dict_entry_unsigned(r, &sub, "ContainerCount", 0);
+ append_property_dict_entry_boolean(r, &sub, "Searchable", FALSE);
+
+ pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
- } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaContainer1")) {
+ } else if (dbus_message_is_method_call(m, "org.gnome.UPnP.MediaContainer2", "ListChildren")
+ || dbus_message_is_method_call(m, "org.gnome.UPnP.MediaContainer2", "ListItems")) {
DBusMessageIter iter, sub;
- char **array;
- unsigned n;
+ unsigned offset, max;
+ char **filter;
+ int filter_len;
pa_assert_se(r = dbus_message_new_method_return(m));
+
dbus_message_iter_init_append(r, &iter);
+ pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "a{sv}", &sub));
+
+ if (get_mediacontainer2_list_args(m, &offset, &max, &filter, &filter_len)) {
+ unsigned end = (max != 0) ? max + offset : UINT_MAX;
+
+ if (pa_streq(path, OBJECT_SINKS)) {
+ pa_sink *sink;
+ char sink_path[sizeof(OBJECT_SINKS) + 32];
+ char *path_end = sink_path + sizeof(OBJECT_SINKS);
+ unsigned item_index = 0;
+ uint32_t idx;
+
+ strcpy(sink_path, OBJECT_SINKS "/");
+
+ PA_IDXSET_FOREACH(sink, u->core->sinks, idx) {
+ if (item_index >= offset && item_index < end) {
+ sprintf(path_end, "%u", sink->index);
+ append_sink_or_source_item_properties(r, &sub, sink_path, u, sink, NULL, filter, filter_len);
+ }
+ ++item_index;
+ }
+ } else {
+ pa_source *source;
+ char source_path[sizeof(OBJECT_SOURCES) + 32];
+ char *path_end = source_path + sizeof(OBJECT_SOURCES);
+ unsigned item_index = 0;
+ uint32_t idx;
+
+ strcpy(source_path, OBJECT_SOURCES "/");
+
+ PA_IDXSET_FOREACH(source, u->core->sources, idx)
+ if (!source->monitor_of) {
+ if (item_index >= offset && item_index < end) {
+ sprintf(path_end, "%u", source->index);
+ append_sink_or_source_item_properties(r, &sub, source_path, u, NULL, source, filter, filter_len);
+ }
+ ++item_index;
+ }
+ }
+
+ dbus_free_string_array(filter);
+ }
- pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
- append_property_dict_entry_object_array(r, &sub, "Containers", array_no_children, PA_ELEMENTSOF(array_no_children));
- append_property_dict_entry_unsigned(r, &sub, "ContainerCount", 0);
+ pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
- array = child_array(u, path, &n);
- append_property_dict_entry_object_array(r, &sub, "Items", (const char**) array, n);
- free_child_array(array, n);
- append_property_dict_entry_unsigned(r, &sub, "ItemCount",
- pa_streq(path, OBJECT_SINKS) ?
- pa_idxset_size(u->core->sinks) :
- pa_idxset_size(u->core->sources));
+ } else if (dbus_message_is_method_call(m, "org.gnome.UPnP.MediaContainer2", "ListContainers")) {
+ DBusMessageIter iter, sub;
+
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ dbus_message_iter_init_append(r, &iter);
+ pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "a{sv}", &sub));
pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject1", "Parent")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Parent")) {
pa_assert_se(r = dbus_message_new_method_return(m));
append_variant_object(r, NULL, OBJECT_ROOT);
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject1", "DisplayName")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Type")) {
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_string(r, NULL, "container");
+
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Path")) {
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_object(r, NULL, path);
+
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "DisplayName")) {
pa_assert_se(r = dbus_message_new_method_return(m));
append_variant_string(r,
NULL,
@@ -569,20 +901,14 @@ static DBusHandlerResult sinks_and_sources_handler(DBusConnection *c, DBusMessag
_("Output Devices") :
_("Input Devices"));
- } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaObject1")) {
+ } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaObject2")) {
DBusMessageIter iter, sub;
pa_assert_se(r = dbus_message_new_method_return(m));
dbus_message_iter_init_append(r, &iter);
-
pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
- append_property_dict_entry_object(m, &sub, "Parent", OBJECT_ROOT);
- append_property_dict_entry_string(m, &sub, "DisplayName",
- pa_streq(path, OBJECT_SINKS) ?
- _("Output Devices") :
- _("Input Devices"));
- pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
+ append_sink_or_source_container_mediaobject2_properties(r, &sub, path);
} else if (dbus_message_is_method_call(m, "org.freedesktop.DBus.Introspectable", "Introspect")) {
pa_strbuf *sb;
@@ -609,10 +935,7 @@ static DBusHandlerResult sinks_and_sources_handler(DBusConnection *c, DBusMessag
xml = pa_strbuf_tostring_free(sb);
pa_assert_se(r = dbus_message_new_method_return(m));
- pa_assert_se(dbus_message_append_args(
- r,
- DBUS_TYPE_STRING, &xml,
- DBUS_TYPE_INVALID));
+ pa_assert_se(dbus_message_append_args(r, DBUS_TYPE_STRING, &xml, DBUS_TYPE_INVALID));
pa_xfree(xml);
} else
@@ -632,91 +955,49 @@ static DBusHandlerResult sinks_and_sources_handler(DBusConnection *c, DBusMessag
if (!sink && !source)
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
- if (message_is_property_get(m, "org.gnome.UPnP.MediaObject1", "Parent")) {
+ if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Parent")) {
pa_assert_se(r = dbus_message_new_method_return(m));
append_variant_object(r, NULL, sink ? OBJECT_SINKS : OBJECT_SOURCES);
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject1", "DisplayName")) {
- pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_string(r, NULL, pa_strna(pa_proplist_gets(sink ? sink->proplist : source->proplist, PA_PROP_DEVICE_DESCRIPTION)));
-
- } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaObject1")) {
- DBusMessageIter iter, sub;
-
- pa_assert_se(r = dbus_message_new_method_return(m));
- dbus_message_iter_init_append(r, &iter);
-
- pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
- append_property_dict_entry_object(r, &sub, "Parent", sink ? OBJECT_SINKS : OBJECT_SOURCES);
- append_property_dict_entry_string(r, &sub, "DisplayName", pa_strna(pa_proplist_gets(sink ? sink->proplist : source->proplist, PA_PROP_DEVICE_DESCRIPTION)));
- pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
-
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaItem1", "Type")) {
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Type")) {
pa_assert_se(r = dbus_message_new_method_return(m));
append_variant_string(r, NULL, "audio");
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaItem1", "MIMEType")) {
- char *t;
-
- if (sink)
- t = pa_sample_spec_to_mime_type_mimefy(&sink->sample_spec, &sink->channel_map);
- else
- t = pa_sample_spec_to_mime_type_mimefy(&source->sample_spec, &source->channel_map);
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "Path")) {
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_object(r, NULL, path);
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaObject2", "DisplayName")) {
pa_assert_se(r = dbus_message_new_method_return(m));
- append_variant_string(r, NULL, t);
- pa_xfree(t);
+ append_variant_item_display_name(r, NULL, sink, source);
- } else if (message_is_property_get(m, "org.gnome.UPnP.MediaItem1", "URLs")) {
- DBusMessageIter iter, sub, array;
- char *url;
+ } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaObject2")) {
+ DBusMessageIter iter, sub;
pa_assert_se(r = dbus_message_new_method_return(m));
-
dbus_message_iter_init_append(r, &iter);
- url = compute_url(u, sink ? sink->monitor_source->name : source->name);
+ pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
+ append_sink_or_source_item_mediaobject2_properties(r, &sub, path, sink, source);
- pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_VARIANT, "as", &sub));
- pa_assert_se(dbus_message_iter_open_container(&sub, DBUS_TYPE_ARRAY, "s", &array));
- pa_assert_se(dbus_message_iter_append_basic(&array, DBUS_TYPE_STRING, &url));
- pa_assert_se(dbus_message_iter_close_container(&sub, &array));
- pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaItem2", "MIMEType")) {
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_mime_type(r, NULL, sink, source);
- pa_xfree(url);
+ } else if (message_is_property_get(m, "org.gnome.UPnP.MediaItem2", "URLs")) {
+ pa_assert_se(r = dbus_message_new_method_return(m));
+ append_variant_urls(r, NULL, u, sink, source);
- } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaItem1")) {
- DBusMessageIter iter, sub, dict, variant, array;
- char *url, *t;
- const char *un = "URLs";
+ } else if (message_is_property_get_all(m, "org.gnome.UPnP.MediaItem2")) {
+ DBusMessageIter iter, sub;
pa_assert_se(r = dbus_message_new_method_return(m));
dbus_message_iter_init_append(r, &iter);
pa_assert_se(dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &sub));
- append_property_dict_entry_string(r, &sub, "Type", "audio");
-
- if (sink)
- t = pa_sample_spec_to_mime_type_mimefy(&sink->sample_spec, &sink->channel_map);
- else
- t = pa_sample_spec_to_mime_type_mimefy(&source->sample_spec, &source->channel_map);
-
- append_property_dict_entry_string(r, &sub, "MIMEType", t);
- pa_xfree(t);
-
- pa_assert_se(dbus_message_iter_open_container(&sub, DBUS_TYPE_DICT_ENTRY, NULL, &dict));
- pa_assert_se(dbus_message_iter_append_basic(&dict, DBUS_TYPE_STRING, &un));
-
- url = compute_url(u, sink ? sink->monitor_source->name : source->name);
-
- pa_assert_se(dbus_message_iter_open_container(&dict, DBUS_TYPE_VARIANT, "as", &variant));
- pa_assert_se(dbus_message_iter_open_container(&variant, DBUS_TYPE_ARRAY, "s", &array));
- pa_assert_se(dbus_message_iter_append_basic(&array, DBUS_TYPE_STRING, &url));
- pa_assert_se(dbus_message_iter_close_container(&variant, &array));
- pa_assert_se(dbus_message_iter_close_container(&dict, &variant));
- pa_assert_se(dbus_message_iter_close_container(&sub, &dict));
- pa_xfree(url);
+ append_property_dict_entry_mime_type(r, &sub, sink, source);
+ append_property_dict_entry_urls(r, &sub, u, sink, source);
pa_assert_se(dbus_message_iter_close_container(&iter, &sub));
@@ -725,10 +1006,7 @@ static DBusHandlerResult sinks_and_sources_handler(DBusConnection *c, DBusMessag
ITEM_INTROSPECT_XML;
pa_assert_se(r = dbus_message_new_method_return(m));
- pa_assert_se(dbus_message_append_args(
- r,
- DBUS_TYPE_STRING, &xml,
- DBUS_TYPE_INVALID));
+ pa_assert_se(dbus_message_append_args(r, DBUS_TYPE_STRING, &xml, DBUS_TYPE_INVALID));
} else
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
diff --git a/src/modules/module-sine-source.c b/src/modules/module-sine-source.c
index 14a04e47..20a68680 100644
--- a/src/modules/module-sine-source.c
+++ b/src/modules/module-sine-source.c
@@ -24,20 +24,14 @@
#endif
#include <stdlib.h>
-#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
-#include <string.h>
-#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
-#include <sys/ioctl.h>
-#include <sys/poll.h>
-#include <pulse/xmalloc.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
+#include <pulse/xmalloc.h>
-#include <pulsecore/core-error.h>
#include <pulsecore/source.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
@@ -46,7 +40,6 @@
#include <pulsecore/thread.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
-#include <pulsecore/rtclock.h>
#include "module-sine-source-symdef.h"
@@ -101,14 +94,14 @@ static int source_process_msg(
case PA_SOURCE_MESSAGE_SET_STATE:
if (PA_PTR_TO_UINT(data) == PA_SOURCE_RUNNING)
- u->timestamp = pa_rtclock_usec();
+ u->timestamp = pa_rtclock_now();
break;
case PA_SOURCE_MESSAGE_GET_LATENCY: {
pa_usec_t now, left_to_fill;
- now = pa_rtclock_usec();
+ now = pa_rtclock_now();
left_to_fill = u->timestamp > now ? u->timestamp - now : 0ULL;
*((pa_usec_t*) data) = u->block_usec > left_to_fill ? u->block_usec - left_to_fill : 0ULL;
@@ -166,9 +159,8 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
- u->timestamp = pa_rtclock_usec();
+ u->timestamp = pa_rtclock_now();
for (;;) {
int ret;
@@ -176,7 +168,7 @@ static void thread_func(void *userdata) {
if (PA_SOURCE_IS_OPENED(u->source->thread_info.state)) {
pa_usec_t now;
- now = pa_rtclock_usec();
+ now = pa_rtclock_now();
if (u->timestamp <= now)
process_render(u, now);
@@ -274,7 +266,7 @@ int pa__init(pa_module*m) {
pa_source_set_rtpoll(u->source, u->rtpoll);
pa_source_set_fixed_latency(u->source, u->block_usec);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("sine-source", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
diff --git a/src/modules/module-sine.c b/src/modules/module-sine.c
index 0be1d722..c6d73039 100644
--- a/src/modules/module-sine.c
+++ b/src/modules/module-sine.c
@@ -24,7 +24,6 @@
#endif
#include <stdio.h>
-#include <math.h>
#include <pulse/xmalloc.h>
@@ -33,7 +32,6 @@
#include <pulsecore/modargs.h>
#include <pulsecore/namereg.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
#include "module-sine-symdef.h"
@@ -157,13 +155,13 @@ int pa__init(pa_module*m) {
pa_sink_input_new_data_init(&data);
data.driver = __FILE__;
data.module = m;
- data.sink = sink;
+ pa_sink_input_new_data_set_sink(&data, sink, FALSE);
pa_proplist_setf(data.proplist, PA_PROP_MEDIA_NAME, "%u Hz Sine", frequency);
pa_proplist_sets(data.proplist, PA_PROP_MEDIA_ROLE, "abstract");
pa_proplist_setf(data.proplist, "sine.hz", "%u", frequency);
pa_sink_input_new_data_set_sample_spec(&data, &ss);
- pa_sink_input_new(&u->sink_input, m->core, &data, 0);
+ pa_sink_input_new(&u->sink_input, m->core, &data);
pa_sink_input_new_data_done(&data);
if (!u->sink_input)
diff --git a/src/modules/module-solaris.c b/src/modules/module-solaris.c
index 5cfa97a7..0e4e4017 100644
--- a/src/modules/module-solaris.c
+++ b/src/modules/module-solaris.c
@@ -28,12 +28,9 @@
#include <stdlib.h>
#include <stdio.h>
#include <errno.h>
-#include <string.h>
#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
#include <sys/ioctl.h>
-#include <sys/stat.h>
#include <sys/types.h>
#include <signal.h>
@@ -41,13 +38,12 @@
#include <sys/conf.h>
#include <sys/audio.h>
-#include <pulse/error.h>
#include <pulse/mainloop-signal.h>
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
#include <pulse/util.h>
+#include <pulse/rtclock.h>
-#include <pulsecore/iochannel.h>
#include <pulsecore/sink.h>
#include <pulsecore/source.h>
#include <pulsecore/module.h>
@@ -59,7 +55,7 @@
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
#include <pulsecore/thread.h>
-#include <pulsecore/rtclock.h>
+#include <pulsecore/time-smoother.h>
#include "module-solaris-symdef.h"
@@ -110,6 +106,8 @@ struct userdata {
uint32_t prev_playback_samples, prev_record_samples;
int32_t minimum_request;
+
+ pa_smoother *smoother;
};
static const char* const valid_modargs[] = {
@@ -133,6 +131,9 @@ static const char* const valid_modargs[] = {
#define MAX_RENDER_HZ (300)
/* This render rate limit imposes a minimum latency, but without it we waste too much CPU time. */
+#define MAX_BUFFER_SIZE (128 * 1024)
+/* An attempt to buffer more than 128 KB causes write() to fail with errno == EAGAIN. */
+
static uint64_t get_playback_buffered_bytes(struct userdata *u) {
audio_info_t info;
uint64_t played_bytes;
@@ -145,7 +146,12 @@ static uint64_t get_playback_buffered_bytes(struct userdata *u) {
/* Handle wrap-around of the device's sample counter, which is a uint_32. */
if (u->prev_playback_samples > info.play.samples) {
- /* Unfortunately info.play.samples can sometimes go backwards, even before it wraps! */
+ /*
+ * Unfortunately info.play.samples can sometimes go backwards, even before it wraps!
+ * The bug seems to be absent on Solaris x86 nv117 with audio810 driver, at least on this (UP) machine.
+ * The bug is present on a different (SMP) machine running Solaris x86 nv103 with audioens driver.
+ * An earlier revision of this file mentions the same bug independently (unknown configuration).
+ */
if (u->prev_playback_samples + info.play.samples < 240000) {
++u->play_samples_msw;
} else {
@@ -155,6 +161,8 @@ static uint64_t get_playback_buffered_bytes(struct userdata *u) {
u->prev_playback_samples = info.play.samples;
played_bytes = (((uint64_t)u->play_samples_msw << 32) + info.play.samples) * u->frame_size;
+ pa_smoother_put(u->smoother, pa_rtclock_now(), pa_bytes_to_usec(played_bytes, &u->sink->sample_spec));
+
return u->written_bytes - played_bytes;
}
@@ -294,8 +302,8 @@ static int auto_format(int fd, int mode, pa_sample_spec *ss) {
info.record.encoding = AUDIO_ENCODING_LINEAR;
break;
default:
- pa_log("AUDIO_SETINFO: Unsupported sample format.");
- return -1;
+ pa_log("AUDIO_SETINFO: Unsupported sample format.");
+ return -1;
}
}
@@ -314,7 +322,7 @@ static int open_audio_device(struct userdata *u, pa_sample_spec *ss) {
pa_assert(u);
pa_assert(ss);
- if ((u->fd = open(u->device_name, u->mode | O_NONBLOCK)) < 0) {
+ if ((u->fd = pa_open_cloexec(u->device_name, u->mode | O_NONBLOCK, 0)) < 0) {
pa_log_warn("open %s failed (%s)", u->device_name, pa_cstrerror(errno));
return -1;
}
@@ -387,6 +395,8 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
pa_assert(PA_SINK_IS_OPENED(u->sink->thread_info.state));
+ pa_smoother_pause(u->smoother, pa_rtclock_now());
+
if (!u->source || u->source_suspended) {
if (suspend(u) < 0)
return -1;
@@ -398,6 +408,8 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
case PA_SINK_RUNNING:
if (u->sink->thread_info.state == PA_SINK_SUSPENDED) {
+ pa_smoother_resume(u->smoother, pa_rtclock_now(), TRUE);
+
if (!u->source || u->source_suspended) {
if (unsuspend(u) < 0)
return -1;
@@ -479,7 +491,7 @@ static void sink_set_volume(pa_sink *s) {
if (u->fd >= 0) {
AUDIO_INITINFO(&info);
- info.play.gain = pa_cvolume_max(&s->virtual_volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
+ info.play.gain = pa_cvolume_max(&s->real_volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
assert(info.play.gain <= AUDIO_MAX_GAIN);
if (ioctl(u->fd, AUDIO_SETINFO, &info) < 0) {
@@ -501,8 +513,7 @@ static void sink_get_volume(pa_sink *s) {
if (ioctl(u->fd, AUDIO_GETINFO, &info) < 0)
pa_log("AUDIO_SETINFO: %s", pa_cstrerror(errno));
else
- pa_cvolume_set(&s->virtual_volume, s->sample_spec.channels,
- info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
+ pa_cvolume_set(&s->real_volume, s->sample_spec.channels, info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
}
}
@@ -515,7 +526,7 @@ static void source_set_volume(pa_source *s) {
if (u->fd >= 0) {
AUDIO_INITINFO(&info);
- info.play.gain = pa_cvolume_max(&s->virtual_volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
+ info.play.gain = pa_cvolume_max(&s->volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
assert(info.play.gain <= AUDIO_MAX_GAIN);
if (ioctl(u->fd, AUDIO_SETINFO, &info) < 0) {
@@ -537,8 +548,7 @@ static void source_get_volume(pa_source *s) {
if (ioctl(u->fd, AUDIO_GETINFO, &info) < 0)
pa_log("AUDIO_SETINFO: %s", pa_cstrerror(errno));
else
- pa_cvolume_set(&s->virtual_volume, s->sample_spec.channels,
- info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
+ pa_cvolume_set(&s->volume, s->sample_spec.channels, info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
}
}
@@ -585,6 +595,10 @@ static void process_rewind(struct userdata *u) {
pa_log_debug("Requested to rewind %lu bytes.", (unsigned long) rewind_nbytes);
rewind_nbytes = PA_MIN(u->memchunk.length, rewind_nbytes);
u->memchunk.length -= rewind_nbytes;
+ if (u->memchunk.length <= 0 && u->memchunk.memblock) {
+ pa_memblock_unref(u->memchunk.memblock);
+ pa_memchunk_reset(&u->memchunk);
+ }
pa_log_debug("Rewound %lu bytes.", (unsigned long) rewind_nbytes);
}
@@ -605,13 +619,14 @@ static void thread_func(void *userdata) {
pa_make_realtime(u->core->realtime_priority);
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
+
+ pa_smoother_set_time_offset(u->smoother, pa_rtclock_now());
for (;;) {
/* Render some data and write it to the dsp */
if (u->sink && PA_SINK_IS_OPENED(u->sink->thread_info.state)) {
- pa_usec_t xtime0;
+ pa_usec_t xtime0, ysleep_interval, xsleep_interval;
uint64_t buffered_bytes;
if (u->sink->thread_info.rewind_requested)
@@ -630,18 +645,21 @@ static void thread_func(void *userdata) {
info.play.error = 0;
if (ioctl(u->fd, AUDIO_SETINFO, &info) < 0)
pa_log("AUDIO_SETINFO: %s", pa_cstrerror(errno));
+
+ pa_smoother_reset(u->smoother, pa_rtclock_now(), TRUE);
}
for (;;) {
void *p;
ssize_t w;
size_t len;
+ int write_type = 1;
/*
* Since we cannot modify the size of the output buffer we fake it
* by not filling it more than u->buffer_size.
*/
- xtime0 = pa_rtclock_usec();
+ xtime0 = pa_rtclock_now();
buffered_bytes = get_playback_buffered_bytes(u);
if (buffered_bytes >= (uint64_t)u->buffer_size)
break;
@@ -652,39 +670,32 @@ static void thread_func(void *userdata) {
if (len < (size_t) u->minimum_request)
break;
- if (u->memchunk.length < len)
+ if (!u->memchunk.length)
pa_sink_render(u->sink, u->sink->thread_info.max_request, &u->memchunk);
+ len = PA_MIN(u->memchunk.length, len);
+
p = pa_memblock_acquire(u->memchunk.memblock);
- w = pa_write(u->fd, (uint8_t*) p + u->memchunk.index, u->memchunk.length, NULL);
+ w = pa_write(u->fd, (uint8_t*) p + u->memchunk.index, len, &write_type);
pa_memblock_release(u->memchunk.memblock);
if (w <= 0) {
- switch (errno) {
- case EINTR:
- continue;
- case EAGAIN:
- /* If the buffer_size is too big, we get EAGAIN. Avoiding that limit by trial and error
- * is not ideal, but I don't know how to get the system to tell me what the limit is.
- */
- u->buffer_size = u->buffer_size * 18 / 25;
- u->buffer_size -= u->buffer_size % u->frame_size;
- u->buffer_size = PA_MAX(u->buffer_size, 2 * u->minimum_request);
- pa_sink_set_max_request_within_thread(u->sink, u->buffer_size);
- pa_sink_set_max_rewind_within_thread(u->sink, u->buffer_size);
- pa_log("EAGAIN. Buffer size is now %u bytes (%llu buffered)", u->buffer_size, buffered_bytes);
- break;
- default:
- pa_log("Failed to write data to DSP: %s", pa_cstrerror(errno));
- goto fail;
+ if (errno == EINTR) {
+ continue;
+ } else if (errno == EAGAIN) {
+ /* We may have realtime priority so yield the CPU to ensure that fd can become writable again. */
+ pa_log_debug("EAGAIN with %llu bytes buffered.", buffered_bytes);
+ break;
+ } else {
+ pa_log("Failed to write data to DSP: %s", pa_cstrerror(errno));
+ goto fail;
}
} else {
pa_assert(w % u->frame_size == 0);
u->written_bytes += w;
- u->memchunk.length -= w;
-
u->memchunk.index += w;
+ u->memchunk.length -= w;
if (u->memchunk.length <= 0) {
pa_memblock_unref(u->memchunk.memblock);
pa_memchunk_reset(&u->memchunk);
@@ -692,7 +703,9 @@ static void thread_func(void *userdata) {
}
}
- pa_rtpoll_set_timer_absolute(u->rtpoll, xtime0 + pa_bytes_to_usec(buffered_bytes / 2, &u->sink->sample_spec));
+ ysleep_interval = pa_bytes_to_usec(buffered_bytes / 2, &u->sink->sample_spec);
+ xsleep_interval = pa_smoother_translate(u->smoother, xtime0, ysleep_interval);
+ pa_rtpoll_set_timer_absolute(u->rtpoll, xtime0 + PA_MIN(xsleep_interval, ysleep_interval));
} else
pa_rtpoll_set_timer_disabled(u->rtpoll);
@@ -798,7 +811,7 @@ static void sig_callback(pa_mainloop_api *api, pa_signal_event*e, int sig, void
pa_log_debug("caught signal");
if (u->sink) {
- pa_sink_get_volume(u->sink, TRUE, FALSE);
+ pa_sink_get_volume(u->sink, TRUE);
pa_sink_get_mute(u->sink, TRUE);
}
@@ -813,7 +826,7 @@ int pa__init(pa_module *m) {
pa_channel_map map;
pa_modargs *ma = NULL;
uint32_t buffer_length_msec;
- int fd;
+ int fd = -1;
pa_sink_new_data sink_new_data;
pa_source_new_data source_new_data;
char const *name;
@@ -839,6 +852,9 @@ int pa__init(pa_module *m) {
u = pa_xnew0(struct userdata, 1);
+ if (!(u->smoother = pa_smoother_new(PA_USEC_PER_SEC, PA_USEC_PER_SEC * 2, TRUE, TRUE, 10, pa_rtclock_now(), TRUE)))
+ goto fail;
+
/*
* For a process (or several processes) to use the same audio device for both
* record and playback at the same time, the device's mixer must be enabled.
@@ -862,7 +878,13 @@ int pa__init(pa_module *m) {
}
u->buffer_size = pa_usec_to_bytes(1000 * buffer_length_msec, &ss);
if (u->buffer_size < 2 * u->minimum_request) {
- pa_log("supplied buffer size argument is too small");
+ pa_log("buffer_length argument cannot be smaller than %u",
+ (unsigned)(pa_bytes_to_usec(2 * u->minimum_request, &ss) / 1000));
+ goto fail;
+ }
+ if (u->buffer_size > MAX_BUFFER_SIZE) {
+ pa_log("buffer_length argument cannot be greater than %u",
+ (unsigned)(pa_bytes_to_usec(MAX_BUFFER_SIZE, &ss) / 1000));
goto fail;
}
@@ -925,6 +947,7 @@ int pa__init(pa_module *m) {
pa_source_set_asyncmsgq(u->source, u->thread_mq.inq);
pa_source_set_rtpoll(u->source, u->rtpoll);
+ pa_source_set_fixed_latency(u->source, pa_bytes_to_usec(u->buffer_size, &u->source->sample_spec));
u->source->get_volume = source_get_volume;
u->source->set_volume = source_set_volume;
@@ -967,15 +990,15 @@ int pa__init(pa_module *m) {
pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
pa_sink_set_rtpoll(u->sink, u->rtpoll);
+ pa_sink_set_fixed_latency(u->sink, pa_bytes_to_usec(u->buffer_size, &u->sink->sample_spec));
+ pa_sink_set_max_request(u->sink, u->buffer_size);
+ pa_sink_set_max_rewind(u->sink, u->buffer_size);
u->sink->get_volume = sink_get_volume;
u->sink->set_volume = sink_set_volume;
u->sink->get_mute = sink_get_mute;
u->sink->set_mute = sink_set_mute;
u->sink->refresh_volume = u->sink->refresh_muted = TRUE;
-
- pa_sink_set_max_request(u->sink, u->buffer_size);
- pa_sink_set_max_rewind(u->sink, u->buffer_size);
} else
u->sink = NULL;
@@ -987,7 +1010,7 @@ int pa__init(pa_module *m) {
else
pa_log_warn("Could not register SIGPOLL handler");
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("solaris", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
@@ -1076,6 +1099,9 @@ void pa__done(pa_module *m) {
if (u->fd >= 0)
close(u->fd);
+ if (u->smoother)
+ pa_smoother_free(u->smoother);
+
pa_xfree(u->device_name);
pa_xfree(u);
diff --git a/src/modules/module-stream-restore.c b/src/modules/module-stream-restore.c
index 2de98f4e..19c09bb6 100644
--- a/src/modules/module-stream-restore.c
+++ b/src/modules/module-stream-restore.c
@@ -2,6 +2,7 @@
This file is part of PulseAudio.
Copyright 2008 Lennart Poettering
+ Copyright 2009 Tanu Kaskinen
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
@@ -29,12 +30,12 @@
#include <sys/types.h>
#include <stdio.h>
#include <stdlib.h>
-#include <ctype.h>
+#include <pulse/gccmacro.h>
#include <pulse/xmalloc.h>
#include <pulse/volume.h>
#include <pulse/timeval.h>
-#include <pulse/util.h>
+#include <pulse/rtclock.h>
#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
@@ -49,6 +50,12 @@
#include <pulsecore/pstream.h>
#include <pulsecore/pstream-util.h>
#include <pulsecore/database.h>
+#include <pulsecore/tagstruct.h>
+
+#ifdef HAVE_DBUS
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/protocol-dbus.h>
+#endif
#include "module-stream-restore-symdef.h"
@@ -59,15 +66,19 @@ PA_MODULE_LOAD_ONCE(TRUE);
PA_MODULE_USAGE(
"restore_device=<Save/restore sinks/sources?> "
"restore_volume=<Save/restore volumes?> "
- "restore_muted=<Save/restore muted states?>");
+ "restore_muted=<Save/restore muted states?> "
+ "on_hotplug=<When new device becomes available, recheck streams?> "
+ "on_rescue=<When device becomes unavailable, recheck streams?>");
-#define SAVE_INTERVAL 10
+#define SAVE_INTERVAL (10 * PA_USEC_PER_SEC)
#define IDENTIFICATION_PROPERTY "module-stream-restore.id"
static const char* const valid_modargs[] = {
"restore_device",
"restore_volume",
"restore_muted",
+ "on_hotplug",
+ "on_rescue",
NULL
};
@@ -79,6 +90,10 @@ struct userdata {
*sink_input_new_hook_slot,
*sink_input_fixate_hook_slot,
*source_output_new_hook_slot,
+ *sink_put_hook_slot,
+ *source_put_hook_slot,
+ *sink_unlink_hook_slot,
+ *source_unlink_hook_slot,
*connection_unlink_hook_slot;
pa_time_event *save_time_event;
pa_database* database;
@@ -86,21 +101,30 @@ struct userdata {
pa_bool_t restore_device:1;
pa_bool_t restore_volume:1;
pa_bool_t restore_muted:1;
+ pa_bool_t on_hotplug:1;
+ pa_bool_t on_rescue:1;
pa_native_protocol *protocol;
pa_idxset *subscribed;
+
+#ifdef HAVE_DBUS
+ pa_dbus_protocol *dbus_protocol;
+ pa_hashmap *dbus_entries;
+ uint32_t next_index; /* For generating object paths for entries. */
+#endif
};
-#define ENTRY_VERSION 2
+#define ENTRY_VERSION 1
struct entry {
uint8_t version;
- pa_bool_t muted_valid:1, volume_valid:1, device_valid:1;
- pa_bool_t muted:1;
+ pa_bool_t muted_valid, volume_valid, device_valid, card_valid;
+ pa_bool_t muted;
pa_channel_map channel_map;
pa_cvolume volume;
- char device[PA_NAME_MAX];
-} PA_GCC_PACKED;
+ char* device;
+ char* card;
+};
enum {
SUBCOMMAND_TEST,
@@ -111,12 +135,823 @@ enum {
SUBCOMMAND_EVENT
};
-static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *tv, void *userdata) {
+
+static struct entry* entry_new(void);
+static void entry_free(struct entry *e);
+static struct entry *entry_read(struct userdata *u, const char *name);
+static pa_bool_t entry_write(struct userdata *u, const char *name, const struct entry *e, pa_bool_t replace);
+static struct entry* entry_copy(const struct entry *e);
+static void entry_apply(struct userdata *u, const char *name, struct entry *e);
+static void trigger_save(struct userdata *u);
+
+#ifdef HAVE_DBUS
+
+#define OBJECT_PATH "/org/pulseaudio/stream_restore1"
+#define ENTRY_OBJECT_NAME "entry"
+#define INTERFACE_STREAM_RESTORE "org.PulseAudio.Ext.StreamRestore1"
+#define INTERFACE_ENTRY INTERFACE_STREAM_RESTORE ".RestoreEntry"
+
+#define DBUS_INTERFACE_REVISION 0
+
+struct dbus_entry {
+ struct userdata *userdata;
+
+ char *entry_name;
+ uint32_t index;
+ char *object_path;
+};
+
+static void handle_get_interface_revision(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_entries(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_add_entry(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_get_entry_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_entry_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_entry_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_entry_get_device(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_entry_set_device(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_entry_get_volume(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_entry_set_volume(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+static void handle_entry_get_mute(DBusConnection *conn, DBusMessage *msg, void *userdata);
+static void handle_entry_set_mute(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+
+static void handle_entry_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+static void handle_entry_remove(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+enum property_handler_index {
+ PROPERTY_HANDLER_INTERFACE_REVISION,
+ PROPERTY_HANDLER_ENTRIES,
+ PROPERTY_HANDLER_MAX
+};
+
+enum entry_property_handler_index {
+ ENTRY_PROPERTY_HANDLER_INDEX,
+ ENTRY_PROPERTY_HANDLER_NAME,
+ ENTRY_PROPERTY_HANDLER_DEVICE,
+ ENTRY_PROPERTY_HANDLER_VOLUME,
+ ENTRY_PROPERTY_HANDLER_MUTE,
+ ENTRY_PROPERTY_HANDLER_MAX
+};
+
+static pa_dbus_property_handler property_handlers[PROPERTY_HANDLER_MAX] = {
+ [PROPERTY_HANDLER_INTERFACE_REVISION] = { .property_name = "InterfaceRevision", .type = "u", .get_cb = handle_get_interface_revision, .set_cb = NULL },
+ [PROPERTY_HANDLER_ENTRIES] = { .property_name = "Entries", .type = "ao", .get_cb = handle_get_entries, .set_cb = NULL }
+};
+
+static pa_dbus_property_handler entry_property_handlers[ENTRY_PROPERTY_HANDLER_MAX] = {
+ [ENTRY_PROPERTY_HANDLER_INDEX] = { .property_name = "Index", .type = "u", .get_cb = handle_entry_get_index, .set_cb = NULL },
+ [ENTRY_PROPERTY_HANDLER_NAME] = { .property_name = "Name", .type = "s", .get_cb = handle_entry_get_name, .set_cb = NULL },
+ [ENTRY_PROPERTY_HANDLER_DEVICE] = { .property_name = "Device", .type = "s", .get_cb = handle_entry_get_device, .set_cb = handle_entry_set_device },
+ [ENTRY_PROPERTY_HANDLER_VOLUME] = { .property_name = "Volume", .type = "a(uu)", .get_cb = handle_entry_get_volume, .set_cb = handle_entry_set_volume },
+ [ENTRY_PROPERTY_HANDLER_MUTE] = { .property_name = "Mute", .type = "b", .get_cb = handle_entry_get_mute, .set_cb = handle_entry_set_mute }
+};
+
+enum method_handler_index {
+ METHOD_HANDLER_ADD_ENTRY,
+ METHOD_HANDLER_GET_ENTRY_BY_NAME,
+ METHOD_HANDLER_MAX
+};
+
+enum entry_method_handler_index {
+ ENTRY_METHOD_HANDLER_REMOVE,
+ ENTRY_METHOD_HANDLER_MAX
+};
+
+static pa_dbus_arg_info add_entry_args[] = { { "name", "s", "in" },
+ { "device", "s", "in" },
+ { "volume", "a(uu)", "in" },
+ { "mute", "b", "in" },
+ { "entry", "o", "out" } };
+static pa_dbus_arg_info get_entry_by_name_args[] = { { "name", "s", "in" }, { "entry", "o", "out" } };
+
+static pa_dbus_method_handler method_handlers[METHOD_HANDLER_MAX] = {
+ [METHOD_HANDLER_ADD_ENTRY] = {
+ .method_name = "AddEntry",
+ .arguments = add_entry_args,
+ .n_arguments = sizeof(add_entry_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_add_entry },
+ [METHOD_HANDLER_GET_ENTRY_BY_NAME] = {
+ .method_name = "GetEntryByName",
+ .arguments = get_entry_by_name_args,
+ .n_arguments = sizeof(get_entry_by_name_args) / sizeof(pa_dbus_arg_info),
+ .receive_cb = handle_get_entry_by_name }
+};
+
+static pa_dbus_method_handler entry_method_handlers[ENTRY_METHOD_HANDLER_MAX] = {
+ [ENTRY_METHOD_HANDLER_REMOVE] = {
+ .method_name = "Remove",
+ .arguments = NULL,
+ .n_arguments = 0,
+ .receive_cb = handle_entry_remove }
+};
+
+enum signal_index {
+ SIGNAL_NEW_ENTRY,
+ SIGNAL_ENTRY_REMOVED,
+ SIGNAL_MAX
+};
+
+enum entry_signal_index {
+ ENTRY_SIGNAL_DEVICE_UPDATED,
+ ENTRY_SIGNAL_VOLUME_UPDATED,
+ ENTRY_SIGNAL_MUTE_UPDATED,
+ ENTRY_SIGNAL_MAX
+};
+
+static pa_dbus_arg_info new_entry_args[] = { { "entry", "o", NULL } };
+static pa_dbus_arg_info entry_removed_args[] = { { "entry", "o", NULL } };
+
+static pa_dbus_arg_info entry_device_updated_args[] = { { "device", "s", NULL } };
+static pa_dbus_arg_info entry_volume_updated_args[] = { { "volume", "a(uu)", NULL } };
+static pa_dbus_arg_info entry_mute_updated_args[] = { { "muted", "b", NULL } };
+
+static pa_dbus_signal_info signals[SIGNAL_MAX] = {
+ [SIGNAL_NEW_ENTRY] = { .name = "NewEntry", .arguments = new_entry_args, .n_arguments = 1 },
+ [SIGNAL_ENTRY_REMOVED] = { .name = "EntryRemoved", .arguments = entry_removed_args, .n_arguments = 1 }
+};
+
+static pa_dbus_signal_info entry_signals[ENTRY_SIGNAL_MAX] = {
+ [ENTRY_SIGNAL_DEVICE_UPDATED] = { .name = "DeviceUpdated", .arguments = entry_device_updated_args, .n_arguments = 1 },
+ [ENTRY_SIGNAL_VOLUME_UPDATED] = { .name = "VolumeUpdated", .arguments = entry_volume_updated_args, .n_arguments = 1 },
+ [ENTRY_SIGNAL_MUTE_UPDATED] = { .name = "MuteUpdated", .arguments = entry_mute_updated_args, .n_arguments = 1 }
+};
+
+static pa_dbus_interface_info stream_restore_interface_info = {
+ .name = INTERFACE_STREAM_RESTORE,
+ .method_handlers = method_handlers,
+ .n_method_handlers = METHOD_HANDLER_MAX,
+ .property_handlers = property_handlers,
+ .n_property_handlers = PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_get_all,
+ .signals = signals,
+ .n_signals = SIGNAL_MAX
+};
+
+static pa_dbus_interface_info entry_interface_info = {
+ .name = INTERFACE_ENTRY,
+ .method_handlers = entry_method_handlers,
+ .n_method_handlers = ENTRY_METHOD_HANDLER_MAX,
+ .property_handlers = entry_property_handlers,
+ .n_property_handlers = ENTRY_PROPERTY_HANDLER_MAX,
+ .get_all_properties_cb = handle_entry_get_all,
+ .signals = entry_signals,
+ .n_signals = ENTRY_SIGNAL_MAX
+};
+
+static struct dbus_entry *dbus_entry_new(struct userdata *u, const char *entry_name) {
+ struct dbus_entry *de;
+
+ pa_assert(u);
+ pa_assert(entry_name);
+ pa_assert(*entry_name);
+
+ de = pa_xnew(struct dbus_entry, 1);
+ de->userdata = u;
+ de->entry_name = pa_xstrdup(entry_name);
+ de->index = u->next_index++;
+ de->object_path = pa_sprintf_malloc("%s/%s%u", OBJECT_PATH, ENTRY_OBJECT_NAME, de->index);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(u->dbus_protocol, de->object_path, &entry_interface_info, de) >= 0);
+
+ return de;
+}
+
+static void dbus_entry_free(struct dbus_entry *de) {
+ pa_assert(de);
+
+ pa_assert_se(pa_dbus_protocol_remove_interface(de->userdata->dbus_protocol, de->object_path, entry_interface_info.name) >= 0);
+
+ pa_xfree(de->entry_name);
+ pa_xfree(de->object_path);
+}
+
+/* Reads an array [(UInt32, UInt32)] from the iterator. The struct items are
+ * are a channel position and a volume value, respectively. The result is
+ * stored in the map and vol arguments. The iterator must point to a "a(uu)"
+ * element. If the data is invalid, an error reply is sent and a negative
+ * number is returned. In case of a failure we make no guarantees about the
+ * state of map and vol. In case of an empty array the channels field of both
+ * map and vol are set to 0. This function calls dbus_message_iter_next(iter)
+ * before returning. */
+static int get_volume_arg(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, pa_channel_map *map, pa_cvolume *vol) {
+ DBusMessageIter array_iter;
+ DBusMessageIter struct_iter;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(pa_streq(dbus_message_iter_get_signature(iter), "a(uu)"));
+ pa_assert(map);
+ pa_assert(vol);
+
+ pa_channel_map_init(map);
+ pa_cvolume_init(vol);
+
+ map->channels = 0;
+ vol->channels = 0;
+
+ dbus_message_iter_recurse(iter, &array_iter);
+
+ while (dbus_message_iter_get_arg_type(&array_iter) != DBUS_TYPE_INVALID) {
+ dbus_uint32_t chan_pos;
+ dbus_uint32_t chan_vol;
+
+ dbus_message_iter_recurse(&array_iter, &struct_iter);
+
+ dbus_message_iter_get_basic(&struct_iter, &chan_pos);
+
+ if (chan_pos >= PA_CHANNEL_POSITION_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid channel position: %u", chan_pos);
+ return -1;
+ }
+
+ pa_assert_se(dbus_message_iter_next(&struct_iter));
+ dbus_message_iter_get_basic(&struct_iter, &chan_vol);
+
+ if (!PA_VOLUME_IS_VALID(chan_vol)) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Invalid volume: %u", chan_vol);
+ return -1;
+ }
+
+ if (map->channels < PA_CHANNELS_MAX) {
+ map->map[map->channels] = chan_pos;
+ vol->values[map->channels] = chan_vol;
+ }
+ ++map->channels;
+ ++vol->channels;
+
+ dbus_message_iter_next(&array_iter);
+ }
+
+ if (map->channels > PA_CHANNELS_MAX) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "Too many channels: %u. The maximum is %u.", map->channels, PA_CHANNELS_MAX);
+ return -1;
+ }
+
+ dbus_message_iter_next(iter);
+
+ return 0;
+}
+
+static void append_volume(DBusMessageIter *iter, struct entry *e) {
+ DBusMessageIter array_iter;
+ DBusMessageIter struct_iter;
+ unsigned i;
+
+ pa_assert(iter);
+ pa_assert(e);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_ARRAY, "(uu)", &array_iter));
+
+ if (!e->volume_valid) {
+ pa_assert_se(dbus_message_iter_close_container(iter, &array_iter));
+ return;
+ }
+
+ for (i = 0; i < e->channel_map.channels; ++i) {
+ pa_assert_se(dbus_message_iter_open_container(&array_iter, DBUS_TYPE_STRUCT, NULL, &struct_iter));
+
+ pa_assert_se(dbus_message_iter_append_basic(&struct_iter, DBUS_TYPE_UINT32, &e->channel_map.map[i]));
+ pa_assert_se(dbus_message_iter_append_basic(&struct_iter, DBUS_TYPE_UINT32, &e->volume.values[i]));
+
+ pa_assert_se(dbus_message_iter_close_container(&array_iter, &struct_iter));
+ }
+
+ pa_assert_se(dbus_message_iter_close_container(iter, &array_iter));
+}
+
+static void append_volume_variant(DBusMessageIter *iter, struct entry *e) {
+ DBusMessageIter variant_iter;
+
+ pa_assert(iter);
+ pa_assert(e);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_VARIANT, "a(uu)", &variant_iter));
+
+ append_volume(&variant_iter, e);
+
+ pa_assert_se(dbus_message_iter_close_container(iter, &variant_iter));
+}
+
+static void send_new_entry_signal(struct dbus_entry *entry) {
+ DBusMessage *signal_msg;
+
+ pa_assert(entry);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(OBJECT_PATH, INTERFACE_STREAM_RESTORE, signals[SIGNAL_NEW_ENTRY].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &entry->object_path, DBUS_TYPE_INVALID));
+ pa_dbus_protocol_send_signal(entry->userdata->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+}
+
+static void send_entry_removed_signal(struct dbus_entry *entry) {
+ DBusMessage *signal_msg;
+
+ pa_assert(entry);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(OBJECT_PATH, INTERFACE_STREAM_RESTORE, signals[SIGNAL_ENTRY_REMOVED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_OBJECT_PATH, &entry->object_path, DBUS_TYPE_INVALID));
+ pa_dbus_protocol_send_signal(entry->userdata->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+}
+
+static void send_device_updated_signal(struct dbus_entry *de, struct entry *e) {
+ DBusMessage *signal_msg;
+ const char *device;
+
+ pa_assert(de);
+ pa_assert(e);
+
+ device = e->device_valid ? e->device : "";
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(de->object_path, INTERFACE_ENTRY, entry_signals[ENTRY_SIGNAL_DEVICE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_STRING, &device, DBUS_TYPE_INVALID));
+ pa_dbus_protocol_send_signal(de->userdata->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+}
+
+static void send_volume_updated_signal(struct dbus_entry *de, struct entry *e) {
+ DBusMessage *signal_msg;
+ DBusMessageIter msg_iter;
+
+ pa_assert(de);
+ pa_assert(e);
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(de->object_path, INTERFACE_ENTRY, entry_signals[ENTRY_SIGNAL_VOLUME_UPDATED].name));
+ dbus_message_iter_init_append(signal_msg, &msg_iter);
+ append_volume(&msg_iter, e);
+ pa_dbus_protocol_send_signal(de->userdata->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+}
+
+static void send_mute_updated_signal(struct dbus_entry *de, struct entry *e) {
+ DBusMessage *signal_msg;
+ dbus_bool_t muted;
+
+ pa_assert(de);
+ pa_assert(e);
+
+ pa_assert(e->muted_valid);
+
+ muted = e->muted;
+
+ pa_assert_se(signal_msg = dbus_message_new_signal(de->object_path, INTERFACE_ENTRY, entry_signals[ENTRY_SIGNAL_MUTE_UPDATED].name));
+ pa_assert_se(dbus_message_append_args(signal_msg, DBUS_TYPE_BOOLEAN, &muted, DBUS_TYPE_INVALID));
+ pa_dbus_protocol_send_signal(de->userdata->dbus_protocol, signal_msg);
+ dbus_message_unref(signal_msg);
+}
+
+static void handle_get_interface_revision(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ dbus_uint32_t interface_revision = DBUS_INTERFACE_REVISION;
+
+ pa_assert(conn);
+ pa_assert(msg);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &interface_revision);
+}
+
+/* The caller frees the array, but not the strings. */
+static const char **get_entries(struct userdata *u, unsigned *n) {
+ const char **entries;
+ unsigned i = 0;
+ void *state = NULL;
+ struct dbus_entry *de;
+
+ pa_assert(u);
+ pa_assert(n);
+
+ *n = pa_hashmap_size(u->dbus_entries);
+
+ if (*n == 0)
+ return NULL;
+
+ entries = pa_xnew(const char *, *n);
+
+ PA_HASHMAP_FOREACH(de, u->dbus_entries, state)
+ entries[i++] = de->object_path;
+
+ return entries;
+}
+
+static void handle_get_entries(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct userdata *u = userdata;
+ const char **entries;
+ unsigned n;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+
+ entries = get_entries(u, &n);
+
+ pa_dbus_send_basic_array_variant_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, entries, n);
+
+ pa_xfree(entries);
+}
+
+static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct userdata *u = userdata;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ dbus_uint32_t interface_revision;
+ const char **entries;
+ unsigned n_entries;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+
+ interface_revision = DBUS_INTERFACE_REVISION;
+ entries = get_entries(u, &n_entries);
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_INTERFACE_REVISION].property_name, DBUS_TYPE_UINT32, &interface_revision);
+ pa_dbus_append_basic_array_variant_dict_entry(&dict_iter, property_handlers[PROPERTY_HANDLER_ENTRIES].property_name, DBUS_TYPE_OBJECT_PATH, entries, n_entries);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+
+ pa_xfree(entries);
+}
+
+static void handle_add_entry(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct userdata *u = userdata;
+ DBusMessageIter msg_iter;
+ const char *name = NULL;
+ const char *device = NULL;
+ pa_channel_map map;
+ pa_cvolume vol;
+ dbus_bool_t muted = FALSE;
+ dbus_bool_t apply_immediately = FALSE;
+ struct dbus_entry *dbus_entry = NULL;
+ struct entry *e = NULL;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+
+ pa_assert_se(dbus_message_iter_init(msg, &msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &name);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &device);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ if (get_volume_arg(conn, msg, &msg_iter, &map, &vol) < 0)
+ return;
+
+ dbus_message_iter_get_basic(&msg_iter, &muted);
+
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &apply_immediately);
+
+ if (!*name) {
+ pa_dbus_send_error(conn, msg, DBUS_ERROR_INVALID_ARGS, "An empty string was given as the entry name.");
+ return;
+ }
+
+ if ((dbus_entry = pa_hashmap_get(u->dbus_entries, name))) {
+ pa_bool_t mute_updated = FALSE;
+ pa_bool_t volume_updated = FALSE;
+ pa_bool_t device_updated = FALSE;
+
+ pa_assert_se(e = entry_read(u, name));
+ mute_updated = e->muted != muted;
+ e->muted = muted;
+ e->muted_valid = TRUE;
+
+ volume_updated = (e->volume_valid != !!map.channels) || !pa_cvolume_equal(&e->volume, &vol);
+ e->volume = vol;
+ e->channel_map = map;
+ e->volume_valid = !!map.channels;
+
+ device_updated = (e->device_valid != !!device[0]) || !pa_streq(e->device, device);
+ pa_xfree(e->device);
+ e->device = pa_xstrdup(device);
+ e->device_valid = !!device[0];
+
+ if (mute_updated)
+ send_mute_updated_signal(dbus_entry, e);
+ if (volume_updated)
+ send_volume_updated_signal(dbus_entry, e);
+ if (device_updated)
+ send_device_updated_signal(dbus_entry, e);
+
+ } else {
+ dbus_entry = dbus_entry_new(u, name);
+ pa_assert_se(pa_hashmap_put(u->dbus_entries, dbus_entry->entry_name, dbus_entry) == 0);
+
+ e = entry_new();
+ e->muted_valid = TRUE;
+ e->volume_valid = !!map.channels;
+ e->device_valid = !!device[0];
+ e->muted = muted;
+ e->volume = vol;
+ e->channel_map = map;
+ e->device = pa_xstrdup(device);
+
+ send_new_entry_signal(dbus_entry);
+ }
+
+ pa_assert_se(entry_write(u, name, e, TRUE));
+
+ if (apply_immediately)
+ entry_apply(u, name, e);
+
+ trigger_save(u);
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ entry_free(e);
+}
+
+static void handle_get_entry_by_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct userdata *u = userdata;
+ const char *name;
+ struct dbus_entry *de;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(u);
+
+ pa_assert_se(dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &name, DBUS_TYPE_INVALID));
+
+ if (!(de = pa_hashmap_get(u->dbus_entries, name))) {
+ pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NOT_FOUND, "No such stream restore entry.");
+ return;
+ }
+
+ pa_dbus_send_basic_value_reply(conn, msg, DBUS_TYPE_OBJECT_PATH, &de->object_path);
+}
+
+static void handle_entry_get_index(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct dbus_entry *de = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(de);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, &de->index);
+}
+
+static void handle_entry_get_name(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct dbus_entry *de = userdata;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(de);
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &de->entry_name);
+}
+
+static void handle_entry_get_device(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct dbus_entry *de = userdata;
+ struct entry *e;
+ const char *device;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(de);
+
+ pa_assert_se(e = entry_read(de->userdata, de->entry_name));
+
+ device = e->device_valid ? e->device : "";
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_STRING, &device);
+
+ entry_free(e);
+}
+
+static void handle_entry_set_device(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ struct dbus_entry *de = userdata;
+ const char *device;
+ struct entry *e;
+ pa_bool_t updated;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(de);
+
+ dbus_message_iter_get_basic(iter, &device);
+
+ pa_assert_se(e = entry_read(de->userdata, de->entry_name));
+
+ updated = (e->device_valid != !!device[0]) || !pa_streq(e->device, device);
+
+ if (updated) {
+ pa_xfree(e->device);
+ e->device = pa_xstrdup(device);
+ e->device_valid = !!device[0];
+
+ pa_assert_se(entry_write(de->userdata, de->entry_name, e, TRUE));
+
+ entry_apply(de->userdata, de->entry_name, e);
+ send_device_updated_signal(de, e);
+ trigger_save(de->userdata);
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ entry_free(e);
+}
+
+static void handle_entry_get_volume(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct dbus_entry *de = userdata;
+ DBusMessage *reply;
+ DBusMessageIter msg_iter;
+ struct entry *e;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(de);
+
+ pa_assert_se(e = entry_read(de->userdata, de->entry_name));
+
+ pa_assert_se(reply = dbus_message_new_method_return(msg));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ append_volume_variant(&msg_iter, e);
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ entry_free(e);
+}
+
+static void handle_entry_set_volume(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ struct dbus_entry *de = userdata;
+ pa_channel_map map;
+ pa_cvolume vol;
+ struct entry *e = NULL;
+ pa_bool_t updated = FALSE;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(de);
+
+ if (get_volume_arg(conn, msg, iter, &map, &vol) < 0)
+ return;
+
+ pa_assert_se(e = entry_read(de->userdata, de->entry_name));
+
+ updated = (e->volume_valid != !!map.channels) || !pa_cvolume_equal(&e->volume, &vol);
+
+ if (updated) {
+ e->volume = vol;
+ e->channel_map = map;
+ e->volume_valid = !!map.channels;
+
+ pa_assert_se(entry_write(de->userdata, de->entry_name, e, TRUE));
+
+ entry_apply(de->userdata, de->entry_name, e);
+ send_volume_updated_signal(de, e);
+ trigger_save(de->userdata);
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ entry_free(e);
+}
+
+static void handle_entry_get_mute(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct dbus_entry *de = userdata;
+ struct entry *e;
+ dbus_bool_t mute;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(de);
+
+ pa_assert_se(e = entry_read(de->userdata, de->entry_name));
+
+ mute = e->muted_valid ? e->muted : FALSE;
+
+ pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_BOOLEAN, &mute);
+
+ entry_free(e);
+}
+
+static void handle_entry_set_mute(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata) {
+ struct dbus_entry *de = userdata;
+ dbus_bool_t mute;
+ struct entry *e;
+ pa_bool_t updated;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(de);
+
+ dbus_message_iter_get_basic(iter, &mute);
+
+ pa_assert_se(e = entry_read(de->userdata, de->entry_name));
+
+ updated = !e->muted_valid || e->muted != mute;
+
+ if (updated) {
+ e->muted = mute;
+ e->muted_valid = TRUE;
+
+ pa_assert_se(entry_write(de->userdata, de->entry_name, e, TRUE));
+
+ entry_apply(de->userdata, de->entry_name, e);
+ send_mute_updated_signal(de, e);
+ trigger_save(de->userdata);
+ }
+
+ pa_dbus_send_empty_reply(conn, msg);
+
+ entry_free(e);
+}
+
+static void handle_entry_get_all(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct dbus_entry *de = userdata;
+ struct entry *e;
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+ DBusMessageIter dict_entry_iter;
+ const char *device;
+ dbus_bool_t mute;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(de);
+
+ pa_assert_se(e = entry_read(de->userdata, de->entry_name));
+
+ device = e->device_valid ? e->device : "";
+ mute = e->muted_valid ? e->muted : FALSE;
+
+ pa_assert_se((reply = dbus_message_new_method_return(msg)));
+
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, entry_property_handlers[ENTRY_PROPERTY_HANDLER_INDEX].property_name, DBUS_TYPE_UINT32, &de->index);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, entry_property_handlers[ENTRY_PROPERTY_HANDLER_NAME].property_name, DBUS_TYPE_STRING, &de->entry_name);
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, entry_property_handlers[ENTRY_PROPERTY_HANDLER_DEVICE].property_name, DBUS_TYPE_STRING, &device);
+
+ pa_assert_se(dbus_message_iter_open_container(&dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter));
+
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &entry_property_handlers[ENTRY_PROPERTY_HANDLER_VOLUME].property_name));
+ append_volume_variant(&dict_entry_iter, e);
+
+ pa_assert_se(dbus_message_iter_close_container(&dict_iter, &dict_entry_iter));
+
+ pa_dbus_append_basic_variant_dict_entry(&dict_iter, entry_property_handlers[ENTRY_PROPERTY_HANDLER_MUTE].property_name, DBUS_TYPE_BOOLEAN, &mute);
+
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+
+ pa_assert_se(dbus_connection_send(conn, reply, NULL));
+
+ dbus_message_unref(reply);
+
+ entry_free(e);
+}
+
+static void handle_entry_remove(DBusConnection *conn, DBusMessage *msg, void *userdata) {
+ struct dbus_entry *de = userdata;
+ pa_datum key;
+
+ pa_assert(conn);
+ pa_assert(msg);
+ pa_assert(de);
+
+ key.data = de->entry_name;
+ key.size = strlen(de->entry_name);
+
+ pa_assert_se(pa_database_unset(de->userdata->database, &key) == 0);
+
+ send_entry_removed_signal(de);
+ trigger_save(de->userdata);
+
+ pa_assert_se(pa_hashmap_remove(de->userdata->dbus_entries, de->entry_name));
+ dbus_entry_free(de);
+
+ pa_dbus_send_empty_reply(conn, msg);
+}
+
+#endif /* HAVE_DBUS */
+
+static void save_time_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *t, void *userdata) {
struct userdata *u = userdata;
pa_assert(a);
pa_assert(e);
- pa_assert(tv);
pa_assert(u);
pa_assert(e == u->save_time_event);
@@ -152,11 +987,107 @@ static char *get_name(pa_proplist *p, const char *prefix) {
return t;
}
-static struct entry* read_entry(struct userdata *u, const char *name) {
+static struct entry* entry_new(void) {
+ struct entry *r = pa_xnew0(struct entry, 1);
+ r->version = ENTRY_VERSION;
+ return r;
+}
+
+static void entry_free(struct entry* e) {
+ pa_assert(e);
+
+ pa_xfree(e->device);
+ pa_xfree(e->card);
+ pa_xfree(e);
+}
+
+static pa_bool_t entry_write(struct userdata *u, const char *name, const struct entry *e, pa_bool_t replace) {
+ pa_tagstruct *t;
pa_datum key, data;
+ pa_bool_t r;
+
+ pa_assert(u);
+ pa_assert(name);
+ pa_assert(e);
+
+ t = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu8(t, e->version);
+ pa_tagstruct_put_boolean(t, e->volume_valid);
+ pa_tagstruct_put_channel_map(t, &e->channel_map);
+ pa_tagstruct_put_cvolume(t, &e->volume);
+ pa_tagstruct_put_boolean(t, e->muted_valid);
+ pa_tagstruct_put_boolean(t, e->muted);
+ pa_tagstruct_put_boolean(t, e->device_valid);
+ pa_tagstruct_puts(t, e->device);
+ pa_tagstruct_put_boolean(t, e->card_valid);
+ pa_tagstruct_puts(t, e->card);
+
+ key.data = (char *) name;
+ key.size = strlen(name);
+
+ data.data = (void*)pa_tagstruct_data(t, &data.size);
+
+ r = (pa_database_set(u->database, &key, &data, replace) == 0);
+
+ pa_tagstruct_free(t);
+
+ return r;
+}
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+
+#define LEGACY_ENTRY_VERSION 3
+static struct entry* legacy_entry_read(struct userdata *u, pa_datum *data) {
+ struct legacy_entry {
+ uint8_t version;
+ pa_bool_t muted_valid:1, volume_valid:1, device_valid:1, card_valid:1;
+ pa_bool_t muted:1;
+ pa_channel_map channel_map;
+ pa_cvolume volume;
+ char device[PA_NAME_MAX];
+ char card[PA_NAME_MAX];
+ } PA_GCC_PACKED;
+ struct legacy_entry *le;
struct entry *e;
pa_assert(u);
+ pa_assert(data);
+
+ if (data->size != sizeof(struct legacy_entry)) {
+ pa_log_debug("Size does not match.");
+ return NULL;
+ }
+
+ le = (struct legacy_entry*)data->data;
+
+ if (le->version != LEGACY_ENTRY_VERSION) {
+ pa_log_debug("Version mismatch.");
+ return NULL;
+ }
+
+ if (!memchr(le->device, 0, sizeof(le->device))) {
+ pa_log_warn("Device has missing NUL byte.");
+ return NULL;
+ }
+
+ if (!memchr(le->card, 0, sizeof(le->card))) {
+ pa_log_warn("Card has missing NUL byte.");
+ return NULL;
+ }
+
+ e = entry_new();
+ e->card = pa_xstrdup(le->card);
+ return e;
+}
+#endif
+
+static struct entry *entry_read(struct userdata *u, const char *name) {
+ pa_datum key, data;
+ struct entry *e = NULL;
+ pa_tagstruct *t = NULL;
+ const char *device, *card;
+
+ pa_assert(u);
pa_assert(name);
key.data = (char*) name;
@@ -167,27 +1098,37 @@ static struct entry* read_entry(struct userdata *u, const char *name) {
if (!pa_database_get(u->database, &key, &data))
goto fail;
- if (data.size != sizeof(struct entry)) {
- /* This is probably just a database upgrade, hence let's not
- * consider this more than a debug message */
- pa_log_debug("Database contains entry for stream %s of wrong size %lu != %lu. Probably due to uprade, ignoring.", name, (unsigned long) data.size, (unsigned long) sizeof(struct entry));
+ t = pa_tagstruct_new(data.data, data.size);
+ e = entry_new();
+
+ if (pa_tagstruct_getu8(t, &e->version) < 0 ||
+ e->version > ENTRY_VERSION ||
+ pa_tagstruct_get_boolean(t, &e->volume_valid) < 0 ||
+ pa_tagstruct_get_channel_map(t, &e->channel_map) < 0 ||
+ pa_tagstruct_get_cvolume(t, &e->volume) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->muted_valid) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->muted) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->device_valid) < 0 ||
+ pa_tagstruct_gets(t, &device) < 0 ||
+ pa_tagstruct_get_boolean(t, &e->card_valid) < 0 ||
+ pa_tagstruct_gets(t, &card) < 0) {
+
goto fail;
}
- e = (struct entry*) data.data;
+ e->device = pa_xstrdup(device);
+ e->card = pa_xstrdup(card);
- if (e->version != ENTRY_VERSION) {
- pa_log_debug("Version of database entry for stream %s doesn't match our version. Probably due to upgrade, ignoring.", name);
+ if (!pa_tagstruct_eof(t))
goto fail;
- }
- if (!memchr(e->device, 0, sizeof(e->device))) {
- pa_log_warn("Database contains entry for stream %s with missing NUL byte in device name", name);
+ if (e->device_valid && !pa_namereg_is_valid_name(e->device)) {
+ pa_log_warn("Invalid device name stored in database for stream %s", name);
goto fail;
}
- if (e->device_valid && !pa_namereg_is_valid_name(e->device)) {
- pa_log_warn("Invalid device name stored in database for stream %s", name);
+ if (e->card_valid && !pa_namereg_is_valid_name(e->card)) {
+ pa_log_warn("Invalid card name stored in database for stream %s", name);
goto fail;
}
@@ -201,16 +1142,48 @@ static struct entry* read_entry(struct userdata *u, const char *name) {
goto fail;
}
+ pa_tagstruct_free(t);
+ pa_datum_free(&data);
+
return e;
fail:
+ pa_log_debug("Database contains invalid data for key: %s (probably pre-v1.0 data)", name);
+
+ if (e)
+ entry_free(e);
+ if (t)
+ pa_tagstruct_free(t);
+
+#ifdef ENABLE_LEGACY_DATABASE_ENTRY_FORMAT
+ pa_log_debug("Attempting to load legacy (pre-v1.0) data for key: %s", name);
+ if ((e = legacy_entry_read(u, &data))) {
+ pa_log_debug("Success. Saving new format for key: %s", name);
+ if (entry_write(u, name, e, TRUE))
+ trigger_save(u);
+ pa_datum_free(&data);
+ return e;
+ } else
+ pa_log_debug("Unable to load legacy (pre-v1.0) data for key: %s. Ignoring.", name);
+#endif
+
pa_datum_free(&data);
return NULL;
}
+static struct entry* entry_copy(const struct entry *e) {
+ struct entry* r;
+
+ pa_assert(e);
+ r = entry_new();
+ *r = *e;
+ r->device = pa_xstrdup(e->device);
+ r->card = pa_xstrdup(e->card);
+ return r;
+}
+
static void trigger_save(struct userdata *u) {
- struct timeval tv;
pa_native_connection *c;
uint32_t idx;
@@ -230,9 +1203,7 @@ static void trigger_save(struct userdata *u) {
if (u->save_time_event)
return;
- pa_gettimeofday(&tv);
- tv.tv_sec += SAVE_INTERVAL;
- u->save_time_event = u->core->mainloop->time_new(u->core->mainloop, &tv, save_time_callback, u);
+ u->save_time_event = pa_core_rttime_new(u->core, pa_rtclock_now() + SAVE_INTERVAL, save_time_callback, u);
}
static pa_bool_t entries_equal(const struct entry *a, const struct entry *b) {
@@ -242,7 +1213,11 @@ static pa_bool_t entries_equal(const struct entry *a, const struct entry *b) {
pa_assert(b);
if (a->device_valid != b->device_valid ||
- (a->device_valid && strncmp(a->device, b->device, sizeof(a->device))))
+ (a->device_valid && !pa_streq(a->device, b->device)))
+ return FALSE;
+
+ if (a->card_valid != b->card_valid ||
+ (a->card_valid && !pa_streq(a->card, b->card)))
return FALSE;
if (a->muted_valid != b->muted_valid ||
@@ -259,9 +1234,19 @@ static pa_bool_t entries_equal(const struct entry *a, const struct entry *b) {
static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint32_t idx, void *userdata) {
struct userdata *u = userdata;
- struct entry entry, *old;
- char *name;
- pa_datum key, data;
+ struct entry *entry, *old = NULL;
+ char *name = NULL;
+
+ /* These are only used when D-Bus is enabled, but in order to reduce ifdef
+ * clutter these are defined here unconditionally. */
+ pa_bool_t created_new_entry = TRUE;
+ pa_bool_t device_updated = FALSE;
+ pa_bool_t volume_updated = FALSE;
+ pa_bool_t mute_updated = FALSE;
+
+#ifdef HAVE_DBUS
+ struct dbus_entry *de = NULL;
+#endif
pa_assert(c);
pa_assert(u);
@@ -272,9 +1257,6 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
t != (PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE))
return;
- pa_zero(entry);
- entry.version = ENTRY_VERSION;
-
if ((t & PA_SUBSCRIPTION_EVENT_FACILITY_MASK) == PA_SUBSCRIPTION_EVENT_SINK_INPUT) {
pa_sink_input *sink_input;
@@ -284,23 +1266,43 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
if (!(name = get_name(sink_input->proplist, "sink-input")))
return;
- if ((old = read_entry(u, name)))
- entry = *old;
+ if ((old = entry_read(u, name))) {
+ entry = entry_copy(old);
+ created_new_entry = FALSE;
+ } else
+ entry = entry_new();
+
+ if (sink_input->save_volume && pa_sink_input_is_volume_readable(sink_input)) {
+ pa_assert(sink_input->volume_writable);
- if (sink_input->save_volume) {
- entry.channel_map = sink_input->channel_map;
- pa_sink_input_get_volume(sink_input, &entry.volume, FALSE);
- entry.volume_valid = TRUE;
+ entry->channel_map = sink_input->channel_map;
+ pa_sink_input_get_volume(sink_input, &entry->volume, FALSE);
+ entry->volume_valid = TRUE;
+
+ volume_updated = !created_new_entry
+ && (!old->volume_valid
+ || !pa_channel_map_equal(&entry->channel_map, &old->channel_map)
+ || !pa_cvolume_equal(&entry->volume, &old->volume));
}
if (sink_input->save_muted) {
- entry.muted = pa_sink_input_get_mute(sink_input);
- entry.muted_valid = TRUE;
+ entry->muted = pa_sink_input_get_mute(sink_input);
+ entry->muted_valid = TRUE;
+
+ mute_updated = !created_new_entry && (!old->muted_valid || entry->muted != old->muted);
}
if (sink_input->save_sink) {
- pa_strlcpy(entry.device, sink_input->sink->name, sizeof(entry.device));
- entry.device_valid = TRUE;
+ pa_xfree(entry->device);
+ entry->device = pa_xstrdup(sink_input->sink->name);
+ entry->device_valid = TRUE;
+
+ device_updated = !created_new_entry && (!old->device_valid || !pa_streq(entry->device, old->device));
+ if (sink_input->sink->card) {
+ pa_xfree(entry->card);
+ entry->card = pa_xstrdup(sink_input->sink->card->name);
+ entry->card_valid = TRUE;
+ }
}
} else {
@@ -314,69 +1316,102 @@ static void subscribe_callback(pa_core *c, pa_subscription_event_type_t t, uint3
if (!(name = get_name(source_output->proplist, "source-output")))
return;
- if ((old = read_entry(u, name)))
- entry = *old;
+ if ((old = entry_read(u, name))) {
+ entry = entry_copy(old);
+ created_new_entry = FALSE;
+ } else
+ entry = entry_new();
if (source_output->save_source) {
- pa_strlcpy(entry.device, source_output->source->name, sizeof(entry.device));
- entry.device_valid = source_output->save_source;
+ pa_xfree(entry->device);
+ entry->device = pa_xstrdup(source_output->source->name);
+ entry->device_valid = TRUE;
+
+ device_updated = !created_new_entry && (!old->device_valid || !pa_streq(entry->device, old->device));
+
+ if (source_output->source->card) {
+ pa_xfree(entry->card);
+ entry->card = pa_xstrdup(source_output->source->card->name);
+ entry->card_valid = TRUE;
+ }
}
}
+ pa_assert(entry);
+
if (old) {
- if (entries_equal(old, &entry)) {
- pa_xfree(old);
+ if (entries_equal(old, entry)) {
+ entry_free(old);
+ entry_free(entry);
pa_xfree(name);
return;
}
- pa_xfree(old);
+ entry_free(old);
}
- key.data = name;
- key.size = strlen(name);
-
- data.data = &entry;
- data.size = sizeof(entry);
-
pa_log_info("Storing volume/mute/device for stream %s.", name);
- pa_database_set(u->database, &key, &data, TRUE);
+ if (entry_write(u, name, entry, TRUE))
+ trigger_save(u);
- pa_xfree(name);
+#ifdef HAVE_DBUS
+ if (created_new_entry) {
+ de = dbus_entry_new(u, name);
+ pa_assert_se(pa_hashmap_put(u->dbus_entries, de->entry_name, de) == 0);
+ send_new_entry_signal(de);
+ } else {
+ pa_assert_se(de = pa_hashmap_get(u->dbus_entries, name));
+
+ if (device_updated)
+ send_device_updated_signal(de, entry);
+ if (volume_updated)
+ send_volume_updated_signal(de, entry);
+ if (mute_updated)
+ send_mute_updated_signal(de, entry);
+ }
+#endif
- trigger_save(u);
+ entry_free(entry);
+ pa_xfree(name);
}
static pa_hook_result_t sink_input_new_hook_callback(pa_core *c, pa_sink_input_new_data *new_data, struct userdata *u) {
char *name;
struct entry *e;
+ pa_assert(c);
pa_assert(new_data);
-
- if (!u->restore_device)
- return PA_HOOK_OK;
+ pa_assert(u);
+ pa_assert(u->restore_device);
if (!(name = get_name(new_data->proplist, "sink-input")))
return PA_HOOK_OK;
- if ((e = read_entry(u, name))) {
- pa_sink *s;
+ if (new_data->sink)
+ pa_log_debug("Not restoring device for stream %s, because already set to '%s'.", name, new_data->sink->name);
+ else if ((e = entry_read(u, name))) {
+ pa_sink *s = NULL;
- if (e->device_valid) {
+ if (e->device_valid)
+ s = pa_namereg_get(c, e->device, PA_NAMEREG_SINK);
- if ((s = pa_namereg_get(c, e->device, PA_NAMEREG_SINK))) {
- if (!new_data->sink) {
- pa_log_info("Restoring device for stream %s.", name);
- new_data->sink = s;
- new_data->save_sink = TRUE;
- } else
- pa_log_info("Not restore device for stream %s, because already set.", name);
- }
+ if (!s && e->card_valid) {
+ pa_card *card;
+
+ if ((card = pa_namereg_get(c, e->card, PA_NAMEREG_CARD)))
+ s = pa_idxset_first(card->sinks, NULL);
}
- pa_xfree(e);
+ /* It might happen that a stream and a sink are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (s && PA_SINK_IS_LINKED(pa_sink_get_state(s)))
+ if (pa_sink_input_new_data_set_sink(new_data, s, TRUE))
+ pa_log_info("Restoring device for stream %s.", name);
+
+ entry_free(e);
}
pa_xfree(name);
@@ -388,30 +1423,33 @@ static pa_hook_result_t sink_input_fixate_hook_callback(pa_core *c, pa_sink_inpu
char *name;
struct entry *e;
+ pa_assert(c);
pa_assert(new_data);
-
- if (!u->restore_volume && !u->restore_muted)
- return PA_HOOK_OK;
+ pa_assert(u);
+ pa_assert(u->restore_volume || u->restore_muted);
if (!(name = get_name(new_data->proplist, "sink-input")))
return PA_HOOK_OK;
- if ((e = read_entry(u, name))) {
+ if ((e = entry_read(u, name))) {
if (u->restore_volume && e->volume_valid) {
-
- if (!new_data->volume_is_set) {
+ if (!new_data->volume_writable)
+ pa_log_debug("Not restoring volume for sink input %s, because its volume can't be changed.", name);
+ else if (new_data->volume_is_set)
+ pa_log_debug("Not restoring volume for sink input %s, because already set.", name);
+ else {
pa_cvolume v;
pa_log_info("Restoring volume for sink input %s.", name);
+
v = e->volume;
pa_cvolume_remap(&v, &e->channel_map, &new_data->channel_map);
pa_sink_input_new_data_set_volume(new_data, &v);
new_data->volume_is_absolute = FALSE;
- new_data->save_volume = FALSE;
- } else
- pa_log_debug("Not restoring volume for sink input %s, because already set.", name);
+ new_data->save_volume = TRUE;
+ }
}
if (u->restore_muted && e->muted_valid) {
@@ -424,7 +1462,7 @@ static pa_hook_result_t sink_input_fixate_hook_callback(pa_core *c, pa_sink_inpu
pa_log_debug("Not restoring mute state for sink input %s, because already set.", name);
}
- pa_xfree(e);
+ entry_free(e);
}
pa_xfree(name);
@@ -436,10 +1474,10 @@ static pa_hook_result_t source_output_new_hook_callback(pa_core *c, pa_source_ou
char *name;
struct entry *e;
+ pa_assert(c);
pa_assert(new_data);
-
- if (!u->restore_device)
- return PA_HOOK_OK;
+ pa_assert(u);
+ pa_assert(u->restore_device);
if (new_data->direct_on_input)
return PA_HOOK_OK;
@@ -447,21 +1485,30 @@ static pa_hook_result_t source_output_new_hook_callback(pa_core *c, pa_source_ou
if (!(name = get_name(new_data->proplist, "source-output")))
return PA_HOOK_OK;
- if ((e = read_entry(u, name))) {
- pa_source *s;
+ if (new_data->source)
+ pa_log_debug("Not restoring device for stream %s, because already set", name);
+ else if ((e = entry_read(u, name))) {
+ pa_source *s = NULL;
- if (e->device_valid) {
- if ((s = pa_namereg_get(c, e->device, PA_NAMEREG_SOURCE))) {
- if (!new_data->source) {
- pa_log_info("Restoring device for stream %s.", name);
- new_data->source = s;
- new_data->save_source = TRUE;
- } else
- pa_log_info("Not restoring device for stream %s, because already set", name);
- }
+ if (e->device_valid)
+ s = pa_namereg_get(c, e->device, PA_NAMEREG_SOURCE);
+
+ if (!s && e->card_valid) {
+ pa_card *card;
+
+ if ((card = pa_namereg_get(c, e->card, PA_NAMEREG_CARD)))
+ s = pa_idxset_first(card->sources, NULL);
+ }
+
+ /* It might happen that a stream and a sink are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (s && PA_SOURCE_IS_LINKED(pa_source_get_state(s))) {
+ pa_log_info("Restoring device for stream %s.", name);
+ pa_source_output_new_data_set_source(new_data, s, TRUE);
}
- pa_xfree(e);
+ entry_free(e);
}
pa_xfree(name);
@@ -469,9 +1516,192 @@ static pa_hook_result_t source_output_new_hook_callback(pa_core *c, pa_source_ou
return PA_HOOK_OK;
}
+static pa_hook_result_t sink_put_hook_callback(pa_core *c, pa_sink *sink, struct userdata *u) {
+ pa_sink_input *si;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(sink);
+ pa_assert(u);
+ pa_assert(u->on_hotplug && u->restore_device);
+
+ PA_IDXSET_FOREACH(si, c->sink_inputs, idx) {
+ char *name;
+ struct entry *e;
+
+ if (si->sink == sink)
+ continue;
+
+ if (si->save_sink)
+ continue;
+
+ /* Skip this if it is already in the process of being moved
+ * anyway */
+ if (!si->sink)
+ continue;
+
+ /* It might happen that a stream and a sink are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (!PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(si)))
+ continue;
+
+ if (!(name = get_name(si->proplist, "sink-input")))
+ continue;
+
+ if ((e = entry_read(u, name))) {
+ if (e->device_valid && pa_streq(e->device, sink->name))
+ pa_sink_input_move_to(si, sink, TRUE);
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_put_hook_callback(pa_core *c, pa_source *source, struct userdata *u) {
+ pa_source_output *so;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(source);
+ pa_assert(u);
+ pa_assert(u->on_hotplug && u->restore_device);
+
+ PA_IDXSET_FOREACH(so, c->source_outputs, idx) {
+ char *name;
+ struct entry *e;
+
+ if (so->source == source)
+ continue;
+
+ if (so->save_source)
+ continue;
+
+ if (so->direct_on_input)
+ continue;
+
+ /* Skip this if it is already in the process of being moved anyway */
+ if (!so->source)
+ continue;
+
+ /* It might happen that a stream and a source are set up at the
+ same time, in which case we want to make sure we don't
+ interfere with that */
+ if (!PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(so)))
+ continue;
+
+ if (!(name = get_name(so->proplist, "source-output")))
+ continue;
+
+ if ((e = entry_read(u, name))) {
+ if (e->device_valid && pa_streq(e->device, source->name))
+ pa_source_output_move_to(so, source, TRUE);
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t sink_unlink_hook_callback(pa_core *c, pa_sink *sink, struct userdata *u) {
+ pa_sink_input *si;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(sink);
+ pa_assert(u);
+ pa_assert(u->on_rescue && u->restore_device);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ PA_IDXSET_FOREACH(si, sink->inputs, idx) {
+ char *name;
+ struct entry *e;
+
+ if (!si->sink)
+ continue;
+
+ if (!(name = get_name(si->proplist, "sink-input")))
+ continue;
+
+ if ((e = entry_read(u, name))) {
+
+ if (e->device_valid) {
+ pa_sink *d;
+
+ if ((d = pa_namereg_get(c, e->device, PA_NAMEREG_SINK)) &&
+ d != sink &&
+ PA_SINK_IS_LINKED(pa_sink_get_state(d)))
+ pa_sink_input_move_to(si, d, TRUE);
+ }
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_unlink_hook_callback(pa_core *c, pa_source *source, struct userdata *u) {
+ pa_source_output *so;
+ uint32_t idx;
+
+ pa_assert(c);
+ pa_assert(source);
+ pa_assert(u);
+ pa_assert(u->on_rescue && u->restore_device);
+
+ /* There's no point in doing anything if the core is shut down anyway */
+ if (c->state == PA_CORE_SHUTDOWN)
+ return PA_HOOK_OK;
+
+ PA_IDXSET_FOREACH(so, source->outputs, idx) {
+ char *name;
+ struct entry *e;
+
+ if (so->direct_on_input)
+ continue;
+
+ if (!so->source)
+ continue;
+
+ if (!(name = get_name(so->proplist, "source-output")))
+ continue;
+
+ if ((e = entry_read(u, name))) {
+
+ if (e->device_valid) {
+ pa_source *d;
+
+ if ((d = pa_namereg_get(c, e->device, PA_NAMEREG_SOURCE)) &&
+ d != source &&
+ PA_SOURCE_IS_LINKED(pa_source_get_state(d)))
+ pa_source_output_move_to(so, d, TRUE);
+ }
+
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+ }
+
+ return PA_HOOK_OK;
+}
+
#define EXT_VERSION 1
-static void apply_entry(struct userdata *u, const char *name, struct entry *e) {
+static void entry_apply(struct userdata *u, const char *name, struct entry *e) {
pa_sink_input *si;
pa_source_output *so;
uint32_t idx;
@@ -480,7 +1710,7 @@ static void apply_entry(struct userdata *u, const char *name, struct entry *e) {
pa_assert(name);
pa_assert(e);
- for (si = pa_idxset_first(u->core->sink_inputs, &idx); si; si = pa_idxset_next(u->core->sink_inputs, &idx)) {
+ PA_IDXSET_FOREACH(si, u->core->sink_inputs, idx) {
char *n;
pa_sink *s;
@@ -493,12 +1723,13 @@ static void apply_entry(struct userdata *u, const char *name, struct entry *e) {
}
pa_xfree(n);
- if (u->restore_volume && e->volume_valid) {
+ if (u->restore_volume && e->volume_valid && si->volume_writable) {
pa_cvolume v;
v = e->volume;
pa_log_info("Restoring volume for sink input %s.", name);
- pa_sink_input_set_volume(si, pa_cvolume_remap(&v, &e->channel_map, &si->channel_map), FALSE, FALSE);
+ pa_cvolume_remap(&v, &e->channel_map, &si->channel_map);
+ pa_sink_input_set_volume(si, &v, TRUE, FALSE);
}
if (u->restore_muted && e->muted_valid) {
@@ -506,16 +1737,28 @@ static void apply_entry(struct userdata *u, const char *name, struct entry *e) {
pa_sink_input_set_mute(si, e->muted, TRUE);
}
- if (u->restore_device &&
- e->device_valid &&
- (s = pa_namereg_get(u->core, e->device, PA_NAMEREG_SINK))) {
-
- pa_log_info("Restoring device for stream %s.", name);
- pa_sink_input_move_to(si, s, TRUE);
+ if (u->restore_device) {
+ if (!e->device_valid) {
+ if (si->save_sink) {
+ pa_log_info("Ensuring device is not saved for stream %s.", name);
+ /* If the device is not valid we should make sure the
+ save flag is cleared as the user may have specifically
+ removed the sink element from the rule. */
+ si->save_sink = FALSE;
+ /* This is cheating a bit. The sink input itself has not changed
+ but the rules governing it's routing have, so we fire this event
+ such that other routing modules (e.g. module-device-manager)
+ will pick up the change and reapply their routing */
+ pa_subscription_post(si->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, si->index);
+ }
+ } else if ((s = pa_namereg_get(u->core, e->device, PA_NAMEREG_SINK))) {
+ pa_log_info("Restoring device for stream %s.", name);
+ pa_sink_input_move_to(si, s, TRUE);
+ }
}
}
- for (so = pa_idxset_first(u->core->source_outputs, &idx); so; so = pa_idxset_next(u->core->source_outputs, &idx)) {
+ PA_IDXSET_FOREACH(so, u->core->source_outputs, idx) {
char *n;
pa_source *s;
@@ -528,18 +1771,30 @@ static void apply_entry(struct userdata *u, const char *name, struct entry *e) {
}
pa_xfree(n);
- if (u->restore_device &&
- e->device_valid &&
- (s = pa_namereg_get(u->core, e->device, PA_NAMEREG_SOURCE))) {
-
- pa_log_info("Restoring device for stream %s.", name);
- pa_source_output_move_to(so, s, TRUE);
+ if (u->restore_device) {
+ if (!e->device_valid) {
+ if (so->save_source) {
+ pa_log_info("Ensuring device is not saved for stream %s.", name);
+ /* If the device is not valid we should make sure the
+ save flag is cleared as the user may have specifically
+ removed the source element from the rule. */
+ so->save_source = FALSE;
+ /* This is cheating a bit. The source output itself has not changed
+ but the rules governing it's routing have, so we fire this event
+ such that other routing modules (e.g. module-device-manager)
+ will pick up the change and reapply their routing */
+ pa_subscription_post(so->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, so->index);
+ }
+ } else if ((s = pa_namereg_get(u->core, e->device, PA_NAMEREG_SOURCE))) {
+ pa_log_info("Restoring device for stream %s.", name);
+ pa_source_output_move_to(so, s, TRUE);
+ }
}
}
}
-#if 0
-static void dump_database(struct userdata *u) {
+#ifdef DEBUG_VOLUME
+PA_GCC_UNUSED static void stream_restore_dump_database(struct userdata *u) {
pa_datum key;
pa_bool_t done;
@@ -555,14 +1810,14 @@ static void dump_database(struct userdata *u) {
name = pa_xstrndup(key.data, key.size);
pa_datum_free(&key);
- if ((e = read_entry(u, name))) {
+ if ((e = entry_read(u, name))) {
char t[256];
pa_log("name=%s", name);
pa_log("device=%s %s", e->device, pa_yes_no(e->device_valid));
pa_log("channel_map=%s", pa_channel_map_snprint(t, sizeof(t), &e->channel_map));
pa_log("volume=%s %s", pa_cvolume_snprint(t, sizeof(t), &e->volume), pa_yes_no(e->volume_valid));
pa_log("mute=%s %s", pa_yes_no(e->muted), pa_yes_no(e->volume_valid));
- pa_xfree(e);
+ entry_free(e);
}
pa_xfree(name);
@@ -619,7 +1874,7 @@ static int extension_cb(pa_native_protocol *p, pa_module *m, pa_native_connectio
name = pa_xstrndup(key.data, key.size);
pa_datum_free(&key);
- if ((e = read_entry(u, name))) {
+ if ((e = entry_read(u, name))) {
pa_cvolume r;
pa_channel_map cm;
@@ -629,7 +1884,7 @@ static int extension_cb(pa_native_protocol *p, pa_module *m, pa_native_connectio
pa_tagstruct_puts(reply, e->device_valid ? e->device : NULL);
pa_tagstruct_put_boolean(reply, e->muted_valid ? e->muted : FALSE);
- pa_xfree(e);
+ entry_free(e);
}
pa_xfree(name);
@@ -653,54 +1908,103 @@ static int extension_cb(pa_native_protocol *p, pa_module *m, pa_native_connectio
mode != PA_UPDATE_SET)
goto fail;
- if (mode == PA_UPDATE_SET)
+ if (mode == PA_UPDATE_SET) {
+#ifdef HAVE_DBUS
+ struct dbus_entry *de;
+ void *state = NULL;
+
+ PA_HASHMAP_FOREACH(de, u->dbus_entries, state) {
+ send_entry_removed_signal(de);
+ dbus_entry_free(pa_hashmap_remove(u->dbus_entries, de->entry_name));
+ }
+#endif
pa_database_clear(u->database);
+ }
while (!pa_tagstruct_eof(t)) {
const char *name, *device;
pa_bool_t muted;
- struct entry entry;
- pa_datum key, data;
+ struct entry *entry;
+#ifdef HAVE_DBUS
+ struct entry *old;
+#endif
- pa_zero(entry);
- entry.version = ENTRY_VERSION;
+ entry = entry_new();
if (pa_tagstruct_gets(t, &name) < 0 ||
- pa_tagstruct_get_channel_map(t, &entry.channel_map) ||
- pa_tagstruct_get_cvolume(t, &entry.volume) < 0 ||
+ pa_tagstruct_get_channel_map(t, &entry->channel_map) ||
+ pa_tagstruct_get_cvolume(t, &entry->volume) < 0 ||
pa_tagstruct_gets(t, &device) < 0 ||
pa_tagstruct_get_boolean(t, &muted) < 0)
goto fail;
- if (!name || !*name)
+ if (!name || !*name) {
+ entry_free(entry);
goto fail;
+ }
- entry.volume_valid = entry.volume.channels > 0;
+ entry->volume_valid = entry->volume.channels > 0;
- if (entry.volume_valid)
- if (!pa_cvolume_compatible_with_channel_map(&entry.volume, &entry.channel_map))
+ if (entry->volume_valid)
+ if (!pa_cvolume_compatible_with_channel_map(&entry->volume, &entry->channel_map)) {
+ entry_free(entry);
goto fail;
+ }
- entry.muted = muted;
- entry.muted_valid = TRUE;
+ entry->muted = muted;
+ entry->muted_valid = TRUE;
- if (device)
- pa_strlcpy(entry.device, device, sizeof(entry.device));
- entry.device_valid = !!entry.device[0];
+ entry->device = pa_xstrdup(device);
+ entry->device_valid = device && !!entry->device[0];
- if (entry.device_valid &&
- !pa_namereg_is_valid_name(entry.device))
+ if (entry->device_valid && !pa_namereg_is_valid_name(entry->device)) {
+ entry_free(entry);
goto fail;
+ }
- key.data = (char*) name;
- key.size = strlen(name);
+#ifdef HAVE_DBUS
+ old = entry_read(u, name);
+#endif
+
+ pa_log_debug("Client %s changes entry %s.",
+ pa_strnull(pa_proplist_gets(pa_native_connection_get_client(c)->proplist, PA_PROP_APPLICATION_PROCESS_BINARY)),
+ name);
+
+ if (entry_write(u, name, entry, mode == PA_UPDATE_REPLACE)) {
+#ifdef HAVE_DBUS
+ struct dbus_entry *de;
+
+ if (old) {
+ pa_assert_se((de = pa_hashmap_get(u->dbus_entries, name)));
+
+ if ((old->device_valid != entry->device_valid)
+ || (entry->device_valid && !pa_streq(entry->device, old->device)))
+ send_device_updated_signal(de, entry);
- data.data = &entry;
- data.size = sizeof(entry);
+ if ((old->volume_valid != entry->volume_valid)
+ || (entry->volume_valid && (!pa_cvolume_equal(&entry->volume, &old->volume)
+ || !pa_channel_map_equal(&entry->channel_map, &old->channel_map))))
+ send_volume_updated_signal(de, entry);
+
+ if (!old->muted_valid || (entry->muted != old->muted))
+ send_mute_updated_signal(de, entry);
+
+ } else {
+ de = dbus_entry_new(u, name);
+ pa_assert_se(pa_hashmap_put(u->dbus_entries, de->entry_name, de) == 0);
+ send_new_entry_signal(de);
+ }
+#endif
- if (pa_database_set(u->database, &key, &data, mode == PA_UPDATE_REPLACE) == 0)
if (apply_immediately)
- apply_entry(u, name, &entry);
+ entry_apply(u, name, entry);
+ }
+
+#ifdef HAVE_DBUS
+ if (old)
+ entry_free(old);
+#endif
+ entry_free(entry);
}
trigger_save(u);
@@ -713,10 +2017,20 @@ static int extension_cb(pa_native_protocol *p, pa_module *m, pa_native_connectio
while (!pa_tagstruct_eof(t)) {
const char *name;
pa_datum key;
+#ifdef HAVE_DBUS
+ struct dbus_entry *de;
+#endif
if (pa_tagstruct_gets(t, &name) < 0)
goto fail;
+#ifdef HAVE_DBUS
+ if ((de = pa_hashmap_get(u->dbus_entries, name))) {
+ send_entry_removed_signal(de);
+ dbus_entry_free(pa_hashmap_remove(u->dbus_entries, name));
+ }
+#endif
+
key.data = (char*) name;
key.size = strlen(name);
@@ -774,7 +2088,11 @@ int pa__init(pa_module*m) {
pa_sink_input *si;
pa_source_output *so;
uint32_t idx;
- pa_bool_t restore_device = TRUE, restore_volume = TRUE, restore_muted = TRUE;
+ pa_bool_t restore_device = TRUE, restore_volume = TRUE, restore_muted = TRUE, on_hotplug = TRUE, on_rescue = TRUE;
+#ifdef HAVE_DBUS
+ pa_datum key;
+ pa_bool_t done;
+#endif
pa_assert(m);
@@ -785,22 +2103,24 @@ int pa__init(pa_module*m) {
if (pa_modargs_get_value_boolean(ma, "restore_device", &restore_device) < 0 ||
pa_modargs_get_value_boolean(ma, "restore_volume", &restore_volume) < 0 ||
- pa_modargs_get_value_boolean(ma, "restore_muted", &restore_muted) < 0) {
- pa_log("restore_device=, restore_volume= and restore_muted= expect boolean arguments");
+ pa_modargs_get_value_boolean(ma, "restore_muted", &restore_muted) < 0 ||
+ pa_modargs_get_value_boolean(ma, "on_hotplug", &on_hotplug) < 0 ||
+ pa_modargs_get_value_boolean(ma, "on_rescue", &on_rescue) < 0) {
+ pa_log("restore_device=, restore_volume=, restore_muted=, on_hotplug= and on_rescue= expect boolean arguments");
goto fail;
}
if (!restore_muted && !restore_volume && !restore_device)
pa_log_warn("Neither restoring volume, nor restoring muted, nor restoring device enabled!");
- m->userdata = u = pa_xnew(struct userdata, 1);
+ m->userdata = u = pa_xnew0(struct userdata, 1);
u->core = m->core;
u->module = m;
- u->save_time_event = NULL;
u->restore_device = restore_device;
u->restore_volume = restore_volume;
u->restore_muted = restore_muted;
- u->database = NULL;
+ u->on_hotplug = on_hotplug;
+ u->on_rescue = on_rescue;
u->subscribed = pa_idxset_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
u->protocol = pa_native_protocol_get(m->core);
@@ -811,17 +2131,27 @@ int pa__init(pa_module*m) {
u->subscription = pa_subscription_new(m->core, PA_SUBSCRIPTION_MASK_SINK_INPUT|PA_SUBSCRIPTION_MASK_SOURCE_OUTPUT, subscribe_callback, u);
if (restore_device) {
+ /* A little bit earlier than module-intended-roles ... */
u->sink_input_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_NEW], PA_HOOK_EARLY, (pa_hook_cb_t) sink_input_new_hook_callback, u);
u->source_output_new_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_NEW], PA_HOOK_EARLY, (pa_hook_cb_t) source_output_new_hook_callback, u);
}
- if (restore_volume || restore_muted)
- u->sink_input_fixate_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_FIXATE], PA_HOOK_EARLY, (pa_hook_cb_t) sink_input_fixate_hook_callback, u);
+ if (restore_device && on_hotplug) {
+ /* A little bit earlier than module-intended-roles ... */
+ u->sink_put_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_LATE, (pa_hook_cb_t) sink_put_hook_callback, u);
+ u->source_put_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_PUT], PA_HOOK_LATE, (pa_hook_cb_t) source_put_hook_callback, u);
+ }
+ if (restore_device && on_rescue) {
+ /* A little bit earlier than module-intended-roles, module-rescue-streams, ... */
+ u->sink_unlink_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) sink_unlink_hook_callback, u);
+ u->source_unlink_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_UNLINK], PA_HOOK_LATE, (pa_hook_cb_t) source_unlink_hook_callback, u);
+ }
- fname = pa_state_path("stream-volumes", TRUE);
+ if (restore_volume || restore_muted)
+ u->sink_input_fixate_hook_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_INPUT_FIXATE], PA_HOOK_EARLY, (pa_hook_cb_t) sink_input_fixate_hook_callback, u);
- if (!fname)
+ if (!(fname = pa_state_path("stream-volumes", TRUE)))
goto fail;
if (!(u->database = pa_database_open(fname, TRUE))) {
@@ -830,13 +2160,46 @@ int pa__init(pa_module*m) {
goto fail;
}
- pa_log_info("Sucessfully opened database file '%s'.", fname);
+ pa_log_info("Successfully opened database file '%s'.", fname);
pa_xfree(fname);
- for (si = pa_idxset_first(m->core->sink_inputs, &idx); si; si = pa_idxset_next(m->core->sink_inputs, &idx))
+#ifdef HAVE_DBUS
+ u->dbus_protocol = pa_dbus_protocol_get(u->core);
+ u->dbus_entries = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ pa_assert_se(pa_dbus_protocol_add_interface(u->dbus_protocol, OBJECT_PATH, &stream_restore_interface_info, u) >= 0);
+ pa_assert_se(pa_dbus_protocol_register_extension(u->dbus_protocol, INTERFACE_STREAM_RESTORE) >= 0);
+
+ /* Create the initial dbus entries. */
+ done = !pa_database_first(u->database, &key, NULL);
+ while (!done) {
+ pa_datum next_key;
+ char *name;
+ struct dbus_entry *de;
+ struct entry *e;
+
+ done = !pa_database_next(u->database, &key, &next_key, NULL);
+
+ name = pa_xstrndup(key.data, key.size);
+ pa_datum_free(&key);
+
+ /* Use entry_read() for checking that the entry is valid. */
+ if ((e = entry_read(u, name))) {
+ de = dbus_entry_new(u, name);
+ pa_assert_se(pa_hashmap_put(u->dbus_entries, de->entry_name, de) == 0);
+ entry_free(e);
+ }
+
+ pa_xfree(name);
+
+ key = next_key;
+ }
+#endif
+
+ PA_IDXSET_FOREACH(si, m->core->sink_inputs, idx)
subscribe_callback(m->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_NEW, si->index, u);
- for (so = pa_idxset_first(m->core->source_outputs, &idx); so; so = pa_idxset_next(m->core->source_outputs, &idx))
+ PA_IDXSET_FOREACH(so, m->core->source_outputs, idx)
subscribe_callback(m->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_NEW, so->index, u);
pa_modargs_free(ma);
@@ -848,8 +2211,18 @@ fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
+}
+
+#ifdef HAVE_DBUS
+static void free_dbus_entry_cb(void *p, void *userdata) {
+ struct dbus_entry *de = p;
+
+ pa_assert(de);
+
+ dbus_entry_free(de);
}
+#endif
void pa__done(pa_module*m) {
struct userdata* u;
@@ -859,6 +2232,19 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
+#ifdef HAVE_DBUS
+ if (u->dbus_protocol) {
+ pa_assert(u->dbus_entries);
+
+ pa_assert_se(pa_dbus_protocol_unregister_extension(u->dbus_protocol, INTERFACE_STREAM_RESTORE) >= 0);
+ pa_assert_se(pa_dbus_protocol_remove_interface(u->dbus_protocol, OBJECT_PATH, stream_restore_interface_info.name) >= 0);
+
+ pa_hashmap_free(u->dbus_entries, free_dbus_entry_cb, NULL);
+
+ pa_dbus_protocol_unref(u->dbus_protocol);
+ }
+#endif
+
if (u->subscription)
pa_subscription_free(u->subscription);
@@ -869,6 +2255,16 @@ void pa__done(pa_module*m) {
if (u->source_output_new_hook_slot)
pa_hook_slot_free(u->source_output_new_hook_slot);
+ if (u->sink_put_hook_slot)
+ pa_hook_slot_free(u->sink_put_hook_slot);
+ if (u->source_put_hook_slot)
+ pa_hook_slot_free(u->source_put_hook_slot);
+
+ if (u->sink_unlink_hook_slot)
+ pa_hook_slot_free(u->sink_unlink_hook_slot);
+ if (u->source_unlink_hook_slot)
+ pa_hook_slot_free(u->source_unlink_hook_slot);
+
if (u->connection_unlink_hook_slot)
pa_hook_slot_free(u->connection_unlink_hook_slot);
diff --git a/src/modules/module-suspend-on-idle.c b/src/modules/module-suspend-on-idle.c
index cc69d74c..e7242628 100644
--- a/src/modules/module-suspend-on-idle.c
+++ b/src/modules/module-suspend-on-idle.c
@@ -25,6 +25,7 @@
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
+#include <pulse/rtclock.h>
#include <pulsecore/core.h>
#include <pulsecore/core-util.h>
@@ -32,7 +33,6 @@
#include <pulsecore/source-output.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
-#include <pulsecore/namereg.h>
#include "module-suspend-on-idle-symdef.h"
@@ -40,9 +40,13 @@ PA_MODULE_AUTHOR("Lennart Poettering");
PA_MODULE_DESCRIPTION("When a sink/source is idle for too long, suspend it");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_USAGE(
+ "timeout=<timeout> "
+ "mempool_vacuum=<vacuum memory if all sinks and sources are suspended?>");
static const char* const valid_modargs[] = {
"timeout",
+ "mempool_vacuum",
NULL,
};
@@ -69,51 +73,78 @@ struct userdata {
*source_output_move_finish_slot,
*sink_input_state_changed_slot,
*source_output_state_changed_slot;
+
+ pa_bool_t mempool_vacuum:1;
};
struct device_info {
struct userdata *userdata;
pa_sink *sink;
pa_source *source;
- struct timeval last_use;
+ pa_usec_t last_use;
pa_time_event *time_event;
};
-static void timeout_cb(pa_mainloop_api*a, pa_time_event* e, const struct timeval *tv, void *userdata) {
+static void check_meempool_vacuum(struct device_info *d) {
+ pa_sink *si;
+ pa_source *so;
+ uint32_t idx;
+
+ pa_assert(d);
+ pa_assert(d->userdata);
+ pa_assert(d->userdata->core);
+
+ idx = 0;
+ PA_IDXSET_FOREACH(si, d->userdata->core->sinks, idx)
+ if (pa_sink_get_state(si) != PA_SINK_SUSPENDED)
+ return;
+
+ idx = 0;
+ PA_IDXSET_FOREACH(so, d->userdata->core->sources, idx)
+ if (pa_source_get_state(so) != PA_SOURCE_SUSPENDED)
+ return;
+
+ pa_log_info("All sinks and sources are suspended, vacuuming memory");
+ pa_mempool_vacuum(d->userdata->core->mempool);
+}
+
+static void timeout_cb(pa_mainloop_api*a, pa_time_event* e, const struct timeval *t, void *userdata) {
struct device_info *d = userdata;
pa_assert(d);
d->userdata->core->mainloop->time_restart(d->time_event, NULL);
- if (d->sink && pa_sink_check_suspend(d->sink) <= 0 && pa_sink_get_state(d->sink) != PA_SINK_SUSPENDED) {
+ if (d->sink && pa_sink_check_suspend(d->sink) <= 0 && !(d->sink->suspend_cause & PA_SUSPEND_IDLE)) {
pa_log_info("Sink %s idle for too long, suspending ...", d->sink->name);
- pa_sink_suspend(d->sink, TRUE);
+ pa_sink_suspend(d->sink, TRUE, PA_SUSPEND_IDLE);
+ if (d->userdata->mempool_vacuum)
+ check_meempool_vacuum(d);
}
- if (d->source && pa_source_check_suspend(d->source) <= 0 && pa_source_get_state(d->source) != PA_SOURCE_SUSPENDED) {
+ if (d->source && pa_source_check_suspend(d->source) <= 0 && !(d->source->suspend_cause & PA_SUSPEND_IDLE)) {
pa_log_info("Source %s idle for too long, suspending ...", d->source->name);
- pa_source_suspend(d->source, TRUE);
+ pa_source_suspend(d->source, TRUE, PA_SUSPEND_IDLE);
+ if (d->userdata->mempool_vacuum)
+ check_meempool_vacuum(d);
}
}
static void restart(struct device_info *d) {
- struct timeval tv;
+ pa_usec_t now;
const char *s;
uint32_t timeout;
+
pa_assert(d);
pa_assert(d->sink || d->source);
- pa_gettimeofday(&tv);
- d->last_use = tv;
+ d->last_use = now = pa_rtclock_now();
s = pa_proplist_gets(d->sink ? d->sink->proplist : d->source->proplist, "module-suspend-on-idle.timeout");
if (!s || pa_atou(s, &timeout) < 0)
- timeout = d->userdata->timeout;
-
- pa_timeval_add(&tv, timeout * PA_USEC_PER_SEC);
+ timeout = d->userdata->timeout;
- d->userdata->core->mainloop->time_restart(d->time_event, &tv);
+ pa_core_rttime_restart(d->userdata->core, d->time_event, now + timeout * PA_USEC_PER_SEC);
if (d->sink)
pa_log_debug("Sink %s becomes idle, timeout in %u seconds.", d->sink->name, timeout);
@@ -127,13 +158,13 @@ static void resume(struct device_info *d) {
d->userdata->core->mainloop->time_restart(d->time_event, NULL);
if (d->sink) {
- pa_sink_suspend(d->sink, FALSE);
+ pa_sink_suspend(d->sink, FALSE, PA_SUSPEND_IDLE);
pa_log_debug("Sink %s becomes busy.", d->sink->name);
}
if (d->source) {
- pa_source_suspend(d->source, FALSE);
+ pa_source_suspend(d->source, FALSE, PA_SUSPEND_IDLE);
pa_log_debug("Source %s becomes busy.", d->source->name);
}
@@ -146,6 +177,10 @@ static pa_hook_result_t sink_input_fixate_hook_cb(pa_core *c, pa_sink_input_new_
pa_assert(data);
pa_assert(u);
+ /* We need to resume the audio device here even for
+ * PA_SINK_INPUT_START_CORKED, since we need the device parameters
+ * to be fully available while the stream is set up. */
+
if ((d = pa_hashmap_get(u->device_infos, data->sink)))
resume(d);
@@ -227,11 +262,16 @@ static pa_hook_result_t sink_input_move_start_hook_cb(pa_core *c, pa_sink_input
static pa_hook_result_t sink_input_move_finish_hook_cb(pa_core *c, pa_sink_input *s, struct userdata *u) {
struct device_info *d;
+ pa_sink_input_state_t state;
pa_assert(c);
pa_sink_input_assert_ref(s);
pa_assert(u);
+ state = pa_sink_input_get_state(s);
+ if (state != PA_SINK_INPUT_RUNNING && state != PA_SINK_INPUT_DRAINED)
+ return PA_HOOK_OK;
+
if ((d = pa_hashmap_get(u->device_infos, s->sink)))
resume(d);
@@ -266,6 +306,9 @@ static pa_hook_result_t source_output_move_finish_hook_cb(pa_core *c, pa_source_
pa_source_output_assert_ref(s);
pa_assert(u);
+ if (pa_source_output_get_state(s) != PA_SOURCE_OUTPUT_RUNNING)
+ return PA_HOOK_OK;
+
if (s->source->monitor_of)
d = pa_hashmap_get(u->device_infos, s->source->monitor_of);
else
@@ -280,6 +323,7 @@ static pa_hook_result_t source_output_move_finish_hook_cb(pa_core *c, pa_source_
static pa_hook_result_t sink_input_state_changed_hook_cb(pa_core *c, pa_sink_input *s, struct userdata *u) {
struct device_info *d;
pa_sink_input_state_t state;
+
pa_assert(c);
pa_sink_input_assert_ref(s);
pa_assert(u);
@@ -293,15 +337,11 @@ static pa_hook_result_t sink_input_state_changed_hook_cb(pa_core *c, pa_sink_inp
}
static pa_hook_result_t source_output_state_changed_hook_cb(pa_core *c, pa_source_output *s, struct userdata *u) {
- pa_source_output_state_t state;
-
pa_assert(c);
pa_source_output_assert_ref(s);
pa_assert(u);
- state = pa_source_output_get_state(s);
-
- if (state == PA_SOURCE_OUTPUT_RUNNING) {
+ if (pa_source_output_get_state(s) == PA_SOURCE_OUTPUT_RUNNING) {
struct device_info *d;
if (s->source->monitor_of)
@@ -338,7 +378,7 @@ static pa_hook_result_t device_new_hook_cb(pa_core *c, pa_object *o, struct user
d->userdata = u;
d->source = source ? pa_source_ref(source) : NULL;
d->sink = sink ? pa_sink_ref(sink) : NULL;
- d->time_event = c->mainloop->time_new(c->mainloop, NULL, timeout_cb, d);
+ d->time_event = pa_core_rttime_new(c, PA_USEC_INVALID, timeout_cb, d);
pa_hashmap_put(u->device_infos, o, d);
if ((d->sink && pa_sink_check_suspend(d->sink) <= 0) ||
@@ -388,22 +428,17 @@ static pa_hook_result_t device_state_changed_hook_cb(pa_core *c, pa_object *o, s
pa_sink *s = PA_SINK(o);
pa_sink_state_t state = pa_sink_get_state(s);
- if (pa_sink_check_suspend(s) <= 0) {
-
+ if (pa_sink_check_suspend(s) <= 0)
if (PA_SINK_IS_OPENED(state))
restart(d);
- }
-
} else if (pa_source_isinstance(o)) {
pa_source *s = PA_SOURCE(o);
pa_source_state_t state = pa_source_get_state(s);
- if (pa_source_check_suspend(s) <= 0) {
-
+ if (pa_source_check_suspend(s) <= 0)
if (PA_SOURCE_IS_OPENED(state))
restart(d);
- }
}
return PA_HOOK_OK;
@@ -413,6 +448,7 @@ int pa__init(pa_module*m) {
pa_modargs *ma = NULL;
struct userdata *u;
uint32_t timeout = 5;
+ pa_bool_t mempool_vacuum = FALSE;
uint32_t idx;
pa_sink *sink;
pa_source *source;
@@ -429,10 +465,16 @@ int pa__init(pa_module*m) {
goto fail;
}
+ if (pa_modargs_get_value_boolean(ma, "mempool_vacuum", &mempool_vacuum) < 0) {
+ pa_log("Failed to parse mempool_vacuum boolean parameter.");
+ goto fail;
+ }
+
m->userdata = u = pa_xnew(struct userdata, 1);
u->core = m->core;
u->timeout = timeout;
u->device_infos = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ u->mempool_vacuum = mempool_vacuum;
for (sink = pa_idxset_first(m->core->sinks, &idx); sink; sink = pa_idxset_next(m->core->sinks, &idx))
device_new_hook_cb(m->core, PA_OBJECT(sink), u);
diff --git a/src/modules/module-switch-on-connect.c b/src/modules/module-switch-on-connect.c
new file mode 100644
index 00000000..b121fd9a
--- /dev/null
+++ b/src/modules/module-switch-on-connect.c
@@ -0,0 +1,187 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2006 Lennart Poettering
+ Copyright 2009 Canonical Ltd
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/core.h>
+#include <pulsecore/sink-input.h>
+#include <pulsecore/source-output.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/core-util.h>
+
+#include "module-switch-on-connect-symdef.h"
+
+PA_MODULE_AUTHOR("Michael Terry");
+PA_MODULE_DESCRIPTION("When a sink/source is added, switch to it");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+
+static const char* const valid_modargs[] = {
+ NULL,
+};
+
+struct userdata {
+ pa_hook_slot
+ *sink_put_slot,
+ *source_put_slot;
+};
+
+static pa_hook_result_t sink_put_hook_callback(pa_core *c, pa_sink *sink, void* userdata) {
+ pa_sink_input *i;
+ uint32_t idx;
+ pa_sink *def;
+ const char *s;
+
+ pa_assert(c);
+ pa_assert(sink);
+
+ /* Don't want to run during startup or shutdown */
+ if (c->state != PA_CORE_RUNNING)
+ return PA_HOOK_OK;
+
+ /* Don't switch to any internal devices */
+ if ((s = pa_proplist_gets(sink->proplist, PA_PROP_DEVICE_BUS))) {
+ if (pa_streq(s, "pci"))
+ return PA_HOOK_OK;
+ else if (pa_streq(s, "isa"))
+ return PA_HOOK_OK;
+ }
+
+ def = pa_namereg_get_default_sink(c);
+ if (def == sink)
+ return PA_HOOK_OK;
+
+ /* Actually do the switch to the new sink */
+ pa_namereg_set_default_sink(c, sink);
+
+ /* Now move all old inputs over */
+ if (pa_idxset_size(def->inputs) <= 0) {
+ pa_log_debug("No sink inputs to move away.");
+ return PA_HOOK_OK;
+ }
+
+ PA_IDXSET_FOREACH(i, def->inputs, idx) {
+ if (i->save_sink)
+ continue;
+
+ if (pa_sink_input_move_to(i, sink, FALSE) < 0)
+ pa_log_info("Failed to move sink input %u \"%s\" to %s.", i->index,
+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), sink->name);
+ else
+ pa_log_info("Sucessfully moved sink input %u \"%s\" to %s.", i->index,
+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), sink->name);
+ }
+
+ return PA_HOOK_OK;
+}
+
+static pa_hook_result_t source_put_hook_callback(pa_core *c, pa_source *source, void* userdata) {
+ pa_source_output *o;
+ uint32_t idx;
+ pa_source *def;
+ const char *s;
+
+ pa_assert(c);
+ pa_assert(source);
+
+ /* Don't want to run during startup or shutdown */
+ if (c->state != PA_CORE_RUNNING)
+ return PA_HOOK_OK;
+
+ /* Don't switch to any internal devices */
+ if ((s = pa_proplist_gets(source->proplist, PA_PROP_DEVICE_BUS))) {
+ if (pa_streq(s, "pci"))
+ return PA_HOOK_OK;
+ else if (pa_streq(s, "isa"))
+ return PA_HOOK_OK;
+ }
+
+ def = pa_namereg_get_default_source(c);
+ if (def == source)
+ return PA_HOOK_OK;
+
+ /* Actually do the switch to the new source */
+ pa_namereg_set_default_source(c, source);
+
+ /* Now move all old outputs over */
+ if (pa_idxset_size(def->outputs) <= 0) {
+ pa_log_debug("No source outputs to move away.");
+ return PA_HOOK_OK;
+ }
+
+ PA_IDXSET_FOREACH(o, def->outputs, idx) {
+ if (o->save_source)
+ continue;
+
+ if (pa_source_output_move_to(o, source, FALSE) < 0)
+ pa_log_info("Failed to move source output %u \"%s\" to %s.", o->index,
+ pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME)), source->name);
+ else
+ pa_log_info("Sucessfully moved source output %u \"%s\" to %s.", o->index,
+ pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME)), source->name);
+ }
+
+ return PA_HOOK_OK;
+}
+
+int pa__init(pa_module*m) {
+ pa_modargs *ma;
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ return -1;
+ }
+
+ m->userdata = u = pa_xnew(struct userdata, 1);
+
+ /* A little bit later than module-rescue-streams... */
+ u->sink_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SINK_PUT], PA_HOOK_LATE+30, (pa_hook_cb_t) sink_put_hook_callback, u);
+ u->source_put_slot = pa_hook_connect(&m->core->hooks[PA_CORE_HOOK_SOURCE_PUT], PA_HOOK_LATE+20, (pa_hook_cb_t) source_put_hook_callback, u);
+
+ pa_modargs_free(ma);
+ return 0;
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->sink_put_slot)
+ pa_hook_slot_free(u->sink_put_slot);
+ if (u->source_put_slot)
+ pa_hook_slot_free(u->source_put_slot);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-tunnel.c b/src/modules/module-tunnel.c
index 6f525da3..4b1ae7df 100644
--- a/src/modules/module-tunnel.c
+++ b/src/modules/module-tunnel.c
@@ -31,6 +31,7 @@
#include <stdio.h>
#include <stdlib.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/util.h>
#include <pulse/version.h>
@@ -41,19 +42,18 @@
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
#include <pulsecore/core-subscribe.h>
-#include <pulsecore/sink-input.h>
#include <pulsecore/pdispatch.h>
#include <pulsecore/pstream.h>
#include <pulsecore/pstream-util.h>
#include <pulsecore/socket-client.h>
-#include <pulsecore/socket-util.h>
#include <pulsecore/time-smoother.h>
#include <pulsecore/thread.h>
#include <pulsecore/thread-mq.h>
-#include <pulsecore/rtclock.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-error.h>
#include <pulsecore/proplist-util.h>
#include <pulsecore/auth-cookie.h>
+#include <pulsecore/mcalign.h>
#ifdef TUNNEL_SINK
#include "module-tunnel-sink-symdef.h"
@@ -112,7 +112,7 @@ static const char* const valid_modargs[] = {
#define DEFAULT_TIMEOUT 5
-#define LATENCY_INTERVAL 10
+#define LATENCY_INTERVAL (10*PA_USEC_PER_SEC)
#define MIN_NETWORK_LATENCY_USEC (8*PA_USEC_PER_MSEC)
@@ -193,6 +193,7 @@ struct userdata {
#else
char *source_name;
pa_source *source;
+ pa_mcalign *mcalign;
#endif
pa_auth_cookie *auth_cookie;
@@ -329,7 +330,7 @@ static void command_moved(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
static void command_stream_buffer_attr_changed(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
struct userdata *u = userdata;
- uint32_t channel, maxlength, tlength, fragsize, prebuf, minreq;
+ uint32_t channel, maxlength, tlength = 0, fragsize, prebuf, minreq;
pa_usec_t usec;
pa_assert(pd);
@@ -376,7 +377,7 @@ static void command_stream_buffer_attr_changed(pa_pdispatch *pd, uint32_t comman
/* Called from main context */
static void command_started(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
- struct userdata *u = userdata;
+ struct userdata *u = userdata;
pa_assert(pd);
pa_assert(t);
@@ -390,12 +391,12 @@ static void command_started(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
#endif
/* Called from IO thread context */
-static void check_smoother_status(struct userdata *u, pa_bool_t past) {
+static void check_smoother_status(struct userdata *u, pa_bool_t past) {
pa_usec_t x;
pa_assert(u);
- x = pa_rtclock_usec();
+ x = pa_rtclock_now();
/* Correct by the time the requested issued needs to travel to the
* other side. This is a valid thread-safe access, because the
@@ -500,7 +501,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
pa_usec_t yl, yr, *usec = data;
yl = pa_bytes_to_usec((uint64_t) u->counter, &u->sink->sample_spec);
- yr = pa_smoother_get(u->smoother, pa_rtclock_usec());
+ yr = pa_smoother_get(u->smoother, pa_rtclock_now());
*usec = yl > yr ? yl - yr : 0;
return 0;
@@ -533,7 +534,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
else
y = 0;
- pa_smoother_put(u->smoother, pa_rtclock_usec(), y);
+ pa_smoother_put(u->smoother, pa_rtclock_now(), y);
/* We can access this freely here, since the main thread is waiting for us */
u->thread_transport_usec = u->transport_usec;
@@ -607,20 +608,29 @@ static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t off
pa_usec_t yr, yl, *usec = data;
yl = pa_bytes_to_usec((uint64_t) u->counter, &PA_SOURCE(o)->sample_spec);
- yr = pa_smoother_get(u->smoother, pa_rtclock_usec());
+ yr = pa_smoother_get(u->smoother, pa_rtclock_now());
*usec = yr > yl ? yr - yl : 0;
return 0;
}
- case SOURCE_MESSAGE_POST:
+ case SOURCE_MESSAGE_POST: {
+ pa_memchunk c;
+
+ pa_mcalign_push(u->mcalign, chunk);
+
+ while (pa_mcalign_pop(u->mcalign, &c) >= 0) {
- if (PA_SOURCE_IS_OPENED(u->source->thread_info.state))
- pa_source_post(u->source, chunk);
+ if (PA_SOURCE_IS_OPENED(u->source->thread_info.state))
+ pa_source_post(u->source, &c);
- u->counter += (int64_t) chunk->length;
+ pa_memblock_unref(c.memblock);
+
+ u->counter += (int64_t) c.length;
+ }
return 0;
+ }
case SOURCE_MESSAGE_REMOTE_SUSPEND:
@@ -633,7 +643,7 @@ static int source_process_msg(pa_msgobject *o, int code, void *data, int64_t off
y = pa_bytes_to_usec((uint64_t) u->counter, &u->source->sample_spec);
y += (pa_usec_t) offset;
- pa_smoother_put(u->smoother, pa_rtclock_usec(), y);
+ pa_smoother_put(u->smoother, pa_rtclock_now(), y);
/* We can access this freely here, since the main thread is waiting for us */
u->thread_transport_usec = u->transport_usec;
@@ -683,7 +693,6 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
int ret;
@@ -730,7 +739,7 @@ static void command_request(pa_pdispatch *pd, uint32_t command, uint32_t tag, p
}
if (channel != u->channel) {
- pa_log("Recieved data for invalid channel");
+ pa_log("Received data for invalid channel");
goto fail;
}
@@ -878,9 +887,8 @@ static void request_latency(struct userdata *u) {
}
/* Called from main context */
-static void timeout_callback(pa_mainloop_api *m, pa_time_event*e, const struct timeval *tv, void *userdata) {
+static void timeout_callback(pa_mainloop_api *m, pa_time_event *e, const struct timeval *t, void *userdata) {
struct userdata *u = userdata;
- struct timeval ntv;
pa_assert(m);
pa_assert(e);
@@ -888,9 +896,7 @@ static void timeout_callback(pa_mainloop_api *m, pa_time_event*e, const struct
request_latency(u);
- pa_gettimeofday(&ntv);
- ntv.tv_sec += LATENCY_INTERVAL;
- m->time_restart(e, &ntv);
+ pa_core_rttime_restart(u->core, e, pa_rtclock_now() + LATENCY_INTERVAL);
}
/* Called from main context */
@@ -965,8 +971,7 @@ static void server_info_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
pa_tagstruct_gets(t, &default_sink_name) < 0 ||
pa_tagstruct_gets(t, &default_source_name) < 0 ||
pa_tagstruct_getu32(t, &cookie) < 0 ||
- (u->version >= 15 &&
- pa_tagstruct_get_channel_map(t, &cm) < 0)) {
+ (u->version >= 15 && pa_tagstruct_get_channel_map(t, &cm) < 0)) {
pa_log("Parse failure");
goto fail;
@@ -1061,6 +1066,50 @@ static void sink_info_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_t
}
}
+ if (u->version >= 16) {
+ uint32_t n_ports;
+ const char *s;
+
+ if (pa_tagstruct_getu32(t, &n_ports)) {
+ pa_log("Parse failure");
+ goto fail;
+ }
+
+ for (uint32_t j = 0; j < n_ports; j++) {
+ uint32_t priority;
+
+ if (pa_tagstruct_gets(t, &s) < 0 || /* name */
+ pa_tagstruct_gets(t, &s) < 0 || /* description */
+ pa_tagstruct_getu32(t, &priority) < 0) {
+
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+
+ if (pa_tagstruct_gets(t, &s) < 0) { /* active port */
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+
+ if (u->version >= 21) {
+ uint8_t n_formats;
+ pa_format_info format;
+
+ if (pa_tagstruct_getu8(t, &n_formats) < 0) { /* no. of formats */
+ pa_log("Parse failure");
+ goto fail;
+ }
+
+ for (uint8_t j = 0; j < n_formats; j++) {
+ if (pa_tagstruct_get_format_info(t, &format)) { /* format info */
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+ }
+
if (!pa_tagstruct_eof(t)) {
pa_log("Packet too long");
goto fail;
@@ -1089,11 +1138,12 @@ static void sink_input_info_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag
uint32_t idx, owner_module, client, sink;
pa_usec_t buffer_usec, sink_usec;
const char *name, *driver, *resample_method;
- pa_bool_t mute;
+ pa_bool_t mute = FALSE;
pa_sample_spec sample_spec;
pa_channel_map channel_map;
pa_cvolume volume;
pa_proplist *pl;
+ pa_bool_t b;
pa_assert(pd);
pa_assert(u);
@@ -1141,6 +1191,33 @@ static void sink_input_info_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag
}
}
+ if (u->version >= 19) {
+ if (pa_tagstruct_get_boolean(t, &b) < 0) {
+
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+
+ if (u->version >= 20) {
+ if (pa_tagstruct_get_boolean(t, &b) < 0 ||
+ pa_tagstruct_get_boolean(t, &b) < 0) {
+
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+
+ if (u->version >= 21) {
+ pa_format_info format;
+
+ if (pa_tagstruct_get_format_info(t, &format) < 0) {
+
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+
if (!pa_tagstruct_eof(t)) {
pa_log("Packet too long");
goto fail;
@@ -1154,7 +1231,7 @@ static void sink_input_info_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag
pa_assert(u->sink);
if ((u->version < 11 || !!mute == !!u->sink->muted) &&
- pa_cvolume_equal(&volume, &u->sink->virtual_volume))
+ pa_cvolume_equal(&volume, &u->sink->real_volume))
return;
pa_sink_volume_changed(u->sink, &volume);
@@ -1237,6 +1314,33 @@ static void source_info_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
}
}
+ if (u->version >= 16) {
+ uint32_t n_ports;
+ const char *s;
+
+ if (pa_tagstruct_getu32(t, &n_ports)) {
+ pa_log("Parse failure");
+ goto fail;
+ }
+
+ for (uint32_t j = 0; j < n_ports; j++) {
+ uint32_t priority;
+
+ if (pa_tagstruct_gets(t, &s) < 0 || /* name */
+ pa_tagstruct_gets(t, &s) < 0 || /* description */
+ pa_tagstruct_getu32(t, &priority) < 0) {
+
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+
+ if (pa_tagstruct_gets(t, &s) < 0) { /* active port */
+ pa_log("Parse failure");
+ goto fail;
+ }
+ }
+
if (!pa_tagstruct_eof(t)) {
pa_log("Packet too long");
goto fail;
@@ -1337,12 +1441,11 @@ static void command_subscribe_event(pa_pdispatch *pd, uint32_t command, uint32
/* Called from main context */
static void start_subscribe(struct userdata *u) {
pa_tagstruct *t;
- uint32_t tag;
pa_assert(u);
t = pa_tagstruct_new(NULL, 0);
pa_tagstruct_putu32(t, PA_COMMAND_SUBSCRIBE);
- pa_tagstruct_putu32(t, tag = u->ctag++);
+ pa_tagstruct_putu32(t, u->ctag++);
pa_tagstruct_putu32(t, PA_SUBSCRIPTION_MASK_SERVER|
#ifdef TUNNEL_SINK
PA_SUBSCRIPTION_MASK_SINK_INPUT|PA_SUBSCRIPTION_MASK_SINK
@@ -1357,7 +1460,6 @@ static void start_subscribe(struct userdata *u) {
/* Called from main context */
static void create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
struct userdata *u = userdata;
- struct timeval ntv;
#ifdef TUNNEL_SINK
uint32_t bytes;
#endif
@@ -1432,6 +1534,13 @@ static void create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t
/* #endif */
}
+ if (u->version >= 21) {
+ pa_format_info format;
+
+ if (pa_tagstruct_get_format_info(t, &format) < 0)
+ goto parse_error;
+ }
+
if (!pa_tagstruct_eof(t))
goto parse_error;
@@ -1439,9 +1548,7 @@ static void create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t
request_info(u);
pa_assert(!u->time_event);
- pa_gettimeofday(&ntv);
- ntv.tv_sec += LATENCY_INTERVAL;
- u->time_event = u->core->mainloop->time_new(u->core->mainloop, &ntv, timeout_callback, u);
+ u->time_event = pa_core_rttime_new(u->core, pa_rtclock_now() + LATENCY_INTERVAL, timeout_callback, u);
request_latency(u);
@@ -1521,7 +1628,7 @@ static void setup_complete_callback(pa_pdispatch *pd, uint32_t command, uint32_t
reply = pa_tagstruct_new(NULL, 0);
pa_tagstruct_putu32(reply, PA_COMMAND_SET_CLIENT_NAME);
- pa_tagstruct_putu32(reply, tag = u->ctag++);
+ pa_tagstruct_putu32(reply, u->ctag++);
if (u->version >= 13) {
pa_proplist *pl;
@@ -1628,6 +1735,21 @@ static void setup_complete_callback(pa_pdispatch *pd, uint32_t command, uint32_t
pa_tagstruct_put_boolean(reply, FALSE); /* fail on suspend */
}
+#ifdef TUNNEL_SINK
+ if (u->version >= 17)
+ pa_tagstruct_put_boolean(reply, FALSE); /* relative volume */
+
+ if (u->version >= 18)
+ pa_tagstruct_put_boolean(reply, FALSE); /* passthrough stream */
+#endif
+
+#ifdef TUNNEL_SINK
+ if (u->version >= 21) {
+ /* We're not using the extended API, so n_formats = 0 and that's that */
+ pa_tagstruct_putu8(t, 0);
+ }
+#endif
+
pa_pstream_send_tagstruct(u->pstream, reply);
pa_pdispatch_register_reply(u->pdispatch, tag, DEFAULT_TIMEOUT, create_stream_callback, u, NULL);
@@ -1675,7 +1797,7 @@ static void pstream_memblock_callback(pa_pstream *p, uint32_t channel, int64_t o
pa_assert(u);
if (channel != u->channel) {
- pa_log("Recieved memory block on bad channel.");
+ pa_log("Received memory block on bad channel.");
pa_module_unload_request(u->module, TRUE);
return;
}
@@ -1706,7 +1828,7 @@ static void on_connection(pa_socket_client *sc, pa_iochannel *io, void *userdata
}
u->pstream = pa_pstream_new(u->core->mainloop, io, u->core->mempool);
- u->pdispatch = pa_pdispatch_new(u->core->mainloop, command_table, PA_COMMAND_MAX);
+ u->pdispatch = pa_pdispatch_new(u->core->mainloop, TRUE, command_table, PA_COMMAND_MAX);
pa_pstream_set_die_callback(u->pstream, pstream_die_callback, u);
pa_pstream_set_recieve_packet_callback(u->pstream, pstream_packet_callback, u);
@@ -1748,7 +1870,6 @@ static void on_connection(pa_socket_client *sc, pa_iochannel *io, void *userdata
static void sink_set_volume(pa_sink *sink) {
struct userdata *u;
pa_tagstruct *t;
- uint32_t tag;
pa_assert(sink);
u = sink->userdata;
@@ -1756,9 +1877,9 @@ static void sink_set_volume(pa_sink *sink) {
t = pa_tagstruct_new(NULL, 0);
pa_tagstruct_putu32(t, PA_COMMAND_SET_SINK_INPUT_VOLUME);
- pa_tagstruct_putu32(t, tag = u->ctag++);
+ pa_tagstruct_putu32(t, u->ctag++);
pa_tagstruct_putu32(t, u->device_index);
- pa_tagstruct_put_cvolume(t, &sink->virtual_volume);
+ pa_tagstruct_put_cvolume(t, &sink->real_volume);
pa_pstream_send_tagstruct(u->pstream, t);
}
@@ -1766,7 +1887,6 @@ static void sink_set_volume(pa_sink *sink) {
static void sink_set_mute(pa_sink *sink) {
struct userdata *u;
pa_tagstruct *t;
- uint32_t tag;
pa_assert(sink);
u = sink->userdata;
@@ -1777,7 +1897,7 @@ static void sink_set_mute(pa_sink *sink) {
t = pa_tagstruct_new(NULL, 0);
pa_tagstruct_putu32(t, PA_COMMAND_SET_SINK_INPUT_MUTE);
- pa_tagstruct_putu32(t, tag = u->ctag++);
+ pa_tagstruct_putu32(t, u->ctag++);
pa_tagstruct_putu32(t, u->device_index);
pa_tagstruct_put_boolean(t, !!sink->muted);
pa_pstream_send_tagstruct(u->pstream, t);
@@ -1825,7 +1945,7 @@ int pa__init(pa_module*m) {
TRUE,
TRUE,
10,
- pa_rtclock_usec(),
+ pa_rtclock_now(),
FALSE);
u->ctag = 1;
u->device_index = u->channel = PA_INVALID_INDEX;
@@ -1853,7 +1973,7 @@ int pa__init(pa_module*m) {
goto fail;
}
- if (!(u->client = pa_socket_client_new_string(m->core->mainloop, u->server_name, PA_NATIVE_DEFAULT_PORT))) {
+ if (!(u->client = pa_socket_client_new_string(m->core->mainloop, TRUE, u->server_name, PA_NATIVE_DEFAULT_PORT))) {
pa_log("Failed to connect to server '%s'", u->server_name);
goto fail;
}
@@ -1863,7 +1983,7 @@ int pa__init(pa_module*m) {
#ifdef TUNNEL_SINK
if (!(dn = pa_xstrdup(pa_modargs_get_value(ma, "sink_name", NULL))))
- dn = pa_sprintf_malloc("tunnel.%s", u->server_name);
+ dn = pa_sprintf_malloc("tunnel-sink.%s", u->server_name);
pa_sink_new_data_init(&data);
data.driver = __FILE__;
@@ -1907,7 +2027,7 @@ int pa__init(pa_module*m) {
#else
if (!(dn = pa_xstrdup(pa_modargs_get_value(ma, "source_name", NULL))))
- dn = pa_sprintf_malloc("tunnel.%s", u->server_name);
+ dn = pa_sprintf_malloc("tunnel-source.%s", u->server_name);
pa_source_new_data_init(&data);
data.driver = __FILE__;
@@ -1943,6 +2063,8 @@ int pa__init(pa_module*m) {
pa_source_set_asyncmsgq(u->source, u->thread_mq.inq);
pa_source_set_rtpoll(u->source, u->rtpoll);
+
+ u->mcalign = pa_mcalign_new(pa_frame_size(&u->source->sample_spec));
#endif
pa_xfree(dn);
@@ -1956,7 +2078,7 @@ int pa__init(pa_module*m) {
u->fragsize = (uint32_t) -1;
#endif
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("module-tunnel", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
@@ -1979,7 +2101,7 @@ fail:
pa_xfree(dn);
- return -1;
+ return -1;
}
void pa__done(pa_module*m) {
@@ -2036,6 +2158,11 @@ void pa__done(pa_module*m) {
if (u->time_event)
u->core->mainloop->time_free(u->time_event);
+#ifndef TUNNEL_SINK
+ if (u->mcalign)
+ pa_mcalign_free(u->mcalign);
+#endif
+
#ifdef TUNNEL_SINK
pa_xfree(u->sink_name);
#else
diff --git a/src/modules/module-udev-detect.c b/src/modules/module-udev-detect.c
new file mode 100644
index 00000000..63ad1952
--- /dev/null
+++ b/src/modules/module-udev-detect.c
@@ -0,0 +1,809 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Lennart Poettering
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of the
+ License, or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <errno.h>
+#include <limits.h>
+#include <dirent.h>
+#include <sys/inotify.h>
+#include <libudev.h>
+
+#include <pulse/timeval.h>
+
+#include <pulsecore/modargs.h>
+#include <pulsecore/core-error.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/ratelimit.h>
+
+#include "module-udev-detect-symdef.h"
+
+PA_MODULE_AUTHOR("Lennart Poettering");
+PA_MODULE_DESCRIPTION("Detect available audio hardware and load matching drivers");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(TRUE);
+PA_MODULE_USAGE(
+ "tsched=<enable system timer based scheduling mode?> "
+ "ignore_dB=<ignore dB information from the device?> "
+ "sync_volume=<syncronize sw and hw voluchanges in IO-thread?>");
+
+struct device {
+ char *path;
+ pa_bool_t need_verify;
+ char *card_name;
+ char *args;
+ uint32_t module;
+ pa_ratelimit ratelimit;
+};
+
+struct userdata {
+ pa_core *core;
+ pa_hashmap *devices;
+
+ pa_bool_t use_tsched:1;
+ pa_bool_t ignore_dB:1;
+ pa_bool_t sync_volume:1;
+
+ struct udev* udev;
+ struct udev_monitor *monitor;
+ pa_io_event *udev_io;
+
+ int inotify_fd;
+ pa_io_event *inotify_io;
+};
+
+static const char* const valid_modargs[] = {
+ "tsched",
+ "ignore_dB",
+ "sync_volume",
+ NULL
+};
+
+static int setup_inotify(struct userdata *u);
+
+static void device_free(struct device *d) {
+ pa_assert(d);
+
+ pa_xfree(d->path);
+ pa_xfree(d->card_name);
+ pa_xfree(d->args);
+ pa_xfree(d);
+}
+
+static const char *path_get_card_id(const char *path) {
+ const char *e;
+
+ if (!path)
+ return NULL;
+
+ if (!(e = strrchr(path, '/')))
+ return NULL;
+
+ if (!pa_startswith(e, "/card"))
+ return NULL;
+
+ return e + 5;
+}
+
+static char *card_get_sysattr(const char *card_idx, const char *name) {
+ struct udev *udev;
+ struct udev_device *card = NULL;
+ char *t, *r = NULL;
+ const char *v;
+
+ pa_assert(card_idx);
+ pa_assert(name);
+
+ if (!(udev = udev_new())) {
+ pa_log_error("Failed to allocate udev context.");
+ goto finish;
+ }
+
+ t = pa_sprintf_malloc("%s/class/sound/card%s", udev_get_sys_path(udev), card_idx);
+ card = udev_device_new_from_syspath(udev, t);
+ pa_xfree(t);
+
+ if (!card) {
+ pa_log_error("Failed to get card object.");
+ goto finish;
+ }
+
+ if ((v = udev_device_get_sysattr_value(card, name)) && *v)
+ r = pa_xstrdup(v);
+
+finish:
+
+ if (card)
+ udev_device_unref(card);
+
+ if (udev)
+ udev_unref(udev);
+
+ return r;
+}
+
+static pa_bool_t pcm_is_modem(const char *card_idx, const char *pcm) {
+ char *sysfs_path, *pcm_class;
+ pa_bool_t is_modem;
+
+ pa_assert(card_idx);
+ pa_assert(pcm);
+
+ /* Check /sys/class/sound/card.../pcmC...../pcm_class. An HDA
+ * modem can be used simultaneously with generic
+ * playback/record. */
+
+ sysfs_path = pa_sprintf_malloc("pcmC%sD%s/pcm_class", card_idx, pcm);
+ pcm_class = card_get_sysattr(card_idx, sysfs_path);
+ is_modem = pcm_class && pa_streq(pcm_class, "modem");
+ pa_xfree(pcm_class);
+ pa_xfree(sysfs_path);
+
+ return is_modem;
+}
+
+static pa_bool_t is_card_busy(const char *id) {
+ char *card_path = NULL, *pcm_path = NULL, *sub_status = NULL;
+ DIR *card_dir = NULL, *pcm_dir = NULL;
+ FILE *status_file = NULL;
+ size_t len;
+ struct dirent *space = NULL, *de;
+ pa_bool_t busy = FALSE;
+ int r;
+
+ pa_assert(id);
+
+ /* This simply uses /proc/asound/card.../pcm.../sub.../status to
+ * check whether there is still a process using this audio device. */
+
+ card_path = pa_sprintf_malloc("/proc/asound/card%s", id);
+
+ if (!(card_dir = opendir(card_path))) {
+ pa_log_warn("Failed to open %s: %s", card_path, pa_cstrerror(errno));
+ goto fail;
+ }
+
+ len = offsetof(struct dirent, d_name) + fpathconf(dirfd(card_dir), _PC_NAME_MAX) + 1;
+ space = pa_xmalloc(len);
+
+ for (;;) {
+ de = NULL;
+
+ if ((r = readdir_r(card_dir, space, &de)) != 0) {
+ pa_log_warn("readdir_r() failed: %s", pa_cstrerror(r));
+ goto fail;
+ }
+
+ if (!de)
+ break;
+
+ if (!pa_startswith(de->d_name, "pcm"))
+ continue;
+
+ if (pcm_is_modem(id, de->d_name + 3))
+ continue;
+
+ pa_xfree(pcm_path);
+ pcm_path = pa_sprintf_malloc("%s/%s", card_path, de->d_name);
+
+ if (pcm_dir)
+ closedir(pcm_dir);
+
+ if (!(pcm_dir = opendir(pcm_path))) {
+ pa_log_warn("Failed to open %s: %s", pcm_path, pa_cstrerror(errno));
+ continue;
+ }
+
+ for (;;) {
+ char line[32];
+
+ if ((r = readdir_r(pcm_dir, space, &de)) != 0) {
+ pa_log_warn("readdir_r() failed: %s", pa_cstrerror(r));
+ goto fail;
+ }
+
+ if (!de)
+ break;
+
+ if (!pa_startswith(de->d_name, "sub"))
+ continue;
+
+ pa_xfree(sub_status);
+ sub_status = pa_sprintf_malloc("%s/%s/status", pcm_path, de->d_name);
+
+ if (status_file)
+ fclose(status_file);
+
+ if (!(status_file = pa_fopen_cloexec(sub_status, "r"))) {
+ pa_log_warn("Failed to open %s: %s", sub_status, pa_cstrerror(errno));
+ continue;
+ }
+
+ if (!(fgets(line, sizeof(line)-1, status_file))) {
+ pa_log_warn("Failed to read from %s: %s", sub_status, pa_cstrerror(errno));
+ continue;
+ }
+
+ if (!pa_streq(line, "closed\n")) {
+ busy = TRUE;
+ break;
+ }
+ }
+ }
+
+fail:
+
+ pa_xfree(card_path);
+ pa_xfree(pcm_path);
+ pa_xfree(sub_status);
+ pa_xfree(space);
+
+ if (card_dir)
+ closedir(card_dir);
+
+ if (pcm_dir)
+ closedir(pcm_dir);
+
+ if (status_file)
+ fclose(status_file);
+
+ return busy;
+}
+
+static void verify_access(struct userdata *u, struct device *d) {
+ char *cd;
+ pa_card *card;
+ pa_bool_t accessible;
+
+ pa_assert(u);
+ pa_assert(d);
+
+ cd = pa_sprintf_malloc("%s/snd/controlC%s", udev_get_dev_path(u->udev), path_get_card_id(d->path));
+ accessible = access(cd, R_OK|W_OK) >= 0;
+ pa_log_debug("%s is accessible: %s", cd, pa_yes_no(accessible));
+
+ pa_xfree(cd);
+
+ if (d->module == PA_INVALID_INDEX) {
+
+ /* If we are not loaded, try to load */
+
+ if (accessible) {
+ pa_module *m;
+ pa_bool_t busy;
+
+ /* Check if any of the PCM devices that belong to this
+ * card are currently busy. If they are, don't try to load
+ * right now, to make sure the probing phase can
+ * successfully complete. When the current user of the
+ * device closes it we will get another notification via
+ * inotify and can then recheck. */
+
+ busy = is_card_busy(path_get_card_id(d->path));
+ pa_log_debug("%s is busy: %s", d->path, pa_yes_no(busy));
+
+ if (!busy) {
+
+ /* So, why do we rate limit here? It's certainly ugly,
+ * but there seems to be no other way. Problem is
+ * this: if we are unable to configure/probe an audio
+ * device after opening it we will close it again and
+ * the module initialization will fail. This will then
+ * cause an inotify event on the device node which
+ * will be forwarded to us. We then try to reopen the
+ * audio device again, practically entering a busy
+ * loop.
+ *
+ * A clean fix would be if we would be able to ignore
+ * our own inotify close events. However, inotify
+ * lacks such functionality. Also, during probing of
+ * the device we cannot really distuingish between
+ * other processes causing EBUSY or ourselves, which
+ * means we have no way to figure out if the probing
+ * during opening was canceled by a "try again"
+ * failure or a "fatal" failure. */
+
+ if (pa_ratelimit_test(&d->ratelimit, PA_LOG_DEBUG)) {
+ pa_log_debug("Loading module-alsa-card with arguments '%s'", d->args);
+ m = pa_module_load(u->core, "module-alsa-card", d->args);
+
+ if (m) {
+ d->module = m->index;
+ pa_log_info("Card %s (%s) module loaded.", d->path, d->card_name);
+ } else
+ pa_log_info("Card %s (%s) failed to load module.", d->path, d->card_name);
+ } else
+ pa_log_warn("Tried to configure %s (%s) more often than %u times in %llus",
+ d->path,
+ d->card_name,
+ d->ratelimit.burst,
+ (long long unsigned) (d->ratelimit.interval / PA_USEC_PER_SEC));
+ }
+ }
+
+ } else {
+
+ /* If we are already loaded update suspend status with
+ * accessible boolean */
+
+ if ((card = pa_namereg_get(u->core, d->card_name, PA_NAMEREG_CARD)))
+ pa_card_suspend(card, !accessible, PA_SUSPEND_SESSION);
+ }
+}
+
+static void card_changed(struct userdata *u, struct udev_device *dev) {
+ struct device *d;
+ const char *path;
+ const char *t;
+ char *n;
+
+ pa_assert(u);
+ pa_assert(dev);
+
+ /* Maybe /dev/snd is now available? */
+ setup_inotify(u);
+
+ path = udev_device_get_devpath(dev);
+
+ if ((d = pa_hashmap_get(u->devices, path))) {
+ verify_access(u, d);
+ return;
+ }
+
+ d = pa_xnew0(struct device, 1);
+ d->path = pa_xstrdup(path);
+ d->module = PA_INVALID_INDEX;
+ PA_INIT_RATELIMIT(d->ratelimit, 10*PA_USEC_PER_SEC, 5);
+
+ if (!(t = udev_device_get_property_value(dev, "PULSE_NAME")))
+ if (!(t = udev_device_get_property_value(dev, "ID_ID")))
+ if (!(t = udev_device_get_property_value(dev, "ID_PATH")))
+ t = path_get_card_id(path);
+
+ n = pa_namereg_make_valid_name(t);
+ d->card_name = pa_sprintf_malloc("alsa_card.%s", n);
+ d->args = pa_sprintf_malloc("device_id=\"%s\" "
+ "name=\"%s\" "
+ "card_name=\"%s\" "
+ "namereg_fail=false "
+ "tsched=%s "
+ "ignore_dB=%s "
+ "sync_volume=%s "
+ "card_properties=\"module-udev-detect.discovered=1\"",
+ path_get_card_id(path),
+ n,
+ d->card_name,
+ pa_yes_no(u->use_tsched),
+ pa_yes_no(u->ignore_dB),
+ pa_yes_no(u->sync_volume));
+ pa_xfree(n);
+
+ pa_hashmap_put(u->devices, d->path, d);
+
+ verify_access(u, d);
+}
+
+static void remove_card(struct userdata *u, struct udev_device *dev) {
+ struct device *d;
+
+ pa_assert(u);
+ pa_assert(dev);
+
+ if (!(d = pa_hashmap_remove(u->devices, udev_device_get_devpath(dev))))
+ return;
+
+ pa_log_info("Card %s removed.", d->path);
+
+ if (d->module != PA_INVALID_INDEX)
+ pa_module_unload_request_by_index(u->core, d->module, TRUE);
+
+ device_free(d);
+}
+
+static void process_device(struct userdata *u, struct udev_device *dev) {
+ const char *action, *ff;
+
+ pa_assert(u);
+ pa_assert(dev);
+
+ if (udev_device_get_property_value(dev, "PULSE_IGNORE")) {
+ pa_log_debug("Ignoring %s, because marked so.", udev_device_get_devpath(dev));
+ return;
+ }
+
+ if ((ff = udev_device_get_property_value(dev, "SOUND_CLASS")) &&
+ pa_streq(ff, "modem")) {
+ pa_log_debug("Ignoring %s, because it is a modem.", udev_device_get_devpath(dev));
+ return;
+ }
+
+ action = udev_device_get_action(dev);
+
+ if (action && pa_streq(action, "remove"))
+ remove_card(u, dev);
+ else if ((!action || pa_streq(action, "change")) && udev_device_get_property_value(dev, "SOUND_INITIALIZED"))
+ card_changed(u, dev);
+
+ /* For an explanation why we don't look for 'add' events here
+ * have a look into /lib/udev/rules.d/78-sound-card.rules! */
+}
+
+static void process_path(struct userdata *u, const char *path) {
+ struct udev_device *dev;
+
+ if (!path_get_card_id(path))
+ return;
+
+ if (!(dev = udev_device_new_from_syspath(u->udev, path))) {
+ pa_log("Failed to get udev device object from udev.");
+ return;
+ }
+
+ process_device(u, dev);
+ udev_device_unref(dev);
+}
+
+static void monitor_cb(
+ pa_mainloop_api*a,
+ pa_io_event* e,
+ int fd,
+ pa_io_event_flags_t events,
+ void *userdata) {
+
+ struct userdata *u = userdata;
+ struct udev_device *dev;
+
+ pa_assert(a);
+
+ if (!(dev = udev_monitor_receive_device(u->monitor))) {
+ pa_log("Failed to get udev device object from monitor.");
+ goto fail;
+ }
+
+ if (!path_get_card_id(udev_device_get_devpath(dev))) {
+ udev_device_unref(dev);
+ return;
+ }
+
+ process_device(u, dev);
+ udev_device_unref(dev);
+ return;
+
+fail:
+ a->io_free(u->udev_io);
+ u->udev_io = NULL;
+}
+
+static pa_bool_t pcm_node_belongs_to_device(
+ struct device *d,
+ const char *node) {
+
+ char *cd;
+ pa_bool_t b;
+
+ cd = pa_sprintf_malloc("pcmC%sD", path_get_card_id(d->path));
+ b = pa_startswith(node, cd);
+ pa_xfree(cd);
+
+ return b;
+}
+
+static pa_bool_t control_node_belongs_to_device(
+ struct device *d,
+ const char *node) {
+
+ char *cd;
+ pa_bool_t b;
+
+ cd = pa_sprintf_malloc("controlC%s", path_get_card_id(d->path));
+ b = pa_streq(node, cd);
+ pa_xfree(cd);
+
+ return b;
+}
+
+static void inotify_cb(
+ pa_mainloop_api*a,
+ pa_io_event* e,
+ int fd,
+ pa_io_event_flags_t events,
+ void *userdata) {
+
+ struct {
+ struct inotify_event e;
+ char name[NAME_MAX];
+ } buf;
+ struct userdata *u = userdata;
+ static int type = 0;
+ pa_bool_t deleted = FALSE;
+ struct device *d;
+ void *state;
+
+ for (;;) {
+ ssize_t r;
+ struct inotify_event *event;
+
+ pa_zero(buf);
+ if ((r = pa_read(fd, &buf, sizeof(buf), &type)) <= 0) {
+
+ if (r < 0 && errno == EAGAIN)
+ break;
+
+ pa_log("read() from inotify failed: %s", r < 0 ? pa_cstrerror(errno) : "EOF");
+ goto fail;
+ }
+
+ event = &buf.e;
+ while (r > 0) {
+ size_t len;
+
+ if ((size_t) r < sizeof(struct inotify_event)) {
+ pa_log("read() too short.");
+ goto fail;
+ }
+
+ len = sizeof(struct inotify_event) + event->len;
+
+ if ((size_t) r < len) {
+ pa_log("Payload missing.");
+ goto fail;
+ }
+
+ /* From udev we get the guarantee that the control
+ * device's ACL is changed last. To avoid races when ACLs
+ * are changed we hence watch only the control device */
+ if (((event->mask & IN_ATTRIB) && pa_startswith(event->name, "controlC")))
+ PA_HASHMAP_FOREACH(d, u->devices, state)
+ if (control_node_belongs_to_device(d, event->name))
+ d->need_verify = TRUE;
+
+ /* ALSA doesn't really give us any guarantee on the closing
+ * order, so let's simply hope */
+ if (((event->mask & IN_CLOSE_WRITE) && pa_startswith(event->name, "pcmC")))
+ PA_HASHMAP_FOREACH(d, u->devices, state)
+ if (pcm_node_belongs_to_device(d, event->name))
+ d->need_verify = TRUE;
+
+ /* /dev/snd/ might have been removed */
+ if ((event->mask & (IN_DELETE_SELF|IN_MOVE_SELF)))
+ deleted = TRUE;
+
+ event = (struct inotify_event*) ((uint8_t*) event + len);
+ r -= len;
+ }
+ }
+
+ PA_HASHMAP_FOREACH(d, u->devices, state)
+ if (d->need_verify) {
+ d->need_verify = FALSE;
+ verify_access(u, d);
+ }
+
+ if (!deleted)
+ return;
+
+fail:
+ if (u->inotify_io) {
+ a->io_free(u->inotify_io);
+ u->inotify_io = NULL;
+ }
+
+ if (u->inotify_fd >= 0) {
+ pa_close(u->inotify_fd);
+ u->inotify_fd = -1;
+ }
+}
+
+static int setup_inotify(struct userdata *u) {
+ char *dev_snd;
+ int r;
+
+ if (u->inotify_fd >= 0)
+ return 0;
+
+ if ((u->inotify_fd = inotify_init1(IN_CLOEXEC|IN_NONBLOCK)) < 0) {
+ pa_log("inotify_init1() failed: %s", pa_cstrerror(errno));
+ return -1;
+ }
+
+ dev_snd = pa_sprintf_malloc("%s/snd", udev_get_dev_path(u->udev));
+ r = inotify_add_watch(u->inotify_fd, dev_snd, IN_ATTRIB|IN_CLOSE_WRITE|IN_DELETE_SELF|IN_MOVE_SELF);
+ pa_xfree(dev_snd);
+
+ if (r < 0) {
+ int saved_errno = errno;
+
+ pa_close(u->inotify_fd);
+ u->inotify_fd = -1;
+
+ if (saved_errno == ENOENT) {
+ pa_log_debug("/dev/snd/ is apparently not existing yet, retrying to create inotify watch later.");
+ return 0;
+ }
+
+ if (saved_errno == ENOSPC) {
+ pa_log("You apparently ran out of inotify watches, probably because Tracker/Beagle took them all away. "
+ "I wished people would do their homework first and fix inotify before using it for watching whole "
+ "directory trees which is something the current inotify is certainly not useful for. "
+ "Please make sure to drop the Tracker/Beagle guys a line complaining about their broken use of inotify.");
+ return 0;
+ }
+
+ pa_log("inotify_add_watch() failed: %s", pa_cstrerror(saved_errno));
+ return -1;
+ }
+
+ pa_assert_se(u->inotify_io = u->core->mainloop->io_new(u->core->mainloop, u->inotify_fd, PA_IO_EVENT_INPUT, inotify_cb, u));
+
+ return 0;
+}
+
+int pa__init(pa_module *m) {
+ struct userdata *u = NULL;
+ pa_modargs *ma;
+ struct udev_enumerate *enumerate = NULL;
+ struct udev_list_entry *item = NULL, *first = NULL;
+ int fd;
+ pa_bool_t use_tsched = TRUE, ignore_dB = FALSE, sync_volume = m->core->sync_volume;
+
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments");
+ goto fail;
+ }
+
+ m->userdata = u = pa_xnew0(struct userdata, 1);
+ u->core = m->core;
+ u->devices = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ u->inotify_fd = -1;
+
+ if (pa_modargs_get_value_boolean(ma, "tsched", &use_tsched) < 0) {
+ pa_log("Failed to parse tsched= argument.");
+ goto fail;
+ }
+ u->use_tsched = use_tsched;
+
+ if (pa_modargs_get_value_boolean(ma, "ignore_dB", &ignore_dB) < 0) {
+ pa_log("Failed to parse ignore_dB= argument.");
+ goto fail;
+ }
+ u->ignore_dB = ignore_dB;
+
+ if (pa_modargs_get_value_boolean(ma, "sync_volume", &sync_volume) < 0) {
+ pa_log("Failed to parse sync_volume= argument.");
+ goto fail;
+ }
+ u->sync_volume = sync_volume;
+
+ if (!(u->udev = udev_new())) {
+ pa_log("Failed to initialize udev library.");
+ goto fail;
+ }
+
+ if (setup_inotify(u) < 0)
+ goto fail;
+
+ if (!(u->monitor = udev_monitor_new_from_netlink(u->udev, "udev"))) {
+ pa_log("Failed to initialize monitor.");
+ goto fail;
+ }
+
+ if (udev_monitor_filter_add_match_subsystem_devtype(u->monitor, "sound", NULL) < 0) {
+ pa_log("Failed to subscribe to sound devices.");
+ goto fail;
+ }
+
+ errno = 0;
+ if (udev_monitor_enable_receiving(u->monitor) < 0) {
+ pa_log("Failed to enable monitor: %s", pa_cstrerror(errno));
+ if (errno == EPERM)
+ pa_log_info("Most likely your kernel is simply too old and "
+ "allows only priviliged processes to listen to device events. "
+ "Please upgrade your kernel to at least 2.6.30.");
+ goto fail;
+ }
+
+ if ((fd = udev_monitor_get_fd(u->monitor)) < 0) {
+ pa_log("Failed to get udev monitor fd.");
+ goto fail;
+ }
+
+ pa_assert_se(u->udev_io = u->core->mainloop->io_new(u->core->mainloop, fd, PA_IO_EVENT_INPUT, monitor_cb, u));
+
+ if (!(enumerate = udev_enumerate_new(u->udev))) {
+ pa_log("Failed to initialize udev enumerator.");
+ goto fail;
+ }
+
+ if (udev_enumerate_add_match_subsystem(enumerate, "sound") < 0) {
+ pa_log("Failed to match to subsystem.");
+ goto fail;
+ }
+
+ if (udev_enumerate_scan_devices(enumerate) < 0) {
+ pa_log("Failed to scan for devices.");
+ goto fail;
+ }
+
+ first = udev_enumerate_get_list_entry(enumerate);
+ udev_list_entry_foreach(item, first)
+ process_path(u, udev_list_entry_get_name(item));
+
+ udev_enumerate_unref(enumerate);
+
+ pa_log_info("Found %u cards.", pa_hashmap_size(u->devices));
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+
+ if (enumerate)
+ udev_enumerate_unref(enumerate);
+
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+void pa__done(pa_module *m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ if (u->udev_io)
+ m->core->mainloop->io_free(u->udev_io);
+
+ if (u->monitor)
+ udev_monitor_unref(u->monitor);
+
+ if (u->udev)
+ udev_unref(u->udev);
+
+ if (u->inotify_io)
+ m->core->mainloop->io_free(u->inotify_io);
+
+ if (u->inotify_fd >= 0)
+ pa_close(u->inotify_fd);
+
+ if (u->devices) {
+ struct device *d;
+
+ while ((d = pa_hashmap_steal_first(u->devices)))
+ device_free(d);
+
+ pa_hashmap_free(u->devices, NULL, NULL);
+ }
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-virtual-sink.c b/src/modules/module-virtual-sink.c
new file mode 100644
index 00000000..a6be2446
--- /dev/null
+++ b/src/modules/module-virtual-sink.c
@@ -0,0 +1,669 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Intel Corporation
+ Contributor: Pierre-Louis Bossart <pierre-louis.bossart@intel.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+/* TODO: Some plugins cause latency, and some even report it by using a control
+ out port. We don't currently use the latency information. */
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/gccmacro.h>
+#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
+
+#include <pulsecore/namereg.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/module.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/rtpoll.h>
+#include <pulsecore/sample-util.h>
+#include <pulsecore/ltdl-helper.h>
+
+#include "module-virtual-sink-symdef.h"
+
+PA_MODULE_AUTHOR("Pierre-Louis Bossart");
+PA_MODULE_DESCRIPTION(_("Virtual sink"));
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE(
+ _("sink_name=<name for the sink> "
+ "sink_properties=<properties for the sink> "
+ "master=<name of sink to filter> "
+ "format=<sample format> "
+ "rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<channel map> "
+ "use_volume_sharing=<yes or no> "
+ "force_flat_volume=<yes or no> "
+ ));
+
+#define MEMBLOCKQ_MAXLENGTH (16*1024*1024)
+
+struct userdata {
+ pa_module *module;
+
+ /* FIXME: Uncomment this and take "autoloaded" as a modarg if this is a filter */
+ /* pa_bool_t autoloaded; */
+
+ pa_sink *sink;
+ pa_sink_input *sink_input;
+
+ pa_memblockq *memblockq;
+
+ pa_bool_t auto_desc;
+ unsigned channels;
+};
+
+static const char* const valid_modargs[] = {
+ "sink_name",
+ "sink_properties",
+ "master",
+ "format",
+ "rate",
+ "channels",
+ "channel_map",
+ "use_volume_sharing",
+ "force_flat_volume",
+ NULL
+};
+
+/* Called from I/O thread context */
+static int sink_process_msg_cb(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SINK(o)->userdata;
+
+ switch (code) {
+
+ case PA_SINK_MESSAGE_GET_LATENCY:
+
+ /* The sink is _put() before the sink input is, so let's
+ * make sure we don't access it in that time. Also, the
+ * sink input is first shut down, the sink second. */
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state)) {
+ *((pa_usec_t*) data) = 0;
+ return 0;
+ }
+
+ *((pa_usec_t*) data) =
+
+ /* Get the latency of the master sink */
+ pa_sink_get_latency_within_thread(u->sink_input->sink) +
+
+ /* Add the latency internal to our sink input on top */
+ pa_bytes_to_usec(pa_memblockq_get_length(u->sink_input->thread_info.render_memblockq), &u->sink_input->sink->sample_spec);
+
+ return 0;
+ }
+
+ return pa_sink_process_msg(o, code, data, offset, chunk);
+}
+
+/* Called from main context */
+static int sink_set_state_cb(pa_sink *s, pa_sink_state_t state) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(state) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return 0;
+
+ pa_sink_input_cork(u->sink_input, state == PA_SINK_SUSPENDED);
+ return 0;
+}
+
+/* Called from I/O thread context */
+static void sink_request_rewind_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
+ /* Just hand this one over to the master sink */
+ pa_sink_input_request_rewind(u->sink_input,
+ s->thread_info.rewind_nbytes +
+ pa_memblockq_get_length(u->memblockq), TRUE, FALSE, FALSE);
+}
+
+/* Called from I/O thread context */
+static void sink_update_requested_latency_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(u->sink->thread_info.state) ||
+ !PA_SINK_INPUT_IS_LINKED(u->sink_input->thread_info.state))
+ return;
+
+ /* Just hand this one over to the master sink */
+ pa_sink_input_set_requested_latency_within_thread(
+ u->sink_input,
+ pa_sink_get_requested_latency_within_thread(s));
+}
+
+/* Called from main context */
+static void sink_set_volume_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_volume(u->sink_input, &s->real_volume, s->save_volume, TRUE);
+}
+
+/* Called from main context */
+static void sink_set_mute_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(pa_sink_get_state(s)) ||
+ !PA_SINK_INPUT_IS_LINKED(pa_sink_input_get_state(u->sink_input)))
+ return;
+
+ pa_sink_input_set_mute(u->sink_input, s->muted, s->save_muted);
+}
+
+/* Called from I/O thread context */
+static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk) {
+ struct userdata *u;
+ float *src, *dst;
+ size_t fs;
+ unsigned n, c;
+ pa_memchunk tchunk;
+ pa_usec_t current_latency PA_GCC_UNUSED;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert(chunk);
+ pa_assert_se(u = i->userdata);
+
+ /* Hmm, process any rewind request that might be queued up */
+ pa_sink_process_rewind(u->sink, 0);
+
+ /* (1) IF YOU NEED A FIXED BLOCK SIZE USE
+ * pa_memblockq_peek_fixed_size() HERE INSTEAD. NOTE THAT FILTERS
+ * WHICH CAN DEAL WITH DYNAMIC BLOCK SIZES ARE HIGHLY
+ * PREFERRED. */
+ while (pa_memblockq_peek(u->memblockq, &tchunk) < 0) {
+ pa_memchunk nchunk;
+
+ pa_sink_render(u->sink, nbytes, &nchunk);
+ pa_memblockq_push(u->memblockq, &nchunk);
+ pa_memblock_unref(nchunk.memblock);
+ }
+
+ /* (2) IF YOU NEED A FIXED BLOCK SIZE, THIS NEXT LINE IS NOT
+ * NECESSARY */
+ tchunk.length = PA_MIN(nbytes, tchunk.length);
+ pa_assert(tchunk.length > 0);
+
+ fs = pa_frame_size(&i->sample_spec);
+ n = (unsigned) (tchunk.length / fs);
+
+ pa_assert(n > 0);
+
+ chunk->index = 0;
+ chunk->length = n*fs;
+ chunk->memblock = pa_memblock_new(i->sink->core->mempool, chunk->length);
+
+ pa_memblockq_drop(u->memblockq, chunk->length);
+
+ src = (float*) ((uint8_t*) pa_memblock_acquire(tchunk.memblock) + tchunk.index);
+ dst = (float*) pa_memblock_acquire(chunk->memblock);
+
+ /* (3) PUT YOUR CODE HERE TO DO SOMETHING WITH THE DATA */
+
+ /* As an example, copy input to output */
+ for (c = 0; c < u->channels; c++) {
+ pa_sample_clamp(PA_SAMPLE_FLOAT32NE,
+ dst+c, u->channels * sizeof(float),
+ src+c, u->channels * sizeof(float),
+ n);
+ }
+
+ pa_memblock_release(tchunk.memblock);
+ pa_memblock_release(chunk->memblock);
+
+ pa_memblock_unref(tchunk.memblock);
+
+ /* (4) IF YOU NEED THE LATENCY FOR SOMETHING ACQUIRE IT LIKE THIS: */
+ current_latency =
+ /* Get the latency of the master sink */
+ pa_sink_get_latency_within_thread(i->sink) +
+
+ /* Add the latency internal to our sink input on top */
+ pa_bytes_to_usec(pa_memblockq_get_length(i->thread_info.render_memblockq), &i->sink->sample_spec);
+
+ return 0;
+}
+
+/* Called from I/O thread context */
+static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+ size_t amount = 0;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ if (u->sink->thread_info.rewind_nbytes > 0) {
+ size_t max_rewrite;
+
+ max_rewrite = nbytes + pa_memblockq_get_length(u->memblockq);
+ amount = PA_MIN(u->sink->thread_info.rewind_nbytes, max_rewrite);
+ u->sink->thread_info.rewind_nbytes = 0;
+
+ if (amount > 0) {
+ pa_memblockq_seek(u->memblockq, - (int64_t) amount, PA_SEEK_RELATIVE, TRUE);
+
+ /* (5) PUT YOUR CODE HERE TO RESET YOUR FILTER */
+ }
+ }
+
+ pa_sink_process_rewind(u->sink, amount);
+ pa_memblockq_rewind(u->memblockq, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_rewind_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_memblockq_set_maxrewind(u->memblockq, nbytes);
+ pa_sink_set_max_rewind_within_thread(u->sink, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_max_request_cb(pa_sink_input *i, size_t nbytes) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ /* (6) IF YOU NEED A FIXED BLOCK SIZE ROUND nbytes UP TO MULTIPLES
+ * OF IT HERE. THE PA_ROUND_UP MACRO IS USEFUL FOR THAT. */
+
+ pa_sink_set_max_request_within_thread(u->sink, nbytes);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_sink_latency_range_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_update_sink_fixed_latency_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ /* (7) IF YOU NEED A FIXED BLOCK SIZE ADD THE LATENCY FOR ONE
+ * BLOCK MINUS ONE SAMPLE HERE. pa_usec_to_bytes_round_up() IS
+ * USEFUL FOR THAT. */
+
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+}
+
+/* Called from I/O thread context */
+static void sink_input_detach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_detach_within_thread(u->sink);
+
+ pa_sink_set_rtpoll(u->sink, NULL);
+}
+
+/* Called from I/O thread context */
+static void sink_input_attach_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_set_rtpoll(u->sink, i->sink->thread_info.rtpoll);
+ pa_sink_set_latency_range_within_thread(u->sink, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
+
+ /* (8.1) IF YOU NEED A FIXED BLOCK SIZE ADD THE LATENCY FOR ONE
+ * BLOCK MINUS ONE SAMPLE HERE. SEE (7) */
+ pa_sink_set_fixed_latency_within_thread(u->sink, i->sink->thread_info.fixed_latency);
+
+ /* (8.2) IF YOU NEED A FIXED BLOCK SIZE ROUND
+ * pa_sink_input_get_max_request(i) UP TO MULTIPLES OF IT
+ * HERE. SEE (6) */
+ pa_sink_set_max_request_within_thread(u->sink, pa_sink_input_get_max_request(i));
+ pa_sink_set_max_rewind_within_thread(u->sink, pa_sink_input_get_max_rewind(i));
+
+ pa_sink_attach_within_thread(u->sink);
+}
+
+/* Called from main context */
+static void sink_input_kill_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ /* The order here matters! We first kill the sink input, followed
+ * by the sink. That means the sink callbacks must be protected
+ * against an unconnected sink input! */
+ pa_sink_input_unlink(u->sink_input);
+ pa_sink_unlink(u->sink);
+
+ pa_sink_input_unref(u->sink_input);
+ u->sink_input = NULL;
+
+ pa_sink_unref(u->sink);
+ u->sink = NULL;
+
+ pa_module_unload_request(u->module, TRUE);
+}
+
+/* Called from IO thread context */
+static void sink_input_state_change_cb(pa_sink_input *i, pa_sink_input_state_t state) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ /* If we are added for the first time, ask for a rewinding so that
+ * we are heard right-away. */
+ if (PA_SINK_INPUT_IS_LINKED(state) &&
+ i->thread_info.state == PA_SINK_INPUT_INIT) {
+ pa_log_debug("Requesting rewind due to state change.");
+ pa_sink_input_request_rewind(i, 0, FALSE, TRUE, TRUE);
+ }
+}
+
+/* Called from main context */
+static pa_bool_t sink_input_may_move_to_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ return u->sink != dest;
+}
+
+/* Called from main context */
+static void sink_input_moving_cb(pa_sink_input *i, pa_sink *dest) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ if (dest) {
+ pa_sink_set_asyncmsgq(u->sink, dest->asyncmsgq);
+ pa_sink_update_flags(u->sink, PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY, dest->flags);
+ } else
+ pa_sink_set_asyncmsgq(u->sink, NULL);
+
+ if (u->auto_desc && dest) {
+ const char *z;
+ pa_proplist *pl;
+
+ pl = pa_proplist_new();
+ z = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(pl, PA_PROP_DEVICE_DESCRIPTION, "Virtual Sink %s on %s",
+ pa_proplist_gets(u->sink->proplist, "device.vsink.name"), z ? z : dest->name);
+
+ pa_sink_update_proplist(u->sink, PA_UPDATE_REPLACE, pl);
+ pa_proplist_free(pl);
+ }
+}
+
+/* Called from main context */
+static void sink_input_volume_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_volume_changed(u->sink, &i->volume);
+}
+
+/* Called from main context */
+static void sink_input_mute_changed_cb(pa_sink_input *i) {
+ struct userdata *u;
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_se(u = i->userdata);
+
+ pa_sink_mute_changed(u->sink, i->muted);
+}
+
+int pa__init(pa_module*m) {
+ struct userdata *u;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ pa_modargs *ma;
+ pa_sink *master=NULL;
+ pa_sink_input_new_data sink_input_data;
+ pa_sink_new_data sink_data;
+ pa_bool_t use_volume_sharing = FALSE;
+ pa_bool_t force_flat_volume = FALSE;
+ pa_memchunk silence;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ if (!(master = pa_namereg_get(m->core, pa_modargs_get_value(ma, "master", NULL), PA_NAMEREG_SINK))) {
+ pa_log("Master sink not found");
+ goto fail;
+ }
+
+ pa_assert(master);
+
+ ss = master->sample_spec;
+ ss.format = PA_SAMPLE_FLOAT32;
+ map = master->channel_map;
+ if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_DEFAULT) < 0) {
+ pa_log("Invalid sample format specification or channel map");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "use_volume_sharing", &use_volume_sharing) < 0) {
+ pa_log("use_volume_sharing= expects a boolean argument");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "force_flat_volume", &force_flat_volume) < 0) {
+ pa_log("force_flat_volume= expects a boolean argument");
+ goto fail;
+ }
+
+ if (use_volume_sharing && force_flat_volume) {
+ pa_log("Flat volume can't be forced when using volume sharing.");
+ goto fail;
+ }
+
+ u = pa_xnew0(struct userdata, 1);
+ u->module = m;
+ m->userdata = u;
+ u->channels = ss.channels;
+
+ /* Create sink */
+ pa_sink_new_data_init(&sink_data);
+ sink_data.driver = __FILE__;
+ sink_data.module = m;
+ if (!(sink_data.name = pa_xstrdup(pa_modargs_get_value(ma, "sink_name", NULL))))
+ sink_data.name = pa_sprintf_malloc("%s.vsink", master->name);
+ pa_sink_new_data_set_sample_spec(&sink_data, &ss);
+ pa_sink_new_data_set_channel_map(&sink_data, &map);
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, master->name);
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_CLASS, "filter");
+ pa_proplist_sets(sink_data.proplist, "device.vsink.name", sink_data.name);
+
+ if (pa_modargs_get_proplist(ma, "sink_properties", sink_data.proplist, PA_UPDATE_REPLACE) < 0) {
+ pa_log("Invalid properties");
+ pa_sink_new_data_done(&sink_data);
+ goto fail;
+ }
+
+ if ((u->auto_desc = !pa_proplist_contains(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ const char *z;
+
+ z = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Virtual Sink %s on %s", sink_data.name, z ? z : master->name);
+ }
+
+ u->sink = pa_sink_new(m->core, &sink_data, (master->flags & (PA_SINK_LATENCY|PA_SINK_DYNAMIC_LATENCY))
+ | (use_volume_sharing ? PA_SINK_SHARE_VOLUME_WITH_MASTER : 0)
+ | (force_flat_volume ? PA_SINK_FLAT_VOLUME : 0));
+ pa_sink_new_data_done(&sink_data);
+
+ if (!u->sink) {
+ pa_log("Failed to create sink.");
+ goto fail;
+ }
+
+ u->sink->parent.process_msg = sink_process_msg_cb;
+ u->sink->set_state = sink_set_state_cb;
+ u->sink->update_requested_latency = sink_update_requested_latency_cb;
+ u->sink->request_rewind = sink_request_rewind_cb;
+ u->sink->set_volume = use_volume_sharing ? NULL : sink_set_volume_cb;
+ u->sink->set_mute = sink_set_mute_cb;
+ u->sink->userdata = u;
+
+ pa_sink_set_asyncmsgq(u->sink, master->asyncmsgq);
+
+ /* Create sink input */
+ pa_sink_input_new_data_init(&sink_input_data);
+ sink_input_data.driver = __FILE__;
+ sink_input_data.module = m;
+ pa_sink_input_new_data_set_sink(&sink_input_data, master, FALSE);
+ sink_input_data.origin_sink = u->sink;
+ pa_proplist_setf(sink_input_data.proplist, PA_PROP_MEDIA_NAME, "Virtual Sink Stream from %s", pa_proplist_gets(u->sink->proplist, PA_PROP_DEVICE_DESCRIPTION));
+ pa_proplist_sets(sink_input_data.proplist, PA_PROP_MEDIA_ROLE, "filter");
+ pa_sink_input_new_data_set_sample_spec(&sink_input_data, &ss);
+ pa_sink_input_new_data_set_channel_map(&sink_input_data, &map);
+
+ pa_sink_input_new(&u->sink_input, m->core, &sink_input_data);
+ pa_sink_input_new_data_done(&sink_input_data);
+
+ if (!u->sink_input)
+ goto fail;
+
+ u->sink_input->pop = sink_input_pop_cb;
+ u->sink_input->process_rewind = sink_input_process_rewind_cb;
+ u->sink_input->update_max_rewind = sink_input_update_max_rewind_cb;
+ u->sink_input->update_max_request = sink_input_update_max_request_cb;
+ u->sink_input->update_sink_latency_range = sink_input_update_sink_latency_range_cb;
+ u->sink_input->update_sink_fixed_latency = sink_input_update_sink_fixed_latency_cb;
+ u->sink_input->kill = sink_input_kill_cb;
+ u->sink_input->attach = sink_input_attach_cb;
+ u->sink_input->detach = sink_input_detach_cb;
+ u->sink_input->state_change = sink_input_state_change_cb;
+ u->sink_input->may_move_to = sink_input_may_move_to_cb;
+ u->sink_input->moving = sink_input_moving_cb;
+ u->sink_input->volume_changed = use_volume_sharing ? NULL : sink_input_volume_changed_cb;
+ u->sink_input->mute_changed = sink_input_mute_changed_cb;
+ u->sink_input->userdata = u;
+
+ u->sink->input_to_master = u->sink_input;
+
+ pa_sink_input_get_silence(u->sink_input, &silence);
+ u->memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, pa_frame_size(&ss), 1, 1, 0, &silence);
+ pa_memblock_unref(silence.memblock);
+
+ /* (9) INITIALIZE ANYTHING ELSE YOU NEED HERE */
+
+ pa_sink_put(u->sink);
+ pa_sink_input_put(u->sink_input);
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+int pa__get_n_used(pa_module *m) {
+ struct userdata *u;
+
+ pa_assert(m);
+ pa_assert_se(u = m->userdata);
+
+ return pa_sink_linked_by(u->sink);
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ /* See comments in sink_input_kill_cb() above regarding
+ * destruction order! */
+
+ if (u->sink_input)
+ pa_sink_input_unlink(u->sink_input);
+
+ if (u->sink)
+ pa_sink_unlink(u->sink);
+
+ if (u->sink_input)
+ pa_sink_input_unref(u->sink_input);
+
+ if (u->sink)
+ pa_sink_unref(u->sink);
+
+ if (u->memblockq)
+ pa_memblockq_free(u->memblockq);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-virtual-source.c b/src/modules/module-virtual-source.c
new file mode 100644
index 00000000..e15f4b94
--- /dev/null
+++ b/src/modules/module-virtual-source.c
@@ -0,0 +1,746 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Intel Corporation
+ Contributor: Pierre-Louis Bossart <pierre-louis.bossart@intel.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdio.h>
+
+#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
+
+#include <pulsecore/macro.h>
+#include <pulsecore/namereg.h>
+#include <pulsecore/sink.h>
+#include <pulsecore/module.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/modargs.h>
+#include <pulsecore/log.h>
+#include <pulsecore/rtpoll.h>
+#include <pulsecore/sample-util.h>
+#include <pulsecore/ltdl-helper.h>
+
+#include "module-virtual-source-symdef.h"
+
+PA_MODULE_AUTHOR("Pierre-Louis Bossart");
+PA_MODULE_DESCRIPTION("Virtual source");
+PA_MODULE_VERSION(PACKAGE_VERSION);
+PA_MODULE_LOAD_ONCE(FALSE);
+PA_MODULE_USAGE(
+ _("source_name=<name for the source> "
+ "source_properties=<properties for the source> "
+ "master=<name of source to filter> "
+ "uplink_sink=<name> (optional)"
+ "format=<sample format> "
+ "rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<channel map> "
+ "use_volume_sharing=<yes or no> "
+ "force_flat_volume=<yes or no> "
+ ));
+
+#define MEMBLOCKQ_MAXLENGTH (16*1024*1024)
+#define BLOCK_USEC 1000 /* FIXME */
+
+struct userdata {
+ pa_module *module;
+
+ /* FIXME: Uncomment this and take "autoloaded" as a modarg if this is a filter */
+ /* pa_bool_t autoloaded; */
+
+ pa_source *source;
+ pa_source_output *source_output;
+
+ pa_memblockq *memblockq;
+
+ pa_bool_t auto_desc;
+ unsigned channels;
+
+ /* optional fields for uplink sink */
+ pa_sink *sink;
+ pa_usec_t block_usec;
+ pa_memblockq *sink_memblockq;
+
+};
+
+static const char* const valid_modargs[] = {
+ "source_name",
+ "source_properties",
+ "master",
+ "uplink_sink",
+ "format",
+ "rate",
+ "channels",
+ "channel_map",
+ "use_volume_sharing",
+ "force_flat_volume",
+ NULL
+};
+
+/* Called from I/O thread context */
+static int sink_process_msg_cb(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+
+ switch (code) {
+
+ case PA_SINK_MESSAGE_GET_LATENCY:
+
+ /* there's no real latency here */
+ *((pa_usec_t*) data) = 0;
+
+ return 0;
+ }
+
+ return pa_sink_process_msg(o, code, data, offset, chunk);
+}
+
+/* Called from main context */
+static int sink_set_state_cb(pa_sink *s, pa_sink_state_t state) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SINK_IS_LINKED(state)) {
+ return 0;
+ }
+
+ if (state == PA_SINK_RUNNING) {
+ /* need to wake-up source if it was suspended */
+ pa_source_suspend(u->source, FALSE, PA_SUSPEND_ALL);
+
+ /* FIXME: if there's no client connected, the source will suspend
+ and playback will be stuck. You'd want to prevent the source from
+ sleeping when the uplink sink is active; even if the audio is
+ discarded at least the app isn't stuck */
+
+ } else {
+ /* nothing to do, if the sink becomes idle or suspended let
+ module-suspend-idle handle the sources later */
+ }
+
+ return 0;
+}
+
+static void sink_update_requested_latency_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ /* FIXME: there's no latency support */
+
+}
+
+
+/* Called from I/O thread context */
+static void sink_request_rewind_cb(pa_sink *s) {
+ struct userdata *u;
+
+ pa_sink_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ /* Do nothing */
+ pa_sink_process_rewind(u->sink, 0);
+
+}
+
+/* Called from I/O thread context */
+static int source_process_msg_cb(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u = PA_SOURCE(o)->userdata;
+
+ switch (code) {
+
+ case PA_SOURCE_MESSAGE_GET_LATENCY:
+
+ /* The source is _put() before the source output is, so let's
+ * make sure we don't access it in that time. Also, the
+ * source output is first shut down, the source second. */
+ if (!PA_SOURCE_IS_LINKED(u->source->thread_info.state) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(u->source_output->thread_info.state)) {
+ *((pa_usec_t*) data) = 0;
+ return 0;
+ }
+
+ *((pa_usec_t*) data) =
+
+ /* Get the latency of the master source */
+ pa_source_get_latency_within_thread(u->source_output->source) +
+
+ /* Add the latency internal to our source output on top */
+ /* FIXME, no idea what I am doing here */
+ pa_bytes_to_usec(pa_memblockq_get_length(u->source_output->thread_info.delay_memblockq), &u->source_output->source->sample_spec);
+
+ return 0;
+ }
+
+ return pa_source_process_msg(o, code, data, offset, chunk);
+}
+
+/* Called from main context */
+static int source_set_state_cb(pa_source *s, pa_source_state_t state) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(state) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return 0;
+
+ pa_source_output_cork(u->source_output, state == PA_SOURCE_SUSPENDED);
+ return 0;
+}
+
+/* Called from I/O thread context */
+static void source_update_requested_latency_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(u->source->thread_info.state) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(u->source_output->thread_info.state))
+ return;
+
+ /* Just hand this one over to the master source */
+ pa_source_output_set_requested_latency_within_thread(
+ u->source_output,
+ pa_source_get_requested_latency_within_thread(s));
+}
+
+/* Called from main context */
+static void source_set_volume_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(s)) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return;
+
+ pa_source_output_set_volume(u->source_output, &s->real_volume, s->save_volume, TRUE);
+}
+
+/* Called from main context */
+static void source_set_mute_cb(pa_source *s) {
+ struct userdata *u;
+
+ pa_source_assert_ref(s);
+ pa_assert_se(u = s->userdata);
+
+ if (!PA_SOURCE_IS_LINKED(pa_source_get_state(s)) ||
+ !PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output)))
+ return;
+
+ pa_source_output_set_mute(u->source_output, s->muted, s->save_muted);
+}
+
+/* Called from input thread context */
+static void source_output_push_cb(pa_source_output *o, const pa_memchunk *chunk) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ if (!PA_SOURCE_OUTPUT_IS_LINKED(pa_source_output_get_state(u->source_output))) {
+ pa_log("push when no link?");
+ return;
+ }
+
+ /* PUT YOUR CODE HERE TO DO SOMETHING WITH THE SOURCE DATA */
+
+ /* if uplink sink exists, pull data from there; simplify by using
+ same length as chunk provided by source */
+ if(u->sink && (pa_sink_get_state(u->sink) == PA_SINK_RUNNING)) {
+ pa_memchunk tchunk;
+ size_t nbytes = chunk->length;
+ pa_mix_info streams[2];
+ pa_memchunk target_chunk;
+ void *target;
+ int ch;
+
+ /* Hmm, process any rewind request that might be queued up */
+ pa_sink_process_rewind(u->sink, 0);
+
+ /* get data from the sink */
+ while (pa_memblockq_peek(u->sink_memblockq, &tchunk) < 0) {
+ pa_memchunk nchunk;
+
+ /* make sure we get nbytes from the sink with render_full,
+ otherwise we cannot mix with the uplink */
+ pa_sink_render_full(u->sink, nbytes, &nchunk);
+ pa_memblockq_push(u->sink_memblockq, &nchunk);
+ pa_memblock_unref(nchunk.memblock);
+ }
+ pa_assert(tchunk.length == chunk->length);
+
+ /* move the read pointer for sink memblockq */
+ pa_memblockq_drop(u->sink_memblockq, tchunk.length);
+
+ /* allocate target chunk */
+ /* this could probably be done in-place, but having chunk as both
+ the input and output creates issues with reference counts */
+ target_chunk.index = 0;
+ target_chunk.length = chunk->length;
+ pa_assert(target_chunk.length == chunk->length);
+
+ target_chunk.memblock = pa_memblock_new(o->source->core->mempool,
+ target_chunk.length);
+ pa_assert( target_chunk.memblock );
+
+ /* get target pointer */
+ target = (void*)((uint8_t*)pa_memblock_acquire(target_chunk.memblock)
+ + target_chunk.index);
+
+ /* set-up mixing structure
+ volume was taken care of in sink and source already */
+ streams[0].chunk = *chunk;
+ for(ch=0;ch<o->sample_spec.channels;ch++)
+ streams[0].volume.values[ch] = PA_VOLUME_NORM; /* FIXME */
+ streams[0].volume.channels = o->sample_spec.channels;
+
+ streams[1].chunk = tchunk;
+ for(ch=0;ch<o->sample_spec.channels;ch++)
+ streams[1].volume.values[ch] = PA_VOLUME_NORM; /* FIXME */
+ streams[1].volume.channels = o->sample_spec.channels;
+
+ /* do mixing */
+ pa_mix(streams, /* 2 streams to be mixed */
+ 2,
+ target, /* put result in target chunk */
+ chunk->length, /* same length as input */
+ (const pa_sample_spec *)&o->sample_spec, /* same sample spec for input and output */
+ NULL, /* no volume information */
+ FALSE); /* no mute */
+
+ pa_memblock_release(target_chunk.memblock);
+ pa_memblock_unref(tchunk.memblock); /* clean-up */
+
+ /* forward the data to the virtual source */
+ pa_source_post(u->source, &target_chunk);
+
+ pa_memblock_unref(target_chunk.memblock); /* clean-up */
+
+ } else {
+ /* forward the data to the virtual source */
+ pa_source_post(u->source, chunk);
+ }
+
+
+}
+
+/* Called from input thread context */
+static void source_output_process_rewind_cb(pa_source_output *o, size_t nbytes) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ /* FIXME, no idea what I am doing here */
+#if 0
+ pa_asyncmsgq_post(u->asyncmsgq, PA_MSGOBJECT(u->sink_input), SINK_INPUT_MESSAGE_REWIND, NULL, (int64_t) nbytes, NULL, NULL);
+ u->send_counter -= (int64_t) nbytes;
+#endif
+}
+
+/* Called from output thread context */
+static int source_output_process_msg_cb(pa_msgobject *obj, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+
+ /* FIXME, nothing to do here ? */
+
+ return pa_source_output_process_msg(obj, code, data, offset, chunk);
+}
+
+/* Called from output thread context */
+static void source_output_attach_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_source_set_rtpoll(u->source, o->source->thread_info.rtpoll);
+ pa_source_set_latency_range_within_thread(u->source, o->source->thread_info.min_latency, o->source->thread_info.max_latency);
+ pa_source_set_fixed_latency_within_thread(u->source, o->source->thread_info.fixed_latency);
+ pa_source_set_max_rewind_within_thread(u->source, pa_source_output_get_max_rewind(o));
+
+ pa_source_attach_within_thread(u->source);
+}
+
+/* Called from output thread context */
+static void source_output_detach_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ pa_source_detach_within_thread(u->source);
+ pa_source_set_rtpoll(u->source, NULL);
+}
+
+/* Called from output thread context */
+static void source_output_state_change_cb(pa_source_output *o, pa_source_output_state_t state) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+ pa_assert_se(u = o->userdata);
+
+ /* FIXME */
+#if 0
+ if (PA_SOURCE_OUTPUT_IS_LINKED(state) && o->thread_info.state == PA_SOURCE_OUTPUT_INIT) {
+
+ u->skip = pa_usec_to_bytes(PA_CLIP_SUB(pa_source_get_latency_within_thread(o->source),
+ u->latency),
+ &o->sample_spec);
+
+ pa_log_info("Skipping %lu bytes", (unsigned long) u->skip);
+ }
+#endif
+}
+
+/* Called from main thread */
+static void source_output_kill_cb(pa_source_output *o) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ /* The order here matters! We first kill the source output, followed
+ * by the source. That means the source callbacks must be protected
+ * against an unconnected source output! */
+ pa_source_output_unlink(u->source_output);
+ pa_source_unlink(u->source);
+
+ pa_source_output_unref(u->source_output);
+ u->source_output = NULL;
+
+ pa_source_unref(u->source);
+ u->source = NULL;
+
+ pa_module_unload_request(u->module, TRUE);
+}
+
+/* Called from main thread */
+static pa_bool_t source_output_may_move_to_cb(pa_source_output *o, pa_source *dest) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ /* FIXME */
+ //return dest != u->source_input->source->monitor_source;
+
+ return TRUE;
+}
+
+/* Called from main thread */
+static void source_output_moving_cb(pa_source_output *o, pa_source *dest) {
+ struct userdata *u;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert_se(u = o->userdata);
+
+ if (dest) {
+ pa_source_set_asyncmsgq(u->source, dest->asyncmsgq);
+ pa_source_update_flags(u->source, PA_SOURCE_LATENCY|PA_SOURCE_DYNAMIC_LATENCY, dest->flags);
+ } else
+ pa_source_set_asyncmsgq(u->source, NULL);
+
+ if (u->auto_desc && dest) {
+ const char *z;
+ pa_proplist *pl;
+
+ pl = pa_proplist_new();
+ z = pa_proplist_gets(dest->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(pl, PA_PROP_DEVICE_DESCRIPTION, "Virtual Source %s on %s",
+ pa_proplist_gets(u->source->proplist, "device.vsource.name"), z ? z : dest->name);
+
+ pa_source_update_proplist(u->source, PA_UPDATE_REPLACE, pl);
+ pa_proplist_free(pl);
+ }
+}
+
+
+int pa__init(pa_module*m) {
+ struct userdata *u;
+ pa_sample_spec ss;
+ pa_channel_map map;
+ pa_modargs *ma;
+ pa_source *master=NULL;
+ pa_source_output_new_data source_output_data;
+ pa_source_new_data source_data;
+ pa_bool_t use_volume_sharing = FALSE;
+ pa_bool_t force_flat_volume = FALSE;
+
+ /* optional for uplink_sink */
+ pa_sink_new_data sink_data;
+ size_t nbytes;
+
+ pa_assert(m);
+
+ if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
+ pa_log("Failed to parse module arguments.");
+ goto fail;
+ }
+
+ if (!(master = pa_namereg_get(m->core, pa_modargs_get_value(ma, "master", NULL), PA_NAMEREG_SOURCE))) {
+ pa_log("Master source not found");
+ goto fail;
+ }
+
+ pa_assert(master);
+
+ ss = master->sample_spec;
+ ss.format = PA_SAMPLE_FLOAT32;
+ map = master->channel_map;
+ if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_DEFAULT) < 0) {
+ pa_log("Invalid sample format specification or channel map");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "use_volume_sharing", &use_volume_sharing) < 0) {
+ pa_log("use_volume_sharing= expects a boolean argument");
+ goto fail;
+ }
+
+ if (pa_modargs_get_value_boolean(ma, "force_flat_volume", &force_flat_volume) < 0) {
+ pa_log("force_flat_volume= expects a boolean argument");
+ goto fail;
+ }
+
+ if (use_volume_sharing && force_flat_volume) {
+ pa_log("Flat volume can't be forced when using volume sharing.");
+ goto fail;
+ }
+
+ u = pa_xnew0(struct userdata, 1);
+ if (!u) {
+ pa_log("Failed to alloc userdata");
+ goto fail;
+ }
+ u->module = m;
+ m->userdata = u;
+ u->memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, pa_frame_size(&ss), 1, 1, 0, NULL);
+ if (!u->memblockq) {
+ pa_log("Failed to create source memblockq.");
+ goto fail;
+ }
+ u->channels = ss.channels;
+
+ /* Create source */
+ pa_source_new_data_init(&source_data);
+ source_data.driver = __FILE__;
+ source_data.module = m;
+ if (!(source_data.name = pa_xstrdup(pa_modargs_get_value(ma, "source_name", NULL))))
+ source_data.name = pa_sprintf_malloc("%s.vsource", master->name);
+ pa_source_new_data_set_sample_spec(&source_data, &ss);
+ pa_source_new_data_set_channel_map(&source_data, &map);
+ pa_proplist_sets(source_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, master->name);
+ pa_proplist_sets(source_data.proplist, PA_PROP_DEVICE_CLASS, "filter");
+ pa_proplist_sets(source_data.proplist, "device.vsource.name", source_data.name);
+
+ if (pa_modargs_get_proplist(ma, "source_properties", source_data.proplist, PA_UPDATE_REPLACE) < 0) {
+ pa_log("Invalid properties");
+ pa_source_new_data_done(&source_data);
+ goto fail;
+ }
+
+ if ((u->auto_desc = !pa_proplist_contains(source_data.proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ const char *z;
+
+ z = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(source_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Virtual Source %s on %s", source_data.name, z ? z : master->name);
+ }
+
+ u->source = pa_source_new(m->core, &source_data, (master->flags & (PA_SOURCE_LATENCY|PA_SOURCE_DYNAMIC_LATENCY))
+ | (use_volume_sharing ? PA_SOURCE_SHARE_VOLUME_WITH_MASTER : 0)
+ | (force_flat_volume ? PA_SOURCE_FLAT_VOLUME : 0));
+
+ pa_source_new_data_done(&source_data);
+
+ if (!u->source) {
+ pa_log("Failed to create source.");
+ goto fail;
+ }
+
+ u->source->parent.process_msg = source_process_msg_cb;
+ u->source->set_state = source_set_state_cb;
+ u->source->update_requested_latency = source_update_requested_latency_cb;
+ u->source->set_volume = use_volume_sharing ? NULL : source_set_volume_cb;
+ u->source->set_mute = source_set_mute_cb;
+ u->source->userdata = u;
+
+ pa_source_set_asyncmsgq(u->source, master->asyncmsgq);
+
+ /* Create source output */
+ pa_source_output_new_data_init(&source_output_data);
+ source_output_data.driver = __FILE__;
+ source_output_data.module = m;
+ pa_source_output_new_data_set_source(&source_output_data, master, FALSE);
+ source_output_data.destination_source = u->source;
+ /* FIXME
+ source_output_data.flags = PA_SOURCE_OUTPUT_DONT_INHIBIT_AUTO_SUSPEND; */
+
+ pa_proplist_setf(source_output_data.proplist, PA_PROP_MEDIA_NAME, "Virtual Source Stream of %s", pa_proplist_gets(u->source->proplist, PA_PROP_DEVICE_DESCRIPTION));
+ pa_proplist_sets(source_output_data.proplist, PA_PROP_MEDIA_ROLE, "filter");
+ pa_source_output_new_data_set_sample_spec(&source_output_data, &ss);
+ pa_source_output_new_data_set_channel_map(&source_output_data, &map);
+
+ pa_source_output_new(&u->source_output, m->core, &source_output_data);
+ pa_source_output_new_data_done(&source_output_data);
+
+ if (!u->source_output)
+ goto fail;
+
+ u->source_output->parent.process_msg = source_output_process_msg_cb;
+ u->source_output->push = source_output_push_cb;
+ u->source_output->process_rewind = source_output_process_rewind_cb;
+ u->source_output->kill = source_output_kill_cb;
+ u->source_output->attach = source_output_attach_cb;
+ u->source_output->detach = source_output_detach_cb;
+ u->source_output->state_change = source_output_state_change_cb;
+ u->source_output->may_move_to = source_output_may_move_to_cb;
+ u->source_output->moving = source_output_moving_cb;
+ u->source_output->userdata = u;
+
+ u->source->output_from_master = u->source_output;
+
+ pa_source_put(u->source);
+ pa_source_output_put(u->source_output);
+
+ /* Create optional uplink sink */
+ pa_sink_new_data_init(&sink_data);
+ sink_data.driver = __FILE__;
+ sink_data.module = m;
+ if ((sink_data.name = pa_xstrdup(pa_modargs_get_value(ma, "uplink_sink", NULL)))) {
+ pa_sink_new_data_set_sample_spec(&sink_data, &ss);
+ pa_sink_new_data_set_channel_map(&sink_data, &map);
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_MASTER_DEVICE, master->name);
+ pa_proplist_sets(sink_data.proplist, PA_PROP_DEVICE_CLASS, "uplink sink");
+ pa_proplist_sets(sink_data.proplist, "device.uplink_sink.name", sink_data.name);
+
+ if ((u->auto_desc = !pa_proplist_contains(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION))) {
+ const char *z;
+
+ z = pa_proplist_gets(master->proplist, PA_PROP_DEVICE_DESCRIPTION);
+ pa_proplist_setf(sink_data.proplist, PA_PROP_DEVICE_DESCRIPTION, "Uplink Sink %s on %s", sink_data.name, z ? z : master->name);
+ }
+
+ u->sink_memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, pa_frame_size(&ss), 1, 1, 0, NULL);
+ if (!u->sink_memblockq) {
+ pa_log("Failed to create sink memblockq.");
+ goto fail;
+ }
+
+ u->sink = pa_sink_new(m->core, &sink_data, 0); /* FIXME, sink has no capabilities */
+ pa_sink_new_data_done(&sink_data);
+
+ if (!u->sink) {
+ pa_log("Failed to create sink.");
+ goto fail;
+ }
+
+ u->sink->parent.process_msg = sink_process_msg_cb;
+ u->sink->update_requested_latency = sink_update_requested_latency_cb;
+ u->sink->request_rewind = sink_request_rewind_cb;
+ u->sink->set_state = sink_set_state_cb;
+ u->sink->userdata = u;
+
+ pa_sink_set_asyncmsgq(u->sink, master->asyncmsgq);
+
+ /* FIXME: no idea what I am doing here */
+ u->block_usec = BLOCK_USEC;
+ nbytes = pa_usec_to_bytes(u->block_usec, &u->sink->sample_spec);
+ pa_sink_set_max_rewind(u->sink, nbytes);
+ pa_sink_set_max_request(u->sink, nbytes);
+
+ pa_sink_put(u->sink);
+ } else {
+ /* optional uplink sink not enabled */
+ u->sink = NULL;
+ }
+
+ pa_modargs_free(ma);
+
+ return 0;
+
+fail:
+ if (ma)
+ pa_modargs_free(ma);
+
+ pa__done(m);
+
+ return -1;
+}
+
+int pa__get_n_used(pa_module *m) {
+ struct userdata *u;
+
+ pa_assert(m);
+ pa_assert_se(u = m->userdata);
+
+ return pa_source_linked_by(u->source);
+}
+
+void pa__done(pa_module*m) {
+ struct userdata *u;
+
+ pa_assert(m);
+
+ if (!(u = m->userdata))
+ return;
+
+ /* See comments in source_output_kill_cb() above regarding
+ * destruction order! */
+
+ if (u->source_output)
+ pa_source_output_unlink(u->source_output);
+
+ if (u->source)
+ pa_source_unlink(u->source);
+
+ if (u->source_output)
+ pa_source_output_unref(u->source_output);
+
+ if (u->source)
+ pa_source_unref(u->source);
+
+ if (u->sink)
+ pa_sink_unref(u->sink);
+
+ if (u->memblockq)
+ pa_memblockq_free(u->memblockq);
+
+ if (u->sink_memblockq)
+ pa_memblockq_free(u->sink_memblockq);
+
+ pa_xfree(u);
+}
diff --git a/src/modules/module-volume-restore.c b/src/modules/module-volume-restore.c
index 91da598e..a344c5eb 100644
--- a/src/modules/module-volume-restore.c
+++ b/src/modules/module-volume-restore.c
@@ -48,6 +48,7 @@ static const char* const valid_modargs[] = {
int pa__init(pa_module*m) {
pa_modargs *ma = NULL;
pa_bool_t restore_device = TRUE, restore_volume = TRUE;
+ pa_module *n;
char *t;
pa_assert(m);
@@ -66,17 +67,19 @@ int pa__init(pa_module*m) {
pa_log_warn("We will now load module-stream-restore. Please make sure to remove module-volume-restore from your configuration.");
t = pa_sprintf_malloc("restore_volume=%s restore_device=%s", pa_yes_no(restore_volume), pa_yes_no(restore_device));
- pa_module_load(m->core, "module-stream-restore", t);
+ n = pa_module_load(m->core, "module-stream-restore", t);
pa_xfree(t);
- pa_module_unload_request(m, TRUE);
+ if (n)
+ pa_module_unload_request(m, TRUE);
pa_modargs_free(ma);
- return 0;
+
+ return n ? 0 : -1;
fail:
if (ma)
pa_modargs_free(ma);
- return -1;
+ return -1;
}
diff --git a/src/modules/module-waveout.c b/src/modules/module-waveout.c
index 2d35828d..cb02723c 100644
--- a/src/modules/module-waveout.c
+++ b/src/modules/module-waveout.c
@@ -27,8 +27,6 @@
#include <windows.h>
#include <mmsystem.h>
-#include <pulse/mainloop-api.h>
-
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
@@ -39,24 +37,27 @@
#include <pulsecore/sample-util.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
+#include <pulsecore/thread.h>
+#include <pulsecore/thread-mq.h>
#include "module-waveout-symdef.h"
-PA_MODULE_AUTHOR("Pierre Ossman")
-PA_MODULE_DESCRIPTION("Windows waveOut Sink/Source")
-PA_MODULE_VERSION(PACKAGE_VERSION)
+PA_MODULE_AUTHOR("Pierre Ossman");
+PA_MODULE_DESCRIPTION("Windows waveOut Sink/Source");
+PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_USAGE(
"sink_name=<name for the sink> "
"source_name=<name for the source> "
"device=<device number> "
+ "device_name=<name of the device> "
"record=<enable source?> "
"playback=<enable sink?> "
"format=<sample format> "
- "channels=<number of channels> "
"rate=<sample rate> "
+ "channels=<number of channels> "
+ "channel_map=<channel map> "
"fragments=<number of fragments> "
- "fragment_size=<fragment size> "
- "channel_map=<channel map>")
+ "fragment_size=<fragment size>");
#define DEFAULT_SINK_NAME "wave_output"
#define DEFAULT_SOURCE_NAME "wave_input"
@@ -67,10 +68,12 @@ struct userdata {
pa_sink *sink;
pa_source *source;
pa_core *core;
- pa_time_event *event;
- pa_defer_event *defer;
pa_usec_t poll_timeout;
+ pa_thread *thread;
+ pa_thread_mq thread_mq;
+ pa_rtpoll *rtpoll;
+
uint32_t fragments, fragment_size;
uint32_t free_ofrags, free_ifrags;
@@ -92,6 +95,7 @@ static const char* const valid_modargs[] = {
"sink_name",
"source_name",
"device",
+ "device_name",
"record",
"playback",
"fragments",
@@ -103,22 +107,19 @@ static const char* const valid_modargs[] = {
NULL
};
-static void update_usage(struct userdata *u) {
- pa_module_set_used(u->module,
- (u->sink ? pa_sink_used_by(u->sink) : 0) +
- (u->source ? pa_source_used_by(u->source) : 0));
-}
-
-static void do_write(struct userdata *u)
-{
+static void do_write(struct userdata *u) {
uint32_t free_frags;
pa_memchunk memchunk;
WAVEHDR *hdr;
MMRESULT res;
+ void *p;
if (!u->sink)
return;
+ if (!PA_SINK_IS_LINKED(u->sink->state))
+ return;
+
EnterCriticalSection(&u->crit);
free_frags = u->free_ofrags;
LeaveCriticalSection(&u->crit);
@@ -137,18 +138,17 @@ static void do_write(struct userdata *u)
len = u->fragment_size - hdr->dwBufferLength;
- if (pa_sink_render(u->sink, len, &memchunk) < 0)
- break;
+ pa_sink_render(u->sink, len, &memchunk);
- assert(memchunk.memblock);
- assert(memchunk.memblock->data);
- assert(memchunk.length);
+ pa_assert(memchunk.memblock);
+ pa_assert(memchunk.length);
if (memchunk.length < len)
len = memchunk.length;
- memcpy(hdr->lpData + hdr->dwBufferLength,
- (char*)memchunk.memblock->data + memchunk.index, len);
+ p = pa_memblock_acquire(memchunk.memblock);
+ memcpy(hdr->lpData + hdr->dwBufferLength, (char*) p + memchunk.index, len);
+ pa_memblock_release(memchunk.memblock);
hdr->dwBufferLength += len;
@@ -156,24 +156,20 @@ static void do_write(struct userdata *u)
memchunk.memblock = NULL;
}
- /* Insufficient data in sink buffer? */
+ /* Underflow detection */
if (hdr->dwBufferLength == 0) {
u->sink_underflow = 1;
break;
}
-
u->sink_underflow = 0;
res = waveOutPrepareHeader(u->hwo, hdr, sizeof(WAVEHDR));
- if (res != MMSYSERR_NOERROR) {
- pa_log_error(__FILE__ ": ERROR: Unable to prepare waveOut block: %d",
- res);
- }
+ if (res != MMSYSERR_NOERROR)
+ pa_log_error("Unable to prepare waveOut block: %d", res);
+
res = waveOutWrite(u->hwo, hdr, sizeof(WAVEHDR));
- if (res != MMSYSERR_NOERROR) {
- pa_log_error(__FILE__ ": ERROR: Unable to write waveOut block: %d",
- res);
- }
+ if (res != MMSYSERR_NOERROR)
+ pa_log_error("Unable to write waveOut block: %d", res);
u->written_bytes += hdr->dwBufferLength;
@@ -187,21 +183,22 @@ static void do_write(struct userdata *u)
}
}
-static void do_read(struct userdata *u)
-{
+static void do_read(struct userdata *u) {
uint32_t free_frags;
pa_memchunk memchunk;
WAVEHDR *hdr;
MMRESULT res;
+ void *p;
if (!u->source)
return;
- EnterCriticalSection(&u->crit);
+ if (!PA_SOURCE_IS_LINKED(u->source->state))
+ return;
+ EnterCriticalSection(&u->crit);
free_frags = u->free_ifrags;
u->free_ifrags = 0;
-
LeaveCriticalSection(&u->crit);
if (free_frags == u->fragments)
@@ -214,11 +211,13 @@ static void do_read(struct userdata *u)
if (hdr->dwBytesRecorded) {
memchunk.memblock = pa_memblock_new(u->core->mempool, hdr->dwBytesRecorded);
- assert(memchunk.memblock);
+ pa_assert(memchunk.memblock);
- memcpy((char*)memchunk.memblock->data, hdr->lpData, hdr->dwBytesRecorded);
+ p = pa_memblock_acquire(memchunk.memblock);
+ memcpy((char*) p, hdr->lpData, hdr->dwBytesRecorded);
+ pa_memblock_release(memchunk.memblock);
- memchunk.length = memchunk.memblock->length = hdr->dwBytesRecorded;
+ memchunk.length = hdr->dwBytesRecorded;
memchunk.index = 0;
pa_source_post(u->source, &memchunk);
@@ -226,15 +225,12 @@ static void do_read(struct userdata *u)
}
res = waveInPrepareHeader(u->hwi, hdr, sizeof(WAVEHDR));
- if (res != MMSYSERR_NOERROR) {
- pa_log_error(__FILE__ ": ERROR: Unable to prepare waveIn block: %d",
- res);
- }
+ if (res != MMSYSERR_NOERROR)
+ pa_log_error("Unable to prepare waveIn block: %d", res);
+
res = waveInAddBuffer(u->hwi, hdr, sizeof(WAVEHDR));
- if (res != MMSYSERR_NOERROR) {
- pa_log_error(__FILE__ ": ERROR: Unable to add waveIn block: %d",
- res);
- }
+ if (res != MMSYSERR_NOERROR)
+ pa_log_error("Unable to add waveIn block: %d", res);
free_frags--;
u->cur_ihdr++;
@@ -242,172 +238,208 @@ static void do_read(struct userdata *u)
}
}
-static void poll_cb(pa_mainloop_api*a, pa_time_event *e, const struct timeval *tv, void *userdata) {
+static void thread_func(void *userdata) {
struct userdata *u = userdata;
- struct timeval ntv;
- assert(u);
+ pa_assert(u);
+ pa_assert(u->sink || u->source);
- update_usage(u);
+ pa_log_debug("Thread starting up");
- do_write(u);
- do_read(u);
+ if (u->core->realtime_scheduling)
+ pa_make_realtime(u->core->realtime_priority);
- pa_gettimeofday(&ntv);
- pa_timeval_add(&ntv, u->poll_timeout);
+ pa_thread_mq_install(&u->thread_mq);
- a->time_restart(e, &ntv);
-}
+ for (;;) {
+ int ret;
+ pa_bool_t need_timer = FALSE;
-static void defer_cb(pa_mainloop_api*a, pa_defer_event *e, void *userdata) {
- struct userdata *u = userdata;
+ if (u->sink && PA_SINK_IS_OPENED(u->sink->thread_info.state)) {
+ if (u->sink->thread_info.rewind_requested)
+ pa_sink_process_rewind(u->sink, 0);
+
+ do_write(u);
+ need_timer = TRUE;
+ }
+ if (u->source && PA_SOURCE_IS_OPENED(u->source->thread_info.state)) {
+ do_read(u);
+ need_timer = TRUE;
+ }
+
+ if (need_timer)
+ pa_rtpoll_set_timer_relative(u->rtpoll, u->poll_timeout);
+ else
+ pa_rtpoll_set_timer_disabled(u->rtpoll);
+
+ /* Hmm, nothing to do. Let's sleep */
+ if ((ret = pa_rtpoll_run(u->rtpoll, TRUE)) < 0)
+ goto fail;
- assert(u);
+ if (ret == 0)
+ goto finish;
+ }
- a->defer_enable(e, 0);
+fail:
+ /* If this was no regular exit from the loop we have to continue
+ * processing messages until we received PA_MESSAGE_SHUTDOWN */
+ pa_asyncmsgq_post(u->thread_mq.outq, PA_MSGOBJECT(u->core), PA_CORE_MESSAGE_UNLOAD_MODULE, u->module, 0, NULL, NULL);
+ pa_asyncmsgq_wait_for(u->thread_mq.inq, PA_MESSAGE_SHUTDOWN);
- do_write(u);
- do_read(u);
+finish:
+ pa_log_debug("Thread shutting down");
}
static void CALLBACK chunk_done_cb(HWAVEOUT hwo, UINT msg, DWORD_PTR inst, DWORD param1, DWORD param2) {
- struct userdata *u = (struct userdata *)inst;
+ struct userdata *u = (struct userdata*) inst;
+ if (msg == WOM_OPEN)
+ pa_log_debug("WaveOut subsystem opened.");
+ if (msg == WOM_CLOSE)
+ pa_log_debug("WaveOut subsystem closed.");
if (msg != WOM_DONE)
return;
EnterCriticalSection(&u->crit);
-
u->free_ofrags++;
- assert(u->free_ofrags <= u->fragments);
-
+ pa_assert(u->free_ofrags <= u->fragments);
LeaveCriticalSection(&u->crit);
}
static void CALLBACK chunk_ready_cb(HWAVEIN hwi, UINT msg, DWORD_PTR inst, DWORD param1, DWORD param2) {
- struct userdata *u = (struct userdata *)inst;
+ struct userdata *u = (struct userdata*) inst;
+ if (msg == WIM_OPEN)
+ pa_log_debug("WaveIn subsystem opened.");
+ if (msg == WIM_CLOSE)
+ pa_log_debug("WaveIn subsystem closed.");
if (msg != WIM_DATA)
return;
EnterCriticalSection(&u->crit);
-
u->free_ifrags++;
- assert(u->free_ifrags <= u->fragments);
-
+ pa_assert(u->free_ifrags <= u->fragments);
LeaveCriticalSection(&u->crit);
}
-static pa_usec_t sink_get_latency_cb(pa_sink *s) {
- struct userdata *u = s->userdata;
+static pa_usec_t sink_get_latency(struct userdata *u) {
uint32_t free_frags;
MMTIME mmt;
- assert(s && u && u->sink);
+ pa_assert(u);
+ pa_assert(u->sink);
memset(&mmt, 0, sizeof(mmt));
mmt.wType = TIME_BYTES;
if (waveOutGetPosition(u->hwo, &mmt, sizeof(mmt)) == MMSYSERR_NOERROR)
- return pa_bytes_to_usec(u->written_bytes - mmt.u.cb, &s->sample_spec);
+ return pa_bytes_to_usec(u->written_bytes - mmt.u.cb, &u->sink->sample_spec);
else {
EnterCriticalSection(&u->crit);
-
free_frags = u->free_ofrags;
-
LeaveCriticalSection(&u->crit);
- return pa_bytes_to_usec((u->fragments - free_frags) * u->fragment_size,
- &s->sample_spec);
+ return pa_bytes_to_usec((u->fragments - free_frags) * u->fragment_size, &u->sink->sample_spec);
}
}
-static pa_usec_t source_get_latency_cb(pa_source *s) {
+static pa_usec_t source_get_latency(struct userdata *u) {
pa_usec_t r = 0;
- struct userdata *u = s->userdata;
uint32_t free_frags;
- assert(s && u && u->sink);
+ pa_assert(u);
+ pa_assert(u->source);
EnterCriticalSection(&u->crit);
-
free_frags = u->free_ifrags;
-
LeaveCriticalSection(&u->crit);
- r += pa_bytes_to_usec((free_frags + 1) * u->fragment_size, &s->sample_spec);
+ r += pa_bytes_to_usec((free_frags + 1) * u->fragment_size, &u->source->sample_spec);
return r;
}
-static void notify_sink_cb(pa_sink *s) {
- struct userdata *u = s->userdata;
- assert(u);
+static int process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) {
+ struct userdata *u;
- u->core->mainloop->defer_enable(u->defer, 1);
-}
+ if (pa_sink_isinstance(o)) {
+ u = PA_SINK(o)->userdata;
-static void notify_source_cb(pa_source *s) {
- struct userdata *u = s->userdata;
- assert(u);
+ switch (code) {
+
+ case PA_SINK_MESSAGE_GET_LATENCY: {
+ pa_usec_t r = 0;
+ if (u->hwo)
+ r = sink_get_latency(u);
+ *((pa_usec_t*) data) = r;
+ return 0;
+ }
+
+ }
+
+ return pa_sink_process_msg(o, code, data, offset, chunk);
+ }
+
+ if (pa_source_isinstance(o)) {
+ u = PA_SOURCE(o)->userdata;
+
+ switch (code) {
+
+ case PA_SOURCE_MESSAGE_GET_LATENCY: {
+ pa_usec_t r = 0;
+ if (u->hwi)
+ r = source_get_latency(u);
+ *((pa_usec_t*) data) = r;
+ return 0;
+ }
+
+ }
+
+ return pa_source_process_msg(o, code, data, offset, chunk);
+ }
- u->core->mainloop->defer_enable(u->defer, 1);
+ return -1;
}
-static int sink_get_hw_volume_cb(pa_sink *s) {
+static void sink_get_volume_cb(pa_sink *s) {
struct userdata *u = s->userdata;
DWORD vol;
pa_volume_t left, right;
if (waveOutGetVolume(u->hwo, &vol) != MMSYSERR_NOERROR)
- return -1;
+ return;
- left = (vol & 0xFFFF) * PA_VOLUME_NORM / WAVEOUT_MAX_VOLUME;
- right = ((vol >> 16) & 0xFFFF) * PA_VOLUME_NORM / WAVEOUT_MAX_VOLUME;
+ left = PA_CLAMP_VOLUME((vol & 0xFFFF) * PA_VOLUME_NORM / WAVEOUT_MAX_VOLUME);
+ right = PA_CLAMP_VOLUME(((vol >> 16) & 0xFFFF) * PA_VOLUME_NORM / WAVEOUT_MAX_VOLUME);
/* Windows supports > 2 channels, except for volume control */
- if (s->hw_volume.channels > 2)
- pa_cvolume_set(&s->hw_volume, s->hw_volume.channels, (left + right)/2);
-
- s->hw_volume.values[0] = left;
- if (s->hw_volume.channels > 1)
- s->hw_volume.values[1] = right;
+ if (s->real_volume.channels > 2)
+ pa_cvolume_set(&s->real_volume, s->real_volume.channels, (left + right)/2);
- return 0;
+ s->real_volume.values[0] = left;
+ if (s->real_volume.channels > 1)
+ s->real_volume.values[1] = right;
}
-static int sink_set_hw_volume_cb(pa_sink *s) {
+static void sink_set_volume_cb(pa_sink *s) {
struct userdata *u = s->userdata;
DWORD vol;
- vol = s->hw_volume.values[0] * WAVEOUT_MAX_VOLUME / PA_VOLUME_NORM;
- if (s->hw_volume.channels > 1)
- vol |= (s->hw_volume.values[0] * WAVEOUT_MAX_VOLUME / PA_VOLUME_NORM) << 16;
+ vol = s->real_volume.values[0] * WAVEOUT_MAX_VOLUME / PA_VOLUME_NORM;
+ if (s->real_volume.channels > 1)
+ vol |= (s->real_volume.values[1] * WAVEOUT_MAX_VOLUME / PA_VOLUME_NORM) << 16;
if (waveOutSetVolume(u->hwo, vol) != MMSYSERR_NOERROR)
- return -1;
-
- return 0;
+ return;
}
static int ss_to_waveformat(pa_sample_spec *ss, LPWAVEFORMATEX wf) {
wf->wFormatTag = WAVE_FORMAT_PCM;
if (ss->channels > 2) {
- pa_log_error("ERROR: More than two channels not supported.");
+ pa_log_error("More than two channels not supported.");
return -1;
}
wf->nChannels = ss->channels;
- switch (ss->rate) {
- case 8000:
- case 11025:
- case 22005:
- case 44100:
- break;
- default:
- pa_log_error("ERROR: Unsupported sample rate.");
- return -1;
- }
-
wf->nSamplesPerSec = ss->rate;
if (ss->format == PA_SAMPLE_U8)
@@ -415,7 +447,7 @@ static int ss_to_waveformat(pa_sample_spec *ss, LPWAVEFORMATEX wf) {
else if (ss->format == PA_SAMPLE_S16NE)
wf->wBitsPerSample = 16;
else {
- pa_log_error("ERROR: Unsupported sample format.");
+ pa_log_error("Unsupported sample format, only u8 and s16 are supported.");
return -1;
}
@@ -427,21 +459,34 @@ static int ss_to_waveformat(pa_sample_spec *ss, LPWAVEFORMATEX wf) {
return 0;
}
-int pa__init(pa_core *c, pa_module*m) {
+int pa__get_n_used(pa_module *m) {
+ struct userdata *u;
+ pa_assert(m);
+ pa_assert(m->userdata);
+ u = (struct userdata*) m->userdata;
+
+ return (u->sink ? pa_sink_used_by(u->sink) : 0) +
+ (u->source ? pa_source_used_by(u->source) : 0);
+}
+
+int pa__init(pa_module *m) {
struct userdata *u = NULL;
HWAVEOUT hwo = INVALID_HANDLE_VALUE;
HWAVEIN hwi = INVALID_HANDLE_VALUE;
WAVEFORMATEX wf;
+ WAVEOUTCAPS pwoc;
+ MMRESULT result;
int nfrags, frag_size;
- int record = 1, playback = 1;
+ pa_bool_t record = TRUE, playback = TRUE;
unsigned int device;
pa_sample_spec ss;
pa_channel_map map;
pa_modargs *ma = NULL;
+ const char *device_name = NULL;
unsigned int i;
- struct timeval tv;
- assert(c && m);
+ pa_assert(m);
+ pa_assert(m->core);
if (!(ma = pa_modargs_new(m->argument, valid_modargs))) {
pa_log("failed to parse module arguments.");
@@ -458,11 +503,31 @@ int pa__init(pa_core *c, pa_module*m) {
goto fail;
}
+ /* Set the device to be opened. If set device_name is used,
+ * else device if set and lastly WAVE_MAPPER is the default */
device = WAVE_MAPPER;
if (pa_modargs_get_value_u32(ma, "device", &device) < 0) {
pa_log("failed to parse device argument");
goto fail;
}
+ if ((device_name = pa_modargs_get_value(ma, "device_name", NULL)) != NULL) {
+ unsigned int num_devices = waveOutGetNumDevs();
+ for (i = 0; i < num_devices; i++) {
+ if (waveOutGetDevCaps(i, &pwoc, sizeof(pwoc)) == MMSYSERR_NOERROR)
+ if (_stricmp(device_name, pwoc.szPname) == 0)
+ break;
+ }
+ if (i < num_devices)
+ device = i;
+ else {
+ pa_log("device not found: %s", device_name);
+ goto fail;
+ }
+ }
+ if (waveOutGetDevCaps(device, &pwoc, sizeof(pwoc)) == MMSYSERR_NOERROR)
+ device_name = pwoc.szPname;
+ else
+ device_name = "unknown";
nfrags = 5;
frag_size = 8192;
@@ -471,7 +536,7 @@ int pa__init(pa_core *c, pa_module*m) {
goto fail;
}
- ss = c->default_sample_spec;
+ ss = m->core->default_sample_spec;
if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_WAVEEX) < 0) {
pa_log("failed to parse sample specification");
goto fail;
@@ -483,56 +548,89 @@ int pa__init(pa_core *c, pa_module*m) {
u = pa_xmalloc(sizeof(struct userdata));
if (record) {
- if (waveInOpen(&hwi, device, &wf, (DWORD_PTR)chunk_ready_cb, (DWORD_PTR)u, CALLBACK_FUNCTION) != MMSYSERR_NOERROR) {
- pa_log("failed to open waveIn");
+ result = waveInOpen(&hwi, device, &wf, 0, 0, WAVE_FORMAT_DIRECT | WAVE_FORMAT_QUERY);
+ if (result != MMSYSERR_NOERROR) {
+ pa_log_warn("Sample spec not supported by WaveIn, falling back to default sample rate.");
+ ss.rate = wf.nSamplesPerSec = m->core->default_sample_spec.rate;
+ }
+ result = waveInOpen(&hwi, device, &wf, (DWORD_PTR) chunk_ready_cb, (DWORD_PTR) u, CALLBACK_FUNCTION);
+ if (result != MMSYSERR_NOERROR) {
+ char errortext[MAXERRORLENGTH];
+ pa_log("Failed to open WaveIn.");
+ if (waveInGetErrorText(result, errortext, sizeof(errortext)) == MMSYSERR_NOERROR)
+ pa_log("Error: %s", errortext);
goto fail;
}
if (waveInStart(hwi) != MMSYSERR_NOERROR) {
pa_log("failed to start waveIn");
goto fail;
}
- pa_log_debug("Opened waveIn subsystem.");
}
if (playback) {
- if (waveOutOpen(&hwo, device, &wf, (DWORD_PTR)chunk_done_cb, (DWORD_PTR)u, CALLBACK_FUNCTION) != MMSYSERR_NOERROR) {
- pa_log("failed to open waveOut");
+ result = waveOutOpen(&hwo, device, &wf, 0, 0, WAVE_FORMAT_DIRECT | WAVE_FORMAT_QUERY);
+ if (result != MMSYSERR_NOERROR) {
+ pa_log_warn("Sample spec not supported by WaveOut, falling back to default sample rate.");
+ ss.rate = wf.nSamplesPerSec = m->core->default_sample_spec.rate;
+ }
+ result = waveOutOpen(&hwo, device, &wf, (DWORD_PTR) chunk_done_cb, (DWORD_PTR) u, CALLBACK_FUNCTION);
+ if (result != MMSYSERR_NOERROR) {
+ char errortext[MAXERRORLENGTH];
+ pa_log("Failed to open WaveOut.");
+ if (waveOutGetErrorText(result, errortext, sizeof(errortext)) == MMSYSERR_NOERROR)
+ pa_log("Error: %s", errortext);
goto fail;
}
- pa_log_debug("Opened waveOut subsystem.");
}
InitializeCriticalSection(&u->crit);
if (hwi != INVALID_HANDLE_VALUE) {
- u->source = pa_source_new(c, __FILE__, pa_modargs_get_value(ma, "source_name", DEFAULT_SOURCE_NAME), 0, &ss, &map);
- assert(u->source);
+ char *description = pa_sprintf_malloc("WaveIn on %s", device_name);
+ pa_source_new_data data;
+ pa_source_new_data_init(&data);
+ data.driver = __FILE__;
+ data.module = m;
+ pa_source_new_data_set_sample_spec(&data, &ss);
+ pa_source_new_data_set_channel_map(&data, &map);
+ pa_source_new_data_set_name(&data, pa_modargs_get_value(ma, "source_name", DEFAULT_SOURCE_NAME));
+ u->source = pa_source_new(m->core, &data, PA_SOURCE_HARDWARE|PA_SOURCE_LATENCY);
+ pa_source_new_data_done(&data);
+
+ pa_assert(u->source);
u->source->userdata = u;
- u->source->notify = notify_source_cb;
- u->source->get_latency = source_get_latency_cb;
- pa_source_set_owner(u->source, m);
- pa_source_set_description(u->source, "Windows waveIn PCM");
- u->source->is_hardware = 1;
+ pa_source_set_description(u->source, description);
+ u->source->parent.process_msg = process_msg;
+ pa_xfree(description);
} else
u->source = NULL;
if (hwo != INVALID_HANDLE_VALUE) {
- u->sink = pa_sink_new(c, __FILE__, pa_modargs_get_value(ma, "sink_name", DEFAULT_SINK_NAME), 0, &ss, &map);
- assert(u->sink);
- u->sink->notify = notify_sink_cb;
- u->sink->get_latency = sink_get_latency_cb;
- u->sink->get_hw_volume = sink_get_hw_volume_cb;
- u->sink->set_hw_volume = sink_set_hw_volume_cb;
+ char *description = pa_sprintf_malloc("WaveOut on %s", device_name);
+ pa_sink_new_data data;
+ pa_sink_new_data_init(&data);
+ data.driver = __FILE__;
+ data.module = m;
+ pa_sink_new_data_set_sample_spec(&data, &ss);
+ pa_sink_new_data_set_channel_map(&data, &map);
+ pa_sink_new_data_set_name(&data, pa_modargs_get_value(ma, "sink_name", DEFAULT_SINK_NAME));
+ u->sink = pa_sink_new(m->core, &data, PA_SINK_HARDWARE|PA_SINK_LATENCY);
+ pa_sink_new_data_done(&data);
+
+ pa_assert(u->sink);
+ u->sink->get_volume = sink_get_volume_cb;
+ u->sink->set_volume = sink_set_volume_cb;
u->sink->userdata = u;
- pa_sink_set_owner(u->sink, m);
- pa_sink_set_description(u->sink, "Windows waveOut PCM");
- u->sink->is_hardware = 1;
+ pa_sink_set_description(u->sink, description);
+ u->sink->parent.process_msg = process_msg;
+ pa_xfree(description);
} else
u->sink = NULL;
- assert(u->source || u->sink);
+ pa_assert(u->source || u->sink);
+ pa_modargs_free(ma);
- u->core = c;
+ u->core = m->core;
u->hwi = hwi;
u->hwo = hwo;
@@ -545,83 +643,90 @@ int pa__init(pa_core *c, pa_module*m) {
u->sink_underflow = 1;
u->poll_timeout = pa_bytes_to_usec(u->fragments * u->fragment_size / 10, &ss);
-
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, u->poll_timeout);
-
- u->event = c->mainloop->time_new(c->mainloop, &tv, poll_cb, u);
- assert(u->event);
-
- u->defer = c->mainloop->defer_new(c->mainloop, defer_cb, u);
- assert(u->defer);
- c->mainloop->defer_enable(u->defer, 0);
+ pa_log_debug("Poll timeout = %.1f ms", (double) u->poll_timeout / PA_USEC_PER_MSEC);
u->cur_ihdr = 0;
u->cur_ohdr = 0;
u->ihdrs = pa_xmalloc0(sizeof(WAVEHDR) * u->fragments);
- assert(u->ihdrs);
+ pa_assert(u->ihdrs);
u->ohdrs = pa_xmalloc0(sizeof(WAVEHDR) * u->fragments);
- assert(u->ohdrs);
- for (i = 0;i < u->fragments;i++) {
+ pa_assert(u->ohdrs);
+ for (i = 0; i < u->fragments; i++) {
u->ihdrs[i].dwBufferLength = u->fragment_size;
u->ohdrs[i].dwBufferLength = u->fragment_size;
u->ihdrs[i].lpData = pa_xmalloc(u->fragment_size);
- assert(u->ihdrs);
+ pa_assert(u->ihdrs);
u->ohdrs[i].lpData = pa_xmalloc(u->fragment_size);
- assert(u->ohdrs);
+ pa_assert(u->ohdrs);
}
u->module = m;
m->userdata = u;
- pa_modargs_free(ma);
-
/* Read mixer settings */
if (u->sink)
- sink_get_hw_volume_cb(u->sink);
+ sink_get_volume_cb(u->sink);
- return 0;
+ u->rtpoll = pa_rtpoll_new();
+ pa_thread_mq_init(&u->thread_mq, m->core->mainloop, u->rtpoll);
-fail:
- if (hwi != INVALID_HANDLE_VALUE)
- waveInClose(hwi);
+ if (u->sink) {
+ pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
+ pa_sink_set_rtpoll(u->sink, u->rtpoll);
+ }
+ if (u->source) {
+ pa_source_set_asyncmsgq(u->source, u->thread_mq.inq);
+ pa_source_set_rtpoll(u->source, u->rtpoll);
+ }
+
+ if (!(u->thread = pa_thread_new("waveout", thread_func, u))) {
+ pa_log("Failed to create thread.");
+ goto fail;
+ }
- if (hwo != INVALID_HANDLE_VALUE)
- waveOutClose(hwo);
+ if (u->sink)
+ pa_sink_put(u->sink);
+ if (u->source)
+ pa_source_put(u->source);
- if (u)
- pa_xfree(u);
+ return 0;
+fail:
if (ma)
pa_modargs_free(ma);
+ pa__done(m);
+
return -1;
}
-void pa__done(pa_core *c, pa_module*m) {
+void pa__done(pa_module *m) {
struct userdata *u;
unsigned int i;
- assert(c && m);
+ pa_assert(m);
+ pa_assert(m->core);
if (!(u = m->userdata))
return;
- if (u->event)
- c->mainloop->time_free(u->event);
+ if (u->sink)
+ pa_sink_unlink(u->sink);
+ if (u->source)
+ pa_source_unlink(u->source);
- if (u->defer)
- c->mainloop->defer_free(u->defer);
+ pa_asyncmsgq_send(u->thread_mq.inq, NULL, PA_MESSAGE_SHUTDOWN, NULL, 0, NULL);
+ if (u->thread)
+ pa_thread_free(u->thread);
+ pa_thread_mq_done(&u->thread_mq);
- if (u->sink) {
- pa_sink_disconnect(u->sink);
+ if (u->sink)
pa_sink_unref(u->sink);
- }
-
- if (u->source) {
- pa_source_disconnect(u->source);
+ if (u->source)
pa_source_unref(u->source);
- }
+
+ if (u->rtpoll)
+ pa_rtpoll_free(u->rtpoll);
if (u->hwi != INVALID_HANDLE_VALUE) {
waveInReset(u->hwi);
@@ -633,7 +738,7 @@ void pa__done(pa_core *c, pa_module*m) {
waveOutClose(u->hwo);
}
- for (i = 0;i < u->fragments;i++) {
+ for (i = 0; i < u->fragments; i++) {
pa_xfree(u->ihdrs[i].lpData);
pa_xfree(u->ohdrs[i].lpData);
}
diff --git a/src/modules/module-zeroconf-discover.c b/src/modules/module-zeroconf-discover.c
index 1fdc1f46..cd076aab 100644
--- a/src/modules/module-zeroconf-discover.c
+++ b/src/modules/module-zeroconf-discover.c
@@ -36,14 +36,9 @@
#include <avahi-common/malloc.h>
#include <pulse/xmalloc.h>
-#include <pulse/util.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/source.h>
-#include <pulsecore/native-common.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-subscribe.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/modargs.h>
#include <pulsecore/namereg.h>
diff --git a/src/modules/module-zeroconf-publish.c b/src/modules/module-zeroconf-publish.c
index d72d2647..0c20cf6c 100644
--- a/src/modules/module-zeroconf-publish.c
+++ b/src/modules/module-zeroconf-publish.c
@@ -25,7 +25,6 @@
#include <stdio.h>
#include <stdlib.h>
-#include <string.h>
#include <unistd.h>
#include <avahi-client/client.h>
@@ -43,11 +42,9 @@
#include <pulsecore/native-common.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-subscribe.h>
#include <pulsecore/dynarray.h>
#include <pulsecore/modargs.h>
#include <pulsecore/avahi-wrap.h>
-#include <pulsecore/endianmacros.h>
#include <pulsecore/protocol-native.h>
#include "module-zeroconf-publish-symdef.h"
diff --git a/src/modules/oss/Makefile b/src/modules/oss/Makefile
deleted file mode 120000
index efe5a336..00000000
--- a/src/modules/oss/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../../pulse/Makefile \ No newline at end of file
diff --git a/src/modules/oss/module-oss.c b/src/modules/oss/module-oss.c
index b1afcfd6..2a99d119 100644
--- a/src/modules/oss/module-oss.c
+++ b/src/modules/oss/module-oss.c
@@ -45,15 +45,10 @@
#include <sys/soundcard.h>
#include <sys/ioctl.h>
#include <stdlib.h>
-#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
-#include <string.h>
#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
-#include <signal.h>
-#include <poll.h>
#include <pulse/xmalloc.h>
#include <pulse/util.h>
@@ -70,6 +65,7 @@
#include <pulsecore/macro.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/rtpoll.h>
+#include <pulsecore/poll.h>
#if defined(__NetBSD__) && !defined(SNDCTL_DSP_GETODELAY)
#include <sys/audioio.h>
@@ -169,7 +165,7 @@ static void trigger(struct userdata *u, pa_bool_t quick) {
if (u->fd < 0)
return;
- pa_log_debug("trigger");
+ pa_log_debug("trigger");
if (u->source && PA_SOURCE_IS_OPENED(u->source->thread_info.state))
enable_bits |= PCM_ENABLE_INPUT;
@@ -812,11 +808,11 @@ static void sink_get_volume(pa_sink *s) {
pa_assert(u->mixer_devmask & (SOUND_MASK_VOLUME|SOUND_MASK_PCM));
if (u->mixer_devmask & SOUND_MASK_VOLUME)
- if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_VOLUME, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_VOLUME, &s->sample_spec, &s->real_volume) >= 0)
return;
if (u->mixer_devmask & SOUND_MASK_PCM)
- if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_PCM, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_PCM, &s->sample_spec, &s->real_volume) >= 0)
return;
pa_log_info("Device doesn't support reading mixer settings: %s", pa_cstrerror(errno));
@@ -830,11 +826,11 @@ static void sink_set_volume(pa_sink *s) {
pa_assert(u->mixer_devmask & (SOUND_MASK_VOLUME|SOUND_MASK_PCM));
if (u->mixer_devmask & SOUND_MASK_VOLUME)
- if (pa_oss_set_volume(u->mixer_fd, SOUND_MIXER_WRITE_VOLUME, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_set_volume(u->mixer_fd, SOUND_MIXER_WRITE_VOLUME, &s->sample_spec, &s->real_volume) >= 0)
return;
if (u->mixer_devmask & SOUND_MASK_PCM)
- if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_WRITE_PCM, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_WRITE_PCM, &s->sample_spec, &s->real_volume) >= 0)
return;
pa_log_info("Device doesn't support writing mixer settings: %s", pa_cstrerror(errno));
@@ -848,11 +844,11 @@ static void source_get_volume(pa_source *s) {
pa_assert(u->mixer_devmask & (SOUND_MASK_IGAIN|SOUND_MASK_RECLEV));
if (u->mixer_devmask & SOUND_MASK_IGAIN)
- if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_IGAIN, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_IGAIN, &s->sample_spec, &s->real_volume) >= 0)
return;
if (u->mixer_devmask & SOUND_MASK_RECLEV)
- if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_RECLEV, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_READ_RECLEV, &s->sample_spec, &s->real_volume) >= 0)
return;
pa_log_info("Device doesn't support reading mixer settings: %s", pa_cstrerror(errno));
@@ -866,11 +862,11 @@ static void source_set_volume(pa_source *s) {
pa_assert(u->mixer_devmask & (SOUND_MASK_IGAIN|SOUND_MASK_RECLEV));
if (u->mixer_devmask & SOUND_MASK_IGAIN)
- if (pa_oss_set_volume(u->mixer_fd, SOUND_MIXER_WRITE_IGAIN, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_set_volume(u->mixer_fd, SOUND_MIXER_WRITE_IGAIN, &s->sample_spec, &s->real_volume) >= 0)
return;
if (u->mixer_devmask & SOUND_MASK_RECLEV)
- if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_WRITE_RECLEV, &s->sample_spec, &s->virtual_volume) >= 0)
+ if (pa_oss_get_volume(u->mixer_fd, SOUND_MIXER_WRITE_RECLEV, &s->sample_spec, &s->real_volume) >= 0)
return;
pa_log_info("Device doesn't support writing mixer settings: %s", pa_cstrerror(errno));
@@ -889,7 +885,6 @@ static void thread_func(void *userdata) {
pa_make_realtime(u->core->realtime_priority);
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
for (;;) {
int ret;
@@ -1457,7 +1452,7 @@ go_on:
pa_memchunk_reset(&u->memchunk);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("oss", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
diff --git a/src/modules/oss/oss-util.c b/src/modules/oss/oss-util.c
index 5a109ae9..04899afe 100644
--- a/src/modules/oss/oss-util.c
+++ b/src/modules/oss/oss-util.c
@@ -31,7 +31,6 @@
#include <string.h>
#include <unistd.h>
#include <sys/types.h>
-#include <sys/stat.h>
#include <fcntl.h>
#include <pulse/xmalloc.h>
@@ -55,7 +54,7 @@ int pa_oss_open(const char *device, int *mode, int* pcaps) {
pcaps = &caps;
if (*mode == O_RDWR) {
- if ((fd = open(device, O_RDWR|O_NDELAY|O_NOCTTY)) >= 0) {
+ if ((fd = pa_open_cloexec(device, O_RDWR|O_NDELAY, 0)) >= 0) {
ioctl(fd, SNDCTL_DSP_SETDUPLEX, 0);
if (ioctl(fd, SNDCTL_DSP_GETCAPS, pcaps) < 0) {
@@ -71,14 +70,14 @@ int pa_oss_open(const char *device, int *mode, int* pcaps) {
pa_close(fd);
}
- if ((fd = open(device, (*mode = O_WRONLY)|O_NDELAY|O_NOCTTY)) < 0) {
- if ((fd = open(device, (*mode = O_RDONLY)|O_NDELAY|O_NOCTTY)) < 0) {
+ if ((fd = pa_open_cloexec(device, (*mode = O_WRONLY)|O_NDELAY, 0)) < 0) {
+ if ((fd = pa_open_cloexec(device, (*mode = O_RDONLY)|O_NDELAY, 0)) < 0) {
pa_log("open('%s'): %s", device, pa_cstrerror(errno));
goto fail;
}
}
} else {
- if ((fd = open(device, *mode|O_NDELAY|O_NOCTTY)) < 0) {
+ if ((fd = pa_open_cloexec(device, *mode|O_NDELAY, 0)) < 0) {
pa_log("open('%s'): %s", device, pa_cstrerror(errno));
goto fail;
}
@@ -145,8 +144,6 @@ success:
pa_log_debug("capabilities:%s", t);
pa_xfree(t);
- pa_make_fd_cloexec(fd);
-
return fd;
fail:
@@ -273,10 +270,10 @@ int pa_oss_get_volume(int fd, unsigned long mixer, const pa_sample_spec *ss, pa_
pa_cvolume_reset(volume, ss->channels);
- volume->values[0] = ((vol & 0xFF) * PA_VOLUME_NORM) / 100;
+ volume->values[0] = PA_CLAMP_VOLUME(((vol & 0xFF) * PA_VOLUME_NORM) / 100);
if (volume->channels >= 2)
- volume->values[1] = (((vol >> 8) & 0xFF) * PA_VOLUME_NORM) / 100;
+ volume->values[1] = PA_CLAMP_VOLUME((((vol >> 8) & 0xFF) * PA_VOLUME_NORM) / 100);
pa_log_debug("Read mixer settings: %s", pa_cvolume_snprint(cv, sizeof(cv), volume));
return 0;
@@ -351,9 +348,9 @@ int pa_oss_get_hw_description(const char *dev, char *name, size_t l) {
if ((n = get_device_number(dev)) < 0)
return -1;
- if (!(f = fopen("/dev/sndstat", "r")) &&
- !(f = fopen("/proc/sndstat", "r")) &&
- !(f = fopen("/proc/asound/oss/sndstat", "r"))) {
+ if (!(f = pa_fopen_cloexec("/dev/sndstat", "r")) &&
+ !(f = pa_fopen_cloexec("/proc/sndstat", "r")) &&
+ !(f = pa_fopen_cloexec("/proc/asound/oss/sndstat", "r"))) {
if (errno != ENOENT)
pa_log_warn("failed to open OSS sndstat device: %s", pa_cstrerror(errno));
@@ -403,7 +400,7 @@ int pa_oss_get_hw_description(const char *dev, char *name, size_t l) {
static int open_mixer(const char *mixer) {
int fd;
- if ((fd = open(mixer, O_RDWR|O_NDELAY|O_NOCTTY)) >= 0)
+ if ((fd = pa_open_cloexec(mixer, O_RDWR|O_NDELAY, 0)) >= 0)
return fd;
return -1;
diff --git a/src/modules/raop/base64.c b/src/modules/raop/base64.c
index e1cbed02..37e47628 100644
--- a/src/modules/raop/base64.c
+++ b/src/modules/raop/base64.c
@@ -38,8 +38,7 @@
static const char base64_chars[] =
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
-static int pos(char c)
-{
+static int pos(char c) {
if (c >= 'A' && c <= 'Z') return c - 'A' + 0;
if (c >= 'a' && c <= 'z') return c - 'a' + 26;
if (c >= '0' && c <= '9') return c - '0' + 52;
@@ -48,8 +47,7 @@ static int pos(char c)
return -1;
}
-int pa_base64_encode(const void *data, int size, char **str)
-{
+int pa_base64_encode(const void *data, int size, char **str) {
char *s, *p;
int i;
int c;
@@ -57,7 +55,6 @@ int pa_base64_encode(const void *data, int size, char **str)
p = s = pa_xnew(char, size * 4 / 3 + 4);
q = (const unsigned char *) data;
- i = 0;
for (i = 0; i < size;) {
c = q[i++];
c *= 256;
@@ -85,8 +82,7 @@ int pa_base64_encode(const void *data, int size, char **str)
#define DECODE_ERROR 0xffffffff
-static unsigned int token_decode(const char *token)
-{
+static unsigned int token_decode(const char *token) {
int i;
unsigned int val = 0;
int marker = 0;
@@ -110,8 +106,7 @@ static unsigned int token_decode(const char *token)
return (marker << 24) | val;
}
-int pa_base64_decode(const char *str, void *data)
-{
+int pa_base64_decode(const char *str, void *data) {
const char *p;
unsigned char *q;
diff --git a/src/modules/module-raop-discover.c b/src/modules/raop/module-raop-discover.c
index eaeb77fc..de1a2b1c 100644
--- a/src/modules/module-raop-discover.c
+++ b/src/modules/raop/module-raop-discover.c
@@ -37,14 +37,9 @@
#include <avahi-common/malloc.h>
#include <pulse/xmalloc.h>
-#include <pulse/util.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/source.h>
-#include <pulsecore/native-common.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-subscribe.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/modargs.h>
#include <pulsecore/namereg.h>
@@ -200,7 +195,7 @@ static void resolver_cb(
if (nicename) {
args = pa_sprintf_malloc("server=%s "
"sink_name=%s "
- "description=\"%s\"",
+ "sink_properties=device.description=\"%s\"",
avahi_address_snprint(at, sizeof(at), a),
vname,
nicename);
@@ -265,7 +260,7 @@ static void browser_cb(
struct tunnel *t2;
if ((t2 = pa_hashmap_get(u->tunnels, t))) {
- pa_module_unload_by_index(u->core, t2->module_index, TRUE);
+ pa_module_unload_request_by_index(u->core, t2->module_index, TRUE);
pa_hashmap_remove(u->tunnels, t2);
tunnel_free(t2);
}
@@ -386,7 +381,7 @@ void pa__done(pa_module*m) {
struct tunnel *t;
while ((t = pa_hashmap_steal_first(u->tunnels))) {
- pa_module_unload_by_index(u->core, t->module_index, TRUE);
+ pa_module_unload_request_by_index(u->core, t->module_index, TRUE);
tunnel_free(t);
}
diff --git a/src/modules/module-raop-sink.c b/src/modules/raop/module-raop-sink.c
index 052a3a5e..87e7bc17 100644
--- a/src/modules/module-raop-sink.c
+++ b/src/modules/raop/module-raop-sink.c
@@ -25,14 +25,10 @@
#endif
#include <stdlib.h>
-#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
#include <string.h>
-#include <fcntl.h>
#include <unistd.h>
-#include <limits.h>
-#include <poll.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/tcp.h>
@@ -42,23 +38,21 @@
#include <linux/sockios.h>
#endif
-#include <pulse/xmalloc.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
+#include <pulse/xmalloc.h>
#include <pulsecore/core-error.h>
-#include <pulsecore/iochannel.h>
#include <pulsecore/sink.h>
#include <pulsecore/module.h>
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
#include <pulsecore/log.h>
#include <pulsecore/socket-client.h>
-#include <pulsecore/authkey.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/thread.h>
#include <pulsecore/time-smoother.h>
-#include <pulsecore/rtclock.h>
-#include <pulsecore/socket-util.h>
+#include <pulsecore/poll.h>
#include "module-raop-sink-symdef.h"
#include "rtp.h"
@@ -124,7 +118,6 @@ static const char* const valid_modargs[] = {
"format",
"rate",
"channels",
- "description", /* supported for compatibility reasons, made redundant by sink_properties= */
NULL
};
@@ -181,7 +174,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
case PA_SINK_SUSPENDED:
pa_assert(PA_SINK_IS_OPENED(u->sink->thread_info.state));
- pa_smoother_pause(u->smoother, pa_rtclock_usec());
+ pa_smoother_pause(u->smoother, pa_rtclock_now());
/* Issue a FLUSH if we are connected */
if (u->fd >= 0) {
@@ -193,7 +186,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
case PA_SINK_RUNNING:
if (u->sink->thread_info.state == PA_SINK_SUSPENDED) {
- pa_smoother_resume(u->smoother, pa_rtclock_usec(), TRUE);
+ pa_smoother_resume(u->smoother, pa_rtclock_now(), TRUE);
/* The connection can be closed when idle, so check to
see if we need to reestablish it */
@@ -216,7 +209,7 @@ static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offse
case PA_SINK_MESSAGE_GET_LATENCY: {
pa_usec_t w, r;
- r = pa_smoother_get(u->smoother, pa_rtclock_usec());
+ r = pa_smoother_get(u->smoother, pa_rtclock_now());
w = pa_bytes_to_usec((u->offset - u->encoding_overhead + (u->encoded_memchunk.length / u->encoding_ratio)), &u->sink->sample_spec);
*((pa_usec_t*) data) = w > r ? w - r : 0;
@@ -282,15 +275,15 @@ static void sink_set_volume_cb(pa_sink *s) {
/* Calculate the max volume of all channels.
We'll use this as our (single) volume on the APEX device and emulate
any variation in channel volumes in software */
- v = pa_cvolume_max(&s->virtual_volume);
+ v = pa_cvolume_max(&s->real_volume);
/* Create a pa_cvolume version of our single value */
pa_cvolume_set(&hw, s->sample_spec.channels, v);
/* Perform any software manipulation of the volume needed */
- pa_sw_cvolume_divide(&s->soft_volume, &s->virtual_volume, &hw);
+ pa_sw_cvolume_divide(&s->soft_volume, &s->real_volume, &hw);
- pa_log_debug("Requested volume: %s", pa_cvolume_snprint(t, sizeof(t), &s->virtual_volume));
+ pa_log_debug("Requested volume: %s", pa_cvolume_snprint(t, sizeof(t), &s->real_volume));
pa_log_debug("Got hardware volume: %s", pa_cvolume_snprint(t, sizeof(t), &hw));
pa_log_debug("Calculated software volume: %s", pa_cvolume_snprint(t, sizeof(t), &s->soft_volume));
@@ -323,9 +316,8 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
pa_thread_mq_install(&u->thread_mq);
- pa_rtpoll_install(u->rtpoll);
- pa_smoother_set_time_offset(u->smoother, pa_rtclock_usec());
+ pa_smoother_set_time_offset(u->smoother, pa_rtclock_now());
/* Create a chunk of memory that is our encoded silence sample. */
pa_memchunk_reset(&silence);
@@ -465,7 +457,7 @@ static void thread_func(void *userdata) {
else
usec = 0;
- pa_smoother_put(u->smoother, pa_rtclock_usec(), usec);
+ pa_smoother_put(u->smoother, pa_rtclock_now(), usec);
}
/* Hmm, nothing to do. Let's sleep */
@@ -514,7 +506,7 @@ int pa__init(pa_module*m) {
struct userdata *u = NULL;
pa_sample_spec ss;
pa_modargs *ma = NULL;
- const char *server, *desc;
+ const char *server;
pa_sink_new_data data;
pa_assert(m);
@@ -583,10 +575,8 @@ int pa__init(pa_module*m) {
pa_sink_new_data_set_name(&data, pa_modargs_get_value(ma, "sink_name", DEFAULT_SINK_NAME));
pa_sink_new_data_set_sample_spec(&data, &ss);
pa_proplist_sets(data.proplist, PA_PROP_DEVICE_STRING, server);
- if ((desc = pa_modargs_get_value(ma, "description", NULL)))
- pa_proplist_sets(data.proplist, PA_PROP_DEVICE_DESCRIPTION, desc);
- else
- pa_proplist_setf(data.proplist, PA_PROP_DEVICE_DESCRIPTION, "RAOP sink '%s'", server);
+ pa_proplist_sets(data.proplist, PA_PROP_DEVICE_INTENDED_ROLES, "music");
+ pa_proplist_setf(data.proplist, PA_PROP_DEVICE_DESCRIPTION, "RAOP sink '%s'", server);
if (pa_modargs_get_proplist(ma, "sink_properties", data.proplist, PA_UPDATE_REPLACE) < 0) {
pa_log("Invalid properties");
@@ -619,7 +609,7 @@ int pa__init(pa_module*m) {
pa_raop_client_set_callback(u->raop, on_connection, u);
pa_raop_client_set_closed_callback(u->raop, on_close, u);
- if (!(u->thread = pa_thread_new(thread_func, u))) {
+ if (!(u->thread = pa_thread_new("raop-sink", thread_func, u))) {
pa_log("Failed to create thread.");
goto fail;
}
diff --git a/src/modules/raop/raop_client.c b/src/modules/raop/raop_client.c
index b3f243c3..cba7af9a 100644
--- a/src/modules/raop/raop_client.c
+++ b/src/modules/raop/raop_client.c
@@ -23,11 +23,9 @@
#include <config.h>
#endif
-#include <fcntl.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
-#include <arpa/inet.h>
#include <unistd.h>
#include <sys/ioctl.h>
@@ -46,18 +44,13 @@
#include <pulsecore/core-error.h>
#include <pulsecore/core-util.h>
+#include <pulsecore/iochannel.h>
#include <pulsecore/socket-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
-#include <pulsecore/strbuf.h>
+#include <pulsecore/memchunk.h>
#include <pulsecore/random.h>
-#ifdef HAVE_POLL_H
-#include <poll.h>
-#else
-#include <pulsecore/poll.h>
-#endif
-
#include "raop_client.h"
#include "rtsp_client.h"
#include "base64.h"
@@ -179,8 +172,7 @@ static int rsa_encrypt(uint8_t *text, int len, uint8_t *res) {
return size;
}
-static int aes_encrypt(pa_raop_client* c, uint8_t *data, int size)
-{
+static int aes_encrypt(pa_raop_client* c, uint8_t *data, int size) {
uint8_t *buf;
int i=0, j;
@@ -199,8 +191,7 @@ static int aes_encrypt(pa_raop_client* c, uint8_t *data, int size)
return i;
}
-static inline void rtrimchar(char *str, char rc)
-{
+static inline void rtrimchar(char *str, char rc) {
char *sp = str + strlen(str) - 1;
while (sp >= str && *sp == rc) {
*sp = '\0';
@@ -228,7 +219,6 @@ static void on_connection(pa_socket_client *sc, pa_iochannel *io, void *userdata
c->fd = pa_iochannel_get_send_fd(io);
pa_iochannel_set_noclose(io, TRUE);
- pa_iochannel_socket_set_sndbuf(io, 1024);
pa_iochannel_free(io);
pa_make_tcp_socket_low_delay(c->fd);
@@ -237,8 +227,7 @@ static void on_connection(pa_socket_client *sc, pa_iochannel *io, void *userdata
c->callback(c->fd, c->userdata);
}
-static void rtsp_cb(pa_rtsp_client *rtsp, pa_rtsp_state state, pa_headerlist* headers, void *userdata)
-{
+static void rtsp_cb(pa_rtsp_client *rtsp, pa_rtsp_state state, pa_headerlist* headers, void *userdata) {
pa_raop_client* c = userdata;
pa_assert(c);
pa_assert(rtsp);
@@ -331,7 +320,7 @@ static void rtsp_cb(pa_rtsp_client *rtsp, pa_rtsp_state state, pa_headerlist* he
uint32_t port = pa_rtsp_serverport(c->rtsp);
pa_log_debug("RAOP: RECORDED");
- if (!(c->sc = pa_socket_client_new_string(c->core->mainloop, c->host, port))) {
+ if (!(c->sc = pa_socket_client_new_string(c->core->mainloop, TRUE, c->host, port))) {
pa_log("failed to connect to server '%s:%d'", c->host, port);
return;
}
@@ -373,8 +362,7 @@ static void rtsp_cb(pa_rtsp_client *rtsp, pa_rtsp_state state, pa_headerlist* he
}
}
-pa_raop_client* pa_raop_client_new(pa_core *core, const char* host)
-{
+pa_raop_client* pa_raop_client_new(pa_core *core, const char* host) {
pa_raop_client* c = pa_xnew0(pa_raop_client, 1);
pa_assert(core);
@@ -392,8 +380,7 @@ pa_raop_client* pa_raop_client_new(pa_core *core, const char* host)
}
-void pa_raop_client_free(pa_raop_client* c)
-{
+void pa_raop_client_free(pa_raop_client* c) {
pa_assert(c);
if (c->rtsp)
@@ -403,8 +390,7 @@ void pa_raop_client_free(pa_raop_client* c)
}
-int pa_raop_connect(pa_raop_client* c)
-{
+int pa_raop_connect(pa_raop_client* c) {
char *sci;
struct {
uint32_t a;
@@ -438,8 +424,7 @@ int pa_raop_connect(pa_raop_client* c)
}
-int pa_raop_flush(pa_raop_client* c)
-{
+int pa_raop_flush(pa_raop_client* c) {
pa_assert(c);
pa_rtsp_flush(c->rtsp, c->seq, c->rtptime);
@@ -447,8 +432,7 @@ int pa_raop_flush(pa_raop_client* c)
}
-int pa_raop_client_set_volume(pa_raop_client* c, pa_volume_t volume)
-{
+int pa_raop_client_set_volume(pa_raop_client* c, pa_volume_t volume) {
int rv;
double db;
char *param;
@@ -470,8 +454,7 @@ int pa_raop_client_set_volume(pa_raop_client* c, pa_volume_t volume)
}
-int pa_raop_client_encode_sample(pa_raop_client* c, pa_memchunk* raw, pa_memchunk* encoded)
-{
+int pa_raop_client_encode_sample(pa_raop_client* c, pa_memchunk* raw, pa_memchunk* encoded) {
uint16_t len;
size_t bufmax;
uint8_t *bp, bpos;
@@ -553,16 +536,14 @@ int pa_raop_client_encode_sample(pa_raop_client* c, pa_memchunk* raw, pa_memchun
}
-void pa_raop_client_set_callback(pa_raop_client* c, pa_raop_client_cb_t callback, void *userdata)
-{
+void pa_raop_client_set_callback(pa_raop_client* c, pa_raop_client_cb_t callback, void *userdata) {
pa_assert(c);
c->callback = callback;
c->userdata = userdata;
}
-void pa_raop_client_set_closed_callback(pa_raop_client* c, pa_raop_client_closed_cb_t callback, void *userdata)
-{
+void pa_raop_client_set_closed_callback(pa_raop_client* c, pa_raop_client_closed_cb_t callback, void *userdata) {
pa_assert(c);
c->closed_callback = callback;
diff --git a/src/modules/raop/raop_client.h b/src/modules/raop/raop_client.h
index 5ad3e3fa..ce81f392 100644
--- a/src/modules/raop/raop_client.h
+++ b/src/modules/raop/raop_client.h
@@ -22,8 +22,6 @@
USA.
***/
-#include <pulse/mainloop-api.h>
-#include <pulsecore/iochannel.h>
#include <pulsecore/core.h>
typedef struct pa_raop_client pa_raop_client;
diff --git a/src/modules/reserve-monitor.c b/src/modules/reserve-monitor.c
new file mode 100644
index 00000000..ab453e61
--- /dev/null
+++ b/src/modules/reserve-monitor.c
@@ -0,0 +1,256 @@
+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: t -*-*/
+
+/***
+ Copyright 2009 Lennart Poettering
+
+ Permission is hereby granted, free of charge, to any person
+ obtaining a copy of this software and associated documentation files
+ (the "Software"), to deal in the Software without restriction,
+ including without limitation the rights to use, copy, modify, merge,
+ publish, distribute, sublicense, and/or sell copies of the Software,
+ and to permit persons to whom the Software is furnished to do so,
+ subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be
+ included in all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+ BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ SOFTWARE.
+***/
+
+#include <string.h>
+#include <unistd.h>
+#include <errno.h>
+#include <stdlib.h>
+#include <stdio.h>
+#include <assert.h>
+
+#include "reserve-monitor.h"
+
+struct rm_monitor {
+ int ref;
+
+ char *device_name;
+ char *service_name;
+ char *match;
+
+ DBusConnection *connection;
+
+ unsigned busy:1;
+ unsigned filtering:1;
+ unsigned matching:1;
+
+ rm_change_cb_t change_cb;
+ void *userdata;
+};
+
+#define SERVICE_PREFIX "org.freedesktop.ReserveDevice1."
+
+#define SERVICE_FILTER \
+ "type='signal'," \
+ "sender='" DBUS_SERVICE_DBUS "'," \
+ "interface='" DBUS_INTERFACE_DBUS "'," \
+ "member='NameOwnerChanged'," \
+ "arg0='%s'"
+
+static DBusHandlerResult filter_handler(
+ DBusConnection *c,
+ DBusMessage *s,
+ void *userdata) {
+
+ rm_monitor *m;
+ DBusError error;
+
+ dbus_error_init(&error);
+
+ m = userdata;
+ assert(m->ref >= 1);
+
+ if (dbus_message_is_signal(s, "org.freedesktop.DBus", "NameOwnerChanged")) {
+ const char *name, *old, *new;
+
+ if (!dbus_message_get_args(
+ s,
+ &error,
+ DBUS_TYPE_STRING, &name,
+ DBUS_TYPE_STRING, &old,
+ DBUS_TYPE_STRING, &new,
+ DBUS_TYPE_INVALID))
+ goto invalid;
+
+ if (strcmp(name, m->service_name) == 0) {
+ m->busy = !!(new && *new);
+
+ /* If we ourselves own the device, then don't consider this 'busy' */
+ if (m->busy) {
+ const char *un;
+
+ if ((un = dbus_bus_get_unique_name(c)))
+ if (strcmp(new, un) == 0)
+ m->busy = FALSE;
+ }
+
+ if (m->change_cb) {
+ m->ref++;
+ m->change_cb(m);
+ rm_release(m);
+ }
+ }
+ }
+
+invalid:
+ dbus_error_free(&error);
+
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+}
+
+int rm_watch(
+ rm_monitor **_m,
+ DBusConnection *connection,
+ const char*device_name,
+ rm_change_cb_t change_cb,
+ DBusError *error) {
+
+ rm_monitor *m = NULL;
+ int r;
+ DBusError _error;
+
+ if (!error)
+ error = &_error;
+
+ dbus_error_init(error);
+
+ if (!_m)
+ return -EINVAL;
+
+ if (!connection)
+ return -EINVAL;
+
+ if (!device_name)
+ return -EINVAL;
+
+ if (!(m = calloc(sizeof(rm_monitor), 1)))
+ return -ENOMEM;
+
+ m->ref = 1;
+
+ if (!(m->device_name = strdup(device_name))) {
+ r = -ENOMEM;
+ goto fail;
+ }
+
+ m->connection = dbus_connection_ref(connection);
+ m->change_cb = change_cb;
+
+ if (!(m->service_name = malloc(sizeof(SERVICE_PREFIX) + strlen(device_name)))) {
+ r = -ENOMEM;
+ goto fail;
+ }
+ sprintf(m->service_name, SERVICE_PREFIX "%s", m->device_name);
+
+ if (!(dbus_connection_add_filter(m->connection, filter_handler, m, NULL))) {
+ r = -ENOMEM;
+ goto fail;
+ }
+
+ m->filtering = 1;
+
+ if (!(m->match = malloc(sizeof(SERVICE_FILTER) - 2 + strlen(m->service_name)))) {
+ r = -ENOMEM;
+ goto fail;
+ }
+
+ sprintf(m->match, SERVICE_FILTER, m->service_name);
+ dbus_bus_add_match(m->connection, m->match, error);
+
+ if (dbus_error_is_set(error)) {
+ r = -EIO;
+ goto fail;
+ }
+
+ m->matching = 1;
+
+ m->busy = dbus_bus_name_has_owner(m->connection, m->service_name, error);
+
+ if (dbus_error_is_set(error)) {
+ r = -EIO;
+ goto fail;
+ }
+
+ *_m = m;
+ return 0;
+
+fail:
+ if (&_error == error)
+ dbus_error_free(&_error);
+
+ if (m)
+ rm_release(m);
+
+ return r;
+}
+
+void rm_release(rm_monitor *m) {
+ if (!m)
+ return;
+
+ assert(m->ref > 0);
+
+ if (--m->ref > 0)
+ return;
+
+ if (m->matching)
+ dbus_bus_remove_match(
+ m->connection,
+ m->match,
+ NULL);
+
+ if (m->filtering)
+ dbus_connection_remove_filter(
+ m->connection,
+ filter_handler,
+ m);
+
+ free(m->device_name);
+ free(m->service_name);
+ free(m->match);
+
+ if (m->connection)
+ dbus_connection_unref(m->connection);
+
+ free(m);
+}
+
+int rm_busy(rm_monitor *m) {
+ if (!m)
+ return -EINVAL;
+
+ assert(m->ref > 0);
+
+ return m->busy;
+}
+
+void rm_set_userdata(rm_monitor *m, void *userdata) {
+
+ if (!m)
+ return;
+
+ assert(m->ref > 0);
+ m->userdata = userdata;
+}
+
+void* rm_get_userdata(rm_monitor *m) {
+
+ if (!m)
+ return NULL;
+
+ assert(m->ref > 0);
+
+ return m->userdata;
+}
diff --git a/src/modules/reserve-monitor.h b/src/modules/reserve-monitor.h
new file mode 100644
index 00000000..3408680f
--- /dev/null
+++ b/src/modules/reserve-monitor.h
@@ -0,0 +1,71 @@
+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: t -*-*/
+
+#ifndef fooreservemonitorhfoo
+#define fooreservemonitorhfoo
+
+/***
+ Copyright 2009 Lennart Poettering
+
+ Permission is hereby granted, free of charge, to any person
+ obtaining a copy of this software and associated documentation files
+ (the "Software"), to deal in the Software without restriction,
+ including without limitation the rights to use, copy, modify, merge,
+ publish, distribute, sublicense, and/or sell copies of the Software,
+ and to permit persons to whom the Software is furnished to do so,
+ subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be
+ included in all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+ BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ SOFTWARE.
+***/
+
+#include <dbus/dbus.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef struct rm_monitor rm_monitor;
+
+/* Prototype for a function that is called whenever the reservation
+ * device of a device changes. Use rm_monitor_busy() to find out the
+ * new state.*/
+typedef void (*rm_change_cb_t)(rm_monitor *m);
+
+/* Creates a monitor for watching the lock status of a device. Returns
+ * 0 on success, a negative errno style return value on error. The
+ * DBus error might be set as well if the error was caused D-Bus. */
+int rm_watch(
+ rm_monitor **m, /* On success a pointer to the newly allocated rm_device object will be filled in here */
+ DBusConnection *connection, /* Session bus (when D-Bus learns about user busses we should switchg to user busses) */
+ const char *device_name, /* The device to monitor, e.g. "Audio0" */
+ rm_change_cb_t change_cb, /* Will be called whenever the lock status changes. May be NULL */
+ DBusError *error); /* If we fail due to a D-Bus related issue the error will be filled in here. May be NULL. */
+
+/* Free a rm_monitor object */
+void rm_release(rm_monitor *m);
+
+/* Checks whether the device is currently reserved, and returns 1
+ * then, 0 if not, negative errno style error code value on error. */
+int rm_busy(rm_monitor *m);
+
+/* Attach a userdata pointer to an rm_monitor */
+void rm_set_userdata(rm_monitor *m, void *userdata);
+
+/* Query the userdata pointer from an rm_monitor. Returns NULL if no
+ * userdata was set. */
+void* rm_get_userdata(rm_monitor *m);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
diff --git a/src/modules/reserve-wrap.c b/src/modules/reserve-wrap.c
index d0d014d3..4be19c73 100644
--- a/src/modules/reserve-wrap.c
+++ b/src/modules/reserve-wrap.c
@@ -35,6 +35,7 @@
#ifdef HAVE_DBUS
#include <pulsecore/dbus-shared.h>
#include "reserve.h"
+#include "reserve-monitor.h"
#endif
#include "reserve-wrap.h"
@@ -50,6 +51,17 @@ struct pa_reserve_wrapper {
#endif
};
+struct pa_reserve_monitor_wrapper {
+ PA_REFCNT_DECLARE;
+ pa_core *core;
+ pa_hook hook;
+ char *shared_name;
+#ifdef HAVE_DBUS
+ pa_dbus_connection *connection;
+ struct rm_monitor *monitor;
+#endif
+};
+
static void reserve_wrapper_free(pa_reserve_wrapper *r) {
pa_assert(r);
@@ -83,7 +95,7 @@ static int request_cb(rd_device *d, int forced) {
PA_REFCNT_INC(r);
k = pa_hook_fire(&r->hook, PA_INT_TO_PTR(forced));
- pa_log_debug("Device unlock has been requested and %s.", k < 0 ? "failed" : "succeeded");
+ pa_log_debug("Device unlock of %s has been requested and %s.", r->shared_name, k < 0 ? "failed" : "succeeded");
pa_reserve_wrapper_unref(r);
@@ -125,7 +137,7 @@ pa_reserve_wrapper* pa_reserve_wrapper_get(pa_core *c, const char *device_name)
#ifdef HAVE_DBUS
if (!(r->connection = pa_dbus_bus_get(c, DBUS_BUS_SESSION, &error)) || dbus_error_is_set(&error)) {
- pa_log_warn("Unable to contact D-Bus session bus: %s: %s", error.name, error.message);
+ pa_log_debug("Unable to contact D-Bus session bus: %s: %s", error.name, error.message);
/* We don't treat this as error here because we want allow PA
* to run even when no session bus is available. */
@@ -142,10 +154,10 @@ pa_reserve_wrapper* pa_reserve_wrapper_get(pa_core *c, const char *device_name)
NULL)) < 0) {
if (k == -EBUSY) {
- pa_log_error("Device '%s' already locked.", device_name);
+ pa_log_debug("Device '%s' already locked.", device_name);
goto fail;
} else {
- pa_log_warn("Failed to acquire reservation lock on device '%s': %s", device_name, pa_cstrerror(-k));
+ pa_log_debug("Failed to acquire reservation lock on device '%s': %s", device_name, pa_cstrerror(-k));
return r;
}
}
@@ -191,3 +203,142 @@ void pa_reserve_wrapper_set_application_device_name(pa_reserve_wrapper *r, const
rd_set_application_device_name(r->device, name);
#endif
}
+
+static void reserve_monitor_wrapper_free(pa_reserve_monitor_wrapper *w) {
+ pa_assert(w);
+
+#ifdef HAVE_DBUS
+ if (w->monitor)
+ rm_release(w->monitor);
+
+ if (w->connection)
+ pa_dbus_connection_unref(w->connection);
+#endif
+
+ pa_hook_done(&w->hook);
+
+ if (w->shared_name) {
+ pa_assert_se(pa_shared_remove(w->core, w->shared_name) >= 0);
+ pa_xfree(w->shared_name);
+ }
+
+ pa_xfree(w);
+}
+
+#ifdef HAVE_DBUS
+static void change_cb(rm_monitor *m) {
+ pa_reserve_monitor_wrapper *w;
+ int k;
+
+ pa_assert(m);
+ pa_assert_se(w = rm_get_userdata(m));
+ pa_assert(PA_REFCNT_VALUE(w) >= 1);
+
+ PA_REFCNT_INC(w);
+
+ if ((k = rm_busy(w->monitor)) < 0)
+ return;
+
+ pa_hook_fire(&w->hook, PA_INT_TO_PTR(!!k));
+ pa_log_debug("Device lock status of %s changed: %s", w->shared_name, k ? "busy" : "not busy");
+
+ pa_reserve_monitor_wrapper_unref(w);
+}
+#endif
+
+pa_reserve_monitor_wrapper* pa_reserve_monitor_wrapper_get(pa_core *c, const char *device_name) {
+ pa_reserve_monitor_wrapper *w;
+ int k;
+ char *t;
+#ifdef HAVE_DBUS
+ DBusError error;
+
+ dbus_error_init(&error);
+#endif
+
+ pa_assert(c);
+ pa_assert(device_name);
+
+ t = pa_sprintf_malloc("reserve-monitor-wrapper@%s", device_name);
+
+ if ((w = pa_shared_get(c, t))) {
+ pa_xfree(t);
+
+ pa_assert(PA_REFCNT_VALUE(w) >= 1);
+ PA_REFCNT_INC(w);
+
+ return w;
+ }
+
+ w = pa_xnew0(pa_reserve_monitor_wrapper, 1);
+ PA_REFCNT_INIT(w);
+ w->core = c;
+ pa_hook_init(&w->hook, w);
+ w->shared_name = t;
+
+ pa_assert_se(pa_shared_set(c, w->shared_name, w) >= 0);
+
+#ifdef HAVE_DBUS
+ if (!(w->connection = pa_dbus_bus_get(c, DBUS_BUS_SESSION, &error)) || dbus_error_is_set(&error)) {
+ pa_log_debug("Unable to contact D-Bus session bus: %s: %s", error.name, error.message);
+
+ /* We don't treat this as error here because we want allow PA
+ * to run even when no session bus is available. */
+ return w;
+ }
+
+ if ((k = rm_watch(
+ &w->monitor,
+ pa_dbus_connection_get(w->connection),
+ device_name,
+ change_cb,
+ NULL)) < 0) {
+
+ pa_log_debug("Failed to create watch on device '%s': %s", device_name, pa_cstrerror(-k));
+ goto fail;
+ }
+
+ pa_log_debug("Successfully create reservation lock monitor for device '%s'", device_name);
+
+ rm_set_userdata(w->monitor, w);
+ return w;
+
+fail:
+ dbus_error_free(&error);
+
+ reserve_monitor_wrapper_free(w);
+
+ return NULL;
+#else
+ return w;
+#endif
+}
+
+void pa_reserve_monitor_wrapper_unref(pa_reserve_monitor_wrapper *w) {
+ pa_assert(w);
+ pa_assert(PA_REFCNT_VALUE(w) >= 1);
+
+ if (PA_REFCNT_DEC(w) > 0)
+ return;
+
+ reserve_monitor_wrapper_free(w);
+}
+
+pa_hook* pa_reserve_monitor_wrapper_hook(pa_reserve_monitor_wrapper *w) {
+ pa_assert(w);
+ pa_assert(PA_REFCNT_VALUE(w) >= 1);
+
+ return &w->hook;
+}
+
+pa_bool_t pa_reserve_monitor_wrapper_busy(pa_reserve_monitor_wrapper *w) {
+ pa_assert(w);
+
+ pa_assert(PA_REFCNT_VALUE(w) >= 1);
+
+#ifdef HAVE_DBUS
+ return rm_busy(w->monitor) > 0;
+#else
+ return FALSE;
+#endif
+}
diff --git a/src/modules/reserve-wrap.h b/src/modules/reserve-wrap.h
index 2b97c91c..2de6c093 100644
--- a/src/modules/reserve-wrap.h
+++ b/src/modules/reserve-wrap.h
@@ -28,11 +28,18 @@
typedef struct pa_reserve_wrapper pa_reserve_wrapper;
pa_reserve_wrapper* pa_reserve_wrapper_get(pa_core *c, const char *device_name);
-
void pa_reserve_wrapper_unref(pa_reserve_wrapper *r);
pa_hook* pa_reserve_wrapper_hook(pa_reserve_wrapper *r);
void pa_reserve_wrapper_set_application_device_name(pa_reserve_wrapper *r, const char *name);
+typedef struct pa_reserve_monitor_wrapper pa_reserve_monitor_wrapper;
+
+pa_reserve_monitor_wrapper* pa_reserve_monitor_wrapper_get(pa_core *c, const char *device_name);
+void pa_reserve_monitor_wrapper_unref(pa_reserve_monitor_wrapper *m);
+
+pa_hook* pa_reserve_monitor_wrapper_hook(pa_reserve_monitor_wrapper *m);
+pa_bool_t pa_reserve_monitor_wrapper_busy(pa_reserve_monitor_wrapper *m);
+
#endif
diff --git a/src/modules/reserve.c b/src/modules/reserve.c
index 9a9591d2..b4c168cf 100644
--- a/src/modules/reserve.c
+++ b/src/modules/reserve.c
@@ -1,3 +1,5 @@
+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: t -*-*/
+
/***
Copyright 2009 Lennart Poettering
@@ -43,16 +45,15 @@ struct rd_device {
DBusConnection *connection;
- int owning:1;
- int registered:1;
- int filtering:1;
- int gave_up:1;
+ unsigned owning:1;
+ unsigned registered:1;
+ unsigned filtering:1;
+ unsigned gave_up:1;
rd_request_cb_t request_cb;
void *userdata;
};
-
#define SERVICE_PREFIX "org.freedesktop.ReserveDevice1."
#define OBJECT_PREFIX "/org/freedesktop/ReserveDevice1/"
@@ -290,13 +291,13 @@ static DBusHandlerResult filter_handler(
DBusMessage *m,
void *userdata) {
- DBusMessage *reply;
rd_device *d;
DBusError error;
dbus_error_init(&error);
d = userdata;
+ assert(d->ref >= 1);
if (dbus_message_is_signal(m, "org.freedesktop.DBus", "NameLost")) {
const char *name;
@@ -321,35 +322,13 @@ static DBusHandlerResult filter_handler(
rd_release(d);
}
- return DBUS_HANDLER_RESULT_HANDLED;
}
}
- return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
-
invalid:
- if (!(reply = dbus_message_new_error(
- m,
- DBUS_ERROR_INVALID_ARGS,
- "Invalid arguments")))
- goto oom;
-
- if (!dbus_connection_send(c, reply, NULL))
- goto oom;
-
- dbus_message_unref(reply);
-
dbus_error_free(&error);
- return DBUS_HANDLER_RESULT_HANDLED;
-
-oom:
- if (reply)
- dbus_message_unref(reply);
-
- dbus_error_free(&error);
-
- return DBUS_HANDLER_RESULT_NEED_MEMORY;
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
}
@@ -560,7 +539,7 @@ void rd_release(
assert(d->ref > 0);
- if (--d->ref)
+ if (--d->ref > 0)
return;
@@ -575,17 +554,11 @@ void rd_release(
d->connection,
d->object_path);
- if (d->owning) {
- DBusError error;
- dbus_error_init(&error);
-
+ if (d->owning)
dbus_bus_release_name(
d->connection,
d->service_name,
- &error);
-
- dbus_error_free(&error);
- }
+ NULL);
free(d->device_name);
free(d->application_name);
diff --git a/src/modules/reserve.h b/src/modules/reserve.h
index b315a08c..9ae49cf5 100644
--- a/src/modules/reserve.h
+++ b/src/modules/reserve.h
@@ -1,3 +1,5 @@
+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: t -*-*/
+
#ifndef fooreservehfoo
#define fooreservehfoo
@@ -28,6 +30,10 @@
#include <dbus/dbus.h>
#include <inttypes.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
typedef struct rd_device rd_device;
/* Prototype for a function that is called whenever someone else wants
@@ -45,7 +51,7 @@ typedef int (*rd_request_cb_t)(
* the error was caused D-Bus. */
int rd_acquire(
rd_device **d, /* On success a pointer to the newly allocated rd_device object will be filled in here */
- DBusConnection *connection,
+ DBusConnection *connection, /* Session bus (when D-Bus learns about user busses we should switchg to user busses) */
const char *device_name, /* The device to lock, e.g. "Audio0" */
const char *application_name, /* A human readable name of the application, e.g. "PulseAudio Sound Server" */
int32_t priority, /* The priority for this application. If unsure use 0 */
@@ -66,4 +72,8 @@ void rd_set_userdata(rd_device *d, void *userdata);
* userdata was set. */
void* rd_get_userdata(rd_device *d);
+#ifdef __cplusplus
+}
+#endif
+
#endif
diff --git a/src/modules/rtp/Makefile b/src/modules/rtp/Makefile
deleted file mode 120000
index efe5a336..00000000
--- a/src/modules/rtp/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../../pulse/Makefile \ No newline at end of file
diff --git a/src/modules/rtp/module-rtp-recv.c b/src/modules/rtp/module-rtp-recv.c
index c61d2d8b..7025c15a 100644
--- a/src/modules/rtp/module-rtp-recv.c
+++ b/src/modules/rtp/module-rtp-recv.c
@@ -27,12 +27,12 @@
#include <stdio.h>
#include <sys/socket.h>
#include <netinet/in.h>
-#include <arpa/inet.h>
#include <errno.h>
#include <string.h>
#include <unistd.h>
-#include <poll.h>
+#include <math.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
@@ -43,17 +43,17 @@
#include <pulsecore/sink-input.h>
#include <pulsecore/memblockq.h>
#include <pulsecore/log.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/modargs.h>
#include <pulsecore/namereg.h>
#include <pulsecore/sample-util.h>
#include <pulsecore/macro.h>
-#include <pulsecore/atomic.h>
-#include <pulsecore/rtclock.h>
-#include <pulsecore/atomic.h>
-#include <pulsecore/time-smoother.h>
#include <pulsecore/socket-util.h>
+#include <pulsecore/atomic.h>
#include <pulsecore/once.h>
+#include <pulsecore/poll.h>
+#include <pulsecore/arpa-inet.h>
#include "module-rtp-recv-symdef.h"
@@ -62,7 +62,7 @@
#include "sap.h"
PA_MODULE_AUTHOR("Lennart Poettering");
-PA_MODULE_DESCRIPTION("Recieve data from a network via RTP/SAP/SDP");
+PA_MODULE_DESCRIPTION("Receive data from a network via RTP/SAP/SDP");
PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(FALSE);
PA_MODULE_USAGE(
@@ -103,15 +103,18 @@ struct session {
pa_atomic_t timestamp;
- pa_smoother *smoother;
pa_usec_t intended_latency;
pa_usec_t sink_latency;
pa_usec_t last_rate_update;
+ pa_usec_t last_latency;
+ double estimated_rate;
+ double avg_estimated_rate;
};
struct userdata {
pa_module *module;
+ pa_core *core;
pa_sap_context sap_context;
pa_io_event* sap_event;
@@ -192,10 +195,9 @@ static void sink_input_suspend_within_thread(pa_sink_input* i, pa_bool_t b) {
pa_sink_input_assert_ref(i);
pa_assert_se(s = i->userdata);
- if (b) {
- pa_smoother_pause(s->smoother, pa_rtclock_usec());
+ if (b)
pa_memblockq_flush_read(s->memblockq);
- } else
+ else
s->first_packet = FALSE;
}
@@ -264,11 +266,6 @@ static int rtpoll_work_cb(pa_rtpoll_item *i) {
} else
pa_rtclock_from_wallclock(&now);
- pa_smoother_put(s->smoother, pa_timeval_load(&now), pa_bytes_to_usec((uint64_t) pa_memblockq_get_write_index(s->memblockq), &s->sink_input->sample_spec));
-
- /* Tell the smoother that we are rolling now, in case it is still paused */
- pa_smoother_resume(s->smoother, pa_timeval_load(&now), TRUE);
-
if (pa_memblockq_push(s->memblockq, &chunk) < 0) {
pa_log_warn("Queue overrun");
pa_memblockq_seek(s->memblockq, (int64_t) chunk.length, PA_SEEK_RELATIVE, TRUE);
@@ -284,12 +281,15 @@ static int rtpoll_work_cb(pa_rtpoll_item *i) {
pa_atomic_store(&s->timestamp, (int) now.tv_sec);
if (s->last_rate_update + RATE_UPDATE_INTERVAL < pa_timeval_load(&now)) {
- pa_usec_t wi, ri, render_delay, sink_delay = 0, latency, fix;
- unsigned fix_samples;
+ pa_usec_t wi, ri, render_delay, sink_delay = 0, latency;
+ uint32_t base_rate = s->sink_input->sink->sample_spec.rate;
+ uint32_t current_rate = s->sink_input->sample_spec.rate;
+ uint32_t new_rate;
+ double estimated_rate, alpha = 0.02;
pa_log_debug("Updating sample rate");
- wi = pa_smoother_get(s->smoother, pa_timeval_load(&now));
+ wi = pa_bytes_to_usec((uint64_t) pa_memblockq_get_write_index(s->memblockq), &s->sink_input->sample_spec);
ri = pa_bytes_to_usec((uint64_t) pa_memblockq_get_read_index(s->memblockq), &s->sink_input->sample_spec);
pa_log_debug("wi=%lu ri=%lu", (unsigned long) wi, (unsigned long) ri);
@@ -307,30 +307,61 @@ static int rtpoll_work_cb(pa_rtpoll_item *i) {
else
latency = wi - ri;
- pa_log_debug("Write index deviates by %0.2f ms, expected %0.2f ms", (double) latency/PA_USEC_PER_MSEC, (double) s->intended_latency/PA_USEC_PER_MSEC);
-
- /* Calculate deviation */
- if (latency < s->intended_latency)
- fix = s->intended_latency - latency;
- else
- fix = latency - s->intended_latency;
-
- /* How many samples is this per second? */
- fix_samples = (unsigned) (fix * (pa_usec_t) s->sink_input->thread_info.sample_spec.rate / (pa_usec_t) RATE_UPDATE_INTERVAL);
-
- /* Check if deviation is in bounds */
- if (fix_samples > s->sink_input->sample_spec.rate*.50)
- pa_log_debug("Hmmm, rate fix is too large (%lu Hz), not applying.", (unsigned long) fix_samples);
- else {
- /* Fix up rate */
- if (latency < s->intended_latency)
- s->sink_input->sample_spec.rate -= fix_samples;
- else
- s->sink_input->sample_spec.rate += fix_samples;
-
- if (s->sink_input->sample_spec.rate > PA_RATE_MAX)
- s->sink_input->sample_spec.rate = PA_RATE_MAX;
+ pa_log_debug("Write index deviates by %0.2f ms, expected %0.2f ms", (double) latency/PA_USEC_PER_MSEC, (double) s->intended_latency/PA_USEC_PER_MSEC);
+
+ /* The buffer is filling with some unknown rate RÌ‚ samples/second. If the rate of reading in
+ * the last T seconds was Râ¿, then the increase in buffer latency ΔLâ¿ = Lâ¿ - Lâ¿â»â± in that
+ * same period is ΔLâ¿ = (TRÌ‚ - TRâ¿) / RÌ‚, giving the estimated target rate
+ * T
+ * R̂ = ─────────────── R⿠. (1)
+ * T - (Lâ¿ - Lâ¿â»â±)
+ *
+ * Setting the sample rate to RÌ‚ results in the latency being constant (if the estimate of RÌ‚
+ * is correct). But there is also the requirement to keep the buffer at a predefined target
+ * latency LÌ‚. So instead of setting Râ¿âºâ± to RÌ‚ immediately, the strategy will be to reduce R
+ * from Râ¿âºâ± to RÌ‚ in a steps of T seconds, where Râ¿âºâ± is chosen such that in the total time
+ * aT the latency is reduced from Lâ¿ to LÌ‚. This strategy translates to the requirements
+ * â‚ RÌ‚ - Râ¿âºÊ² a-j+1 j-1
+ * Σ T ────────── = LÌ‚ - Lâ¿ with Râ¿âºÊ² = ───── Râ¿âºâ± + ───── RÌ‚ .
+ * ʲâ¼â± RÌ‚ a a
+ * Solving for Râ¿âºâ± gives
+ * T - ²∕â‚₊â‚(LÌ‚ - Lâ¿)
+ * Râ¿âºâ± = ───────────────── RÌ‚ . (2)
+ * T
+ * In the code below a = 7 is used.
+ *
+ * Equation (1) is not directly used in (2), but instead an exponentially weighted average
+ * of the estimated rate RÌ‚ is used. This average RÌ… is defined as
+ * RÌ…â¿ = α R̂⿠+ (1-α) RÌ…â¿â»â± .
+ * Because it is difficult to find a fixed value for the coefficient α such that the
+ * averaging is without significant lag but oscillations are filtered out, a heuristic is
+ * used. When the successive estimates R̂⿠do not change much then α→1, but when there is a
+ * sudden spike in the estimated rate α→0, such that the deviation is given little weight.
+ */
+ estimated_rate = (double) current_rate * (double) RATE_UPDATE_INTERVAL / (double) (RATE_UPDATE_INTERVAL + s->last_latency - latency);
+ if (fabs(s->estimated_rate - s->avg_estimated_rate) > 1) {
+ double ratio = (estimated_rate + s->estimated_rate - 2*s->avg_estimated_rate) / (s->estimated_rate - s->avg_estimated_rate);
+ alpha = PA_CLAMP(2 * (ratio + fabs(ratio)) / (4 + ratio*ratio), 0.02, 0.8);
}
+ s->avg_estimated_rate = alpha * estimated_rate + (1-alpha) * s->avg_estimated_rate;
+ s->estimated_rate = estimated_rate;
+ pa_log_debug("Estimated target rate: %.0f Hz, using average of %.0f Hz (α=%.3f)", estimated_rate, s->avg_estimated_rate, alpha);
+ new_rate = (uint32_t) ((double) (RATE_UPDATE_INTERVAL + latency/4 - s->intended_latency/4) / (double) RATE_UPDATE_INTERVAL * s->avg_estimated_rate);
+ s->last_latency = latency;
+
+ if (new_rate < (uint32_t) (base_rate*0.8) || new_rate > (uint32_t) (base_rate*1.25)) {
+ pa_log_warn("Sample rates too different, not adjusting (%u vs. %u).", base_rate, new_rate);
+ new_rate = base_rate;
+ } else {
+ if (base_rate < new_rate + 20 && new_rate < base_rate + 20)
+ new_rate = base_rate;
+ /* Do the adjustment in small steps; 2‰ can be considered inaudible */
+ if (new_rate < (uint32_t) (current_rate*0.998) || new_rate > (uint32_t) (current_rate*1.002)) {
+ pa_log_info("New rate of %u Hz not within 2‰ of %u Hz, forcing smaller adjustment", new_rate, current_rate);
+ new_rate = PA_CLAMP(new_rate, (uint32_t) (current_rate*0.998), (uint32_t) (current_rate*1.002));
+ }
+ }
+ s->sink_input->sample_spec.rate = new_rate;
pa_assert(pa_sample_spec_valid(&s->sink_input->sample_spec));
@@ -344,7 +375,9 @@ static int rtpoll_work_cb(pa_rtpoll_item *i) {
if (pa_memblockq_is_readable(s->memblockq) &&
s->sink_input->thread_info.underrun_for > 0) {
pa_log_debug("Requesting rewind due to end of underrun");
- pa_sink_input_request_rewind(s->sink_input, 0, FALSE, TRUE, FALSE);
+ pa_sink_input_request_rewind(s->sink_input,
+ (size_t) (s->sink_input->thread_info.underrun_for == (uint64_t) -1 ? 0 : s->sink_input->thread_info.underrun_for),
+ FALSE, TRUE, FALSE);
}
return 1;
@@ -359,7 +392,7 @@ static void sink_input_attach(pa_sink_input *i) {
pa_assert_se(s = i->userdata);
pa_assert(!s->rtpoll_item);
- s->rtpoll_item = pa_rtpoll_item_new(i->sink->rtpoll, PA_RTPOLL_LATE, 1);
+ s->rtpoll_item = pa_rtpoll_item_new(i->sink->thread_info.rtpoll, PA_RTPOLL_LATE, 1);
p = pa_rtpoll_item_get_pollfd(s->rtpoll_item, NULL);
p->fd = s->rtp_context.fd;
@@ -388,7 +421,7 @@ static int mcast_socket(const struct sockaddr* sa, socklen_t salen) {
pa_assert(salen > 0);
af = sa->sa_family;
- if ((fd = socket(af, SOCK_DGRAM, 0)) < 0) {
+ if ((fd = pa_socket_cloexec(af, SOCK_DGRAM, 0)) < 0) {
pa_log("Failed to create socket: %s", pa_cstrerror(errno));
goto fail;
}
@@ -469,22 +502,17 @@ static struct session *session_new(struct userdata *u, const pa_sdp_info *sdp_in
s->sdp_info = *sdp_info;
s->rtpoll_item = NULL;
s->intended_latency = LATENCY_USEC;
- s->smoother = pa_smoother_new(
- PA_USEC_PER_SEC*5,
- PA_USEC_PER_SEC*2,
- TRUE,
- TRUE,
- 10,
- pa_timeval_load(&now),
- TRUE);
s->last_rate_update = pa_timeval_load(&now);
+ s->last_latency = LATENCY_USEC;
+ s->estimated_rate = (double) sink->sample_spec.rate;
+ s->avg_estimated_rate = (double) sink->sample_spec.rate;
pa_atomic_store(&s->timestamp, (int) now.tv_sec);
if ((fd = mcast_socket((const struct sockaddr*) &sdp_info->sa, sdp_info->salen)) < 0)
goto fail;
pa_sink_input_new_data_init(&data);
- data.sink = sink;
+ pa_sink_input_new_data_set_sink(&data, sink, FALSE);
data.driver = __FILE__;
pa_proplist_sets(data.proplist, PA_PROP_MEDIA_ROLE, "stream");
pa_proplist_setf(data.proplist, PA_PROP_MEDIA_NAME,
@@ -499,8 +527,9 @@ static struct session *session_new(struct userdata *u, const pa_sdp_info *sdp_in
pa_proplist_setf(data.proplist, "rtp.payload", "%u", (unsigned) sdp_info->payload);
data.module = u->module;
pa_sink_input_new_data_set_sample_spec(&data, &sdp_info->sample_spec);
+ data.flags = PA_SINK_INPUT_VARIABLE_RATE;
- pa_sink_input_new(&s->sink_input, u->module->core, &data, PA_SINK_INPUT_VARIABLE_RATE);
+ pa_sink_input_new(&s->sink_input, u->module->core, &data);
pa_sink_input_new_data_done(&data);
if (!s->sink_input) {
@@ -576,8 +605,6 @@ static void session_free(struct session *s) {
pa_sdp_info_destroy(&s->sdp_info);
pa_rtp_context_destroy(&s->rtp_context);
- pa_smoother_free(s->smoother);
-
pa_xfree(s);
}
@@ -621,15 +648,13 @@ static void sap_event_cb(pa_mainloop_api *m, pa_io_event *e, int fd, pa_io_event
}
}
-static void check_death_event_cb(pa_mainloop_api *m, pa_time_event *t, const struct timeval *ptv, void *userdata) {
+static void check_death_event_cb(pa_mainloop_api *m, pa_time_event *t, const struct timeval *tv, void *userdata) {
struct session *s, *n;
struct userdata *u = userdata;
struct timeval now;
- struct timeval tv;
pa_assert(m);
pa_assert(t);
- pa_assert(ptv);
pa_assert(u);
pa_rtclock_get(&now);
@@ -647,9 +672,7 @@ static void check_death_event_cb(pa_mainloop_api *m, pa_time_event *t, const str
}
/* Restart timer */
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, DEATH_TIMEOUT*PA_USEC_PER_SEC);
- m->time_restart(t, &tv);
+ pa_core_rttime_restart(u->module->core, t, pa_rtclock_now() + DEATH_TIMEOUT * PA_USEC_PER_SEC);
}
int pa__init(pa_module*m) {
@@ -663,7 +686,6 @@ int pa__init(pa_module*m) {
socklen_t salen;
const char *sap_address;
int fd = -1;
- struct timeval tv;
pa_assert(m);
@@ -696,6 +718,7 @@ int pa__init(pa_module*m) {
m->userdata = u = pa_xnew(struct userdata, 1);
u->module = m;
+ u->core = m->core;
u->sink_name = pa_xstrdup(pa_modargs_get_value(ma, "sink", NULL));
u->sap_event = m->core->mainloop->io_new(m->core->mainloop, fd, PA_IO_EVENT_INPUT, sap_event_cb, u);
@@ -705,9 +728,7 @@ int pa__init(pa_module*m) {
u->n_sessions = 0;
u->by_origin = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, DEATH_TIMEOUT * PA_USEC_PER_SEC);
- u->check_death_event = m->core->mainloop->time_new(m->core->mainloop, &tv, check_death_event_cb, u);
+ u->check_death_event = pa_core_rttime_new(m->core, pa_rtclock_now() + DEATH_TIMEOUT * PA_USEC_PER_SEC, check_death_event_cb, u);
pa_modargs_free(ma);
diff --git a/src/modules/rtp/module-rtp-send.c b/src/modules/rtp/module-rtp-send.c
index cdd2c57d..7131629c 100644
--- a/src/modules/rtp/module-rtp-send.c
+++ b/src/modules/rtp/module-rtp-send.c
@@ -26,18 +26,16 @@
#include <stdio.h>
#include <sys/socket.h>
#include <netinet/in.h>
-#include <arpa/inet.h>
#include <errno.h>
-#include <string.h>
#include <unistd.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/util.h>
#include <pulse/xmalloc.h>
#include <pulsecore/core-error.h>
#include <pulsecore/module.h>
-#include <pulsecore/llist.h>
#include <pulsecore/source.h>
#include <pulsecore/source-output.h>
#include <pulsecore/memblockq.h>
@@ -48,6 +46,7 @@
#include <pulsecore/sample-util.h>
#include <pulsecore/macro.h>
#include <pulsecore/socket-util.h>
+#include <pulsecore/arpa-inet.h>
#include "module-rtp-send-symdef.h"
@@ -77,7 +76,7 @@ PA_MODULE_USAGE(
#define DEFAULT_DESTINATION "224.0.0.56"
#define MEMBLOCKQ_MAXLENGTH (1024*170)
#define DEFAULT_MTU 1280
-#define SAP_INTERVAL 5
+#define SAP_INTERVAL (5*PA_USEC_PER_SEC)
static const char* const valid_modargs[] = {
"source",
@@ -151,18 +150,14 @@ static void source_output_kill(pa_source_output* o) {
static void sap_event_cb(pa_mainloop_api *m, pa_time_event *t, const struct timeval *tv, void *userdata) {
struct userdata *u = userdata;
- struct timeval next;
pa_assert(m);
pa_assert(t);
- pa_assert(tv);
pa_assert(u);
pa_sap_send(&u->sap_context, 0);
- pa_gettimeofday(&next);
- pa_timeval_add(&next, SAP_INTERVAL * PA_USEC_PER_SEC);
- m->time_restart(t, &next);
+ pa_core_rttime_restart(u->module->core, t, pa_rtclock_now() + SAP_INTERVAL);
}
int pa__init(pa_module*m) {
@@ -186,7 +181,6 @@ int pa__init(pa_module*m) {
char *p;
int r, j;
socklen_t k;
- struct timeval tv;
char hn[128], *n;
pa_bool_t loop = FALSE;
pa_source_output_new_data data;
@@ -266,7 +260,7 @@ int pa__init(pa_module*m) {
goto fail;
}
- if ((fd = socket(af, SOCK_DGRAM, 0)) < 0) {
+ if ((fd = pa_socket_cloexec(af, SOCK_DGRAM, 0)) < 0) {
pa_log("socket() failed: %s", pa_cstrerror(errno));
goto fail;
}
@@ -281,7 +275,7 @@ int pa__init(pa_module*m) {
#endif
}
- if ((sap_fd = socket(af, SOCK_DGRAM, 0)) < 0) {
+ if ((sap_fd = pa_socket_cloexec(af, SOCK_DGRAM, 0)) < 0) {
pa_log("socket() failed: %s", pa_cstrerror(errno));
goto fail;
}
@@ -320,8 +314,6 @@ int pa__init(pa_module*m) {
/* If the socket queue is full, let's drop packets */
pa_make_fd_nonblock(fd);
pa_make_udp_socket_low_delay(fd);
- pa_make_fd_cloexec(fd);
- pa_make_fd_cloexec(sap_fd);
pa_source_output_new_data_init(&data);
pa_proplist_sets(data.proplist, PA_PROP_MEDIA_NAME, "RTP Monitor Stream");
@@ -331,11 +323,12 @@ int pa__init(pa_module*m) {
pa_proplist_setf(data.proplist, "rtp.ttl", "%lu", (unsigned long) ttl);
data.driver = __FILE__;
data.module = m;
- data.source = s;
+ pa_source_output_new_data_set_source(&data, s, FALSE);
pa_source_output_new_data_set_sample_spec(&data, &ss);
pa_source_output_new_data_set_channel_map(&data, &cm);
+ data.flags = PA_SOURCE_OUTPUT_DONT_INHIBIT_AUTO_SUSPEND;
- pa_source_output_new(&o, m->core, &data, PA_SOURCE_OUTPUT_DONT_INHIBIT_AUTO_SUSPEND);
+ pa_source_output_new(&o, m->core, &data);
pa_source_output_new_data_done(&data);
if (!o) {
@@ -347,8 +340,8 @@ int pa__init(pa_module*m) {
o->push = source_output_push;
o->kill = source_output_kill;
- pa_log_info("Configured source latency of %lu ms.",
- pa_source_output_set_requested_latency(o, pa_bytes_to_usec(mtu, &o->sample_spec)) / PA_USEC_PER_MSEC);
+ pa_log_info("Configured source latency of %llu ms.",
+ (unsigned long long) pa_source_output_set_requested_latency(o, pa_bytes_to_usec(mtu, &o->sample_spec)) / PA_USEC_PER_MSEC);
m->userdata = o->userdata = u = pa_xnew(struct userdata, 1);
u->module = m;
@@ -395,9 +388,7 @@ int pa__init(pa_module*m) {
pa_sap_send(&u->sap_context, 0);
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, SAP_INTERVAL * PA_USEC_PER_SEC);
- u->sap_event = m->core->mainloop->time_new(m->core->mainloop, &tv, sap_event_cb, u);
+ u->sap_event = pa_core_rttime_new(m->core, pa_rtclock_now() + SAP_INTERVAL, sap_event_cb, u);
pa_source_output_put(u->source_output);
diff --git a/src/modules/rtp/rtp.c b/src/modules/rtp/rtp.c
index 6706a10f..05c736a7 100644
--- a/src/modules/rtp/rtp.c
+++ b/src/modules/rtp/rtp.c
@@ -23,11 +23,9 @@
#include <config.h>
#endif
-#include <fcntl.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
-#include <arpa/inet.h>
#include <unistd.h>
#include <sys/ioctl.h>
@@ -43,6 +41,7 @@
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-util.h>
+#include <pulsecore/arpa-inet.h>
#include "rtp.h"
@@ -278,8 +277,8 @@ int pa_rtp_recv(pa_rtp_context *c, pa_memchunk *chunk, pa_mempool *pool, struct
pa_memchunk_reset(&c->memchunk);
}
- for (cm = CMSG_FIRSTHDR(&m); cm; cm = CMSG_NXTHDR(&m, cm)) {
- if (cm->cmsg_level == SOL_SOCKET && cm->cmsg_type == SO_TIMESTAMP)
+ for (cm = CMSG_FIRSTHDR(&m); cm; cm = CMSG_NXTHDR(&m, cm))
+ if (cm->cmsg_level == SOL_SOCKET && cm->cmsg_type == SO_TIMESTAMP) {
memcpy(tstamp, CMSG_DATA(cm), sizeof(struct timeval));
found_tstamp = TRUE;
break;
diff --git a/src/modules/rtp/rtp.h b/src/modules/rtp/rtp.h
index b197e82f..e975e750 100644
--- a/src/modules/rtp/rtp.h
+++ b/src/modules/rtp/rtp.h
@@ -40,6 +40,9 @@ typedef struct pa_rtp_context {
} pa_rtp_context;
pa_rtp_context* pa_rtp_context_init_send(pa_rtp_context *c, int fd, uint32_t ssrc, uint8_t payload, size_t frame_size);
+
+/* If the memblockq doesn't have a silence memchunk set, then the caller must
+ * guarantee that the current read index doesn't point to a hole. */
int pa_rtp_send(pa_rtp_context *c, size_t size, pa_memblockq *q);
pa_rtp_context* pa_rtp_context_init_recv(pa_rtp_context *c, int fd, size_t frame_size);
diff --git a/src/modules/rtp/rtsp_client.c b/src/modules/rtp/rtsp_client.c
index cb037de6..ecf85b89 100644
--- a/src/modules/rtp/rtsp_client.c
+++ b/src/modules/rtp/rtsp_client.c
@@ -23,11 +23,9 @@
#include <config.h>
#endif
-#include <fcntl.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
-#include <arpa/inet.h>
#include <unistd.h>
#include <sys/ioctl.h>
#include <netinet/in.h>
@@ -40,17 +38,11 @@
#include <pulsecore/core-error.h>
#include <pulsecore/core-util.h>
-#include <pulsecore/socket-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/strbuf.h>
#include <pulsecore/ioline.h>
-
-#ifdef HAVE_POLL_H
-#include <poll.h>
-#else
-#include <pulsecore/poll.h>
-#endif
+#include <pulsecore/arpa-inet.h>
#include "rtsp_client.h"
@@ -60,7 +52,6 @@ struct pa_rtsp_client {
uint16_t port;
pa_socket_client *sc;
- pa_iochannel *io;
pa_ioline *ioline;
pa_rtsp_cb_t callback;
@@ -111,10 +102,8 @@ void pa_rtsp_client_free(pa_rtsp_client* c) {
if (c->sc)
pa_socket_client_unref(c->sc);
- if (c->ioline)
- pa_ioline_close(c->ioline);
- else if (c->io)
- pa_iochannel_free(c->io);
+
+ pa_rtsp_disconnect(c);
pa_xfree(c->hostname);
pa_xfree(c->url);
@@ -187,7 +176,6 @@ static void line_callback(pa_ioline *line, const char *s, void *userdata) {
if (!s) {
/* Keep the ioline/iochannel open as they will be freed automatically */
c->ioline = NULL;
- c->io = NULL;
c->callback(c, STATE_DISCONNECTED, NULL, c->userdata);
return;
}
@@ -214,11 +202,13 @@ static void line_callback(pa_ioline *line, const char *s, void *userdata) {
/* End of headers */
/* We will have a header left from our looping iteration, so add it in :) */
if (c->last_header) {
+ char *tmp = pa_strbuf_tostring_free(c->header_buffer);
/* This is not a continuation header so let's dump it into our proplist */
- pa_headerlist_puts(c->response_headers, c->last_header, pa_strbuf_tostring_free(c->header_buffer));
+ pa_headerlist_puts(c->response_headers, c->last_header, tmp);
+ pa_xfree(tmp);
pa_xfree(c->last_header);
c->last_header = NULL;
- c->header_buffer= NULL;
+ c->header_buffer = NULL;
}
pa_log_debug("Full response received. Dispatching");
@@ -240,9 +230,11 @@ static void line_callback(pa_ioline *line, const char *s, void *userdata) {
}
if (c->last_header) {
+ char *tmp = pa_strbuf_tostring_free(c->header_buffer);
/* This is not a continuation header so let's dump the full
header/value into our proplist */
- pa_headerlist_puts(c->response_headers, c->last_header, pa_strbuf_tostring_free(c->header_buffer));
+ pa_headerlist_puts(c->response_headers, c->last_header, tmp);
+ pa_xfree(tmp);
pa_xfree(c->last_header);
c->last_header = NULL;
c->header_buffer = NULL;
@@ -299,8 +291,7 @@ static void on_connection(pa_socket_client *sc, pa_iochannel *io, void *userdata
pa_log("Connection failed: %s", pa_cstrerror(errno));
return;
}
- pa_assert(!c->io);
- c->io = io;
+ pa_assert(!c->ioline);
c->ioline = pa_ioline_new(io);
pa_ioline_set_callback(c->ioline, line_callback, c);
@@ -333,7 +324,7 @@ int pa_rtsp_connect(pa_rtsp_client *c) {
pa_xfree(c->session);
c->session = NULL;
- if (!(c->sc = pa_socket_client_new_string(c->mainloop, c->hostname, c->port))) {
+ if (!(c->sc = pa_socket_client_new_string(c->mainloop, TRUE, c->hostname, c->port))) {
pa_log("failed to connect to server '%s:%d'", c->hostname, c->port);
return -1;
}
@@ -356,9 +347,6 @@ void pa_rtsp_disconnect(pa_rtsp_client *c) {
if (c->ioline)
pa_ioline_close(c->ioline);
- else if (c->io)
- pa_iochannel_free(c->io);
- c->io = NULL;
c->ioline = NULL;
}
@@ -381,8 +369,7 @@ void pa_rtsp_set_url(pa_rtsp_client* c, const char* url) {
c->url = pa_xstrdup(url);
}
-void pa_rtsp_add_header(pa_rtsp_client *c, const char* key, const char* value)
-{
+void pa_rtsp_add_header(pa_rtsp_client *c, const char* key, const char* value) {
pa_assert(c);
pa_assert(key);
pa_assert(value);
@@ -390,8 +377,7 @@ void pa_rtsp_add_header(pa_rtsp_client *c, const char* key, const char* value)
pa_headerlist_puts(c->headers, key, value);
}
-void pa_rtsp_remove_header(pa_rtsp_client *c, const char* key)
-{
+void pa_rtsp_remove_header(pa_rtsp_client *c, const char* key) {
pa_assert(c);
pa_assert(key);
@@ -404,13 +390,11 @@ static int rtsp_exec(pa_rtsp_client* c, const char* cmd,
pa_headerlist* headers) {
pa_strbuf* buf;
char* hdrs;
- ssize_t l;
pa_assert(c);
pa_assert(c->url);
-
- if (!cmd)
- return -1;
+ pa_assert(cmd);
+ pa_assert(c->ioline);
pa_log_debug("Sending command: %s", cmd);
@@ -449,7 +433,7 @@ static int rtsp_exec(pa_rtsp_client* c, const char* cmd,
hdrs = pa_strbuf_tostring_free(buf);
/*pa_log_debug("Submitting request:");
pa_log_debug(hdrs);*/
- l = pa_iochannel_write(c->io, hdrs, strlen(hdrs));
+ pa_ioline_puts(c->ioline, hdrs);
pa_xfree(hdrs);
return 0;
diff --git a/src/modules/rtp/rtsp_client.h b/src/modules/rtp/rtsp_client.h
index b229f261..a56b9324 100644
--- a/src/modules/rtp/rtsp_client.h
+++ b/src/modules/rtp/rtsp_client.h
@@ -27,8 +27,6 @@
#include <sys/types.h>
#include <netdb.h>
-#include <pulsecore/memblockq.h>
-#include <pulsecore/memchunk.h>
#include <pulsecore/socket-client.h>
#include <pulse/mainloop-api.h>
diff --git a/src/modules/rtp/sap.c b/src/modules/rtp/sap.c
index adde16df..4d8bf668 100644
--- a/src/modules/rtp/sap.c
+++ b/src/modules/rtp/sap.c
@@ -23,12 +23,10 @@
#include <config.h>
#endif
-#include <time.h>
#include <stdlib.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
-#include <arpa/inet.h>
#include <errno.h>
#include <string.h>
#include <unistd.h>
@@ -48,6 +46,7 @@
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
+#include <pulsecore/arpa-inet.h>
#include "sap.h"
#include "sdp.h"
diff --git a/src/modules/rtp/sdp.c b/src/modules/rtp/sdp.c
index 7fc7e38c..3e61d9b8 100644
--- a/src/modules/rtp/sdp.c
+++ b/src/modules/rtp/sdp.c
@@ -28,7 +28,6 @@
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
-#include <arpa/inet.h>
#include <string.h>
#include <pulse/xmalloc.h>
@@ -37,6 +36,7 @@
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
+#include <pulsecore/arpa-inet.h>
#include "sdp.h"
#include "rtp.h"
diff --git a/src/modules/udev-util.c b/src/modules/udev-util.c
index 144ad797..356f7736 100644
--- a/src/modules/udev-util.c
+++ b/src/modules/udev-util.c
@@ -58,7 +58,113 @@ static int read_id(struct udev_device *d, const char *n) {
return u;
}
-int pa_udev_get_info(pa_core *core, pa_proplist *p, int card_idx) {
+static int dehex(char x) {
+ if (x >= '0' && x <= '9')
+ return x - '0';
+
+ if (x >= 'A' && x <= 'F')
+ return x - 'A' + 10;
+
+ if (x >= 'a' && x <= 'f')
+ return x - 'a' + 10;
+
+ return -1;
+}
+
+static void proplist_sets_unescape(pa_proplist *p, const char *prop, const char *s) {
+ const char *f;
+ char *t, *r;
+ int c = 0;
+
+ enum {
+ TEXT,
+ BACKSLASH,
+ EX,
+ FIRST
+ } state = TEXT;
+
+ /* The resulting string is definitely shorter than the source string */
+ r = pa_xnew(char, strlen(s)+1);
+
+ for (f = s, t = r; *f; f++) {
+
+ switch (state) {
+
+ case TEXT:
+ if (*f == '\\')
+ state = BACKSLASH;
+ else
+ *(t++) = *f;
+ break;
+
+ case BACKSLASH:
+ if (*f == 'x')
+ state = EX;
+ else {
+ *(t++) = '\\';
+ *(t++) = *f;
+ state = TEXT;
+ }
+ break;
+
+ case EX:
+ c = dehex(*f);
+
+ if (c < 0) {
+ *(t++) = '\\';
+ *(t++) = 'x';
+ *(t++) = *f;
+ state = TEXT;
+ } else
+ state = FIRST;
+
+ break;
+
+ case FIRST: {
+ int d = dehex(*f);
+
+ if (d < 0) {
+ *(t++) = '\\';
+ *(t++) = 'x';
+ *(t++) = *(f-1);
+ *(t++) = *f;
+ } else
+ *(t++) = (char) (c << 4) | d;
+
+ state = TEXT;
+ break;
+ }
+ }
+ }
+
+ switch (state) {
+
+ case TEXT:
+ break;
+
+ case BACKSLASH:
+ *(t++) = '\\';
+ break;
+
+ case EX:
+ *(t++) = '\\';
+ *(t++) = 'x';
+ break;
+
+ case FIRST:
+ *(t++) = '\\';
+ *(t++) = 'x';
+ *(t++) = *(f-1);
+ break;
+ }
+
+ *t = 0;
+
+ pa_proplist_sets(p, prop, r);
+ pa_xfree(r);
+}
+
+int pa_udev_get_info(int card_idx, pa_proplist *p) {
int r = -1;
struct udev *udev;
struct udev_device *card = NULL;
@@ -66,7 +172,6 @@ int pa_udev_get_info(pa_core *core, pa_proplist *p, int card_idx) {
const char *v;
int id;
- pa_assert(core);
pa_assert(p);
pa_assert(card_idx >= 0);
@@ -84,6 +189,19 @@ int pa_udev_get_info(pa_core *core, pa_proplist *p, int card_idx) {
goto finish;
}
+ if (!pa_proplist_contains(p, PA_PROP_DEVICE_BUS_PATH))
+ if (((v = udev_device_get_property_value(card, "ID_PATH")) && *v) ||
+ (v = udev_device_get_devpath(card)))
+ pa_proplist_sets(p, PA_PROP_DEVICE_BUS_PATH, v);
+
+ if (!pa_proplist_contains(p, "sysfs.path"))
+ if ((v = udev_device_get_devpath(card)))
+ pa_proplist_sets(p, "sysfs.path", v);
+
+ if (!pa_proplist_contains(p, "udev.id"))
+ if ((v = udev_device_get_property_value(card, "ID_ID")) && *v)
+ pa_proplist_sets(p, "udev.id", v);
+
if (!pa_proplist_contains(p, PA_PROP_DEVICE_BUS))
if ((v = udev_device_get_property_value(card, "ID_BUS")) && *v)
pa_proplist_sets(p, PA_PROP_DEVICE_BUS, v);
@@ -95,6 +213,8 @@ int pa_udev_get_info(pa_core *core, pa_proplist *p, int card_idx) {
if (!pa_proplist_contains(p, PA_PROP_DEVICE_VENDOR_NAME)) {
if ((v = udev_device_get_property_value(card, "ID_VENDOR_FROM_DATABASE")) && *v)
pa_proplist_sets(p, PA_PROP_DEVICE_VENDOR_NAME, v);
+ else if ((v = udev_device_get_property_value(card, "ID_VENDOR_ENC")) && *v)
+ proplist_sets_unescape(p, PA_PROP_DEVICE_VENDOR_NAME, v);
else if ((v = udev_device_get_property_value(card, "ID_VENDOR")) && *v)
pa_proplist_sets(p, PA_PROP_DEVICE_VENDOR_NAME, v);
}
@@ -106,6 +226,8 @@ int pa_udev_get_info(pa_core *core, pa_proplist *p, int card_idx) {
if (!pa_proplist_contains(p, PA_PROP_DEVICE_PRODUCT_NAME)) {
if ((v = udev_device_get_property_value(card, "ID_MODEL_FROM_DATABASE")) && *v)
pa_proplist_sets(p, PA_PROP_DEVICE_PRODUCT_NAME, v);
+ else if ((v = udev_device_get_property_value(card, "ID_MODEL_ENC")) && *v)
+ proplist_sets_unescape(p, PA_PROP_DEVICE_PRODUCT_NAME, v);
else if ((v = udev_device_get_property_value(card, "ID_MODEL")) && *v)
pa_proplist_sets(p, PA_PROP_DEVICE_PRODUCT_NAME, v);
}
@@ -114,15 +236,15 @@ int pa_udev_get_info(pa_core *core, pa_proplist *p, int card_idx) {
if ((v = udev_device_get_property_value(card, "ID_SERIAL")) && *v)
pa_proplist_sets(p, PA_PROP_DEVICE_SERIAL, v);
+ if (!pa_proplist_contains(p, PA_PROP_DEVICE_CLASS))
+ if ((v = udev_device_get_property_value(card, "SOUND_CLASS")) && *v)
+ pa_proplist_sets(p, PA_PROP_DEVICE_CLASS, v);
+
if (!pa_proplist_contains(p, PA_PROP_DEVICE_FORM_FACTOR))
if ((v = udev_device_get_property_value(card, "SOUND_FORM_FACTOR")) && *v)
pa_proplist_sets(p, PA_PROP_DEVICE_FORM_FACTOR, v);
- if (!pa_proplist_contains(p, PA_PROP_DEVICE_BUS_PATH))
- if ((v = udev_device_get_devpath(card)))
- pa_proplist_sets(p, PA_PROP_DEVICE_BUS_PATH, v);
-
- /* This is normaly not set by th udev rules but may be useful to
+ /* This is normaly not set by the udev rules but may be useful to
* allow administrators to overwrite the device description.*/
if (!pa_proplist_contains(p, PA_PROP_DEVICE_DESCRIPTION))
if ((v = udev_device_get_property_value(card, "SOUND_DESCRIPTION")) && *v)
@@ -140,3 +262,40 @@ finish:
return r;
}
+
+char* pa_udev_get_property(int card_idx, const char *name) {
+ struct udev *udev;
+ struct udev_device *card = NULL;
+ char *t, *r = NULL;
+ const char *v;
+
+ pa_assert(card_idx >= 0);
+ pa_assert(name);
+
+ if (!(udev = udev_new())) {
+ pa_log_error("Failed to allocate udev context.");
+ goto finish;
+ }
+
+ t = pa_sprintf_malloc("%s/class/sound/card%i", udev_get_sys_path(udev), card_idx);
+ card = udev_device_new_from_syspath(udev, t);
+ pa_xfree(t);
+
+ if (!card) {
+ pa_log_error("Failed to get card object.");
+ goto finish;
+ }
+
+ if ((v = udev_device_get_property_value(card, name)) && *v)
+ r = pa_xstrdup(v);
+
+finish:
+
+ if (card)
+ udev_device_unref(card);
+
+ if (udev)
+ udev_unref(udev);
+
+ return r;
+}
diff --git a/src/modules/udev-util.h b/src/modules/udev-util.h
index 5120abdd..a978178f 100644
--- a/src/modules/udev-util.h
+++ b/src/modules/udev-util.h
@@ -23,8 +23,9 @@
***/
-#include <pulsecore/core.h>
+#include <pulse/proplist.h>
-int pa_udev_get_info(pa_core *core, pa_proplist *p, int card);
+int pa_udev_get_info(int card_idx, pa_proplist *p);
+char* pa_udev_get_property(int card_idx, const char *name);
#endif
diff --git a/src/modules/x11/module-x11-bell.c b/src/modules/x11/module-x11-bell.c
index ac303c3b..37ab2e78 100644
--- a/src/modules/x11/module-x11-bell.c
+++ b/src/modules/x11/module-x11-bell.c
@@ -25,18 +25,14 @@
#include <stdio.h>
#include <stdlib.h>
-#include <string.h>
#include <X11/Xlib.h>
#include <X11/XKBlib.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/iochannel.h>
-#include <pulsecore/sink.h>
#include <pulsecore/core-scache.h>
#include <pulsecore/modargs.h>
-#include <pulsecore/namereg.h>
#include <pulsecore/log.h>
#include <pulsecore/x11wrap.h>
diff --git a/src/modules/x11/module-x11-cork-request.c b/src/modules/x11/module-x11-cork-request.c
index c1380c27..0e67db00 100644
--- a/src/modules/x11/module-x11-cork-request.c
+++ b/src/modules/x11/module-x11-cork-request.c
@@ -25,7 +25,6 @@
#include <stdio.h>
#include <stdlib.h>
-#include <string.h>
#include <unistd.h>
#include <X11/Xlib.h>
@@ -33,7 +32,6 @@
#include <X11/XF86keysym.h>
#include <X11/keysym.h>
-#include <pulse/util.h>
#include <pulse/xmalloc.h>
#include <pulsecore/module.h>
diff --git a/src/modules/x11/module-x11-publish.c b/src/modules/x11/module-x11-publish.c
index 2c7fdc12..716fe0b8 100644
--- a/src/modules/x11/module-x11-publish.c
+++ b/src/modules/x11/module-x11-publish.c
@@ -28,17 +28,12 @@
#include <string.h>
#include <unistd.h>
-#include <X11/Xlib.h>
-#include <X11/Xatom.h>
+#include <xcb/xcb.h>
-#include <pulse/util.h>
#include <pulse/xmalloc.h>
#include <pulsecore/module.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/core-scache.h>
#include <pulsecore/modargs.h>
-#include <pulsecore/namereg.h>
#include <pulsecore/log.h>
#include <pulsecore/x11wrap.h>
#include <pulsecore/core-util.h>
@@ -46,7 +41,6 @@
#include <pulsecore/auth-cookie.h>
#include <pulsecore/x11prop.h>
#include <pulsecore/strlist.h>
-#include <pulsecore/shared.h>
#include <pulsecore/protocol-native.h>
#include "module-x11-publish-symdef.h"
@@ -85,27 +79,31 @@ struct userdata {
static void publish_servers(struct userdata *u, pa_strlist *l) {
+ int screen = DefaultScreen(pa_x11_wrapper_get_display(u->x11_wrapper));
+
if (l) {
char *s;
l = pa_strlist_reverse(l);
s = pa_strlist_tostring(l);
- l = pa_strlist_reverse(l);
+ pa_strlist_reverse(l);
- pa_x11_set_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SERVER", s);
+ pa_x11_set_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SERVER", s);
pa_xfree(s);
} else
- pa_x11_del_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SERVER");
+ pa_x11_del_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SERVER");
}
static pa_hook_result_t servers_changed_cb(void *hook_data, void *call_data, void *slot_data) {
pa_strlist *servers = call_data;
struct userdata *u = slot_data;
char t[256];
+ int screen;
pa_assert(u);
- if (!pa_x11_get_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_ID", t, sizeof(t)) || strcmp(t, u->id)) {
+ screen = DefaultScreen(pa_x11_wrapper_get_display(u->x11_wrapper));
+ if (!pa_x11_get_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_ID", t, sizeof(t)) || strcmp(t, u->id)) {
pa_log_warn("PulseAudio information vanished from X11!");
return PA_HOOK_OK;
}
@@ -139,6 +137,7 @@ int pa__init(pa_module*m) {
char *mid, *sid;
char hx[PA_NATIVE_COOKIE_LENGTH*2+1];
const char *t;
+ int screen;
pa_assert(m);
@@ -164,26 +163,27 @@ int pa__init(pa_module*m) {
if (!(u->x11_wrapper = pa_x11_wrapper_get(m->core, pa_modargs_get_value(ma, "display", NULL))))
goto fail;
+ screen = DefaultScreen(pa_x11_wrapper_get_display(u->x11_wrapper));
mid = pa_machine_id();
u->id = pa_sprintf_malloc("%lu@%s/%lu", (unsigned long) getuid(), mid, (unsigned long) getpid());
pa_xfree(mid);
- pa_x11_set_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_ID", u->id);
+ pa_x11_set_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_ID", u->id);
if ((sid = pa_session_id())) {
- pa_x11_set_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SESSION_ID", sid);
+ pa_x11_set_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SESSION_ID", sid);
pa_xfree(sid);
}
publish_servers(u, pa_native_protocol_servers(u->protocol));
if ((t = pa_modargs_get_value(ma, "source", NULL)))
- pa_x11_set_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SOURCE", t);
+ pa_x11_set_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SOURCE", t);
if ((t = pa_modargs_get_value(ma, "sink", NULL)))
- pa_x11_set_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SINK", t);
+ pa_x11_set_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SINK", t);
- pa_x11_set_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_COOKIE",
+ pa_x11_set_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_COOKIE",
pa_hexstr(pa_auth_cookie_read(u->auth_cookie, PA_NATIVE_COOKIE_LENGTH), PA_NATIVE_COOKIE_LENGTH, hx, sizeof(hx)));
u->x11_client = pa_x11_client_new(u->x11_wrapper, NULL, x11_kill_cb, u);
@@ -214,18 +214,19 @@ void pa__done(pa_module*m) {
if (u->x11_wrapper) {
char t[256];
+ int screen = DefaultScreen(pa_x11_wrapper_get_display(u->x11_wrapper));
/* Yes, here is a race condition */
- if (!pa_x11_get_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_ID", t, sizeof(t)) || strcmp(t, u->id))
+ if (!pa_x11_get_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_ID", t, sizeof(t)) || strcmp(t, u->id))
pa_log_warn("PulseAudio information vanished from X11!");
else {
- pa_x11_del_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_ID");
- pa_x11_del_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SERVER");
- pa_x11_del_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SINK");
- pa_x11_del_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SOURCE");
- pa_x11_del_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_COOKIE");
- pa_x11_del_prop(pa_x11_wrapper_get_display(u->x11_wrapper), "PULSE_SESSION_ID");
- XSync(pa_x11_wrapper_get_display(u->x11_wrapper), False);
+ pa_x11_del_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_ID");
+ pa_x11_del_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SERVER");
+ pa_x11_del_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SINK");
+ pa_x11_del_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SOURCE");
+ pa_x11_del_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_COOKIE");
+ pa_x11_del_prop(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper), screen, "PULSE_SESSION_ID");
+ xcb_flush(pa_x11_wrapper_get_xcb_connection(u->x11_wrapper));
}
pa_x11_wrapper_unref(u->x11_wrapper);
diff --git a/src/modules/x11/module-x11-xsmp.c b/src/modules/x11/module-x11-xsmp.c
index 28fd373a..6a6116ff 100644
--- a/src/modules/x11/module-x11-xsmp.c
+++ b/src/modules/x11/module-x11-xsmp.c
@@ -33,13 +33,8 @@
#include <pulse/xmalloc.h>
#include <pulse/util.h>
-#include <pulsecore/iochannel.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/core-scache.h>
#include <pulsecore/modargs.h>
-#include <pulsecore/namereg.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
#include <pulsecore/x11wrap.h>
#include "module-x11-xsmp-symdef.h"
@@ -129,7 +124,7 @@ int pa__init(pa_module*m) {
pa_assert(m);
if (ice_in_use) {
- pa_log("module-x11-xsmp may no be loaded twice.");
+ pa_log("module-x11-xsmp may not be loaded twice.");
return -1;
}
diff --git a/src/pulse/Makefile b/src/pulse/Makefile
deleted file mode 100644
index 7c8875f3..00000000
--- a/src/pulse/Makefile
+++ /dev/null
@@ -1,13 +0,0 @@
-# This is a dirty trick just to ease compilation with emacs
-#
-# This file is not intended to be distributed or anything
-#
-# So: don't touch it, even better ignore it!
-
-all:
- $(MAKE) -C ..
-
-clean:
- $(MAKE) -C .. clean
-
-.PHONY: all clean
diff --git a/src/pulse/browser.c b/src/pulse/browser.c
deleted file mode 100644
index 4cf5d0c3..00000000
--- a/src/pulse/browser.c
+++ /dev/null
@@ -1,464 +0,0 @@
-/***
- This file is part of PulseAudio.
-
- Copyright 2004-2006 Lennart Poettering
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of the
- License, or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-
-#include <avahi-client/lookup.h>
-#include <avahi-common/domain.h>
-#include <avahi-common/error.h>
-
-#include <pulse/xmalloc.h>
-
-#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
-#include <pulsecore/avahi-wrap.h>
-#include <pulsecore/refcnt.h>
-#include <pulsecore/macro.h>
-
-#include "browser.h"
-
-#define SERVICE_TYPE_SINK "_pulse-sink._tcp."
-#define SERVICE_TYPE_SOURCE "_pulse-source._tcp."
-#define SERVICE_TYPE_SERVER "_pulse-server._tcp."
-
-struct pa_browser {
- PA_REFCNT_DECLARE;
-
- pa_mainloop_api *mainloop;
- AvahiPoll* avahi_poll;
-
- pa_browse_cb_t callback;
- void *userdata;
-
- pa_browser_error_cb_t error_callback;
- void *error_userdata;
-
- AvahiClient *client;
- AvahiServiceBrowser *server_browser, *sink_browser, *source_browser;
-
-};
-
-static int map_to_opcode(const char *type, int new) {
-
- if (avahi_domain_equal(type, SERVICE_TYPE_SINK))
- return new ? PA_BROWSE_NEW_SINK : PA_BROWSE_REMOVE_SINK;
- else if (avahi_domain_equal(type, SERVICE_TYPE_SOURCE))
- return new ? PA_BROWSE_NEW_SOURCE : PA_BROWSE_REMOVE_SOURCE;
- else if (avahi_domain_equal(type, SERVICE_TYPE_SERVER))
- return new ? PA_BROWSE_NEW_SERVER : PA_BROWSE_REMOVE_SERVER;
-
- return -1;
-}
-
-static void resolve_callback(
- AvahiServiceResolver *r,
- AvahiIfIndex interface,
- AvahiProtocol protocol,
- AvahiResolverEvent event,
- const char *name,
- const char *type,
- const char *domain,
- const char *host_name,
- const AvahiAddress *aa,
- uint16_t port,
- AvahiStringList *txt,
- AvahiLookupResultFlags flags,
- void *userdata) {
-
- pa_browser *b = userdata;
- pa_browse_info i;
- char ip[256], a[256];
- int opcode;
- int device_found = 0;
- uint32_t cookie;
- pa_sample_spec ss;
- int ss_valid = 0;
- char *key = NULL, *value = NULL;
-
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- memset(&i, 0, sizeof(i));
- i.name = name;
-
- if (event != AVAHI_RESOLVER_FOUND)
- goto fail;
-
- if (!b->callback)
- goto fail;
-
- opcode = map_to_opcode(type, 1);
- pa_assert(opcode >= 0);
-
- if (aa->proto == AVAHI_PROTO_INET)
- pa_snprintf(a, sizeof(a), "tcp:%s:%u", avahi_address_snprint(ip, sizeof(ip), aa), port);
- else {
- pa_assert(aa->proto == AVAHI_PROTO_INET6);
- pa_snprintf(a, sizeof(a), "tcp6:%s:%u", avahi_address_snprint(ip, sizeof(ip), aa), port);
- }
- i.server = a;
-
-
- while (txt) {
-
- if (avahi_string_list_get_pair(txt, &key, &value, NULL) < 0)
- break;
-
- if (!strcmp(key, "device")) {
- device_found = 1;
- pa_xfree((char*) i.device);
- i.device = value;
- value = NULL;
- } else if (!strcmp(key, "server-version")) {
- pa_xfree((char*) i.server_version);
- i.server_version = value;
- value = NULL;
- } else if (!strcmp(key, "user-name")) {
- pa_xfree((char*) i.user_name);
- i.user_name = value;
- value = NULL;
- } else if (!strcmp(key, "fqdn")) {
- size_t l;
-
- pa_xfree((char*) i.fqdn);
- i.fqdn = value;
- value = NULL;
-
- l = strlen(a);
- pa_assert(l+1 <= sizeof(a));
- strncat(a, " ", sizeof(a)-l-1);
- strncat(a, i.fqdn, sizeof(a)-l-2);
- } else if (!strcmp(key, "cookie")) {
-
- if (pa_atou(value, &cookie) < 0)
- goto fail;
-
- i.cookie = &cookie;
- } else if (!strcmp(key, "description")) {
- pa_xfree((char*) i.description);
- i.description = value;
- value = NULL;
- } else if (!strcmp(key, "channels")) {
- uint32_t ch;
-
- if (pa_atou(value, &ch) < 0 || ch <= 0 || ch > 255)
- goto fail;
-
- ss.channels = (uint8_t) ch;
- ss_valid |= 1;
-
- } else if (!strcmp(key, "rate")) {
- if (pa_atou(value, &ss.rate) < 0)
- goto fail;
- ss_valid |= 2;
- } else if (!strcmp(key, "format")) {
-
- if ((ss.format = pa_parse_sample_format(value)) == PA_SAMPLE_INVALID)
- goto fail;
-
- ss_valid |= 4;
- }
-
- pa_xfree(key);
- pa_xfree(value);
- key = value = NULL;
-
- txt = avahi_string_list_get_next(txt);
- }
-
- /* No device txt record was sent for a sink or source service */
- if (opcode != PA_BROWSE_NEW_SERVER && !device_found)
- goto fail;
-
- if (ss_valid == 7)
- i.sample_spec = &ss;
-
- b->callback(b, opcode, &i, b->userdata);
-
-fail:
- pa_xfree((void*) i.device);
- pa_xfree((void*) i.fqdn);
- pa_xfree((void*) i.server_version);
- pa_xfree((void*) i.user_name);
- pa_xfree((void*) i.description);
-
- pa_xfree(key);
- pa_xfree(value);
-
- avahi_service_resolver_free(r);
-}
-
-static void handle_failure(pa_browser *b) {
- const char *e = NULL;
-
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- if (b->sink_browser)
- avahi_service_browser_free(b->sink_browser);
- if (b->source_browser)
- avahi_service_browser_free(b->source_browser);
- if (b->server_browser)
- avahi_service_browser_free(b->server_browser);
-
- b->sink_browser = b->source_browser = b->server_browser = NULL;
-
- if (b->client) {
- e = avahi_strerror(avahi_client_errno(b->client));
- avahi_client_free(b->client);
- }
-
- b->client = NULL;
-
- if (b->error_callback)
- b->error_callback(b, e, b->error_userdata);
-}
-
-static void browse_callback(
- AvahiServiceBrowser *sb,
- AvahiIfIndex interface,
- AvahiProtocol protocol,
- AvahiBrowserEvent event,
- const char *name,
- const char *type,
- const char *domain,
- AvahiLookupResultFlags flags,
- void *userdata) {
-
- pa_browser *b = userdata;
-
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- switch (event) {
- case AVAHI_BROWSER_NEW: {
-
- if (!avahi_service_resolver_new(
- b->client,
- interface,
- protocol,
- name,
- type,
- domain,
- AVAHI_PROTO_UNSPEC,
- 0,
- resolve_callback,
- b))
- handle_failure(b);
-
- break;
- }
-
- case AVAHI_BROWSER_REMOVE: {
-
- if (b->callback) {
- pa_browse_info i;
- int opcode;
-
- memset(&i, 0, sizeof(i));
- i.name = name;
-
- opcode = map_to_opcode(type, 0);
- pa_assert(opcode >= 0);
-
- b->callback(b, opcode, &i, b->userdata);
- }
- break;
- }
-
- case AVAHI_BROWSER_FAILURE: {
- handle_failure(b);
- break;
- }
-
- default:
- ;
- }
-}
-
-static void client_callback(AvahiClient *s, AvahiClientState state, void *userdata) {
- pa_browser *b = userdata;
-
- pa_assert(s);
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- if (state == AVAHI_CLIENT_FAILURE)
- handle_failure(b);
-}
-
-static void browser_free(pa_browser *b);
-
-
-PA_WARN_REFERENCE(pa_browser_new, "libpulse-browse is being phased out.");
-
-pa_browser *pa_browser_new(pa_mainloop_api *mainloop) {
- return pa_browser_new_full(mainloop, PA_BROWSE_FOR_SERVERS|PA_BROWSE_FOR_SINKS|PA_BROWSE_FOR_SOURCES, NULL);
-}
-
-PA_WARN_REFERENCE(pa_browser_new_full, "libpulse-browse is being phased out.");
-
-pa_browser *pa_browser_new_full(pa_mainloop_api *mainloop, pa_browse_flags_t flags, const char **error_string) {
- pa_browser *b;
- int error;
-
- pa_assert(mainloop);
-
- if (flags & ~(PA_BROWSE_FOR_SERVERS|PA_BROWSE_FOR_SINKS|PA_BROWSE_FOR_SOURCES) || flags == 0)
- return NULL;
-
- b = pa_xnew(pa_browser, 1);
- b->mainloop = mainloop;
- PA_REFCNT_INIT(b);
- b->callback = NULL;
- b->userdata = NULL;
- b->error_callback = NULL;
- b->error_userdata = NULL;
- b->sink_browser = b->source_browser = b->server_browser = NULL;
-
- b->avahi_poll = pa_avahi_poll_new(mainloop);
-
- if (!(b->client = avahi_client_new(b->avahi_poll, 0, client_callback, b, &error))) {
- if (error_string)
- *error_string = avahi_strerror(error);
- goto fail;
- }
-
- if ((flags & PA_BROWSE_FOR_SERVERS) &&
- !(b->server_browser = avahi_service_browser_new(
- b->client,
- AVAHI_IF_UNSPEC,
- AVAHI_PROTO_INET,
- SERVICE_TYPE_SERVER,
- NULL,
- 0,
- browse_callback,
- b))) {
-
- if (error_string)
- *error_string = avahi_strerror(avahi_client_errno(b->client));
- goto fail;
- }
-
- if ((flags & PA_BROWSE_FOR_SINKS) &&
- !(b->sink_browser = avahi_service_browser_new(
- b->client,
- AVAHI_IF_UNSPEC,
- AVAHI_PROTO_UNSPEC,
- SERVICE_TYPE_SINK,
- NULL,
- 0,
- browse_callback,
- b))) {
-
- if (error_string)
- *error_string = avahi_strerror(avahi_client_errno(b->client));
- goto fail;
- }
-
- if ((flags & PA_BROWSE_FOR_SOURCES) &&
- !(b->source_browser = avahi_service_browser_new(
- b->client,
- AVAHI_IF_UNSPEC,
- AVAHI_PROTO_UNSPEC,
- SERVICE_TYPE_SOURCE,
- NULL,
- 0,
- browse_callback,
- b))) {
-
- if (error_string)
- *error_string = avahi_strerror(avahi_client_errno(b->client));
- goto fail;
- }
-
- return b;
-
-fail:
- if (b)
- browser_free(b);
-
- return NULL;
-}
-
-static void browser_free(pa_browser *b) {
- pa_assert(b);
- pa_assert(b->mainloop);
-
- if (b->sink_browser)
- avahi_service_browser_free(b->sink_browser);
- if (b->source_browser)
- avahi_service_browser_free(b->source_browser);
- if (b->server_browser)
- avahi_service_browser_free(b->server_browser);
-
- if (b->client)
- avahi_client_free(b->client);
-
- if (b->avahi_poll)
- pa_avahi_poll_free(b->avahi_poll);
-
- pa_xfree(b);
-}
-
-PA_WARN_REFERENCE(pa_browser_ref, "libpulse-browse is being phased out.");
-
-pa_browser *pa_browser_ref(pa_browser *b) {
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- PA_REFCNT_INC(b);
- return b;
-}
-
-PA_WARN_REFERENCE(pa_browser_unref, "libpulse-browse is being phased out.");
-
-void pa_browser_unref(pa_browser *b) {
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- if (PA_REFCNT_DEC(b) <= 0)
- browser_free(b);
-}
-
-PA_WARN_REFERENCE(pa_browser_set_callback, "libpulse-browse is being phased out.");
-
-void pa_browser_set_callback(pa_browser *b, pa_browse_cb_t cb, void *userdata) {
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- b->callback = cb;
- b->userdata = userdata;
-}
-
-PA_WARN_REFERENCE(pa_browser_set_error_callback, "libpulse-browse is being phased out.");
-
-void pa_browser_set_error_callback(pa_browser *b, pa_browser_error_cb_t cb, void *userdata) {
- pa_assert(b);
- pa_assert(PA_REFCNT_VALUE(b) >= 1);
-
- b->error_callback = cb;
- b->error_userdata = userdata;
-}
diff --git a/src/pulse/browser.h b/src/pulse/browser.h
deleted file mode 100644
index c843e2a2..00000000
--- a/src/pulse/browser.h
+++ /dev/null
@@ -1,99 +0,0 @@
-#ifndef foobrowserhfoo
-#define foobrowserhfoo
-
-/***
- This file is part of PulseAudio.
-
- Copyright 2004-2006 Lennart Poettering
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of the
- License, or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#include <pulse/mainloop-api.h>
-#include <pulse/sample.h>
-#include <pulse/channelmap.h>
-#include <pulse/cdecl.h>
-#include <pulse/version.h>
-
-/** \file
- * An abstract interface for Zeroconf browsing of PulseAudio servers */
-
-PA_C_DECL_BEGIN
-
-/** An opaque Zeroconf service browser object */
-typedef struct pa_browser pa_browser;
-
-/** Opcodes for pa_browser_cb_t callbacks */
-typedef enum pa_browse_opcode {
- PA_BROWSE_NEW_SERVER = 0, /**< New server found */
- PA_BROWSE_NEW_SINK, /**< New sink found */
- PA_BROWSE_NEW_SOURCE, /**< New source found */
- PA_BROWSE_REMOVE_SERVER, /**< Server disappeared */
- PA_BROWSE_REMOVE_SINK, /**< Sink disappeared */
- PA_BROWSE_REMOVE_SOURCE /**< Source disappeared */
-} pa_browse_opcode_t;
-
-typedef enum pa_browse_flags {
- PA_BROWSE_FOR_SERVERS = 1, /**< Browse for servers */
- PA_BROWSE_FOR_SINKS = 2, /**< Browse for sinks */
- PA_BROWSE_FOR_SOURCES = 4 /** Browse for sources */
-} pa_browse_flags_t;
-
-/** Create a new browser object on the specified main loop */
-pa_browser *pa_browser_new(pa_mainloop_api *mainloop);
-
-/** Same pa_browser_new, but pass additional flags parameter. */
-pa_browser *pa_browser_new_full(pa_mainloop_api *mainloop, pa_browse_flags_t flags, const char **error_string);
-
-/** Increase reference counter of the specified browser object */
-pa_browser *pa_browser_ref(pa_browser *z);
-
-/** Decrease reference counter of the specified browser object */
-void pa_browser_unref(pa_browser *z);
-
-/** Information about a sink/source/server found with Zeroconf */
-typedef struct pa_browse_info {
- const char *name; /**< Unique service name; always available */
-
- const char *server; /**< Server name; always available */
- const char *server_version; /**< Server version string; optional */
- const char *user_name; /**< User name of the server process; optional */
- const char *fqdn; /* Server version; optional */
- const uint32_t *cookie; /* Server cookie; optional */
-
- const char *device; /* Device name; always available when this information is of a sink/source */
- const char *description; /* Device description; optional */
- const pa_sample_spec *sample_spec; /* Sample specification of the device; optional */
-} pa_browse_info;
-
-/** Callback prototype */
-typedef void (*pa_browse_cb_t)(pa_browser *z, pa_browse_opcode_t c, const pa_browse_info *i, void *userdata);
-
-/** Set the callback pointer for the browser object */
-void pa_browser_set_callback(pa_browser *z, pa_browse_cb_t cb, void *userdata);
-
-/** Callback prototype for errors */
-typedef void (*pa_browser_error_cb_t)(pa_browser *z, const char *error_string, void *userdata);
-
-/** Set a callback function that is called whenever the browser object
- * becomes invalid due to an error. After this function has been
- * called the browser object has become invalid and should be
- * freed. */
-void pa_browser_set_error_callback(pa_browser *z, pa_browser_error_cb_t, void *userdata);
-
-PA_C_DECL_END
-
-#endif
diff --git a/src/pulse/channelmap.c b/src/pulse/channelmap.c
index 4654a9ad..83fdb437 100644
--- a/src/pulse/channelmap.c
+++ b/src/pulse/channelmap.c
@@ -30,9 +30,11 @@
#include <pulse/xmalloc.h>
#include <pulse/i18n.h>
+
#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
#include <pulsecore/bitset.h>
+#include <pulsecore/sample-util.h>
#include "channelmap.h"
@@ -110,7 +112,7 @@ const char *const pretty_table[PA_CHANNEL_POSITION_MAX] = {
[PA_CHANNEL_POSITION_REAR_LEFT] = N_("Rear Left"),
[PA_CHANNEL_POSITION_REAR_RIGHT] = N_("Rear Right"),
- [PA_CHANNEL_POSITION_LFE] = N_("Low Frequency Emmiter"),
+ [PA_CHANNEL_POSITION_LFE] = N_("Subwoofer"),
[PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER] = N_("Front Left-of-center"),
[PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER] = N_("Front Right-of-center"),
@@ -217,11 +219,11 @@ pa_channel_map* pa_channel_map_init_auto(pa_channel_map *m, unsigned channels, p
case 6:
m->map[0] = PA_CHANNEL_POSITION_FRONT_LEFT;
- m->map[1] = PA_CHANNEL_POSITION_REAR_LEFT;
+ m->map[1] = PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER;
m->map[2] = PA_CHANNEL_POSITION_FRONT_CENTER;
m->map[3] = PA_CHANNEL_POSITION_FRONT_RIGHT;
- m->map[4] = PA_CHANNEL_POSITION_REAR_RIGHT;
- m->map[5] = PA_CHANNEL_POSITION_LFE;
+ m->map[4] = PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER;
+ m->map[5] = PA_CHANNEL_POSITION_REAR_CENTER;
return m;
case 5:
@@ -245,7 +247,7 @@ pa_channel_map* pa_channel_map_init_auto(pa_channel_map *m, unsigned channels, p
m->map[0] = PA_CHANNEL_POSITION_LEFT;
m->map[1] = PA_CHANNEL_POSITION_CENTER;
m->map[2] = PA_CHANNEL_POSITION_RIGHT;
- m->map[3] = PA_CHANNEL_POSITION_LFE;
+ m->map[3] = PA_CHANNEL_POSITION_REAR_CENTER;
return m;
default:
@@ -297,6 +299,8 @@ pa_channel_map* pa_channel_map_init_auto(pa_channel_map *m, unsigned channels, p
case PA_CHANNEL_MAP_WAVEEX:
+ /* Following http://www.microsoft.com/whdc/device/audio/multichaud.mspx#EKLAC */
+
switch (channels) {
case 1:
m->map[0] = PA_CHANNEL_POSITION_MONO;
@@ -449,6 +453,10 @@ int pa_channel_map_equal(const pa_channel_map *a, const pa_channel_map *b) {
pa_assert(b);
pa_return_val_if_fail(pa_channel_map_valid(a), 0);
+
+ if (PA_UNLIKELY(a == b))
+ return 1;
+
pa_return_val_if_fail(pa_channel_map_valid(b), 0);
if (a->channels != b->channels)
@@ -491,6 +499,27 @@ char* pa_channel_map_snprint(char *s, size_t l, const pa_channel_map *map) {
return s;
}
+pa_channel_position_t pa_channel_position_from_string(const char *p) {
+ pa_channel_position_t i;
+ pa_assert(p);
+
+ /* Some special aliases */
+ if (pa_streq(p, "left"))
+ return PA_CHANNEL_POSITION_LEFT;
+ else if (pa_streq(p, "right"))
+ return PA_CHANNEL_POSITION_RIGHT;
+ else if (pa_streq(p, "center"))
+ return PA_CHANNEL_POSITION_CENTER;
+ else if (pa_streq(p, "subwoofer"))
+ return PA_CHANNEL_POSITION_SUBWOOFER;
+
+ for (i = 0; i < PA_CHANNEL_POSITION_MAX; i++)
+ if (pa_streq(p, table[i]))
+ return i;
+
+ return PA_CHANNEL_POSITION_INVALID;
+}
+
pa_channel_map *pa_channel_map_parse(pa_channel_map *rmap, const char *s) {
const char *state;
pa_channel_map map;
@@ -559,36 +588,19 @@ pa_channel_map *pa_channel_map_parse(pa_channel_map *rmap, const char *s) {
map.channels = 0;
while ((p = pa_split(s, ",", &state))) {
+ pa_channel_position_t f;
if (map.channels >= PA_CHANNELS_MAX) {
pa_xfree(p);
return NULL;
}
- /* Some special aliases */
- if (pa_streq(p, "left"))
- map.map[map.channels++] = PA_CHANNEL_POSITION_LEFT;
- else if (pa_streq(p, "right"))
- map.map[map.channels++] = PA_CHANNEL_POSITION_RIGHT;
- else if (pa_streq(p, "center"))
- map.map[map.channels++] = PA_CHANNEL_POSITION_CENTER;
- else if (pa_streq(p, "subwoofer"))
- map.map[map.channels++] = PA_CHANNEL_POSITION_SUBWOOFER;
- else {
- pa_channel_position_t i;
-
- for (i = 0; i < PA_CHANNEL_POSITION_MAX; i++)
- if (strcmp(p, table[i]) == 0) {
- map.map[map.channels++] = i;
- break;
- }
-
- if (i >= PA_CHANNEL_POSITION_MAX) {
- pa_xfree(p);
- return NULL;
- }
+ if ((f = pa_channel_position_from_string(p)) == PA_CHANNEL_POSITION_INVALID) {
+ pa_xfree(p);
+ return NULL;
}
+ map.map[map.channels++] = f;
pa_xfree(p);
}
@@ -627,107 +639,48 @@ int pa_channel_map_compatible(const pa_channel_map *map, const pa_sample_spec *s
}
int pa_channel_map_superset(const pa_channel_map *a, const pa_channel_map *b) {
- pa_bitset_t in_a[PA_BITSET_ELEMENTS(PA_CHANNEL_POSITION_MAX)];
- unsigned i;
+ pa_channel_position_mask_t am, bm;
pa_assert(a);
pa_assert(b);
pa_return_val_if_fail(pa_channel_map_valid(a), 0);
- pa_return_val_if_fail(pa_channel_map_valid(b), 0);
- memset(in_a, 0, sizeof(in_a));
+ if (PA_UNLIKELY(a == b))
+ return 1;
- for (i = 0; i < a->channels; i++)
- pa_bitset_set(in_a, a->map[i], TRUE);
+ pa_return_val_if_fail(pa_channel_map_valid(b), 0);
- for (i = 0; i < b->channels; i++)
- if (!pa_bitset_get(in_a, b->map[i]))
- return 0;
+ am = pa_channel_map_mask(a);
+ bm = pa_channel_map_mask(b);
- return 1;
+ return (bm & am) == bm;
}
int pa_channel_map_can_balance(const pa_channel_map *map) {
- unsigned c;
- pa_bool_t left = FALSE, right = FALSE;
+ pa_channel_position_mask_t m;
pa_assert(map);
-
pa_return_val_if_fail(pa_channel_map_valid(map), 0);
- for (c = 0; c < map->channels; c++) {
-
- switch (map->map[c]) {
- case PA_CHANNEL_POSITION_LEFT:
- case PA_CHANNEL_POSITION_REAR_LEFT:
- case PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER:
- case PA_CHANNEL_POSITION_SIDE_LEFT:
- case PA_CHANNEL_POSITION_TOP_FRONT_LEFT:
- case PA_CHANNEL_POSITION_TOP_REAR_LEFT:
- left = TRUE;
- break;
-
- case PA_CHANNEL_POSITION_RIGHT:
- case PA_CHANNEL_POSITION_REAR_RIGHT:
- case PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER:
- case PA_CHANNEL_POSITION_SIDE_RIGHT:
- case PA_CHANNEL_POSITION_TOP_FRONT_RIGHT:
- case PA_CHANNEL_POSITION_TOP_REAR_RIGHT:
- right = TRUE;
- break;
-
- default:
- ;
- }
-
- if (left && right)
- return 1;
- }
+ m = pa_channel_map_mask(map);
- return 0;
+ return
+ (PA_CHANNEL_POSITION_MASK_LEFT & m) &&
+ (PA_CHANNEL_POSITION_MASK_RIGHT & m);
}
int pa_channel_map_can_fade(const pa_channel_map *map) {
- unsigned c;
- pa_bool_t front = FALSE, rear = FALSE;
+ pa_channel_position_mask_t m;
pa_assert(map);
-
pa_return_val_if_fail(pa_channel_map_valid(map), 0);
- for (c = 0; c < map->channels; c++) {
-
- switch (map->map[c]) {
- case PA_CHANNEL_POSITION_FRONT_LEFT:
- case PA_CHANNEL_POSITION_FRONT_RIGHT:
- case PA_CHANNEL_POSITION_FRONT_CENTER:
- case PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER:
- case PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER:
- case PA_CHANNEL_POSITION_TOP_FRONT_LEFT:
- case PA_CHANNEL_POSITION_TOP_FRONT_RIGHT:
- case PA_CHANNEL_POSITION_TOP_FRONT_CENTER:
- front = TRUE;
- break;
-
- case PA_CHANNEL_POSITION_REAR_LEFT:
- case PA_CHANNEL_POSITION_REAR_RIGHT:
- case PA_CHANNEL_POSITION_REAR_CENTER:
- case PA_CHANNEL_POSITION_TOP_REAR_LEFT:
- case PA_CHANNEL_POSITION_TOP_REAR_RIGHT:
- case PA_CHANNEL_POSITION_TOP_REAR_CENTER:
- rear = TRUE;
- break;
-
- default:
- ;
- }
+ m = pa_channel_map_mask(map);
- if (front && rear)
- return 1;
- }
-
- return 0;
+ return
+ (PA_CHANNEL_POSITION_MASK_FRONT & m) &&
+ (PA_CHANNEL_POSITION_MASK_REAR & m);
}
const char* pa_channel_map_to_name(const pa_channel_map *map) {
diff --git a/src/pulse/channelmap.h b/src/pulse/channelmap.h
index 2aaead01..a6b93ddc 100644
--- a/src/pulse/channelmap.h
+++ b/src/pulse/channelmap.h
@@ -65,7 +65,10 @@
*/
/** \file
- * Constants and routines for channel mapping handling */
+ * Constants and routines for channel mapping handling
+ *
+ * See also \subpage channelmap
+ */
PA_C_DECL_BEGIN
@@ -74,9 +77,9 @@ typedef enum pa_channel_position {
PA_CHANNEL_POSITION_INVALID = -1,
PA_CHANNEL_POSITION_MONO = 0,
- PA_CHANNEL_POSITION_FRONT_LEFT, /* Apple calls this 'Left' */
- PA_CHANNEL_POSITION_FRONT_RIGHT, /* Apple calls this 'Right' */
- PA_CHANNEL_POSITION_FRONT_CENTER, /* Apple calls this 'Center' */
+ PA_CHANNEL_POSITION_FRONT_LEFT, /* Apple, Dolby call this 'Left' */
+ PA_CHANNEL_POSITION_FRONT_RIGHT, /* Apple, Dolby call this 'Right' */
+ PA_CHANNEL_POSITION_FRONT_CENTER, /* Apple, Dolby call this 'Center' */
/** \cond fulldocs */
PA_CHANNEL_POSITION_LEFT = PA_CHANNEL_POSITION_FRONT_LEFT,
@@ -84,20 +87,20 @@ typedef enum pa_channel_position {
PA_CHANNEL_POSITION_CENTER = PA_CHANNEL_POSITION_FRONT_CENTER,
/** \endcond */
- PA_CHANNEL_POSITION_REAR_CENTER, /* Microsoft calls this 'Back Center', Apple calls this 'Center Surround' */
- PA_CHANNEL_POSITION_REAR_LEFT, /* Microsoft calls this 'Back Left', Apple calls this 'Left Surround' */
- PA_CHANNEL_POSITION_REAR_RIGHT, /* Microsoft calls this 'Back Right', Apple calls this 'Right Surround' */
+ PA_CHANNEL_POSITION_REAR_CENTER, /* Microsoft calls this 'Back Center', Apple calls this 'Center Surround', Dolby calls this 'Surround Rear Center' */
+ PA_CHANNEL_POSITION_REAR_LEFT, /* Microsoft calls this 'Back Left', Apple calls this 'Left Surround' (!), Dolby calls this 'Surround Rear Left' */
+ PA_CHANNEL_POSITION_REAR_RIGHT, /* Microsoft calls this 'Back Right', Apple calls this 'Right Surround' (!), Dolby calls this 'Surround Rear Right' */
PA_CHANNEL_POSITION_LFE, /* Microsoft calls this 'Low Frequency', Apple calls this 'LFEScreen' */
/** \cond fulldocs */
PA_CHANNEL_POSITION_SUBWOOFER = PA_CHANNEL_POSITION_LFE,
/** \endcond */
- PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER, /* Apple calls this 'Left Center' */
- PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER, /* Apple calls this 'Right Center */
+ PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER, /* Apple, Dolby call this 'Left Center' */
+ PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER, /* Apple, Dolby call this 'Right Center */
- PA_CHANNEL_POSITION_SIDE_LEFT, /* Apple calls this 'Left Surround Direct' */
- PA_CHANNEL_POSITION_SIDE_RIGHT, /* Apple calls this 'Right Surround Direct' */
+ PA_CHANNEL_POSITION_SIDE_LEFT, /* Apple calls this 'Left Surround Direct', Dolby calls this 'Surround Left' (!) */
+ PA_CHANNEL_POSITION_SIDE_RIGHT, /* Apple calls this 'Right Surround Direct', Dolby calls this 'Surround Right' (!) */
PA_CHANNEL_POSITION_AUX0,
PA_CHANNEL_POSITION_AUX1,
@@ -209,24 +212,34 @@ typedef enum pa_channel_position {
typedef uint64_t pa_channel_position_mask_t;
/** Makes a bit mask from a channel position. \since 0.9.16 */
-#define PA_CHANNEL_POSITION_MASK(f) ((pa_channel_position_mask_t) (1 << (f)))
+#define PA_CHANNEL_POSITION_MASK(f) ((pa_channel_position_mask_t) (1ULL << (f)))
/** A list of channel mapping definitions for pa_channel_map_init_auto() */
typedef enum pa_channel_map_def {
PA_CHANNEL_MAP_AIFF,
/**< The mapping from RFC3551, which is based on AIFF-C */
+/** \cond fulldocs */
PA_CHANNEL_MAP_ALSA,
- /**< The default mapping used by ALSA */
+ /**< The default mapping used by ALSA. This mapping is probably
+ * not too useful since ALSA's default channel mapping depends on
+ * the device string used. */
+/** \endcond */
PA_CHANNEL_MAP_AUX,
/**< Only aux channels */
PA_CHANNEL_MAP_WAVEEX,
- /**< Microsoft's WAVEFORMATEXTENSIBLE mapping */
+ /**< Microsoft's WAVEFORMATEXTENSIBLE mapping. This mapping works
+ * as if all LSBs of dwChannelMask are set. */
+/** \cond fulldocs */
PA_CHANNEL_MAP_OSS,
- /**< The default channel mapping used by OSS as defined in the OSS 4.0 API specs */
+ /**< The default channel mapping used by OSS as defined in the OSS
+ * 4.0 API specs. This mapping is probably not too useful since
+ * the OSS API has changed in this respect and no longer knows a
+ * default channel mapping based on the number of channels. */
+/** \endcond */
/**< Upper limit of valid channel mapping definitions */
PA_CHANNEL_MAP_DEF_MAX,
@@ -282,6 +295,9 @@ pa_channel_map* pa_channel_map_init_extend(pa_channel_map *m, unsigned channels,
/** Return a text label for the specified channel position */
const char* pa_channel_position_to_string(pa_channel_position_t pos) PA_GCC_PURE;
+/** The inverse of pa_channel_position_to_string(). \since 0.9.16 */
+pa_channel_position_t pa_channel_position_from_string(const char *s) PA_GCC_PURE;
+
/** Return a human readable text label for the specified channel position. \since 0.9.7 */
const char* pa_channel_position_to_pretty_string(pa_channel_position_t pos);
diff --git a/src/pulse/client-conf-x11.c b/src/pulse/client-conf-x11.c
index 4970363b..76b1b7b3 100644
--- a/src/pulse/client-conf-x11.c
+++ b/src/pulse/client-conf-x11.c
@@ -25,8 +25,7 @@
#include <string.h>
-#include <X11/Xlib.h>
-#include <X11/Xatom.h>
+#include <xcb/xcb.h>
#include <pulse/xmalloc.h>
#include <pulse/i18n.h>
@@ -39,8 +38,8 @@
#include "client-conf-x11.h"
int pa_client_conf_from_x11(pa_client_conf *c, const char *dname) {
- Display *d = NULL;
- int ret = -1;
+ xcb_connection_t *xcb = NULL;
+ int ret = -1, screen = 0;
char t[1024];
pa_assert(c);
@@ -51,18 +50,23 @@ int pa_client_conf_from_x11(pa_client_conf *c, const char *dname) {
if (*dname == 0)
goto finish;
- if (!(d = XOpenDisplay(dname))) {
- pa_log(_("XOpenDisplay() failed"));
+ if (!(xcb = xcb_connect(dname, NULL))) {
+ pa_log(_("xcb_connect() failed"));
goto finish;
}
- if (pa_x11_get_prop(d, "PULSE_SERVER", t, sizeof(t))) {
+ if (xcb_connection_has_error(xcb)) {
+ pa_log(_("xcb_connection_has_error() returned true"));
+ goto finish;
+ }
+
+ if (pa_x11_get_prop(xcb, screen, "PULSE_SERVER", t, sizeof(t))) {
pa_bool_t disable_autospawn = TRUE;
pa_xfree(c->default_server);
c->default_server = pa_xstrdup(t);
- if (pa_x11_get_prop(d, "PULSE_SESSION_ID", t, sizeof(t))) {
+ if (pa_x11_get_prop(xcb, screen, "PULSE_SESSION_ID", t, sizeof(t))) {
char *id;
if ((id = pa_session_id())) {
@@ -76,17 +80,17 @@ int pa_client_conf_from_x11(pa_client_conf *c, const char *dname) {
c->autospawn = FALSE;
}
- if (pa_x11_get_prop(d, "PULSE_SINK", t, sizeof(t))) {
+ if (pa_x11_get_prop(xcb, screen, "PULSE_SINK", t, sizeof(t))) {
pa_xfree(c->default_sink);
c->default_sink = pa_xstrdup(t);
}
- if (pa_x11_get_prop(d, "PULSE_SOURCE", t, sizeof(t))) {
+ if (pa_x11_get_prop(xcb, screen, "PULSE_SOURCE", t, sizeof(t))) {
pa_xfree(c->default_source);
c->default_source = pa_xstrdup(t);
}
- if (pa_x11_get_prop(d, "PULSE_COOKIE", t, sizeof(t))) {
+ if (pa_x11_get_prop(xcb, screen, "PULSE_COOKIE", t, sizeof(t))) {
uint8_t cookie[PA_NATIVE_COOKIE_LENGTH];
if (pa_parsehex(t, cookie, sizeof(cookie)) != sizeof(cookie)) {
@@ -106,8 +110,8 @@ int pa_client_conf_from_x11(pa_client_conf *c, const char *dname) {
ret = 0;
finish:
- if (d)
- XCloseDisplay(d);
+ if (xcb)
+ xcb_disconnect(xcb);
return ret;
diff --git a/src/pulse/client-conf.c b/src/pulse/client-conf.c
index 940d0b67..e899af19 100644
--- a/src/pulse/client-conf.c
+++ b/src/pulse/client-conf.c
@@ -27,7 +27,6 @@
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
-#include <string.h>
#include <pulse/xmalloc.h>
#include <pulse/i18n.h>
@@ -57,11 +56,14 @@ static const pa_client_conf default_conf = {
.default_sink = NULL,
.default_source = NULL,
.default_server = NULL,
+ .default_dbus_server = NULL,
.autospawn = TRUE,
.disable_shm = FALSE,
.cookie_file = NULL,
.cookie_valid = FALSE,
- .shm_size = 0
+ .shm_size = 0,
+ .auto_connect_localhost = FALSE,
+ .auto_connect_display = FALSE
};
pa_client_conf *pa_client_conf_new(void) {
@@ -81,6 +83,7 @@ void pa_client_conf_free(pa_client_conf *c) {
pa_xfree(c->default_sink);
pa_xfree(c->default_source);
pa_xfree(c->default_server);
+ pa_xfree(c->default_dbus_server);
pa_xfree(c->cookie_file);
pa_xfree(c);
}
@@ -92,21 +95,25 @@ int pa_client_conf_load(pa_client_conf *c, const char *filename) {
/* Prepare the configuration parse table */
pa_config_item table[] = {
- { "daemon-binary", pa_config_parse_string, &c->daemon_binary, NULL },
- { "extra-arguments", pa_config_parse_string, &c->extra_arguments, NULL },
- { "default-sink", pa_config_parse_string, &c->default_sink, NULL },
- { "default-source", pa_config_parse_string, &c->default_source, NULL },
- { "default-server", pa_config_parse_string, &c->default_server, NULL },
- { "autospawn", pa_config_parse_bool, &c->autospawn, NULL },
- { "cookie-file", pa_config_parse_string, &c->cookie_file, NULL },
- { "disable-shm", pa_config_parse_bool, &c->disable_shm, NULL },
- { "shm-size-bytes", pa_config_parse_size, &c->shm_size, NULL },
- { NULL, NULL, NULL, NULL },
+ { "daemon-binary", pa_config_parse_string, &c->daemon_binary, NULL },
+ { "extra-arguments", pa_config_parse_string, &c->extra_arguments, NULL },
+ { "default-sink", pa_config_parse_string, &c->default_sink, NULL },
+ { "default-source", pa_config_parse_string, &c->default_source, NULL },
+ { "default-server", pa_config_parse_string, &c->default_server, NULL },
+ { "default-dbus-server", pa_config_parse_string, &c->default_dbus_server, NULL },
+ { "autospawn", pa_config_parse_bool, &c->autospawn, NULL },
+ { "cookie-file", pa_config_parse_string, &c->cookie_file, NULL },
+ { "disable-shm", pa_config_parse_bool, &c->disable_shm, NULL },
+ { "enable-shm", pa_config_parse_not_bool, &c->disable_shm, NULL },
+ { "shm-size-bytes", pa_config_parse_size, &c->shm_size, NULL },
+ { "auto-connect-localhost", pa_config_parse_bool, &c->auto_connect_localhost, NULL },
+ { "auto-connect-display", pa_config_parse_bool, &c->auto_connect_display, NULL },
+ { NULL, NULL, NULL, NULL },
};
if (filename) {
- if (!(f = fopen(filename, "r"))) {
+ if (!(f = pa_fopen_cloexec(filename, "r"))) {
pa_log(_("Failed to open configuration file '%s': %s"), fn, pa_cstrerror(errno));
goto finish;
}
diff --git a/src/pulse/client-conf.h b/src/pulse/client-conf.h
index ab97dc6a..f281f4eb 100644
--- a/src/pulse/client-conf.h
+++ b/src/pulse/client-conf.h
@@ -22,13 +22,14 @@
USA.
***/
+#include <pulsecore/macro.h>
#include <pulsecore/native-common.h>
/* A structure containing configuration data for PulseAudio clients. */
typedef struct pa_client_conf {
- char *daemon_binary, *extra_arguments, *default_sink, *default_source, *default_server, *cookie_file;
- pa_bool_t autospawn, disable_shm;
+ char *daemon_binary, *extra_arguments, *default_sink, *default_source, *default_server, *default_dbus_server, *cookie_file;
+ pa_bool_t autospawn, disable_shm, auto_connect_localhost, auto_connect_display;
uint8_t cookie[PA_NATIVE_COOKIE_LENGTH];
pa_bool_t cookie_valid; /* non-zero, when cookie is valid */
size_t shm_size;
diff --git a/src/pulse/client.conf.in b/src/pulse/client.conf.in
index 579bcc20..17753b02 100644
--- a/src/pulse/client.conf.in
+++ b/src/pulse/client.conf.in
@@ -16,12 +16,13 @@
# USA.
## Configuration file for PulseAudio clients. See pulse-client.conf(5) for
-## more information. Default values a commented out. Use either ; or # for
+## more information. Default values are commented out. Use either ; or # for
## commenting.
; default-sink =
; default-source =
; default-server =
+; default-dbus-server =
; autospawn = yes
; daemon-binary = @PA_BINARY@
@@ -29,5 +30,8 @@
; cookie-file =
-; disable-shm = no
+; enable-shm = yes
; shm-size-bytes = 0 # setting this 0 will use the system-default, usually 64 MiB
+
+; auto-connect-localhost = no
+; auto-connect-display = no
diff --git a/src/pulse/context.c b/src/pulse/context.c
index 3b7bf08d..e8f30328 100644
--- a/src/pulse/context.c
+++ b/src/pulse/context.c
@@ -32,54 +32,43 @@
#include <sys/stat.h>
#include <errno.h>
#include <signal.h>
-#include <limits.h>
-#include <locale.h>
#ifdef HAVE_SYS_WAIT_H
#include <sys/wait.h>
#endif
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#ifdef HAVE_SYS_UN_H
-#include <sys/un.h>
-#endif
#ifdef HAVE_NETDB_H
#include <netdb.h>
#endif
#include <pulse/version.h>
#include <pulse/xmalloc.h>
-#include <pulse/utf8.h>
#include <pulse/util.h>
#include <pulse/i18n.h>
+#include <pulse/mainloop.h>
+#include <pulse/timeval.h>
+#include <pulse/fork-detect.h>
+#include <pulse/client-conf.h>
+#ifdef HAVE_X11
+#include <pulse/client-conf-x11.h>
+#endif
-#include <pulsecore/winsock.h>
#include <pulsecore/core-error.h>
-
#include <pulsecore/native-common.h>
#include <pulsecore/pdispatch.h>
#include <pulsecore/pstream.h>
-#include <pulsecore/dynarray.h>
+#include <pulsecore/hashmap.h>
#include <pulsecore/socket-client.h>
#include <pulsecore/pstream-util.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
-#include <pulsecore/socket-util.h>
+#include <pulsecore/socket.h>
#include <pulsecore/creds.h>
#include <pulsecore/macro.h>
#include <pulsecore/proplist-util.h>
#include "internal.h"
-
-#include "client-conf.h"
-#include "fork-detect.h"
-
-#ifdef HAVE_X11
-#include "client-conf-x11.h"
-#endif
-
#include "context.h"
void pa_command_extension(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata);
@@ -125,6 +114,12 @@ static void reset_callbacks(pa_context *c) {
c->event_callback = NULL;
c->event_userdata = NULL;
+ c->ext_device_manager.callback = NULL;
+ c->ext_device_manager.userdata = NULL;
+
+ c->ext_device_restore.callback = NULL;
+ c->ext_device_restore.userdata = NULL;
+
c->ext_stream_restore.callback = NULL;
c->ext_stream_restore.userdata = NULL;
}
@@ -139,7 +134,7 @@ pa_context *pa_context_new_with_proplist(pa_mainloop_api *mainloop, const char *
pa_init_i18n();
- c = pa_xnew(pa_context, 1);
+ c = pa_xnew0(pa_context, 1);
PA_REFCNT_INIT(c);
c->proplist = p ? pa_proplist_copy(p) : pa_proplist_new();
@@ -151,34 +146,19 @@ pa_context *pa_context_new_with_proplist(pa_mainloop_api *mainloop, const char *
c->system_bus = c->session_bus = NULL;
#endif
c->mainloop = mainloop;
- c->client = NULL;
- c->pstream = NULL;
- c->pdispatch = NULL;
- c->playback_streams = pa_dynarray_new();
- c->record_streams = pa_dynarray_new();
+ c->playback_streams = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ c->record_streams = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
c->client_index = PA_INVALID_INDEX;
+ c->use_rtclock = pa_mainloop_is_our_api(mainloop);
PA_LLIST_HEAD_INIT(pa_stream, c->streams);
PA_LLIST_HEAD_INIT(pa_operation, c->operations);
c->error = PA_OK;
c->state = PA_CONTEXT_UNCONNECTED;
- c->ctag = 0;
- c->csyncid = 0;
reset_callbacks(c);
- c->is_local = FALSE;
- c->server_list = NULL;
- c->server = NULL;
-
- c->do_shm = FALSE;
-
- c->server_specified = FALSE;
- c->no_fail = FALSE;
- c->do_autospawn = FALSE;
- memset(&c->spawn_api, 0, sizeof(c->spawn_api));
-
#ifndef MSG_NOSIGNAL
#ifdef SIGPIPE
pa_check_signal_is_blocked(SIGPIPE);
@@ -248,20 +228,22 @@ static void context_free(pa_context *c) {
#ifdef HAVE_DBUS
if (c->system_bus) {
- dbus_connection_remove_filter(pa_dbus_wrap_connection_get(c->system_bus), filter_cb, c);
+ if (c->filter_added)
+ dbus_connection_remove_filter(pa_dbus_wrap_connection_get(c->system_bus), filter_cb, c);
pa_dbus_wrap_connection_free(c->system_bus);
}
if (c->session_bus) {
- dbus_connection_remove_filter(pa_dbus_wrap_connection_get(c->session_bus), filter_cb, c);
+ if (c->filter_added)
+ dbus_connection_remove_filter(pa_dbus_wrap_connection_get(c->session_bus), filter_cb, c);
pa_dbus_wrap_connection_free(c->session_bus);
}
#endif
if (c->record_streams)
- pa_dynarray_free(c->record_streams, NULL, NULL);
+ pa_hashmap_free(c->record_streams, NULL, NULL);
if (c->playback_streams)
- pa_dynarray_free(c->playback_streams, NULL, NULL);
+ pa_hashmap_free(c->playback_streams, NULL, NULL);
if (c->mempool)
pa_mempool_free(c->mempool);
@@ -368,7 +350,7 @@ static void pstream_memblock_callback(pa_pstream *p, uint32_t channel, int64_t o
pa_context_ref(c);
- if ((s = pa_dynarray_get(c->record_streams, channel))) {
+ if ((s = pa_hashmap_get(c->record_streams, PA_UINT32_TO_PTR(channel)))) {
if (chunk->memblock) {
pa_memblockq_seek(s->record_memblockq, offset, seek, TRUE);
@@ -540,7 +522,7 @@ static void setup_context(pa_context *c, pa_iochannel *io) {
pa_pstream_set_recieve_memblock_callback(c->pstream, pstream_memblock_callback, c);
pa_assert(!c->pdispatch);
- c->pdispatch = pa_pdispatch_new(c->mainloop, command_table, PA_COMMAND_MAX);
+ c->pdispatch = pa_pdispatch_new(c->mainloop, c->use_rtclock, command_table, PA_COMMAND_MAX);
if (!c->conf->cookie_valid)
pa_log_info(_("No cookie loaded. Attempting to connect without."));
@@ -596,10 +578,12 @@ static char *get_old_legacy_runtime_dir(void) {
return NULL;
}
+#ifdef HAVE_GETUID
if (st.st_uid != getuid()) {
pa_xfree(p);
return NULL;
}
+#endif
return p;
}
@@ -618,10 +602,12 @@ static char *get_very_old_legacy_runtime_dir(void) {
return NULL;
}
+#ifdef HAVE_GETUID
if (st.st_uid != getuid()) {
pa_xfree(p);
return NULL;
}
+#endif
return p;
}
@@ -631,7 +617,7 @@ static pa_strlist *prepend_per_user(pa_strlist *l) {
char *ufn;
#ifdef ENABLE_LEGACY_RUNTIME_DIR
- static char *legacy_dir;
+ char *legacy_dir;
/* The very old per-user instance path (< 0.9.11). This is supported only to ease upgrades */
if ((legacy_dir = get_very_old_legacy_runtime_dir())) {
@@ -664,11 +650,24 @@ static pa_strlist *prepend_per_user(pa_strlist *l) {
static int context_autospawn(pa_context *c) {
pid_t pid;
int status, r;
-
- pa_log_debug("Trying to autospawn...");
+ struct sigaction sa;
pa_context_ref(c);
+ if (sigaction(SIGCHLD, NULL, &sa) < 0) {
+ pa_log_debug("sigaction() failed: %s", pa_cstrerror(errno));
+ pa_context_fail(c, PA_ERR_INTERNAL);
+ goto fail;
+ }
+
+ if ((sa.sa_flags & SA_NOCLDWAIT) || sa.sa_handler == SIG_IGN) {
+ pa_log_debug("Process disabled waitpid(), cannot autospawn.");
+ pa_context_fail(c, PA_ERR_CONNECTIONREFUSED);
+ goto fail;
+ }
+
+ pa_log_debug("Trying to autospawn...");
+
if (c->spawn_api.prefork)
c->spawn_api.prefork();
@@ -684,23 +683,23 @@ static int context_autospawn(pa_context *c) {
/* Child */
const char *state = NULL;
-#define MAX_ARGS 64
- const char * argv[MAX_ARGS+1];
- int n;
+ const char * argv[32];
+ unsigned n = 0;
if (c->spawn_api.atfork)
c->spawn_api.atfork();
+ /* We leave most of the cleaning up of the process environment
+ * to the executable. We only clean up the file descriptors to
+ * make sure the executable can actually be loaded
+ * correctly. */
pa_close_all(-1);
/* Setup argv */
-
- n = 0;
-
argv[n++] = c->conf->daemon_binary;
argv[n++] = "--start";
- while (n < MAX_ARGS) {
+ while (n < PA_ELEMENTSOF(argv)-1) {
char *a;
if (!(a = pa_split_spaces(c->conf->extra_arguments, &state)))
@@ -710,10 +709,10 @@ static int context_autospawn(pa_context *c) {
}
argv[n++] = NULL;
+ pa_assert(n <= PA_ELEMENTSOF(argv));
execv(argv[0], (char * const *) argv);
_exit(1);
-#undef MAX_ARGS
}
/* Parent */
@@ -726,9 +725,16 @@ static int context_autospawn(pa_context *c) {
} while (r < 0 && errno == EINTR);
if (r < 0) {
- pa_log(_("waitpid(): %s"), pa_cstrerror(errno));
- pa_context_fail(c, PA_ERR_INTERNAL);
- goto fail;
+
+ if (errno != ESRCH) {
+ pa_log(_("waitpid(): %s"), pa_cstrerror(errno));
+ pa_context_fail(c, PA_ERR_INTERNAL);
+ goto fail;
+ }
+
+ /* hmm, something already reaped our child, so we assume
+ * startup worked, even if we cannot know */
+
} else if (!WIFEXITED(status) || WEXITSTATUS(status) != 0) {
pa_context_fail(c, PA_ERR_CONNECTIONREFUSED);
goto fail;
@@ -757,22 +763,34 @@ static void track_pulseaudio_on_dbus(pa_context *c, DBusBusType type, pa_dbus_wr
pa_assert(conn);
dbus_error_init(&error);
- if (!(*conn = pa_dbus_wrap_connection_new(c->mainloop, type, &error)) || dbus_error_is_set(&error)) {
+
+ if (!(*conn = pa_dbus_wrap_connection_new(c->mainloop, c->use_rtclock, type, &error)) || dbus_error_is_set(&error)) {
pa_log_warn("Unable to contact DBUS: %s: %s", error.name, error.message);
- goto finish;
+ goto fail;
}
if (!dbus_connection_add_filter(pa_dbus_wrap_connection_get(*conn), filter_cb, c, NULL)) {
pa_log_warn("Failed to add filter function");
- goto finish;
+ goto fail;
}
+ c->filter_added = TRUE;
if (pa_dbus_add_matches(
pa_dbus_wrap_connection_get(*conn), &error,
- "type='signal',sender='" DBUS_SERVICE_DBUS "',interface='" DBUS_INTERFACE_DBUS "',member='NameOwnerChanged',arg0='org.pulseaudio.Server',arg1=''", NULL) < 0)
+ "type='signal',sender='" DBUS_SERVICE_DBUS "',interface='" DBUS_INTERFACE_DBUS "',member='NameOwnerChanged',arg0='org.pulseaudio.Server',arg1=''", NULL) < 0) {
+
pa_log_warn("Unable to track org.pulseaudio.Server: %s: %s", error.name, error.message);
+ goto fail;
+ }
+
+ return;
+
+fail:
+ if (*conn) {
+ pa_dbus_wrap_connection_free(*conn);
+ *conn = NULL;
+ }
- finish:
dbus_error_free(&error);
}
#endif
@@ -827,7 +845,7 @@ static int try_next_connection(pa_context *c) {
pa_xfree(c->server);
c->server = pa_xstrdup(u);
- if (!(c->client = pa_socket_client_new_string(c->mainloop, u, PA_NATIVE_DEFAULT_PORT)))
+ if (!(c->client = pa_socket_client_new_string(c->mainloop, c->use_rtclock, u, PA_NATIVE_DEFAULT_PORT)))
continue;
c->is_local = !!pa_socket_client_is_local(c->client);
@@ -857,7 +875,7 @@ static void on_connection(pa_socket_client *client, pa_iochannel*io, void *userd
c->client = NULL;
if (!io) {
- /* Try the item in the list */
+ /* Try the next item in the list */
if (saved_errno == ECONNREFUSED ||
saved_errno == ETIMEDOUT ||
saved_errno == EHOSTUNREACH) {
@@ -893,7 +911,7 @@ static DBusHandlerResult filter_cb(DBusConnection *bus, DBusMessage *message, vo
/* FIXME: We probably should check if this is actually the NameOwnerChanged we were looking for */
is_session = c->session_bus && bus == pa_dbus_wrap_connection_get(c->session_bus);
- pa_log_debug("Rock!! PulseAudio is back on %s bus", is_session ? "session" : "system");
+ pa_log_debug("Rock!! PulseAudio might be back on %s bus", is_session ? "session" : "system");
if (is_session)
/* The user instance via PF_LOCAL */
@@ -933,7 +951,7 @@ int pa_context_connect(
pa_context_ref(c);
- c->no_fail = flags & PA_CONTEXT_NOFAIL;
+ c->no_fail = !!(flags & PA_CONTEXT_NOFAIL);
c->server_specified = !!server;
pa_assert(!c->server_list);
@@ -949,21 +967,22 @@ int pa_context_connect(
/* Prepend in reverse order */
/* Follow the X display */
- if ((d = getenv("DISPLAY"))) {
- char *e;
- d = pa_xstrdup(d);
- if ((e = strchr(d, ':')))
- *e = 0;
+ if (c->conf->auto_connect_display) {
+ if ((d = getenv("DISPLAY"))) {
+ d = pa_xstrndup(d, strcspn(d, ":"));
- if (*d)
- c->server_list = pa_strlist_prepend(c->server_list, d);
+ if (*d)
+ c->server_list = pa_strlist_prepend(c->server_list, d);
- pa_xfree(d);
+ pa_xfree(d);
+ }
}
/* Add TCP/IP on the localhost */
- c->server_list = pa_strlist_prepend(c->server_list, "tcp6:[::1]");
- c->server_list = pa_strlist_prepend(c->server_list, "tcp4:127.0.0.1");
+ if (c->conf->auto_connect_localhost) {
+ c->server_list = pa_strlist_prepend(c->server_list, "tcp6:[::1]");
+ c->server_list = pa_strlist_prepend(c->server_list, "tcp4:127.0.0.1");
+ }
/* The system wide instance via PF_LOCAL */
c->server_list = pa_strlist_prepend(c->server_list, PA_SYSTEM_RUNTIME_PATH PA_PATH_SEP PA_NATIVE_DEFAULT_UNIX_SOCKET);
@@ -975,6 +994,7 @@ int pa_context_connect(
/* Set up autospawning */
if (!(flags & PA_CONTEXT_NOAUTOSPAWN) && c->conf->autospawn) {
+#ifdef HAVE_GETUID
if (getuid() == 0)
pa_log_debug("Not doing autospawn since we are root.");
else {
@@ -983,6 +1003,7 @@ int pa_context_connect(
if (api)
c->spawn_api = *api;
}
+#endif
}
pa_context_set_state(c, PA_CONTEXT_CONNECTING);
@@ -1013,7 +1034,10 @@ pa_context_state_t pa_context_get_state(pa_context *c) {
}
int pa_context_errno(pa_context *c) {
- pa_assert(c);
+
+ if (!c)
+ return PA_ERR_INVALID;
+
pa_assert(PA_REFCNT_VALUE(c) >= 1);
return c->error;
@@ -1397,7 +1421,11 @@ void pa_command_extension(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_t
goto finish;
}
- if (!strcmp(name, "module-stream-restore"))
+ if (pa_streq(name, "module-device-manager"))
+ pa_ext_device_manager_command(c, tag, t);
+ else if (pa_streq(name, "module-device-restore"))
+ pa_ext_device_manager_command(c, tag, t);
+ else if (pa_streq(name, "module-stream-restore"))
pa_ext_stream_restore_command(c, tag, t);
else
pa_log(_("Received message for unknown extension '%s'"), name);
@@ -1443,3 +1471,48 @@ finish:
if (pl)
pa_proplist_free(pl);
}
+
+pa_time_event* pa_context_rttime_new(pa_context *c, pa_usec_t usec, pa_time_event_cb_t cb, void *userdata) {
+ struct timeval tv;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(c->mainloop);
+
+ if (usec == PA_USEC_INVALID)
+ return c->mainloop->time_new(c->mainloop, NULL, cb, userdata);
+
+ pa_timeval_rtstore(&tv, usec, c->use_rtclock);
+
+ return c->mainloop->time_new(c->mainloop, &tv, cb, userdata);
+}
+
+void pa_context_rttime_restart(pa_context *c, pa_time_event *e, pa_usec_t usec) {
+ struct timeval tv;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(c->mainloop);
+
+
+ if (usec == PA_USEC_INVALID)
+ c->mainloop->time_restart(e, NULL);
+ else {
+ pa_timeval_rtstore(&tv, usec, c->use_rtclock);
+ c->mainloop->time_restart(e, &tv);
+ }
+}
+
+size_t pa_context_get_tile_size(pa_context *c, const pa_sample_spec *ss) {
+ size_t fs, mbs;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_ANY(c, !pa_detect_fork(), PA_ERR_FORKED, (size_t) -1);
+ PA_CHECK_VALIDITY_RETURN_ANY(c, !ss || pa_sample_spec_valid(ss), PA_ERR_INVALID, (size_t) -1);
+
+ fs = ss ? pa_frame_size(ss) : 1;
+ mbs = PA_ROUND_DOWN(pa_mempool_block_size_max(c->mempool), fs);
+ return PA_MAX(mbs, fs);
+}
diff --git a/src/pulse/context.h b/src/pulse/context.h
index 139d0e0b..7686456d 100644
--- a/src/pulse/context.h
+++ b/src/pulse/context.h
@@ -145,13 +145,10 @@
/** \file
* Connection contexts for asynchrononous communication with a
* server. A pa_context object wraps a connection to a PulseAudio
- * server using its native protocol. */
-
-/** \example pacat.c
- * A playback and recording tool using the asynchronous API */
-
-/** \example paplay.c
- * A sound file playback tool using the asynchronous API, based on libsndfile */
+ * server using its native protocol.
+ *
+ * See also \subpage async
+ */
PA_C_DECL_BEGIN
@@ -260,6 +257,29 @@ pa_operation *pa_context_proplist_remove(pa_context *c, const char *const keys[]
* introspection functions, such as pa_context_get_client_info(). \since 0.9.11 */
uint32_t pa_context_get_index(pa_context *s);
+/** Create a new timer event source for the specified time (wrapper
+ * for mainloop->time_new). \since 0.9.16 */
+pa_time_event* pa_context_rttime_new(pa_context *c, pa_usec_t usec, pa_time_event_cb_t cb, void *userdata);
+
+/** Restart a running or expired timer event source (wrapper for
+ * mainloop->time_restart). \since 0.9.16 */
+void pa_context_rttime_restart(pa_context *c, pa_time_event *e, pa_usec_t usec);
+
+/* Return the optimal block size for passing around audio buffers. It
+ * is recommended to allocate buffers of the size returned here when
+ * writing audio data to playback streams, if the latency constraints
+ * permit this. It is not recommended writing larger blocks than this
+ * because usually they will then be split up internally into chunks
+ * of this size. It is not recommended writing smaller blocks than
+ * this (unless required due to latency demands) because this
+ * increases CPU usage. If ss is NULL you will be returned the
+ * byte-exact tile size. If you pass a valid ss, then the tile size
+ * will be rounded down to multiple of the frame size. This is
+ * supposed to be used in a construct such as
+ * pa_context_get_tile_size(pa_stream_get_context(s),
+ * pa_stream_get_sample_spec(ss)); \since 0.9.20 */
+size_t pa_context_get_tile_size(pa_context *c, const pa_sample_spec *ss);
+
PA_C_DECL_END
#endif
diff --git a/src/pulse/def.h b/src/pulse/def.h
index d5bbefe3..16b2e596 100644
--- a/src/pulse/def.h
+++ b/src/pulse/def.h
@@ -25,7 +25,6 @@
#include <inttypes.h>
#include <sys/time.h>
-#include <time.h>
#include <pulse/cdecl.h>
#include <pulse/sample.h>
@@ -63,6 +62,7 @@ static inline int PA_CONTEXT_IS_GOOD(pa_context_state_t x) {
#define PA_CONTEXT_SETTING_NAME PA_CONTEXT_SETTING_NAME
#define PA_CONTEXT_READY PA_CONTEXT_READY
#define PA_CONTEXT_FAILED PA_CONTEXT_FAILED
+#define PA_CONTEXT_TERMINATED PA_CONTEXT_TERMINATED
#define PA_CONTEXT_IS_GOOD PA_CONTEXT_IS_GOOD
/** \endcond */
@@ -95,13 +95,14 @@ static inline int PA_STREAM_IS_GOOD(pa_stream_state_t x) {
typedef enum pa_operation_state {
PA_OPERATION_RUNNING, /**< The operation is still running */
PA_OPERATION_DONE, /**< The operation has been completed */
- PA_OPERATION_CANCELED /**< The operation has been canceled */
+ PA_OPERATION_CANCELLED /**< The operation has been cancelled. Before 0.9.18 this was called PA_OPERATION_CANCELED. That name is still available for compatibility. */
} pa_operation_state_t;
/** \cond fulldocs */
#define PA_OPERATION_RUNNING PA_OPERATION_RUNNING
#define PA_OPERATION_DONE PA_OPERATION_DONE
-#define PA_OPERATION_CANCELED PA_OPERATION_CANCELED
+#define PA_OPERATION_CANCELED PA_OPERATION_CANCELLED
+#define PA_OPERATION_CANCELLED PA_OPERATION_CANCELLED
/** \endcond */
/** An invalid index */
@@ -109,6 +110,8 @@ typedef enum pa_operation_state {
/** Some special flags for contexts. */
typedef enum pa_context_flags {
+ PA_CONTEXT_NOFLAGS = 0x0000U,
+ /**< Flag to pass when no specific options are needed (used to avoid casting) \since 0.9.19 */
PA_CONTEXT_NOAUTOSPAWN = 0x0001U,
/**< Disabled autospawning of the PulseAudio daemon if required */
PA_CONTEXT_NOFAIL = 0x0002U
@@ -139,6 +142,9 @@ typedef enum pa_stream_direction {
/** Some special flags for stream connections. */
typedef enum pa_stream_flags {
+ PA_STREAM_NOFLAGS = 0x0000U,
+ /**< Flag to pass when no specific options are needed (used to avoid casting) \since 0.9.19 */
+
PA_STREAM_START_CORKED = 0x0001U,
/**< Create the stream corked, requiring an explicit
* pa_stream_cork() call to uncork it. */
@@ -270,11 +276,24 @@ typedef enum pa_stream_flags {
* whether to create the stream in muted or in unmuted
* state. \since 0.9.15 */
- PA_STREAM_FAIL_ON_SUSPEND = 0x20000U
+ PA_STREAM_FAIL_ON_SUSPEND = 0x20000U,
/**< If the sink/source this stream is connected to is suspended
* during the creation of this stream, cause it to fail. If the
* sink/source is being suspended during creation of this stream,
* make sure this stream is terminated. \since 0.9.15 */
+
+ PA_STREAM_RELATIVE_VOLUME = 0x40000U,
+ /**< If a volume is passed when this stream is created, consider
+ * it relative to the sink's current volume, never as absolute
+ * device volume. If this is not specified the volume will be
+ * consider absolute when the sink is in flat volume mode,
+ * relative otherwise. \since 0.9.20 */
+
+ PA_STREAM_PASSTHROUGH = 0x80000U
+ /**< Used to tag content that will be rendered by passthrough sinks.
+ * The data will be left as is and not reformatted, resampled.
+ * \since 1.0 */
+
} pa_stream_flags_t;
/** \cond fulldocs */
@@ -301,6 +320,8 @@ typedef enum pa_stream_flags {
#define PA_STREAM_DONT_INHIBIT_AUTO_SUSPEND PA_STREAM_DONT_INHIBIT_AUTO_SUSPEND
#define PA_STREAM_START_UNMUTED PA_STREAM_START_UNMUTED
#define PA_STREAM_FAIL_ON_SUSPEND PA_STREAM_FAIL_ON_SUSPEND
+#define PA_STREAM_RELATIVE_VOLUME PA_STREAM_RELATIVE_VOLUME
+#define PA_STREAM_PASSTHROUGH PA_STREAM_PASSTHROUGH
/** \endcond */
@@ -337,7 +358,7 @@ typedef struct pa_buffer_attr {
* that may be. Initialize to 0 to enable manual start/stop
* control of the stream. This means that playback will not stop
* on underrun and playback will not start automatically. Instead
- * pa_stream_corked() needs to be called explicitly. If you set
+ * pa_stream_cork() needs to be called explicitly. If you set
* this value to 0 you should also set PA_STREAM_START_CORKED. */
uint32_t minreq;
@@ -393,6 +414,8 @@ enum {
PA_ERR_OBSOLETE, /**< Obsolete functionality. \since 0.9.15 */
PA_ERR_NOTIMPLEMENTED, /**< Missing implementation. \since 0.9.15 */
PA_ERR_FORKED, /**< The caller forked without calling execve() and tried to reuse the context. \since 0.9.15 */
+ PA_ERR_IO, /**< An IO error happened. \since 0.9.16 */
+ PA_ERR_BUSY, /**< Device or resource busy. \since 0.9.17 */
PA_ERR_MAX /**< Not really an error but the first invalid error code */
};
@@ -685,6 +708,9 @@ typedef enum pa_seek_mode {
/** Special sink flags. */
typedef enum pa_sink_flags {
+ PA_SINK_NOFLAGS = 0x0000U,
+ /**< Flag to pass when no specific options are needed (used to avoid casting) \since 0.9.19 */
+
PA_SINK_HW_VOLUME_CTRL = 0x0001U,
/**< Supports hardware volume control */
@@ -709,9 +735,24 @@ typedef enum pa_sink_flags {
/**< This sink is in flat volume mode, i.e. always the maximum of
* the volume of all connected inputs. \since 0.9.15 */
- PA_SINK_DYNAMIC_LATENCY = 0x0080U
+ PA_SINK_DYNAMIC_LATENCY = 0x0080U,
/**< The latency can be adjusted dynamically depending on the
* needs of the connected streams. \since 0.9.15 */
+
+ PA_SINK_SYNC_VOLUME = 0x0100U,
+ /**< The HW volume changes are syncronized with SW volume.
+ * \since 1.0 */
+
+/** \cond fulldocs */
+ /* PRIVATE: Server-side values -- do not try to use these at client-side.
+ * The server will filter out these flags anyway, so you should never see
+ * these flags in sinks. */
+
+ PA_SINK_SHARE_VOLUME_WITH_MASTER = 0x0200U,
+ /**< This sink shares the volume with the master sink (used by some filter
+ * sinks). */
+/** \endcond */
+
} pa_sink_flags_t;
/** \cond fulldocs */
@@ -723,6 +764,9 @@ typedef enum pa_sink_flags {
#define PA_SINK_DECIBEL_VOLUME PA_SINK_DECIBEL_VOLUME
#define PA_SINK_FLAT_VOLUME PA_SINK_FLAT_VOLUME
#define PA_SINK_DYNAMIC_LATENCY PA_SINK_DYNAMIC_LATENCY
+#define PA_SINK_SYNC_VOLUME PA_SINK_SYNC_VOLUME
+#define PA_SINK_SHARE_VOLUME_WITH_MASTER PA_SINK_SHARE_VOLUME_WITH_MASTER
+
/** \endcond */
/** Sink state. \since 0.9.15 */
@@ -772,6 +816,9 @@ static inline int PA_SINK_IS_OPENED(pa_sink_state_t x) {
/** Special source flags. */
typedef enum pa_source_flags {
+ PA_SOURCE_NOFLAGS = 0x0000U,
+ /**< Flag to pass when no specific options are needed (used to avoid casting) \since 0.9.19 */
+
PA_SOURCE_HW_VOLUME_CTRL = 0x0001U,
/**< Supports hardware volume control */
@@ -792,9 +839,31 @@ typedef enum pa_source_flags {
/**< Volume can be translated to dB with pa_sw_volume_to_dB()
* \since 0.9.11 */
- PA_SOURCE_DYNAMIC_LATENCY = 0x0040U
+ PA_SOURCE_DYNAMIC_LATENCY = 0x0040U,
/**< The latency can be adjusted dynamically depending on the
* needs of the connected streams. \since 0.9.15 */
+
+ PA_SOURCE_FLAT_VOLUME = 0x0080U,
+ /**< This source is in flat volume mode, i.e. always the maximum of
+ * the volume of all connected outputs. \since 1.0 */
+
+ PA_SOURCE_PASSTHROUGH = 0x0100U,
+ /**< This sink has support for passthrough mode. The data will be left
+ * as is and not reformatted, resampled, mixed.
+ * \since 1.0 */
+
+ PA_SOURCE_SYNC_VOLUME = 0x0200U,
+ /**< The HW volume changes are syncronized with SW volume.
+ * \since 1.0 */
+
+/** \cond fulldocs */
+ /* PRIVATE: Server-side values -- do not try to use these at client-side.
+ * The server will filter out these flags anyway, so you should never see
+ * these flags in sources. */
+
+ PA_SOURCE_SHARE_VOLUME_WITH_MASTER = 0x0400U,
+ /**< This source shares the volume with the master source (used by some filter
+ * sources). */
} pa_source_flags_t;
/** \cond fulldocs */
@@ -805,6 +874,11 @@ typedef enum pa_source_flags {
#define PA_SOURCE_HW_MUTE_CTRL PA_SOURCE_HW_MUTE_CTRL
#define PA_SOURCE_DECIBEL_VOLUME PA_SOURCE_DECIBEL_VOLUME
#define PA_SOURCE_DYNAMIC_LATENCY PA_SOURCE_DYNAMIC_LATENCY
+#define PA_SOURCE_FLAT_VOLUME PA_SOURCE_FLAT_VOLUME
+#define PA_SOURCE_PASSTHROUGH PA_SOURCE_PASSTHROUGH
+#define PA_SOURCE_SYNC_VOLUME PA_SOURCE_SYNC_VOLUME
+#define PA_SOURCE_SHARE_VOLUME_WITH_MASTER PA_SOURCE_SHARE_VOLUME_WITH_MASTER
+
/** \endcond */
/** Source state. \since 0.9.15 */
@@ -865,6 +939,13 @@ typedef void (*pa_free_cb_t)(void *p);
* information, \since 0.9.15 */
#define PA_STREAM_EVENT_REQUEST_UNCORK "request-uncork"
+/** A stream event notifying that the stream is going to be
+ * disconnected because the underlying sink changed and no longer
+ * supports the format that was originally negotiated. Clients need
+ * to connect a new stream to renegotiate a format and continue
+ * playback, \since 1.0 */
+#define PA_STREAM_EVENT_FORMAT_LOST "format-lost"
+
PA_C_DECL_END
#endif
diff --git a/src/pulse/error.c b/src/pulse/error.c
index 93a13fc6..19a759c2 100644
--- a/src/pulse/error.c
+++ b/src/pulse/error.c
@@ -27,14 +27,10 @@
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
-#include <string.h>
-#include <pulse/xmalloc.h>
+#include <pulse/def.h>
#include <pulse/i18n.h>
-#include <pulsecore/core-util.h>
-#include <pulsecore/native-common.h>
-
#include "error.h"
const char*pa_strerror(int error) {
@@ -64,7 +60,9 @@ const char*pa_strerror(int error) {
[PA_ERR_NOEXTENSION] = N_("No such extension"),
[PA_ERR_OBSOLETE] = N_("Obsolete functionality"),
[PA_ERR_NOTIMPLEMENTED] = N_("Missing implementation"),
- [PA_ERR_FORKED] = N_("Client forked")
+ [PA_ERR_FORKED] = N_("Client forked"),
+ [PA_ERR_IO] = N_("Input/Output error"),
+ [PA_ERR_BUSY] = N_("Device or resource busy")
};
pa_init_i18n();
diff --git a/src/pulse/error.h b/src/pulse/error.h
index ea535608..788db845 100644
--- a/src/pulse/error.h
+++ b/src/pulse/error.h
@@ -23,7 +23,6 @@
USA.
***/
-#include <inttypes.h>
#include <pulse/cdecl.h>
#include <pulse/version.h>
diff --git a/src/pulse/ext-device-manager.c b/src/pulse/ext-device-manager.c
new file mode 100644
index 00000000..f2ea63a5
--- /dev/null
+++ b/src/pulse/ext-device-manager.c
@@ -0,0 +1,435 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2008 Lennart Poettering
+ Copyright 2009 Colin Guthrie
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/context.h>
+#include <pulse/xmalloc.h>
+#include <pulse/fork-detect.h>
+#include <pulse/operation.h>
+
+#include <pulsecore/macro.h>
+#include <pulsecore/pstream-util.h>
+
+#include "internal.h"
+#include "ext-device-manager.h"
+
+enum {
+ SUBCOMMAND_TEST,
+ SUBCOMMAND_READ,
+ SUBCOMMAND_RENAME,
+ SUBCOMMAND_DELETE,
+ SUBCOMMAND_ROLE_DEVICE_PRIORITY_ROUTING,
+ SUBCOMMAND_REORDER,
+ SUBCOMMAND_SUBSCRIBE,
+ SUBCOMMAND_EVENT
+};
+
+static void ext_device_manager_test_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
+ pa_operation *o = userdata;
+ uint32_t version = PA_INVALID_INDEX;
+
+ pa_assert(pd);
+ pa_assert(o);
+ pa_assert(PA_REFCNT_VALUE(o) >= 1);
+
+ if (!o->context)
+ goto finish;
+
+ if (command != PA_COMMAND_REPLY) {
+ if (pa_context_handle_error(o->context, command, t, FALSE) < 0)
+ goto finish;
+
+ } else if (pa_tagstruct_getu32(t, &version) < 0 ||
+ !pa_tagstruct_eof(t)) {
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+ goto finish;
+ }
+
+ if (o->callback) {
+ pa_ext_device_manager_test_cb_t cb = (pa_ext_device_manager_test_cb_t) o->callback;
+ cb(o->context, version, o->userdata);
+ }
+
+finish:
+ pa_operation_done(o);
+ pa_operation_unref(o);
+}
+
+pa_operation *pa_ext_device_manager_test(
+ pa_context *c,
+ pa_ext_device_manager_test_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-manager");
+ pa_tagstruct_putu32(t, SUBCOMMAND_TEST);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, ext_device_manager_test_cb, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+static void ext_device_manager_read_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
+ pa_operation *o = userdata;
+ int eol = 1;
+
+ pa_assert(pd);
+ pa_assert(o);
+ pa_assert(PA_REFCNT_VALUE(o) >= 1);
+
+ if (!o->context)
+ goto finish;
+
+ if (command != PA_COMMAND_REPLY) {
+ if (pa_context_handle_error(o->context, command, t, FALSE) < 0)
+ goto finish;
+
+ eol = -1;
+ } else {
+
+ while (!pa_tagstruct_eof(t)) {
+ pa_ext_device_manager_info i;
+
+ memset(&i, 0, sizeof(i));
+
+ if (pa_tagstruct_gets(t, &i.name) < 0 ||
+ pa_tagstruct_gets(t, &i.description) < 0 ||
+ pa_tagstruct_gets(t, &i.icon) < 0 ||
+ pa_tagstruct_getu32(t, &i.index) < 0 ||
+ pa_tagstruct_getu32(t, &i.n_role_priorities) < 0) {
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+ goto finish;
+ }
+
+ if (i.n_role_priorities > 0) {
+ uint32_t j;
+ i.role_priorities = pa_xnew0(pa_ext_device_manager_role_priority_info, i.n_role_priorities+1);
+
+ for (j = 0; j < i.n_role_priorities; j++) {
+
+ if (pa_tagstruct_gets(t, &i.role_priorities[j].role) < 0 ||
+ pa_tagstruct_getu32(t, &i.role_priorities[j].priority) < 0) {
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+ pa_xfree(i.role_priorities);
+ goto finish;
+ }
+ }
+
+ /* Terminate with an extra NULL entry, just to make sure */
+ i.role_priorities[j].role = NULL;
+ i.role_priorities[j].priority = 0;
+ }
+
+ if (o->callback) {
+ pa_ext_device_manager_read_cb_t cb = (pa_ext_device_manager_read_cb_t) o->callback;
+ cb(o->context, &i, 0, o->userdata);
+ }
+
+ pa_xfree(i.role_priorities);
+ }
+ }
+
+ if (o->callback) {
+ pa_ext_device_manager_read_cb_t cb = (pa_ext_device_manager_read_cb_t) o->callback;
+ cb(o->context, NULL, eol, o->userdata);
+ }
+
+finish:
+ pa_operation_done(o);
+ pa_operation_unref(o);
+}
+
+pa_operation *pa_ext_device_manager_read(
+ pa_context *c,
+ pa_ext_device_manager_read_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-manager");
+ pa_tagstruct_putu32(t, SUBCOMMAND_READ);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, ext_device_manager_read_cb, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation *pa_ext_device_manager_set_device_description(
+ pa_context *c,
+ const char* device,
+ const char* description,
+ pa_context_success_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o = NULL;
+ pa_tagstruct *t = NULL;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(device);
+ pa_assert(description);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-manager");
+ pa_tagstruct_putu32(t, SUBCOMMAND_RENAME);
+
+ pa_tagstruct_puts(t, device);
+ pa_tagstruct_puts(t, description);
+
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation *pa_ext_device_manager_delete(
+ pa_context *c,
+ const char *const s[],
+ pa_context_success_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o = NULL;
+ pa_tagstruct *t = NULL;
+ const char *const *k;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(s);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-manager");
+ pa_tagstruct_putu32(t, SUBCOMMAND_DELETE);
+
+ for (k = s; *k; k++) {
+ if (!*k || !**k)
+ goto fail;
+
+ pa_tagstruct_puts(t, *k);
+ }
+
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+
+fail:
+ if (o) {
+ pa_operation_cancel(o);
+ pa_operation_unref(o);
+ }
+
+ if (t)
+ pa_tagstruct_free(t);
+
+ pa_context_set_error(c, PA_ERR_INVALID);
+ return NULL;
+}
+
+pa_operation *pa_ext_device_manager_enable_role_device_priority_routing(
+ pa_context *c,
+ int enable,
+ pa_context_success_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o = NULL;
+ pa_tagstruct *t = NULL;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-manager");
+ pa_tagstruct_putu32(t, SUBCOMMAND_ROLE_DEVICE_PRIORITY_ROUTING);
+ pa_tagstruct_put_boolean(t, !!enable);
+
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation *pa_ext_device_manager_reorder_devices_for_role(
+ pa_context *c,
+ const char* role,
+ const char** devices,
+ pa_context_success_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag, i;
+ pa_operation *o = NULL;
+ pa_tagstruct *t = NULL;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ pa_assert(role);
+ pa_assert(devices);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-manager");
+ pa_tagstruct_putu32(t, SUBCOMMAND_REORDER);
+ pa_tagstruct_puts(t, role);
+
+ i = 0; while (devices[i]) i++;
+ pa_tagstruct_putu32(t, i);
+
+ i = 0;
+ while (devices[i])
+ pa_tagstruct_puts(t, devices[i++]);
+
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation *pa_ext_device_manager_subscribe(
+ pa_context *c,
+ int enable,
+ pa_context_success_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-manager");
+ pa_tagstruct_putu32(t, SUBCOMMAND_SUBSCRIBE);
+ pa_tagstruct_put_boolean(t, enable);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+void pa_ext_device_manager_set_subscribe_cb(
+ pa_context *c,
+ pa_ext_device_manager_subscribe_cb_t cb,
+ void *userdata) {
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ if (pa_detect_fork())
+ return;
+
+ c->ext_device_manager.callback = cb;
+ c->ext_device_manager.userdata = userdata;
+}
+
+void pa_ext_device_manager_command(pa_context *c, uint32_t tag, pa_tagstruct *t) {
+ uint32_t subcommand;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(t);
+
+ if (pa_tagstruct_getu32(t, &subcommand) < 0 ||
+ !pa_tagstruct_eof(t)) {
+
+ pa_context_fail(c, PA_ERR_PROTOCOL);
+ return;
+ }
+
+ if (subcommand != SUBCOMMAND_EVENT) {
+ pa_context_fail(c, PA_ERR_PROTOCOL);
+ return;
+ }
+
+ if (c->ext_device_manager.callback)
+ c->ext_device_manager.callback(c, c->ext_device_manager.userdata);
+}
diff --git a/src/pulse/ext-device-manager.h b/src/pulse/ext-device-manager.h
new file mode 100644
index 00000000..1e41ebd7
--- /dev/null
+++ b/src/pulse/ext-device-manager.h
@@ -0,0 +1,129 @@
+#ifndef foopulseextdevicemanagerhfoo
+#define foopulseextdevicemanagerhfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2008 Lennart Poettering
+ Copyright 2009 Colin Guthrie
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <pulse/cdecl.h>
+#include <pulse/context.h>
+#include <pulse/version.h>
+
+/** \file
+ *
+ * Routines for controlling module-device-manager
+ */
+
+PA_C_DECL_BEGIN
+
+typedef struct pa_ext_device_manager_role_priority_info {
+ const char *role;
+ uint32_t priority;
+} pa_ext_device_manager_role_priority_info;
+
+/** Stores information about one device in the device database that is
+ * maintained by module-device-manager. \since 0.9.21 */
+typedef struct pa_ext_device_manager_info {
+ const char *name; /**< Identifier string of the device. A string like "sink:" or similar followed by the name of the device. */
+ const char *description; /**< The description of the device when it was last seen, if applicable and saved */
+ const char *icon; /**< The icon given to the device */
+ uint32_t index; /**< The device index if it is currently available or PA_INVALID_INDEX */
+ uint32_t n_role_priorities; /**< How many role priorities do we have? */
+ pa_ext_device_manager_role_priority_info *role_priorities; /**< An array of role priority structures or NULL */
+} pa_ext_device_manager_info;
+
+/** Callback prototype for pa_ext_device_manager_test(). \since 0.9.21 */
+typedef void (*pa_ext_device_manager_test_cb_t)(
+ pa_context *c,
+ uint32_t version,
+ void *userdata);
+
+/** Test if this extension module is available in the server. \since 0.9.21 */
+pa_operation *pa_ext_device_manager_test(
+ pa_context *c,
+ pa_ext_device_manager_test_cb_t cb,
+ void *userdata);
+
+/** Callback prototype for pa_ext_device_manager_read(). \since 0.9.21 */
+typedef void (*pa_ext_device_manager_read_cb_t)(
+ pa_context *c,
+ const pa_ext_device_manager_info *info,
+ int eol,
+ void *userdata);
+
+/** Read all entries from the device database. \since 0.9.21 */
+pa_operation *pa_ext_device_manager_read(
+ pa_context *c,
+ pa_ext_device_manager_read_cb_t cb,
+ void *userdata);
+
+/** Sets the description for a device. \since 0.9.21 */
+pa_operation *pa_ext_device_manager_set_device_description(
+ pa_context *c,
+ const char* device,
+ const char* description,
+ pa_context_success_cb_t cb,
+ void *userdata);
+
+/** Delete entries from the device database. \since 0.9.21 */
+pa_operation *pa_ext_device_manager_delete(
+ pa_context *c,
+ const char *const s[],
+ pa_context_success_cb_t cb,
+ void *userdata);
+
+/** Enable the role-based device-priority routing mode. \since 0.9.21 */
+pa_operation *pa_ext_device_manager_enable_role_device_priority_routing(
+ pa_context *c,
+ int enable,
+ pa_context_success_cb_t cb,
+ void *userdata);
+
+/** Prefer a given device in the priority list. \since 0.9.21 */
+pa_operation *pa_ext_device_manager_reorder_devices_for_role(
+ pa_context *c,
+ const char* role,
+ const char** devices,
+ pa_context_success_cb_t cb,
+ void *userdata);
+
+/** Subscribe to changes in the device database. \since 0.9.21 */
+pa_operation *pa_ext_device_manager_subscribe(
+ pa_context *c,
+ int enable,
+ pa_context_success_cb_t cb,
+ void *userdata);
+
+/** Callback prototype for pa_ext_device_manager_set_subscribe_cb(). \since 0.9.21 */
+typedef void (*pa_ext_device_manager_subscribe_cb_t)(
+ pa_context *c,
+ void *userdata);
+
+/** Set the subscription callback that is called when
+ * pa_ext_device_manager_subscribe() was called. \since 0.9.21 */
+void pa_ext_device_manager_set_subscribe_cb(
+ pa_context *c,
+ pa_ext_device_manager_subscribe_cb_t cb,
+ void *userdata);
+
+PA_C_DECL_END
+
+#endif
diff --git a/src/pulse/ext-device-restore.c b/src/pulse/ext-device-restore.c
new file mode 100644
index 00000000..938d4664
--- /dev/null
+++ b/src/pulse/ext-device-restore.c
@@ -0,0 +1,346 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2008 Lennart Poettering
+ Copyright 2011 Colin Guthrie
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/context.h>
+#include <pulse/gccmacro.h>
+#include <pulse/xmalloc.h>
+#include <pulse/fork-detect.h>
+#include <pulse/operation.h>
+#include <pulse/format.h>
+
+#include <pulsecore/macro.h>
+#include <pulsecore/pstream-util.h>
+
+#include "internal.h"
+#include "ext-device-restore.h"
+
+/* Protocol extention commands */
+enum {
+ SUBCOMMAND_TEST,
+ SUBCOMMAND_SUBSCRIBE,
+ SUBCOMMAND_EVENT,
+ SUBCOMMAND_READ_SINK_FORMATS_ALL,
+ SUBCOMMAND_READ_SINK_FORMATS,
+ SUBCOMMAND_SAVE_SINK_FORMATS
+};
+
+static void ext_device_restore_test_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
+ pa_operation *o = userdata;
+ uint32_t version = PA_INVALID_INDEX;
+
+ pa_assert(pd);
+ pa_assert(o);
+ pa_assert(PA_REFCNT_VALUE(o) >= 1);
+
+ if (!o->context)
+ goto finish;
+
+ if (command != PA_COMMAND_REPLY) {
+ if (pa_context_handle_error(o->context, command, t, FALSE) < 0)
+ goto finish;
+
+ } else if (pa_tagstruct_getu32(t, &version) < 0 ||
+ !pa_tagstruct_eof(t)) {
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+ goto finish;
+ }
+
+ if (o->callback) {
+ pa_ext_device_restore_test_cb_t cb = (pa_ext_device_restore_test_cb_t) o->callback;
+ cb(o->context, version, o->userdata);
+ }
+
+finish:
+ pa_operation_done(o);
+ pa_operation_unref(o);
+}
+
+pa_operation *pa_ext_device_restore_test(
+ pa_context *c,
+ pa_ext_device_restore_test_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-restore");
+ pa_tagstruct_putu32(t, SUBCOMMAND_TEST);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, ext_device_restore_test_cb, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation *pa_ext_device_restore_subscribe(
+ pa_context *c,
+ int enable,
+ pa_context_success_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-restore");
+ pa_tagstruct_putu32(t, SUBCOMMAND_SUBSCRIBE);
+ pa_tagstruct_put_boolean(t, enable);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+void pa_ext_device_restore_set_subscribe_cb(
+ pa_context *c,
+ pa_ext_device_restore_subscribe_cb_t cb,
+ void *userdata) {
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ if (pa_detect_fork())
+ return;
+
+ c->ext_device_restore.callback = cb;
+ c->ext_device_restore.userdata = userdata;
+}
+
+static void ext_device_restore_read_device_formats_cb(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
+ pa_operation *o = userdata;
+ int eol = 1;
+
+ pa_assert(pd);
+ pa_assert(o);
+ pa_assert(PA_REFCNT_VALUE(o) >= 1);
+
+ if (!o->context)
+ goto finish;
+
+ if (command != PA_COMMAND_REPLY) {
+ if (pa_context_handle_error(o->context, command, t, FALSE) < 0)
+ goto finish;
+
+ eol = -1;
+ } else {
+ uint8_t j;
+
+ while (!pa_tagstruct_eof(t)) {
+ pa_ext_device_restore_info i;
+ pa_zero(i);
+
+ if (pa_tagstruct_getu32(t, &i.index) < 0 ||
+ pa_tagstruct_getu8(t, &i.n_formats) < 0) {
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+ goto finish;
+ }
+
+ if (i.n_formats > 0) {
+ i.formats = pa_xnew0(pa_format_info*, i.n_formats);
+
+ for (j = 0; j < i.n_formats; j++) {
+
+ pa_format_info *f = i.formats[j] = pa_format_info_new();
+ if (pa_tagstruct_get_format_info(t, f) < 0) {
+ uint8_t k;
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+ for (k = 0; k <= j; k++)
+ pa_format_info_free(i.formats[k]);
+ pa_xfree(i.formats);
+ goto finish;
+ }
+ }
+ }
+
+ if (o->callback) {
+ pa_ext_device_restore_read_device_formats_cb_t cb = (pa_ext_device_restore_read_device_formats_cb_t) o->callback;
+ cb(o->context, &i, 0, o->userdata);
+ }
+
+ for (j = 0; j < i.n_formats; j++)
+ pa_format_info_free(i.formats[j]);
+ pa_xfree(i.formats);
+ }
+ }
+
+ if (o->callback) {
+ pa_ext_device_restore_read_device_formats_cb_t cb = (pa_ext_device_restore_read_device_formats_cb_t) o->callback;
+ cb(o->context, NULL, eol, o->userdata);
+ }
+
+finish:
+ pa_operation_done(o);
+ pa_operation_unref(o);
+}
+
+pa_operation *pa_ext_device_restore_read_sink_formats_all(
+ pa_context *c,
+ pa_ext_device_restore_read_device_formats_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-restore");
+ pa_tagstruct_putu32(t, SUBCOMMAND_READ_SINK_FORMATS_ALL);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, ext_device_restore_read_device_formats_cb, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation *pa_ext_device_restore_read_sink_formats(
+ pa_context *c,
+ uint32_t idx,
+ pa_ext_device_restore_read_device_formats_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(idx != PA_INVALID_INDEX);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-restore");
+ pa_tagstruct_putu32(t, SUBCOMMAND_READ_SINK_FORMATS);
+ pa_tagstruct_putu32(t, idx);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, ext_device_restore_read_device_formats_cb, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation *pa_ext_device_restore_save_sink_formats(
+ pa_context *c,
+ uint32_t idx,
+ uint8_t n_formats,
+ pa_format_info **formats,
+ pa_context_success_cb_t cb,
+ void *userdata) {
+
+ uint32_t tag;
+ pa_operation *o;
+ pa_tagstruct *t;
+ uint8_t j;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(idx != PA_INVALID_INDEX);
+ pa_assert(n_formats > 0);
+ pa_assert(formats && *formats);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 14, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_EXTENSION, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, "module-device-restore");
+ pa_tagstruct_putu32(t, SUBCOMMAND_SAVE_SINK_FORMATS);
+
+ pa_tagstruct_putu32(t, idx);
+ pa_tagstruct_putu8(t, n_formats);
+ for (j = 0; j < n_formats; j++)
+ pa_tagstruct_put_format_info(t, formats[j]);
+
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+/* Command function defined in internal.h */
+void pa_ext_device_restore_command(pa_context *c, uint32_t tag, pa_tagstruct *t) {
+ uint32_t subcommand;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(t);
+
+ if (pa_tagstruct_getu32(t, &subcommand) < 0 ||
+ !pa_tagstruct_eof(t)) {
+
+ pa_context_fail(c, PA_ERR_PROTOCOL);
+ return;
+ }
+
+ if (subcommand != SUBCOMMAND_EVENT) {
+ pa_context_fail(c, PA_ERR_PROTOCOL);
+ return;
+ }
+
+ if (c->ext_device_restore.callback)
+ c->ext_device_restore.callback(c, c->ext_device_restore.userdata);
+}
diff --git a/src/pulse/ext-device-restore.h b/src/pulse/ext-device-restore.h
new file mode 100644
index 00000000..eb0619cd
--- /dev/null
+++ b/src/pulse/ext-device-restore.h
@@ -0,0 +1,106 @@
+#ifndef foopulseextdevicerestorehfoo
+#define foopulseextdevicerestorehfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2008 Lennart Poettering
+ Copyright 2011 Colin Guthrie
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <pulse/context.h>
+#include <pulse/version.h>
+
+/** \file
+ *
+ * Routines for controlling module-device-restore
+ */
+
+PA_C_DECL_BEGIN
+
+/** Stores information about one device in the device database that is
+ * maintained by module-device-manager. \since 1.0 */
+typedef struct pa_ext_device_restore_info {
+ uint32_t index; /**< The device index */
+ uint8_t n_formats; /**< How many formats do we have? */
+ pa_format_info **formats; /**< An array of formats (may be NULL if n_formats == 0) */
+} pa_ext_device_restore_info;
+
+/** Callback prototype for pa_ext_device_restore_test(). \since 1.0 */
+typedef void (*pa_ext_device_restore_test_cb_t)(
+ pa_context *c,
+ uint32_t version,
+ void *userdata);
+
+/** Test if this extension module is available in the server. \since 1.0 */
+pa_operation *pa_ext_device_restore_test(
+ pa_context *c,
+ pa_ext_device_restore_test_cb_t cb,
+ void *userdata);
+
+/** Subscribe to changes in the device database. \since 1.0 */
+pa_operation *pa_ext_device_restore_subscribe(
+ pa_context *c,
+ int enable,
+ pa_context_success_cb_t cb,
+ void *userdata);
+
+/** Callback prototype for pa_ext_device_restore_set_subscribe_cb(). \since 1.0 */
+typedef void (*pa_ext_device_restore_subscribe_cb_t)(
+ pa_context *c,
+ void *userdata);
+
+/** Set the subscription callback that is called when
+ * pa_ext_device_restore_subscribe() was called. \since 1.0 */
+void pa_ext_device_restore_set_subscribe_cb(
+ pa_context *c,
+ pa_ext_device_restore_subscribe_cb_t cb,
+ void *userdata);
+
+/** Callback prototype for pa_ext_device_restore_read_sink_formats(). \since 1.0 */
+typedef void (*pa_ext_device_restore_read_device_formats_cb_t)(
+ pa_context *c,
+ const pa_ext_device_restore_info *info,
+ int eol,
+ void *userdata);
+
+/** Read the formats for all present sinks from the device database. \since 1.0 */
+pa_operation *pa_ext_device_restore_read_sink_formats_all(
+ pa_context *c,
+ pa_ext_device_restore_read_device_formats_cb_t cb,
+ void *userdata);
+
+/** Read an entry from the device database. \since 1.0 */
+pa_operation *pa_ext_device_restore_read_sink_formats(
+ pa_context *c,
+ uint32_t idx,
+ pa_ext_device_restore_read_device_formats_cb_t cb,
+ void *userdata);
+
+/** Read an entry from the device database. \since 1.0 */
+pa_operation *pa_ext_device_restore_save_sink_formats(
+ pa_context *c,
+ uint32_t idx,
+ uint8_t n_formats,
+ pa_format_info **formats,
+ pa_context_success_cb_t cb,
+ void *userdata);
+
+PA_C_DECL_END
+
+#endif
diff --git a/src/pulse/ext-stream-restore.c b/src/pulse/ext-stream-restore.c
index 63c911f8..1f72c1c4 100644
--- a/src/pulse/ext-stream-restore.c
+++ b/src/pulse/ext-stream-restore.c
@@ -24,15 +24,13 @@
#endif
#include <pulse/context.h>
-#include <pulse/gccmacro.h>
+#include <pulse/fork-detect.h>
+#include <pulse/operation.h>
#include <pulsecore/macro.h>
#include <pulsecore/pstream-util.h>
#include "internal.h"
-#include "operation.h"
-#include "fork-detect.h"
-
#include "ext-stream-restore.h"
enum {
@@ -239,13 +237,10 @@ pa_operation *pa_ext_stream_restore_write(
return o;
fail:
- if (o) {
- pa_operation_cancel(o);
- pa_operation_unref(o);
- }
+ pa_operation_cancel(o);
+ pa_operation_unref(o);
- if (t)
- pa_tagstruct_free(t);
+ pa_tagstruct_free(t);
pa_context_set_error(c, PA_ERR_INVALID);
return NULL;
@@ -290,13 +285,10 @@ pa_operation *pa_ext_stream_restore_delete(
return o;
fail:
- if (o) {
- pa_operation_cancel(o);
- pa_operation_unref(o);
- }
+ pa_operation_cancel(o);
+ pa_operation_unref(o);
- if (t)
- pa_tagstruct_free(t);
+ pa_tagstruct_free(t);
pa_context_set_error(c, PA_ERR_INVALID);
return NULL;
diff --git a/src/pulse/ext-stream-restore.h b/src/pulse/ext-stream-restore.h
index 0b5d8eb6..acb16a83 100644
--- a/src/pulse/ext-stream-restore.h
+++ b/src/pulse/ext-stream-restore.h
@@ -22,8 +22,11 @@
USA.
***/
+#include <pulse/cdecl.h>
#include <pulse/context.h>
#include <pulse/version.h>
+#include <pulse/volume.h>
+#include <pulse/channelmap.h>
/** \file
*
diff --git a/src/pulse/format.c b/src/pulse/format.c
new file mode 100644
index 00000000..b256d72f
--- /dev/null
+++ b/src/pulse/format.c
@@ -0,0 +1,461 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2011 Intel Corporation
+ Copyright 2011 Collabora Multimedia
+ Copyright 2011 Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <json.h>
+
+#include <pulse/internal.h>
+#include <pulse/xmalloc.h>
+#include <pulse/i18n.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/macro.h>
+
+#include "format.h"
+
+#define PA_JSON_MIN_KEY "min"
+#define PA_JSON_MAX_KEY "max"
+
+static int pa_format_info_prop_compatible(const char *one, const char *two);
+
+const char *pa_encoding_to_string(pa_encoding_t e) {
+ static const char* const table[]= {
+ [PA_ENCODING_PCM] = "pcm",
+ [PA_ENCODING_AC3_IEC61937] = "ac3-iec61937",
+ [PA_ENCODING_EAC3_IEC61937] = "eac3-iec61937",
+ [PA_ENCODING_MPEG_IEC61937] = "mpeg-iec61937",
+ [PA_ENCODING_DTS_IEC61937] = "dts-iec61937",
+ [PA_ENCODING_ANY] = "any",
+ };
+
+ if (e < 0 || e >= PA_ENCODING_MAX)
+ return NULL;
+
+ return table[e];
+}
+
+pa_format_info* pa_format_info_new(void) {
+ pa_format_info *f = pa_xnew(pa_format_info, 1);
+
+ f->encoding = PA_ENCODING_INVALID;
+ f->plist = pa_proplist_new();
+
+ return f;
+}
+
+pa_format_info* pa_format_info_copy(const pa_format_info *src) {
+ pa_format_info *dest;
+
+ pa_assert(src);
+
+ dest = pa_xnew(pa_format_info, 1);
+
+ dest->encoding = src->encoding;
+
+ if (src->plist)
+ dest->plist = pa_proplist_copy(src->plist);
+ else
+ dest->plist = NULL;
+
+ return dest;
+}
+
+void pa_format_info_free(pa_format_info *f) {
+ pa_assert(f);
+
+ pa_proplist_free(f->plist);
+ pa_xfree(f);
+}
+
+void pa_format_info_free2(pa_format_info *f, void *userdata) {
+ pa_format_info_free(f);
+}
+
+int pa_format_info_valid(const pa_format_info *f) {
+ return (f->encoding >= 0 && f->encoding < PA_ENCODING_MAX && f->plist != NULL);
+}
+
+int pa_format_info_is_pcm(const pa_format_info *f) {
+ return f->encoding == PA_ENCODING_PCM;
+}
+
+char *pa_format_info_snprint(char *s, size_t l, const pa_format_info *f) {
+ char *tmp;
+
+ pa_assert(s);
+ pa_assert(l > 0);
+ pa_assert(f);
+
+ pa_init_i18n();
+
+ if (!pa_format_info_valid(f))
+ pa_snprintf(s, l, _("(invalid)"));
+ else {
+ tmp = pa_proplist_to_string_sep(f->plist, ", ");
+ pa_snprintf(s, l, _("%s, %s"), pa_encoding_to_string(f->encoding), tmp[0] ? tmp : _("(no properties)"));
+ pa_xfree(tmp);
+ }
+
+ return s;
+}
+
+int pa_format_info_is_compatible(pa_format_info *first, pa_format_info *second) {
+ const char *key;
+ void *state = NULL;
+
+ pa_assert(first);
+ pa_assert(second);
+
+ if (first->encoding != second->encoding)
+ return FALSE;
+
+ while ((key = pa_proplist_iterate(first->plist, &state))) {
+ const char *value_one, *value_two;
+
+ value_one = pa_proplist_gets(first->plist, key);
+ value_two = pa_proplist_gets(second->plist, key);
+
+ if (!value_two || !pa_format_info_prop_compatible(value_one, value_two))
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+pa_format_info* pa_format_info_from_sample_spec(pa_sample_spec *ss, pa_channel_map *map) {
+ char cm[PA_CHANNEL_MAP_SNPRINT_MAX];
+ pa_format_info *f;
+
+ pa_assert(ss && pa_sample_spec_valid(ss));
+ pa_assert(!map || pa_channel_map_valid(map));
+
+ f = pa_format_info_new();
+ f->encoding = PA_ENCODING_PCM;
+
+ pa_format_info_set_sample_format(f, ss->format);
+ pa_format_info_set_rate(f, ss->rate);
+ pa_format_info_set_channels(f, ss->channels);
+
+ if (map) {
+ pa_channel_map_snprint(cm, sizeof(cm), map);
+ pa_format_info_set_prop_string(f, PA_PROP_FORMAT_CHANNEL_MAP, cm);
+ }
+
+ return f;
+}
+
+/* For PCM streams */
+pa_bool_t pa_format_info_to_sample_spec(pa_format_info *f, pa_sample_spec *ss, pa_channel_map *map) {
+ char *sf = NULL, *m = NULL;
+ int rate, channels;
+ pa_bool_t ret = FALSE;
+
+ pa_assert(f);
+ pa_assert(ss);
+ pa_return_val_if_fail(f->encoding == PA_ENCODING_PCM, FALSE);
+
+ if (!pa_format_info_get_prop_string(f, PA_PROP_FORMAT_SAMPLE_FORMAT, &sf))
+ goto out;
+ if (!pa_format_info_get_prop_int(f, PA_PROP_FORMAT_RATE, &rate))
+ goto out;
+ if (!pa_format_info_get_prop_int(f, PA_PROP_FORMAT_CHANNELS, &channels))
+ goto out;
+
+ if ((ss->format = pa_parse_sample_format(sf)) == PA_SAMPLE_INVALID)
+ goto out;
+
+ ss->rate = (uint32_t) rate;
+ ss->channels = (uint8_t) channels;
+
+ if (map) {
+ pa_channel_map_init(map);
+
+ if (pa_format_info_get_prop_string(f, PA_PROP_FORMAT_CHANNEL_MAP, &m))
+ if (pa_channel_map_parse(map, m) == NULL)
+ goto out;
+ }
+
+ ret = TRUE;
+
+out:
+ if (sf)
+ pa_xfree(sf);
+ if (m)
+ pa_xfree(m);
+
+ return ret;
+}
+
+/* For compressed streams */
+pa_bool_t pa_format_info_to_sample_spec_fake(pa_format_info *f, pa_sample_spec *ss) {
+ int rate;
+
+ pa_assert(f);
+ pa_assert(ss);
+ pa_return_val_if_fail(f->encoding != PA_ENCODING_PCM, FALSE);
+
+ ss->format = PA_SAMPLE_S16LE;
+ ss->channels = 2;
+
+ pa_return_val_if_fail(pa_format_info_get_prop_int(f, PA_PROP_FORMAT_RATE, &rate), FALSE);
+ ss->rate = (uint32_t) rate;
+
+ if (f->encoding == PA_ENCODING_EAC3_IEC61937)
+ ss->rate *= 4;
+
+ return TRUE;
+}
+
+void pa_format_info_set_sample_format(pa_format_info *f, pa_sample_format_t sf) {
+ pa_format_info_set_prop_string(f, PA_PROP_FORMAT_SAMPLE_FORMAT, pa_sample_format_to_string(sf));
+}
+
+void pa_format_info_set_rate(pa_format_info *f, int rate) {
+ pa_format_info_set_prop_int(f, PA_PROP_FORMAT_RATE, rate);
+}
+
+void pa_format_info_set_channels(pa_format_info *f, int channels) {
+ pa_format_info_set_prop_int(f, PA_PROP_FORMAT_CHANNELS, channels);
+}
+
+void pa_format_info_set_channel_map(pa_format_info *f, const pa_channel_map *map) {
+ char map_str[PA_CHANNEL_MAP_SNPRINT_MAX];
+
+ pa_channel_map_snprint(map_str, sizeof(map_str), map);
+
+ pa_format_info_set_prop_string(f, PA_PROP_FORMAT_CHANNEL_MAP, map_str);
+}
+
+pa_bool_t pa_format_info_get_prop_int(pa_format_info *f, const char *key, int *v) {
+ const char *str;
+ json_object *o;
+
+ pa_assert(f);
+ pa_assert(key);
+ pa_assert(v);
+
+ pa_return_val_if_fail(str = pa_proplist_gets(f->plist, key), FALSE);
+ o = json_tokener_parse(str);
+ pa_return_val_if_fail(!is_error(o), FALSE);
+ if (json_object_get_type(o) != json_type_int) {
+ json_object_put(o);
+ return FALSE;
+ }
+
+ *v = json_object_get_int(o);
+ json_object_put(o);
+
+ return TRUE;
+}
+
+pa_bool_t pa_format_info_get_prop_string(pa_format_info *f, const char *key, char **v) {
+ const char *str = NULL;
+ json_object *o;
+
+ pa_assert(f);
+ pa_assert(key);
+ pa_assert(v);
+
+ str = pa_proplist_gets(f->plist, key), FALSE;
+ if (!str)
+ return FALSE;
+
+ o = json_tokener_parse(str);
+ pa_return_val_if_fail(!is_error(o), FALSE);
+ if (json_object_get_type(o) != json_type_string) {
+ json_object_put(o);
+ return FALSE;
+ }
+
+ *v = pa_xstrdup(json_object_get_string(o));
+ json_object_put(o);
+
+ return TRUE;
+}
+
+void pa_format_info_set_prop_int(pa_format_info *f, const char *key, int value) {
+ json_object *o;
+
+ pa_assert(f);
+ pa_assert(key);
+
+ o = json_object_new_int(value);
+
+ pa_proplist_sets(f->plist, key, json_object_to_json_string(o));
+
+ json_object_put(o);
+}
+
+void pa_format_info_set_prop_int_array(pa_format_info *f, const char *key, const int *values, int n_values) {
+ json_object *o;
+ int i;
+
+ pa_assert(f);
+ pa_assert(key);
+
+ o = json_object_new_array();
+
+ for (i = 0; i < n_values; i++)
+ json_object_array_add(o, json_object_new_int(values[i]));
+
+ pa_proplist_sets(f->plist, key, json_object_to_json_string(o));
+
+ json_object_put(o);
+}
+
+void pa_format_info_set_prop_int_range(pa_format_info *f, const char *key, int min, int max) {
+ json_object *o;
+
+ pa_assert(f);
+ pa_assert(key);
+
+ o = json_object_new_object();
+
+ json_object_object_add(o, PA_JSON_MIN_KEY, json_object_new_int(min));
+ json_object_object_add(o, PA_JSON_MAX_KEY, json_object_new_int(max));
+
+ pa_proplist_sets(f->plist, key, json_object_to_json_string(o));
+
+ json_object_put(o);
+}
+
+void pa_format_info_set_prop_string(pa_format_info *f, const char *key, const char *value) {
+ json_object *o;
+
+ pa_assert(f);
+ pa_assert(key);
+
+ o = json_object_new_string(value);
+
+ pa_proplist_sets(f->plist, key, json_object_to_json_string(o));
+
+ json_object_put(o);
+}
+
+void pa_format_info_set_prop_string_array(pa_format_info *f, const char *key, const char **values, int n_values) {
+ json_object *o;
+ int i;
+
+ pa_assert(f);
+ pa_assert(key);
+
+ o = json_object_new_array();
+
+ for (i = 0; i < n_values; i++)
+ json_object_array_add(o, json_object_new_string(values[i]));
+
+ pa_proplist_sets(f->plist, key, json_object_to_json_string(o));
+
+ json_object_put(o);
+}
+
+static pa_bool_t pa_json_is_fixed_type(json_object *o)
+{
+ switch(json_object_get_type(o)) {
+ case json_type_object:
+ case json_type_array:
+ return FALSE;
+
+ default:
+ return TRUE;
+ }
+}
+
+static int pa_json_value_equal(json_object *o1, json_object *o2) {
+ return (json_object_get_type(o1) == json_object_get_type(o2)) &&
+ pa_streq(json_object_to_json_string(o1), json_object_to_json_string(o2));
+}
+
+static int pa_format_info_prop_compatible(const char *one, const char *two) {
+ json_object *o1 = NULL, *o2 = NULL;
+ int i, ret = 0;
+
+ o1 = json_tokener_parse(one);
+ if (is_error(o1))
+ goto out;
+
+ o2 = json_tokener_parse(two);
+ if (is_error(o2))
+ goto out;
+
+ /* We don't deal with both values being non-fixed - just because there is no immediate need (FIXME) */
+ pa_return_val_if_fail(pa_json_is_fixed_type(o1) || pa_json_is_fixed_type(o2), FALSE);
+
+ if (pa_json_is_fixed_type(o1) && pa_json_is_fixed_type(o2)) {
+ ret = pa_json_value_equal(o1, o2);
+ goto out;
+ }
+
+ if (pa_json_is_fixed_type(o1)) {
+ json_object *tmp = o2;
+ o2 = o1;
+ o1 = tmp;
+ }
+
+ /* o2 is now a fixed type, and o1 is not */
+
+ if (json_object_get_type(o1) == json_type_array) {
+ for (i = 0; i < json_object_array_length(o1); i++) {
+ if (pa_json_value_equal(json_object_array_get_idx(o1, i), o2)) {
+ ret = 1;
+ break;
+ }
+ }
+ } else if (json_object_get_type(o1) == json_type_object) {
+ /* o1 should be a range type */
+ int min, max, v;
+ json_object *o_min = NULL, *o_max = NULL;
+
+ if (json_object_get_type(o2) != json_type_int) {
+ /* We don't support non-integer ranges */
+ goto out;
+ }
+
+ o_min = json_object_object_get(o1, PA_JSON_MIN_KEY);
+ if (!o_min || json_object_get_type(o_min) != json_type_int)
+ goto out;
+
+ o_max = json_object_object_get(o1, PA_JSON_MAX_KEY);
+ if (!o_max || json_object_get_type(o_max) != json_type_int)
+ goto out;
+
+ v = json_object_get_int(o2);
+ min = json_object_get_int(o_min);
+ max = json_object_get_int(o_max);
+
+ ret = v >= min && v <= max;
+ } else {
+ pa_log_warn("Got a format type that we don't support");
+ }
+
+out:
+ if (o1)
+ json_object_put(o1);
+ if (o2)
+ json_object_put(o2);
+
+ return ret;
+}
diff --git a/src/pulse/format.h b/src/pulse/format.h
new file mode 100644
index 00000000..821149ca
--- /dev/null
+++ b/src/pulse/format.h
@@ -0,0 +1,130 @@
+#ifndef fooformathfoo
+#define fooformathfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2011 Intel Corporation
+ Copyright 2011 Collabora Multimedia
+ Copyright 2011 Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <pulse/cdecl.h>
+#include <pulse/gccmacro.h>
+#include <pulse/proplist.h>
+#include <pulse/sample.h>
+#include <pulse/channelmap.h>
+
+PA_C_DECL_BEGIN
+
+/**< Represents the type of encoding used in a stream or accepted by a sink. \since 1.0 */
+typedef enum pa_encoding {
+ PA_ENCODING_ANY,
+ /**< Any encoding format, PCM or compressed */
+
+ PA_ENCODING_PCM,
+ /**< Any PCM format */
+
+ PA_ENCODING_AC3_IEC61937,
+ /**< AC3 data encapsulated in IEC 61937 header/padding */
+
+ PA_ENCODING_EAC3_IEC61937,
+ /**< EAC3 data encapsulated in IEC 61937 header/padding */
+
+ PA_ENCODING_MPEG_IEC61937,
+ /**< MPEG-1 or MPEG-2 (Part 3, not AAC) data encapsulated in IEC 61937 header/padding */
+
+ PA_ENCODING_DTS_IEC61937,
+ /**< DTS data encapsulated in IEC 61937 header/padding */
+
+ PA_ENCODING_MAX,
+ /**< Valid encoding types must be less than this value */
+
+ PA_ENCODING_INVALID = -1,
+ /**< Represents an invalid encoding */
+} pa_encoding_t;
+
+/** Returns a printable string representing the given encoding type. \since 1.0 */
+const char *pa_encoding_to_string(pa_encoding_t e) PA_GCC_CONST;
+
+/**< Represents the format of data provided in a stream or processed by a sink. \since 1.0 */
+typedef struct pa_format_info {
+ pa_encoding_t encoding;
+ /**< The encoding used for the format */
+
+ pa_proplist *plist;
+ /**< Additional encoding-specific properties such as sample rate, bitrate, etc. */
+} pa_format_info;
+
+/**< Allocates a new \a pa_format_info structure. Clients must initialise at least the encoding field themselves. */
+pa_format_info* pa_format_info_new(void);
+
+/**< Returns a new \a pa_format_info struct and representing the same format as \a src */
+pa_format_info* pa_format_info_copy(const pa_format_info *src);
+
+/**< Frees a \a pa_format_info structure */
+void pa_format_info_free(pa_format_info *f);
+
+/** Returns non-zero when the format info structure is valid */
+int pa_format_info_valid(const pa_format_info *f);
+
+/** Returns non-zero when the format info structure represents a PCM (i.e. uncompressed data) format */
+int pa_format_info_is_pcm(const pa_format_info *f);
+
+/** Returns non-zero if the format represented \a first is a subset of
+ * the format represented by \second. This means that \a second must
+ * have all the fields that \a first does, but the reverse need not
+ * be true. This is typically expected to be used to check if a
+ * stream's format is compatible with a given sink. In such a case,
+ * \a first would be the sink's format and \a second would be the
+ * stream's.*/
+int pa_format_info_is_compatible(pa_format_info *first, pa_format_info *second);
+
+/** Maximum required string length for
+ * pa_format_info_snprint(). Please note that this value can change
+ * with any release without warning and without being considered API
+ * or ABI breakage. You should not use this definition anywhere where
+ * it might become part of an ABI. \since 1.0 */
+#define PA_FORMAT_INFO_SNPRINT_MAX 256
+
+/** Return a human-readable string representing the given format. \since 1.0 */
+char *pa_format_info_snprint(char *s, size_t l, const pa_format_info *f);
+
+/** Sets an integer property on the given format info */
+void pa_format_info_set_prop_int(pa_format_info *f, const char *key, int value);
+/** Sets a property with a list of integer values on the given format info */
+void pa_format_info_set_prop_int_array(pa_format_info *f, const char *key, const int *values, int n_values);
+/** Sets a property which can have any value in a given integer range on the given format info */
+void pa_format_info_set_prop_int_range(pa_format_info *f, const char *key, int min, int max);
+/** Sets a string property on the given format info */
+void pa_format_info_set_prop_string(pa_format_info *f, const char *key, const char *value);
+/** Sets a property with a list of string values on the given format info */
+void pa_format_info_set_prop_string_array(pa_format_info *f, const char *key, const char **values, int n_values);
+
+/** Convenience method to set the sample format as a property on the given format */
+void pa_format_info_set_sample_format(pa_format_info *f, pa_sample_format_t sf);
+/** Convenience method to set the sampling rate as a property on the given format */
+void pa_format_info_set_rate(pa_format_info *f, int rate);
+/** Convenience method to set the number of channels as a property on the given format */
+void pa_format_info_set_channels(pa_format_info *f, int channels);
+/** Convenience method to set the channel map as a property on the given format */
+void pa_format_info_set_channel_map(pa_format_info *f, const pa_channel_map *map);
+
+PA_C_DECL_END
+
+#endif
diff --git a/src/pulse/gccmacro.h b/src/pulse/gccmacro.h
index e85ecb66..5749a6bb 100644
--- a/src/pulse/gccmacro.h
+++ b/src/pulse/gccmacro.h
@@ -49,7 +49,7 @@
#ifdef __GNUC__
#define PA_GCC_UNUSED __attribute__ ((unused))
#else
-/** Macro for not used parameter */
+/** Macro for not used function, variable or parameter */
#define PA_GCC_UNUSED
#endif
@@ -118,7 +118,7 @@
#endif
#ifndef PA_GCC_WEAKREF
-#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ > 1)) || (__GNUC__ > 4))
+#if defined(__GNUC__) && defined(__ELF__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ > 1)) || (__GNUC__ > 4))
/** Macro for usgae of GCC's weakref attribute */
#define PA_GCC_WEAKREF(x) __attribute__((weakref(#x)));
#endif
diff --git a/src/pulse/glib-mainloop.c b/src/pulse/glib-mainloop.c
index 6afb7a2d..35c9c6a2 100644
--- a/src/pulse/glib-mainloop.c
+++ b/src/pulse/glib-mainloop.c
@@ -26,7 +26,6 @@
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
-#include <pulsecore/idxset.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/llist.h>
@@ -34,7 +33,7 @@
#include <glib.h>
#include "glib-mainloop.h"
-struct pa_io_event {
+struct pa_io_event {
pa_glib_mainloop *mainloop;
int dead;
@@ -336,7 +335,7 @@ static void glib_time_restart(pa_time_event*e, const struct timeval *tv) {
e->mainloop->cached_next_time_event = e;
} else if (e->mainloop->cached_next_time_event == e)
e->mainloop->cached_next_time_event = NULL;
- }
+}
static void glib_time_free(pa_time_event *e) {
g_assert(e);
diff --git a/src/pulse/glib-mainloop.h b/src/pulse/glib-mainloop.h
index 189513a8..805d7460 100644
--- a/src/pulse/glib-mainloop.h
+++ b/src/pulse/glib-mainloop.h
@@ -41,7 +41,10 @@
*/
/** \file
- * GLIB main loop support */
+ * GLIB main loop support
+ *
+ * See also \subpage glib-mainloop
+ */
PA_C_DECL_BEGIN
@@ -56,7 +59,9 @@ pa_glib_mainloop *pa_glib_mainloop_new(GMainContext *c);
/** Free the GLIB main loop object */
void pa_glib_mainloop_free(pa_glib_mainloop* g);
-/** Return the abstract main loop API vtable for the GLIB main loop object */
+/** Return the abstract main loop API vtable for the GLIB main loop
+ object. No need to free the API as it is owned by the loop
+ and is destroyed when the loop is freed. */
pa_mainloop_api* pa_glib_mainloop_get_api(pa_glib_mainloop *g);
PA_C_DECL_END
diff --git a/src/pulse/i18n.h b/src/pulse/i18n.h
index f91c0bf9..fac3c7b2 100644
--- a/src/pulse/i18n.h
+++ b/src/pulse/i18n.h
@@ -23,7 +23,6 @@
***/
#include <pulse/cdecl.h>
-#include <pulse/gccmacro.h>
#include <pulse/version.h>
PA_C_DECL_BEGIN
diff --git a/src/pulse/internal.h b/src/pulse/internal.h
index 28a989b3..92379094 100644
--- a/src/pulse/internal.h
+++ b/src/pulse/internal.h
@@ -28,12 +28,13 @@
#include <pulse/stream.h>
#include <pulse/operation.h>
#include <pulse/subscribe.h>
+#include <pulse/ext-device-manager.h>
+#include <pulse/ext-device-restore.h>
#include <pulse/ext-stream-restore.h>
#include <pulsecore/socket-client.h>
#include <pulsecore/pstream.h>
#include <pulsecore/pdispatch.h>
-#include <pulsecore/dynarray.h>
#include <pulsecore/llist.h>
#include <pulsecore/native-common.h>
#include <pulsecore/strlist.h>
@@ -65,7 +66,7 @@ struct pa_context {
pa_pstream *pstream;
pa_pdispatch *pdispatch;
- pa_dynarray *record_streams, *playback_streams;
+ pa_hashmap *record_streams, *playback_streams;
PA_LLIST_HEAD(pa_stream, streams);
PA_LLIST_HEAD(pa_operation, operations);
@@ -89,6 +90,8 @@ struct pa_context {
pa_bool_t server_specified:1;
pa_bool_t no_fail:1;
pa_bool_t do_autospawn:1;
+ pa_bool_t use_rtclock:1;
+ pa_bool_t filter_added:1;
pa_spawn_api spawn_api;
pa_strlist *server_list;
@@ -101,6 +104,14 @@ struct pa_context {
/* Extension specific data */
struct {
+ pa_ext_device_manager_subscribe_cb_t callback;
+ void *userdata;
+ } ext_device_manager;
+ struct {
+ pa_ext_device_restore_subscribe_cb_t callback;
+ void *userdata;
+ } ext_device_restore;
+ struct {
pa_ext_stream_restore_subscribe_cb_t callback;
void *userdata;
} ext_stream_restore;
@@ -116,6 +127,8 @@ typedef struct pa_index_correction {
pa_bool_t corrupt:1;
} pa_index_correction;
+#define PA_MAX_FORMATS (PA_ENCODING_MAX)
+
struct pa_stream {
PA_REFCNT_DECLARE;
PA_LLIST_FIELDS(pa_stream);
@@ -131,6 +144,9 @@ struct pa_stream {
pa_sample_spec sample_spec;
pa_channel_map channel_map;
+ uint8_t n_formats;
+ pa_format_info *req_formats[PA_MAX_FORMATS];
+ pa_format_info *format;
pa_proplist *proplist;
@@ -150,6 +166,11 @@ struct pa_stream {
uint32_t device_index;
char *device_name;
+ /* playback */
+ pa_memblock *write_memblock;
+ void *write_data;
+
+ /* recording */
pa_memchunk peek_memchunk;
void *peek_data;
pa_memblockq *record_memblockq;
@@ -277,6 +298,17 @@ pa_tagstruct *pa_tagstruct_command(pa_context *c, uint32_t command, uint32_t *ta
#define PA_FAIL_RETURN_NULL(context, error) \
PA_FAIL_RETURN_ANY(context, error, NULL)
+void pa_ext_device_manager_command(pa_context *c, uint32_t tag, pa_tagstruct *t);
+void pa_ext_device_restore_command(pa_context *c, uint32_t tag, pa_tagstruct *t);
void pa_ext_stream_restore_command(pa_context *c, uint32_t tag, pa_tagstruct *t);
+void pa_format_info_free2(pa_format_info *f, void *userdata);
+pa_format_info* pa_format_info_from_sample_spec(pa_sample_spec *ss, pa_channel_map *map);
+pa_bool_t pa_format_info_to_sample_spec(pa_format_info *f, pa_sample_spec *ss, pa_channel_map *map);
+pa_bool_t pa_format_info_to_sample_spec_fake(pa_format_info *f, pa_sample_spec *ss);
+pa_bool_t pa_format_info_get_prop_int(pa_format_info *f, const char *key, int *v);
+pa_bool_t pa_format_info_get_prop_string(pa_format_info *f, const char *key, char **v);
+
+pa_bool_t pa_mainloop_is_our_api(pa_mainloop_api*m);
+
#endif
diff --git a/src/pulse/introspect.c b/src/pulse/introspect.c
index ac8a11aa..27a298cf 100644
--- a/src/pulse/introspect.c
+++ b/src/pulse/introspect.c
@@ -24,19 +24,15 @@
#include <config.h>
#endif
-#include <string.h>
-
#include <pulse/context.h>
-#include <pulse/gccmacro.h>
#include <pulse/xmalloc.h>
+#include <pulse/fork-detect.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-util.h>
#include <pulsecore/pstream-util.h>
#include "internal.h"
-#include "fork-detect.h"
-
#include "introspect.h"
/*** Statistics ***/
@@ -49,7 +45,7 @@ static void context_stat_callback(pa_pdispatch *pd, uint32_t command, uint32_t t
pa_assert(o);
pa_assert(PA_REFCNT_VALUE(o) >= 1);
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
if (!o->context)
goto finish;
@@ -93,7 +89,7 @@ static void context_get_server_info_callback(pa_pdispatch *pd, uint32_t command,
pa_assert(o);
pa_assert(PA_REFCNT_VALUE(o) >= 1);
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
if (!o->context)
goto finish;
@@ -141,11 +137,16 @@ pa_operation* pa_context_get_server_info(pa_context *c, pa_server_info_cb_t cb,
static void context_get_sink_info_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
pa_operation *o = userdata;
int eol = 1;
+ pa_sink_info i;
+ uint32_t j;
pa_assert(pd);
pa_assert(o);
pa_assert(PA_REFCNT_VALUE(o) >= 1);
+ /* For safety incase someone use fail: outside the while loop below */
+ pa_zero(i);
+
if (!o->context)
goto finish;
@@ -157,12 +158,12 @@ static void context_get_sink_info_callback(pa_pdispatch *pd, uint32_t command, u
} else {
while (!pa_tagstruct_eof(t)) {
- pa_sink_info i;
pa_bool_t mute;
uint32_t flags;
uint32_t state;
+ const char *ap = NULL;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
i.proplist = pa_proplist_new();
i.base_volume = PA_VOLUME_NORM;
i.n_volume_steps = PA_VOLUME_NORM+1;
@@ -190,11 +191,58 @@ static void context_get_sink_info_callback(pa_pdispatch *pd, uint32_t command, u
(pa_tagstruct_get_volume(t, &i.base_volume) < 0 ||
pa_tagstruct_getu32(t, &state) < 0 ||
pa_tagstruct_getu32(t, &i.n_volume_steps) < 0 ||
- pa_tagstruct_getu32(t, &i.card) < 0))) {
+ pa_tagstruct_getu32(t, &i.card) < 0)) ||
+ (o->context->version >= 16 &&
+ (pa_tagstruct_getu32(t, &i.n_ports)))) {
- pa_context_fail(o->context, PA_ERR_PROTOCOL);
- pa_proplist_free(i.proplist);
- goto finish;
+ goto fail;
+ }
+
+ if (o->context->version >= 16) {
+ if (i.n_ports > 0) {
+ i.ports = pa_xnew(pa_sink_port_info*, i.n_ports+1);
+ i.ports[0] = pa_xnew(pa_sink_port_info, i.n_ports);
+
+ for (j = 0; j < i.n_ports; j++) {
+ if (pa_tagstruct_gets(t, &i.ports[0][j].name) < 0 ||
+ pa_tagstruct_gets(t, &i.ports[0][j].description) < 0 ||
+ pa_tagstruct_getu32(t, &i.ports[0][j].priority) < 0) {
+
+ goto fail;
+ }
+
+ i.ports[j] = &i.ports[0][j];
+ }
+
+ i.ports[j] = NULL;
+ }
+
+ if (pa_tagstruct_gets(t, &ap) < 0)
+ goto fail;
+
+ if (ap) {
+ for (j = 0; j < i.n_ports; j++)
+ if (pa_streq(i.ports[j]->name, ap)) {
+ i.active_port = i.ports[j];
+ break;
+ }
+ }
+ }
+
+ if (o->context->version >= 21) {
+ uint8_t n_formats;
+ if (pa_tagstruct_getu8(t, &n_formats) < 0 || n_formats < 1)
+ goto fail;
+
+ i.formats = pa_xnew0(pa_format_info*, n_formats);
+
+ for (j = 0; j < n_formats; j++) {
+ i.n_formats++;
+ i.formats[j] = pa_format_info_new();
+
+ if (pa_tagstruct_get_format_info(t, i.formats[j]) < 0)
+ goto fail;
+ }
}
i.mute = (int) mute;
@@ -206,6 +254,15 @@ static void context_get_sink_info_callback(pa_pdispatch *pd, uint32_t command, u
cb(o->context, &i, 0, o->userdata);
}
+ if (i.formats) {
+ for (j = 0; j < i.n_formats; j++)
+ pa_format_info_free(i.formats[j]);
+ pa_xfree(i.formats);
+ }
+ if (i.ports) {
+ pa_xfree(i.ports[0]);
+ pa_xfree(i.ports);
+ }
pa_proplist_free(i.proplist);
}
}
@@ -218,6 +275,25 @@ static void context_get_sink_info_callback(pa_pdispatch *pd, uint32_t command, u
finish:
pa_operation_done(o);
pa_operation_unref(o);
+ return;
+
+fail:
+ pa_assert(i.proplist);
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+
+ if (i.formats) {
+ for (j = 0; j < i.n_formats; j++)
+ pa_format_info_free(i.formats[j]);
+ pa_xfree(i.formats);
+ }
+ if (i.ports) {
+ pa_xfree(i.ports[0]);
+ pa_xfree(i.ports);
+ }
+ pa_proplist_free(i.proplist);
+
+ goto finish;
}
pa_operation* pa_context_get_sink_info_list(pa_context *c, pa_sink_info_cb_t cb, void *userdata) {
@@ -271,16 +347,71 @@ pa_operation* pa_context_get_sink_info_by_name(pa_context *c, const char *name,
return o;
}
+pa_operation* pa_context_set_sink_port_by_index(pa_context *c, uint32_t idx, const char*port, pa_context_success_cb_t cb, void *userdata) {
+ pa_operation *o;
+ pa_tagstruct *t;
+ uint32_t tag;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, idx != PA_INVALID_INDEX, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 16, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_SET_SINK_PORT, &tag);
+ pa_tagstruct_putu32(t, idx);
+ pa_tagstruct_puts(t, NULL);
+ pa_tagstruct_puts(t, port);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation* pa_context_set_sink_port_by_name(pa_context *c, const char *name, const char*port, pa_context_success_cb_t cb, void *userdata) {
+ pa_operation *o;
+ pa_tagstruct *t;
+ uint32_t tag;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !name || *name, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 16, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_SET_SINK_PORT, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, name);
+ pa_tagstruct_puts(t, port);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
/*** Source info ***/
static void context_get_source_info_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
pa_operation *o = userdata;
int eol = 1;
+ pa_source_info i;
+ uint32_t j;
pa_assert(pd);
pa_assert(o);
pa_assert(PA_REFCNT_VALUE(o) >= 1);
+ /* For safety incase someone use fail: outside the while loop below */
+ pa_zero(i);
+
if (!o->context)
goto finish;
@@ -292,12 +423,12 @@ static void context_get_source_info_callback(pa_pdispatch *pd, uint32_t command,
} else {
while (!pa_tagstruct_eof(t)) {
- pa_source_info i;
pa_bool_t mute;
uint32_t flags;
uint32_t state;
+ const char *ap;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
i.proplist = pa_proplist_new();
i.base_volume = PA_VOLUME_NORM;
i.n_volume_steps = PA_VOLUME_NORM+1;
@@ -325,11 +456,58 @@ static void context_get_source_info_callback(pa_pdispatch *pd, uint32_t command,
(pa_tagstruct_get_volume(t, &i.base_volume) < 0 ||
pa_tagstruct_getu32(t, &state) < 0 ||
pa_tagstruct_getu32(t, &i.n_volume_steps) < 0 ||
- pa_tagstruct_getu32(t, &i.card) < 0))) {
+ pa_tagstruct_getu32(t, &i.card) < 0)) ||
+ (o->context->version >= 16 &&
+ (pa_tagstruct_getu32(t, &i.n_ports)))) {
- pa_context_fail(o->context, PA_ERR_PROTOCOL);
- pa_proplist_free(i.proplist);
- goto finish;
+ goto fail;
+ }
+
+ if (o->context->version >= 16) {
+ if (i.n_ports > 0) {
+ i.ports = pa_xnew(pa_source_port_info*, i.n_ports+1);
+ i.ports[0] = pa_xnew(pa_source_port_info, i.n_ports);
+
+ for (j = 0; j < i.n_ports; j++) {
+ if (pa_tagstruct_gets(t, &i.ports[0][j].name) < 0 ||
+ pa_tagstruct_gets(t, &i.ports[0][j].description) < 0 ||
+ pa_tagstruct_getu32(t, &i.ports[0][j].priority) < 0) {
+
+ goto fail;
+ }
+
+ i.ports[j] = &i.ports[0][j];
+ }
+
+ i.ports[j] = NULL;
+ }
+
+ if (pa_tagstruct_gets(t, &ap) < 0)
+ goto fail;
+
+ if (ap) {
+ for (j = 0; j < i.n_ports; j++)
+ if (pa_streq(i.ports[j]->name, ap)) {
+ i.active_port = i.ports[j];
+ break;
+ }
+ }
+ }
+
+ if (o->context->version >= 22) {
+ uint8_t n_formats;
+ if (pa_tagstruct_getu8(t, &n_formats) < 0 || n_formats < 1)
+ goto fail;
+
+ i.formats = pa_xnew0(pa_format_info*, n_formats);
+
+ for (j = 0; j < n_formats; j++) {
+ i.n_formats++;
+ i.formats[j] = pa_format_info_new();
+
+ if (pa_tagstruct_get_format_info(t, i.formats[j]) < 0)
+ goto fail;
+ }
}
i.mute = (int) mute;
@@ -341,6 +519,15 @@ static void context_get_source_info_callback(pa_pdispatch *pd, uint32_t command,
cb(o->context, &i, 0, o->userdata);
}
+ if (i.formats) {
+ for (j = 0; j < i.n_formats; j++)
+ pa_format_info_free(i.formats[j]);
+ pa_xfree(i.formats);
+ }
+ if (i.ports) {
+ pa_xfree(i.ports[0]);
+ pa_xfree(i.ports);
+ }
pa_proplist_free(i.proplist);
}
}
@@ -353,6 +540,25 @@ static void context_get_source_info_callback(pa_pdispatch *pd, uint32_t command,
finish:
pa_operation_done(o);
pa_operation_unref(o);
+ return;
+
+fail:
+ pa_assert(i.proplist);
+
+ pa_context_fail(o->context, PA_ERR_PROTOCOL);
+
+ if (i.formats) {
+ for (j = 0; j < i.n_formats; j++)
+ pa_format_info_free(i.formats[j]);
+ pa_xfree(i.formats);
+ }
+ if (i.ports) {
+ pa_xfree(i.ports[0]);
+ pa_xfree(i.ports);
+ }
+ pa_proplist_free(i.proplist);
+
+ goto finish;
}
pa_operation* pa_context_get_source_info_list(pa_context *c, pa_source_info_cb_t cb, void *userdata) {
@@ -406,6 +612,56 @@ pa_operation* pa_context_get_source_info_by_name(pa_context *c, const char *name
return o;
}
+pa_operation* pa_context_set_source_port_by_index(pa_context *c, uint32_t idx, const char*port, pa_context_success_cb_t cb, void *userdata) {
+ pa_operation *o;
+ pa_tagstruct *t;
+ uint32_t tag;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, idx != PA_INVALID_INDEX, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 16, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_SET_SOURCE_PORT, &tag);
+ pa_tagstruct_putu32(t, idx);
+ pa_tagstruct_puts(t, NULL);
+ pa_tagstruct_puts(t, port);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation* pa_context_set_source_port_by_name(pa_context *c, const char *name, const char*port, pa_context_success_cb_t cb, void *userdata) {
+ pa_operation *o;
+ pa_tagstruct *t;
+ uint32_t tag;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !name || *name, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 16, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_SET_SOURCE_PORT, &tag);
+ pa_tagstruct_putu32(t, PA_INVALID_INDEX);
+ pa_tagstruct_puts(t, name);
+ pa_tagstruct_puts(t, port);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
/*** Client info ***/
static void context_get_client_info_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
@@ -429,7 +685,7 @@ static void context_get_client_info_callback(pa_pdispatch *pd, uint32_t command,
while (!pa_tagstruct_eof(t)) {
pa_client_info i;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
i.proplist = pa_proplist_new();
if (pa_tagstruct_getu32(t, &i.index) < 0 ||
@@ -514,7 +770,7 @@ static void context_get_card_info_callback(pa_pdispatch *pd, uint32_t command, u
uint32_t j;
const char*ap;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
if (pa_tagstruct_getu32(t, &i.index) < 0 ||
pa_tagstruct_gets(t, &i.name) < 0 ||
@@ -527,7 +783,7 @@ static void context_get_card_info_callback(pa_pdispatch *pd, uint32_t command, u
}
if (i.n_profiles > 0) {
- i.profiles = pa_xnew(pa_card_profile_info, i.n_profiles+1);
+ i.profiles = pa_xnew0(pa_card_profile_info, i.n_profiles+1);
for (j = 0; j < i.n_profiles; j++) {
@@ -638,6 +894,8 @@ pa_operation* pa_context_get_card_info_by_name(pa_context *c, const char*name, p
}
pa_operation* pa_context_get_card_info_list(pa_context *c, pa_card_info_cb_t cb, void *userdata) {
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 15, PA_ERR_NOTSUPPORTED);
+
return pa_context_send_simple_command(c, PA_COMMAND_GET_CARD_INFO_LIST, context_get_card_info_callback, (pa_operation_cb_t) cb, userdata);
}
@@ -715,7 +973,7 @@ static void context_get_module_info_callback(pa_pdispatch *pd, uint32_t command,
pa_module_info i;
pa_bool_t auto_unload = FALSE;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
i.proplist = pa_proplist_new();
if (pa_tagstruct_getu32(t, &i.index) < 0 ||
@@ -798,10 +1056,11 @@ static void context_get_sink_input_info_callback(pa_pdispatch *pd, uint32_t comm
while (!pa_tagstruct_eof(t)) {
pa_sink_input_info i;
- pa_bool_t mute = FALSE;
+ pa_bool_t mute = FALSE, corked = FALSE, has_volume = FALSE, volume_writable = TRUE;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
i.proplist = pa_proplist_new();
+ i.format = pa_format_info_new();
if (pa_tagstruct_getu32(t, &i.index) < 0 ||
pa_tagstruct_gets(t, &i.name) < 0 ||
@@ -816,14 +1075,22 @@ static void context_get_sink_input_info_callback(pa_pdispatch *pd, uint32_t comm
pa_tagstruct_gets(t, &i.resample_method) < 0 ||
pa_tagstruct_gets(t, &i.driver) < 0 ||
(o->context->version >= 11 && pa_tagstruct_get_boolean(t, &mute) < 0) ||
- (o->context->version >= 13 && pa_tagstruct_get_proplist(t, i.proplist) < 0)) {
+ (o->context->version >= 13 && pa_tagstruct_get_proplist(t, i.proplist) < 0) ||
+ (o->context->version >= 19 && pa_tagstruct_get_boolean(t, &corked) < 0) ||
+ (o->context->version >= 20 && (pa_tagstruct_get_boolean(t, &has_volume) < 0 ||
+ pa_tagstruct_get_boolean(t, &volume_writable) < 0)) ||
+ (o->context->version >= 21 && pa_tagstruct_get_format_info(t, i.format) < 0)) {
pa_context_fail(o->context, PA_ERR_PROTOCOL);
pa_proplist_free(i.proplist);
+ pa_format_info_free(i.format);
goto finish;
}
i.mute = (int) mute;
+ i.corked = (int) corked;
+ i.has_volume = (int) has_volume;
+ i.volume_writable = (int) volume_writable;
if (o->callback) {
pa_sink_input_info_cb_t cb = (pa_sink_input_info_cb_t) o->callback;
@@ -831,6 +1098,7 @@ static void context_get_sink_input_info_callback(pa_pdispatch *pd, uint32_t comm
}
pa_proplist_free(i.proplist);
+ pa_format_info_free(i.format);
}
}
@@ -893,9 +1161,11 @@ static void context_get_source_output_info_callback(pa_pdispatch *pd, uint32_t c
while (!pa_tagstruct_eof(t)) {
pa_source_output_info i;
+ pa_bool_t mute = FALSE, corked = FALSE, has_volume = FALSE, volume_writable = TRUE;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
i.proplist = pa_proplist_new();
+ i.format = pa_format_info_new();
if (pa_tagstruct_getu32(t, &i.index) < 0 ||
pa_tagstruct_gets(t, &i.name) < 0 ||
@@ -908,19 +1178,32 @@ static void context_get_source_output_info_callback(pa_pdispatch *pd, uint32_t c
pa_tagstruct_get_usec(t, &i.source_usec) < 0 ||
pa_tagstruct_gets(t, &i.resample_method) < 0 ||
pa_tagstruct_gets(t, &i.driver) < 0 ||
- (o->context->version >= 13 && pa_tagstruct_get_proplist(t, i.proplist) < 0)) {
+ (o->context->version >= 13 && pa_tagstruct_get_proplist(t, i.proplist) < 0) ||
+ (o->context->version >= 19 && pa_tagstruct_get_boolean(t, &corked) < 0) ||
+ (o->context->version >= 22 && (pa_tagstruct_get_cvolume(t, &i.volume) < 0 ||
+ pa_tagstruct_get_boolean(t, &mute) < 0 ||
+ pa_tagstruct_get_boolean(t, &has_volume) < 0 ||
+ pa_tagstruct_get_boolean(t, &volume_writable) < 0 ||
+ pa_tagstruct_get_format_info(t, i.format) < 0))) {
pa_context_fail(o->context, PA_ERR_PROTOCOL);
pa_proplist_free(i.proplist);
+ pa_format_info_free(i.format);
goto finish;
}
+ i.mute = (int) mute;
+ i.corked = (int) corked;
+ i.has_volume = (int) has_volume;
+ i.volume_writable = (int) volume_writable;
+
if (o->callback) {
pa_source_output_info_cb_t cb = (pa_source_output_info_cb_t) o->callback;
cb(o->context, &i, 0, o->userdata);
}
pa_proplist_free(i.proplist);
+ pa_format_info_free(i.format);
}
}
@@ -1212,6 +1495,56 @@ pa_operation* pa_context_set_source_mute_by_name(pa_context *c, const char *name
return o;
}
+pa_operation* pa_context_set_source_output_volume(pa_context *c, uint32_t idx, const pa_cvolume *volume, pa_context_success_cb_t cb, void *userdata) {
+ pa_operation *o;
+ pa_tagstruct *t;
+ uint32_t tag;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert(volume);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, idx != PA_INVALID_INDEX, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 22, PA_ERR_NOTSUPPORTED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, pa_cvolume_valid(volume), PA_ERR_INVALID);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_SET_SOURCE_OUTPUT_VOLUME, &tag);
+ pa_tagstruct_putu32(t, idx);
+ pa_tagstruct_put_cvolume(t, volume);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
+pa_operation* pa_context_set_source_output_mute(pa_context *c, uint32_t idx, int mute, pa_context_success_cb_t cb, void *userdata) {
+ pa_operation *o;
+ pa_tagstruct *t;
+ uint32_t tag;
+
+ pa_assert(c);
+ pa_assert(PA_REFCNT_VALUE(c) >= 1);
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, idx != PA_INVALID_INDEX, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 22, PA_ERR_NOTSUPPORTED);
+
+ o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
+
+ t = pa_tagstruct_command(c, PA_COMMAND_SET_SOURCE_OUTPUT_MUTE, &tag);
+ pa_tagstruct_putu32(t, idx);
+ pa_tagstruct_put_boolean(t, mute);
+ pa_pstream_send_tagstruct(c->pstream, t);
+ pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, pa_context_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+
+ return o;
+}
+
/** Sample Cache **/
static void context_get_sample_info_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
@@ -1236,7 +1569,7 @@ static void context_get_sample_info_callback(pa_pdispatch *pd, uint32_t command,
pa_sample_info i;
pa_bool_t lazy = FALSE;
- memset(&i, 0, sizeof(i));
+ pa_zero(i);
i.proplist = pa_proplist_new();
if (pa_tagstruct_getu32(t, &i.index) < 0 ||
diff --git a/src/pulse/introspect.h b/src/pulse/introspect.h
index 117880c8..196d44d6 100644
--- a/src/pulse/introspect.h
+++ b/src/pulse/introspect.h
@@ -32,6 +32,7 @@
#include <pulse/channelmap.h>
#include <pulse/volume.h>
#include <pulse/proplist.h>
+#include <pulse/format.h>
#include <pulse/version.h>
/** \page introspect Server Query and Control
@@ -59,7 +60,7 @@
* Note that even if a single object is requested, and not the entire list,
* the terminating call will still be made.
*
- * If an error occurs, the callback will be called without and information
+ * If an error occurs, the callback will be called without an information
* structure and eol set to a negative value..
*
* Data members in the information structures are only valid during the
@@ -163,9 +164,8 @@
*
* If an application desires to modify the volume of just a single stream
* (commonly one of its own streams), this can be done by setting the volume
- * of its associated sink input, using pa_context_set_sink_input_volume().
- *
- * There is no support for modifying the volume of source outputs.
+ * of its associated sink input or source output, using
+ * pa_context_set_sink_input_volume() or pa_context_set_source_output_volume()
*
* It is also possible to remove sink inputs and source outputs, terminating
* the streams associated with them:
@@ -187,12 +187,23 @@
/** \file
*
* Routines for daemon introspection.
+ *
+ * See also \subpage introspect
*/
PA_C_DECL_BEGIN
/** @{ \name Sinks */
+/** Stores information about a specific port of a sink. Please
+ * note that this structure can be extended as part of evolutionary
+ * API updates at any time in any new release. \since 0.9.16 */
+typedef struct pa_sink_port_info {
+ const char *name; /**< Name of this port */
+ const char *description; /**< Description of this port */
+ uint32_t priority; /**< The higher this value is the more useful this port is as a default */
+} pa_sink_port_info;
+
/** Stores information about sinks. Please note that this structure
* can be extended as part of evolutionary API updates at any time in
* any new release. */
@@ -216,6 +227,11 @@ typedef struct pa_sink_info {
pa_sink_state_t state; /**< State \since 0.9.15 */
uint32_t n_volume_steps; /**< Number of volume steps for sinks which do not support arbitrary volumes. \since 0.9.15 */
uint32_t card; /**< Card index, or PA_INVALID_INDEX. \since 0.9.15 */
+ uint32_t n_ports; /**< Number of entries in port array \since 0.9.16 */
+ pa_sink_port_info** ports; /**< Array of available ports, or NULL. Array is terminated by an entry set to NULL. The number of entries is stored in n_ports \since 0.9.16 */
+ pa_sink_port_info* active_port; /**< Pointer to active port in the array, or NULL \since 0.9.16 */
+ uint8_t n_formats; /**< Number of formats supported by the sink. \since 1.0 */
+ pa_format_info **formats; /**< Array of formats supported by the sink. \since 1.0 */
} pa_sink_info;
/** Callback prototype for pa_context_get_sink_info_by_name() and friends */
@@ -248,10 +264,25 @@ pa_operation* pa_context_suspend_sink_by_name(pa_context *c, const char *sink_na
/** Suspend/Resume a sink. If idx is PA_INVALID_INDEX all sinks will be suspended. \since 0.9.7 */
pa_operation* pa_context_suspend_sink_by_index(pa_context *c, uint32_t idx, int suspend, pa_context_success_cb_t cb, void* userdata);
+/** Change the profile of a sink. \since 0.9.16 */
+pa_operation* pa_context_set_sink_port_by_index(pa_context *c, uint32_t idx, const char*port, pa_context_success_cb_t cb, void *userdata);
+
+/** Change the profile of a sink. \since 0.9.15 */
+pa_operation* pa_context_set_sink_port_by_name(pa_context *c, const char*name, const char*port, pa_context_success_cb_t cb, void *userdata);
+
/** @} */
/** @{ \name Sources */
+/** Stores information about a specific port of a source. Please
+ * note that this structure can be extended as part of evolutionary
+ * API updates at any time in any new release. \since 0.9.16 */
+typedef struct pa_source_port_info {
+ const char *name; /**< Name of this port */
+ const char *description; /**< Description of this port */
+ uint32_t priority; /**< The higher this value is the more useful this port is as a default */
+} pa_source_port_info;
+
/** Stores information about sources. Please note that this structure
* can be extended as part of evolutionary API updates at any time in
* any new release. */
@@ -275,6 +306,11 @@ typedef struct pa_source_info {
pa_source_state_t state; /**< State \since 0.9.15 */
uint32_t n_volume_steps; /**< Number of volume steps for sources which do not support arbitrary volumes. \since 0.9.15 */
uint32_t card; /**< Card index, or PA_INVALID_INDEX. \since 0.9.15 */
+ uint32_t n_ports; /**< Number of entries in port array \since 0.9.16 */
+ pa_source_port_info** ports; /**< Array of available ports, or NULL. Array is terminated by an entry set to NULL. The number of entries is stored in n_ports \since 0.9.16 */
+ pa_source_port_info* active_port; /**< Pointer to active port in the array, or NULL \since 0.9.16 */
+ uint8_t n_formats; /**< Number of formats supported by the source. \since 1.0 */
+ pa_format_info **formats; /**< Array of formats supported by the source. \since 1.0 */
} pa_source_info;
/** Callback prototype for pa_context_get_source_info_by_name() and friends */
@@ -301,6 +337,18 @@ pa_operation* pa_context_set_source_mute_by_index(pa_context *c, uint32_t idx, i
/** Set the mute switch of a source device specified by its name */
pa_operation* pa_context_set_source_mute_by_name(pa_context *c, const char *name, int mute, pa_context_success_cb_t cb, void *userdata);
+/** Suspend/Resume a source. \since 0.9.7 */
+pa_operation* pa_context_suspend_source_by_name(pa_context *c, const char *source_name, int suspend, pa_context_success_cb_t cb, void* userdata);
+
+/** Suspend/Resume a source. If idx is PA_INVALID_INDEX all sources will be suspended. \since 0.9.7 */
+pa_operation* pa_context_suspend_source_by_index(pa_context *c, uint32_t idx, int suspend, pa_context_success_cb_t cb, void* userdata);
+
+/** Change the profile of a source. \since 0.9.16 */
+pa_operation* pa_context_set_source_port_by_index(pa_context *c, uint32_t idx, const char*port, pa_context_success_cb_t cb, void *userdata);
+
+/** Change the profile of a source. \since 0.9.15 */
+pa_operation* pa_context_set_source_port_by_name(pa_context *c, const char*name, const char*port, pa_context_success_cb_t cb, void *userdata);
+
/** @} */
/** @{ \name Server */
@@ -418,7 +466,7 @@ typedef struct pa_card_info {
pa_proplist *proplist; /**< Property list */
} pa_card_info;
-/** Callback prototype for pa_context_get_card_info() and friends \since 0.9.15 */
+/** Callback prototype for pa_context_get_card_info_...() \since 0.9.15 */
typedef void (*pa_card_info_cb_t) (pa_context *c, const pa_card_info*i, int eol, void *userdata);
/** Get information about a card by its index \since 0.9.15 */
@@ -458,6 +506,10 @@ typedef struct pa_sink_input_info {
const char *driver; /**< Driver name */
int mute; /**< Stream muted \since 0.9.7 */
pa_proplist *proplist; /**< Property list \since 0.9.11 */
+ int corked; /**< Stream corked \since 1.0 */
+ int has_volume; /**< Stream has volume. If not set, then the meaning of this struct's volume member is unspecified. \since 1.0 */
+ int volume_writable; /**< The volume can be set. If not set, the volume can still change even though clients can't control the volume. \since 1.0 */
+ pa_format_info *format; /**< Stream format information. \since 1.0 */
} pa_sink_input_info;
/** Callback prototype for pa_context_get_sink_input_info() and friends*/
@@ -504,6 +556,12 @@ typedef struct pa_source_output_info {
const char *resample_method; /**< The resampling method used by this source output. */
const char *driver; /**< Driver name */
pa_proplist *proplist; /**< Property list \since 0.9.11 */
+ int corked; /**< Stream corked \since 1.0 */
+ pa_cvolume volume; /**< The volume of this source output \since 1.0 */
+ int mute; /**< Stream muted \since 1.0 */
+ int has_volume; /**< Stream has volume. If not set, then the meaning of this struct's volume member is unspecified. \since 1.0 */
+ int volume_writable; /**< The volume can be set. If not set, the volume can still change even though clients can't control the volume. \since 1.0 */
+ pa_format_info *format; /**< Stream format information. \since 1.0 */
} pa_source_output_info;
/** Callback prototype for pa_context_get_source_output_info() and friends*/
@@ -521,11 +579,11 @@ pa_operation* pa_context_move_source_output_by_name(pa_context *c, uint32_t idx,
/** Move the specified source output to a different source. \since 0.9.5 */
pa_operation* pa_context_move_source_output_by_index(pa_context *c, uint32_t idx, uint32_t source_idx, pa_context_success_cb_t cb, void* userdata);
-/** Suspend/Resume a source. \since 0.9.7 */
-pa_operation* pa_context_suspend_source_by_name(pa_context *c, const char *source_name, int suspend, pa_context_success_cb_t cb, void* userdata);
+/** Set the volume of a source output stream \since 1.0 */
+pa_operation* pa_context_set_source_output_volume(pa_context *c, uint32_t idx, const pa_cvolume *volume, pa_context_success_cb_t cb, void *userdata);
-/** Suspend/Resume a source. If idx is PA_INVALID_INDEX all sources will be suspended. \since 0.9.7 */
-pa_operation* pa_context_suspend_source_by_index(pa_context *c, uint32_t idx, int suspend, pa_context_success_cb_t cb, void* userdata);
+/** Set the mute switch of a source output stream \since 1.0 */
+pa_operation* pa_context_set_source_output_mute(pa_context *c, uint32_t idx, int mute, pa_context_success_cb_t cb, void *userdata);
/** Kill a source output. */
pa_operation* pa_context_kill_source_output(pa_context *c, uint32_t idx, pa_context_success_cb_t cb, void *userdata);
diff --git a/src/pulse/mainloop-api.c b/src/pulse/mainloop-api.c
index 4b862f9a..c1f76046 100644
--- a/src/pulse/mainloop-api.c
+++ b/src/pulse/mainloop-api.c
@@ -26,7 +26,6 @@
#include <stdlib.h>
#include <pulse/xmalloc.h>
-#include <pulse/gccmacro.h>
#include <pulse/i18n.h>
#include <pulsecore/macro.h>
diff --git a/src/pulse/mainloop-api.h b/src/pulse/mainloop-api.h
index e353ed96..eb2e8421 100644
--- a/src/pulse/mainloop-api.h
+++ b/src/pulse/mainloop-api.h
@@ -24,7 +24,6 @@
***/
#include <sys/time.h>
-#include <time.h>
#include <pulse/cdecl.h>
#include <pulse/version.h>
@@ -80,7 +79,7 @@ typedef void (*pa_defer_event_cb_t)(pa_mainloop_api*a, pa_defer_event* e, void *
typedef void (*pa_defer_event_destroy_cb_t)(pa_mainloop_api*a, pa_defer_event *e, void *userdata);
/** An abstract mainloop API vtable */
-struct pa_mainloop_api {
+struct pa_mainloop_api {
/** A pointer to some private, arbitrary data of the main loop implementation */
void *userdata;
diff --git a/src/pulse/mainloop-signal.c b/src/pulse/mainloop-signal.c
index 3dc74398..393d1f7d 100644
--- a/src/pulse/mainloop-signal.c
+++ b/src/pulse/mainloop-signal.c
@@ -30,14 +30,12 @@
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
-#include <fcntl.h>
#ifdef HAVE_WINDOWS_H
#include <windows.h>
#endif
#include <pulse/xmalloc.h>
-#include <pulse/gccmacro.h>
#include <pulse/i18n.h>
#include <pulsecore/core-error.h>
@@ -124,15 +122,13 @@ int pa_signal_init(pa_mainloop_api *a) {
pa_assert(signal_pipe[1] == -1);
pa_assert(!io_event);
- if (pipe(signal_pipe) < 0) {
+ if (pa_pipe_cloexec(signal_pipe) < 0) {
pa_log("pipe(): %s", pa_cstrerror(errno));
return -1;
}
pa_make_fd_nonblock(signal_pipe[0]);
pa_make_fd_nonblock(signal_pipe[1]);
- pa_make_fd_cloexec(signal_pipe[0]);
- pa_make_fd_cloexec(signal_pipe[1]);
api = a;
diff --git a/src/pulse/mainloop.c b/src/pulse/mainloop.c
index 225fd098..3ef387b6 100644
--- a/src/pulse/mainloop.c
+++ b/src/pulse/mainloop.c
@@ -25,35 +25,31 @@
#endif
#include <stdio.h>
-#include <signal.h>
#include <unistd.h>
#include <stdlib.h>
-#include <string.h>
#include <fcntl.h>
#include <errno.h>
-#ifdef HAVE_POLL_H
-#include <poll.h>
-#else
-#include <pulsecore/poll.h>
-#endif
-
#ifndef HAVE_PIPE
#include <pulsecore/pipe.h>
#endif
+#include <pulse/i18n.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
-#include <pulse/i18n.h>
+#include <pulsecore/poll.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/llist.h>
#include <pulsecore/log.h>
#include <pulsecore/core-error.h>
-#include <pulsecore/winsock.h>
+#include <pulsecore/socket.h>
#include <pulsecore/macro.h>
#include "mainloop.h"
+#include "internal.h"
struct pa_io_event {
pa_mainloop *mainloop;
@@ -75,7 +71,8 @@ struct pa_time_event {
pa_bool_t dead:1;
pa_bool_t enabled:1;
- struct timeval timeval;
+ pa_bool_t use_rtclock:1;
+ pa_usec_t time;
pa_time_event_cb_t callback;
void *userdata;
@@ -109,7 +106,7 @@ struct pa_mainloop {
struct pollfd *pollfds;
unsigned max_pollfds, n_pollfds;
- int prepared_timeout;
+ pa_usec_t prepared_timeout;
pa_time_event *cached_next_time_event;
pa_mainloop_api api;
@@ -152,7 +149,7 @@ static pa_io_event_flags_t map_flags_from_libc(short flags) {
/* IO events */
static pa_io_event* mainloop_io_new(
- pa_mainloop_api*a,
+ pa_mainloop_api *a,
int fd,
pa_io_event_flags_t events,
pa_io_event_cb_t callback,
@@ -169,17 +166,14 @@ static pa_io_event* mainloop_io_new(
m = a->userdata;
pa_assert(a == &m->api);
- e = pa_xnew(pa_io_event, 1);
+ e = pa_xnew0(pa_io_event, 1);
e->mainloop = m;
- e->dead = FALSE;
e->fd = fd;
e->events = events;
- e->pollfd = NULL;
e->callback = callback;
e->userdata = userdata;
- e->destroy_callback = NULL;
#ifdef OS_IS_WIN32
{
@@ -248,7 +242,7 @@ static void mainloop_io_set_destroy(pa_io_event *e, pa_io_event_destroy_cb_t cal
/* Defer events */
static pa_defer_event* mainloop_defer_new(
- pa_mainloop_api*a,
+ pa_mainloop_api *a,
pa_defer_event_cb_t callback,
void *userdata) {
@@ -262,16 +256,14 @@ static pa_defer_event* mainloop_defer_new(
m = a->userdata;
pa_assert(a == &m->api);
- e = pa_xnew(pa_defer_event, 1);
+ e = pa_xnew0(pa_defer_event, 1);
e->mainloop = m;
- e->dead = FALSE;
e->enabled = TRUE;
m->n_enabled_defer_events++;
e->callback = callback;
e->userdata = userdata;
- e->destroy_callback = NULL;
PA_LLIST_PREPEND(pa_defer_event, m->defer_events, e);
@@ -317,42 +309,64 @@ static void mainloop_defer_set_destroy(pa_defer_event *e, pa_defer_event_destroy
}
/* Time events */
+static pa_usec_t make_rt(const struct timeval *tv, pa_bool_t *use_rtclock) {
+ struct timeval ttv;
+
+ if (!tv) {
+ *use_rtclock = FALSE;
+ return PA_USEC_INVALID;
+ }
+
+ ttv = *tv;
+ *use_rtclock = !!(ttv.tv_usec & PA_TIMEVAL_RTCLOCK);
+
+ if (*use_rtclock)
+ ttv.tv_usec &= ~PA_TIMEVAL_RTCLOCK;
+ else
+ pa_rtclock_from_wallclock(&ttv);
+
+ return pa_timeval_load(&ttv);
+}
+
static pa_time_event* mainloop_time_new(
- pa_mainloop_api*a,
+ pa_mainloop_api *a,
const struct timeval *tv,
pa_time_event_cb_t callback,
void *userdata) {
pa_mainloop *m;
pa_time_event *e;
+ pa_usec_t t;
+ pa_bool_t use_rtclock = FALSE;
pa_assert(a);
pa_assert(a->userdata);
pa_assert(callback);
+ t = make_rt(tv, &use_rtclock);
+
m = a->userdata;
pa_assert(a == &m->api);
- e = pa_xnew(pa_time_event, 1);
+ e = pa_xnew0(pa_time_event, 1);
e->mainloop = m;
- e->dead = FALSE;
- if ((e->enabled = !!tv)) {
- e->timeval = *tv;
+ if ((e->enabled = (t != PA_USEC_INVALID))) {
+ e->time = t;
+ e->use_rtclock = use_rtclock;
m->n_enabled_time_events++;
if (m->cached_next_time_event) {
pa_assert(m->cached_next_time_event->enabled);
- if (pa_timeval_cmp(tv, &m->cached_next_time_event->timeval) < 0)
+ if (t < m->cached_next_time_event->time)
m->cached_next_time_event = e;
}
}
e->callback = callback;
e->userdata = userdata;
- e->destroy_callback = NULL;
PA_LLIST_PREPEND(pa_time_event, m->time_events, e);
@@ -363,24 +377,32 @@ static pa_time_event* mainloop_time_new(
}
static void mainloop_time_restart(pa_time_event *e, const struct timeval *tv) {
+ pa_bool_t valid;
+ pa_usec_t t;
+ pa_bool_t use_rtclock = FALSE;
+
pa_assert(e);
pa_assert(!e->dead);
- if (e->enabled && !tv) {
+ t = make_rt(tv, &use_rtclock);
+
+ valid = (t != PA_USEC_INVALID);
+ if (e->enabled && !valid) {
pa_assert(e->mainloop->n_enabled_time_events > 0);
e->mainloop->n_enabled_time_events--;
- } else if (!e->enabled && tv)
+ } else if (!e->enabled && valid)
e->mainloop->n_enabled_time_events++;
- if ((e->enabled = !!tv)) {
- e->timeval = *tv;
+ if ((e->enabled = valid)) {
+ e->time = t;
+ e->use_rtclock = use_rtclock;
pa_mainloop_wakeup(e->mainloop);
}
if (e->mainloop->cached_next_time_event && e->enabled) {
pa_assert(e->mainloop->cached_next_time_event->enabled);
- if (pa_timeval_cmp(tv, &e->mainloop->cached_next_time_event->timeval) < 0)
+ if (t < e->mainloop->cached_next_time_event->time)
e->mainloop->cached_next_time_event = e;
} else if (e->mainloop->cached_next_time_event == e)
e->mainloop->cached_next_time_event = NULL;
@@ -414,7 +436,7 @@ static void mainloop_time_set_destroy(pa_time_event *e, pa_time_event_destroy_cb
/* quit() */
-static void mainloop_quit(pa_mainloop_api*a, int retval) {
+static void mainloop_quit(pa_mainloop_api *a, int retval) {
pa_mainloop *m;
pa_assert(a);
@@ -428,10 +450,10 @@ static void mainloop_quit(pa_mainloop_api*a, int retval) {
static const pa_mainloop_api vtable = {
.userdata = NULL,
- .io_new= mainloop_io_new,
- .io_enable= mainloop_io_enable,
- .io_free= mainloop_io_free,
- .io_set_destroy= mainloop_io_set_destroy,
+ .io_new = mainloop_io_new,
+ .io_enable = mainloop_io_enable,
+ .io_free = mainloop_io_free,
+ .io_set_destroy = mainloop_io_set_destroy,
.time_new = mainloop_time_new,
.time_restart = mainloop_time_restart,
@@ -451,10 +473,9 @@ pa_mainloop *pa_mainloop_new(void) {
pa_init_i18n();
- m = pa_xnew(pa_mainloop, 1);
+ m = pa_xnew0(pa_mainloop, 1);
- m->wakeup_pipe_type = 0;
- if (pipe(m->wakeup_pipe) < 0) {
+ if (pa_pipe_cloexec(m->wakeup_pipe) < 0) {
pa_log_error("ERROR: cannot create wakeup pipe");
pa_xfree(m);
return NULL;
@@ -462,45 +483,23 @@ pa_mainloop *pa_mainloop_new(void) {
pa_make_fd_nonblock(m->wakeup_pipe[0]);
pa_make_fd_nonblock(m->wakeup_pipe[1]);
- pa_make_fd_cloexec(m->wakeup_pipe[0]);
- pa_make_fd_cloexec(m->wakeup_pipe[1]);
- m->wakeup_requested = FALSE;
-
- PA_LLIST_HEAD_INIT(pa_io_event, m->io_events);
- PA_LLIST_HEAD_INIT(pa_time_event, m->time_events);
- PA_LLIST_HEAD_INIT(pa_defer_event, m->defer_events);
-
- m->n_enabled_defer_events = m->n_enabled_time_events = m->n_io_events = 0;
- m->io_events_please_scan = m->time_events_please_scan = m->defer_events_please_scan = 0;
- m->cached_next_time_event = NULL;
- m->prepared_timeout = 0;
-
- m->pollfds = NULL;
- m->max_pollfds = m->n_pollfds = 0;
m->rebuild_pollfds = TRUE;
- m->quit = FALSE;
- m->retval = 0;
-
m->api = vtable;
m->api.userdata = m;
m->state = STATE_PASSIVE;
- m->poll_func = NULL;
- m->poll_func_userdata = NULL;
m->poll_func_ret = -1;
return m;
}
static void cleanup_io_events(pa_mainloop *m, pa_bool_t force) {
- pa_io_event *e;
+ pa_io_event *e, *n;
- e = m->io_events;
- while (e) {
- pa_io_event *n = e->next;
+ PA_LLIST_FOREACH_SAFE(e, n, m->io_events) {
if (!force && m->io_events_please_scan <= 0)
break;
@@ -520,19 +519,15 @@ static void cleanup_io_events(pa_mainloop *m, pa_bool_t force) {
m->rebuild_pollfds = TRUE;
}
-
- e = n;
}
pa_assert(m->io_events_please_scan == 0);
}
static void cleanup_time_events(pa_mainloop *m, pa_bool_t force) {
- pa_time_event *e;
+ pa_time_event *e, *n;
- e = m->time_events;
- while (e) {
- pa_time_event *n = e->next;
+ PA_LLIST_FOREACH_SAFE(e, n, m->time_events) {
if (!force && m->time_events_please_scan <= 0)
break;
@@ -556,19 +551,15 @@ static void cleanup_time_events(pa_mainloop *m, pa_bool_t force) {
pa_xfree(e);
}
-
- e = n;
}
pa_assert(m->time_events_please_scan == 0);
}
static void cleanup_defer_events(pa_mainloop *m, pa_bool_t force) {
- pa_defer_event *e;
+ pa_defer_event *e, *n;
- e = m->defer_events;
- while (e) {
- pa_defer_event *n = e->next;
+ PA_LLIST_FOREACH_SAFE(e, n, m->defer_events) {
if (!force && m->defer_events_please_scan <= 0)
break;
@@ -592,15 +583,13 @@ static void cleanup_defer_events(pa_mainloop *m, pa_bool_t force) {
pa_xfree(e);
}
-
- e = n;
}
pa_assert(m->defer_events_please_scan == 0);
}
-void pa_mainloop_free(pa_mainloop* m) {
+void pa_mainloop_free(pa_mainloop *m) {
pa_assert(m);
cleanup_io_events(m, TRUE);
@@ -650,7 +639,7 @@ static void rebuild_pollfds(pa_mainloop *m) {
m->n_pollfds++;
}
- for (e = m->io_events; e; e = e->next) {
+ PA_LLIST_FOREACH(e, m->io_events) {
if (e->dead) {
e->pollfd = NULL;
continue;
@@ -668,36 +657,46 @@ static void rebuild_pollfds(pa_mainloop *m) {
m->rebuild_pollfds = FALSE;
}
-static int dispatch_pollfds(pa_mainloop *m) {
+static unsigned dispatch_pollfds(pa_mainloop *m) {
pa_io_event *e;
- int r = 0, k;
+ unsigned r = 0, k;
pa_assert(m->poll_func_ret > 0);
- for (e = m->io_events, k = m->poll_func_ret; e && !m->quit && k > 0; e = e->next) {
+ k = m->poll_func_ret;
+
+ PA_LLIST_FOREACH(e, m->io_events) {
+
+ if (k <= 0 || m->quit)
+ break;
+
if (e->dead || !e->pollfd || !e->pollfd->revents)
continue;
pa_assert(e->pollfd->fd == e->fd);
pa_assert(e->callback);
+
e->callback(&m->api, e, e->fd, map_flags_from_libc(e->pollfd->revents), e->userdata);
e->pollfd->revents = 0;
r++;
-
k--;
}
return r;
}
-static int dispatch_defer(pa_mainloop *m) {
+static unsigned dispatch_defer(pa_mainloop *m) {
pa_defer_event *e;
- int r = 0;
+ unsigned r = 0;
if (m->n_enabled_defer_events <= 0)
return 0;
- for (e = m->defer_events; e && !m->quit; e = e->next) {
+ PA_LLIST_FOREACH(e, m->defer_events) {
+
+ if (m->quit)
+ break;
+
if (e->dead || !e->enabled)
continue;
@@ -716,16 +715,16 @@ static pa_time_event* find_next_time_event(pa_mainloop *m) {
if (m->cached_next_time_event)
return m->cached_next_time_event;
- for (t = m->time_events; t; t = t->next) {
+ PA_LLIST_FOREACH(t, m->time_events) {
if (t->dead || !t->enabled)
continue;
- if (!n || pa_timeval_cmp(&t->timeval, &n->timeval) < 0) {
+ if (!n || t->time < n->time) {
n = t;
- /* Shortcut for tv = { 0, 0 } */
- if (n->timeval.tv_sec <= 0)
+ /* Shortcut for time == 0 */
+ if (n->time == 0)
break;
}
}
@@ -734,52 +733,53 @@ static pa_time_event* find_next_time_event(pa_mainloop *m) {
return n;
}
-static int calc_next_timeout(pa_mainloop *m) {
+static pa_usec_t calc_next_timeout(pa_mainloop *m) {
pa_time_event *t;
- struct timeval now;
- pa_usec_t usec;
+ pa_usec_t clock_now;
- if (!m->n_enabled_time_events)
- return -1;
+ if (m->n_enabled_time_events <= 0)
+ return PA_USEC_INVALID;
- t = find_next_time_event(m);
- pa_assert(t);
+ pa_assert_se(t = find_next_time_event(m));
- if (t->timeval.tv_sec <= 0)
+ if (t->time <= 0)
return 0;
- pa_gettimeofday(&now);
+ clock_now = pa_rtclock_now();
- if (pa_timeval_cmp(&t->timeval, &now) <= 0)
+ if (t->time <= clock_now)
return 0;
- usec = pa_timeval_diff(&t->timeval, &now);
- return (int) (usec / 1000);
+ return t->time - clock_now;
}
-static int dispatch_timeout(pa_mainloop *m) {
+static unsigned dispatch_timeout(pa_mainloop *m) {
pa_time_event *e;
- struct timeval now;
- int r = 0;
+ pa_usec_t now;
+ unsigned r = 0;
pa_assert(m);
if (m->n_enabled_time_events <= 0)
return 0;
- pa_gettimeofday(&now);
+ now = pa_rtclock_now();
+
+ PA_LLIST_FOREACH(e, m->time_events) {
- for (e = m->time_events; e && !m->quit; e = e->next) {
+ if (m->quit)
+ break;
if (e->dead || !e->enabled)
continue;
- if (pa_timeval_cmp(&e->timeval, &now) <= 0) {
+ if (e->time <= now) {
+ struct timeval tv;
pa_assert(e->callback);
/* Disable time event */
mainloop_time_restart(e, NULL);
- e->callback(&m->api, e, &e->timeval, e->userdata);
+ e->callback(&m->api, e, pa_timeval_rtstore(&tv, e->time, e->use_rtclock), e->userdata);
r++;
}
@@ -807,7 +807,8 @@ static void clear_wakeup(pa_mainloop *m) {
return;
if (m->wakeup_requested) {
- while (pa_read(m->wakeup_pipe[0], &c, sizeof(c), &m->wakeup_pipe_type) == sizeof(c));
+ while (pa_read(m->wakeup_pipe[0], &c, sizeof(c), &m->wakeup_pipe_type) == sizeof(c))
+ ;
m->wakeup_requested = 0;
}
}
@@ -823,12 +824,17 @@ int pa_mainloop_prepare(pa_mainloop *m, int timeout) {
goto quit;
if (m->n_enabled_defer_events <= 0) {
+
if (m->rebuild_pollfds)
rebuild_pollfds(m);
m->prepared_timeout = calc_next_timeout(m);
- if (timeout >= 0 && (timeout < m->prepared_timeout || m->prepared_timeout < 0))
- m->prepared_timeout = timeout;
+ if (timeout >= 0) {
+ uint64_t u = (uint64_t) timeout * PA_USEC_PER_MSEC;
+
+ if (u < m->prepared_timeout || m->prepared_timeout == PA_USEC_INVALID)
+ m->prepared_timeout = timeout;
+ }
}
m->state = STATE_PREPARED;
@@ -839,6 +845,18 @@ quit:
return -2;
}
+static int usec_to_timeout(pa_usec_t u) {
+ int timeout;
+
+ if (u == PA_USEC_INVALID)
+ return -1;
+
+ timeout = (u + PA_USEC_PER_MSEC - 1) / PA_USEC_PER_MSEC;
+ pa_assert(timeout >= 0);
+
+ return timeout;
+}
+
int pa_mainloop_poll(pa_mainloop *m) {
pa_assert(m);
pa_assert(m->state == STATE_PREPARED);
@@ -854,9 +872,24 @@ int pa_mainloop_poll(pa_mainloop *m) {
pa_assert(!m->rebuild_pollfds);
if (m->poll_func)
- m->poll_func_ret = m->poll_func(m->pollfds, m->n_pollfds, m->prepared_timeout, m->poll_func_userdata);
- else
- m->poll_func_ret = poll(m->pollfds, m->n_pollfds, m->prepared_timeout);
+ m->poll_func_ret = m->poll_func(
+ m->pollfds, m->n_pollfds,
+ usec_to_timeout(m->prepared_timeout),
+ m->poll_func_userdata);
+ else {
+#ifdef HAVE_PPOLL
+ struct timespec ts;
+
+ m->poll_func_ret = ppoll(
+ m->pollfds, m->n_pollfds,
+ m->prepared_timeout == PA_USEC_INVALID ? NULL : pa_timespec_store(&ts, m->prepared_timeout),
+ NULL);
+#else
+ m->poll_func_ret = pa_poll(
+ m->pollfds, m->n_pollfds,
+ usec_to_timeout(m->prepared_timeout));
+#endif
+ }
if (m->poll_func_ret < 0) {
if (errno == EINTR)
@@ -875,7 +908,7 @@ quit:
}
int pa_mainloop_dispatch(pa_mainloop *m) {
- int dispatched = 0;
+ unsigned dispatched = 0;
pa_assert(m);
pa_assert(m->state == STATE_POLLED);
@@ -901,7 +934,7 @@ int pa_mainloop_dispatch(pa_mainloop *m) {
m->state = STATE_PASSIVE;
- return dispatched;
+ return (int) dispatched;
quit:
m->state = STATE_QUIT;
@@ -910,6 +943,7 @@ quit:
int pa_mainloop_get_retval(pa_mainloop *m) {
pa_assert(m);
+
return m->retval;
}
@@ -938,7 +972,8 @@ quit:
int pa_mainloop_run(pa_mainloop *m, int *retval) {
int r;
- while ((r = pa_mainloop_iterate(m, 1, retval)) >= 0);
+ while ((r = pa_mainloop_iterate(m, 1, retval)) >= 0)
+ ;
if (r == -2)
return 1;
@@ -956,8 +991,9 @@ void pa_mainloop_quit(pa_mainloop *m, int retval) {
pa_mainloop_wakeup(m);
}
-pa_mainloop_api* pa_mainloop_get_api(pa_mainloop*m) {
+pa_mainloop_api* pa_mainloop_get_api(pa_mainloop *m) {
pa_assert(m);
+
return &m->api;
}
@@ -967,3 +1003,9 @@ void pa_mainloop_set_poll_func(pa_mainloop *m, pa_poll_func poll_func, void *use
m->poll_func = poll_func;
m->poll_func_userdata = userdata;
}
+
+pa_bool_t pa_mainloop_is_our_api(pa_mainloop_api *m) {
+ pa_assert(m);
+
+ return m->io_new == mainloop_io_new;
+}
diff --git a/src/pulse/mainloop.h b/src/pulse/mainloop.h
index 4a83ebe8..19b17fa6 100644
--- a/src/pulse/mainloop.h
+++ b/src/pulse/mainloop.h
@@ -71,7 +71,10 @@ struct pollfd;
* function. Using the routines defined herein you may create a simple
* main loop supporting the generic main loop abstraction layer as
* defined in \ref mainloop-api.h. This implementation is thread safe
- * as long as you access the main loop object from a single thread only.*/
+ * as long as you access the main loop object from a single thread only.
+ *
+ * See also \subpage mainloop
+ */
/** An opaque main loop object */
typedef struct pa_mainloop pa_mainloop;
@@ -108,7 +111,9 @@ int pa_mainloop_iterate(pa_mainloop *m, int block, int *retval);
/** Run unlimited iterations of the main loop object until the main loop's quit() routine is called. */
int pa_mainloop_run(pa_mainloop *m, int *retval);
-/** Return the abstract main loop abstraction layer vtable for this main loop. */
+/** Return the abstract main loop abstraction layer vtable for this
+ main loop. No need to free the API as it is owned by the loop
+ and is destroyed when the loop is freed. */
pa_mainloop_api* pa_mainloop_get_api(pa_mainloop*m);
/** Shutdown the main loop */
diff --git a/src/pulse/operation.h b/src/pulse/operation.h
index 7b0dabdd..b6b5691d 100644
--- a/src/pulse/operation.h
+++ b/src/pulse/operation.h
@@ -40,7 +40,11 @@ pa_operation *pa_operation_ref(pa_operation *o);
/** Decrease the reference count by one */
void pa_operation_unref(pa_operation *o);
-/** Cancel the operation. Beware! This will not necessarily cancel the execution of the operation on the server side. */
+/** Cancel the operation. Beware! This will not necessarily cancel the
+ * execution of the operation on the server side. However it will make
+ * sure that the callback associated with this operation will not be
+ * called anymore, effectively disabling the operation from the client
+ * side's view. */
void pa_operation_cancel(pa_operation *o);
/** Return the current status of the operation */
diff --git a/src/pulse/proplist.c b/src/pulse/proplist.c
index c904f533..75445e06 100644
--- a/src/pulse/proplist.c
+++ b/src/pulse/proplist.c
@@ -28,7 +28,6 @@
#include <pulse/xmalloc.h>
#include <pulse/utf8.h>
-#include <pulse/i18n.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/strbuf.h>
@@ -251,7 +250,7 @@ int pa_proplist_set(pa_proplist *p, const char *key, const void *data, size_t nb
pa_assert(p);
pa_assert(key);
- pa_assert(data);
+ pa_assert(data || nbytes == 0);
if (!property_name_valid(key))
return -1;
@@ -264,7 +263,8 @@ int pa_proplist_set(pa_proplist *p, const char *key, const void *data, size_t nb
pa_xfree(prop->value);
prop->value = pa_xmalloc(nbytes+1);
- memcpy(prop->value, data, nbytes);
+ if (nbytes > 0)
+ memcpy(prop->value, data, nbytes);
((char*) prop->value)[nbytes] = 0;
prop->nbytes = nbytes;
@@ -680,3 +680,32 @@ int pa_proplist_isempty(pa_proplist *p) {
return pa_hashmap_isempty(MAKE_HASHMAP(p));
}
+
+int pa_proplist_equal(pa_proplist *a, pa_proplist *b) {
+ const void *key = NULL;
+ struct property *a_prop = NULL;
+ struct property *b_prop = NULL;
+ void *state = NULL;
+
+ pa_assert(a);
+ pa_assert(b);
+
+ if (a == b)
+ return 1;
+
+ if (pa_proplist_size(a) != pa_proplist_size(b))
+ return 0;
+
+ while ((a_prop = pa_hashmap_iterate(MAKE_HASHMAP(a), &state, &key))) {
+ if (!(b_prop = pa_hashmap_get(MAKE_HASHMAP(b), key)))
+ return 0;
+
+ if (a_prop->nbytes != b_prop->nbytes)
+ return 0;
+
+ if (memcmp(a_prop->value, b_prop->value, a_prop->nbytes) != 0)
+ return 0;
+ }
+
+ return 1;
+}
diff --git a/src/pulse/proplist.h b/src/pulse/proplist.h
index 4c791dce..a641f248 100644
--- a/src/pulse/proplist.h
+++ b/src/pulse/proplist.h
@@ -59,9 +59,18 @@ PA_C_DECL_BEGIN
/** For streams: an XDG icon name for the media. e.g. "audio-x-mp3" */
#define PA_PROP_MEDIA_ICON_NAME "media.icon_name"
-/** For streams: logic role of this media. One of the strings "video", "music", "game", "event", "phone", "animation", "production", "a11y" */
+/** For streams: logic role of this media. One of the strings "video", "music", "game", "event", "phone", "animation", "production", "a11y", "test" */
#define PA_PROP_MEDIA_ROLE "media.role"
+/** For streams: the name of a filter that is desired, e.g. "echo-cancel" or "equalizer-sink". PulseAudio may choose to not apply the filter if it does not make sense (for example, applying echo-cancellation on a Bluetooth headset probably does not make sense. \since 1.0 */
+#define PA_PROP_FILTER_WANT "filter.want"
+
+/** For streams: the name of a filter that is desired, e.g. "echo-cancel" or "equalizer-sink". Differs from PA_PROP_FILTER_WANT in that it forces PulseAudio to apply the filter, regardless of whether PulseAudio thinks it makes sense to do so or not. If this is set, PA_PROP_FILTER_WANT is ignored. In other words, you almost certainly do not want to use this. \since 1.0 */
+#define PA_PROP_FILTER_APPLY "filter.apply"
+
+/** For streams: the name of a filter that should specifically suppressed (i.e. overrides PA_PROP_FILTER_WANT). Useful for the times that PA_PROP_FILTER_WANT is automatically added (e.g. echo-cancellation for phone streams when $VOIP_APP does it's own, internal AEC) \since 1.0 */
+#define PA_PROP_FILTER_SUPPRESS "filter.suppress"
+
/** For event sound streams: XDG event sound name. e.g. "message-new-email" (Event sound streams are those with media.role set to "event") */
#define PA_PROP_EVENT_ID "event.id"
@@ -97,6 +106,27 @@ PA_C_DECL_BEGIN
/** For streams that belong to a window on the screen: an XDG icon name for the window. e.g. "totem" */
#define PA_PROP_WINDOW_ICON_NAME "window.icon_name"
+/** For streams that belong to a window on the screen: absolute horizontal window position on the screen, integer formatted as text string. e.g. "865". \since 0.9.17 */
+#define PA_PROP_WINDOW_X "window.x"
+
+/** For streams that belong to a window on the screen: absolute vertical window position on the screen, integer formatted as text string. e.g. "343". \since 0.9.17 */
+#define PA_PROP_WINDOW_Y "window.y"
+
+/** For streams that belong to a window on the screen: window width on the screen, integer formatted as text string. e.g. "365". \since 0.9.17 */
+#define PA_PROP_WINDOW_WIDTH "window.width"
+
+/** For streams that belong to a window on the screen: window height on the screen, integer formatted as text string. e.g. "643". \since 0.9.17 */
+#define PA_PROP_WINDOW_HEIGHT "window.height"
+
+/** For streams that belong to a window on the screen: relative position of the window center on the screen, float formatted as text string, ranging from 0.0 (left side of the screen) to 1.0 (right side of the screen). e.g. "0.65". \since 0.9.17 */
+#define PA_PROP_WINDOW_HPOS "window.hpos"
+
+/** For streams that belong to a window on the screen: relative position of the window center on the screen, float formatted as text string, ranging from 0.0 (top of the screen) to 1.0 (bottom of the screen). e.g. "0.43". \since 0.9.17 */
+#define PA_PROP_WINDOW_VPOS "window.vpos"
+
+/** For streams that belong to a window on the screen: if the windowing system supports multiple desktops, a comma seperated list of indexes of the desktops this window is visible on. If this property is an empty string, it is visible on all desktops (i.e. 'sticky'). The first desktop is 0. e.g. "0,2,3" \since 0.9.18 */
+#define PA_PROP_WINDOW_DESKTOP "window.desktop"
+
/** For streams that belong to an X11 window on the screen: the X11 display string. e.g. ":0.0" */
#define PA_PROP_WINDOW_X11_DISPLAY "window.x11.display"
@@ -197,7 +227,7 @@ PA_C_DECL_BEGIN
/** For filter devices: master device id if applicable. */
#define PA_PROP_DEVICE_MASTER_DEVICE "device.master_device"
-/** For devices: buffer size in bytes, integer formatted as string.. */
+/** For devices: buffer size in bytes, integer formatted as string. */
#define PA_PROP_DEVICE_BUFFERING_BUFFER_SIZE "device.buffering.buffer_size"
/** For devices: fragment size in bytes, integer formatted as string. */
@@ -206,6 +236,9 @@ PA_C_DECL_BEGIN
/** For devices: profile identifier for the profile this devices is in. e.g. "analog-stereo", "analog-surround-40", "iec958-stereo", ...*/
#define PA_PROP_DEVICE_PROFILE_NAME "device.profile.name"
+/** For devices: intended use. A comma seperated list of roles (see PA_PROP_MEDIA_ROLE) this device is particularly well suited for, due to latency, quality or form factor. \since 0.9.16 */
+#define PA_PROP_DEVICE_INTENDED_ROLES "device.intended_roles"
+
/** For devices: human readable one-line description of the profile this device is in. e.g. "Analog Stereo", ... */
#define PA_PROP_DEVICE_PROFILE_DESCRIPTION "device.profile.description"
@@ -221,6 +254,18 @@ PA_C_DECL_BEGIN
/** For modules: a version string for the module. e.g. "0.9.15" */
#define PA_PROP_MODULE_VERSION "module.version"
+/** For PCM formats: the sample format used as returned by pa_sample_format_to_string() \since 1.0 */
+#define PA_PROP_FORMAT_SAMPLE_FORMAT "format.sample_format"
+
+/** For all formats: the sample rate (unsigned integer) \since 1.0 */
+#define PA_PROP_FORMAT_RATE "format.rate"
+
+/** For all formats: the number of channels (unsigned integer) \since 1.0 */
+#define PA_PROP_FORMAT_CHANNELS "format.channels"
+
+/** For PCM formats: the channel map of the stream as returned by pa_channel_map_snprint() \since 1.0 */
+#define PA_PROP_FORMAT_CHANNEL_MAP "format.channel_map"
+
/** A property list object. Basically a dictionary with ASCII strings
* as keys and arbitrary data as values. \since 0.9.11 */
typedef struct pa_proplist pa_proplist;
@@ -301,7 +346,7 @@ void pa_proplist_update(pa_proplist *p, pa_update_mode_t mode, pa_proplist *othe
* specified key name. \since 0.9.11 */
int pa_proplist_unset(pa_proplist *p, const char *key);
-/** Similar to pa_proplist_remove() but takes an array of keys to
+/** Similar to pa_proplist_unset() but takes an array of keys to
* remove. The array should be terminated by a NULL pointer. Return -1
* on failure, otherwise the number of entries actually removed (which
* might even be 0, if there where no matching entries to
@@ -334,7 +379,7 @@ char *pa_proplist_to_string_sep(pa_proplist *p, const char *sep);
* readable string. \since 0.9.15 */
pa_proplist *pa_proplist_from_string(const char *str);
- /** Returns 1 if an entry for the specified key is existant in the
+/** Returns 1 if an entry for the specified key is existant in the
* property list. \since 0.9.11 */
int pa_proplist_contains(pa_proplist *p, const char *key);
@@ -351,6 +396,10 @@ unsigned pa_proplist_size(pa_proplist *t);
/** Returns 0 when the proplist is empty, positive otherwise \since 0.9.15 */
int pa_proplist_isempty(pa_proplist *t);
+/** Return non-zero when a and b have the same keys and values.
+ * \since 0.9.16 */
+int pa_proplist_equal(pa_proplist *a, pa_proplist *b);
+
PA_C_DECL_END
#endif
diff --git a/src/pulse/pulseaudio.h b/src/pulse/pulseaudio.h
index aa369e69..a399ed96 100644
--- a/src/pulse/pulseaudio.h
+++ b/src/pulse/pulseaudio.h
@@ -25,6 +25,7 @@
#include <pulse/mainloop-api.h>
#include <pulse/sample.h>
+#include <pulse/format.h>
#include <pulse/def.h>
#include <pulse/context.h>
#include <pulse/stream.h>
@@ -44,15 +45,17 @@
#include <pulse/util.h>
#include <pulse/timeval.h>
#include <pulse/proplist.h>
+#include <pulse/rtclock.h>
/** \file
- * Include all libpulse header files at once. The following
- * files are included: \ref mainloop-api.h, \ref sample.h, \ref def.h,
- * \ref context.h, \ref stream.h, \ref introspect.h, \ref subscribe.h,
- * \ref scache.h, \ref version.h, \ref error.h, \ref channelmap.h,
- * \ref operation.h,\ref volume.h, \ref xmalloc.h, \ref utf8.h, \ref
- * thread-mainloop.h, \ref mainloop.h, \ref util.h, \ref proplist.h, \ref timeval.h and
- * \ref mainloop-signal.h at once */
+ * Include all libpulse header files at once. The following files are
+ * included: \ref mainloop-api.h, \ref sample.h, \ref def.h, \ref
+ * context.h, \ref stream.h, \ref introspect.h, \ref subscribe.h, \ref
+ * scache.h, \ref version.h, \ref error.h, \ref channelmap.h, \ref
+ * operation.h,\ref volume.h, \ref xmalloc.h, \ref utf8.h, \ref
+ * thread-mainloop.h, \ref mainloop.h, \ref util.h, \ref proplist.h,
+ * \ref timeval.h, \ref rtclock.h and \ref mainloop-signal.h at
+ * once */
/** \mainpage
*
diff --git a/src/pulsecore/rtsig.h b/src/pulse/rtclock.c
index e414122d..dd1b6009 100644
--- a/src/pulsecore/rtsig.h
+++ b/src/pulse/rtclock.c
@@ -1,6 +1,3 @@
-#ifndef foopulsertsighfoo
-#define foopulsertsighfoo
-
/***
This file is part of PulseAudio.
@@ -22,18 +19,20 @@
USA.
***/
-/* Return the next unused POSIX Realtime signals */
-int pa_rtsig_get(void);
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
-/* If not called before in the current thread, return the next unused
- * rtsig, and install it in a TLS region and give it up automatically
- * when the thread shuts down */
-int pa_rtsig_get_for_thread(void);
+#include <sys/time.h>
-/* Give an rtsig back. */
-void pa_rtsig_put(int sig);
+#include <pulse/timeval.h>
-/* Block all RT signals */
-void pa_rtsig_configure(int start, int end);
+#include <pulsecore/core-rtclock.h>
-#endif
+#include "rtclock.h"
+
+pa_usec_t pa_rtclock_now(void) {
+ struct timeval tv;
+
+ return pa_timeval_load(pa_rtclock_get(&tv));
+}
diff --git a/src/pulse/rtclock.h b/src/pulse/rtclock.h
new file mode 100644
index 00000000..cba20e31
--- /dev/null
+++ b/src/pulse/rtclock.h
@@ -0,0 +1,40 @@
+#ifndef foortclockfoo
+#define foortclockfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2009 Lennart Poettering
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of the
+ License, or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <pulse/cdecl.h>
+#include <pulse/sample.h>
+
+/** \file
+ * Monotonic clock utilities. */
+
+PA_C_DECL_BEGIN
+
+/** Return the current monotonic system time in usec, if such a clock
+ * is available. If it is not available this will return the
+ * wallclock time instead. \since 0.9.16 */
+pa_usec_t pa_rtclock_now(void);
+
+PA_C_DECL_END
+
+#endif
diff --git a/src/pulse/sample.c b/src/pulse/sample.c
index 0f19f8eb..8365e93e 100644
--- a/src/pulse/sample.c
+++ b/src/pulse/sample.c
@@ -25,7 +25,6 @@
#endif
#include <stdio.h>
-#include <math.h>
#include <string.h>
#include <pulse/timeval.h>
@@ -36,28 +35,27 @@
#include "sample.h"
-size_t pa_sample_size_of_format(pa_sample_format_t f) {
-
- static const size_t table[] = {
- [PA_SAMPLE_U8] = 1,
- [PA_SAMPLE_ULAW] = 1,
- [PA_SAMPLE_ALAW] = 1,
- [PA_SAMPLE_S16LE] = 2,
- [PA_SAMPLE_S16BE] = 2,
- [PA_SAMPLE_FLOAT32LE] = 4,
- [PA_SAMPLE_FLOAT32BE] = 4,
- [PA_SAMPLE_S32LE] = 4,
- [PA_SAMPLE_S32BE] = 4,
- [PA_SAMPLE_S24LE] = 3,
- [PA_SAMPLE_S24BE] = 3,
- [PA_SAMPLE_S24_32LE] = 4,
- [PA_SAMPLE_S24_32BE] = 4
- };
+static const size_t size_table[] = {
+ [PA_SAMPLE_U8] = 1,
+ [PA_SAMPLE_ULAW] = 1,
+ [PA_SAMPLE_ALAW] = 1,
+ [PA_SAMPLE_S16LE] = 2,
+ [PA_SAMPLE_S16BE] = 2,
+ [PA_SAMPLE_FLOAT32LE] = 4,
+ [PA_SAMPLE_FLOAT32BE] = 4,
+ [PA_SAMPLE_S32LE] = 4,
+ [PA_SAMPLE_S32BE] = 4,
+ [PA_SAMPLE_S24LE] = 3,
+ [PA_SAMPLE_S24BE] = 3,
+ [PA_SAMPLE_S24_32LE] = 4,
+ [PA_SAMPLE_S24_32BE] = 4
+};
+size_t pa_sample_size_of_format(pa_sample_format_t f) {
pa_assert(f >= 0);
pa_assert(f < PA_SAMPLE_MAX);
- return table[f];
+ return size_table[f];
}
size_t pa_sample_size(const pa_sample_spec *spec) {
@@ -65,35 +63,35 @@ size_t pa_sample_size(const pa_sample_spec *spec) {
pa_assert(spec);
pa_return_val_if_fail(pa_sample_spec_valid(spec), 0);
- return pa_sample_size_of_format(spec->format);
+ return size_table[spec->format];
}
size_t pa_frame_size(const pa_sample_spec *spec) {
pa_assert(spec);
pa_return_val_if_fail(pa_sample_spec_valid(spec), 0);
- return pa_sample_size(spec) * spec->channels;
+ return size_table[spec->format] * spec->channels;
}
size_t pa_bytes_per_second(const pa_sample_spec *spec) {
pa_assert(spec);
pa_return_val_if_fail(pa_sample_spec_valid(spec), 0);
- return spec->rate*pa_frame_size(spec);
+ return spec->rate * size_table[spec->format] * spec->channels;
}
pa_usec_t pa_bytes_to_usec(uint64_t length, const pa_sample_spec *spec) {
pa_assert(spec);
pa_return_val_if_fail(pa_sample_spec_valid(spec), 0);
- return (((pa_usec_t) (length / pa_frame_size(spec)) * PA_USEC_PER_SEC) / spec->rate);
+ return (((pa_usec_t) (length / (size_table[spec->format] * spec->channels)) * PA_USEC_PER_SEC) / spec->rate);
}
size_t pa_usec_to_bytes(pa_usec_t t, const pa_sample_spec *spec) {
pa_assert(spec);
pa_return_val_if_fail(pa_sample_spec_valid(spec), 0);
- return (size_t) (((t * spec->rate) / PA_USEC_PER_SEC)) * pa_frame_size(spec);
+ return (size_t) (((t * spec->rate) / PA_USEC_PER_SEC)) * (size_table[spec->format] * spec->channels);
}
pa_sample_spec* pa_sample_spec_init(pa_sample_spec *spec) {
@@ -109,12 +107,12 @@ pa_sample_spec* pa_sample_spec_init(pa_sample_spec *spec) {
int pa_sample_spec_valid(const pa_sample_spec *spec) {
pa_assert(spec);
- if (spec->rate <= 0 ||
+ if (PA_UNLIKELY (spec->rate <= 0 ||
spec->rate > PA_RATE_MAX ||
spec->channels <= 0 ||
spec->channels > PA_CHANNELS_MAX ||
spec->format >= PA_SAMPLE_MAX ||
- spec->format < 0)
+ spec->format < 0))
return 0;
return 1;
@@ -125,6 +123,10 @@ int pa_sample_spec_equal(const pa_sample_spec*a, const pa_sample_spec*b) {
pa_assert(b);
pa_return_val_if_fail(pa_sample_spec_valid(a), 0);
+
+ if (PA_UNLIKELY(a == b))
+ return 1;
+
pa_return_val_if_fail(pa_sample_spec_valid(b), 0);
return
@@ -239,7 +241,7 @@ pa_sample_format_t pa_parse_sample_format(const char *format) {
else if (strcasecmp(format, "s24-32re") == 0)
return PA_SAMPLE_S24_32RE;
- return -1;
+ return PA_SAMPLE_INVALID;
}
int pa_sample_format_is_le(pa_sample_format_t f) {
diff --git a/src/pulse/sample.h b/src/pulse/sample.h
index 53d7dea3..8d9ef1d0 100644
--- a/src/pulse/sample.h
+++ b/src/pulse/sample.h
@@ -26,7 +26,6 @@
#include <inttypes.h>
#include <sys/types.h>
#include <sys/param.h>
-#include <math.h>
#include <pulse/gccmacro.h>
#include <pulse/cdecl.h>
@@ -105,7 +104,10 @@
*/
/** \file
- * Constants and routines for sample type handling */
+ * Constants and routines for sample type handling
+ *
+ * See also \subpage sample
+ */
PA_C_DECL_BEGIN
@@ -302,6 +304,13 @@ pa_sample_format_t pa_parse_sample_format(const char *format) PA_GCC_PURE;
/** Pretty print a sample type specification to a string */
char* pa_sample_spec_snprint(char *s, size_t l, const pa_sample_spec *spec);
+/** Maximum required string length for pa_bytes_snprint(). Please note
+ * that this value can change with any release without warning and
+ * without being considered API or ABI breakage. You should not use
+ * this definition anywhere where it might become part of an
+ * ABI. \since 0.9.16 */
+#define PA_BYTES_SNPRINT_MAX 11
+
/** Pretty print a byte size value. (i.e. "2.5 MiB") */
char* pa_bytes_snprint(char *s, size_t l, unsigned v);
diff --git a/src/pulse/scache.c b/src/pulse/scache.c
index 77f60d72..3fad82a1 100644
--- a/src/pulse/scache.c
+++ b/src/pulse/scache.c
@@ -25,16 +25,15 @@
#include <stdlib.h>
#include <stdio.h>
-#include <string.h>
#include <pulse/utf8.h>
+#include <pulse/fork-detect.h>
#include <pulsecore/pstream-util.h>
#include <pulsecore/macro.h>
#include <pulsecore/proplist-util.h>
#include "internal.h"
-
#include "scache.h"
int pa_stream_connect_upload(pa_stream *s, size_t length) {
@@ -45,9 +44,11 @@ int pa_stream_connect_upload(pa_stream *s, size_t length) {
pa_assert(s);
pa_assert(PA_REFCNT_VALUE(s) >= 1);
+ PA_CHECK_VALIDITY(s->context, !pa_detect_fork(), PA_ERR_FORKED);
PA_CHECK_VALIDITY(s->context, s->state == PA_STREAM_UNCONNECTED, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY(s->context, length > 0, PA_ERR_INVALID);
PA_CHECK_VALIDITY(s->context, length == (size_t) (uint32_t) length, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY(s->context, s->context->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
if (!(name = pa_proplist_gets(s->proplist, PA_PROP_EVENT_ID)))
name = pa_proplist_gets(s->proplist, PA_PROP_MEDIA_NAME);
@@ -85,6 +86,7 @@ int pa_stream_finish_upload(pa_stream *s) {
pa_assert(s);
pa_assert(PA_REFCNT_VALUE(s) >= 1);
+ PA_CHECK_VALIDITY(s->context, !pa_detect_fork(), PA_ERR_FORKED);
PA_CHECK_VALIDITY(s->context, s->channel_valid, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY(s->context, s->context->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
@@ -174,6 +176,7 @@ pa_operation *pa_context_play_sample(pa_context *c, const char *name, const char
pa_assert(c);
pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(c, name && *name, PA_ERR_INVALID);
PA_CHECK_VALIDITY_RETURN_NULL(c, !dev || *dev, PA_ERR_INVALID);
@@ -187,7 +190,7 @@ pa_operation *pa_context_play_sample(pa_context *c, const char *name, const char
pa_tagstruct_putu32(t, PA_INVALID_INDEX);
pa_tagstruct_puts(t, dev);
- if (volume == (pa_volume_t) -1 && c->version < 15)
+ if (!PA_VOLUME_IS_VALID(volume) && c->version < 15)
volume = PA_VOLUME_NORM;
pa_tagstruct_putu32(t, volume);
@@ -213,10 +216,10 @@ pa_operation *pa_context_play_sample_with_proplist(pa_context *c, const char *na
pa_assert(c);
pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(c, name && *name, PA_ERR_INVALID);
PA_CHECK_VALIDITY_RETURN_NULL(c, !dev || *dev, PA_ERR_INVALID);
- PA_CHECK_VALIDITY_RETURN_NULL(c, p, PA_ERR_INVALID);
PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 13, PA_ERR_NOTSUPPORTED);
o = pa_operation_new(c, NULL, (pa_operation_cb_t) cb, userdata);
@@ -228,12 +231,19 @@ pa_operation *pa_context_play_sample_with_proplist(pa_context *c, const char *na
pa_tagstruct_putu32(t, PA_INVALID_INDEX);
pa_tagstruct_puts(t, dev);
- if (volume == (pa_volume_t) -1 && c->version < 15)
+ if (!PA_VOLUME_IS_VALID(volume) && c->version < 15)
volume = PA_VOLUME_NORM;
pa_tagstruct_putu32(t, volume);
pa_tagstruct_puts(t, name);
- pa_tagstruct_put_proplist(t, p);
+
+ if (p)
+ pa_tagstruct_put_proplist(t, p);
+ else {
+ p = pa_proplist_new();
+ pa_tagstruct_put_proplist(t, p);
+ pa_proplist_free(p);
+ }
pa_pstream_send_tagstruct(c->pstream, t);
pa_pdispatch_register_reply(c->pdispatch, tag, DEFAULT_TIMEOUT, play_sample_with_proplist_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
@@ -249,6 +259,7 @@ pa_operation* pa_context_remove_sample(pa_context *c, const char *name, pa_conte
pa_assert(c);
pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
PA_CHECK_VALIDITY_RETURN_NULL(c, c->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(c, name && *name, PA_ERR_INVALID);
diff --git a/src/pulse/scache.h b/src/pulse/scache.h
index cd579d2e..b4fcbd07 100644
--- a/src/pulse/scache.h
+++ b/src/pulse/scache.h
@@ -74,7 +74,10 @@
*/
/** \file
- * All sample cache related routines */
+ * All sample cache related routines
+ *
+ * See also \subpage scache
+ */
PA_C_DECL_BEGIN
@@ -101,7 +104,7 @@ pa_operation* pa_context_play_sample(
pa_context *c /**< Context */,
const char *name /**< Name of the sample to play */,
const char *dev /**< Sink to play this sample on */,
- pa_volume_t volume /**< Volume to play this sample with. Starting with 0.9.15 you may pass here (pa_volume_t) -1 which will leave the decision about the volume to the server side which is a good idea. */ ,
+ pa_volume_t volume /**< Volume to play this sample with. Starting with 0.9.15 you may pass here PA_VOLUME_INVALID which will leave the decision about the volume to the server side which is a good idea. */ ,
pa_context_success_cb_t cb /**< Call this function after successfully starting playback, or NULL */,
void *userdata /**< Userdata to pass to the callback */);
@@ -113,7 +116,7 @@ pa_operation* pa_context_play_sample_with_proplist(
pa_context *c /**< Context */,
const char *name /**< Name of the sample to play */,
const char *dev /**< Sink to play this sample on */,
- pa_volume_t volume /**< Volume to play this sample with. Starting with 0.9.15 you may pass here (pa_volume_t) -1 which will leave the decision about the volume to the server side which is a good idea. */ ,
+ pa_volume_t volume /**< Volume to play this sample with. Starting with 0.9.15 you may pass here PA_VOLUME_INVALID which will leave the decision about the volume to the server side which is a good idea. */ ,
pa_proplist *proplist /**< Property list for this sound. The property list of the cached entry will be merged into this property list */,
pa_context_play_sample_cb_t cb /**< Call this function after successfully starting playback, or NULL */,
void *userdata /**< Userdata to pass to the callback */);
diff --git a/src/pulse/simple.c b/src/pulse/simple.c
index f4481fc3..3524296a 100644
--- a/src/pulse/simple.c
+++ b/src/pulse/simple.c
@@ -32,7 +32,6 @@
#include <pulse/thread-mainloop.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/native-common.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
@@ -70,8 +69,8 @@ struct pa_simple {
#define CHECK_DEAD_GOTO(p, rerror, label) \
do { \
- if (!(p)->context || pa_context_get_state((p)->context) != PA_CONTEXT_READY || \
- !(p)->stream || pa_stream_get_state((p)->stream) != PA_STREAM_READY) { \
+ if (!(p)->context || !PA_CONTEXT_IS_GOOD(pa_context_get_state((p)->context)) || \
+ !(p)->stream || !PA_STREAM_IS_GOOD(pa_stream_get_state((p)->stream))) { \
if (((p)->context && pa_context_get_state((p)->context) == PA_CONTEXT_FAILED) || \
((p)->stream && pa_stream_get_state((p)->stream) == PA_STREAM_FAILED)) { \
if (rerror) \
@@ -157,12 +156,8 @@ pa_simple* pa_simple_new(
CHECK_VALIDITY_RETURN_ANY(rerror, ss && pa_sample_spec_valid(ss), PA_ERR_INVALID, NULL);
CHECK_VALIDITY_RETURN_ANY(rerror, !map || (pa_channel_map_valid(map) && map->channels == ss->channels), PA_ERR_INVALID, NULL)
- p = pa_xnew(pa_simple, 1);
- p->context = NULL;
- p->stream = NULL;
+ p = pa_xnew0(pa_simple, 1);
p->direction = dir;
- p->read_data = NULL;
- p->read_index = p->read_length = 0;
if (!(p->mainloop = pa_threaded_mainloop_new()))
goto fail;
@@ -182,12 +177,21 @@ pa_simple* pa_simple_new(
if (pa_threaded_mainloop_start(p->mainloop) < 0)
goto unlock_and_fail;
- /* Wait until the context is ready */
- pa_threaded_mainloop_wait(p->mainloop);
+ for (;;) {
+ pa_context_state_t state;
- if (pa_context_get_state(p->context) != PA_CONTEXT_READY) {
- error = pa_context_errno(p->context);
- goto unlock_and_fail;
+ state = pa_context_get_state(p->context);
+
+ if (state == PA_CONTEXT_READY)
+ break;
+
+ if (!PA_CONTEXT_IS_GOOD(state)) {
+ error = pa_context_errno(p->context);
+ goto unlock_and_fail;
+ }
+
+ /* Wait until the context is ready */
+ pa_threaded_mainloop_wait(p->mainloop);
}
if (!(p->stream = pa_stream_new(p->context, stream_name, ss, map))) {
@@ -216,13 +220,21 @@ pa_simple* pa_simple_new(
goto unlock_and_fail;
}
- /* Wait until the stream is ready */
- pa_threaded_mainloop_wait(p->mainloop);
+ for (;;) {
+ pa_stream_state_t state;
- /* Wait until the stream is ready */
- if (pa_stream_get_state(p->stream) != PA_STREAM_READY) {
- error = pa_context_errno(p->context);
- goto unlock_and_fail;
+ state = pa_stream_get_state(p->stream);
+
+ if (state == PA_STREAM_READY)
+ break;
+
+ if (!PA_STREAM_IS_GOOD(state)) {
+ error = pa_context_errno(p->context);
+ goto unlock_and_fail;
+ }
+
+ /* Wait until the stream is ready */
+ pa_threaded_mainloop_wait(p->mainloop);
}
pa_threaded_mainloop_unlock(p->mainloop);
@@ -248,8 +260,10 @@ void pa_simple_free(pa_simple *s) {
if (s->stream)
pa_stream_unref(s->stream);
- if (s->context)
+ if (s->context) {
+ pa_context_disconnect(s->context);
pa_context_unref(s->context);
+ }
if (s->mainloop)
pa_threaded_mainloop_free(s->mainloop);
@@ -261,7 +275,8 @@ int pa_simple_write(pa_simple *p, const void*data, size_t length, int *rerror) {
pa_assert(p);
CHECK_VALIDITY_RETURN_ANY(rerror, p->direction == PA_STREAM_PLAYBACK, PA_ERR_BADSTATE, -1);
- CHECK_VALIDITY_RETURN_ANY(rerror, data && length, PA_ERR_INVALID, -1);
+ CHECK_VALIDITY_RETURN_ANY(rerror, data, PA_ERR_INVALID, -1);
+ CHECK_VALIDITY_RETURN_ANY(rerror, length > 0, PA_ERR_INVALID, -1);
pa_threaded_mainloop_lock(p->mainloop);
@@ -300,7 +315,8 @@ int pa_simple_read(pa_simple *p, void*data, size_t length, int *rerror) {
pa_assert(p);
CHECK_VALIDITY_RETURN_ANY(rerror, p->direction == PA_STREAM_RECORD, PA_ERR_BADSTATE, -1);
- CHECK_VALIDITY_RETURN_ANY(rerror, data && length, PA_ERR_INVALID, -1);
+ CHECK_VALIDITY_RETURN_ANY(rerror, data, PA_ERR_INVALID, -1);
+ CHECK_VALIDITY_RETURN_ANY(rerror, length > 0, PA_ERR_INVALID, -1);
pa_threaded_mainloop_lock(p->mainloop);
@@ -375,7 +391,7 @@ int pa_simple_drain(pa_simple *p, int *rerror) {
CHECK_SUCCESS_GOTO(p, rerror, o, unlock_and_fail);
p->operation_success = 0;
- while (pa_operation_get_state(o) != PA_OPERATION_DONE) {
+ while (pa_operation_get_state(o) == PA_OPERATION_RUNNING) {
pa_threaded_mainloop_wait(p->mainloop);
CHECK_DEAD_GOTO(p, rerror, unlock_and_fail);
}
@@ -411,7 +427,7 @@ int pa_simple_flush(pa_simple *p, int *rerror) {
CHECK_SUCCESS_GOTO(p, rerror, o, unlock_and_fail);
p->operation_success = 0;
- while (pa_operation_get_state(o) != PA_OPERATION_DONE) {
+ while (pa_operation_get_state(o) == PA_OPERATION_RUNNING) {
pa_threaded_mainloop_wait(p->mainloop);
CHECK_DEAD_GOTO(p, rerror, unlock_and_fail);
}
diff --git a/src/pulse/simple.h b/src/pulse/simple.h
index 6f1ba414..ecffe4fa 100644
--- a/src/pulse/simple.h
+++ b/src/pulse/simple.h
@@ -82,8 +82,8 @@
*
* \li pa_simple_drain() - Will wait for all sent data to finish playing.
* \li pa_simple_flush() - Will throw away all data currently in buffers.
- * \li pa_simple_get_playback_latency() - Will return the total latency of
- * the playback pipeline.
+ * \li pa_simple_get_latency() - Will return the total latency of
+ * the playback pipeline.
*
* \section cleanup_sec Cleanup
*
@@ -98,7 +98,10 @@
/** \file
* A simple but limited synchronous playback and recording
* API. This is a synchronous, simplified wrapper around the standard
- * asynchronous API. */
+ * asynchronous API.
+ *
+ * See also \subpage simple
+ */
/** \example pacat-simple.c
* A simple playback tool using the simple API */
@@ -140,7 +143,7 @@ int pa_simple_read(pa_simple *s, void*data, size_t bytes, int *error);
/** Return the playback latency. */
pa_usec_t pa_simple_get_latency(pa_simple *s, int *error);
-/** Flush the playback buffer. */
+/** Flush the playback buffer. This discards any audio in the buffer. */
int pa_simple_flush(pa_simple *s, int *error);
PA_C_DECL_END
diff --git a/src/pulse/stream.c b/src/pulse/stream.c
index 339a89e5..373bc346 100644
--- a/src/pulse/stream.c
+++ b/src/pulse/stream.c
@@ -30,16 +30,19 @@
#include <pulse/def.h>
#include <pulse/timeval.h>
+#include <pulse/rtclock.h>
#include <pulse/xmalloc.h>
+#include <pulse/fork-detect.h>
#include <pulsecore/pstream-util.h>
#include <pulsecore/log.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/macro.h>
-#include <pulsecore/rtclock.h>
+#include <pulsecore/core-rtclock.h>
+#include <pulsecore/core-util.h>
-#include "fork-detect.h"
#include "internal.h"
+#include "stream.h"
#define AUTO_TIMING_INTERVAL_START_USEC (10*PA_USEC_PER_MSEC)
#define AUTO_TIMING_INTERVAL_END_USEC (1500*PA_USEC_PER_MSEC)
@@ -77,31 +80,26 @@ static void reset_callbacks(pa_stream *s) {
s->buffer_attr_userdata = NULL;
}
-pa_stream *pa_stream_new_with_proplist(
+static pa_stream *pa_stream_new_with_proplist_internal(
pa_context *c,
const char *name,
const pa_sample_spec *ss,
const pa_channel_map *map,
+ pa_format_info * const *formats,
+ unsigned int n_formats,
pa_proplist *p) {
pa_stream *s;
- int i;
- pa_channel_map tmap;
+ unsigned int i;
pa_assert(c);
pa_assert(PA_REFCNT_VALUE(c) >= 1);
+ pa_assert((ss == NULL && map == NULL) || (formats == NULL && n_formats == 0));
+ pa_assert(n_formats < PA_MAX_FORMATS);
PA_CHECK_VALIDITY_RETURN_NULL(c, !pa_detect_fork(), PA_ERR_FORKED);
- PA_CHECK_VALIDITY_RETURN_NULL(c, ss && pa_sample_spec_valid(ss), PA_ERR_INVALID);
- PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 12 || (ss->format != PA_SAMPLE_S32LE && ss->format != PA_SAMPLE_S32BE), PA_ERR_NOTSUPPORTED);
- PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 15 || (ss->format != PA_SAMPLE_S24LE && ss->format != PA_SAMPLE_S24BE), PA_ERR_NOTSUPPORTED);
- PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 15 || (ss->format != PA_SAMPLE_S24_32LE && ss->format != PA_SAMPLE_S24_32BE), PA_ERR_NOTSUPPORTED);
- PA_CHECK_VALIDITY_RETURN_NULL(c, !map || (pa_channel_map_valid(map) && map->channels == ss->channels), PA_ERR_INVALID);
PA_CHECK_VALIDITY_RETURN_NULL(c, name || (p && pa_proplist_contains(p, PA_PROP_MEDIA_NAME)), PA_ERR_INVALID);
- if (!map)
- PA_CHECK_VALIDITY_RETURN_NULL(c, map = pa_channel_map_init_auto(&tmap, ss->channels, PA_CHANNEL_MAP_DEFAULT), PA_ERR_INVALID);
-
s = pa_xnew(pa_stream, 1);
PA_REFCNT_INIT(s);
s->context = c;
@@ -111,8 +109,25 @@ pa_stream *pa_stream_new_with_proplist(
s->state = PA_STREAM_UNCONNECTED;
s->flags = 0;
- s->sample_spec = *ss;
- s->channel_map = *map;
+ if (ss)
+ s->sample_spec = *ss;
+ else
+ s->sample_spec.format = PA_SAMPLE_INVALID;
+
+ if (map)
+ s->channel_map = *map;
+ else
+ pa_channel_map_init(&s->channel_map);
+
+ s->n_formats = 0;
+ if (formats) {
+ s->n_formats = n_formats;
+ for (i = 0; i < n_formats; i++)
+ s->req_formats[i] = pa_format_info_copy(formats[i]);
+ }
+
+ /* We'll get the final negotiated format after connecting */
+ s->format = NULL;
s->direct_on_input = PA_INVALID_INDEX;
@@ -133,7 +148,18 @@ pa_stream *pa_stream_new_with_proplist(
* what older PA versions provided. */
s->buffer_attr.maxlength = (uint32_t) -1;
- s->buffer_attr.tlength = (uint32_t) pa_usec_to_bytes(250*PA_USEC_PER_MSEC, ss); /* 250ms of buffering */
+ if (ss)
+ s->buffer_attr.tlength = (uint32_t) pa_usec_to_bytes(250*PA_USEC_PER_MSEC, ss); /* 250ms of buffering */
+ else {
+ /* FIXME: We assume a worst-case compressed format corresponding to
+ * 48000 Hz, 2 ch, S16 PCM, but this can very well be incorrect */
+ pa_sample_spec tmp_ss = {
+ .format = PA_SAMPLE_S16NE,
+ .rate = 48000,
+ .channels = 2,
+ };
+ s->buffer_attr.tlength = (uint32_t) pa_usec_to_bytes(250*PA_USEC_PER_MSEC, &tmp_ss); /* 250ms of buffering */
+ }
s->buffer_attr.minreq = (uint32_t) -1;
s->buffer_attr.prebuf = (uint32_t) -1;
s->buffer_attr.fragsize = (uint32_t) -1;
@@ -143,12 +169,13 @@ pa_stream *pa_stream_new_with_proplist(
s->suspended = FALSE;
s->corked = FALSE;
+ s->write_memblock = NULL;
+ s->write_data = NULL;
+
pa_memchunk_reset(&s->peek_memchunk);
s->peek_data = NULL;
-
s->record_memblockq = NULL;
-
memset(&s->timing_info, 0, sizeof(s->timing_info));
s->timing_info_valid = FALSE;
@@ -175,6 +202,39 @@ pa_stream *pa_stream_new_with_proplist(
return s;
}
+pa_stream *pa_stream_new_with_proplist(
+ pa_context *c,
+ const char *name,
+ const pa_sample_spec *ss,
+ const pa_channel_map *map,
+ pa_proplist *p) {
+
+ pa_channel_map tmap;
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, ss && pa_sample_spec_valid(ss), PA_ERR_INVALID);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 12 || (ss->format != PA_SAMPLE_S32LE && ss->format != PA_SAMPLE_S32BE), PA_ERR_NOTSUPPORTED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 15 || (ss->format != PA_SAMPLE_S24LE && ss->format != PA_SAMPLE_S24BE), PA_ERR_NOTSUPPORTED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 15 || (ss->format != PA_SAMPLE_S24_32LE && ss->format != PA_SAMPLE_S24_32BE), PA_ERR_NOTSUPPORTED);
+ PA_CHECK_VALIDITY_RETURN_NULL(c, !map || (pa_channel_map_valid(map) && map->channels == ss->channels), PA_ERR_INVALID);
+
+ if (!map)
+ PA_CHECK_VALIDITY_RETURN_NULL(c, map = pa_channel_map_init_auto(&tmap, ss->channels, PA_CHANNEL_MAP_DEFAULT), PA_ERR_INVALID);
+
+ return pa_stream_new_with_proplist_internal(c, name, ss, map, NULL, 0, p);
+}
+
+pa_stream *pa_stream_new_extended(
+ pa_context *c,
+ const char *name,
+ pa_format_info * const *formats,
+ unsigned int n_formats,
+ pa_proplist *p) {
+
+ PA_CHECK_VALIDITY_RETURN_NULL(c, c->version >= 21, PA_ERR_NOTSUPPORTED);
+
+ return pa_stream_new_with_proplist_internal(c, name, NULL, NULL, formats, n_formats, p);
+}
+
static void stream_unlink(pa_stream *s) {
pa_operation *o, *n;
pa_assert(s);
@@ -197,7 +257,7 @@ static void stream_unlink(pa_stream *s) {
pa_pdispatch_unregister_reply(s->context->pdispatch, s);
if (s->channel_valid) {
- pa_dynarray_put((s->direction == PA_STREAM_PLAYBACK) ? s->context->playback_streams : s->context->record_streams, s->channel, NULL);
+ pa_hashmap_remove((s->direction == PA_STREAM_PLAYBACK) ? s->context->playback_streams : s->context->record_streams, PA_UINT32_TO_PTR(s->channel));
s->channel = 0;
s->channel_valid = FALSE;
}
@@ -216,10 +276,17 @@ static void stream_unlink(pa_stream *s) {
}
static void stream_free(pa_stream *s) {
+ unsigned int i;
+
pa_assert(s);
stream_unlink(s);
+ if (s->write_memblock) {
+ pa_memblock_release(s->write_memblock);
+ pa_memblock_unref(s->write_data);
+ }
+
if (s->peek_memchunk.memblock) {
if (s->peek_data)
pa_memblock_release(s->peek_memchunk.memblock);
@@ -235,6 +302,12 @@ static void stream_free(pa_stream *s) {
if (s->smoother)
pa_smoother_free(s->smoother);
+ for (i = 0; i < s->n_formats; i++)
+ pa_format_info_free(s->req_formats[i]);
+
+ if (s->format)
+ pa_format_info_free(s->format);
+
pa_xfree(s->device_name);
pa_xfree(s);
}
@@ -319,16 +392,18 @@ static void request_auto_timing_update(pa_stream *s, pa_bool_t force) {
}
if (s->auto_timing_update_event) {
- struct timeval next;
-
- if (force)
- s->auto_timing_interval_usec = AUTO_TIMING_INTERVAL_START_USEC;
+ if (s->suspended && !force) {
+ pa_assert(s->mainloop);
+ s->mainloop->time_free(s->auto_timing_update_event);
+ s->auto_timing_update_event = NULL;
+ } else {
+ if (force)
+ s->auto_timing_interval_usec = AUTO_TIMING_INTERVAL_START_USEC;
- pa_gettimeofday(&next);
- pa_timeval_add(&next, s->auto_timing_interval_usec);
- s->mainloop->time_restart(s->auto_timing_update_event, &next);
+ pa_context_rttime_restart(s->context, s->auto_timing_update_event, pa_rtclock_now() + s->auto_timing_interval_usec);
- s->auto_timing_interval_usec = PA_MIN(AUTO_TIMING_INTERVAL_END_USEC, s->auto_timing_interval_usec*2);
+ s->auto_timing_interval_usec = PA_MIN(AUTO_TIMING_INTERVAL_END_USEC, s->auto_timing_interval_usec*2);
+ }
}
}
@@ -351,7 +426,7 @@ void pa_command_stream_killed(pa_pdispatch *pd, uint32_t command, uint32_t tag,
goto finish;
}
- if (!(s = pa_dynarray_get(command == PA_COMMAND_PLAYBACK_STREAM_KILLED ? c->playback_streams : c->record_streams, channel)))
+ if (!(s = pa_hashmap_get(command == PA_COMMAND_PLAYBACK_STREAM_KILLED ? c->playback_streams : c->record_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
@@ -373,7 +448,7 @@ static void check_smoother_status(pa_stream *s, pa_bool_t aposteriori, pa_bool_t
if (!s->smoother)
return;
- x = pa_rtclock_usec();
+ x = pa_rtclock_now();
if (s->timing_info_valid) {
if (aposteriori)
@@ -384,14 +459,33 @@ static void check_smoother_status(pa_stream *s, pa_bool_t aposteriori, pa_bool_t
if (s->suspended || s->corked || force_stop)
pa_smoother_pause(s->smoother, x);
- else if (force_start || s->buffer_attr.prebuf == 0)
- pa_smoother_resume(s->smoother, x, TRUE);
+ else if (force_start || s->buffer_attr.prebuf == 0) {
+
+ if (!s->timing_info_valid &&
+ !aposteriori &&
+ !force_start &&
+ !force_stop &&
+ s->context->version >= 13) {
+
+ /* If the server supports STARTED events we take them as
+ * indications when audio really starts/stops playing, if
+ * we don't have any timing info yet -- instead of trying
+ * to be smart and guessing the server time. Otherwise the
+ * unknown transport delay add too much noise to our time
+ * calculations. */
+
+ return;
+ }
+ pa_smoother_resume(s->smoother, x, TRUE);
+ }
/* Please note that we have no idea if playback actually started
* if prebuf is non-zero! */
}
+static void auto_timing_update_callback(pa_mainloop_api *m, pa_time_event *e, const struct timeval *t, void *userdata);
+
void pa_command_stream_moved(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
pa_context *c = userdata;
pa_stream *s;
@@ -454,7 +548,7 @@ void pa_command_stream_moved(pa_pdispatch *pd, uint32_t command, uint32_t tag, p
goto finish;
}
- if (!(s = pa_dynarray_get(command == PA_COMMAND_PLAYBACK_STREAM_MOVED ? c->playback_streams : c->record_streams, channel)))
+ if (!(s = pa_hashmap_get(command == PA_COMMAND_PLAYBACK_STREAM_MOVED ? c->playback_streams : c->record_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
@@ -479,6 +573,12 @@ void pa_command_stream_moved(pa_pdispatch *pd, uint32_t command, uint32_t tag, p
s->suspended = suspended;
+ if ((s->flags & PA_STREAM_AUTO_TIMING_UPDATE) && !suspended && !s->auto_timing_update_event) {
+ s->auto_timing_interval_usec = AUTO_TIMING_INTERVAL_START_USEC;
+ s->auto_timing_update_event = pa_context_rttime_new(s->context, pa_rtclock_now() + s->auto_timing_interval_usec, &auto_timing_update_callback, s);
+ request_auto_timing_update(s, TRUE);
+ }
+
check_smoother_status(s, TRUE, FALSE, FALSE);
request_auto_timing_update(s, TRUE);
@@ -537,7 +637,7 @@ void pa_command_stream_buffer_attr(pa_pdispatch *pd, uint32_t command, uint32_t
goto finish;
}
- if (!(s = pa_dynarray_get(command == PA_COMMAND_PLAYBACK_BUFFER_ATTR_CHANGED ? c->playback_streams : c->record_streams, channel)))
+ if (!(s = pa_hashmap_get(command == PA_COMMAND_PLAYBACK_BUFFER_ATTR_CHANGED ? c->playback_streams : c->record_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
@@ -589,7 +689,7 @@ void pa_command_stream_suspended(pa_pdispatch *pd, uint32_t command, uint32_t ta
goto finish;
}
- if (!(s = pa_dynarray_get(command == PA_COMMAND_PLAYBACK_STREAM_SUSPENDED ? c->playback_streams : c->record_streams, channel)))
+ if (!(s = pa_hashmap_get(command == PA_COMMAND_PLAYBACK_STREAM_SUSPENDED ? c->playback_streams : c->record_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
@@ -597,6 +697,12 @@ void pa_command_stream_suspended(pa_pdispatch *pd, uint32_t command, uint32_t ta
s->suspended = suspended;
+ if ((s->flags & PA_STREAM_AUTO_TIMING_UPDATE) && !suspended && !s->auto_timing_update_event) {
+ s->auto_timing_interval_usec = AUTO_TIMING_INTERVAL_START_USEC;
+ s->auto_timing_update_event = pa_context_rttime_new(s->context, pa_rtclock_now() + s->auto_timing_interval_usec, &auto_timing_update_callback, s);
+ request_auto_timing_update(s, TRUE);
+ }
+
check_smoother_status(s, TRUE, FALSE, FALSE);
request_auto_timing_update(s, TRUE);
@@ -631,7 +737,7 @@ void pa_command_stream_started(pa_pdispatch *pd, uint32_t command, uint32_t tag,
goto finish;
}
- if (!(s = pa_dynarray_get(c->playback_streams, channel)))
+ if (!(s = pa_hashmap_get(c->playback_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
@@ -677,12 +783,19 @@ void pa_command_stream_event(pa_pdispatch *pd, uint32_t command, uint32_t tag, p
goto finish;
}
- if (!(s = pa_dynarray_get(command == PA_COMMAND_PLAYBACK_STREAM_EVENT ? c->playback_streams : c->record_streams, channel)))
+ if (!(s = pa_hashmap_get(command == PA_COMMAND_PLAYBACK_STREAM_EVENT ? c->playback_streams : c->record_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
goto finish;
+ if (pa_streq(event, PA_STREAM_EVENT_FORMAT_LOST)) {
+ /* Let client know what the running time was when the stream had to be killed */
+ pa_usec_t stream_time;
+ if (pa_stream_get_time(s, &stream_time) == 0)
+ pa_proplist_setf(pl, "stream-time", "%llu", (unsigned long long) stream_time);
+ }
+
if (s->event_callback)
s->event_callback(s, event, pl, s->event_userdata);
@@ -713,7 +826,7 @@ void pa_command_request(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tag
goto finish;
}
- if (!(s = pa_dynarray_get(c->playback_streams, channel)))
+ if (!(s = pa_hashmap_get(c->playback_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
@@ -721,6 +834,8 @@ void pa_command_request(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tag
s->requested_bytes += bytes;
+ /* pa_log("got request for %lli, now at %lli", (long long) bytes, (long long) s->requested_bytes); */
+
if (s->requested_bytes > 0 && s->write_callback)
s->write_callback(s, (size_t) s->requested_bytes, s->write_userdata);
@@ -747,7 +862,7 @@ void pa_command_overflow_or_underflow(pa_pdispatch *pd, uint32_t command, uint32
goto finish;
}
- if (!(s = pa_dynarray_get(c->playback_streams, channel)))
+ if (!(s = pa_hashmap_get(c->playback_streams, PA_UINT32_TO_PTR(channel))))
goto finish;
if (s->state != PA_STREAM_READY)
@@ -766,7 +881,7 @@ void pa_command_overflow_or_underflow(pa_pdispatch *pd, uint32_t command, uint32
s->underflow_callback(s, s->underflow_userdata);
}
- finish:
+finish:
pa_context_unref(c);
}
@@ -800,7 +915,7 @@ static void invalidate_indexes(pa_stream *s, pa_bool_t r, pa_bool_t w) {
request_auto_timing_update(s, TRUE);
}
-static void auto_timing_update_callback(pa_mainloop_api *m, pa_time_event *e, const struct timeval *tv, void *userdata) {
+static void auto_timing_update_callback(pa_mainloop_api *m, pa_time_event *e, const struct timeval *t, void *userdata) {
pa_stream *s = userdata;
pa_assert(s);
@@ -822,12 +937,9 @@ static void create_stream_complete(pa_stream *s) {
s->write_callback(s, (size_t) s->requested_bytes, s->write_userdata);
if (s->flags & PA_STREAM_AUTO_TIMING_UPDATE) {
- struct timeval tv;
- pa_gettimeofday(&tv);
s->auto_timing_interval_usec = AUTO_TIMING_INTERVAL_START_USEC;
- pa_timeval_add(&tv, s->auto_timing_interval_usec);
pa_assert(!s->auto_timing_update_event);
- s->auto_timing_update_event = s->mainloop->time_new(s->mainloop, &tv, &auto_timing_update_callback, s);
+ s->auto_timing_update_event = pa_context_rttime_new(s->context, pa_rtclock_now() + s->auto_timing_interval_usec, &auto_timing_update_callback, s);
request_auto_timing_update(s, TRUE);
}
@@ -835,10 +947,28 @@ static void create_stream_complete(pa_stream *s) {
check_smoother_status(s, TRUE, FALSE, FALSE);
}
-static void automatic_buffer_attr(pa_stream *s, pa_buffer_attr *attr, const pa_sample_spec *ss) {
+static void patch_buffer_attr(pa_stream *s, pa_buffer_attr *attr, pa_stream_flags_t *flags) {
+ const char *e;
+
pa_assert(s);
pa_assert(attr);
- pa_assert(ss);
+
+ if ((e = getenv("PULSE_LATENCY_MSEC"))) {
+ uint32_t ms;
+
+ if (pa_atou(e, &ms) < 0 || ms <= 0)
+ pa_log_debug("Failed to parse $PULSE_LATENCY_MSEC: %s", e);
+ else {
+ attr->maxlength = (uint32_t) -1;
+ attr->tlength = pa_usec_to_bytes(ms * PA_USEC_PER_MSEC, &s->sample_spec);
+ attr->minreq = (uint32_t) -1;
+ attr->prebuf = (uint32_t) -1;
+ attr->fragsize = attr->tlength;
+ }
+
+ if (flags)
+ *flags |= PA_STREAM_ADJUST_LATENCY;
+ }
if (s->context->version >= 13)
return;
@@ -853,7 +983,7 @@ static void automatic_buffer_attr(pa_stream *s, pa_buffer_attr *attr, const pa_s
attr->maxlength = 4*1024*1024; /* 4MB is the maximum queue length PulseAudio <= 0.9.9 supported. */
if (attr->tlength == (uint32_t) -1)
- attr->tlength = (uint32_t) pa_usec_to_bytes(250*PA_USEC_PER_MSEC, ss); /* 250ms of buffering */
+ attr->tlength = (uint32_t) pa_usec_to_bytes(250*PA_USEC_PER_MSEC, &s->sample_spec); /* 250ms of buffering */
if (attr->minreq == (uint32_t) -1)
attr->minreq = (attr->tlength)/5; /* Ask for more data when there are only 200ms left in the playback buffer */
@@ -867,7 +997,7 @@ static void automatic_buffer_attr(pa_stream *s, pa_buffer_attr *attr, const pa_s
void pa_create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
pa_stream *s = userdata;
- uint32_t requested_bytes;
+ uint32_t requested_bytes = 0;
pa_assert(pd);
pa_assert(s);
@@ -886,7 +1016,7 @@ void pa_create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag,
if (pa_tagstruct_getu32(t, &s->channel) < 0 ||
s->channel == PA_INVALID_INDEX ||
- ((s->direction != PA_STREAM_UPLOAD) && (pa_tagstruct_getu32(t, &s->stream_index) < 0 || s->stream_index == PA_INVALID_INDEX)) ||
+ ((s->direction != PA_STREAM_UPLOAD) && (pa_tagstruct_getu32(t, &s->stream_index) < 0 || s->stream_index == PA_INVALID_INDEX)) ||
((s->direction != PA_STREAM_RECORD) && pa_tagstruct_getu32(t, &requested_bytes) < 0)) {
pa_context_fail(s->context, PA_ERR_PROTOCOL);
goto finish;
@@ -931,9 +1061,10 @@ void pa_create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag,
ss.channels != cm.channels ||
!pa_channel_map_valid(&cm) ||
!pa_sample_spec_valid(&ss) ||
- (!(s->flags & PA_STREAM_FIX_FORMAT) && ss.format != s->sample_spec.format) ||
- (!(s->flags & PA_STREAM_FIX_RATE) && ss.rate != s->sample_spec.rate) ||
- (!(s->flags & PA_STREAM_FIX_CHANNELS) && !pa_channel_map_equal(&cm, &s->channel_map))) {
+ (s->n_formats == 0 && (
+ (!(s->flags & PA_STREAM_FIX_FORMAT) && ss.format != s->sample_spec.format) ||
+ (!(s->flags & PA_STREAM_FIX_RATE) && ss.rate != s->sample_spec.rate) ||
+ (!(s->flags & PA_STREAM_FIX_CHANNELS) && !pa_channel_map_equal(&cm, &s->channel_map))))) {
pa_context_fail(s->context, PA_ERR_PROTOCOL);
goto finish;
}
@@ -960,6 +1091,24 @@ void pa_create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag,
s->timing_info.configured_sink_usec = usec;
}
+ if ((s->context->version >= 21 && s->direction == PA_STREAM_PLAYBACK)
+ || s->context->version >= 22) {
+
+ pa_format_info *f = pa_format_info_new();
+ pa_tagstruct_get_format_info(t, f);
+
+ if (pa_format_info_valid(f))
+ s->format = f;
+ else {
+ pa_format_info_free(f);
+ if (s->n_formats > 0) {
+ /* We used the extended API, so we should have got back a proper format */
+ pa_context_fail(s->context, PA_ERR_PROTOCOL);
+ goto finish;
+ }
+ }
+ }
+
if (!pa_tagstruct_eof(t)) {
pa_context_fail(s->context, PA_ERR_PROTOCOL);
goto finish;
@@ -980,7 +1129,7 @@ void pa_create_stream_callback(pa_pdispatch *pd, uint32_t command, uint32_t tag,
}
s->channel_valid = TRUE;
- pa_dynarray_put((s->direction == PA_STREAM_RECORD) ? s->context->record_streams : s->context->playback_streams, s->channel, s);
+ pa_hashmap_put((s->direction == PA_STREAM_RECORD) ? s->context->record_streams : s->context->playback_streams, PA_UINT32_TO_PTR(s->channel), s);
create_stream_complete(s);
@@ -999,7 +1148,9 @@ static int create_stream(
pa_tagstruct *t;
uint32_t tag;
- pa_bool_t volume_set = FALSE;
+ pa_bool_t volume_set = !!volume;
+ pa_cvolume cv;
+ uint32_t i;
pa_assert(s);
pa_assert(PA_REFCNT_VALUE(s) >= 1);
@@ -1025,7 +1176,10 @@ static int create_stream(
PA_STREAM_EARLY_REQUESTS|
PA_STREAM_DONT_INHIBIT_AUTO_SUSPEND|
PA_STREAM_START_UNMUTED|
- PA_STREAM_FAIL_ON_SUSPEND)), PA_ERR_INVALID);
+ PA_STREAM_FAIL_ON_SUSPEND|
+ PA_STREAM_RELATIVE_VOLUME|
+ PA_STREAM_PASSTHROUGH)), PA_ERR_INVALID);
+
PA_CHECK_VALIDITY(s->context, s->context->version >= 12 || !(flags & PA_STREAM_VARIABLE_RATE), PA_ERR_NOTSUPPORTED);
PA_CHECK_VALIDITY(s->context, s->context->version >= 13 || !(flags & PA_STREAM_PEAK_DETECT), PA_ERR_NOTSUPPORTED);
@@ -1037,27 +1191,28 @@ static int create_stream(
PA_CHECK_VALIDITY(s->context, direction == PA_STREAM_PLAYBACK || !(flags & (PA_STREAM_START_MUTED)), PA_ERR_INVALID);
PA_CHECK_VALIDITY(s->context, direction == PA_STREAM_RECORD || !(flags & (PA_STREAM_PEAK_DETECT)), PA_ERR_INVALID);
- PA_CHECK_VALIDITY(s->context, !volume || volume->channels == s->sample_spec.channels, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY(s->context, !volume || (pa_sample_spec_valid(&s->sample_spec) && volume->channels == s->sample_spec.channels), PA_ERR_INVALID);
PA_CHECK_VALIDITY(s->context, !sync_stream || (direction == PA_STREAM_PLAYBACK && sync_stream->direction == PA_STREAM_PLAYBACK), PA_ERR_INVALID);
PA_CHECK_VALIDITY(s->context, (flags & (PA_STREAM_ADJUST_LATENCY|PA_STREAM_EARLY_REQUESTS)) != (PA_STREAM_ADJUST_LATENCY|PA_STREAM_EARLY_REQUESTS), PA_ERR_INVALID);
pa_stream_ref(s);
s->direction = direction;
- s->flags = flags;
- s->corked = !!(flags & PA_STREAM_START_CORKED);
if (sync_stream)
s->syncid = sync_stream->syncid;
if (attr)
s->buffer_attr = *attr;
- automatic_buffer_attr(s, &s->buffer_attr, &s->sample_spec);
+ patch_buffer_attr(s, &s->buffer_attr, &flags);
+
+ s->flags = flags;
+ s->corked = !!(flags & PA_STREAM_START_CORKED);
if (flags & PA_STREAM_INTERPOLATE_TIMING) {
pa_usec_t x;
- x = pa_rtclock_usec();
+ x = pa_rtclock_now();
pa_assert(!s->smoother);
s->smoother = pa_smoother_new(
@@ -1091,9 +1246,18 @@ static int create_stream(
PA_TAG_BOOLEAN, s->corked,
PA_TAG_INVALID);
- if (s->direction == PA_STREAM_PLAYBACK) {
- pa_cvolume cv;
+ if (!volume) {
+ if (pa_sample_spec_valid(&s->sample_spec))
+ volume = pa_cvolume_reset(&cv, s->sample_spec.channels);
+ else {
+ /* This is not really relevant, since no volume was set, and
+ * the real number of channels is embedded in the format_info
+ * structure */
+ volume = pa_cvolume_reset(&cv, PA_CHANNELS_MAX);
+ }
+ }
+ if (s->direction == PA_STREAM_PLAYBACK) {
pa_tagstruct_put(
t,
PA_TAG_U32, s->buffer_attr.tlength,
@@ -1102,11 +1266,6 @@ static int create_stream(
PA_TAG_U32, s->syncid,
PA_TAG_INVALID);
- volume_set = !!volume;
-
- if (!volume)
- volume = pa_cvolume_reset(&cv, s->sample_spec.channels);
-
pa_tagstruct_put_cvolume(t, volume);
} else
pa_tagstruct_putu32(t, s->buffer_attr.fragsize);
@@ -1158,6 +1317,29 @@ static int create_stream(
pa_tagstruct_put_boolean(t, flags & PA_STREAM_FAIL_ON_SUSPEND);
}
+ if (s->context->version >= 17 && s->direction == PA_STREAM_PLAYBACK)
+ pa_tagstruct_put_boolean(t, flags & PA_STREAM_RELATIVE_VOLUME);
+
+ if (s->context->version >= 18 && s->direction == PA_STREAM_PLAYBACK)
+ pa_tagstruct_put_boolean(t, flags & (PA_STREAM_PASSTHROUGH));
+
+ if ((s->context->version >= 21 && s->direction == PA_STREAM_PLAYBACK)
+ || s->context->version >= 22) {
+
+ pa_tagstruct_putu8(t, s->n_formats);
+ for (i = 0; i < s->n_formats; i++)
+ pa_tagstruct_put_format_info(t, s->req_formats[i]);
+ }
+
+ if (s->context->version >= 22 && s->direction == PA_STREAM_RECORD) {
+ pa_tagstruct_put_cvolume(t, volume);
+ pa_tagstruct_put_boolean(t, flags & PA_STREAM_START_MUTED);
+ pa_tagstruct_put_boolean(t, volume_set);
+ pa_tagstruct_put_boolean(t, flags & (PA_STREAM_START_MUTED|PA_STREAM_START_UNMUTED));
+ pa_tagstruct_put_boolean(t, flags & PA_STREAM_RELATIVE_VOLUME);
+ pa_tagstruct_put_boolean(t, flags & (PA_STREAM_PASSTHROUGH));
+ }
+
pa_pstream_send_tagstruct(s->context->pstream, t);
pa_pdispatch_register_reply(s->context->pdispatch, tag, DEFAULT_TIMEOUT, pa_create_stream_callback, s, NULL);
@@ -1172,7 +1354,7 @@ int pa_stream_connect_playback(
const char *dev,
const pa_buffer_attr *attr,
pa_stream_flags_t flags,
- pa_cvolume *volume,
+ const pa_cvolume *volume,
pa_stream *sync_stream) {
pa_assert(s);
@@ -1193,20 +1375,71 @@ int pa_stream_connect_record(
return create_stream(PA_STREAM_RECORD, s, dev, attr, flags, NULL, NULL);
}
+int pa_stream_begin_write(
+ pa_stream *s,
+ void **data,
+ size_t *nbytes) {
+
+ pa_assert(s);
+ pa_assert(PA_REFCNT_VALUE(s) >= 1);
+
+ PA_CHECK_VALIDITY(s->context, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY(s->context, s->state == PA_STREAM_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY(s->context, s->direction == PA_STREAM_PLAYBACK || s->direction == PA_STREAM_UPLOAD, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY(s->context, data, PA_ERR_INVALID);
+ PA_CHECK_VALIDITY(s->context, nbytes && *nbytes != 0, PA_ERR_INVALID);
+
+ if (*nbytes != (size_t) -1) {
+ size_t m, fs;
+
+ m = pa_mempool_block_size_max(s->context->mempool);
+ fs = pa_frame_size(&s->sample_spec);
+
+ m = (m / fs) * fs;
+ if (*nbytes > m)
+ *nbytes = m;
+ }
+
+ if (!s->write_memblock) {
+ s->write_memblock = pa_memblock_new(s->context->mempool, *nbytes);
+ s->write_data = pa_memblock_acquire(s->write_memblock);
+ }
+
+ *data = s->write_data;
+ *nbytes = pa_memblock_get_length(s->write_memblock);
+
+ return 0;
+}
+
+int pa_stream_cancel_write(
+ pa_stream *s) {
+
+ pa_assert(s);
+ pa_assert(PA_REFCNT_VALUE(s) >= 1);
+
+ PA_CHECK_VALIDITY(s->context, !pa_detect_fork(), PA_ERR_FORKED);
+ PA_CHECK_VALIDITY(s->context, s->state == PA_STREAM_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY(s->context, s->direction == PA_STREAM_PLAYBACK || s->direction == PA_STREAM_UPLOAD, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY(s->context, s->write_memblock, PA_ERR_BADSTATE);
+
+ pa_assert(s->write_data);
+
+ pa_memblock_release(s->write_memblock);
+ pa_memblock_unref(s->write_memblock);
+ s->write_memblock = NULL;
+ s->write_data = NULL;
+
+ return 0;
+}
+
int pa_stream_write(
pa_stream *s,
const void *data,
size_t length,
- void (*free_cb)(void *p),
+ pa_free_cb_t free_cb,
int64_t offset,
pa_seek_mode_t seek) {
- pa_memchunk chunk;
- pa_seek_mode_t t_seek;
- int64_t t_offset;
- size_t t_length;
- const void *t_data;
-
pa_assert(s);
pa_assert(PA_REFCNT_VALUE(s) >= 1);
pa_assert(data);
@@ -1216,51 +1449,78 @@ int pa_stream_write(
PA_CHECK_VALIDITY(s->context, s->direction == PA_STREAM_PLAYBACK || s->direction == PA_STREAM_UPLOAD, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY(s->context, seek <= PA_SEEK_RELATIVE_END, PA_ERR_INVALID);
PA_CHECK_VALIDITY(s->context, s->direction == PA_STREAM_PLAYBACK || (seek == PA_SEEK_RELATIVE && offset == 0), PA_ERR_INVALID);
+ PA_CHECK_VALIDITY(s->context,
+ !s->write_memblock ||
+ ((data >= s->write_data) &&
+ ((const char*) data + length <= (const char*) s->write_data + pa_memblock_get_length(s->write_memblock))),
+ PA_ERR_INVALID);
+ PA_CHECK_VALIDITY(s->context, !free_cb || !s->write_memblock, PA_ERR_INVALID);
- if (length <= 0)
- return 0;
+ if (s->write_memblock) {
+ pa_memchunk chunk;
- t_seek = seek;
- t_offset = offset;
- t_length = length;
- t_data = data;
+ /* pa_stream_write_begin() was called before */
- while (t_length > 0) {
+ pa_memblock_release(s->write_memblock);
- chunk.index = 0;
+ chunk.memblock = s->write_memblock;
+ chunk.index = (const char *) data - (const char *) s->write_data;
+ chunk.length = length;
- if (free_cb && !pa_pstream_get_shm(s->context->pstream)) {
- chunk.memblock = pa_memblock_new_user(s->context->mempool, (void*) t_data, t_length, free_cb, 1);
- chunk.length = t_length;
- } else {
- void *d;
+ s->write_memblock = NULL;
+ s->write_data = NULL;
+
+ pa_pstream_send_memblock(s->context->pstream, s->channel, offset, seek, &chunk);
+ pa_memblock_unref(chunk.memblock);
- chunk.length = PA_MIN(t_length, pa_mempool_block_size_max(s->context->mempool));
- chunk.memblock = pa_memblock_new(s->context->mempool, chunk.length);
+ } else {
+ pa_seek_mode_t t_seek = seek;
+ int64_t t_offset = offset;
+ size_t t_length = length;
+ const void *t_data = data;
- d = pa_memblock_acquire(chunk.memblock);
- memcpy(d, t_data, chunk.length);
- pa_memblock_release(chunk.memblock);
- }
+ /* pa_stream_write_begin() was not called before */
- pa_pstream_send_memblock(s->context->pstream, s->channel, t_offset, t_seek, &chunk);
+ while (t_length > 0) {
+ pa_memchunk chunk;
- t_offset = 0;
- t_seek = PA_SEEK_RELATIVE;
+ chunk.index = 0;
- t_data = (const uint8_t*) t_data + chunk.length;
- t_length -= chunk.length;
+ if (free_cb && !pa_pstream_get_shm(s->context->pstream)) {
+ chunk.memblock = pa_memblock_new_user(s->context->mempool, (void*) t_data, t_length, free_cb, 1);
+ chunk.length = t_length;
+ } else {
+ void *d;
- pa_memblock_unref(chunk.memblock);
- }
+ chunk.length = PA_MIN(t_length, pa_mempool_block_size_max(s->context->mempool));
+ chunk.memblock = pa_memblock_new(s->context->mempool, chunk.length);
- if (free_cb && pa_pstream_get_shm(s->context->pstream))
- free_cb((void*) data);
+ d = pa_memblock_acquire(chunk.memblock);
+ memcpy(d, t_data, chunk.length);
+ pa_memblock_release(chunk.memblock);
+ }
+
+ pa_pstream_send_memblock(s->context->pstream, s->channel, t_offset, t_seek, &chunk);
+
+ t_offset = 0;
+ t_seek = PA_SEEK_RELATIVE;
+
+ t_data = (const uint8_t*) t_data + chunk.length;
+ t_length -= chunk.length;
+
+ pa_memblock_unref(chunk.memblock);
+ }
+
+ if (free_cb && pa_pstream_get_shm(s->context->pstream))
+ free_cb((void*) data);
+ }
/* This is obviously wrong since we ignore the seeking index . But
* that's OK, the server side applies the same error */
s->requested_bytes -= (seek == PA_SEEK_RELATIVE ? offset : 0) + (int64_t) length;
+ /* pa_log("wrote %lli, now at %lli", (long long) length, (long long) s->requested_bytes); */
+
if (s->direction == PA_STREAM_PLAYBACK) {
/* Update latency request correction */
@@ -1381,6 +1641,11 @@ pa_operation * pa_stream_drain(pa_stream *s, pa_stream_success_cb_t cb, void *us
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->state == PA_STREAM_READY, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->direction == PA_STREAM_PLAYBACK, PA_ERR_BADSTATE);
+ /* Ask for a timing update before we cork/uncork to get the best
+ * accuracy for the transport latency suitable for the
+ * check_smoother_status() call in the started callback */
+ request_auto_timing_update(s, TRUE);
+
o = pa_operation_new(s->context, s, (pa_operation_cb_t) cb, userdata);
t = pa_tagstruct_command(s->context, PA_COMMAND_DRAIN_PLAYBACK_STREAM, &tag);
@@ -1388,6 +1653,10 @@ pa_operation * pa_stream_drain(pa_stream *s, pa_stream_success_cb_t cb, void *us
pa_pstream_send_tagstruct(s->context->pstream, t);
pa_pdispatch_register_reply(s->context->pdispatch, tag, DEFAULT_TIMEOUT, pa_stream_simple_ack_callback, pa_operation_ref(o), (pa_free_cb_t) pa_operation_unref);
+ /* This might cause the read index to conitnue again, hence
+ * let's request a timing update */
+ request_auto_timing_update(s, TRUE);
+
return o;
}
@@ -1590,11 +1859,11 @@ static void stream_get_timing_info_callback(pa_pdispatch *pd, uint32_t command,
i->read_index -= (int64_t) pa_memblockq_get_length(o->stream->record_memblockq);
}
- /* Update smoother */
- if (o->stream->smoother) {
+ /* Update smoother if we're not corked */
+ if (o->stream->smoother && !o->stream->corked) {
pa_usec_t u, x;
- u = x = pa_rtclock_usec() - i->transport_usec;
+ u = x = pa_rtclock_now() - i->transport_usec;
if (o->stream->direction == PA_STREAM_PLAYBACK && o->context->version >= 13) {
pa_usec_t su;
@@ -1936,6 +2205,11 @@ pa_operation* pa_stream_cork(pa_stream *s, int b, pa_stream_success_cb_t cb, voi
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->state == PA_STREAM_READY, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->direction != PA_STREAM_UPLOAD, PA_ERR_BADSTATE);
+ /* Ask for a timing update before we cork/uncork to get the best
+ * accuracy for the transport latency suitable for the
+ * check_smoother_status() call in the started callback */
+ request_auto_timing_update(s, TRUE);
+
s->corked = b;
o = pa_operation_new(s->context, s, (pa_operation_cb_t) cb, userdata);
@@ -1951,8 +2225,8 @@ pa_operation* pa_stream_cork(pa_stream *s, int b, pa_stream_success_cb_t cb, voi
check_smoother_status(s, FALSE, FALSE, FALSE);
- /* This might cause the indexes to hang/start again, hence
- * let's request a timing update */
+ /* This might cause the indexes to hang/start again, hence let's
+ * request a timing update, after the cork/uncork, too */
request_auto_timing_update(s, TRUE);
return o;
@@ -1989,6 +2263,11 @@ pa_operation* pa_stream_flush(pa_stream *s, pa_stream_success_cb_t cb, void *use
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->state == PA_STREAM_READY, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->direction != PA_STREAM_UPLOAD, PA_ERR_BADSTATE);
+ /* Ask for a timing update *before* the flush, so that the
+ * transport usec is as up to date as possible when we get the
+ * underflow message and update the smoother status*/
+ request_auto_timing_update(s, TRUE);
+
if (!(o = stream_send_simple_command(s, (uint32_t) (s->direction == PA_STREAM_PLAYBACK ? PA_COMMAND_FLUSH_PLAYBACK_STREAM : PA_COMMAND_FLUSH_RECORD_STREAM), cb, userdata)))
return NULL;
@@ -2009,6 +2288,11 @@ pa_operation* pa_stream_flush(pa_stream *s, pa_stream_success_cb_t cb, void *use
* index, but the read index might jump. */
invalidate_indexes(s, TRUE, FALSE);
+ /* Note that we do not update requested_bytes here. This is
+ * because we cannot really know how data actually was dropped
+ * from the write index due to this. This 'error' will be applied
+ * by both client and server and hence we should be fine. */
+
return o;
}
@@ -2023,6 +2307,11 @@ pa_operation* pa_stream_prebuf(pa_stream *s, pa_stream_success_cb_t cb, void *us
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->direction == PA_STREAM_PLAYBACK, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->buffer_attr.prebuf > 0, PA_ERR_BADSTATE);
+ /* Ask for a timing update before we cork/uncork to get the best
+ * accuracy for the transport latency suitable for the
+ * check_smoother_status() call in the started callback */
+ request_auto_timing_update(s, TRUE);
+
if (!(o = stream_send_simple_command(s, PA_COMMAND_PREBUF_PLAYBACK_STREAM, cb, userdata)))
return NULL;
@@ -2044,6 +2333,11 @@ pa_operation* pa_stream_trigger(pa_stream *s, pa_stream_success_cb_t cb, void *u
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->direction == PA_STREAM_PLAYBACK, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->buffer_attr.prebuf > 0, PA_ERR_BADSTATE);
+ /* Ask for a timing update before we cork/uncork to get the best
+ * accuracy for the transport latency suitable for the
+ * check_smoother_status() call in the started callback */
+ request_auto_timing_update(s, TRUE);
+
if (!(o = stream_send_simple_command(s, PA_COMMAND_TRIGGER_PLAYBACK_STREAM, cb, userdata)))
return NULL;
@@ -2103,7 +2397,7 @@ int pa_stream_get_time(pa_stream *s, pa_usec_t *r_usec) {
PA_CHECK_VALIDITY(s->context, s->direction != PA_STREAM_RECORD || !s->timing_info.write_index_corrupt, PA_ERR_NODATA);
if (s->smoother)
- usec = pa_smoother_get(s->smoother, pa_rtclock_usec());
+ usec = pa_smoother_get(s->smoother, pa_rtclock_now());
else
usec = calc_time(s, FALSE);
@@ -2206,6 +2500,16 @@ const pa_channel_map* pa_stream_get_channel_map(pa_stream *s) {
return &s->channel_map;
}
+const pa_format_info* pa_stream_get_format_info(pa_stream *s) {
+ pa_assert(s);
+ pa_assert(PA_REFCNT_VALUE(s) >= 1);
+
+ /* We don't have the format till routing is done */
+ PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->state == PA_STREAM_READY, PA_ERR_BADSTATE);
+ PA_CHECK_VALIDITY_RETURN_NULL(s->context, !pa_detect_fork(), PA_ERR_FORKED);
+
+ return s->format;
+}
const pa_buffer_attr* pa_stream_get_buffer_attr(pa_stream *s) {
pa_assert(s);
pa_assert(PA_REFCNT_VALUE(s) >= 1);
@@ -2285,6 +2589,7 @@ pa_operation* pa_stream_set_buffer_attr(pa_stream *s, const pa_buffer_attr *attr
pa_operation *o;
pa_tagstruct *t;
uint32_t tag;
+ pa_buffer_attr copy;
pa_assert(s);
pa_assert(PA_REFCNT_VALUE(s) >= 1);
@@ -2295,6 +2600,11 @@ pa_operation* pa_stream_set_buffer_attr(pa_stream *s, const pa_buffer_attr *attr
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->direction != PA_STREAM_UPLOAD, PA_ERR_BADSTATE);
PA_CHECK_VALIDITY_RETURN_NULL(s->context, s->context->version >= 12, PA_ERR_NOTSUPPORTED);
+ /* Ask for a timing update before we cork/uncork to get the best
+ * accuracy for the transport latency suitable for the
+ * check_smoother_status() call in the started callback */
+ request_auto_timing_update(s, TRUE);
+
o = pa_operation_new(s->context, s, (pa_operation_cb_t) cb, userdata);
t = pa_tagstruct_command(
@@ -2303,6 +2613,10 @@ pa_operation* pa_stream_set_buffer_attr(pa_stream *s, const pa_buffer_attr *attr
&tag);
pa_tagstruct_putu32(t, s->channel);
+ copy = *attr;
+ patch_buffer_attr(s, &copy, NULL);
+ attr = &copy;
+
pa_tagstruct_putu32(t, attr->maxlength);
if (s->direction == PA_STREAM_PLAYBACK)
diff --git a/src/pulse/stream.h b/src/pulse/stream.h
index 49c132a2..010f968f 100644
--- a/src/pulse/stream.h
+++ b/src/pulse/stream.h
@@ -26,11 +26,14 @@
#include <sys/types.h>
#include <pulse/sample.h>
+#include <pulse/format.h>
#include <pulse/channelmap.h>
#include <pulse/volume.h>
#include <pulse/def.h>
#include <pulse/cdecl.h>
#include <pulse/operation.h>
+#include <pulse/context.h>
+#include <pulse/proplist.h>
/** \page streams Audio Streams
*
@@ -264,7 +267,7 @@
* pa_stream_get_time() and pa_stream_get_latency() will try to
* interpolate the current playback time/latency by estimating the
* number of samples that have been played back by the hardware since
- * the last regular timing update. It is espcially useful to combine
+ * the last regular timing update. It is especially useful to combine
* this option with PA_STREAM_AUTO_TIMING_UPDATE, which will enable
* you to monitor the current playback time/latency very precisely and
* very frequently without requiring a network round trip every time.
@@ -287,7 +290,7 @@
* issued on the others.
*
* To synchronize a stream to another, just pass the "master" stream
- * as last argument to pa_stream_connect_playack(). To make sure that
+ * as last argument to pa_stream_connect_playback(). To make sure that
* the freshly created stream doesn't start playback right-away, make
* sure to pass PA_STREAM_START_CORKED and - after all streams have
* been created - uncork them all with a single call to
@@ -308,7 +311,10 @@
*/
/** \file
- * Audio streams for input, output and sample upload */
+ * Audio streams for input, output and sample upload
+ *
+ * See also \subpage streams
+ */
PA_C_DECL_BEGIN
@@ -319,7 +325,7 @@ typedef struct pa_stream pa_stream;
typedef void (*pa_stream_success_cb_t) (pa_stream*s, int success, void *userdata);
/** A generic request callback */
-typedef void (*pa_stream_request_cb_t)(pa_stream *p, size_t bytes, void *userdata);
+typedef void (*pa_stream_request_cb_t)(pa_stream *p, size_t nbytes, void *userdata);
/** A generic notification callback */
typedef void (*pa_stream_notify_cb_t)(pa_stream *p, void *userdata);
@@ -351,6 +357,17 @@ pa_stream* pa_stream_new_with_proplist(
const pa_channel_map *map /**< The desired channel map, or NULL for default */,
pa_proplist *p /**< The initial property list */);
+/* Create a new, unconnected stream with the specified name, the set of formats
+ * this client can provide, and an initial list of properties. While
+ * connecting, the server will select the most appropriate format which the
+ * client must then provide. \since 1.0 */
+pa_stream *pa_stream_new_extended(
+ pa_context *c /**< The context to create this stream in */,
+ const char *name /**< A name for this stream */,
+ pa_format_info * const * formats /**< The list of formats that can be provided */,
+ unsigned int n_formats /**< The number of formats being passed in */,
+ pa_proplist *p /**< The initial property list */);
+
/** Decrease the reference counter by one */
void pa_stream_unref(pa_stream *s);
@@ -399,13 +416,28 @@ int pa_stream_is_suspended(pa_stream *s);
* not, and negative on error. \since 0.9.11 */
int pa_stream_is_corked(pa_stream *s);
-/** Connect the stream to a sink */
+/** Connect the stream to a sink. It is strongly recommended to pass
+ * NULL in both dev and volume and not to set either
+ * PA_STREAM_START_MUTED nor PA_STREAM_START_UNMUTED -- unless these
+ * options are directly dependant on user input or configuration. If
+ * you follow this rule then the sound server will have the full
+ * flexibility to choose the device, volume and mute status
+ * automatically, based on server-side policies, heuristics and stored
+ * information from previous uses. Also the server may choose to
+ * reconfigure audio devices to make other sinks/sources or
+ * capabilities available to be able to accept the stream. Before
+ * 0.9.20 it was not defined whether the 'volume' parameter was
+ * interpreted relative to the sink's current volume or treated as
+ * absolute device volume. Since 0.9.20 it is an absolute volume when
+ * the sink is in flat volume mode, and relative otherwise, thus
+ * making sure the volume passed here has always the same semantics as
+ * the volume passed to pa_context_set_sink_input_volume(). */
int pa_stream_connect_playback(
pa_stream *s /**< The stream to connect to a sink */,
const char *dev /**< Name of the sink to connect to, or NULL for default */ ,
const pa_buffer_attr *attr /**< Buffering attributes, or NULL for default */,
pa_stream_flags_t flags /**< Additional flags, or 0 for default */,
- pa_cvolume *volume /**< Initial volume, or NULL for default */,
+ const pa_cvolume *volume /**< Initial volume, or NULL for default */,
pa_stream *sync_stream /**< Synchronize this stream with the specified one, or NULL for a standalone stream*/);
/** Connect the stream to a source */
@@ -418,15 +450,71 @@ int pa_stream_connect_record(
/** Disconnect a stream from a source/sink */
int pa_stream_disconnect(pa_stream *s);
-/** Write some data to the server (for playback sinks), if free_cb is
- * non-NULL this routine is called when all data has been written out
- * and an internal reference to the specified data is kept, the data
- * is not copied. If NULL, the data is copied into an internal
- * buffer. The client my freely seek around in the output buffer. For
+/** Prepare writing data to the server (for playback streams). This
+ * function may be used to optimize the number of memory copies when
+ * doing playback ("zero-copy"). It is recommended to call this
+ * function before each call to pa_stream_write(). Pass in the address
+ * to a pointer and an address of the number of bytes you want to
+ * write. On return the two values will contain a pointer where you
+ * can place the data to write and the maximum number of bytes you can
+ * write. On return *nbytes can be smaller or have the same value as
+ * you passed in. You need to be able to handle both cases. Accessing
+ * memory beyond the returned *nbytes value is invalid. Acessing the
+ * memory returned after the following pa_stream_write() or
+ * pa_stream_cancel_write() is invalid. On invocation only *nbytes
+ * needs to be initialized, on return both *data and *nbytes will be
+ * valid. If you place (size_t) -1 in *nbytes on invocation the memory
+ * size will be chosen automatically (which is recommended to
+ * do). After placing your data in the memory area returned call
+ * pa_stream_write() with data set to an address within this memory
+ * area and an nbytes value that is smaller or equal to what was
+ * returned by this function to actually execute the write. An
+ * invocation of pa_stream_write() should follow "quickly" on
+ * pa_stream_begin_write(). It is not recommended letting an unbounded
+ * amount of time pass after calling pa_stream_begin_write() and
+ * before calling pa_stream_write(). If you want to cancel a
+ * previously called pa_stream_begin_write() without calling
+ * pa_stream_write() use pa_stream_cancel_write(). Calling
+ * pa_stream_begin_write() twice without calling pa_stream_write() or
+ * pa_stream_cancel_write() in between will return exactly the same
+ * pointer/nbytes values.\since 0.9.16 */
+int pa_stream_begin_write(
+ pa_stream *p,
+ void **data,
+ size_t *nbytes);
+
+/** Reverses the effect of pa_stream_begin_write() dropping all data
+ * that has already been placed in the memory area returned by
+ * pa_stream_begin_write(). Only valid to call if
+ * pa_stream_begin_write() was called before and neither
+ * pa_stream_cancel_write() nor pa_stream_write() have been called
+ * yet. Accessing the memory previously returned by
+ * pa_stream_begin_write() after this call is invalid. Any further
+ * explicit freeing of the memory area is not necessary. \since
+ * 0.9.16 */
+int pa_stream_cancel_write(
+ pa_stream *p);
+
+/** Write some data to the server (for playback streams), if free_cb
+ * is non-NULL this routine is called when all data has been written
+ * out and an internal reference to the specified data is kept, the
+ * data is not copied. If NULL, the data is copied into an internal
+ * buffer. The client may freely seek around in the output buffer. For
* most applications passing 0 and PA_SEEK_RELATIVE as arguments for
- * offset and seek should be useful. Afte ther write call succeeded
- * the write index will be a the position after where this chunk of
- * data has been written to. */
+ * offset and seek should be useful. After the write call succeeded
+ * the write index will be at the position after where this chunk of
+ * data has been written to.
+ *
+ * As an optimization for avoiding needless memory copies you may call
+ * pa_stream_begin_write() before this call and then place your audio
+ * data directly in the memory area returned by that call. Then, pass
+ * a pointer to that memory area to pa_stream_write(). After the
+ * invocation of pa_stream_write() the memory area may no longer be
+ * accessed. Any further explicit freeing of the memory area is not
+ * necessary. It is OK to write the memory area returned by
+ * pa_stream_begin_write() only partially with this call, skipping
+ * bytes both at the end and at the beginning of the reserved memory
+ * area.*/
int pa_stream_write(
pa_stream *p /**< The stream to use */,
const void *data /**< The data to write */,
@@ -435,11 +523,12 @@ int pa_stream_write(
int64_t offset, /**< Offset for seeking, must be 0 for upload streams */
pa_seek_mode_t seek /**< Seek mode, must be PA_SEEK_RELATIVE for upload streams */);
-/** Read the next fragment from the buffer (for recording).
- * data will point to the actual data and length will contain the size
- * of the data in bytes (which can be less than a complete framgnet).
- * Use pa_stream_drop() to actually remove the data from the
- * buffer. If no data is available will return a NULL pointer */
+/** Read the next fragment from the buffer (for recording streams).
+ * data will point to the actual data and nbytes will contain the size
+ * of the data in bytes (which can be less or more than a complete
+ * fragment). Use pa_stream_drop() to actually remove the data from
+ * the buffer. If no data is available this will return a NULL
+ * pointer */
int pa_stream_peek(
pa_stream *p /**< The stream to use */,
const void **data /**< Pointer to pointer that will point to data */,
@@ -455,7 +544,10 @@ size_t pa_stream_writable_size(pa_stream *p);
/** Return the number of bytes that may be read using pa_stream_peek()*/
size_t pa_stream_readable_size(pa_stream *p);
-/** Drain a playback stream. Use this for notification when the buffer is empty */
+/** Drain a playback stream. Use this for notification when the
+ * playback buffer is empty after playing all the audio in the buffer.
+ * Please note that only one drain operation per stream may be issued
+ * at a time. */
pa_operation* pa_stream_drain(pa_stream *s, pa_stream_success_cb_t cb, void *userdata);
/** Request a timing info structure update for a stream. Use
@@ -533,10 +625,10 @@ void pa_stream_set_buffer_attr_callback(pa_stream *p, pa_stream_notify_cb_t cb,
* of the stream it will be created in corked state. */
pa_operation* pa_stream_cork(pa_stream *s, int b, pa_stream_success_cb_t cb, void *userdata);
-/** Flush the playback buffer of this stream. Most of the time you're
- * better off using the parameter delta of pa_stream_write() instead
- * of this function. Available on both playback and recording
- * streams. */
+/** Flush the playback buffer of this stream. This discards any audio
+ * in the buffer. Most of the time you're better off using the parameter
+ * delta of pa_stream_write() instead of this function. Available on both
+ * playback and recording streams. */
pa_operation* pa_stream_flush(pa_stream *s, pa_stream_success_cb_t cb, void *userdata);
/** Reenable prebuffering as specified in the pa_buffer_attr
@@ -618,6 +710,9 @@ const pa_sample_spec* pa_stream_get_sample_spec(pa_stream *s);
/** Return a pointer to the stream's channel map. */
const pa_channel_map* pa_stream_get_channel_map(pa_stream *s);
+/** Return a pointer to the stream's format \since 1.0 */
+const pa_format_info* pa_stream_get_format_info(pa_stream *s);
+
/** Return the per-stream server-side buffer metrics of the
* stream. Only valid after the stream has been connected successfuly
* and if the server is at least PulseAudio 0.9. This will return the
@@ -640,7 +735,7 @@ pa_operation *pa_stream_set_buffer_attr(pa_stream *s, const pa_buffer_attr *attr
/** Change the stream sampling rate during playback. You need to pass
* PA_STREAM_VARIABLE_RATE in the flags parameter of
- * pa_stream_connect() if you plan to use this function. Only valid
+ * pa_stream_connect_...() if you plan to use this function. Only valid
* after the stream has been connected successfully and if the server
* is at least PulseAudio 0.9.8. \since 0.9.8 */
pa_operation *pa_stream_update_sample_rate(pa_stream *s, uint32_t rate, pa_stream_success_cb_t cb, void *userdata);
@@ -663,8 +758,9 @@ pa_operation *pa_stream_proplist_remove(pa_stream *s, const char *const keys[],
* 0.9.11 */
int pa_stream_set_monitor_stream(pa_stream *s, uint32_t sink_input_idx);
-/** Return what has been set with pa_stream_set_monitor_stream()
- * ebfore. \since 0.9.11 */
+/** Return the sink input index previously set with
+ * pa_stream_set_monitor_stream().
+ * \since 0.9.11 */
uint32_t pa_stream_get_monitor_stream(pa_stream *s);
PA_C_DECL_END
diff --git a/src/pulse/subscribe.c b/src/pulse/subscribe.c
index 203bc928..a6ad238c 100644
--- a/src/pulse/subscribe.c
+++ b/src/pulse/subscribe.c
@@ -25,13 +25,10 @@
#include <stdio.h>
-#include <pulse/gccmacro.h>
-
#include <pulsecore/macro.h>
#include <pulsecore/pstream-util.h>
#include "internal.h"
-
#include "subscribe.h"
void pa_command_subscribe_event(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
diff --git a/src/pulse/subscribe.h b/src/pulse/subscribe.h
index 44ed24ae..f1e17ca1 100644
--- a/src/pulse/subscribe.h
+++ b/src/pulse/subscribe.h
@@ -45,7 +45,10 @@
*/
/** \file
- * Daemon introspection event subscription subsystem. */
+ * Daemon introspection event subscription subsystem.
+ *
+ * See also \subpage subscribe
+ */
PA_C_DECL_BEGIN
diff --git a/src/pulse/thread-mainloop.c b/src/pulse/thread-mainloop.c
index c77cc64e..b07ad789 100644
--- a/src/pulse/thread-mainloop.c
+++ b/src/pulse/thread-mainloop.c
@@ -24,30 +24,28 @@
#include <config.h>
#endif
+#ifndef OS_IS_WIN32
+#include <pthread.h>
+#endif
+
#include <signal.h>
#include <stdio.h>
-#ifdef HAVE_POLL_H
-#include <poll.h>
-#else
-#include <pulsecore/poll.h>
-#endif
-
#include <pulse/xmalloc.h>
#include <pulse/mainloop.h>
#include <pulse/i18n.h>
#include <pulsecore/log.h>
-#include <pulsecore/hashmap.h>
#include <pulsecore/thread.h>
#include <pulsecore/mutex.h>
#include <pulsecore/macro.h>
+#include <pulsecore/poll.h>
#include "thread-mainloop.h"
struct pa_threaded_mainloop {
pa_mainloop *real_mainloop;
- int n_waiting;
+ volatile int n_waiting, n_waiting_for_accept;
pa_thread* thread;
pa_mutex* mutex;
@@ -68,7 +66,7 @@ static int poll_func(struct pollfd *ufds, unsigned long nfds, int timeout, void
* avahi_simple_poll_quit() can succeed from another thread. */
pa_mutex_unlock(mutex);
- r = poll(ufds, nfds, timeout);
+ r = pa_poll(ufds, nfds, timeout);
pa_mutex_lock(mutex);
return r;
@@ -112,6 +110,7 @@ pa_threaded_mainloop *pa_threaded_mainloop_new(void) {
pa_mainloop_set_poll_func(m->real_mainloop, poll_func, m->mutex);
m->n_waiting = 0;
+ m->n_waiting_for_accept = 0;
return m;
}
@@ -141,7 +140,7 @@ int pa_threaded_mainloop_start(pa_threaded_mainloop *m) {
pa_assert(!m->thread || !pa_thread_is_running(m->thread));
- if (!(m->thread = pa_thread_new(thread, m)))
+ if (!(m->thread = pa_thread_new("threaded-ml", thread, m)))
return -1;
return 0;
@@ -181,15 +180,21 @@ void pa_threaded_mainloop_unlock(pa_threaded_mainloop *m) {
pa_mutex_unlock(m->mutex);
}
+/* Called with the lock taken */
void pa_threaded_mainloop_signal(pa_threaded_mainloop *m, int wait_for_accept) {
pa_assert(m);
pa_cond_signal(m->cond, 1);
- if (wait_for_accept && m->n_waiting > 0)
- pa_cond_wait(m->accept_cond, m->mutex);
+ if (wait_for_accept) {
+ m->n_waiting_for_accept ++;
+
+ while (m->n_waiting_for_accept > 0)
+ pa_cond_wait(m->accept_cond, m->mutex);
+ }
}
+/* Called with the lock taken */
void pa_threaded_mainloop_wait(pa_threaded_mainloop *m) {
pa_assert(m);
@@ -204,12 +209,16 @@ void pa_threaded_mainloop_wait(pa_threaded_mainloop *m) {
m->n_waiting --;
}
+/* Called with the lock taken */
void pa_threaded_mainloop_accept(pa_threaded_mainloop *m) {
pa_assert(m);
/* Make sure that this function is not called from the helper thread */
pa_assert(!m->thread || !pa_thread_is_running(m->thread) || !in_worker(m));
+ pa_assert(m->n_waiting_for_accept > 0);
+ m->n_waiting_for_accept --;
+
pa_cond_signal(m->accept_cond, 0);
}
diff --git a/src/pulse/thread-mainloop.h b/src/pulse/thread-mainloop.h
index 8eddce4c..f911228b 100644
--- a/src/pulse/thread-mainloop.h
+++ b/src/pulse/thread-mainloop.h
@@ -137,15 +137,19 @@ PA_C_DECL_BEGIN
* The main function, my_drain_stream_func(), will wait for the callback to
* be called using pa_threaded_mainloop_wait().
*
- * If your application is multi-threaded, then this waiting must be done
- * inside a while loop. The reason for this is that multiple threads might be
- * using pa_threaded_mainloop_wait() at the same time. Each thread must
- * therefore verify that it was its callback that was invoked.
+ * If your application is multi-threaded, then this waiting must be
+ * done inside a while loop. The reason for this is that multiple
+ * threads might be using pa_threaded_mainloop_wait() at the same
+ * time. Each thread must therefore verify that it was its callback
+ * that was invoked. Also the underlying OS synchronization primitives
+ * are usually not free of spurious wake-ups, so a
+ * pa_threaded_mainloop_wait() must be called within a loop even if
+ * you have only one thread waiting.
*
* The callback, my_drain_callback(), indicates to the main function that it
* has been called using pa_threaded_mainloop_signal().
*
- * As you can see, both pa_threaded_mainloop_wait() may only be called with
+ * As you can see, pa_threaded_mainloop_wait() may only be called with
* the lock held. The same thing is true for pa_threaded_mainloop_signal(),
* but as the lock is held before the callback is invoked, you do not have to
* deal with that.
@@ -235,7 +239,10 @@ PA_C_DECL_BEGIN
* A thread based event loop implementation based on pa_mainloop. The
* event loop is run in a helper thread in the background. A few
* synchronization primitives are available to access the objects
- * attached to the event loop safely. */
+ * attached to the event loop safely.
+ *
+ * See also \subpage threaded_mainloop
+ */
/** An opaque threaded main loop object */
typedef struct pa_threaded_mainloop pa_threaded_mainloop;
@@ -246,7 +253,7 @@ typedef struct pa_threaded_mainloop pa_threaded_mainloop;
pa_threaded_mainloop *pa_threaded_mainloop_new(void);
/** Free a threaded main loop object. If the event loop thread is
- * still running, it is terminated using pa_threaded_mainloop_stop()
+ * still running, terminate it with pa_threaded_mainloop_stop()
* first. */
void pa_threaded_mainloop_free(pa_threaded_mainloop* m);
@@ -274,7 +281,9 @@ void pa_threaded_mainloop_unlock(pa_threaded_mainloop *m);
* inside the event loop thread. Prior to this call the event loop
* object needs to be locked using pa_threaded_mainloop_lock(). While
* waiting the lock will be released, immediately before returning it
- * will be acquired again. */
+ * will be acquired again. This function may spuriously wake up even
+ * without _signal() being called. You need to make sure to handle
+ * that! */
void pa_threaded_mainloop_wait(pa_threaded_mainloop *m);
/** Signal all threads waiting for a signalling event in
@@ -293,7 +302,9 @@ void pa_threaded_mainloop_accept(pa_threaded_mainloop *m);
/** Return the return value as specified with the main loop's quit() routine. */
int pa_threaded_mainloop_get_retval(pa_threaded_mainloop *m);
-/** Return the abstract main loop abstraction layer vtable for this main loop. */
+/** Return the abstract main loop abstraction layer vtable for this
+ main loop. No need to free the API as it is owned by the loop
+ and is destroyed when the loop is freed. */
pa_mainloop_api* pa_threaded_mainloop_get_api(pa_threaded_mainloop*m);
/** Returns non-zero when called from withing the event loop thread. \since 0.9.7 */
diff --git a/src/pulse/timeval.c b/src/pulse/timeval.c
index 376cf13c..b405a70a 100644
--- a/src/pulse/timeval.c
+++ b/src/pulse/timeval.c
@@ -31,34 +31,28 @@
#include <windows.h>
#endif
-#include <pulsecore/winsock.h>
#include <pulsecore/macro.h>
+#include <pulsecore/core-util.h>
#include "timeval.h"
struct timeval *pa_gettimeofday(struct timeval *tv) {
-#ifdef HAVE_GETTIMEOFDAY
pa_assert(tv);
- pa_assert_se(gettimeofday(tv, NULL) == 0);
- return tv;
-#elif defined(OS_IS_WIN32)
+#if defined(OS_IS_WIN32)
/*
* Copied from implementation by Steven Edwards (LGPL).
* Found on wine mailing list.
*/
-
#if defined(_MSC_VER) || defined(__BORLANDC__)
#define EPOCHFILETIME (116444736000000000i64)
#else
#define EPOCHFILETIME (116444736000000000LL)
#endif
-
- FILETIME ft;
- LARGE_INTEGER li;
- __int64 t;
-
- pa_assert(tv);
+{
+ FILETIME ft;
+ LARGE_INTEGER li;
+ int64_t t;
GetSystemTimeAsFileTime(&ft);
li.LowPart = ft.dwLowDateTime;
@@ -68,11 +62,14 @@ struct timeval *pa_gettimeofday(struct timeval *tv) {
t /= 10; /* In microseconds */
tv->tv_sec = (time_t) (t / PA_USEC_PER_SEC);
tv->tv_usec = (suseconds_t) (t % PA_USEC_PER_SEC);
-
- return tv;
+}
+#elif defined(HAVE_GETTIMEOFDAY)
+ pa_assert_se(gettimeofday(tv, NULL) == 0);
#else
#error "Platform lacks gettimeofday() or equivalent function."
#endif
+
+ return tv;
}
pa_usec_t pa_timeval_diff(const struct timeval *a, const struct timeval *b) {
@@ -82,7 +79,7 @@ pa_usec_t pa_timeval_diff(const struct timeval *a, const struct timeval *b) {
pa_assert(b);
/* Check which whan is the earlier time and swap the two arguments if required. */
- if (pa_timeval_cmp(a, b) < 0) {
+ if (PA_UNLIKELY(pa_timeval_cmp(a, b) < 0)) {
const struct timeval *c;
c = a;
a = b;
@@ -94,9 +91,9 @@ pa_usec_t pa_timeval_diff(const struct timeval *a, const struct timeval *b) {
/* Calculate the microsecond difference */
if (a->tv_usec > b->tv_usec)
- r += ((pa_usec_t) a->tv_usec - (pa_usec_t) b->tv_usec);
+ r += (pa_usec_t) a->tv_usec - (pa_usec_t) b->tv_usec;
else if (a->tv_usec < b->tv_usec)
- r -= ((pa_usec_t) b->tv_usec - (pa_usec_t) a->tv_usec);
+ r -= (pa_usec_t) b->tv_usec - (pa_usec_t) a->tv_usec;
return r;
}
@@ -128,45 +125,77 @@ pa_usec_t pa_timeval_age(const struct timeval *tv) {
}
struct timeval* pa_timeval_add(struct timeval *tv, pa_usec_t v) {
- unsigned long secs;
+ time_t secs;
pa_assert(tv);
- secs = (unsigned long) (v/PA_USEC_PER_SEC);
- tv->tv_sec += (time_t) secs;
- v -= ((pa_usec_t) secs) * PA_USEC_PER_SEC;
+ secs = (time_t) (v/PA_USEC_PER_SEC);
+
+ if (PA_UNLIKELY(tv->tv_sec > PA_INT_TYPE_MAX(time_t) - secs))
+ goto overflow;
+ tv->tv_sec += secs;
+ v -= (pa_usec_t) secs * PA_USEC_PER_SEC;
tv->tv_usec += (suseconds_t) v;
/* Normalize */
- while ((unsigned) tv->tv_usec >= PA_USEC_PER_SEC) {
+ while ((pa_usec_t) tv->tv_usec >= PA_USEC_PER_SEC) {
+
+ if (PA_UNLIKELY(tv->tv_sec >= PA_INT_TYPE_MAX(time_t)))
+ goto overflow;
+
tv->tv_sec++;
tv->tv_usec -= (suseconds_t) PA_USEC_PER_SEC;
}
return tv;
+
+overflow:
+ tv->tv_sec = PA_INT_TYPE_MAX(time_t);
+ tv->tv_usec = (suseconds_t) (PA_USEC_PER_SEC-1);
+ return tv;
}
struct timeval* pa_timeval_sub(struct timeval *tv, pa_usec_t v) {
- unsigned long secs;
+ time_t secs;
pa_assert(tv);
- secs = (unsigned long) (v/PA_USEC_PER_SEC);
- tv->tv_sec -= (time_t) secs;
- v -= ((pa_usec_t) secs) * PA_USEC_PER_SEC;
+ secs = (time_t) (v/PA_USEC_PER_SEC);
+
+ if (PA_UNLIKELY(tv->tv_sec < secs))
+ goto underflow;
+
+ tv->tv_sec -= secs;
+ v -= (pa_usec_t) secs * PA_USEC_PER_SEC;
if (tv->tv_usec >= (suseconds_t) v)
tv->tv_usec -= (suseconds_t) v;
else {
+
+ if (PA_UNLIKELY(tv->tv_sec <= 0))
+ goto underflow;
+
tv->tv_sec --;
tv->tv_usec += (suseconds_t) (PA_USEC_PER_SEC - v);
}
return tv;
+
+underflow:
+ tv->tv_sec = 0;
+ tv->tv_usec = 0;
+ return tv;
}
struct timeval* pa_timeval_store(struct timeval *tv, pa_usec_t v) {
pa_assert(tv);
+ if (PA_UNLIKELY(v == PA_USEC_INVALID)) {
+ tv->tv_sec = PA_INT_TYPE_MAX(time_t);
+ tv->tv_usec = (suseconds_t) (PA_USEC_PER_SEC-1);
+
+ return tv;
+ }
+
tv->tv_sec = (time_t) (v / PA_USEC_PER_SEC);
tv->tv_usec = (suseconds_t) (v % PA_USEC_PER_SEC);
@@ -174,7 +203,9 @@ struct timeval* pa_timeval_store(struct timeval *tv, pa_usec_t v) {
}
pa_usec_t pa_timeval_load(const struct timeval *tv) {
- pa_assert(tv);
+
+ if (PA_UNLIKELY(!tv))
+ return PA_USEC_INVALID;
return
(pa_usec_t) tv->tv_sec * PA_USEC_PER_SEC +
diff --git a/src/pulse/timeval.h b/src/pulse/timeval.h
index 651da953..42014638 100644
--- a/src/pulse/timeval.h
+++ b/src/pulse/timeval.h
@@ -40,20 +40,26 @@ PA_C_DECL_BEGIN
#define PA_USEC_PER_SEC ((pa_usec_t) 1000000ULL)
/** The number of nanoseconds in a second */
-#define PA_NSEC_PER_SEC ((pa_usec_t) 1000000000ULL)
+#define PA_NSEC_PER_SEC ((unsigned long long) 1000000000ULL)
/** The number of microseconds in a millisecond */
#define PA_USEC_PER_MSEC ((pa_usec_t) 1000ULL)
/** The number of nanoseconds in a millisecond */
-#define PA_NSEC_PER_MSEC ((pa_usec_t) 1000000ULL)
+#define PA_NSEC_PER_MSEC ((unsigned long long) 1000000ULL)
/** The number of nanoseconds in a microsecond */
-#define PA_NSEC_PER_USEC ((pa_usec_t) 1000ULL)
+#define PA_NSEC_PER_USEC ((unsigned long long) 1000ULL)
+
+/** Invalid time in usec. \since 0.9.15 */
+#define PA_USEC_INVALID ((pa_usec_t) -1)
+
+/** Biggest time in usec. \since 0.9.18 */
+#define PA_USEC_MAX ((pa_usec_t) -2)
struct timeval;
-/** Return the current timestamp, just like UNIX gettimeofday() */
+/** Return the current wallclock timestamp, just like UNIX gettimeofday(). */
struct timeval *pa_gettimeofday(struct timeval *tv);
/** Calculate the difference between the two specified timeval
@@ -66,10 +72,10 @@ int pa_timeval_cmp(const struct timeval *a, const struct timeval *b) PA_GCC_PURE
/** Return the time difference between now and the specified timestamp */
pa_usec_t pa_timeval_age(const struct timeval *tv);
-/** Add the specified time inmicroseconds to the specified timeval structure */
+/** Add the specified time in microseconds to the specified timeval structure */
struct timeval* pa_timeval_add(struct timeval *tv, pa_usec_t v);
-/** Subtract the specified time inmicroseconds to the specified timeval structure. \since 0.9.11 */
+/** Subtract the specified time in microseconds to the specified timeval structure. \since 0.9.11 */
struct timeval* pa_timeval_sub(struct timeval *tv, pa_usec_t v);
/** Store the specified uec value in the timeval struct. \since 0.9.7 */
diff --git a/src/pulse/utf8.c b/src/pulse/utf8.c
index 6b58bde3..fe7bcd26 100644
--- a/src/pulse/utf8.c
+++ b/src/pulse/utf8.c
@@ -120,10 +120,8 @@ static char* utf8_validate(const char *str, char *output) {
size = 4;
min = (1 << 16);
val = (uint32_t) (*p & 0x07);
- } else {
- size = 1;
+ } else
goto error;
- }
p++;
if (!is_continuation_char(*p))
@@ -150,12 +148,9 @@ ONE_REMAINING:
if (o) {
memcpy(o, last, (size_t) size);
- o += size - 1;
+ o += size;
}
- if (o)
- o++;
-
continue;
error:
diff --git a/src/pulse/util.c b/src/pulse/util.c
index 6f1e40a9..6656bc3f 100644
--- a/src/pulse/util.c
+++ b/src/pulse/util.c
@@ -37,10 +37,6 @@
#include <pwd.h>
#endif
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-
#ifdef HAVE_NETDB_H
#include <netdb.h>
#endif
@@ -53,46 +49,55 @@
#include <sys/prctl.h>
#endif
+#ifdef OS_IS_DARWIN
+#include <libgen.h>
+#include <sys/sysctl.h>
+#endif
+
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
-#include <pulsecore/winsock.h>
-#include <pulsecore/core-error.h>
-#include <pulsecore/log.h>
+#include <pulsecore/socket.h>
#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
+#include <pulsecore/usergroup.h>
#include "util.h"
char *pa_get_user_name(char *s, size_t l) {
const char *p;
+ char *name = NULL;
+#ifdef OS_IS_WIN32
char buf[1024];
+#endif
#ifdef HAVE_PWD_H
- struct passwd pw, *r;
+ struct passwd *r;
#endif
pa_assert(s);
pa_assert(l > 0);
- if (!(p = (getuid() == 0 ? "root" : NULL)) &&
- !(p = getenv("USER")) &&
- !(p = getenv("LOGNAME")) &&
- !(p = getenv("USERNAME"))) {
+ p = NULL;
+#ifdef HAVE_GETUID
+ p = getuid() == 0 ? "root" : NULL;
+#endif
+ if (!p) p = getenv("USER");
+ if (!p) p = getenv("LOGNAME");
+ if (!p) p = getenv("USERNAME");
+
+ if (p) {
+ name = pa_strlcpy(s, p, l);
+ } else {
#ifdef HAVE_PWD_H
-#ifdef HAVE_GETPWUID_R
- if (getpwuid_r(getuid(), &pw, buf, sizeof(buf), &r) != 0 || !r) {
-#else
- /* XXX Not thread-safe, but needed on OSes (e.g. FreeBSD 4.X)
- * that do not support getpwuid_r. */
- if ((r = getpwuid(getuid())) == NULL) {
-#endif
+ if ((r = pa_getpwuid_malloc(getuid())) == NULL) {
pa_snprintf(s, l, "%lu", (unsigned long) getuid());
return s;
}
- p = r->pw_name;
+ name = pa_strlcpy(s, r->pw_name, l);
+ pa_getpwuid_free(r);
#elif defined(OS_IS_WIN32) /* HAVE_PWD_H */
DWORD size = sizeof(buf);
@@ -102,7 +107,7 @@ char *pa_get_user_name(char *s, size_t l) {
return NULL;
}
- p = buf;
+ name = pa_strlcpy(s, buf, l);
#else /* HAVE_PWD_H */
@@ -110,7 +115,7 @@ char *pa_get_user_name(char *s, size_t l) {
#endif /* HAVE_PWD_H */
}
- return pa_strlcpy(s, p, l);
+ return name;
}
char *pa_get_host_name(char *s, size_t l) {
@@ -127,10 +132,9 @@ char *pa_get_host_name(char *s, size_t l) {
char *pa_get_home_dir(char *s, size_t l) {
char *e;
-
#ifdef HAVE_PWD_H
- char buf[1024];
- struct passwd pw, *r;
+ char *dir;
+ struct passwd *r;
#endif
pa_assert(s);
@@ -143,22 +147,19 @@ char *pa_get_home_dir(char *s, size_t l) {
return pa_strlcpy(s, e, l);
#ifdef HAVE_PWD_H
-
errno = 0;
-#ifdef HAVE_GETPWUID_R
- if (getpwuid_r(getuid(), &pw, buf, sizeof(buf), &r) != 0 || !r) {
-#else
- /* XXX Not thread-safe, but needed on OSes (e.g. FreeBSD 4.X)
- * that do not support getpwuid_r. */
- if ((r = getpwuid(getuid())) == NULL) {
-#endif
+ if ((r = pa_getpwuid_malloc(getuid())) == NULL) {
if (!errno)
errno = ENOENT;
return NULL;
}
- return pa_strlcpy(s, r->pw_dir, l);
+ dir = pa_strlcpy(s, r->pw_dir, l);
+
+ pa_getpwuid_free(r);
+
+ return dir;
#else /* HAVE_PWD_H */
errno = ENOENT;
@@ -191,7 +192,18 @@ char *pa_get_binary_name(char *s, size_t l) {
return s;
}
}
+#endif
+#ifdef __FreeBSD__
+ {
+ char *rp;
+
+ if ((rp = pa_readlink("/proc/curproc/file"))) {
+ pa_strlcpy(s, pa_path_get_filename(rp), l);
+ pa_xfree(rp);
+ return s;
+ }
+ }
#endif
#if defined(HAVE_SYS_PRCTL_H) && defined(PR_GET_NAME)
@@ -212,6 +224,27 @@ char *pa_get_binary_name(char *s, size_t l) {
}
#endif
+#ifdef OS_IS_DARWIN
+ {
+ int mib[] = { CTL_KERN, KERN_PROCARGS, getpid(), 0 };
+ size_t len, nmib = (sizeof(mib) / sizeof(mib[0])) - 1;
+ char *buf;
+
+ sysctl(mib, nmib, NULL, &len, NULL, 0);
+ buf = (char *) pa_xmalloc(len);
+
+ if (sysctl(mib, nmib, buf, &len, NULL, 0) == 0) {
+ pa_strlcpy(s, basename(buf), l);
+ pa_xfree(buf);
+ return s;
+ }
+
+ pa_xfree(buf);
+
+ /* fall thru */
+ }
+#endif /* OS_IS_DARWIN */
+
errno = ENOENT;
return NULL;
}
diff --git a/src/pulse/util.h b/src/pulse/util.h
index ad85653d..e490d56d 100644
--- a/src/pulse/util.h
+++ b/src/pulse/util.h
@@ -26,7 +26,6 @@
#include <stddef.h>
#include <pulse/cdecl.h>
-#include <pulse/gccmacro.h>
#include <pulse/version.h>
/** \file
diff --git a/src/pulse/version.h.in b/src/pulse/version.h.in
index 3143e98e..7e00c5e1 100644
--- a/src/pulse/version.h.in
+++ b/src/pulse/version.h.in
@@ -57,15 +57,15 @@ const char* pa_get_library_version(void);
/** The minor version of PA. \since 0.9.15 */
#define PA_MINOR @PA_MINOR@
-/** The micro version of PA. \since 0.9.15 */
-#define PA_MICRO @PA_MICRO@
+/** The micro version of PA (will always be 0 from v1.0 onwards). \since 0.9.15 */
+#define PA_MICRO 0
/** Evaluates to TRUE if the PulseAudio library version is equal or
* newer than the specified. \since 0.9.16 */
#define PA_CHECK_VERSION(major,minor,micro) \
((PA_MAJOR > (major)) || \
- (PA_MAJOR == (major) && CA_MINOR > (minor)) || \
- (PA_MAJOR == (major) && CA_MINOR == (minor) && CA_MICRO >= (micro)))
+ (PA_MAJOR == (major) && PA_MINOR > (minor)) || \
+ (PA_MAJOR == (major) && PA_MINOR == (minor) && PA_MICRO >= (micro)))
PA_C_DECL_END
diff --git a/src/pulse/volume.c b/src/pulse/volume.c
index 64688e0b..82e57572 100644
--- a/src/pulse/volume.c
+++ b/src/pulse/volume.c
@@ -25,10 +25,13 @@
#include <stdio.h>
#include <string.h>
+#include <math.h>
#include <pulse/i18n.h>
+
#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
+#include <pulsecore/sample-util.h>
#include "volume.h"
@@ -38,6 +41,10 @@ int pa_cvolume_equal(const pa_cvolume *a, const pa_cvolume *b) {
pa_assert(b);
pa_return_val_if_fail(pa_cvolume_valid(a), 0);
+
+ if (PA_UNLIKELY(a == b))
+ return 1;
+
pa_return_val_if_fail(pa_cvolume_valid(b), 0);
if (a->channels != b->channels)
@@ -58,7 +65,7 @@ pa_cvolume* pa_cvolume_init(pa_cvolume *a) {
a->channels = 0;
for (c = 0; c < PA_CHANNELS_MAX; c++)
- a->values[c] = (pa_volume_t) -1;
+ a->values[c] = PA_VOLUME_INVALID;
return a;
}
@@ -73,7 +80,9 @@ pa_cvolume* pa_cvolume_set(pa_cvolume *a, unsigned channels, pa_volume_t v) {
a->channels = (uint8_t) channels;
for (i = 0; i < a->channels; i++)
- a->values[i] = v;
+ /* Clamp in case there is stale data that exceeds the current
+ * PA_VOLUME_MAX */
+ a->values[i] = PA_CLAMP_VOLUME(v);
return a;
}
@@ -120,7 +129,7 @@ pa_volume_t pa_cvolume_avg_mask(const pa_cvolume *a, const pa_channel_map *cm, p
}
pa_volume_t pa_cvolume_max(const pa_cvolume *a) {
- pa_volume_t m = 0;
+ pa_volume_t m = PA_VOLUME_MUTED;
unsigned c;
pa_assert(a);
@@ -133,9 +142,23 @@ pa_volume_t pa_cvolume_max(const pa_cvolume *a) {
return m;
}
+pa_volume_t pa_cvolume_min(const pa_cvolume *a) {
+ pa_volume_t m = PA_VOLUME_MAX;
+ unsigned c;
+
+ pa_assert(a);
+ pa_return_val_if_fail(pa_cvolume_valid(a), PA_VOLUME_MUTED);
+
+ for (c = 0; c < a->channels; c++)
+ if (a->values[c] < m)
+ m = a->values[c];
+
+ return m;
+}
+
pa_volume_t pa_cvolume_max_mask(const pa_cvolume *a, const pa_channel_map *cm, pa_channel_position_mask_t mask) {
- pa_volume_t m = 0;
- unsigned c, n;
+ pa_volume_t m = PA_VOLUME_MUTED;
+ unsigned c;
pa_assert(a);
@@ -144,7 +167,7 @@ pa_volume_t pa_cvolume_max_mask(const pa_cvolume *a, const pa_channel_map *cm, p
pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(a, cm), PA_VOLUME_MUTED);
- for (c = n = 0; c < a->channels; c++) {
+ for (c = 0; c < a->channels; c++) {
if (!(PA_CHANNEL_POSITION_MASK(cm->map[c]) & mask))
continue;
@@ -156,17 +179,48 @@ pa_volume_t pa_cvolume_max_mask(const pa_cvolume *a, const pa_channel_map *cm, p
return m;
}
+pa_volume_t pa_cvolume_min_mask(const pa_cvolume *a, const pa_channel_map *cm, pa_channel_position_mask_t mask) {
+ pa_volume_t m = PA_VOLUME_MAX;
+ unsigned c;
+
+ pa_assert(a);
+
+ if (!cm)
+ return pa_cvolume_min(a);
+
+ pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(a, cm), PA_VOLUME_MUTED);
+
+ for (c = 0; c < a->channels; c++) {
+
+ if (!(PA_CHANNEL_POSITION_MASK(cm->map[c]) & mask))
+ continue;
+
+ if (a->values[c] < m)
+ m = a->values[c];
+ }
+
+ return m;
+}
+
pa_volume_t pa_sw_volume_multiply(pa_volume_t a, pa_volume_t b) {
- return pa_sw_volume_from_linear(pa_sw_volume_to_linear(a) * pa_sw_volume_to_linear(b));
+
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(a), PA_VOLUME_INVALID);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(b), PA_VOLUME_INVALID);
+
+ /* cbrt((a/PA_VOLUME_NORM)^3*(b/PA_VOLUME_NORM)^3)*PA_VOLUME_NORM = a*b/PA_VOLUME_NORM */
+
+ return (pa_volume_t) PA_CLAMP_VOLUME((((uint64_t) a * (uint64_t) b + (uint64_t) PA_VOLUME_NORM / 2ULL) / (uint64_t) PA_VOLUME_NORM));
}
pa_volume_t pa_sw_volume_divide(pa_volume_t a, pa_volume_t b) {
- double v = pa_sw_volume_to_linear(b);
- if (v <= 0)
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(a), PA_VOLUME_INVALID);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(b), PA_VOLUME_INVALID);
+
+ if (b <= PA_VOLUME_MUTED)
return 0;
- return pa_sw_volume_from_linear(pa_sw_volume_to_linear(a) / v);
+ return (pa_volume_t) (((uint64_t) a * (uint64_t) PA_VOLUME_NORM + (uint64_t) b / 2ULL) / (uint64_t) b);
}
/* Amplitude, not power */
@@ -187,6 +241,8 @@ pa_volume_t pa_sw_volume_from_dB(double dB) {
double pa_sw_volume_to_dB(pa_volume_t v) {
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(v), PA_DECIBEL_MININFTY);
+
if (v <= PA_VOLUME_MUTED)
return PA_DECIBEL_MININFTY;
@@ -203,14 +259,19 @@ pa_volume_t pa_sw_volume_from_linear(double v) {
*
* http://www.robotplanet.dk/audio/audio_gui_design/
* http://lists.linuxaudio.org/pipermail/linux-audio-dev/2009-May/thread.html#23151
+ *
+ * We make sure that the conversion to linear and back yields the
+ * same volume value! That's why we need the lround() below!
*/
- return (pa_volume_t) (cbrt(v) * PA_VOLUME_NORM);
+ return (pa_volume_t) PA_CLAMP_VOLUME((uint64_t) lround(cbrt(v) * PA_VOLUME_NORM));
}
double pa_sw_volume_to_linear(pa_volume_t v) {
double f;
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(v), 0.0);
+
if (v <= PA_VOLUME_MUTED)
return 0.0;
@@ -244,7 +305,7 @@ char *pa_cvolume_snprint(char *s, size_t l, const pa_cvolume *c) {
l -= pa_snprintf(e, l, "%s%u: %3u%%",
first ? "" : " ",
channel,
- (c->values[channel]*100)/PA_VOLUME_NORM);
+ (c->values[channel]*100+PA_VOLUME_NORM/2)/PA_VOLUME_NORM);
e = strchr(e, 0);
first = FALSE;
@@ -259,12 +320,12 @@ char *pa_volume_snprint(char *s, size_t l, pa_volume_t v) {
pa_init_i18n();
- if (v == (pa_volume_t) -1) {
+ if (!PA_VOLUME_IS_VALID(v)) {
pa_snprintf(s, l, _("(invalid)"));
return s;
}
- pa_snprintf(s, l, "%3u%%", (v*100)/PA_VOLUME_NORM);
+ pa_snprintf(s, l, "%3u%%", (v*100+PA_VOLUME_NORM/2)/PA_VOLUME_NORM);
return s;
}
@@ -309,14 +370,13 @@ char *pa_sw_volume_snprint_dB(char *s, size_t l, pa_volume_t v) {
pa_init_i18n();
- if (v == (pa_volume_t) -1) {
+ if (!PA_VOLUME_IS_VALID(v)) {
pa_snprintf(s, l, _("(invalid)"));
return s;
}
f = pa_sw_volume_to_dB(v);
- pa_snprintf(s, l, "%0.2f dB",
- isinf(f) < 0 || f <= PA_DECIBEL_MININFTY ? -INFINITY : f);
+ pa_snprintf(s, l, "%0.2f dB", isinf(f) < 0 || f <= PA_DECIBEL_MININFTY ? -INFINITY : f);
return s;
}
@@ -326,6 +386,7 @@ int pa_cvolume_channels_equal_to(const pa_cvolume *a, pa_volume_t v) {
pa_assert(a);
pa_return_val_if_fail(pa_cvolume_valid(a), 0);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(v), 0);
for (c = 0; c < a->channels; c++)
if (a->values[c] != v)
@@ -344,7 +405,7 @@ pa_cvolume *pa_sw_cvolume_multiply(pa_cvolume *dest, const pa_cvolume *a, const
pa_return_val_if_fail(pa_cvolume_valid(a), NULL);
pa_return_val_if_fail(pa_cvolume_valid(b), NULL);
- for (i = 0; i < a->channels && i < b->channels && i < PA_CHANNELS_MAX; i++)
+ for (i = 0; i < a->channels && i < b->channels; i++)
dest->values[i] = pa_sw_volume_multiply(a->values[i], b->values[i]);
dest->channels = (uint8_t) i;
@@ -352,6 +413,23 @@ pa_cvolume *pa_sw_cvolume_multiply(pa_cvolume *dest, const pa_cvolume *a, const
return dest;
}
+pa_cvolume *pa_sw_cvolume_multiply_scalar(pa_cvolume *dest, const pa_cvolume *a, pa_volume_t b) {
+ unsigned i;
+
+ pa_assert(dest);
+ pa_assert(a);
+
+ pa_return_val_if_fail(pa_cvolume_valid(a), NULL);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(b), NULL);
+
+ for (i = 0; i < a->channels; i++)
+ dest->values[i] = pa_sw_volume_multiply(a->values[i], b);
+
+ dest->channels = (uint8_t) i;
+
+ return dest;
+}
+
pa_cvolume *pa_sw_cvolume_divide(pa_cvolume *dest, const pa_cvolume *a, const pa_cvolume *b) {
unsigned i;
@@ -362,7 +440,7 @@ pa_cvolume *pa_sw_cvolume_divide(pa_cvolume *dest, const pa_cvolume *a, const pa
pa_return_val_if_fail(pa_cvolume_valid(a), NULL);
pa_return_val_if_fail(pa_cvolume_valid(b), NULL);
- for (i = 0; i < a->channels && i < b->channels && i < PA_CHANNELS_MAX; i++)
+ for (i = 0; i < a->channels && i < b->channels; i++)
dest->values[i] = pa_sw_volume_divide(a->values[i], b->values[i]);
dest->channels = (uint8_t) i;
@@ -370,6 +448,23 @@ pa_cvolume *pa_sw_cvolume_divide(pa_cvolume *dest, const pa_cvolume *a, const pa
return dest;
}
+pa_cvolume *pa_sw_cvolume_divide_scalar(pa_cvolume *dest, const pa_cvolume *a, pa_volume_t b) {
+ unsigned i;
+
+ pa_assert(dest);
+ pa_assert(a);
+
+ pa_return_val_if_fail(pa_cvolume_valid(a), NULL);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(b), NULL);
+
+ for (i = 0; i < a->channels; i++)
+ dest->values[i] = pa_sw_volume_divide(a->values[i], b);
+
+ dest->channels = (uint8_t) i;
+
+ return dest;
+}
+
int pa_cvolume_valid(const pa_cvolume *v) {
unsigned c;
@@ -379,72 +474,34 @@ int pa_cvolume_valid(const pa_cvolume *v) {
return 0;
for (c = 0; c < v->channels; c++)
- if (v->values[c] == (pa_volume_t) -1)
+ if (!PA_VOLUME_IS_VALID(v->values[c]))
return 0;
return 1;
}
static pa_bool_t on_left(pa_channel_position_t p) {
-
- return
- p == PA_CHANNEL_POSITION_FRONT_LEFT ||
- p == PA_CHANNEL_POSITION_REAR_LEFT ||
- p == PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER ||
- p == PA_CHANNEL_POSITION_SIDE_LEFT ||
- p == PA_CHANNEL_POSITION_TOP_FRONT_LEFT ||
- p == PA_CHANNEL_POSITION_TOP_REAR_LEFT;
+ return !!(PA_CHANNEL_POSITION_MASK(p) & PA_CHANNEL_POSITION_MASK_LEFT);
}
static pa_bool_t on_right(pa_channel_position_t p) {
-
- return
- p == PA_CHANNEL_POSITION_FRONT_RIGHT ||
- p == PA_CHANNEL_POSITION_REAR_RIGHT ||
- p == PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER ||
- p == PA_CHANNEL_POSITION_SIDE_RIGHT ||
- p == PA_CHANNEL_POSITION_TOP_FRONT_RIGHT ||
- p == PA_CHANNEL_POSITION_TOP_REAR_RIGHT;
+ return !!(PA_CHANNEL_POSITION_MASK(p) & PA_CHANNEL_POSITION_MASK_RIGHT);
}
static pa_bool_t on_center(pa_channel_position_t p) {
-
- return
- p == PA_CHANNEL_POSITION_FRONT_CENTER ||
- p == PA_CHANNEL_POSITION_REAR_CENTER ||
- p == PA_CHANNEL_POSITION_TOP_CENTER ||
- p == PA_CHANNEL_POSITION_TOP_FRONT_CENTER ||
- p == PA_CHANNEL_POSITION_TOP_REAR_CENTER;
+ return !!(PA_CHANNEL_POSITION_MASK(p) & PA_CHANNEL_POSITION_MASK_CENTER);
}
static pa_bool_t on_lfe(pa_channel_position_t p) {
-
- return
- p == PA_CHANNEL_POSITION_LFE;
+ return p == PA_CHANNEL_POSITION_LFE;
}
static pa_bool_t on_front(pa_channel_position_t p) {
-
- return
- p == PA_CHANNEL_POSITION_FRONT_LEFT ||
- p == PA_CHANNEL_POSITION_FRONT_RIGHT ||
- p == PA_CHANNEL_POSITION_FRONT_CENTER ||
- p == PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER ||
- p == PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER ||
- p == PA_CHANNEL_POSITION_TOP_FRONT_LEFT ||
- p == PA_CHANNEL_POSITION_TOP_FRONT_RIGHT ||
- p == PA_CHANNEL_POSITION_TOP_FRONT_CENTER;
+ return !!(PA_CHANNEL_POSITION_MASK(p) & PA_CHANNEL_POSITION_MASK_FRONT);
}
static pa_bool_t on_rear(pa_channel_position_t p) {
-
- return
- p == PA_CHANNEL_POSITION_REAR_LEFT ||
- p == PA_CHANNEL_POSITION_REAR_RIGHT ||
- p == PA_CHANNEL_POSITION_REAR_CENTER ||
- p == PA_CHANNEL_POSITION_TOP_REAR_LEFT ||
- p == PA_CHANNEL_POSITION_TOP_REAR_RIGHT ||
- p == PA_CHANNEL_POSITION_TOP_REAR_CENTER;
+ return !!(PA_CHANNEL_POSITION_MASK(p) & PA_CHANNEL_POSITION_MASK_REAR);
}
pa_cvolume *pa_cvolume_remap(pa_cvolume *v, const pa_channel_map *from, const pa_channel_map *to) {
@@ -455,8 +512,6 @@ pa_cvolume *pa_cvolume_remap(pa_cvolume *v, const pa_channel_map *from, const pa
pa_assert(from);
pa_assert(to);
- pa_return_val_if_fail(pa_cvolume_valid(v), NULL);
- pa_return_val_if_fail(pa_channel_map_valid(from), NULL);
pa_return_val_if_fail(pa_channel_map_valid(to), NULL);
pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(v, from), NULL);
@@ -558,8 +613,6 @@ float pa_cvolume_get_balance(const pa_cvolume *v, const pa_channel_map *map) {
pa_assert(v);
pa_assert(map);
- pa_return_val_if_fail(pa_cvolume_valid(v), 0.0f);
- pa_return_val_if_fail(pa_channel_map_valid(map), 0.0f);
pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(v, map), 0.0f);
if (!pa_channel_map_can_balance(map))
@@ -591,12 +644,10 @@ pa_cvolume* pa_cvolume_set_balance(pa_cvolume *v, const pa_channel_map *map, flo
pa_assert(map);
pa_assert(v);
- pa_assert(new_balance >= -1.0f);
- pa_assert(new_balance <= 1.0f);
- pa_return_val_if_fail(pa_cvolume_valid(v), NULL);
- pa_return_val_if_fail(pa_channel_map_valid(map), NULL);
pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(v, map), NULL);
+ pa_return_val_if_fail(new_balance >= -1.0f, NULL);
+ pa_return_val_if_fail(new_balance <= 1.0f, NULL);
if (!pa_channel_map_can_balance(map))
return v;
@@ -606,9 +657,9 @@ pa_cvolume* pa_cvolume_set_balance(pa_cvolume *v, const pa_channel_map *map, flo
m = PA_MAX(left, right);
if (new_balance <= 0) {
- nright = (new_balance + 1.0f) * m;
+ nright = (new_balance + 1.0f) * m;
nleft = m;
- } else {
+ } else {
nleft = (1.0f - new_balance) * m;
nright = m;
}
@@ -618,12 +669,12 @@ pa_cvolume* pa_cvolume_set_balance(pa_cvolume *v, const pa_channel_map *map, flo
if (left == 0)
v->values[c] = nleft;
else
- v->values[c] = (pa_volume_t) (((uint64_t) v->values[c] * (uint64_t) nleft) / (uint64_t) left);
+ v->values[c] = (pa_volume_t) PA_CLAMP_VOLUME(((uint64_t) v->values[c] * (uint64_t) nleft) / (uint64_t) left);
} else if (on_right(map->map[c])) {
if (right == 0)
v->values[c] = nright;
else
- v->values[c] = (pa_volume_t) (((uint64_t) v->values[c] * (uint64_t) nright) / (uint64_t) right);
+ v->values[c] = (pa_volume_t) PA_CLAMP_VOLUME(((uint64_t) v->values[c] * (uint64_t) nright) / (uint64_t) right);
}
}
@@ -637,7 +688,7 @@ pa_cvolume* pa_cvolume_scale(pa_cvolume *v, pa_volume_t max) {
pa_assert(v);
pa_return_val_if_fail(pa_cvolume_valid(v), NULL);
- pa_return_val_if_fail(max != (pa_volume_t) -1, NULL);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(max), NULL);
t = pa_cvolume_max(v);
@@ -645,7 +696,7 @@ pa_cvolume* pa_cvolume_scale(pa_cvolume *v, pa_volume_t max) {
return pa_cvolume_set(v, v->channels, max);
for (c = 0; c < v->channels; c++)
- v->values[c] = (pa_volume_t) (((uint64_t) v->values[c] * (uint64_t) max) / (uint64_t) t);
+ v->values[c] = (pa_volume_t) PA_CLAMP_VOLUME(((uint64_t) v->values[c] * (uint64_t) max) / (uint64_t) t);
return v;
}
@@ -656,8 +707,12 @@ pa_cvolume* pa_cvolume_scale_mask(pa_cvolume *v, pa_volume_t max, pa_channel_map
pa_assert(v);
- pa_return_val_if_fail(pa_cvolume_valid(v), NULL);
- pa_return_val_if_fail(max != (pa_volume_t) -1, NULL);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(max), NULL);
+
+ if (!cm)
+ return pa_cvolume_scale(v, max);
+
+ pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(v, cm), NULL);
t = pa_cvolume_max_mask(v, cm, mask);
@@ -665,7 +720,7 @@ pa_cvolume* pa_cvolume_scale_mask(pa_cvolume *v, pa_volume_t max, pa_channel_map
return pa_cvolume_set(v, v->channels, max);
for (c = 0; c < v->channels; c++)
- v->values[c] = (pa_volume_t) (((uint64_t) v->values[c] * (uint64_t) max) / (uint64_t) t);
+ v->values[c] = (pa_volume_t) PA_CLAMP_VOLUME(((uint64_t) v->values[c] * (uint64_t) max) / (uint64_t) t);
return v;
}
@@ -708,8 +763,6 @@ float pa_cvolume_get_fade(const pa_cvolume *v, const pa_channel_map *map) {
pa_assert(v);
pa_assert(map);
- pa_return_val_if_fail(pa_cvolume_valid(v), 0.0f);
- pa_return_val_if_fail(pa_channel_map_valid(map), 0.0f);
pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(v, map), 0.0f);
if (!pa_channel_map_can_fade(map))
@@ -732,12 +785,10 @@ pa_cvolume* pa_cvolume_set_fade(pa_cvolume *v, const pa_channel_map *map, float
pa_assert(map);
pa_assert(v);
- pa_assert(new_fade >= -1.0f);
- pa_assert(new_fade <= 1.0f);
- pa_return_val_if_fail(pa_cvolume_valid(v), NULL);
- pa_return_val_if_fail(pa_channel_map_valid(map), NULL);
pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(v, map), NULL);
+ pa_return_val_if_fail(new_fade >= -1.0f, NULL);
+ pa_return_val_if_fail(new_fade <= 1.0f, NULL);
if (!pa_channel_map_can_fade(map))
return v;
@@ -747,9 +798,9 @@ pa_cvolume* pa_cvolume_set_fade(pa_cvolume *v, const pa_channel_map *map, float
m = PA_MAX(front, rear);
if (new_fade <= 0) {
- nfront = (new_fade + 1.0f) * m;
+ nfront = (new_fade + 1.0f) * m;
nrear = m;
- } else {
+ } else {
nrear = (1.0f - new_fade) * m;
nfront = m;
}
@@ -759,12 +810,12 @@ pa_cvolume* pa_cvolume_set_fade(pa_cvolume *v, const pa_channel_map *map, float
if (front == 0)
v->values[c] = nfront;
else
- v->values[c] = (pa_volume_t) (((uint64_t) v->values[c] * (uint64_t) nfront) / (uint64_t) front);
+ v->values[c] = (pa_volume_t) PA_CLAMP_VOLUME(((uint64_t) v->values[c] * (uint64_t) nfront) / (uint64_t) front);
} else if (on_rear(map->map[c])) {
if (rear == 0)
v->values[c] = nrear;
else
- v->values[c] = (pa_volume_t) (((uint64_t) v->values[c] * (uint64_t) nrear) / (uint64_t) rear);
+ v->values[c] = (pa_volume_t) PA_CLAMP_VOLUME(((uint64_t) v->values[c] * (uint64_t) nrear) / (uint64_t) rear);
}
}
@@ -785,6 +836,7 @@ pa_cvolume* pa_cvolume_set_position(
pa_return_val_if_fail(pa_cvolume_compatible_with_channel_map(cv, map), NULL);
pa_return_val_if_fail(t < PA_CHANNEL_POSITION_MAX, NULL);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(v), NULL);
for (c = 0; c < map->channels; c++)
if (map->map[c] == t) {
@@ -816,3 +868,61 @@ pa_volume_t pa_cvolume_get_position(
return v;
}
+
+pa_cvolume* pa_cvolume_merge(pa_cvolume *dest, const pa_cvolume *a, const pa_cvolume *b) {
+ unsigned i;
+
+ pa_assert(dest);
+ pa_assert(a);
+ pa_assert(b);
+
+ pa_return_val_if_fail(pa_cvolume_valid(a), NULL);
+ pa_return_val_if_fail(pa_cvolume_valid(b), NULL);
+
+ for (i = 0; i < a->channels && i < b->channels; i++)
+ dest->values[i] = PA_MAX(a->values[i], b->values[i]);
+
+ dest->channels = (uint8_t) i;
+
+ return dest;
+}
+
+pa_cvolume* pa_cvolume_inc_clamp(pa_cvolume *v, pa_volume_t inc, pa_volume_t limit) {
+ pa_volume_t m;
+
+ pa_assert(v);
+
+ pa_return_val_if_fail(pa_cvolume_valid(v), NULL);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(inc), NULL);
+
+ m = pa_cvolume_max(v);
+
+ if (m >= limit - inc)
+ m = limit;
+ else
+ m += inc;
+
+ return pa_cvolume_scale(v, m);
+}
+
+pa_cvolume* pa_cvolume_inc(pa_cvolume *v, pa_volume_t inc){
+ return pa_cvolume_inc_clamp(v, inc, PA_VOLUME_MAX);
+}
+
+pa_cvolume* pa_cvolume_dec(pa_cvolume *v, pa_volume_t dec) {
+ pa_volume_t m;
+
+ pa_assert(v);
+
+ pa_return_val_if_fail(pa_cvolume_valid(v), NULL);
+ pa_return_val_if_fail(PA_VOLUME_IS_VALID(dec), NULL);
+
+ m = pa_cvolume_max(v);
+
+ if (m <= PA_VOLUME_MUTED + dec)
+ m = PA_VOLUME_MUTED;
+ else
+ m -= dec;
+
+ return pa_cvolume_scale(v, m);
+}
diff --git a/src/pulse/volume.h b/src/pulse/volume.h
index c07fd99a..abf930ea 100644
--- a/src/pulse/volume.h
+++ b/src/pulse/volume.h
@@ -81,18 +81,21 @@
* structure are muted.
* \li pa_cvolume_is_norm() - Tests if all channels of a pa_cvolume structure
* are at a normal volume.
- * \li pa_cvolume_set() - Set all channels of a pa_cvolume structure to a
- * certain volume.
- * \li pa_cvolume_reset() - Set all channels of a pa_cvolume structure to a
- * normal volume.
- * \li pa_cvolume_mute() - Set all channels of a pa_cvolume structure to a
- * muted volume.
+ * \li pa_cvolume_set() - Set the first n channels of a pa_cvolume structure to
+ * a certain volume.
+ * \li pa_cvolume_reset() - Set the first n channels of a pa_cvolume structure
+ * to a normal volume.
+ * \li pa_cvolume_mute() - Set the first n channels of a pa_cvolume structure
+ * to a muted volume.
* \li pa_cvolume_avg() - Return the average volume of all channels.
* \li pa_cvolume_snprint() - Pretty print a pa_cvolume structure.
*/
/** \file
- * Constants and routines for volume handling */
+ * Constants and routines for volume handling
+ *
+ * See also \subpage volume
+ */
PA_C_DECL_BEGIN
@@ -106,16 +109,32 @@ typedef uint32_t pa_volume_t;
/** Normal volume (100%, 0 dB) */
#define PA_VOLUME_NORM ((pa_volume_t) 0x10000U)
-/** Muted volume (0%, -inf dB) */
+/** Muted (minimal valid) volume (0%, -inf dB) */
#define PA_VOLUME_MUTED ((pa_volume_t) 0U)
-/** Maximum volume we can store. \since 0.9.15 */
-#define PA_VOLUME_MAX ((pa_volume_t) UINT32_MAX)
+/** Maximum valid volume we can store. \since 0.9.15 */
+#define PA_VOLUME_MAX ((pa_volume_t) UINT32_MAX/2)
+
+/** Recommended maximum volume to show in user facing UIs.
+ * Note: UIs should deal gracefully with volumes greater than this value
+ * and not cause feedback loops etc. - i.e. if the volume is more than
+ * this, the UI should not limit it and push the limited value back to
+ * the server. \since 0.9.23 */
+#define PA_VOLUME_UI_MAX (pa_sw_volume_from_dB(+11.0))
+
+/** Special 'invalid' volume. \since 0.9.16 */
+#define PA_VOLUME_INVALID ((pa_volume_t) UINT32_MAX)
+
+/** Check if volume is valid. \since 1.0 */
+#define PA_VOLUME_IS_VALID(v) ((v) <= PA_VOLUME_MAX)
+
+/** Clamp volume to the permitted range. \since 1.0 */
+#define PA_CLAMP_VOLUME(v) (PA_CLAMP_UNLIKELY((v), PA_VOLUME_MUTED, PA_VOLUME_MAX))
/** A structure encapsulating a per-channel volume */
typedef struct pa_cvolume {
uint8_t channels; /**< Number of channels */
- pa_volume_t values[PA_CHANNELS_MAX]; /**< Per-channel volume */
+ pa_volume_t values[PA_CHANNELS_MAX]; /**< Per-channel volume */
} pa_cvolume;
/** Return non-zero when *a == *b */
@@ -126,13 +145,13 @@ int pa_cvolume_equal(const pa_cvolume *a, const pa_cvolume *b) PA_GCC_PURE;
* pa_cvolume_valid() will fail for it. \since 0.9.13 */
pa_cvolume* pa_cvolume_init(pa_cvolume *a);
-/** Set the volume of all channels to PA_VOLUME_NORM */
+/** Set the volume of the first n channels to PA_VOLUME_NORM */
#define pa_cvolume_reset(a, n) pa_cvolume_set((a), (n), PA_VOLUME_NORM)
-/** Set the volume of all channels to PA_VOLUME_MUTED */
+/** Set the volume of the first n channels to PA_VOLUME_MUTED */
#define pa_cvolume_mute(a, n) pa_cvolume_set((a), (n), PA_VOLUME_MUTED)
-/** Set the volume of all channels to the specified parameter */
+/** Set the volume of the specified number of channels to the volume v */
pa_cvolume* pa_cvolume_set(pa_cvolume *a, unsigned channels, pa_volume_t v);
/** Maximum length of the strings returned by
@@ -146,7 +165,7 @@ pa_cvolume* pa_cvolume_set(pa_cvolume *a, unsigned channels, pa_volume_t v);
char *pa_cvolume_snprint(char *s, size_t l, const pa_cvolume *c);
/** Maximum length of the strings returned by
- * pa_cvolume_snprint_dB(). Please note that this value can change with
+ * pa_sw_cvolume_snprint_dB(). Please note that this value can change with
* any release without warning and without being considered API or ABI
* breakage. You should not use this definition anywhere where it
* might become part of an ABI. \since 0.9.13 */
@@ -166,7 +185,7 @@ char *pa_sw_cvolume_snprint_dB(char *s, size_t l, const pa_cvolume *c);
char *pa_volume_snprint(char *s, size_t l, pa_volume_t v);
/** Maximum length of the strings returned by
- * pa_volume_snprint_dB(). Please note that this value can change with
+ * pa_sw_volume_snprint_dB(). Please note that this value can change with
* any release without warning and without being considered API or ABI
* breakage. You should not use this definition anywhere where it
* might become part of an ABI. \since 0.9.15 */
@@ -195,6 +214,16 @@ pa_volume_t pa_cvolume_max(const pa_cvolume *a) PA_GCC_PURE;
* \since 0.9.16 */
pa_volume_t pa_cvolume_max_mask(const pa_cvolume *a, const pa_channel_map *cm, pa_channel_position_mask_t mask) PA_GCC_PURE;
+/** Return the minimum volume of all channels. \since 0.9.16 */
+pa_volume_t pa_cvolume_min(const pa_cvolume *a) PA_GCC_PURE;
+
+/** Return the minimum volume of all channels that are included in the
+ * specified channel map with the specified channel position mask. If
+ * cm is NULL this call is identical to pa_cvolume_min(). If no
+ * channel is selected the returned value will be PA_VOLUME_MUTED.
+ * \since 0.9.16 */
+pa_volume_t pa_cvolume_min_mask(const pa_cvolume *a, const pa_channel_map *cm, pa_channel_position_mask_t mask) PA_GCC_PURE;
+
/** Return TRUE when the passed cvolume structure is valid, FALSE otherwise */
int pa_cvolume_valid(const pa_cvolume *v) PA_GCC_PURE;
@@ -213,26 +242,41 @@ int pa_cvolume_channels_equal_to(const pa_cvolume *a, pa_volume_t v) PA_GCC_PURE
pa_volume_t pa_sw_volume_multiply(pa_volume_t a, pa_volume_t b) PA_GCC_CONST;
/** Multiply two per-channel volumes and return the result in
- * *dest. This is only valid for software volumes! */
+ * *dest. This is only valid for software volumes! a, b and dest may
+ * point to the same structure. */
pa_cvolume *pa_sw_cvolume_multiply(pa_cvolume *dest, const pa_cvolume *a, const pa_cvolume *b);
+/** Multiply a per-channel volume with a scalar volume and return the
+ * result in *dest. This is only valid for software volumes! a
+ * and dest may point to the same structure. \since
+ * 0.9.16 */
+pa_cvolume *pa_sw_cvolume_multiply_scalar(pa_cvolume *dest, const pa_cvolume *a, pa_volume_t b);
+
/** Divide two volume specifications, return the result. This uses
* PA_VOLUME_NORM as neutral element of division. This is only valid
* for software volumes! If a division by zero is tried the result
* will be 0. \since 0.9.13 */
pa_volume_t pa_sw_volume_divide(pa_volume_t a, pa_volume_t b) PA_GCC_CONST;
-/** Multiply to per-channel volumes and return the result in
- * *dest. This is only valid for software volumes! \since 0.9.13 */
+/** Divide two per-channel volumes and return the result in
+ * *dest. This is only valid for software volumes! a, b
+ * and dest may point to the same structure. \since 0.9.13 */
pa_cvolume *pa_sw_cvolume_divide(pa_cvolume *dest, const pa_cvolume *a, const pa_cvolume *b);
+/** Divide a per-channel volume by a scalar volume and return the
+ * result in *dest. This is only valid for software volumes! a
+ * and dest may point to the same structure. \since
+ * 0.9.16 */
+pa_cvolume *pa_sw_cvolume_divide_scalar(pa_cvolume *dest, const pa_cvolume *a, pa_volume_t b);
+
/** Convert a decibel value to a volume (amplitude, not power). This is only valid for software volumes! */
pa_volume_t pa_sw_volume_from_dB(double f) PA_GCC_CONST;
/** Convert a volume to a decibel value (amplitude, not power). This is only valid for software volumes! */
double pa_sw_volume_to_dB(pa_volume_t v) PA_GCC_CONST;
-/** Convert a linear factor to a volume. This is only valid for software volumes! */
+/** Convert a linear factor to a volume. 0.0 and less is muted while
+ * 1.0 is PA_VOLUME_NORM. This is only valid for software volumes! */
pa_volume_t pa_sw_volume_from_linear(double v) PA_GCC_CONST;
/** Convert a volume to a linear factor. This is only valid for software volumes! */
@@ -241,7 +285,7 @@ double pa_sw_volume_to_linear(pa_volume_t v) PA_GCC_CONST;
#ifdef INFINITY
#define PA_DECIBEL_MININFTY ((double) -INFINITY)
#else
-/** This floor value is used as minus infinity when using pa_volume_{to,from}_dB(). */
+/** This floor value is used as minus infinity when using pa_sw_volume_to_dB() / pa_sw_volume_from_dB(). */
#define PA_DECIBEL_MININFTY ((double) -200.0)
#endif
@@ -316,6 +360,23 @@ pa_cvolume* pa_cvolume_set_position(pa_cvolume *cv, const pa_channel_map *map, p
* position by calling pa_channel_map_has_position(). \since 0.9.16 */
pa_volume_t pa_cvolume_get_position(pa_cvolume *cv, const pa_channel_map *map, pa_channel_position_t t) PA_GCC_PURE;
+/** This goes through all channels in a and b and sets the
+ * corresponding channel in dest to the greater volume of both. a, b
+ * and dest may point to the same structure. \since 0.9.16 */
+pa_cvolume* pa_cvolume_merge(pa_cvolume *dest, const pa_cvolume *a, const pa_cvolume *b);
+
+/** Increase the volume passed in by 'inc', but not exceeding 'limit'.
+ * The proportions between the channels are kept. \since 0.9.19 */
+pa_cvolume* pa_cvolume_inc_clamp(pa_cvolume *v, pa_volume_t inc, pa_volume_t limit);
+
+/** Increase the volume passed in by 'inc'. The proportions between
+ * the channels are kept. \since 0.9.16 */
+pa_cvolume* pa_cvolume_inc(pa_cvolume *v, pa_volume_t inc);
+
+/** Increase the volume passed in by 'inc'. The proportions between
+ * the channels are kept. \since 0.9.16 */
+pa_cvolume* pa_cvolume_dec(pa_cvolume *v, pa_volume_t dec);
+
PA_C_DECL_END
#endif
diff --git a/src/pulse/xmalloc.h b/src/pulse/xmalloc.h
index db20496f..f720d83f 100644
--- a/src/pulse/xmalloc.h
+++ b/src/pulse/xmalloc.h
@@ -88,9 +88,20 @@ static inline void* _pa_xnewdup_internal(const void *p, size_t n, size_t k) {
return pa_xmemdup(p, n*k);
}
-/** Same as pa_xnew() but set the memory to zero */
+/** Same as pa_xnew() but duplicate the specified data */
#define pa_xnewdup(type, p, n) ((type*) _pa_xnewdup_internal((p), (n), sizeof(type)))
+/** Internal helper for pa_xrenew() */
+static void* _pa_xrenew_internal(void *p, size_t n, size_t k) PA_GCC_MALLOC PA_GCC_ALLOC_SIZE2(2,3);
+
+static inline void* _pa_xrenew_internal(void *p, size_t n, size_t k) {
+ assert(n < INT_MAX/k);
+ return pa_xrealloc(p, n*k);
+}
+
+/** Reallocate n new structures of the specified type. */
+#define pa_xrenew(type, p, n) ((type*) _pa_xrenew_internal(p, (n), sizeof(type)))
+
PA_C_DECL_END
#endif
diff --git a/src/pulsecore/Makefile b/src/pulsecore/Makefile
deleted file mode 120000
index c110232d..00000000
--- a/src/pulsecore/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../pulse/Makefile \ No newline at end of file
diff --git a/src/pulsecore/inet_ntop.c b/src/pulsecore/arpa-inet.c
index 012a1a05..09570bb0 100644
--- a/src/pulsecore/inet_ntop.c
+++ b/src/pulsecore/arpa-inet.c
@@ -23,18 +23,15 @@
#include <config.h>
#endif
-#include <stdio.h>
-#include <errno.h>
-
-#ifndef HAVE_INET_NTOP
+#if !defined(HAVE_ARPA_INET_H) && defined(OS_IS_WIN32)
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
+#include <errno.h>
-#include "winsock.h"
+#include <pulsecore/macro.h>
+#include <pulsecore/socket.h>
+#include <pulsecore/core-util.h>
-#include "inet_ntop.h"
+#include "arpa-inet.h"
const char *inet_ntop(int af, const void *src, char *dst, socklen_t cnt) {
struct in_addr *in = (struct in_addr*)src;
@@ -42,7 +39,8 @@ const char *inet_ntop(int af, const void *src, char *dst, socklen_t cnt) {
struct in6_addr *in6 = (struct in6_addr*)src;
#endif
- assert(src && dst);
+ pa_assert(src);
+ pa_assert(dst);
switch (af) {
case AF_INET:
@@ -80,4 +78,31 @@ const char *inet_ntop(int af, const void *src, char *dst, socklen_t cnt) {
return dst;
}
-#endif /* INET_NTOP */
+int inet_pton(int af, const char *src, void *dst) {
+ struct in_addr *in = (struct in_addr*)dst;
+#ifdef HAVE_IPV6
+ struct in6_addr *in6 = (struct in6_addr*)dst;
+#endif
+
+ pa_assert(src);
+ pa_assert(dst);
+
+ switch (af) {
+ case AF_INET:
+ in->s_addr = inet_addr(src);
+ if (in->s_addr == INADDR_NONE)
+ return 0;
+ break;
+#ifdef HAVE_IPV6
+ case AF_INET6:
+ /* FIXME */
+#endif
+ default:
+ errno = EAFNOSUPPORT;
+ return -1;
+ }
+
+ return 1;
+}
+
+#endif
diff --git a/src/pulsecore/arpa-inet.h b/src/pulsecore/arpa-inet.h
new file mode 100644
index 00000000..303c905b
--- /dev/null
+++ b/src/pulsecore/arpa-inet.h
@@ -0,0 +1,23 @@
+#ifndef fooarpa_inethfoo
+#define fooarpa_inethfoo
+
+
+#if defined(HAVE_ARPA_INET_H)
+
+#include <arpa/inet.h>
+
+#elif defined(OS_IS_WIN32)
+
+/* On Windows winsock2.h (here included via pulsecore/socket.h) provides most of the functionality of arpa/inet.h, except for
+ * the inet_ntop and inet_pton functions, which are implemented here. */
+
+#include <pulsecore/socket.h>
+
+const char *inet_ntop(int af, const void *src, char *dst, socklen_t cnt);
+
+int inet_pton(int af, const char *src, void *dst);
+
+#endif
+
+
+#endif
diff --git a/src/pulsecore/asyncmsgq.c b/src/pulsecore/asyncmsgq.c
index e191b05f..408416c9 100644
--- a/src/pulsecore/asyncmsgq.c
+++ b/src/pulsecore/asyncmsgq.c
@@ -26,14 +26,14 @@
#include <unistd.h>
#include <errno.h>
-#include <pulsecore/atomic.h>
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/macro.h>
#include <pulsecore/log.h>
-#include <pulsecore/thread.h>
#include <pulsecore/semaphore.h>
#include <pulsecore/macro.h>
-#include <pulsecore/core-util.h>
+#include <pulsecore/mutex.h>
#include <pulsecore/flist.h>
-#include <pulse/xmalloc.h>
#include "asyncmsgq.h"
@@ -76,7 +76,7 @@ static void asyncmsgq_free(pa_asyncmsgq *a) {
struct asyncmsgq_item *i;
pa_assert(a);
- while ((i = pa_asyncq_pop(a->asyncq, 0))) {
+ while ((i = pa_asyncq_pop(a->asyncq, FALSE))) {
pa_assert(!i->semaphore);
@@ -172,11 +172,11 @@ int pa_asyncmsgq_send(pa_asyncmsgq *a, pa_msgobject *object, int code, const voi
return i.ret;
}
-int pa_asyncmsgq_get(pa_asyncmsgq *a, pa_msgobject **object, int *code, void **userdata, int64_t *offset, pa_memchunk *chunk, pa_bool_t wait) {
+int pa_asyncmsgq_get(pa_asyncmsgq *a, pa_msgobject **object, int *code, void **userdata, int64_t *offset, pa_memchunk *chunk, pa_bool_t wait_op) {
pa_assert(PA_REFCNT_VALUE(a) > 0);
pa_assert(!a->current);
- if (!(a->current = pa_asyncq_pop(a->asyncq, wait))) {
+ if (!(a->current = pa_asyncq_pop(a->asyncq, wait_op))) {
/* pa_log("failure"); */
return -1;
}
@@ -246,7 +246,7 @@ int pa_asyncmsgq_wait_for(pa_asyncmsgq *a, int code) {
pa_memchunk chunk;
int ret;
- if (pa_asyncmsgq_get(a, &o, &c, &data, &offset, &chunk, 1) < 0)
+ if (pa_asyncmsgq_get(a, &o, &c, &data, &offset, &chunk, TRUE) < 0)
return -1;
ret = pa_asyncmsgq_dispatch(o, c, data, offset, &chunk);
@@ -269,7 +269,7 @@ int pa_asyncmsgq_process_one(pa_asyncmsgq *a) {
pa_assert(PA_REFCNT_VALUE(a) > 0);
- if (pa_asyncmsgq_get(a, &object, &code, &data, &offset, &chunk, 0) < 0)
+ if (pa_asyncmsgq_get(a, &object, &code, &data, &offset, &chunk, FALSE) < 0)
return 0;
pa_asyncmsgq_ref(a);
@@ -319,7 +319,39 @@ void pa_asyncmsgq_write_after_poll(pa_asyncmsgq *a) {
int pa_asyncmsgq_dispatch(pa_msgobject *object, int code, void *userdata, int64_t offset, pa_memchunk *memchunk) {
if (object)
- return object->process_msg(object, code, userdata, offset, memchunk);
+ return object->process_msg(object, code, userdata, offset, pa_memchunk_isset(memchunk) ? memchunk : NULL);
return 0;
}
+
+void pa_asyncmsgq_flush(pa_asyncmsgq *a, pa_bool_t run) {
+ pa_assert(PA_REFCNT_VALUE(a) > 0);
+
+ for (;;) {
+ pa_msgobject *object;
+ int code;
+ void *data;
+ int64_t offset;
+ pa_memchunk chunk;
+ int ret;
+
+ if (pa_asyncmsgq_get(a, &object, &code, &data, &offset, &chunk, FALSE) < 0)
+ return;
+
+ if (!run) {
+ pa_asyncmsgq_done(a, -1);
+ continue;
+ }
+
+ pa_asyncmsgq_ref(a);
+ ret = pa_asyncmsgq_dispatch(object, code, data, offset, &chunk);
+ pa_asyncmsgq_done(a, ret);
+ pa_asyncmsgq_unref(a);
+ }
+}
+
+pa_bool_t pa_asyncmsgq_dispatching(pa_asyncmsgq *a) {
+ pa_assert(PA_REFCNT_VALUE(a) > 0);
+
+ return !!a->current;
+}
diff --git a/src/pulsecore/asyncmsgq.h b/src/pulsecore/asyncmsgq.h
index 1f38207a..1085c2f0 100644
--- a/src/pulsecore/asyncmsgq.h
+++ b/src/pulsecore/asyncmsgq.h
@@ -66,6 +66,8 @@ void pa_asyncmsgq_done(pa_asyncmsgq *q, int ret);
int pa_asyncmsgq_wait_for(pa_asyncmsgq *a, int code);
int pa_asyncmsgq_process_one(pa_asyncmsgq *a);
+void pa_asyncmsgq_flush(pa_asyncmsgq *a, pa_bool_t run);
+
/* For the reading side */
int pa_asyncmsgq_read_fd(pa_asyncmsgq *q);
int pa_asyncmsgq_read_before_poll(pa_asyncmsgq *a);
@@ -76,4 +78,6 @@ int pa_asyncmsgq_write_fd(pa_asyncmsgq *q);
void pa_asyncmsgq_write_before_poll(pa_asyncmsgq *a);
void pa_asyncmsgq_write_after_poll(pa_asyncmsgq *a);
+pa_bool_t pa_asyncmsgq_dispatching(pa_asyncmsgq *a);
+
#endif
diff --git a/src/pulsecore/asyncq.c b/src/pulsecore/asyncq.c
index 67f661fe..8c2d58a0 100644
--- a/src/pulsecore/asyncq.c
+++ b/src/pulsecore/asyncq.c
@@ -26,6 +26,8 @@
#include <unistd.h>
#include <errno.h>
+#include <pulse/xmalloc.h>
+
#include <pulsecore/atomic.h>
#include <pulsecore/log.h>
#include <pulsecore/thread.h>
@@ -33,10 +35,9 @@
#include <pulsecore/core-util.h>
#include <pulsecore/llist.h>
#include <pulsecore/flist.h>
-#include <pulse/xmalloc.h>
+#include <pulsecore/fdsem.h>
#include "asyncq.h"
-#include "fdsem.h"
#define ASYNCQ_SIZE 256
@@ -131,7 +132,7 @@ void pa_asyncq_free(pa_asyncq *l, pa_free_cb_t free_cb) {
pa_xfree(l);
}
-static int push(pa_asyncq*l, void *p, pa_bool_t wait) {
+static int push(pa_asyncq*l, void *p, pa_bool_t wait_op) {
unsigned idx;
pa_atomic_ptr_t *cells;
@@ -145,7 +146,7 @@ static int push(pa_asyncq*l, void *p, pa_bool_t wait) {
if (!pa_atomic_ptr_cmpxchg(&cells[idx], NULL, p)) {
- if (!wait)
+ if (!wait_op)
return -1;
/* pa_log("sleeping on push"); */
@@ -163,14 +164,14 @@ static int push(pa_asyncq*l, void *p, pa_bool_t wait) {
return 0;
}
-static pa_bool_t flush_postq(pa_asyncq *l, pa_bool_t wait) {
+static pa_bool_t flush_postq(pa_asyncq *l, pa_bool_t wait_op) {
struct localq *q;
pa_assert(l);
while ((q = l->last_localq)) {
- if (push(l, q->data, wait) < 0)
+ if (push(l, q->data, wait_op) < 0)
return FALSE;
l->last_localq = q->prev;
@@ -184,13 +185,13 @@ static pa_bool_t flush_postq(pa_asyncq *l, pa_bool_t wait) {
return TRUE;
}
-int pa_asyncq_push(pa_asyncq*l, void *p, pa_bool_t wait) {
+int pa_asyncq_push(pa_asyncq*l, void *p, pa_bool_t wait_op) {
pa_assert(l);
- if (!flush_postq(l, wait))
+ if (!flush_postq(l, wait_op))
return -1;
- return push(l, p, wait);
+ return push(l, p, wait_op);
}
void pa_asyncq_post(pa_asyncq*l, void *p) {
@@ -206,7 +207,7 @@ void pa_asyncq_post(pa_asyncq*l, void *p) {
/* OK, we couldn't push anything in the queue. So let's queue it
* locally and push it later */
- if (pa_log_ratelimit())
+ if (pa_log_ratelimit(PA_LOG_WARN))
pa_log_warn("q overrun, queuing locally");
if (!(q = pa_flist_pop(PA_STATIC_FLIST_GET(localq))))
@@ -221,7 +222,7 @@ void pa_asyncq_post(pa_asyncq*l, void *p) {
return;
}
-void* pa_asyncq_pop(pa_asyncq*l, pa_bool_t wait) {
+void* pa_asyncq_pop(pa_asyncq*l, pa_bool_t wait_op) {
unsigned idx;
void *ret;
pa_atomic_ptr_t *cells;
@@ -235,7 +236,7 @@ void* pa_asyncq_pop(pa_asyncq*l, pa_bool_t wait) {
if (!(ret = pa_atomic_ptr_load(&cells[idx]))) {
- if (!wait)
+ if (!wait_op)
return NULL;
/* pa_log("sleeping on pop"); */
diff --git a/src/pulsecore/asyncq.h b/src/pulsecore/asyncq.h
index e6847ab8..47ccbf03 100644
--- a/src/pulsecore/asyncq.h
+++ b/src/pulsecore/asyncq.h
@@ -48,8 +48,9 @@ void pa_asyncq_free(pa_asyncq* q, pa_free_cb_t free_cb);
void* pa_asyncq_pop(pa_asyncq *q, pa_bool_t wait);
int pa_asyncq_push(pa_asyncq *q, void *p, pa_bool_t wait);
-/* Similar to pa_asyncq_push(), but if the queue is full, postpone it
- * locally and delay until pa_asyncq_before_poll_post() */
+/* Similar to pa_asyncq_push(), but if the queue is full, postpone the
+ * appending of the item locally and delay until
+ * pa_asyncq_before_poll_post() is called. */
void pa_asyncq_post(pa_asyncq*l, void *p);
/* For the reading side */
diff --git a/src/pulsecore/atomic.h b/src/pulsecore/atomic.h
index 119c445b..51d08210 100644
--- a/src/pulsecore/atomic.h
+++ b/src/pulsecore/atomic.h
@@ -180,6 +180,110 @@ static inline pa_bool_t pa_atomic_ptr_cmpxchg(pa_atomic_ptr_t *a, void *old_p, v
return r == old_p;
}
+#elif defined(__FreeBSD__)
+
+#include <sys/cdefs.h>
+#include <sys/types.h>
+#include <sys/param.h>
+#include <machine/atomic.h>
+
+#if __FreeBSD_version < 600000
+#if defined(__i386__) || defined(__amd64__)
+#if defined(__amd64__)
+#define atomic_load_acq_64 atomic_load_acq_long
+#endif
+static inline u_int atomic_fetchadd_int(volatile u_int *p, u_int v) {
+ __asm __volatile(
+ " " __XSTRING(MPLOCKED) " "
+ " xaddl %0, %1 ; "
+ "# atomic_fetchadd_int"
+ : "+r" (v),
+ "=m" (*p)
+ : "m" (*p));
+
+ return (v);
+}
+#elif defined(__sparc64__)
+#define atomic_load_acq_64 atomic_load_acq_long
+#define atomic_fetchadd_int atomic_add_int
+#elif defined(__ia64__)
+#define atomic_load_acq_64 atomic_load_acq_long
+static inline uint32_t
+atomic_fetchadd_int(volatile uint32_t *p, uint32_t v) {
+ uint32_t value;
+
+ do {
+ value = *p;
+ } while (!atomic_cmpset_32(p, value, value + v));
+ return (value);
+}
+#endif
+#endif
+
+typedef struct pa_atomic {
+ volatile unsigned long value;
+} pa_atomic_t;
+
+#define PA_ATOMIC_INIT(v) { .value = (v) }
+
+static inline int pa_atomic_load(const pa_atomic_t *a) {
+ return (int) atomic_load_acq_int((unsigned int *) &a->value);
+}
+
+static inline void pa_atomic_store(pa_atomic_t *a, int i) {
+ atomic_store_rel_int((unsigned int *) &a->value, i);
+}
+
+static inline int pa_atomic_add(pa_atomic_t *a, int i) {
+ return atomic_fetchadd_int((unsigned int *) &a->value, i);
+}
+
+static inline int pa_atomic_sub(pa_atomic_t *a, int i) {
+ return atomic_fetchadd_int((unsigned int *) &a->value, -(i));
+}
+
+static inline int pa_atomic_inc(pa_atomic_t *a) {
+ return atomic_fetchadd_int((unsigned int *) &a->value, 1);
+}
+
+static inline int pa_atomic_dec(pa_atomic_t *a) {
+ return atomic_fetchadd_int((unsigned int *) &a->value, -1);
+}
+
+static inline int pa_atomic_cmpxchg(pa_atomic_t *a, int old_i, int new_i) {
+ return atomic_cmpset_int((unsigned int *) &a->value, old_i, new_i);
+}
+
+typedef struct pa_atomic_ptr {
+ volatile unsigned long value;
+} pa_atomic_ptr_t;
+
+#define PA_ATOMIC_PTR_INIT(v) { .value = (unsigned long) (v) }
+
+static inline void* pa_atomic_ptr_load(const pa_atomic_ptr_t *a) {
+#ifdef atomic_load_acq_64
+ return (void*) atomic_load_acq_ptr((unsigned long *) &a->value);
+#else
+ return (void*) atomic_load_acq_ptr((unsigned int *) &a->value);
+#endif
+}
+
+static inline void pa_atomic_ptr_store(pa_atomic_ptr_t *a, void *p) {
+#ifdef atomic_load_acq_64
+ atomic_store_rel_ptr(&a->value, (unsigned long) p);
+#else
+ atomic_store_rel_ptr((unsigned int *) &a->value, (unsigned int) p);
+#endif
+}
+
+static inline int pa_atomic_ptr_cmpxchg(pa_atomic_ptr_t *a, void *old_p, void* new_p) {
+#ifdef atomic_load_acq_64
+ return atomic_cmpset_ptr(&a->value, (unsigned long) old_p, (unsigned long) new_p);
+#else
+ return atomic_cmpset_ptr((unsigned int *) &a->value, (unsigned int) old_p, (unsigned int) new_p);
+#endif
+}
+
#elif defined(__GNUC__) && (defined(__amd64__) || defined(__x86_64__))
#warn "The native atomic operations implementation for AMD64 has not been tested thoroughly. libatomic_ops is known to not work properly on AMD64 and your gcc version is too old for the gcc-builtin atomic ops support. You have three options now: test the native atomic operations implementation for AMD64, fix libatomic_ops, or upgrade your GCC."
diff --git a/src/pulsecore/aupdate.c b/src/pulsecore/aupdate.c
index 56ebb8e5..85b6e00e 100644
--- a/src/pulsecore/aupdate.c
+++ b/src/pulsecore/aupdate.c
@@ -39,6 +39,7 @@ struct pa_aupdate {
pa_atomic_t read_lock;
pa_mutex *write_lock;
pa_semaphore *semaphore;
+ pa_bool_t swapped;
};
pa_aupdate *pa_aupdate_new(void) {
@@ -101,6 +102,8 @@ unsigned pa_aupdate_write_begin(pa_aupdate *a) {
n = (unsigned) pa_atomic_load(&a->read_lock);
+ a->swapped = FALSE;
+
return !WHICH(n);
}
@@ -119,11 +122,16 @@ unsigned pa_aupdate_write_swap(pa_aupdate *a) {
break;
}
+ a->swapped = TRUE;
+
return WHICH(n);
}
void pa_aupdate_write_end(pa_aupdate *a) {
pa_assert(a);
+ if (!a->swapped)
+ pa_aupdate_write_swap(a);
+
pa_mutex_unlock(a->write_lock);
}
diff --git a/src/pulsecore/aupdate.h b/src/pulsecore/aupdate.h
index 072e382d..48871126 100644
--- a/src/pulsecore/aupdate.h
+++ b/src/pulsecore/aupdate.h
@@ -39,7 +39,7 @@ void pa_aupdate_write_end(pa_aupdate *a);
/* Will return 0, or 1, depending which copy of the data the caller
* should modify. Each time called this will return the opposite of
- * the previous pa_aupdate_write_begin()/pa_aupdate_write_swap()
+ * the previous pa_aupdate_write_begin() / pa_aupdate_write_swap()
* call. Should only be called between pa_aupdate_write_begin() and
* pa_aupdate_write_end() */
unsigned pa_aupdate_write_swap(pa_aupdate *a);
@@ -93,6 +93,10 @@ unsigned pa_aupdate_write_swap(pa_aupdate *a);
* pa_update_write_end(a)
* }
*
+ * In some cases keeping both structures up-to-date might not be
+ * necessary, since they are fully rebuilt on each iteration
+ * anyway. In that case you may leave the _write_swap() call out, it
+ * will then be done implicitly in the _write_end() invocation.
*/
#endif
diff --git a/src/pulsecore/auth-cookie.c b/src/pulsecore/auth-cookie.c
index 2f45eca0..0897502f 100644
--- a/src/pulsecore/auth-cookie.c
+++ b/src/pulsecore/auth-cookie.c
@@ -26,7 +26,6 @@
#include <sys/types.h>
#include <pulse/xmalloc.h>
-#include <pulse/util.h>
#include <pulsecore/refcnt.h>
#include <pulsecore/macro.h>
diff --git a/src/pulsecore/authkey.c b/src/pulsecore/authkey.c
index 1e31d076..398e5b1b 100644
--- a/src/pulsecore/authkey.c
+++ b/src/pulsecore/authkey.c
@@ -29,13 +29,11 @@
#include <string.h>
#include <errno.h>
#include <stdio.h>
-#include <inttypes.h>
#include <stdlib.h>
-#include <time.h>
-#include <limits.h>
#include <sys/stat.h>
#include <pulse/util.h>
+#include <pulse/xmalloc.h>
#include <pulsecore/core-error.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
@@ -55,7 +53,10 @@ static int generate(int fd, void *ret_data, size_t length) {
pa_random(ret_data, length);
lseek(fd, (off_t) 0, SEEK_SET);
- (void) ftruncate(fd, (off_t) 0);
+ if (ftruncate(fd, (off_t) 0) < 0) {
+ pa_log("Failed to truncate cookie file: %s", pa_cstrerror(errno));
+ return -1;
+ }
if ((r = pa_loop_write(fd, ret_data, length, NULL)) < 0 || (size_t) r != length) {
pa_log("Failed to write cookie file: %s", pa_cstrerror(errno));
@@ -69,10 +70,6 @@ static int generate(int fd, void *ret_data, size_t length) {
#define O_BINARY 0
#endif
-#ifndef O_NOCTTY
-#define O_NOCTTY 0
-#endif
-
/* Load an euthorization cookie from file fn and store it in data. If
* the cookie file doesn't exist, create it */
static int load(const char *fn, void *data, size_t length) {
@@ -85,9 +82,9 @@ static int load(const char *fn, void *data, size_t length) {
pa_assert(data);
pa_assert(length > 0);
- if ((fd = open(fn, O_RDWR|O_CREAT|O_BINARY|O_NOCTTY, S_IRUSR|S_IWUSR)) < 0) {
+ if ((fd = pa_open_cloexec(fn, O_RDWR|O_CREAT|O_BINARY, S_IRUSR|S_IWUSR)) < 0) {
- if (errno != EACCES || (fd = open(fn, O_RDONLY|O_BINARY|O_NOCTTY)) < 0) {
+ if (errno != EACCES || (fd = open(fn, O_RDONLY|O_BINARY)) < 0) {
pa_log_warn("Failed to open cookie file '%s': %s", fn, pa_cstrerror(errno));
goto finish;
} else
@@ -147,47 +144,46 @@ int pa_authkey_load(const char *path, void *data, size_t length) {
/* If the specified file path starts with / return it, otherwise
* return path prepended with home directory */
-static const char *normalize_path(const char *fn, char *s, size_t l) {
+static char *normalize_path(const char *fn) {
pa_assert(fn);
- pa_assert(s);
- pa_assert(l > 0);
#ifndef OS_IS_WIN32
if (fn[0] != '/') {
#else
- if (strlen(fn) < 3 || !isalpha(fn[0]) || fn[1] != ':' || fn[2] != '\\') {
+ if (strlen(fn) < 3 || !IsCharAlpha(fn[0]) || fn[1] != ':' || fn[2] != '\\') {
#endif
- char homedir[PATH_MAX];
+ char *homedir, *s;
- if (!pa_get_home_dir(homedir, sizeof(homedir)))
+ if (!(homedir = pa_get_home_dir_malloc()))
return NULL;
-#ifndef OS_IS_WIN32
- pa_snprintf(s, l, "%s/%s", homedir, fn);
-#else
- pa_snprintf(s, l, "%s\\%s", homedir, fn);
-#endif
+ s = pa_sprintf_malloc("%s" PA_PATH_SEP "%s", homedir, fn);
+ pa_xfree(homedir);
+
return s;
}
- return fn;
+ return pa_xstrdup(fn);
}
/* Load a cookie from a file in the home directory. If the specified
* path starts with /, use it as absolute path instead. */
int pa_authkey_load_auto(const char *fn, void *data, size_t length) {
- char path[PATH_MAX];
- const char *p;
+ char *p;
+ int ret;
pa_assert(fn);
pa_assert(data);
pa_assert(length > 0);
- if (!(p = normalize_path(fn, path, sizeof(path))))
+ if (!(p = normalize_path(fn)))
return -2;
- return pa_authkey_load(p, data, length);
+ ret = pa_authkey_load(p, data, length);
+ pa_xfree(p);
+
+ return ret;
}
/* Store the specified cookie in the specified cookie file */
@@ -195,17 +191,16 @@ int pa_authkey_save(const char *fn, const void *data, size_t length) {
int fd = -1;
int unlock = 0, ret = -1;
ssize_t r;
- char path[PATH_MAX];
- const char *p;
+ char *p;
pa_assert(fn);
pa_assert(data);
pa_assert(length > 0);
- if (!(p = normalize_path(fn, path, sizeof(path))))
+ if (!(p = normalize_path(fn)))
return -2;
- if ((fd = open(p, O_RDWR|O_CREAT|O_NOCTTY, S_IRUSR|S_IWUSR)) < 0) {
+ if ((fd = pa_open_cloexec(p, O_RDWR|O_CREAT, S_IRUSR|S_IWUSR)) < 0) {
pa_log_warn("Failed to open cookie file '%s': %s", fn, pa_cstrerror(errno));
goto finish;
}
@@ -232,5 +227,7 @@ finish:
}
}
+ pa_xfree(p);
+
return ret;
}
diff --git a/src/pulsecore/avahi-wrap.c b/src/pulsecore/avahi-wrap.c
index 56d9d3dd..997d81ff 100644
--- a/src/pulsecore/avahi-wrap.c
+++ b/src/pulsecore/avahi-wrap.c
@@ -23,9 +23,9 @@
#include <config.h>
#endif
+#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include "avahi-wrap.h"
@@ -116,14 +116,13 @@ struct AvahiTimeout {
void *userdata;
};
-static void timeout_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *tv, void *userdata) {
- AvahiTimeout *t = userdata;
+static void timeout_callback(pa_mainloop_api*a, pa_time_event* e, const struct timeval *t, void *userdata) {
+ AvahiTimeout *to = userdata;
pa_assert(a);
pa_assert(e);
- pa_assert(t);
- t->callback(t, t->userdata);
+ to->callback(to, to->userdata);
}
static AvahiTimeout* timeout_new(const AvahiPoll *api, const struct timeval *tv, AvahiTimeoutCallback callback, void *userdata) {
@@ -145,6 +144,7 @@ static AvahiTimeout* timeout_new(const AvahiPoll *api, const struct timeval *tv,
}
static void timeout_update(AvahiTimeout *t, const struct timeval *tv) {
+
pa_assert(t);
if (t->time_event && tv)
diff --git a/src/pulsecore/card.c b/src/pulsecore/card.c
index 8101a92e..feaa4440 100644
--- a/src/pulsecore/card.c
+++ b/src/pulsecore/card.c
@@ -148,15 +148,12 @@ pa_card *pa_card_new(pa_core *core, pa_card_new_data *data) {
c->save_profile = data->save_profile;
if (!c->active_profile && c->profiles) {
- void *state = NULL;
+ void *state;
pa_card_profile *p;
- while ((p = pa_hashmap_iterate(c->profiles, &state, NULL))) {
- if (!c->active_profile ||
- p->priority > c->active_profile->priority)
-
+ PA_HASHMAP_FOREACH(p, c->profiles, state)
+ if (!c->active_profile || p->priority > c->active_profile->priority)
c->active_profile = p;
- }
}
c->userdata = NULL;
@@ -164,6 +161,7 @@ pa_card *pa_card_new(pa_core *core, pa_card_new_data *data) {
pa_device_init_description(c->proplist);
pa_device_init_icon(c->proplist, TRUE);
+ pa_device_init_intended_roles(c->proplist);
pa_assert_se(pa_idxset_put(core->cards, c, &c->index) >= 0);
@@ -176,7 +174,6 @@ pa_card *pa_card_new(pa_core *core, pa_card_new_data *data) {
void pa_card_free(pa_card *c) {
pa_core *core;
- pa_card_profile *profile;
pa_assert(c);
pa_assert(c->core);
@@ -199,8 +196,10 @@ void pa_card_free(pa_card *c) {
pa_idxset_free(c->sources, NULL, NULL);
if (c->profiles) {
- while ((profile = pa_hashmap_steal_first(c->profiles)))
- pa_card_profile_free(profile);
+ pa_card_profile *p;
+
+ while ((p = pa_hashmap_steal_first(c->profiles)))
+ pa_card_profile_free(p);
pa_hashmap_free(c->profiles, NULL, NULL);
}
@@ -213,26 +212,27 @@ void pa_card_free(pa_card *c) {
int pa_card_set_profile(pa_card *c, const char *name, pa_bool_t save) {
pa_card_profile *profile;
+ int r;
pa_assert(c);
if (!c->set_profile) {
- pa_log_warn("set_profile() operation not implemented for card %u \"%s\"", c->index, c->name);
- return -1;
+ pa_log_debug("set_profile() operation not implemented for card %u \"%s\"", c->index, c->name);
+ return -PA_ERR_NOTIMPLEMENTED;
}
if (!c->profiles)
- return -1;
+ return -PA_ERR_NOENTITY;
if (!(profile = pa_hashmap_get(c->profiles, name)))
- return -1;
+ return -PA_ERR_NOENTITY;
if (c->active_profile == profile) {
c->save_profile = c->save_profile || save;
return 0;
}
- if (c->set_profile(c, profile) < 0)
- return -1;
+ if ((r = c->set_profile(c, profile)) < 0)
+ return r;
pa_subscription_post(c->core, PA_SUBSCRIPTION_EVENT_CARD|PA_SUBSCRIPTION_EVENT_CHANGE, c->index);
@@ -241,22 +241,33 @@ int pa_card_set_profile(pa_card *c, const char *name, pa_bool_t save) {
c->active_profile = profile;
c->save_profile = save;
+ pa_hook_fire(&c->core->hooks[PA_CORE_HOOK_CARD_PROFILE_CHANGED], c);
+
return 0;
}
-int pa_card_suspend(pa_card *c, pa_bool_t suspend) {
+int pa_card_suspend(pa_card *c, pa_bool_t suspend, pa_suspend_cause_t cause) {
pa_sink *sink;
pa_source *source;
uint32_t idx;
int ret = 0;
pa_assert(c);
+ pa_assert(cause != 0);
- for (sink = pa_idxset_first(c->sinks, &idx); sink; sink = pa_idxset_next(c->sinks, &idx))
- ret -= pa_sink_suspend(sink, suspend) < 0;
+ for (sink = pa_idxset_first(c->sinks, &idx); sink; sink = pa_idxset_next(c->sinks, &idx)) {
+ int r;
- for (source = pa_idxset_first(c->sources, &idx); source; source = pa_idxset_next(c->sources, &idx))
- ret -= pa_source_suspend(source, suspend) < 0;
+ if ((r = pa_sink_suspend(sink, suspend, cause)) < 0)
+ ret = r;
+ }
+
+ for (source = pa_idxset_first(c->sources, &idx); source; source = pa_idxset_next(c->sources, &idx)) {
+ int r;
+
+ if ((r = pa_source_suspend(source, suspend, cause)) < 0)
+ ret = r;
+ }
return ret;
}
diff --git a/src/pulsecore/card.h b/src/pulsecore/card.h
index 3b7608f6..2d691b67 100644
--- a/src/pulsecore/card.h
+++ b/src/pulsecore/card.h
@@ -63,7 +63,7 @@ struct pa_card {
pa_hashmap *profiles;
pa_card_profile *active_profile;
- pa_bool_t save_profile;
+ pa_bool_t save_profile:1;
void *userdata;
@@ -72,9 +72,8 @@ struct pa_card {
typedef struct pa_card_new_data {
char *name;
- char *description;
-
pa_proplist *proplist;
+
const char *driver;
pa_module *module;
@@ -99,6 +98,6 @@ void pa_card_free(pa_card *c);
int pa_card_set_profile(pa_card *c, const char *name, pa_bool_t save);
-int pa_card_suspend(pa_card *c, pa_bool_t suspend);
+int pa_card_suspend(pa_card *c, pa_bool_t suspend, pa_suspend_cause_t cause);
#endif
diff --git a/src/pulsecore/cli-command.c b/src/pulsecore/cli-command.c
index dad647a8..16c76617 100644
--- a/src/pulsecore/cli-command.c
+++ b/src/pulsecore/cli-command.c
@@ -30,6 +30,9 @@
#include <errno.h>
#include <unistd.h>
#include <ltdl.h>
+#include <sys/stat.h>
+#include <dirent.h>
+#include <time.h>
#include <pulse/xmalloc.h>
#include <pulse/error.h>
@@ -45,7 +48,6 @@
#include <pulsecore/namereg.h>
#include <pulsecore/cli-text.h>
#include <pulsecore/core-scache.h>
-#include <pulsecore/sample-util.h>
#include <pulsecore/sound-file.h>
#include <pulsecore/play-memchunk.h>
#include <pulsecore/sound-file-stream.h>
@@ -53,6 +55,7 @@
#include <pulsecore/core-util.h>
#include <pulsecore/core-error.h>
#include <pulsecore/modinfo.h>
+#include <pulsecore/dynarray.h>
#include "cli-command.h"
@@ -125,6 +128,8 @@ static int pa_cli_command_update_source_proplist(pa_core *c, pa_tokenizer *t, pa
static int pa_cli_command_update_sink_input_proplist(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail);
static int pa_cli_command_update_source_output_proplist(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail);
static int pa_cli_command_card_profile(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail);
+static int pa_cli_command_sink_port(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail);
+static int pa_cli_command_source_port(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail);
/* A method table for all available commands */
@@ -176,10 +181,12 @@ static const struct command commands[] = {
{ "suspend-source", pa_cli_command_suspend_source, "Suspend source (args: index|name, bool)", 3},
{ "suspend", pa_cli_command_suspend, "Suspend all sinks and all sources (args: bool)", 2},
{ "set-card-profile", pa_cli_command_card_profile, "Change the profile of a card (args: index, name)", 3},
+ { "set-sink-port", pa_cli_command_sink_port, "Change the port of a sink (args: index, name)", 3},
+ { "set-source-port", pa_cli_command_source_port, "Change the port of a source (args: index, name)", 3},
{ "set-log-level", pa_cli_command_log_level, "Change the log level (args: numeric level)", 2},
{ "set-log-meta", pa_cli_command_log_meta, "Show source code location in log messages (args: bool)", 2},
{ "set-log-time", pa_cli_command_log_time, "Show timestamps in log messages (args: bool)", 2},
- { "set-log-backtrace", pa_cli_command_log_backtrace, "Show bakctrace in log messages (args: frames)", 2},
+ { "set-log-backtrace", pa_cli_command_log_backtrace, "Show backtrace in log messages (args: frames)", 2},
{ NULL, NULL, NULL, 0 }
};
@@ -324,8 +331,8 @@ static int pa_cli_command_source_outputs(pa_core *c, pa_tokenizer *t, pa_strbuf
static int pa_cli_command_stat(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail) {
char ss[PA_SAMPLE_SPEC_SNPRINT_MAX];
char cm[PA_CHANNEL_MAP_SNPRINT_MAX];
- char s[256];
- const pa_mempool_stat *stat;
+ char bytes[PA_BYTES_SNPRINT_MAX];
+ const pa_mempool_stat *mstat;
unsigned k;
pa_sink *def_sink;
pa_source *def_source;
@@ -344,26 +351,26 @@ static int pa_cli_command_stat(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_b
pa_assert(buf);
pa_assert(fail);
- stat = pa_mempool_get_stat(c->mempool);
+ mstat = pa_mempool_get_stat(c->mempool);
pa_strbuf_printf(buf, "Memory blocks currently allocated: %u, size: %s.\n",
- (unsigned) pa_atomic_load(&stat->n_allocated),
- pa_bytes_snprint(s, sizeof(s), (unsigned) pa_atomic_load(&stat->allocated_size)));
+ (unsigned) pa_atomic_load(&mstat->n_allocated),
+ pa_bytes_snprint(bytes, sizeof(bytes), (unsigned) pa_atomic_load(&mstat->allocated_size)));
pa_strbuf_printf(buf, "Memory blocks allocated during the whole lifetime: %u, size: %s.\n",
- (unsigned) pa_atomic_load(&stat->n_accumulated),
- pa_bytes_snprint(s, sizeof(s), (unsigned) pa_atomic_load(&stat->accumulated_size)));
+ (unsigned) pa_atomic_load(&mstat->n_accumulated),
+ pa_bytes_snprint(bytes, sizeof(bytes), (unsigned) pa_atomic_load(&mstat->accumulated_size)));
pa_strbuf_printf(buf, "Memory blocks imported from other processes: %u, size: %s.\n",
- (unsigned) pa_atomic_load(&stat->n_imported),
- pa_bytes_snprint(s, sizeof(s), (unsigned) pa_atomic_load(&stat->imported_size)));
+ (unsigned) pa_atomic_load(&mstat->n_imported),
+ pa_bytes_snprint(bytes, sizeof(bytes), (unsigned) pa_atomic_load(&mstat->imported_size)));
pa_strbuf_printf(buf, "Memory blocks exported to other processes: %u, size: %s.\n",
- (unsigned) pa_atomic_load(&stat->n_exported),
- pa_bytes_snprint(s, sizeof(s), (unsigned) pa_atomic_load(&stat->exported_size)));
+ (unsigned) pa_atomic_load(&mstat->n_exported),
+ pa_bytes_snprint(bytes, sizeof(bytes), (unsigned) pa_atomic_load(&mstat->exported_size)));
pa_strbuf_printf(buf, "Total sample cache size: %s.\n",
- pa_bytes_snprint(s, sizeof(s), (unsigned) pa_scache_total_size(c)));
+ pa_bytes_snprint(bytes, sizeof(bytes), (unsigned) pa_scache_total_size(c)));
pa_strbuf_printf(buf, "Default sample spec: %s\n",
pa_sample_spec_snprint(ss, sizeof(ss), &c->default_sample_spec));
@@ -382,8 +389,8 @@ static int pa_cli_command_stat(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_b
pa_strbuf_printf(buf,
"Memory blocks of type %s: %u allocated/%u accumulated.\n",
type_table[k],
- (unsigned) pa_atomic_load(&stat->n_allocated_by_type[k]),
- (unsigned) pa_atomic_load(&stat->n_accumulated_by_type[k]));
+ (unsigned) pa_atomic_load(&mstat->n_allocated_by_type[k]),
+ (unsigned) pa_atomic_load(&mstat->n_accumulated_by_type[k]));
return 0;
}
@@ -520,13 +527,18 @@ static int pa_cli_command_sink_volume(pa_core *c, pa_tokenizer *t, pa_strbuf *bu
return -1;
}
+ if (!PA_VOLUME_IS_VALID(volume)) {
+ pa_strbuf_puts(buf, "Volume outside permissible range.\n");
+ return -1;
+ }
+
if (!(sink = pa_namereg_get(c, n, PA_NAMEREG_SINK))) {
pa_strbuf_puts(buf, "No sink found by this name or index.\n");
return -1;
}
- pa_cvolume_set(&cvolume, sink->sample_spec.channels, volume);
- pa_sink_set_volume(sink, &cvolume, TRUE, TRUE, TRUE);
+ pa_cvolume_set(&cvolume, 1, volume);
+ pa_sink_set_volume(sink, &cvolume, TRUE, TRUE);
return 0;
}
@@ -562,12 +574,22 @@ static int pa_cli_command_sink_input_volume(pa_core *c, pa_tokenizer *t, pa_strb
return -1;
}
- if (!(si = pa_idxset_get_by_index(c->sink_inputs, (uint32_t) idx))) {
+ if (!PA_VOLUME_IS_VALID(volume)) {
+ pa_strbuf_puts(buf, "Volume outside permissible range.\n");
+ return -1;
+ }
+
+ if (!(si = pa_idxset_get_by_index(c->sink_inputs, idx))) {
pa_strbuf_puts(buf, "No sink input found with this index.\n");
return -1;
}
- pa_cvolume_set(&cvolume, si->sample_spec.channels, volume);
+ if (!si->volume_writable) {
+ pa_strbuf_puts(buf, "This sink input's volume can't be changed.\n");
+ return -1;
+ }
+
+ pa_cvolume_set(&cvolume, 1, volume);
pa_sink_input_set_volume(si, &cvolume, TRUE, TRUE);
return 0;
}
@@ -598,13 +620,18 @@ static int pa_cli_command_source_volume(pa_core *c, pa_tokenizer *t, pa_strbuf *
return -1;
}
+ if (!PA_VOLUME_IS_VALID(volume)) {
+ pa_strbuf_puts(buf, "Volume outside permissible range.\n");
+ return -1;
+ }
+
if (!(source = pa_namereg_get(c, n, PA_NAMEREG_SOURCE))) {
pa_strbuf_puts(buf, "No source found by this name or index.\n");
return -1;
}
- pa_cvolume_set(&cvolume, source->sample_spec.channels, volume);
- pa_source_set_volume(source, &cvolume);
+ pa_cvolume_set(&cvolume, 1, volume);
+ pa_source_set_volume(source, &cvolume, TRUE, TRUE);
return 0;
}
@@ -638,7 +665,7 @@ static int pa_cli_command_sink_mute(pa_core *c, pa_tokenizer *t, pa_strbuf *buf,
return -1;
}
- pa_sink_set_mute(sink, mute);
+ pa_sink_set_mute(sink, mute, TRUE);
return 0;
}
@@ -672,7 +699,7 @@ static int pa_cli_command_source_mute(pa_core *c, pa_tokenizer *t, pa_strbuf *bu
return -1;
}
- pa_source_set_mute(source, mute);
+ pa_source_set_mute(source, mute, TRUE);
return 0;
}
@@ -1278,7 +1305,7 @@ static int pa_cli_command_suspend_sink(pa_core *c, pa_tokenizer *t, pa_strbuf *b
return -1;
}
- if ((r = pa_sink_suspend(sink, suspend)) < 0)
+ if ((r = pa_sink_suspend(sink, suspend, PA_SUSPEND_USER)) < 0)
pa_strbuf_printf(buf, "Failed to resume/suspend sink: %s\n", pa_strerror(r));
return 0;
@@ -1314,7 +1341,7 @@ static int pa_cli_command_suspend_source(pa_core *c, pa_tokenizer *t, pa_strbuf
return -1;
}
- if ((r = pa_source_suspend(source, suspend)) < 0)
+ if ((r = pa_source_suspend(source, suspend, PA_SUSPEND_USER)) < 0)
pa_strbuf_printf(buf, "Failed to resume/suspend source: %s\n", pa_strerror(r));
return 0;
@@ -1339,10 +1366,10 @@ static int pa_cli_command_suspend(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, p
return -1;
}
- if ((r = pa_sink_suspend_all(c, suspend)) < 0)
+ if ((r = pa_sink_suspend_all(c, suspend, PA_SUSPEND_USER)) < 0)
pa_strbuf_printf(buf, "Failed to resume/suspend all sinks: %s\n", pa_strerror(r));
- if ((r = pa_source_suspend_all(c, suspend)) < 0)
+ if ((r = pa_source_suspend_all(c, suspend, PA_SUSPEND_USER)) < 0)
pa_strbuf_printf(buf, "Failed to resume/suspend all sources: %s\n", pa_strerror(r));
return 0;
@@ -1476,15 +1503,81 @@ static int pa_cli_command_card_profile(pa_core *c, pa_tokenizer *t, pa_strbuf *b
return 0;
}
+static int pa_cli_command_sink_port(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail) {
+ const char *n, *p;
+ pa_sink *sink;
+
+ pa_core_assert_ref(c);
+ pa_assert(t);
+ pa_assert(buf);
+ pa_assert(fail);
+
+ if (!(n = pa_tokenizer_get(t, 1))) {
+ pa_strbuf_puts(buf, "You need to specify a sink either by its name or its index.\n");
+ return -1;
+ }
+
+ if (!(p = pa_tokenizer_get(t, 2))) {
+ pa_strbuf_puts(buf, "You need to specify a profile by its name.\n");
+ return -1;
+ }
+
+ if (!(sink = pa_namereg_get(c, n, PA_NAMEREG_SINK))) {
+ pa_strbuf_puts(buf, "No sink found by this name or index.\n");
+ return -1;
+ }
+
+ if (pa_sink_set_port(sink, p, TRUE) < 0) {
+ pa_strbuf_printf(buf, "Failed to set sink port to '%s'.\n", p);
+ return -1;
+ }
+
+ return 0;
+}
+
+static int pa_cli_command_source_port(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail) {
+ const char *n, *p;
+ pa_source *source;
+
+ pa_core_assert_ref(c);
+ pa_assert(t);
+ pa_assert(buf);
+ pa_assert(fail);
+
+ if (!(n = pa_tokenizer_get(t, 1))) {
+ pa_strbuf_puts(buf, "You need to specify a source either by its name or its index.\n");
+ return -1;
+ }
+
+ if (!(p = pa_tokenizer_get(t, 2))) {
+ pa_strbuf_puts(buf, "You need to specify a profile by its name.\n");
+ return -1;
+ }
+
+ if (!(source = pa_namereg_get(c, n, PA_NAMEREG_SOURCE))) {
+ pa_strbuf_puts(buf, "No source found by this name or index.\n");
+ return -1;
+ }
+
+ if (pa_source_set_port(source, p, TRUE) < 0) {
+ pa_strbuf_printf(buf, "Failed to set source port to '%s'.\n", p);
+ return -1;
+ }
+
+ return 0;
+}
+
static int pa_cli_command_dump(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_bool_t *fail) {
pa_module *m;
pa_sink *sink;
pa_source *source;
pa_card *card;
- int nl;
+ pa_bool_t nl;
uint32_t idx;
- char txt[256];
time_t now;
+#ifdef HAVE_CTIME_R
+ char txt[256];
+#endif
pa_core_assert_ref(c);
pa_assert(t);
@@ -1499,7 +1592,7 @@ static int pa_cli_command_dump(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_b
pa_strbuf_printf(buf, "### Configuration dump generated at %s\n", ctime(&now));
#endif
- for (m = pa_idxset_first(c->modules, &idx); m; m = pa_idxset_next(c->modules, &idx)) {
+ PA_IDXSET_FOREACH(m, c->modules, idx) {
pa_strbuf_printf(buf, "load-module %s", m->name);
@@ -1509,58 +1602,58 @@ static int pa_cli_command_dump(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_b
pa_strbuf_puts(buf, "\n");
}
- nl = 0;
-
- for (sink = pa_idxset_first(c->sinks, &idx); sink; sink = pa_idxset_next(c->sinks, &idx)) {
+ nl = FALSE;
+ PA_IDXSET_FOREACH(sink, c->sinks, idx) {
if (!nl) {
pa_strbuf_puts(buf, "\n");
- nl = 1;
+ nl = TRUE;
}
- pa_strbuf_printf(buf, "set-sink-volume %s 0x%03x\n", sink->name, pa_cvolume_avg(pa_sink_get_volume(sink, FALSE, TRUE)));
+ pa_strbuf_printf(buf, "set-sink-volume %s 0x%03x\n", sink->name, pa_cvolume_max(pa_sink_get_volume(sink, FALSE)));
pa_strbuf_printf(buf, "set-sink-mute %s %s\n", sink->name, pa_yes_no(pa_sink_get_mute(sink, FALSE)));
pa_strbuf_printf(buf, "suspend-sink %s %s\n", sink->name, pa_yes_no(pa_sink_get_state(sink) == PA_SINK_SUSPENDED));
}
- for (source = pa_idxset_first(c->sources, &idx); source; source = pa_idxset_next(c->sources, &idx)) {
+ nl = FALSE;
+ PA_IDXSET_FOREACH(source, c->sources, idx) {
if (!nl) {
pa_strbuf_puts(buf, "\n");
- nl = 1;
+ nl = TRUE;
}
- pa_strbuf_printf(buf, "set-source-volume %s 0x%03x\n", source->name, pa_cvolume_avg(pa_source_get_volume(source, FALSE)));
+ pa_strbuf_printf(buf, "set-source-volume %s 0x%03x\n", source->name, pa_cvolume_max(pa_source_get_volume(source, FALSE)));
pa_strbuf_printf(buf, "set-source-mute %s %s\n", source->name, pa_yes_no(pa_source_get_mute(source, FALSE)));
pa_strbuf_printf(buf, "suspend-source %s %s\n", source->name, pa_yes_no(pa_source_get_state(source) == PA_SOURCE_SUSPENDED));
}
- for (card = pa_idxset_first(c->cards, &idx); card; card = pa_idxset_next(c->cards, &idx)) {
+ nl = FALSE;
+ PA_IDXSET_FOREACH(card, c->cards, idx) {
if (!nl) {
pa_strbuf_puts(buf, "\n");
- nl = 1;
+ nl = TRUE;
}
if (card->active_profile)
pa_strbuf_printf(buf, "set-card-profile %s %s\n", card->name, card->active_profile->name);
}
- nl = 0;
-
+ nl = FALSE;
if ((sink = pa_namereg_get_default_sink(c))) {
if (!nl) {
pa_strbuf_puts(buf, "\n");
- nl = 1;
+ nl = TRUE;
}
+
pa_strbuf_printf(buf, "set-default-sink %s\n", sink->name);
}
if ((source = pa_namereg_get_default_source(c))) {
- if (!nl) {
+ if (!nl)
pa_strbuf_puts(buf, "\n");
- nl = 1;
- }
+
pa_strbuf_printf(buf, "set-default-source %s\n", source->name);
}
@@ -1609,10 +1702,74 @@ int pa_cli_command_execute_line_stateful(pa_core *c, const char *s, pa_strbuf *b
l = strcspn(cs, whitespace);
if (l == sizeof(META_INCLUDE)-1 && !strncmp(cs, META_INCLUDE, l)) {
+ struct stat st;
const char *filename = cs+l+strspn(cs+l, whitespace);
- if (pa_cli_command_execute_file(c, filename, buf, fail) < 0)
+
+ if (stat(filename, &st) < 0) {
+ pa_log_warn("stat('%s'): %s", filename, pa_cstrerror(errno));
if (*fail)
return -1;
+ } else {
+ if (S_ISDIR(st.st_mode)) {
+ DIR *d;
+
+ if (!(d = opendir(filename))) {
+ pa_log_warn("Failed to read '%s': %s", filename, pa_cstrerror(errno));
+ if (*fail)
+ return -1;
+ } else {
+ unsigned i, count;
+ char **sorted_files;
+ struct dirent *de;
+ pa_bool_t failed = FALSE;
+ pa_dynarray *files = pa_dynarray_new();
+
+ while ((de = readdir(d))) {
+ char *extn;
+ size_t flen = strlen(de->d_name);
+
+ if (flen < 4)
+ continue;
+
+ extn = &de->d_name[flen-3];
+ if (strncmp(extn, ".pa", 3) == 0)
+ pa_dynarray_append(files, pa_sprintf_malloc("%s" PA_PATH_SEP "%s", filename, de->d_name));
+ }
+
+ closedir(d);
+
+ count = pa_dynarray_size(files);
+ sorted_files = pa_xnew(char*, count);
+ for (i = 0; i < count; ++i)
+ sorted_files[i] = pa_dynarray_get(files, i);
+ pa_dynarray_free(files, NULL, NULL);
+
+ for (i = 0; i < count; ++i) {
+ for (unsigned j = 0; j < count; ++j) {
+ if (strcmp(sorted_files[i], sorted_files[j]) < 0) {
+ char *tmp = sorted_files[i];
+ sorted_files[i] = sorted_files[j];
+ sorted_files[j] = tmp;
+ }
+ }
+ }
+
+ for (i = 0; i < count; ++i) {
+ if (!failed) {
+ if (pa_cli_command_execute_file(c, sorted_files[i], buf, fail) < 0 && *fail)
+ failed = TRUE;
+ }
+
+ pa_xfree(sorted_files[i]);
+ }
+ pa_xfree(sorted_files);
+ if (failed)
+ return -1;
+ }
+ } else if (pa_cli_command_execute_file(c, filename, buf, fail) < 0 && *fail) {
+ return -1;
+ }
+ }
} else if (l == sizeof(META_IFEXISTS)-1 && !strncmp(cs, META_IFEXISTS, l)) {
if (!ifstate) {
pa_strbuf_printf(buf, "Meta command %s is not valid in this context\n", cs);
@@ -1698,7 +1855,7 @@ int pa_cli_command_execute_line(pa_core *c, const char *s, pa_strbuf *buf, pa_bo
}
int pa_cli_command_execute_file_stream(pa_core *c, FILE *f, pa_strbuf *buf, pa_bool_t *fail) {
- char line[1024];
+ char line[2048];
int ifstate = IFSTATE_NONE;
int ret = -1;
pa_bool_t _fail = TRUE;
@@ -1736,17 +1893,16 @@ int pa_cli_command_execute_file(pa_core *c, const char *fn, pa_strbuf *buf, pa_b
if (!fail)
fail = &_fail;
- if (!(f = fopen(fn, "r"))) {
+ if (!(f = pa_fopen_cloexec(fn, "r"))) {
pa_strbuf_printf(buf, "open('%s') failed: %s\n", fn, pa_cstrerror(errno));
if (!*fail)
ret = 0;
goto fail;
}
+ pa_log_debug("Parsing script '%s'", fn);
ret = pa_cli_command_execute_file_stream(c, f, buf, fail);
- ret = 0;
-
fail:
if (f)
fclose(f);
diff --git a/src/pulsecore/cli-text.c b/src/pulsecore/cli-text.c
index 604678be..5498744c 100644
--- a/src/pulsecore/cli-text.c
+++ b/src/pulsecore/cli-text.c
@@ -23,8 +23,6 @@
#include <config.h>
#endif
-#include <string.h>
-
#include <pulse/volume.h>
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
@@ -36,7 +34,6 @@
#include <pulsecore/sink-input.h>
#include <pulsecore/source-output.h>
#include <pulsecore/strbuf.h>
-#include <pulsecore/sample-util.h>
#include <pulsecore/core-scache.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-util.h>
@@ -139,11 +136,10 @@ char *pa_card_list_to_string(pa_core *c) {
if (card->profiles) {
pa_card_profile *p;
- void *state = NULL;
+ void *state;
pa_strbuf_puts(s, "\tprofiles:\n");
-
- while ((p = pa_hashmap_iterate(card->profiles, &state, NULL)))
+ PA_HASHMAP_FOREACH(p, card->profiles, state)
pa_strbuf_printf(s, "\t\t%s: %s (priority %u)\n", p->name, p->description, p->priority);
}
@@ -232,6 +228,8 @@ char *pa_sink_list_to_string(pa_core *c) {
"\tdriver: <%s>\n"
"\tflags: %s%s%s%s%s%s%s%s\n"
"\tstate: %s\n"
+ "\tsuspend cause: %s%s%s%s\n"
+ "\tpriority: %u\n"
"\tvolume: %s%s%s\n"
"\t balance %0.2f\n"
"\tbase volume: %s%s%s\n"
@@ -258,10 +256,15 @@ char *pa_sink_list_to_string(pa_core *c) {
sink->flags & PA_SINK_FLAT_VOLUME ? "FLAT_VOLUME " : "",
sink->flags & PA_SINK_DYNAMIC_LATENCY ? "DYNAMIC_LATENCY" : "",
sink_state_to_string(pa_sink_get_state(sink)),
- pa_cvolume_snprint(cv, sizeof(cv), pa_sink_get_volume(sink, FALSE, FALSE)),
+ sink->suspend_cause & PA_SUSPEND_USER ? "USER " : "",
+ sink->suspend_cause & PA_SUSPEND_APPLICATION ? "APPLICATION " : "",
+ sink->suspend_cause & PA_SUSPEND_IDLE ? "IDLE " : "",
+ sink->suspend_cause & PA_SUSPEND_SESSION ? "SESSION" : "",
+ sink->priority,
+ pa_cvolume_snprint(cv, sizeof(cv), pa_sink_get_volume(sink, FALSE)),
sink->flags & PA_SINK_DECIBEL_VOLUME ? "\n\t " : "",
- sink->flags & PA_SINK_DECIBEL_VOLUME ? pa_sw_cvolume_snprint_dB(cvdb, sizeof(cvdb), pa_sink_get_volume(sink, FALSE, FALSE)) : "",
- pa_cvolume_get_balance(pa_sink_get_volume(sink, FALSE, FALSE), &sink->channel_map),
+ sink->flags & PA_SINK_DECIBEL_VOLUME ? pa_sw_cvolume_snprint_dB(cvdb, sizeof(cvdb), pa_sink_get_volume(sink, FALSE)) : "",
+ pa_cvolume_get_balance(pa_sink_get_volume(sink, FALSE), &sink->channel_map),
pa_volume_snprint(v, sizeof(v), sink->base_volume),
sink->flags & PA_SINK_DECIBEL_VOLUME ? "\n\t " : "",
sink->flags & PA_SINK_DECIBEL_VOLUME ? pa_sw_volume_snprint_dB(vdb, sizeof(vdb), sink->base_volume) : "",
@@ -292,7 +295,7 @@ char *pa_sink_list_to_string(pa_core *c) {
pa_strbuf_printf(
s,
"\tfixed latency: %0.2f ms\n",
- (double) pa_sink_get_requested_latency(sink) / PA_USEC_PER_MSEC);
+ (double) pa_sink_get_fixed_latency(sink) / PA_USEC_PER_MSEC);
if (sink->card)
pa_strbuf_printf(s, "\tcard: %u <%s>\n", sink->card->index, sink->card->name);
@@ -302,6 +305,22 @@ char *pa_sink_list_to_string(pa_core *c) {
t = pa_proplist_to_string_sep(sink->proplist, "\n\t\t");
pa_strbuf_printf(s, "\tproperties:\n\t\t%s\n", t);
pa_xfree(t);
+
+ if (sink->ports) {
+ pa_device_port *p;
+ void *state;
+
+ pa_strbuf_puts(s, "\tports:\n");
+ PA_HASHMAP_FOREACH(p, sink->ports, state)
+ pa_strbuf_printf(s, "\t\t%s: %s (priority %u)\n", p->name, p->description, p->priority);
+ }
+
+
+ if (sink->active_port)
+ pa_strbuf_printf(
+ s,
+ "\tactive port: <%s>\n",
+ sink->active_port->name);
}
return pa_strbuf_tostring_free(s);
@@ -335,6 +354,8 @@ char *pa_source_list_to_string(pa_core *c) {
"\tdriver: <%s>\n"
"\tflags: %s%s%s%s%s%s%s\n"
"\tstate: %s\n"
+ "\tsuspend cause: %s%s%s%s\n"
+ "\tpriority: %u\n"
"\tvolume: %s%s%s\n"
"\t balance %0.2f\n"
"\tbase volume: %s%s%s\n"
@@ -358,6 +379,11 @@ char *pa_source_list_to_string(pa_core *c) {
source->flags & PA_SOURCE_LATENCY ? "LATENCY " : "",
source->flags & PA_SOURCE_DYNAMIC_LATENCY ? "DYNAMIC_LATENCY" : "",
source_state_to_string(pa_source_get_state(source)),
+ source->suspend_cause & PA_SUSPEND_USER ? "USER " : "",
+ source->suspend_cause & PA_SUSPEND_APPLICATION ? "APPLICATION " : "",
+ source->suspend_cause & PA_SUSPEND_IDLE ? "IDLE " : "",
+ source->suspend_cause & PA_SUSPEND_SESSION ? "SESSION" : "",
+ source->priority,
pa_cvolume_snprint(cv, sizeof(cv), pa_source_get_volume(source, FALSE)),
source->flags & PA_SOURCE_DECIBEL_VOLUME ? "\n\t " : "",
source->flags & PA_SOURCE_DECIBEL_VOLUME ? pa_sw_cvolume_snprint_dB(cvdb, sizeof(cvdb), pa_source_get_volume(source, FALSE)) : "",
@@ -390,7 +416,7 @@ char *pa_source_list_to_string(pa_core *c) {
pa_strbuf_printf(
s,
"\tfixed latency: %0.2f ms\n",
- (double) pa_source_get_requested_latency(source) / PA_USEC_PER_MSEC);
+ (double) pa_source_get_fixed_latency(source) / PA_USEC_PER_MSEC);
if (source->monitor_of)
pa_strbuf_printf(s, "\tmonitor_of: %u\n", source->monitor_of->index);
@@ -402,6 +428,21 @@ char *pa_source_list_to_string(pa_core *c) {
t = pa_proplist_to_string_sep(source->proplist, "\n\t\t");
pa_strbuf_printf(s, "\tproperties:\n\t\t%s\n", t);
pa_xfree(t);
+
+ if (source->ports) {
+ pa_device_port *p;
+ void *state;
+
+ pa_strbuf_puts(s, "\tports:\n");
+ PA_HASHMAP_FOREACH(p, source->ports, state)
+ pa_strbuf_printf(s, "\t\t%s: %s (priority %u)\n", p->name, p->description, p->priority);
+ }
+
+ if (source->active_port)
+ pa_strbuf_printf(
+ s,
+ "\tactive port: <%s>\n",
+ source->active_port->name);
}
return pa_strbuf_tostring_free(s);
@@ -442,7 +483,7 @@ char *pa_source_output_list_to_string(pa_core *c) {
s,
" index: %u\n"
"\tdriver: <%s>\n"
- "\tflags: %s%s%s%s%s%s%s%s%s%s\n"
+ "\tflags: %s%s%s%s%s%s%s%s%s%s%s\n"
"\tstate: %s\n"
"\tsource: %u <%s>\n"
"\tcurrent latency: %0.2f ms\n"
@@ -461,7 +502,8 @@ char *pa_source_output_list_to_string(pa_core *c) {
o->flags & PA_SOURCE_OUTPUT_FIX_RATE ? "FIX_RATE " : "",
o->flags & PA_SOURCE_OUTPUT_FIX_CHANNELS ? "FIX_CHANNELS " : "",
o->flags & PA_SOURCE_OUTPUT_DONT_INHIBIT_AUTO_SUSPEND ? "DONT_INHIBIT_AUTO_SUSPEND " : "",
- o->flags & PA_SOURCE_OUTPUT_FAIL_ON_SUSPEND ? "FAIL_ON_SUSPEND " : "",
+ o->flags & PA_SOURCE_OUTPUT_NO_CREATE_ON_SUSPEND ? "NO_CREATE_ON_SUSPEND " : "",
+ o->flags & PA_SOURCE_OUTPUT_KILL_ON_SUSPEND ? "KILL_ON_SUSPEND " : "",
state_table[pa_source_output_get_state(o)],
o->source->index, o->source->name,
(double) pa_source_output_get_latency(o, NULL) / PA_USEC_PER_MSEC,
@@ -508,8 +550,7 @@ char *pa_sink_input_list_to_string(pa_core *c) {
pa_usec_t cl;
const char *cmn;
pa_cvolume v;
-
- pa_sink_input_get_volume(i, &v, TRUE);
+ char *volume_str = NULL;
cmn = pa_channel_map_to_pretty_name(&i->channel_map);
@@ -520,16 +561,23 @@ char *pa_sink_input_list_to_string(pa_core *c) {
pa_assert(i->sink);
+ if (pa_sink_input_is_volume_readable(i)) {
+ pa_sink_input_get_volume(i, &v, TRUE);
+ volume_str = pa_sprintf_malloc("%s\n\t %s\n\t balance %0.2f",
+ pa_cvolume_snprint(cv, sizeof(cv), &v),
+ pa_sw_cvolume_snprint_dB(cvdb, sizeof(cvdb), &v),
+ pa_cvolume_get_balance(&v, &i->channel_map));
+ } else
+ volume_str = pa_xstrdup("n/a");
+
pa_strbuf_printf(
s,
" index: %u\n"
"\tdriver: <%s>\n"
- "\tflags: %s%s%s%s%s%s%s%s%s%s\n"
+ "\tflags: %s%s%s%s%s%s%s%s%s%s%s\n"
"\tstate: %s\n"
"\tsink: %u <%s>\n"
"\tvolume: %s\n"
- "\t %s\n"
- "\t balance %0.2f\n"
"\tmuted: %s\n"
"\tcurrent latency: %0.2f ms\n"
"\trequested latency: %s\n"
@@ -547,12 +595,11 @@ char *pa_sink_input_list_to_string(pa_core *c) {
i->flags & PA_SINK_INPUT_FIX_RATE ? "FIX_RATE " : "",
i->flags & PA_SINK_INPUT_FIX_CHANNELS ? "FIX_CHANNELS " : "",
i->flags & PA_SINK_INPUT_DONT_INHIBIT_AUTO_SUSPEND ? "DONT_INHIBIT_AUTO_SUSPEND " : "",
- i->flags & PA_SINK_INPUT_FAIL_ON_SUSPEND ? "FAIL_ON_SUSPEND " : "",
+ i->flags & PA_SINK_INPUT_NO_CREATE_ON_SUSPEND ? "NO_CREATE_SUSPEND " : "",
+ i->flags & PA_SINK_INPUT_KILL_ON_SUSPEND ? "KILL_ON_SUSPEND " : "",
state_table[pa_sink_input_get_state(i)],
i->sink->index, i->sink->name,
- pa_cvolume_snprint(cv, sizeof(cv), &v),
- pa_sw_cvolume_snprint_dB(cvdb, sizeof(cvdb), &v),
- pa_cvolume_get_balance(&v, &i->channel_map),
+ volume_str,
pa_yes_no(pa_sink_input_get_mute(i)),
(double) pa_sink_input_get_latency(i, NULL) / PA_USEC_PER_MSEC,
clt,
@@ -562,6 +609,8 @@ char *pa_sink_input_list_to_string(pa_core *c) {
cmn ? cmn : "",
pa_resample_method_to_string(pa_sink_input_get_resample_method(i)));
+ pa_xfree(volume_str);
+
if (i->module)
pa_strbuf_printf(s, "\tmodule: %u\n", i->module->index);
if (i->client)
diff --git a/src/pulsecore/cli.c b/src/pulsecore/cli.c
index 54514e7f..53aa6511 100644
--- a/src/pulsecore/cli.c
+++ b/src/pulsecore/cli.c
@@ -24,21 +24,16 @@
#endif
#include <stdio.h>
-#include <string.h>
#include <stdlib.h>
#include <pulse/xmalloc.h>
+#include <pulsecore/core-util.h>
#include <pulsecore/ioline.h>
#include <pulsecore/module.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/source.h>
#include <pulsecore/client.h>
-#include <pulsecore/sink-input.h>
-#include <pulsecore/source-output.h>
#include <pulsecore/tokenizer.h>
#include <pulsecore/strbuf.h>
-#include <pulsecore/namereg.h>
#include <pulsecore/cli-text.h>
#include <pulsecore/cli-command.h>
#include <pulsecore/log.h>
diff --git a/src/pulsecore/conf-parser.c b/src/pulsecore/conf-parser.c
index a6eb581c..71529557 100644
--- a/src/pulsecore/conf-parser.c
+++ b/src/pulsecore/conf-parser.c
@@ -40,48 +40,37 @@
#define COMMENTS "#;\n"
/* Run the user supplied parser for an assignment */
-static int next_assignment(const char *filename, unsigned line, const char *section, const pa_config_item *t, const char *lvalue, const char *rvalue, void *userdata) {
+static int next_assignment(
+ const char *filename,
+ unsigned line,
+ const char *section,
+ const pa_config_item *t,
+ const char *lvalue,
+ const char *rvalue,
+ void *userdata) {
+
pa_assert(filename);
pa_assert(t);
pa_assert(lvalue);
pa_assert(rvalue);
- for (; t->parse; t++)
- if (!t->lvalue ||
- (pa_streq(lvalue, t->lvalue) &&
- ((!section && !t->section) || pa_streq(section, t->section))))
- return t->parse(filename, line, section, lvalue, rvalue, t->data, userdata);
-
- pa_log("[%s:%u] Unknown lvalue '%s' in section '%s'.", filename, line, lvalue, pa_strnull(section));
-
- return -1;
-}
-
-/* Returns non-zero when c is contained in s */
-static int in_string(char c, const char *s) {
- pa_assert(s);
+ for (; t->parse; t++) {
- for (; *s; s++)
- if (*s == c)
- return 1;
+ if (t->lvalue && !pa_streq(lvalue, t->lvalue))
+ continue;
- return 0;
-}
+ if (t->section && !section)
+ continue;
-/* Remove all whitepsapce from the beginning and the end of *s. *s may
- * be modified. */
-static char *strip(char *s) {
- char *b = s+strspn(s, WHITESPACE);
- char *e, *l = NULL;
+ if (t->section && !pa_streq(section, t->section))
+ continue;
- for (e = b; *e; e++)
- if (!in_string(*e, WHITESPACE))
- l = e;
+ return t->parse(filename, line, section, lvalue, rvalue, t->data, userdata);
+ }
- if (l)
- *(l+1) = 0;
+ pa_log("[%s:%u] Unknown lvalue '%s' in section '%s'.", filename, line, lvalue, pa_strna(section));
- return b;
+ return -1;
}
/* Parse a variable assignment line */
@@ -96,6 +85,25 @@ static int parse_line(const char *filename, unsigned line, char **section, const
if (!*b)
return 0;
+ if (pa_startswith(b, ".include ")) {
+ char *path = NULL, *fn;
+ int r;
+
+ fn = pa_strip(b+9);
+ if (!pa_is_path_absolute(fn)) {
+ const char *k;
+ if ((k = strrchr(filename, '/'))) {
+ char *dir = pa_xstrndup(filename, k-filename);
+ fn = path = pa_sprintf_malloc("%s" PA_PATH_SEP "%s", dir, fn);
+ pa_xfree(dir);
+ }
+ }
+
+ r = pa_config_parse(fn, NULL, t, userdata);
+ pa_xfree(path);
+ return r;
+ }
+
if (*b == '[') {
size_t k;
@@ -120,7 +128,7 @@ static int parse_line(const char *filename, unsigned line, char **section, const
*e = 0;
e++;
- return next_assignment(filename, line, *section, t, strip(b), strip(e), userdata);
+ return next_assignment(filename, line, *section, t, pa_strip(b), pa_strip(e), userdata);
}
/* Go through the file and parse each line */
@@ -133,8 +141,9 @@ int pa_config_parse(const char *filename, FILE *f, const pa_config_item *t, void
pa_assert(filename);
pa_assert(t);
- if (!f && !(f = fopen(filename, "r"))) {
+ if (!f && !(f = pa_fopen_cloexec(filename, "r"))) {
if (errno == ENOENT) {
+ pa_log_debug("Failed to open configuration file '%s': %s", filename, pa_cstrerror(errno));
r = 0;
goto finish;
}
@@ -242,6 +251,30 @@ int pa_config_parse_bool(const char *filename, unsigned line, const char *sectio
return 0;
}
+int pa_config_parse_not_bool(
+ const char *filename, unsigned line,
+ const char *section,
+ const char *lvalue, const char *rvalue,
+ void *data, void *userdata) {
+
+ int k;
+ pa_bool_t *b = data;
+
+ pa_assert(filename);
+ pa_assert(lvalue);
+ pa_assert(rvalue);
+ pa_assert(data);
+
+ if ((k = pa_parse_boolean(rvalue)) < 0) {
+ pa_log("[%s:%u] Failed to parse boolean value: %s", filename, line, rvalue);
+ return -1;
+ }
+
+ *b = !k;
+
+ return 0;
+}
+
int pa_config_parse_string(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
char **s = data;
diff --git a/src/pulsecore/conf-parser.h b/src/pulsecore/conf-parser.h
index 08e17ca7..c6c8a148 100644
--- a/src/pulsecore/conf-parser.h
+++ b/src/pulsecore/conf-parser.h
@@ -47,6 +47,7 @@ int pa_config_parse_int(const char *filename, unsigned line, const char *section
int pa_config_parse_unsigned(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata);
int pa_config_parse_size(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata);
int pa_config_parse_bool(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata);
+int pa_config_parse_not_bool(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata);
int pa_config_parse_string(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata);
#endif
diff --git a/src/pulsecore/core-error.c b/src/pulsecore/core-error.c
index c4408069..4d930a09 100644
--- a/src/pulsecore/core-error.c
+++ b/src/pulsecore/core-error.c
@@ -32,8 +32,6 @@
#include <pulse/utf8.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/core-util.h>
-#include <pulsecore/native-common.h>
#include <pulsecore/thread.h>
#include <pulsecore/macro.h>
#include <pulsecore/log.h>
diff --git a/src/pulsecore/core-error.h b/src/pulsecore/core-error.h
index e7bc4fca..e2950916 100644
--- a/src/pulsecore/core-error.h
+++ b/src/pulsecore/core-error.h
@@ -23,7 +23,6 @@
USA.
***/
-#include <inttypes.h>
#include <pulse/cdecl.h>
/** \file
diff --git a/src/pulsecore/rtclock.c b/src/pulsecore/core-rtclock.c
index 65c826a6..6632cc6d 100644
--- a/src/pulsecore/rtclock.c
+++ b/src/pulsecore/core-rtclock.c
@@ -24,6 +24,10 @@
#include <config.h>
#endif
+#ifdef OS_IS_DARWIN
+#define _POSIX_C_SOURCE 1
+#endif
+
#include <stddef.h>
#include <time.h>
#include <sys/time.h>
@@ -33,11 +37,26 @@
#include <sys/prctl.h>
#endif
+#ifdef OS_IS_DARWIN
+#include <CoreServices/CoreServices.h>
+#include <mach/mach.h>
+#include <mach/mach_time.h>
+#include <unistd.h>
+#endif
+
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#endif
+
#include <pulse/timeval.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-error.h>
-#include "rtclock.h"
+#include "core-rtclock.h"
+
+#ifdef OS_IS_WIN32
+static int64_t counter_freq = 0;
+#endif
pa_usec_t pa_rtclock_age(const struct timeval *tv) {
struct timeval now;
@@ -47,7 +66,20 @@ pa_usec_t pa_rtclock_age(const struct timeval *tv) {
}
struct timeval *pa_rtclock_get(struct timeval *tv) {
-#ifdef HAVE_CLOCK_GETTIME
+
+#if defined(OS_IS_DARWIN)
+ uint64_t val, abs_time = mach_absolute_time();
+ Nanoseconds nanos;
+
+ nanos = AbsoluteToNanoseconds(*(AbsoluteTime *) &abs_time);
+ val = *(uint64_t *) &nanos;
+
+ tv->tv_sec = val / PA_NSEC_PER_SEC;
+ tv->tv_usec = (val % PA_NSEC_PER_SEC) / PA_NSEC_PER_USEC;
+
+ return tv;
+
+#elif defined(HAVE_CLOCK_GETTIME)
struct timespec ts;
#ifdef CLOCK_MONOTONIC
@@ -59,45 +91,70 @@ struct timeval *pa_rtclock_get(struct timeval *tv) {
no_monotonic = TRUE;
if (no_monotonic)
-#endif
+#endif /* CLOCK_MONOTONIC */
pa_assert_se(clock_gettime(CLOCK_REALTIME, &ts) == 0);
pa_assert(tv);
tv->tv_sec = ts.tv_sec;
- tv->tv_usec = ts.tv_nsec / 1000;
+ tv->tv_usec = ts.tv_nsec / PA_NSEC_PER_USEC;
return tv;
+#elif defined(OS_IS_WIN32)
+ if (counter_freq > 0) {
+ LARGE_INTEGER count;
-#else /* HAVE_CLOCK_GETTIME */
+ pa_assert_se(QueryPerformanceCounter(&count));
- return pa_gettimeofday(tv);
+ tv->tv_sec = count.QuadPart / counter_freq;
+ tv->tv_usec = (count.QuadPart % counter_freq) * PA_USEC_PER_SEC / counter_freq;
-#endif
+ return tv;
+ }
+#endif /* HAVE_CLOCK_GETTIME */
+
+ return pa_gettimeofday(tv);
}
pa_bool_t pa_rtclock_hrtimer(void) {
-#ifdef HAVE_CLOCK_GETTIME
+
+#if defined (OS_IS_DARWIN)
+ mach_timebase_info_data_t tbi;
+ uint64_t time_nsec;
+
+ mach_timebase_info(&tbi);
+
+ /* nsec = nticks * (N/D) - we want 1 tick == resolution !? */
+ time_nsec = tbi.numer / tbi.denom;
+ return time_nsec <= (long) (PA_HRTIMER_THRESHOLD_USEC*PA_NSEC_PER_USEC);
+
+#elif defined(HAVE_CLOCK_GETTIME)
struct timespec ts;
#ifdef CLOCK_MONOTONIC
+
if (clock_getres(CLOCK_MONOTONIC, &ts) >= 0)
- return ts.tv_sec == 0 && ts.tv_nsec <= PA_HRTIMER_THRESHOLD_USEC*1000;
-#endif
+ return ts.tv_sec == 0 && ts.tv_nsec <= (long) (PA_HRTIMER_THRESHOLD_USEC*PA_NSEC_PER_USEC);
+
+#endif /* CLOCK_MONOTONIC */
pa_assert_se(clock_getres(CLOCK_REALTIME, &ts) == 0);
- return ts.tv_sec == 0 && ts.tv_nsec <= PA_HRTIMER_THRESHOLD_USEC*1000;
+ return ts.tv_sec == 0 && ts.tv_nsec <= (long) (PA_HRTIMER_THRESHOLD_USEC*PA_NSEC_PER_USEC);
-#else /* HAVE_CLOCK_GETTIME */
+#elif defined(OS_IS_WIN32)
- return FALSE;
+ if (counter_freq > 0)
+ return counter_freq >= (int64_t) (PA_USEC_PER_SEC/PA_HRTIMER_THRESHOLD_USEC);
-#endif
+#endif /* HAVE_CLOCK_GETTIME */
+
+ return FALSE;
}
#define TIMER_SLACK_NS (int) ((500 * PA_NSEC_PER_USEC))
void pa_rtclock_hrtimer_enable(void) {
+
#ifdef PR_SET_TIMERSLACK
int slack_ns;
@@ -119,24 +176,24 @@ void pa_rtclock_hrtimer_enable(void) {
}
}
-#endif
-}
+#elif defined(OS_IS_WIN32)
+ LARGE_INTEGER freq;
-pa_usec_t pa_rtclock_usec(void) {
- struct timeval tv;
+ pa_assert_se(QueryPerformanceFrequency(&freq));
+ counter_freq = freq.QuadPart;
- return pa_timeval_load(pa_rtclock_get(&tv));
+#endif
}
struct timeval* pa_rtclock_from_wallclock(struct timeval *tv) {
-
-#ifdef HAVE_CLOCK_GETTIME
struct timeval wc_now, rt_now;
+ pa_assert(tv);
+
pa_gettimeofday(&wc_now);
pa_rtclock_get(&rt_now);
- pa_assert(tv);
+ /* pa_timeval_sub() saturates on underflow! */
if (pa_timeval_cmp(&wc_now, tv) < 0)
pa_timeval_add(&rt_now, pa_timeval_diff(tv, &wc_now));
@@ -144,15 +201,69 @@ struct timeval* pa_rtclock_from_wallclock(struct timeval *tv) {
pa_timeval_sub(&rt_now, pa_timeval_diff(&wc_now, tv));
*tv = rt_now;
-#endif
return tv;
}
+#ifdef HAVE_CLOCK_GETTIME
pa_usec_t pa_timespec_load(const struct timespec *ts) {
- pa_assert(ts);
+
+ if (PA_UNLIKELY(!ts))
+ return PA_USEC_INVALID;
return
(pa_usec_t) ts->tv_sec * PA_USEC_PER_SEC +
(pa_usec_t) ts->tv_nsec / PA_NSEC_PER_USEC;
}
+
+struct timespec* pa_timespec_store(struct timespec *ts, pa_usec_t v) {
+ pa_assert(ts);
+
+ if (PA_UNLIKELY(v == PA_USEC_INVALID)) {
+ ts->tv_sec = PA_INT_TYPE_MAX(time_t);
+ ts->tv_nsec = (long) (PA_NSEC_PER_SEC-1);
+ return NULL;
+ }
+
+ ts->tv_sec = (time_t) (v / PA_USEC_PER_SEC);
+ ts->tv_nsec = (long) ((v % PA_USEC_PER_SEC) * PA_NSEC_PER_USEC);
+
+ return ts;
+}
+#endif
+
+static struct timeval* wallclock_from_rtclock(struct timeval *tv) {
+ struct timeval wc_now, rt_now;
+
+ pa_assert(tv);
+
+ pa_gettimeofday(&wc_now);
+ pa_rtclock_get(&rt_now);
+
+ /* pa_timeval_sub() saturates on underflow! */
+
+ if (pa_timeval_cmp(&rt_now, tv) < 0)
+ pa_timeval_add(&wc_now, pa_timeval_diff(tv, &rt_now));
+ else
+ pa_timeval_sub(&wc_now, pa_timeval_diff(&rt_now, tv));
+
+ *tv = wc_now;
+
+ return tv;
+}
+
+struct timeval* pa_timeval_rtstore(struct timeval *tv, pa_usec_t v, pa_bool_t rtclock) {
+ pa_assert(tv);
+
+ if (v == PA_USEC_INVALID)
+ return NULL;
+
+ pa_timeval_store(tv, v);
+
+ if (rtclock)
+ tv->tv_usec |= PA_TIMEVAL_RTCLOCK;
+ else
+ wallclock_from_rtclock(tv);
+
+ return tv;
+}
diff --git a/src/pulsecore/rtclock.h b/src/pulsecore/core-rtclock.h
index 03cc1c72..62535368 100644
--- a/src/pulsecore/rtclock.h
+++ b/src/pulsecore/core-rtclock.h
@@ -31,8 +31,6 @@ struct timeval;
struct timeval *pa_rtclock_get(struct timeval *ts);
-pa_usec_t pa_rtclock_usec(void);
-
pa_usec_t pa_rtclock_age(const struct timeval *tv);
pa_bool_t pa_rtclock_hrtimer(void);
void pa_rtclock_hrtimer_enable(void);
@@ -40,8 +38,16 @@ void pa_rtclock_hrtimer_enable(void);
/* timer with a resolution better than this are considered high-resolution */
#define PA_HRTIMER_THRESHOLD_USEC 10
+/* bit to set in tv.tv_usec to mark that the timeval is in monotonic time */
+#define PA_TIMEVAL_RTCLOCK ((time_t) (1LU << 30))
+
struct timeval* pa_rtclock_from_wallclock(struct timeval *tv);
+#ifdef HAVE_CLOCK_GETTIME
pa_usec_t pa_timespec_load(const struct timespec *ts);
+struct timespec* pa_timespec_store(struct timespec *ts, pa_usec_t v);
+#endif
+
+struct timeval* pa_timeval_rtstore(struct timeval *tv, pa_usec_t v, pa_bool_t rtclock);
#endif
diff --git a/src/pulsecore/core-scache.c b/src/pulsecore/core-scache.c
index 086f5fcb..4f2a44dc 100644
--- a/src/pulsecore/core-scache.c
+++ b/src/pulsecore/core-scache.c
@@ -25,13 +25,13 @@
#endif
#include <stdlib.h>
-#include <string.h>
#include <stdio.h>
#include <sys/types.h>
#include <dirent.h>
#include <sys/stat.h>
#include <errno.h>
#include <limits.h>
+#include <time.h>
#ifdef HAVE_GLOB_H
#include <glob.h>
@@ -47,13 +47,14 @@
#include <pulse/util.h>
#include <pulse/volume.h>
#include <pulse/xmalloc.h>
+#include <pulse/rtclock.h>
#include <pulsecore/sink-input.h>
-#include <pulsecore/sample-util.h>
#include <pulsecore/play-memchunk.h>
#include <pulsecore/core-subscribe.h>
#include <pulsecore/namereg.h>
#include <pulsecore/sound-file.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/core-error.h>
@@ -61,11 +62,10 @@
#include "core-scache.h"
-#define UNLOAD_POLL_TIME 60
+#define UNLOAD_POLL_TIME (60 * PA_USEC_PER_SEC)
-static void timeout_callback(pa_mainloop_api *m, pa_time_event*e, const struct timeval *tv, void *userdata) {
+static void timeout_callback(pa_mainloop_api *m, pa_time_event *e, const struct timeval *t, void *userdata) {
pa_core *c = userdata;
- struct timeval ntv;
pa_assert(c);
pa_assert(c->mainloop == m);
@@ -73,9 +73,7 @@ static void timeout_callback(pa_mainloop_api *m, pa_time_event*e, const struct t
pa_scache_unload_unused(c);
- pa_gettimeofday(&ntv);
- ntv.tv_sec += UNLOAD_POLL_TIME;
- m->time_restart(e, &ntv);
+ pa_core_rttime_restart(c, e, pa_rtclock_now() + UNLOAD_POLL_TIME);
}
static void free_entry(pa_scache_entry *e) {
@@ -256,12 +254,8 @@ int pa_scache_add_file_lazy(pa_core *c, const char *name, const char *filename,
pa_proplist_sets(e->proplist, PA_PROP_MEDIA_FILENAME, filename);
- if (!c->scache_auto_unload_event) {
- struct timeval ntv;
- pa_gettimeofday(&ntv);
- ntv.tv_sec += UNLOAD_POLL_TIME;
- c->scache_auto_unload_event = c->mainloop->time_new(c->mainloop, &ntv, timeout_callback, c);
- }
+ if (!c->scache_auto_unload_event)
+ c->scache_auto_unload_event = pa_core_rttime_new(c, pa_rtclock_now() + UNLOAD_POLL_TIME, timeout_callback, c);
if (idx)
*idx = e->index;
@@ -315,7 +309,8 @@ int pa_scache_play_item(pa_core *c, const char *name, pa_sink *sink, pa_volume_t
return -1;
merged = pa_proplist_new();
- pa_proplist_setf(merged, PA_PROP_MEDIA_NAME, "Sample %s", name);
+ pa_proplist_sets(merged, PA_PROP_MEDIA_NAME, name);
+ pa_proplist_sets(merged, PA_PROP_EVENT_ID, name);
if (e->lazy && !e->memchunk.memblock) {
pa_channel_map old_channel_map = e->channel_map;
@@ -340,12 +335,12 @@ int pa_scache_play_item(pa_core *c, const char *name, pa_sink *sink, pa_volume_t
pass_volume = TRUE;
- if (e->volume_is_set && volume != (pa_volume_t) -1) {
+ if (e->volume_is_set && PA_VOLUME_IS_VALID(volume)) {
pa_cvolume_set(&r, e->sample_spec.channels, volume);
pa_sw_cvolume_multiply(&r, &r, &e->volume);
} else if (e->volume_is_set)
r = e->volume;
- else if (volume != (pa_volume_t) -1)
+ else if (PA_VOLUME_IS_VALID(volume))
pa_cvolume_set(&r, e->sample_spec.channels, volume);
else
pass_volume = FALSE;
@@ -355,7 +350,12 @@ int pa_scache_play_item(pa_core *c, const char *name, pa_sink *sink, pa_volume_t
if (p)
pa_proplist_update(merged, PA_UPDATE_REPLACE, p);
- if (pa_play_memchunk(sink, &e->sample_spec, &e->channel_map, &e->memchunk, pass_volume ? &r : NULL, merged, sink_input_idx) < 0)
+ if (pa_play_memchunk(sink,
+ &e->sample_spec, &e->channel_map,
+ &e->memchunk,
+ pass_volume ? &r : NULL,
+ merged,
+ PA_SINK_INPUT_NO_CREATE_ON_SUSPEND|PA_SINK_INPUT_KILL_ON_SUSPEND, sink_input_idx) < 0)
goto fail;
pa_proplist_free(merged);
@@ -499,13 +499,14 @@ int pa_scache_add_directory_lazy(pa_core *c, const char *pathname) {
struct dirent *e;
while ((e = readdir(dir))) {
- char p[PATH_MAX];
+ char *p;
if (e->d_name[0] == '.')
continue;
- pa_snprintf(p, sizeof(p), "%s/%s", pathname, e->d_name);
+ p = pa_sprintf_malloc("%s" PA_PATH_SEP "%s", pathname, e->d_name);
add_file(c, p);
+ pa_xfree(p);
}
closedir(dir);
diff --git a/src/pulsecore/core-subscribe.c b/src/pulsecore/core-subscribe.c
index 54fb7ec2..e13e6ea2 100644
--- a/src/pulsecore/core-subscribe.c
+++ b/src/pulsecore/core-subscribe.c
@@ -27,7 +27,6 @@
#include <pulse/xmalloc.h>
-#include <pulsecore/queue.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
diff --git a/src/pulsecore/core-util.c b/src/pulsecore/core-util.c
index b747cd84..f27f87ae 100644
--- a/src/pulsecore/core-util.c
+++ b/src/pulsecore/core-util.c
@@ -34,15 +34,24 @@
#include <fcntl.h>
#include <unistd.h>
#include <limits.h>
-#include <time.h>
#include <ctype.h>
#include <sys/types.h>
#include <sys/stat.h>
-#include <sys/time.h>
#include <dirent.h>
-#include <regex.h>
+
+#ifdef HAVE_LANGINFO_H
#include <langinfo.h>
+#endif
+
+#ifdef HAVE_UNAME
#include <sys/utsname.h>
+#endif
+
+#if defined(HAVE_REGEX_H)
+#include <regex.h>
+#elif defined(HAVE_PCREPOSIX_H)
+#include <pcreposix.h>
+#endif
#ifdef HAVE_STRTOF_L
#include <locale.h>
@@ -50,6 +59,10 @@
#ifdef HAVE_SCHED_H
#include <sched.h>
+
+#if defined(__linux__) && !defined(SCHED_RESET_ON_FORK)
+#define SCHED_RESET_ON_FORK 0x40000000
+#endif
#endif
#ifdef HAVE_SYS_RESOURCE_H
@@ -76,6 +89,10 @@
#include <windows.h>
#endif
+#ifndef ENOTSUP
+#define ENOTSUP 135
+#endif
+
#ifdef HAVE_PWD_H
#include <pwd.h>
#endif
@@ -90,6 +107,18 @@
#ifdef __APPLE__
#include <xlocale.h>
+#include <mach/mach_init.h>
+#include <mach/thread_act.h>
+#include <mach/thread_policy.h>
+#include <sys/sysctl.h>
+#endif
+
+#ifdef HAVE_DBUS
+#include "rtkit.h"
+#endif
+
+#ifdef __linux__
+#include <sys/personality.h>
#endif
#include <pulse/xmalloc.h>
@@ -97,11 +126,15 @@
#include <pulse/utf8.h>
#include <pulsecore/core-error.h>
-#include <pulsecore/winsock.h>
+#include <pulsecore/socket.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/thread.h>
#include <pulsecore/strbuf.h>
+#include <pulsecore/usergroup.h>
+#include <pulsecore/strlist.h>
+#include <pulsecore/cpu-x86.h>
+#include <pulsecore/pipe.h>
#include "core-util.h"
@@ -110,28 +143,36 @@
#define MSG_NOSIGNAL 0
#endif
-#ifdef OS_IS_WIN32
+#define NEWLINE "\r\n"
+#define WHITESPACE "\n\r \t"
-#define PULSE_ROOTENV "PULSE_ROOT"
+static pa_strlist *recorded_env = NULL;
-int pa_set_root(HANDLE handle) {
- char library_path[MAX_PATH + sizeof(PULSE_ROOTENV) + 1], *sep;
+#ifdef OS_IS_WIN32
- strcpy(library_path, PULSE_ROOTENV "=");
+/* Returns the directory of the current DLL, with '/bin/' removed if it is the last component */
+char *pa_win32_get_toplevel(HANDLE handle) {
+ static char *toplevel = NULL;
- /* FIXME: Needs to set errno */
+ if (!toplevel) {
+ char library_path[MAX_PATH];
+ char *p;
- if (!GetModuleFileName(handle, library_path + sizeof(PULSE_ROOTENV), MAX_PATH))
- return 0;
+ if (!GetModuleFileName(handle, library_path, MAX_PATH))
+ return NULL;
- sep = strrchr(library_path, PA_PATH_SEP_CHAR);
- if (sep)
- *sep = '\0';
+ toplevel = pa_xstrdup(library_path);
- if (_putenv(library_path) < 0)
- return 0;
+ p = strrchr(toplevel, PA_PATH_SEP_CHAR);
+ if (p)
+ *p = '\0';
- return 1;
+ p = strrchr(toplevel, PA_PATH_SEP_CHAR);
+ if (p && (strcmp(p + 1, "bin") == 0))
+ *p = '\0';
+ }
+
+ return toplevel;
}
#endif
@@ -185,27 +226,59 @@ int pa_make_secure_dir(const char* dir, mode_t m, uid_t uid, gid_t gid) {
#ifdef OS_IS_WIN32
r = mkdir(dir);
#else
- {
+{
mode_t u;
u = umask((~m) & 0777);
r = mkdir(dir, m);
umask(u);
- }
+}
#endif
if (r < 0 && errno != EEXIST)
return -1;
-#ifdef HAVE_CHOWN
- if (uid == (uid_t)-1)
+#if defined(HAVE_FSTAT) && !defined(OS_IS_WIN32)
+{
+ int fd;
+ if ((fd = open(dir,
+#ifdef O_CLOEXEC
+ O_CLOEXEC|
+#endif
+#ifdef O_NOCTTY
+ O_NOCTTY|
+#endif
+#ifdef O_NOFOLLOW
+ O_NOFOLLOW|
+#endif
+ O_RDONLY)) < 0)
+ goto fail;
+
+ if (fstat(fd, &st) < 0) {
+ pa_assert_se(pa_close(fd) >= 0);
+ goto fail;
+ }
+
+ if (!S_ISDIR(st.st_mode)) {
+ pa_assert_se(pa_close(fd) >= 0);
+ errno = EEXIST;
+ goto fail;
+ }
+
+#ifdef HAVE_FCHOWN
+ if (uid == (uid_t) -1)
uid = getuid();
- if (gid == (gid_t)-1)
+ if (gid == (gid_t) -1)
gid = getgid();
- (void) chown(dir, uid, gid);
+ if (fchown(fd, uid, gid) < 0)
+ goto fail;
#endif
-#ifdef HAVE_CHMOD
- chmod(dir, m);
+#ifdef HAVE_FCHMOD
+ (void) fchmod(fd, m);
+#endif
+
+ pa_assert_se(pa_close(fd) >= 0);
+}
#endif
#ifdef HAVE_LSTAT
@@ -484,7 +557,7 @@ void pa_check_signal_is_blocked(int sig) {
/* The following function is based on an example from the GNU libc
* documentation. This function is similar to GNU's asprintf(). */
char *pa_sprintf_malloc(const char *format, ...) {
- size_t size = 100;
+ size_t size = 100;
char *c = NULL;
pa_assert(format);
@@ -514,7 +587,7 @@ char *pa_sprintf_malloc(const char *format, ...) {
/* Same as the previous function, but use a va_list instead of an
* ellipsis */
char *pa_vsprintf_malloc(const char *format, va_list ap) {
- size_t size = 100;
+ size_t size = 100;
char *c = NULL;
pa_assert(format);
@@ -543,159 +616,218 @@ char *pa_vsprintf_malloc(const char *format, va_list ap) {
/* Similar to OpenBSD's strlcpy() function */
char *pa_strlcpy(char *b, const char *s, size_t l) {
+ size_t k;
+
pa_assert(b);
pa_assert(s);
pa_assert(l > 0);
- strncpy(b, s, l);
- b[l-1] = 0;
+ k = strlen(s);
+
+ if (k > l-1)
+ k = l-1;
+
+ memcpy(b, s, k);
+ b[k] = 0;
+
return b;
}
-/* Make the current thread a realtime thread, and acquire the highest
- * rtprio we can get that is less or equal the specified parameter. If
- * the thread is already realtime, don't do anything. */
-int pa_make_realtime(int rtprio) {
-
#ifdef _POSIX_PRIORITY_SCHEDULING
+static int set_scheduler(int rtprio) {
+#ifdef HAVE_SCHED_H
struct sched_param sp;
- int r, policy;
+#ifdef HAVE_DBUS
+ int r;
+ DBusError error;
+ DBusConnection *bus;
- memset(&sp, 0, sizeof(sp));
- policy = 0;
+ dbus_error_init(&error);
+#endif
- if ((r = pthread_getschedparam(pthread_self(), &policy, &sp)) != 0) {
- pa_log("pthread_getschedgetparam(): %s", pa_cstrerror(r));
- return -1;
+ pa_zero(sp);
+ sp.sched_priority = rtprio;
+
+#ifdef SCHED_RESET_ON_FORK
+ if (pthread_setschedparam(pthread_self(), SCHED_RR|SCHED_RESET_ON_FORK, &sp) == 0) {
+ pa_log_debug("SCHED_RR|SCHED_RESET_ON_FORK worked.");
+ return 0;
}
+#endif
- if (policy == SCHED_FIFO && sp.sched_priority >= rtprio) {
- pa_log_info("Thread already being scheduled with SCHED_FIFO with priority %i.", sp.sched_priority);
+ if (pthread_setschedparam(pthread_self(), SCHED_RR, &sp) == 0) {
+ pa_log_debug("SCHED_RR worked.");
return 0;
}
+#endif /* HAVE_SCHED_H */
- sp.sched_priority = rtprio;
- if ((r = pthread_setschedparam(pthread_self(), SCHED_FIFO, &sp)) != 0) {
+#ifdef HAVE_DBUS
+ /* Try to talk to RealtimeKit */
- while (sp.sched_priority > 1) {
- sp.sched_priority --;
+ if (!(bus = dbus_bus_get_private(DBUS_BUS_SYSTEM, &error))) {
+ pa_log("Failed to connect to system bus: %s\n", error.message);
+ dbus_error_free(&error);
+ errno = -EIO;
+ return -1;
+ }
- if ((r = pthread_setschedparam(pthread_self(), SCHED_FIFO, &sp)) == 0) {
- pa_log_info("Successfully enabled SCHED_FIFO scheduling for thread, with priority %i, which is lower than the requested %i.", sp.sched_priority, rtprio);
- return 0;
- }
- }
+ /* We need to disable exit on disconnect because otherwise
+ * dbus_shutdown will kill us. See
+ * https://bugs.freedesktop.org/show_bug.cgi?id=16924 */
+ dbus_connection_set_exit_on_disconnect(bus, FALSE);
- pa_log_warn("pthread_setschedparam(): %s", pa_cstrerror(r));
- return -1;
+ r = rtkit_make_realtime(bus, 0, rtprio);
+ dbus_connection_close(bus);
+ dbus_connection_unref(bus);
+
+ if (r >= 0) {
+ pa_log_debug("RealtimeKit worked.");
+ return 0;
}
- pa_log_info("Successfully enabled SCHED_FIFO scheduling for thread, with priority %i.", sp.sched_priority);
- return 0;
+ errno = -r;
#else
+ errno = 0;
+#endif
- errno = ENOTSUP;
return -1;
-#endif
}
+#endif
+
+/* Make the current thread a realtime thread, and acquire the highest
+ * rtprio we can get that is less or equal the specified parameter. If
+ * the thread is already realtime, don't do anything. */
+int pa_make_realtime(int rtprio) {
-/* This is merely used for giving the user a hint. This is not correct
- * for anything security related */
-pa_bool_t pa_can_realtime(void) {
+#if defined(OS_IS_DARWIN)
+ struct thread_time_constraint_policy ttcpolicy;
+ uint64_t freq = 0;
+ size_t size = sizeof(freq);
+ int ret;
- if (geteuid() == 0)
- return TRUE;
+ ret = sysctlbyname("hw.cpufrequency", &freq, &size, NULL, 0);
+ if (ret < 0) {
+ pa_log_info("Unable to read CPU frequency, acquisition of real-time scheduling failed.");
+ return -1;
+ }
-#if defined(HAVE_SYS_RESOURCE_H) && defined(RLIMIT_RTPRIO)
- {
- struct rlimit rl;
+ pa_log_debug("sysctl for hw.cpufrequency: %llu", freq);
- if (getrlimit(RLIMIT_RTPRIO, &rl) >= 0)
- if (rl.rlim_cur > 0 || rl.rlim_cur == RLIM_INFINITY)
- return TRUE;
+ /* See http://developer.apple.com/library/mac/#documentation/Darwin/Conceptual/KernelProgramming/scheduler/scheduler.html */
+ ttcpolicy.period = freq / 160;
+ ttcpolicy.computation = freq / 3300;
+ ttcpolicy.constraint = freq / 2200;
+ ttcpolicy.preemptible = 1;
+
+ ret = thread_policy_set(mach_thread_self(),
+ THREAD_TIME_CONSTRAINT_POLICY,
+ (thread_policy_t) &ttcpolicy,
+ THREAD_TIME_CONSTRAINT_POLICY_COUNT);
+ if (ret) {
+ pa_log_info("Unable to set real-time thread priority (%08x).", ret);
+ return -1;
}
-#endif
-#if defined(HAVE_SYS_CAPABILITY_H) && defined(CAP_SYS_NICE)
- {
- cap_t cap;
+ pa_log_info("Successfully acquired real-time thread priority.");
+ return 0;
- if ((cap = cap_get_proc())) {
- cap_flag_value_t flag = CAP_CLEAR;
+#elif defined(_POSIX_PRIORITY_SCHEDULING)
+ int p;
- if (cap_get_flag(cap, CAP_SYS_NICE, CAP_EFFECTIVE, &flag) >= 0)
- if (flag == CAP_SET) {
- cap_free(cap);
- return TRUE;
- }
+ if (set_scheduler(rtprio) >= 0) {
+ pa_log_info("Successfully enabled SCHED_RR scheduling for thread, with priority %i.", rtprio);
+ return 0;
+ }
- cap_free(cap);
+ for (p = rtprio-1; p >= 1; p--)
+ if (set_scheduler(p) >= 0) {
+ pa_log_info("Successfully enabled SCHED_RR scheduling for thread, with priority %i, which is lower than the requested %i.", p, rtprio);
+ return 0;
}
+#elif defined(OS_IS_WIN32)
+ /* Windows only allows realtime scheduling to be set on a per process basis.
+ * Therefore, instead of making the thread realtime, just give it the highest non-realtime priority. */
+ if (SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_TIME_CRITICAL)) {
+ pa_log_info("Successfully enabled THREAD_PRIORITY_TIME_CRITICAL scheduling for thread.");
+ return 0;
}
-#endif
- return FALSE;
+ pa_log_warn("SetThreadPriority() failed: 0x%08X", GetLastError());
+ errno = EPERM;
+#else
+ errno = ENOTSUP;
+#endif
+ pa_log_info("Failed to acquire real-time scheduling: %s", pa_cstrerror(errno));
+ return -1;
}
-/* This is merely used for giving the user a hint. This is not correct
- * for anything security related */
-pa_bool_t pa_can_high_priority(void) {
-
- if (geteuid() == 0)
- return TRUE;
+#ifdef HAVE_SYS_RESOURCE_H
+static int set_nice(int nice_level) {
+#ifdef HAVE_DBUS
+ DBusError error;
+ DBusConnection *bus;
+ int r;
-#if defined(HAVE_SYS_RESOURCE_H) && defined(RLIMIT_RTPRIO)
- {
- struct rlimit rl;
+ dbus_error_init(&error);
+#endif
- if (getrlimit(RLIMIT_NICE, &rl) >= 0)
- if (rl.rlim_cur >= 21 || rl.rlim_cur == RLIM_INFINITY)
- return TRUE;
+#ifdef HAVE_SYS_RESOURCE_H
+ if (setpriority(PRIO_PROCESS, 0, nice_level) >= 0) {
+ pa_log_debug("setpriority() worked.");
+ return 0;
}
#endif
-#if defined(HAVE_SYS_CAPABILITY_H) && defined(CAP_SYS_NICE)
- {
- cap_t cap;
+#ifdef HAVE_DBUS
+ /* Try to talk to RealtimeKit */
+
+ if (!(bus = dbus_bus_get(DBUS_BUS_SYSTEM, &error))) {
+ pa_log("Failed to connect to system bus: %s\n", error.message);
+ dbus_error_free(&error);
+ errno = -EIO;
+ return -1;
+ }
- if ((cap = cap_get_proc())) {
- cap_flag_value_t flag = CAP_CLEAR;
+ /* We need to disable exit on disconnect because otherwise
+ * dbus_shutdown will kill us. See
+ * https://bugs.freedesktop.org/show_bug.cgi?id=16924 */
+ dbus_connection_set_exit_on_disconnect(bus, FALSE);
- if (cap_get_flag(cap, CAP_SYS_NICE, CAP_EFFECTIVE, &flag) >= 0)
- if (flag == CAP_SET) {
- cap_free(cap);
- return TRUE;
- }
+ r = rtkit_make_high_priority(bus, 0, nice_level);
+ dbus_connection_unref(bus);
- cap_free(cap);
- }
+ if (r >= 0) {
+ pa_log_debug("RealtimeKit worked.");
+ return 0;
}
+
+ errno = -r;
#endif
- return FALSE;
+ return -1;
}
+#endif
/* Raise the priority of the current process as much as possible that
* is <= the specified nice level..*/
int pa_raise_priority(int nice_level) {
#ifdef HAVE_SYS_RESOURCE_H
- if (setpriority(PRIO_PROCESS, 0, nice_level) < 0) {
- int n;
+ int n;
- for (n = nice_level+1; n < 0; n++) {
+ if (set_nice(nice_level) >= 0) {
+ pa_log_info("Successfully gained nice level %i.", nice_level);
+ return 0;
+ }
- if (setpriority(PRIO_PROCESS, 0, n) == 0) {
- pa_log_info("Successfully acquired nice level %i, which is lower than the requested %i.", n, nice_level);
- return 0;
- }
+ for (n = nice_level+1; n < 0; n++)
+ if (set_nice(n) >= 0) {
+ pa_log_info("Successfully acquired nice level %i, which is lower than the requested %i.", n, nice_level);
+ return 0;
}
- pa_log_warn("setpriority(): %s", pa_cstrerror(errno));
- return -1;
- }
-
- pa_log_info("Successfully gained nice level %i.", nice_level);
+ pa_log_info("Failed to acquire high-priority scheduling: %s", pa_cstrerror(errno));
+ return -1;
#endif
#ifdef OS_IS_WIN32
@@ -703,9 +835,10 @@ int pa_raise_priority(int nice_level) {
if (!SetPriorityClass(GetCurrentProcess(), HIGH_PRIORITY_CLASS)) {
pa_log_warn("SetPriorityClass() failed: 0x%08X", GetLastError());
errno = EPERM;
- return .-1;
- } else
- pa_log_info("Successfully gained high priority class.");
+ return -1;
+ }
+
+ pa_log_info("Successfully gained high priority class.");
}
#endif
@@ -720,8 +853,8 @@ void pa_reset_priority(void) {
setpriority(PRIO_PROCESS, 0, 0);
- memset(&sp, 0, sizeof(sp));
- pa_assert_se(pthread_setschedparam(pthread_self(), SCHED_OTHER, &sp) == 0);
+ pa_zero(sp);
+ pthread_setschedparam(pthread_self(), SCHED_OTHER, &sp);
#endif
#ifdef OS_IS_WIN32
@@ -756,8 +889,6 @@ int pa_match(const char *expr, const char *v) {
/* Try to parse a boolean string value.*/
int pa_parse_boolean(const char *v) {
- const char *expr;
- int r;
pa_assert(v);
/* First we check language independant */
@@ -766,16 +897,21 @@ int pa_parse_boolean(const char *v) {
else if (!strcmp(v, "0") || v[0] == 'n' || v[0] == 'N' || v[0] == 'f' || v[0] == 'F' || !strcasecmp(v, "off"))
return 0;
+#ifdef HAVE_LANGINFO_H
+{
+ const char *expr;
/* And then we check language dependant */
if ((expr = nl_langinfo(YESEXPR)))
if (expr[0])
- if ((r = pa_match(expr, v)) > 0)
+ if (pa_match(expr, v) > 0)
return 1;
if ((expr = nl_langinfo(NOEXPR)))
if (expr[0])
- if ((r = pa_match(expr, v)) > 0)
+ if (pa_match(expr, v) > 0)
return 0;
+}
+#endif
errno = EINVAL;
return -1;
@@ -801,9 +937,6 @@ char *pa_split(const char *c, const char *delimiter, const char**state) {
return pa_xstrndup(current, l);
}
-/* What is interpreted as whitespace? */
-#define WHITESPACE " \t\n"
-
/* Split a string into words. Otherwise similar to pa_split(). */
char *pa_split_spaces(const char *c, const char **state) {
const char *current = *state ? *state : c;
@@ -847,7 +980,7 @@ const char *pa_sig2str(int sig) {
}
#else
- switch(sig) {
+ switch (sig) {
#ifdef SIGHUP
case SIGHUP: return "SIGHUP";
#endif
@@ -954,54 +1087,23 @@ fail:
/* Check whether the specified GID and the group name match */
static int is_group(gid_t gid, const char *name) {
- struct group group, *result = NULL;
- long n;
- void *data;
+ struct group *group = NULL;
int r = -1;
-#ifdef HAVE_GETGRGID_R
-#ifdef _SC_GETGR_R_SIZE_MAX
- n = sysconf(_SC_GETGR_R_SIZE_MAX);
-#else
- n = -1;
-#endif
- if (n <= 0)
- n = 512;
-
- data = pa_xmalloc((size_t) n);
-
errno = 0;
- if (getgrgid_r(gid, &group, data, (size_t) n, &result) < 0 || !result) {
- pa_log("getgrgid_r(%u): %s", (unsigned) gid, pa_cstrerror(errno));
-
+ if (!(group = pa_getgrgid_malloc(gid))) {
if (!errno)
errno = ENOENT;
- goto finish;
- }
-
- r = strcmp(name, result->gr_name) == 0;
-
-finish:
- pa_xfree(data);
-#else
- /* XXX Not thread-safe, but needed on OSes (e.g. FreeBSD 4.X) that do not
- * support getgrgid_r. */
-
- errno = 0;
- if (!(result = getgrgid(gid))) {
- pa_log("getgrgid(%u): %s", gid, pa_cstrerror(errno));
-
- if (!errno)
- errno = ENOENT;
+ pa_log("pa_getgrgid_malloc(%u): %s", gid, pa_cstrerror(errno));
goto finish;
}
- r = strcmp(name, result->gr_name) == 0;
+ r = strcmp(name, group->gr_name) == 0;
finish:
-#endif
+ pa_getgrgid_free(group);
return r;
}
@@ -1050,64 +1152,36 @@ finish:
/* Check whether the specifc user id is a member of the specified group */
int pa_uid_in_group(uid_t uid, const char *name) {
- char *g_buf, *p_buf;
- long g_n, p_n;
- struct group grbuf, *gr;
+ struct group *group = NULL;
char **i;
int r = -1;
-#ifdef _SC_GETGR_R_SIZE_MAX
- g_n = sysconf(_SC_GETGR_R_SIZE_MAX);
-#else
- g_n = -1;
-#endif
- if (g_n <= 0)
- g_n = 512;
-
- g_buf = pa_xmalloc((size_t) g_n);
-
-#ifdef _SC_GETPW_R_SIZE_MAX
- p_n = sysconf(_SC_GETPW_R_SIZE_MAX);
-#else
- p_n = -1;
-#endif
- if (p_n <= 0)
- p_n = 512;
-
- p_buf = pa_xmalloc((size_t) p_n);
-
errno = 0;
-#ifdef HAVE_GETGRNAM_R
- if (getgrnam_r(name, &grbuf, g_buf, (size_t) g_n, &gr) != 0 || !gr)
-#else
- if (!(gr = getgrnam(name)))
-#endif
- {
+ if (!(group = pa_getgrnam_malloc(name))) {
if (!errno)
errno = ENOENT;
goto finish;
}
r = 0;
- for (i = gr->gr_mem; *i; i++) {
- struct passwd pwbuf, *pw;
+ for (i = group->gr_mem; *i; i++) {
+ struct passwd *pw = NULL;
-#ifdef HAVE_GETPWNAM_R
- if (getpwnam_r(*i, &pwbuf, p_buf, (size_t) p_n, &pw) != 0 || !pw)
-#else
- if (!(pw = getpwnam(*i)))
-#endif
+ errno = 0;
+ if (!(pw = pa_getpwnam_malloc(*i)))
continue;
- if (pw->pw_uid == uid) {
+ if (pw->pw_uid == uid)
r = 1;
+
+ pa_getpwnam_free(pw);
+
+ if (r == 1)
break;
- }
}
finish:
- pa_xfree(g_buf);
- pa_xfree(p_buf);
+ pa_getgrnam_free(group);
return r;
}
@@ -1115,27 +1189,10 @@ finish:
/* Get the GID of a gfiven group, return (gid_t) -1 on failure. */
gid_t pa_get_gid_of_group(const char *name) {
gid_t ret = (gid_t) -1;
- char *g_buf;
- long g_n;
- struct group grbuf, *gr;
-
-#ifdef _SC_GETGR_R_SIZE_MAX
- g_n = sysconf(_SC_GETGR_R_SIZE_MAX);
-#else
- g_n = -1;
-#endif
- if (g_n <= 0)
- g_n = 512;
-
- g_buf = pa_xmalloc((size_t) g_n);
+ struct group *gr = NULL;
errno = 0;
-#ifdef HAVE_GETGRNAM_R
- if (getgrnam_r(name, &grbuf, g_buf, (size_t) g_n, &gr) != 0 || !gr)
-#else
- if (!(gr = getgrnam(name)))
-#endif
- {
+ if (!(gr = pa_getgrnam_malloc(name))) {
if (!errno)
errno = ENOENT;
goto finish;
@@ -1144,7 +1201,7 @@ gid_t pa_get_gid_of_group(const char *name) {
ret = gr->gr_gid;
finish:
- pa_xfree(g_buf);
+ pa_getgrnam_free(gr);
return ret;
}
@@ -1165,23 +1222,23 @@ int pa_check_in_group(gid_t g) {
#else /* HAVE_GRP_H */
int pa_own_uid_in_group(const char *name, gid_t *gid) {
- errno = ENOSUP;
+ errno = ENOTSUP;
return -1;
}
int pa_uid_in_group(uid_t uid, const char *name) {
- errno = ENOSUP;
+ errno = ENOTSUP;
return -1;
}
gid_t pa_get_gid_of_group(const char *name) {
- errno = ENOSUP;
+ errno = ENOTSUP;
return (gid_t) -1;
}
int pa_check_in_group(gid_t g) {
- errno = ENOSUP;
+ errno = ENOTSUP;
return -1;
}
@@ -1191,30 +1248,30 @@ int pa_check_in_group(gid_t g) {
(advisory on UNIX, mandatory on Windows) */
int pa_lock_fd(int fd, int b) {
#ifdef F_SETLKW
- struct flock flock;
+ struct flock f_lock;
/* Try a R/W lock first */
- flock.l_type = (short) (b ? F_WRLCK : F_UNLCK);
- flock.l_whence = SEEK_SET;
- flock.l_start = 0;
- flock.l_len = 0;
+ f_lock.l_type = (short) (b ? F_WRLCK : F_UNLCK);
+ f_lock.l_whence = SEEK_SET;
+ f_lock.l_start = 0;
+ f_lock.l_len = 0;
- if (fcntl(fd, F_SETLKW, &flock) >= 0)
+ if (fcntl(fd, F_SETLKW, &f_lock) >= 0)
return 0;
/* Perhaps the file descriptor qas opened for read only, than try again with a read lock. */
if (b && errno == EBADF) {
- flock.l_type = F_RDLCK;
- if (fcntl(fd, F_SETLKW, &flock) >= 0)
+ f_lock.l_type = F_RDLCK;
+ if (fcntl(fd, F_SETLKW, &f_lock) >= 0)
return 0;
}
- pa_log("%slock: %s", !b? "un" : "", pa_cstrerror(errno));
+ pa_log("%slock: %s", !b ? "un" : "", pa_cstrerror(errno));
#endif
#ifdef OS_IS_WIN32
- HANDLE h = (HANDLE)_get_osfhandle(fd);
+ HANDLE h = (HANDLE) _get_osfhandle(fd);
if (b && LockFile(h, 0, 0, 0xFFFFFFFF, 0xFFFFFFFF))
return 0;
@@ -1233,22 +1290,39 @@ int pa_lock_fd(int fd, int b) {
char* pa_strip_nl(char *s) {
pa_assert(s);
- s[strcspn(s, "\r\n")] = 0;
+ s[strcspn(s, NEWLINE)] = 0;
+ return s;
+}
+
+char *pa_strip(char *s) {
+ char *e, *l = NULL;
+
+ /* Drops trailing whitespace. Modifies the string in
+ * place. Returns pointer to first non-space character */
+
+ s += strspn(s, WHITESPACE);
+
+ for (e = s; *e; e++)
+ if (!strchr(WHITESPACE, *e))
+ l = e;
+
+ if (l)
+ *(l+1) = 0;
+ else
+ *s = 0;
+
return s;
}
/* Create a temporary lock file and lock it. */
int pa_lock_lockfile(const char *fn) {
- int fd = -1;
+ int fd;
pa_assert(fn);
for (;;) {
struct stat st;
- if ((fd = open(fn, O_CREAT|O_RDWR
-#ifdef O_NOCTTY
- |O_NOCTTY
-#endif
+ if ((fd = pa_open_cloexec(fn, O_CREAT|O_RDWR
#ifdef O_NOFOLLOW
|O_NOFOLLOW
#endif
@@ -1282,8 +1356,6 @@ int pa_lock_lockfile(const char *fn) {
fd = -1;
goto fail;
}
-
- fd = -1;
}
return fd;
@@ -1325,26 +1397,34 @@ int pa_unlock_lockfile(const char *fn, int fd) {
}
static char *get_pulse_home(void) {
- char h[PATH_MAX];
+ char *h;
struct stat st;
+ char *ret = NULL;
- if (!pa_get_home_dir(h, sizeof(h))) {
+ if (!(h = pa_get_home_dir_malloc())) {
pa_log_error("Failed to get home directory.");
return NULL;
}
if (stat(h, &st) < 0) {
pa_log_error("Failed to stat home directory %s: %s", h, pa_cstrerror(errno));
- return NULL;
+ goto finish;
}
+#ifdef HAVE_GETUID
if (st.st_uid != getuid()) {
pa_log_error("Home directory %s not ours.", h);
errno = EACCES;
- return NULL;
+ goto finish;
}
+#endif
- return pa_sprintf_malloc("%s" PA_PATH_SEP ".pulse", h);
+ ret = pa_sprintf_malloc("%s" PA_PATH_SEP ".pulse", h);
+
+finish:
+ pa_xfree(h);
+
+ return ret;
}
char *pa_get_state_dir(void) {
@@ -1360,7 +1440,7 @@ char *pa_get_state_dir(void) {
/* If PULSE_STATE_PATH and PULSE_RUNTIME_PATH point to the same
* dir then this will break. */
- if (pa_make_secure_dir(d, 0700U, (uid_t) -1, (gid_t) -1) < 0) {
+ if (pa_make_secure_dir(d, 0700U, (uid_t) -1, (gid_t) -1) < 0) {
pa_log_error("Failed to create secure directory: %s", pa_cstrerror(errno));
pa_xfree(d);
return NULL;
@@ -1369,25 +1449,60 @@ char *pa_get_state_dir(void) {
return d;
}
+char *pa_get_home_dir_malloc(void) {
+ char *homedir;
+ size_t allocated = 128;
+
+ for (;;) {
+ homedir = pa_xmalloc(allocated);
+
+ if (!pa_get_home_dir(homedir, allocated)) {
+ pa_xfree(homedir);
+ return NULL;
+ }
+
+ if (strlen(homedir) < allocated - 1)
+ break;
+
+ pa_xfree(homedir);
+ allocated *= 2;
+ }
+
+ return homedir;
+}
+
+char *pa_get_binary_name_malloc(void) {
+ char *t;
+ size_t allocated = 128;
+
+ for (;;) {
+ t = pa_xmalloc(allocated);
+
+ if (!pa_get_binary_name(t, allocated)) {
+ pa_xfree(t);
+ return NULL;
+ }
+
+ if (strlen(t) < allocated - 1)
+ break;
+
+ pa_xfree(t);
+ allocated *= 2;
+ }
+
+ return t;
+}
+
static char* make_random_dir(mode_t m) {
static const char table[] =
"abcdefghijklmnopqrstuvwxyz"
"ABCDEFGHIJKLMNOPQRSTUVWXYZ"
"0123456789";
- const char *tmpdir;
char *fn;
size_t pathlen;
- if (!(tmpdir = getenv("TMPDIR")))
- if (!(tmpdir = getenv("TMP")))
- if (!(tmpdir = getenv("TEMP")))
- tmpdir = getenv("TEMPDIR");
-
- if (!tmpdir || !pa_is_path_absolute(tmpdir))
- tmpdir = "/tmp";
-
- fn = pa_sprintf_malloc("%s/pulse-XXXXXXXXXXXX", tmpdir);
+ fn = pa_sprintf_malloc("%s" PA_PATH_SEP "pulse-XXXXXXXXXXXX", pa_get_temp_dir());
pathlen = strlen(fn);
for (;;) {
@@ -1400,7 +1515,11 @@ static char* make_random_dir(mode_t m) {
fn[i] = table[rand() % (sizeof(table)-1)];
u = umask((~m) & 0777);
+#ifndef OS_IS_WIN32
r = mkdir(fn, m);
+#else
+ r = mkdir(fn);
+#endif
saved_errno = errno;
umask(u);
@@ -1423,6 +1542,7 @@ static int make_random_dir_and_link(mode_t m, const char *k) {
if (!(p = make_random_dir(m)))
return -1;
+#ifdef HAVE_SYMLINK
if (symlink(p, k) < 0) {
int saved_errno = errno;
@@ -1435,6 +1555,10 @@ static int make_random_dir_and_link(mode_t m, const char *k) {
errno = saved_errno;
return -1;
}
+#else
+ pa_xfree(p);
+ return -1;
+#endif
pa_xfree(p);
return 0;
@@ -1442,7 +1566,6 @@ static int make_random_dir_and_link(mode_t m, const char *k) {
char *pa_get_runtime_dir(void) {
char *d, *k = NULL, *p = NULL, *t = NULL, *mid;
- struct stat st;
mode_t m;
/* The runtime directory shall contain dynamic data that needs NOT
@@ -1456,7 +1579,7 @@ char *pa_get_runtime_dir(void) {
if ((d = getenv("PULSE_RUNTIME_PATH"))) {
- if (pa_make_secure_dir(d, m, (uid_t) -1, (gid_t) -1) < 0) {
+ if (pa_make_secure_dir(d, m, (uid_t) -1, (gid_t) -1) < 0) {
pa_log_error("Failed to create secure directory: %s", pa_cstrerror(errno));
goto fail;
}
@@ -1467,7 +1590,7 @@ char *pa_get_runtime_dir(void) {
if (!(d = get_pulse_home()))
goto fail;
- if (pa_make_secure_dir(d, m, (uid_t) -1, (gid_t) -1) < 0) {
+ if (pa_make_secure_dir(d, m, (uid_t) -1, (gid_t) -1) < 0) {
pa_log_error("Failed to create secure directory: %s", pa_cstrerror(errno));
pa_xfree(d);
goto fail;
@@ -1478,7 +1601,7 @@ char *pa_get_runtime_dir(void) {
goto fail;
}
- k = pa_sprintf_malloc("%s" PA_PATH_SEP "%s:runtime", d, mid);
+ k = pa_sprintf_malloc("%s" PA_PATH_SEP "%s-runtime", d, mid);
pa_xfree(d);
pa_xfree(mid);
@@ -1493,6 +1616,7 @@ char *pa_get_runtime_dir(void) {
goto fail;
}
+#ifdef HAVE_SYMLINK
/* Hmm, so the runtime directory didn't exist yet, so let's
* create one in /tmp and symlink that to it */
@@ -1505,6 +1629,11 @@ char *pa_get_runtime_dir(void) {
goto fail;
}
+#else
+ /* No symlink possible, so let's just create the runtime directly */
+ if (!mkdir(k))
+ goto fail;
+#endif
return k;
}
@@ -1516,9 +1645,10 @@ char *pa_get_runtime_dir(void) {
goto fail;
}
- /* Hmm, so this symlink is still around, make sure nobody fools
- * us */
-
+ /* Hmm, so this symlink is still around, make sure nobody fools us */
+#ifdef HAVE_LSTAT
+{
+ struct stat st;
if (lstat(p, &st) < 0) {
if (errno != ENOENT) {
@@ -1538,6 +1668,8 @@ char *pa_get_runtime_dir(void) {
pa_log_info("Hmm, runtime path exists, but points to an invalid directory. Changing runtime directory.");
}
+}
+#endif
pa_xfree(p);
p = NULL;
@@ -1592,24 +1724,10 @@ fail:
* stored there.*/
FILE *pa_open_config_file(const char *global, const char *local, const char *env, char **result) {
const char *fn;
-#ifdef OS_IS_WIN32
- char buf[PATH_MAX];
-
- if (!getenv(PULSE_ROOTENV))
- pa_set_root(NULL);
-#endif
+ FILE *f;
if (env && (fn = getenv(env))) {
- FILE *f;
-
-#ifdef OS_IS_WIN32
- if (!ExpandEnvironmentStrings(fn, buf, PATH_MAX))
- /* FIXME: Needs to set errno! */
- return NULL;
- fn = buf;
-#endif
-
- if ((f = fopen(fn, "r"))) {
+ if ((f = pa_fopen_cloexec(fn, "r"))) {
if (result)
*result = pa_xstrdup(fn);
@@ -1623,26 +1741,17 @@ FILE *pa_open_config_file(const char *global, const char *local, const char *env
if (local) {
const char *e;
char *lfn;
- char h[PATH_MAX];
- FILE *f;
+ char *h;
if ((e = getenv("PULSE_CONFIG_PATH")))
fn = lfn = pa_sprintf_malloc("%s" PA_PATH_SEP "%s", e, local);
- else if (pa_get_home_dir(h, sizeof(h)))
+ else if ((h = pa_get_home_dir_malloc())) {
fn = lfn = pa_sprintf_malloc("%s" PA_PATH_SEP ".pulse" PA_PATH_SEP "%s", h, local);
- else
+ pa_xfree(h);
+ } else
return NULL;
-#ifdef OS_IS_WIN32
- if (!ExpandEnvironmentStrings(lfn, buf, PATH_MAX)) {
- /* FIXME: Needs to set errno! */
- pa_xfree(lfn);
- return NULL;
- }
- fn = buf;
-#endif
-
- if ((f = fopen(fn, "r"))) {
+ if ((f = pa_fopen_cloexec(fn, "r"))) {
if (result)
*result = pa_xstrdup(fn);
@@ -1660,22 +1769,26 @@ FILE *pa_open_config_file(const char *global, const char *local, const char *env
}
if (global) {
- FILE *f;
+ char *gfn;
#ifdef OS_IS_WIN32
- if (!ExpandEnvironmentStrings(global, buf, PATH_MAX))
- /* FIXME: Needs to set errno! */
- return NULL;
- global = buf;
+ if (strncmp(global, PA_DEFAULT_CONFIG_DIR, strlen(PA_DEFAULT_CONFIG_DIR)) == 0)
+ gfn = pa_sprintf_malloc("%s" PA_PATH_SEP "etc" PA_PATH_SEP "pulse%s",
+ pa_win32_get_toplevel(NULL),
+ global + strlen(PA_DEFAULT_CONFIG_DIR));
+ else
#endif
+ gfn = pa_xstrdup(global);
- if ((f = fopen(global, "r"))) {
-
+ if ((f = pa_fopen_cloexec(gfn, "r"))) {
if (result)
- *result = pa_xstrdup(global);
+ *result = gfn;
+ else
+ pa_xfree(gfn);
return f;
}
+ pa_xfree(gfn);
}
errno = ENOENT;
@@ -1684,22 +1797,8 @@ FILE *pa_open_config_file(const char *global, const char *local, const char *env
char *pa_find_config_file(const char *global, const char *local, const char *env) {
const char *fn;
-#ifdef OS_IS_WIN32
- char buf[PATH_MAX];
-
- if (!getenv(PULSE_ROOTENV))
- pa_set_root(NULL);
-#endif
if (env && (fn = getenv(env))) {
-
-#ifdef OS_IS_WIN32
- if (!ExpandEnvironmentStrings(fn, buf, PATH_MAX))
- /* FIXME: Needs to set errno! */
- return NULL;
- fn = buf;
-#endif
-
if (access(fn, R_OK) == 0)
return pa_xstrdup(fn);
@@ -1710,23 +1809,15 @@ char *pa_find_config_file(const char *global, const char *local, const char *env
if (local) {
const char *e;
char *lfn;
- char h[PATH_MAX];
+ char *h;
if ((e = getenv("PULSE_CONFIG_PATH")))
fn = lfn = pa_sprintf_malloc("%s" PA_PATH_SEP "%s", e, local);
- else if (pa_get_home_dir(h, sizeof(h)))
+ else if ((h = pa_get_home_dir_malloc())) {
fn = lfn = pa_sprintf_malloc("%s" PA_PATH_SEP ".pulse" PA_PATH_SEP "%s", h, local);
- else
- return NULL;
-
-#ifdef OS_IS_WIN32
- if (!ExpandEnvironmentStrings(lfn, buf, PATH_MAX)) {
- /* FIXME: Needs to set errno! */
- pa_xfree(lfn);
+ pa_xfree(h);
+ } else
return NULL;
- }
- fn = buf;
-#endif
if (access(fn, R_OK) == 0) {
char *r = pa_xstrdup(fn);
@@ -1744,15 +1835,20 @@ char *pa_find_config_file(const char *global, const char *local, const char *env
}
if (global) {
+ char *gfn;
+
#ifdef OS_IS_WIN32
- if (!ExpandEnvironmentStrings(global, buf, PATH_MAX))
- /* FIXME: Needs to set errno! */
- return NULL;
- global = buf;
+ if (strncmp(global, PA_DEFAULT_CONFIG_DIR, strlen(PA_DEFAULT_CONFIG_DIR)) == 0)
+ gfn = pa_sprintf_malloc("%s" PA_PATH_SEP "etc" PA_PATH_SEP "pulse%s",
+ pa_win32_get_toplevel(NULL),
+ global + strlen(PA_DEFAULT_CONFIG_DIR));
+ else
#endif
+ gfn = pa_xstrdup(global);
- if (access(global, R_OK) == 0)
- return pa_xstrdup(global);
+ if (access(gfn, R_OK) == 0)
+ return gfn;
+ pa_xfree(gfn);
}
errno = ENOENT;
@@ -1769,7 +1865,7 @@ char *pa_hexstr(const uint8_t* d, size_t dlength, char *s, size_t slength) {
pa_assert(s);
pa_assert(slength > 0);
- while (i < dlength && j+3 <= slength) {
+ while (j+2 < slength && i < dlength) {
s[j++] = hex[*d >> 4];
s[j++] = hex[*d & 0xF];
@@ -1882,17 +1978,17 @@ char *pa_make_path_absolute(const char *p) {
static char *get_path(const char *fn, pa_bool_t prependmid, pa_bool_t rt) {
char *rtp;
- if (pa_is_path_absolute(fn))
- return pa_xstrdup(fn);
-
rtp = rt ? pa_get_runtime_dir() : pa_get_state_dir();
- if (!rtp)
- return NULL;
-
if (fn) {
char *r;
+ if (pa_is_path_absolute(fn))
+ return pa_xstrdup(fn);
+
+ if (!rtp)
+ return NULL;
+
if (prependmid) {
char *mid;
@@ -1901,7 +1997,7 @@ static char *get_path(const char *fn, pa_bool_t prependmid, pa_bool_t rt) {
return NULL;
}
- r = pa_sprintf_malloc("%s" PA_PATH_SEP "%s:%s", rtp, mid, fn);
+ r = pa_sprintf_malloc("%s" PA_PATH_SEP "%s-%s", rtp, mid, fn);
pa_xfree(mid);
} else
r = pa_sprintf_malloc("%s" PA_PATH_SEP "%s", rtp, fn);
@@ -1922,20 +2018,13 @@ char *pa_state_path(const char *fn, pa_bool_t appendmid) {
/* Convert the string s to a signed integer in *ret_i */
int pa_atoi(const char *s, int32_t *ret_i) {
- char *x = NULL;
long l;
pa_assert(s);
pa_assert(ret_i);
- errno = 0;
- l = strtol(s, &x, 0);
-
- if (!x || *x || errno) {
- if (!errno)
- errno = EINVAL;
+ if (pa_atol(s, &l) < 0)
return -1;
- }
if ((int32_t) l != l) {
errno = ERANGE;
@@ -1974,6 +2063,28 @@ int pa_atou(const char *s, uint32_t *ret_u) {
return 0;
}
+/* Convert the string s to a signed long integer in *ret_l. */
+int pa_atol(const char *s, long *ret_l) {
+ char *x = NULL;
+ long l;
+
+ pa_assert(s);
+ pa_assert(ret_l);
+
+ errno = 0;
+ l = strtol(s, &x, 0);
+
+ if (!x || *x || errno) {
+ if (!errno)
+ errno = EINVAL;
+ return -1;
+ }
+
+ *ret_l = l;
+
+ return 0;
+}
+
#ifdef HAVE_STRTOF_L
static locale_t c_locale = NULL;
@@ -2097,7 +2208,7 @@ void *pa_will_need(const void *p, size_t l) {
#endif
const void *a;
size_t size;
- int r;
+ int r = ENOTSUP;
size_t bs;
pa_assert(p);
@@ -2175,6 +2286,7 @@ void pa_close_pipe(int fds[2]) {
}
char *pa_readlink(const char *p) {
+#ifdef HAVE_READLINK
size_t l = 100;
for (;;) {
@@ -2196,6 +2308,9 @@ char *pa_readlink(const char *p) {
pa_xfree(c);
l *= 2;
}
+#else
+ return NULL;
+#endif
}
int pa_close_all(int except_fd, ...) {
@@ -2228,18 +2343,18 @@ int pa_close_all(int except_fd, ...) {
va_end(ap);
r = pa_close_allv(p);
- free(p);
+ pa_xfree(p);
return r;
}
int pa_close_allv(const int except_fds[]) {
+#ifndef OS_IS_WIN32
struct rlimit rl;
int maxfd, fd;
- int saved_errno;
#ifdef __linux__
-
+ int saved_errno;
DIR *d;
if ((d = opendir("/proc/self/fd"))) {
@@ -2324,6 +2439,7 @@ int pa_close_allv(const int except_fds[]) {
if (pa_close(fd) < 0 && errno != EBADF)
return -1;
}
+#endif /* !OS_IS_WIN32 */
return 0;
}
@@ -2364,6 +2480,7 @@ int pa_unblock_sigs(int except, ...) {
}
int pa_unblock_sigsv(const int except[]) {
+#ifndef OS_IS_WIN32
int i;
sigset_t ss;
@@ -2375,6 +2492,9 @@ int pa_unblock_sigsv(const int except[]) {
return -1;
return sigprocmask(SIG_SETMASK, &ss, NULL);
+#else
+ return 0;
+#endif
}
int pa_reset_sigs(int except, ...) {
@@ -2400,7 +2520,7 @@ int pa_reset_sigs(int except, ...) {
p[i++] = except;
while ((sig = va_arg(ap, int)) >= 0)
- sig = p[i++];
+ p[i++] = sig;
}
p[i] = -1;
@@ -2413,6 +2533,7 @@ int pa_reset_sigs(int except, ...) {
}
int pa_reset_sigsv(const int except[]) {
+#ifndef OS_IS_WIN32
int sig;
for (sig = 1; sig < NSIG; sig++) {
@@ -2449,6 +2570,7 @@ int pa_reset_sigsv(const int except[]) {
return -1;
}
}
+#endif
return 0;
}
@@ -2457,7 +2579,44 @@ void pa_set_env(const char *key, const char *value) {
pa_assert(key);
pa_assert(value);
- putenv(pa_sprintf_malloc("%s=%s", key, value));
+ /* This is not thread-safe */
+
+#ifdef OS_IS_WIN32
+ SetEnvironmentVariable(key, value);
+#else
+ setenv(key, value, 1);
+#endif
+}
+
+void pa_set_env_and_record(const char *key, const char *value) {
+ pa_assert(key);
+ pa_assert(value);
+
+ /* This is not thread-safe */
+
+ pa_set_env(key, value);
+ recorded_env = pa_strlist_prepend(recorded_env, key);
+}
+
+void pa_unset_env_recorded(void) {
+
+ /* This is not thread-safe */
+
+ for (;;) {
+ char *s;
+
+ recorded_env = pa_strlist_pop(recorded_env, &s);
+
+ if (!s)
+ break;
+
+#ifdef OS_IS_WIN32
+ SetEnvironmentVariable(s, NULL);
+#else
+ unsetenv(s);
+#endif
+ pa_xfree(s);
+ }
}
pa_bool_t pa_in_system_mode(void) {
@@ -2539,7 +2698,7 @@ char *pa_machine_id(void) {
* since it fits perfectly our needs and is not as volatile as the
* hostname which might be set from dhcp. */
- if ((f = fopen(PA_MACHINE_ID, "r"))) {
+ if ((f = pa_fopen_cloexec(PA_MACHINE_ID, "r"))) {
char ln[34] = "", *r;
r = fgets(ln, sizeof(ln)-1, f);
@@ -2554,9 +2713,13 @@ char *pa_machine_id(void) {
if ((h = pa_get_host_name_malloc()))
return h;
+#ifndef OS_IS_WIN32
/* If no hostname was set we use the POSIX hostid. It's usually
* the IPv4 address. Might not be that stable. */
return pa_sprintf_malloc("%08lx", (unsigned long) gethostid);
+#else
+ return NULL;
+#endif
}
char *pa_session_id(void) {
@@ -2569,11 +2732,22 @@ char *pa_session_id(void) {
}
char *pa_uname_string(void) {
+#ifdef HAVE_UNAME
struct utsname u;
pa_assert_se(uname(&u) >= 0);
return pa_sprintf_malloc("%s %s %s %s", u.sysname, u.machine, u.release, u.version);
+#endif
+#ifdef OS_IS_WIN32
+ OSVERSIONINFO i;
+
+ pa_zero(i);
+ i.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
+ pa_assert_se(GetVersionEx(&i));
+
+ return pa_sprintf_malloc("Windows %d.%d (%d) %s", i.dwMajorVersion, i.dwMinorVersion, i.dwBuildNumber, i.szCSDVersion);
+#endif
}
#ifdef HAVE_VALGRIND_MEMCHECK_H
@@ -2654,6 +2828,28 @@ char *pa_replace(const char*s, const char*a, const char *b) {
return pa_strbuf_tostring_free(sb);
}
+char *pa_escape(const char *p, const char *chars) {
+ const char *s;
+ const char *c;
+ pa_strbuf *buf = pa_strbuf_new();
+
+ for (s = p; *s; ++s) {
+ if (*s == '\\')
+ pa_strbuf_putc(buf, '\\');
+ else if (chars) {
+ for (c = chars; *c; ++c) {
+ if (*s == *c) {
+ pa_strbuf_putc(buf, '\\');
+ break;
+ }
+ }
+ }
+ pa_strbuf_putc(buf, *s);
+ }
+
+ return pa_strbuf_tostring_free(buf);
+}
+
char *pa_unescape(char *p) {
char *s, *d;
pa_bool_t escaped = FALSE;
@@ -2700,10 +2896,17 @@ char *pa_realpath(const char *path) {
char *path_buf;
path_buf = pa_xmalloc(PATH_MAX);
+#if defined(OS_IS_WIN32)
+ if (!(t = _fullpath(path_buf, path, _MAX_PATH))) {
+ pa_xfree(path_buf);
+ return NULL;
+ }
+#else
if (!(t = realpath(path, path_buf))) {
pa_xfree(path_buf);
return NULL;
}
+#endif
}
#else
#error "It's not clear whether this system supports realpath(..., NULL) like GNU libc does. If it doesn't we need a private version of realpath() here."
@@ -2732,3 +2935,332 @@ void pa_disable_sigpipe(void) {
}
#endif
}
+
+void pa_xfreev(void**a) {
+ void **p;
+
+ if (!a)
+ return;
+
+ for (p = a; *p; p++)
+ pa_xfree(*p);
+
+ pa_xfree(a);
+}
+
+char **pa_split_spaces_strv(const char *s) {
+ char **t, *e;
+ unsigned i = 0, n = 8;
+ const char *state = NULL;
+
+ t = pa_xnew(char*, n);
+ while ((e = pa_split_spaces(s, &state))) {
+ t[i++] = e;
+
+ if (i >= n) {
+ n *= 2;
+ t = pa_xrenew(char*, t, n);
+ }
+ }
+
+ if (i <= 0) {
+ pa_xfree(t);
+ return NULL;
+ }
+
+ t[i] = NULL;
+ return t;
+}
+
+char* pa_maybe_prefix_path(const char *path, const char *prefix) {
+ pa_assert(path);
+
+ if (pa_is_path_absolute(path))
+ return pa_xstrdup(path);
+
+ return pa_sprintf_malloc("%s" PA_PATH_SEP "%s", prefix, path);
+}
+
+size_t pa_pipe_buf(int fd) {
+
+#ifdef _PC_PIPE_BUF
+ long n;
+
+ if ((n = fpathconf(fd, _PC_PIPE_BUF)) >= 0)
+ return (size_t) n;
+#endif
+
+#ifdef PIPE_BUF
+ return PIPE_BUF;
+#else
+ return 4096;
+#endif
+}
+
+void pa_reset_personality(void) {
+
+#ifdef __linux__
+ if (personality(PER_LINUX) < 0)
+ pa_log_warn("Uh, personality() failed: %s", pa_cstrerror(errno));
+#endif
+
+}
+
+#if defined(__linux__) && !defined(__OPTIMIZE__)
+
+pa_bool_t pa_run_from_build_tree(void) {
+ char *rp;
+ pa_bool_t b = FALSE;
+
+ if ((rp = pa_readlink("/proc/self/exe"))) {
+ b = pa_startswith(rp, PA_BUILDDIR);
+ pa_xfree(rp);
+ }
+
+ return b;
+}
+
+#endif
+
+const char *pa_get_temp_dir(void) {
+ const char *t;
+
+ if ((t = getenv("TMPDIR")) &&
+ pa_is_path_absolute(t))
+ return t;
+
+ if ((t = getenv("TMP")) &&
+ pa_is_path_absolute(t))
+ return t;
+
+ if ((t = getenv("TEMP")) &&
+ pa_is_path_absolute(t))
+ return t;
+
+ if ((t = getenv("TEMPDIR")) &&
+ pa_is_path_absolute(t))
+ return t;
+
+ return "/tmp";
+}
+
+int pa_open_cloexec(const char *fn, int flags, mode_t mode) {
+ int fd;
+
+#ifdef O_NOCTTY
+ flags |= O_NOCTTY;
+#endif
+
+#ifdef O_CLOEXEC
+ if ((fd = open(fn, flags|O_CLOEXEC, mode)) >= 0)
+ goto finish;
+
+ if (errno != EINVAL)
+ return fd;
+#endif
+
+ if ((fd = open(fn, flags, mode)) < 0)
+ return fd;
+
+finish:
+ /* Some implementations might simply ignore O_CLOEXEC if it is not
+ * understood, make sure FD_CLOEXEC is enabled anyway */
+
+ pa_make_fd_cloexec(fd);
+ return fd;
+}
+
+int pa_socket_cloexec(int domain, int type, int protocol) {
+ int fd;
+
+#ifdef SOCK_CLOEXEC
+ if ((fd = socket(domain, type | SOCK_CLOEXEC, protocol)) >= 0)
+ goto finish;
+
+ if (errno != EINVAL)
+ return fd;
+#endif
+
+ if ((fd = socket(domain, type, protocol)) < 0)
+ return fd;
+
+finish:
+ /* Some implementations might simply ignore SOCK_CLOEXEC if it is
+ * not understood, make sure FD_CLOEXEC is enabled anyway */
+
+ pa_make_fd_cloexec(fd);
+ return fd;
+}
+
+int pa_pipe_cloexec(int pipefd[2]) {
+ int r;
+
+#ifdef HAVE_PIPE2
+ if ((r = pipe2(pipefd, O_CLOEXEC)) >= 0)
+ goto finish;
+
+ if (errno != EINVAL && errno != ENOSYS)
+ return r;
+
+#endif
+
+ if ((r = pipe(pipefd)) < 0)
+ return r;
+
+finish:
+ pa_make_fd_cloexec(pipefd[0]);
+ pa_make_fd_cloexec(pipefd[1]);
+
+ return 0;
+}
+
+int pa_accept_cloexec(int sockfd, struct sockaddr *addr, socklen_t *addrlen) {
+ int fd;
+
+#ifdef HAVE_ACCEPT4
+ if ((fd = accept4(sockfd, addr, addrlen, SOCK_CLOEXEC)) >= 0)
+ goto finish;
+
+ if (errno != EINVAL && errno != ENOSYS)
+ return fd;
+
+#endif
+
+ if ((fd = accept(sockfd, addr, addrlen)) < 0)
+ return fd;
+
+finish:
+ pa_make_fd_cloexec(fd);
+ return fd;
+}
+
+FILE* pa_fopen_cloexec(const char *path, const char *mode) {
+ FILE *f;
+ char *m;
+
+ m = pa_sprintf_malloc("%se", mode);
+
+ errno = 0;
+ if ((f = fopen(path, m))) {
+ pa_xfree(m);
+ goto finish;
+ }
+
+ pa_xfree(m);
+
+ if (errno != EINVAL)
+ return NULL;
+
+ if (!(f = fopen(path, mode)))
+ return NULL;
+
+finish:
+ pa_make_fd_cloexec(fileno(f));
+ return f;
+}
+
+void pa_nullify_stdfds(void) {
+
+#ifndef OS_IS_WIN32
+ pa_close(STDIN_FILENO);
+ pa_close(STDOUT_FILENO);
+ pa_close(STDERR_FILENO);
+
+ pa_assert_se(open("/dev/null", O_RDONLY) == STDIN_FILENO);
+ pa_assert_se(open("/dev/null", O_WRONLY) == STDOUT_FILENO);
+ pa_assert_se(open("/dev/null", O_WRONLY) == STDERR_FILENO);
+#else
+ FreeConsole();
+#endif
+
+}
+
+char *pa_read_line_from_file(const char *fn) {
+ FILE *f;
+ char ln[256] = "", *r;
+
+ if (!(f = pa_fopen_cloexec(fn, "r")))
+ return NULL;
+
+ r = fgets(ln, sizeof(ln)-1, f);
+ fclose(f);
+
+ if (!r) {
+ errno = EIO;
+ return NULL;
+ }
+
+ pa_strip_nl(ln);
+ return pa_xstrdup(ln);
+}
+
+pa_bool_t pa_running_in_vm(void) {
+
+#if defined(__i386__) || defined(__x86_64__)
+
+ /* Both CPUID and DMI are x86 specific interfaces... */
+
+ uint32_t eax = 0x40000000;
+ union {
+ uint32_t sig32[3];
+ char text[13];
+ } sig;
+
+#ifdef __linux__
+ const char *const dmi_vendors[] = {
+ "/sys/class/dmi/id/sys_vendor",
+ "/sys/class/dmi/id/board_vendor",
+ "/sys/class/dmi/id/bios_vendor"
+ };
+
+ unsigned i;
+
+ for (i = 0; i < PA_ELEMENTSOF(dmi_vendors); i++) {
+ char *s;
+
+ if ((s = pa_read_line_from_file(dmi_vendors[i]))) {
+
+ if (pa_startswith(s, "QEMU") ||
+ /* http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1009458 */
+ pa_startswith(s, "VMware") ||
+ pa_startswith(s, "VMW") ||
+ pa_startswith(s, "Microsoft Corporation") ||
+ pa_startswith(s, "innotek GmbH") ||
+ pa_startswith(s, "Xen")) {
+
+ pa_xfree(s);
+ return TRUE;
+ }
+
+ pa_xfree(s);
+ }
+ }
+
+#endif
+
+ /* http://lwn.net/Articles/301888/ */
+ pa_zero(sig);
+
+ __asm__ __volatile__ (
+ /* ebx/rbx is being used for PIC! */
+ " push %%"PA_REG_b" \n\t"
+ " cpuid \n\t"
+ " mov %%ebx, %1 \n\t"
+ " pop %%"PA_REG_b" \n\t"
+
+ : "=a" (eax), "=r" (sig.sig32[0]), "=c" (sig.sig32[1]), "=d" (sig.sig32[2])
+ : "0" (eax)
+ );
+
+ if (pa_streq(sig.text, "XenVMMXenVMM") ||
+ pa_streq(sig.text, "KVMKVMKVM") ||
+ /* http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1009458 */
+ pa_streq(sig.text, "VMwareVMware") ||
+ /* http://msdn.microsoft.com/en-us/library/bb969719.aspx */
+ pa_streq(sig.text, "Microsoft Hv"))
+ return TRUE;
+
+#endif
+
+ return FALSE;
+}
diff --git a/src/pulsecore/core-util.h b/src/pulsecore/core-util.h
index d073b750..0b34a183 100644
--- a/src/pulsecore/core-util.h
+++ b/src/pulsecore/core-util.h
@@ -35,6 +35,7 @@
#include <pulse/gccmacro.h>
#include <pulsecore/macro.h>
+#include <pulsecore/socket.h>
#ifndef PACKAGE
#error "Please include config.h before including this file!"
@@ -80,9 +81,6 @@ int pa_make_realtime(int rtprio);
int pa_raise_priority(int nice_level);
void pa_reset_priority(void);
-pa_bool_t pa_can_realtime(void);
-pa_bool_t pa_can_high_priority(void);
-
int pa_parse_boolean(const char *s) PA_GCC_PURE;
static inline const char *pa_yes_no(pa_bool_t b) {
@@ -105,6 +103,7 @@ char *pa_split(const char *c, const char*delimiters, const char **state);
char *pa_split_spaces(const char *c, const char **state);
char *pa_strip_nl(char *s);
+char *pa_strip(char *s);
const char *pa_sig2str(int sig) PA_GCC_PURE;
@@ -129,11 +128,14 @@ char* pa_find_config_file(const char *global, const char *local, const char *env
char *pa_get_runtime_dir(void);
char *pa_get_state_dir(void);
+char *pa_get_home_dir_malloc(void);
+char *pa_get_binary_name_malloc(void);
char *pa_runtime_path(const char *fn);
char *pa_state_path(const char *fn, pa_bool_t prepend_machine_id);
int pa_atoi(const char *s, int32_t *ret_i);
int pa_atou(const char *s, uint32_t *ret_u);
+int pa_atol(const char *s, long *ret_l);
int pa_atod(const char *s, double *ret_d);
size_t pa_snprintf(char *str, size_t size, const char *format, ...);
@@ -196,6 +198,8 @@ int pa_reset_sigs(int except, ...);
int pa_reset_sigsv(const int except[]);
void pa_set_env(const char *key, const char *value);
+void pa_set_env_and_record(const char *key, const char *value);
+void pa_unset_env_recorded(void);
pa_bool_t pa_in_system_mode(void);
@@ -223,10 +227,58 @@ unsigned pa_ncpus(void);
char *pa_replace(const char*s, const char*a, const char *b);
+/* Escapes p by inserting backslashes in front of backslashes. chars is a
+ * regular (ie. NULL-terminated) string containing additional characters that
+ * should be escaped. chars can be NULL. The caller has to free the returned
+ * string. */
+char *pa_escape(const char *p, const char *chars);
+
+/* Does regular backslash unescaping. Returns the argument p. */
char *pa_unescape(char *p);
char *pa_realpath(const char *path);
void pa_disable_sigpipe(void);
+void pa_xfreev(void**a);
+
+static inline void pa_xstrfreev(char **a) {
+ pa_xfreev((void**) a);
+}
+
+char **pa_split_spaces_strv(const char *s);
+
+char* pa_maybe_prefix_path(const char *path, const char *prefix);
+
+/* Returns size of the specified pipe or 4096 on failure */
+size_t pa_pipe_buf(int fd);
+
+void pa_reset_personality(void);
+
+/* We abuse __OPTIMIZE__ as a check whether we are a debug build
+ * or not. If we are and are run from the build tree then we
+ * override the search path to point to our build tree */
+#if defined(__linux__) && !defined(__OPTIMIZE__)
+pa_bool_t pa_run_from_build_tree(void);
+#else
+static inline pa_bool_t pa_run_from_build_tree(void) {return FALSE;}
+#endif
+
+const char *pa_get_temp_dir(void);
+
+int pa_open_cloexec(const char *fn, int flags, mode_t mode);
+int pa_socket_cloexec(int domain, int type, int protocol);
+int pa_pipe_cloexec(int pipefd[2]);
+int pa_accept_cloexec(int sockfd, struct sockaddr *addr, socklen_t *addrlen);
+FILE* pa_fopen_cloexec(const char *path, const char *mode);
+
+void pa_nullify_stdfds(void);
+
+char *pa_read_line_from_file(const char *fn);
+pa_bool_t pa_running_in_vm(void);
+
+#ifdef OS_IS_WIN32
+char *pa_win32_get_toplevel(HANDLE handle);
+#endif
+
#endif
diff --git a/src/pulsecore/core.c b/src/pulsecore/core.c
index 06573f17..2a68fdf4 100644
--- a/src/pulsecore/core.c
+++ b/src/pulsecore/core.c
@@ -28,24 +28,22 @@
#include <stdio.h>
#include <signal.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
#include <pulsecore/module.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/source.h>
-#include <pulsecore/namereg.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/core-scache.h>
#include <pulsecore/core-subscribe.h>
-#include <pulsecore/shared.h>
#include <pulsecore/random.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include "core.h"
-static PA_DEFINE_CHECK_TYPE(pa_core, pa_msgobject);
+PA_DEFINE_PUBLIC_CLASS(pa_core, pa_msgobject);
static int core_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offset, pa_memchunk *chunk) {
pa_core *c = PA_CORE(o);
@@ -115,6 +113,9 @@ pa_core* pa_core_new(pa_mainloop_api *m, pa_bool_t shared, size_t shm_size) {
c->default_n_fragments = 4;
c->default_fragment_size_msec = 25;
+ c->sync_volume_safety_margin_usec = 8000;
+ c->sync_volume_extra_delay_usec = 0;
+
c->module_defer_unload_event = NULL;
c->scache_auto_unload_event = NULL;
@@ -139,6 +140,7 @@ pa_core* pa_core_new(pa_mainloop_api *m, pa_bool_t shared, size_t shm_size) {
c->realtime_priority = 5;
c->disable_remixing = FALSE;
c->disable_lfe_remixing = FALSE;
+ c->sync_volume = TRUE;
c->resample_method = PA_RESAMPLER_SPEEX_FLOAT_BASE + 3;
for (j = 0; j < PA_CORE_HOOK_MAX; j++)
@@ -214,7 +216,7 @@ static void core_free(pa_object *o) {
pa_xfree(c);
}
-static void exit_callback(pa_mainloop_api*m, pa_time_event *e, const struct timeval *tv, void *userdata) {
+static void exit_callback(pa_mainloop_api *m, pa_time_event *e, const struct timeval *t, void *userdata) {
pa_core *c = userdata;
pa_assert(c->exit_event == e);
@@ -229,11 +231,7 @@ void pa_core_check_idle(pa_core *c) {
c->exit_idle_time >= 0 &&
pa_idxset_size(c->clients) == 0) {
- struct timeval tv;
- pa_gettimeofday(&tv);
- tv.tv_sec+= c->exit_idle_time;
-
- c->exit_event = c->mainloop->time_new(c->mainloop, &tv, exit_callback, c);
+ c->exit_event = pa_core_rttime_new(c, pa_rtclock_now() + c->exit_idle_time * PA_USEC_PER_SEC, exit_callback, c);
} else if (c->exit_event && pa_idxset_size(c->clients) > 0) {
c->mainloop->time_free(c->exit_event);
@@ -261,3 +259,21 @@ void pa_core_maybe_vacuum(pa_core *c) {
pa_log_debug("Hmm, no streams around, trying to vacuum.");
pa_mempool_vacuum(c->mempool);
}
+
+pa_time_event* pa_core_rttime_new(pa_core *c, pa_usec_t usec, pa_time_event_cb_t cb, void *userdata) {
+ struct timeval tv;
+
+ pa_assert(c);
+ pa_assert(c->mainloop);
+
+ return c->mainloop->time_new(c->mainloop, pa_timeval_rtstore(&tv, usec, TRUE), cb, userdata);
+}
+
+void pa_core_rttime_restart(pa_core *c, pa_time_event *e, pa_usec_t usec) {
+ struct timeval tv;
+
+ pa_assert(c);
+ pa_assert(c->mainloop);
+
+ c->mainloop->time_restart(e, pa_timeval_rtstore(&tv, usec, TRUE));
+}
diff --git a/src/pulsecore/core.h b/src/pulsecore/core.h
index c6794445..61c86903 100644
--- a/src/pulsecore/core.h
+++ b/src/pulsecore/core.h
@@ -24,14 +24,25 @@
#include <pulse/mainloop-api.h>
#include <pulse/sample.h>
+#include <pulsecore/cpu.h>
typedef struct pa_core pa_core;
+/* This is a bitmask that encodes the cause why a sink/source is
+ * suspended. */
+typedef enum pa_suspend_cause {
+ PA_SUSPEND_USER = 1, /* Exposed to the user via some protocol */
+ PA_SUSPEND_APPLICATION = 2, /* Used by the device reservation logic */
+ PA_SUSPEND_IDLE = 4, /* Used by module-suspend-on-idle */
+ PA_SUSPEND_SESSION = 8, /* Used by module-hal for mark inactive sessions */
+ PA_SUSPEND_PASSTHROUGH = 16, /* Used to suspend monitor sources when the sink is in passthrough mode */
+ PA_SUSPEND_ALL = 0xFFFF /* Magic cause that can be used to resume forcibly */
+} pa_suspend_cause_t;
+
#include <pulsecore/idxset.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/memblock.h>
#include <pulsecore/resampler.h>
-#include <pulsecore/queue.h>
#include <pulsecore/llist.h>
#include <pulsecore/hook-list.h>
#include <pulsecore/asyncmsgq.h>
@@ -39,9 +50,15 @@ typedef struct pa_core pa_core;
#include <pulsecore/sink.h>
#include <pulsecore/source.h>
#include <pulsecore/core-subscribe.h>
-#include <pulsecore/sink-input.h>
#include <pulsecore/msgobject.h>
+typedef enum pa_server_type {
+ PA_SERVER_TYPE_UNSET,
+ PA_SERVER_TYPE_USER,
+ PA_SERVER_TYPE_SYSTEM,
+ PA_SERVER_TYPE_NONE
+} pa_server_type_t;
+
typedef enum pa_core_state {
PA_CORE_STARTUP,
PA_CORE_RUNNING,
@@ -56,6 +73,7 @@ typedef enum pa_core_hook {
PA_CORE_HOOK_SINK_UNLINK_POST,
PA_CORE_HOOK_SINK_STATE_CHANGED,
PA_CORE_HOOK_SINK_PROPLIST_CHANGED,
+ PA_CORE_HOOK_SINK_PORT_CHANGED,
PA_CORE_HOOK_SOURCE_NEW,
PA_CORE_HOOK_SOURCE_FIXATE,
PA_CORE_HOOK_SOURCE_PUT,
@@ -63,6 +81,7 @@ typedef enum pa_core_hook {
PA_CORE_HOOK_SOURCE_UNLINK_POST,
PA_CORE_HOOK_SOURCE_STATE_CHANGED,
PA_CORE_HOOK_SOURCE_PROPLIST_CHANGED,
+ PA_CORE_HOOK_SOURCE_PORT_CHANGED,
PA_CORE_HOOK_SINK_INPUT_NEW,
PA_CORE_HOOK_SINK_INPUT_FIXATE,
PA_CORE_HOOK_SINK_INPUT_PUT,
@@ -73,7 +92,6 @@ typedef enum pa_core_hook {
PA_CORE_HOOK_SINK_INPUT_MOVE_FAIL,
PA_CORE_HOOK_SINK_INPUT_STATE_CHANGED,
PA_CORE_HOOK_SINK_INPUT_PROPLIST_CHANGED,
- PA_CORE_HOOK_SINK_INPUT_SET_VOLUME,
PA_CORE_HOOK_SINK_INPUT_SEND_EVENT,
PA_CORE_HOOK_SOURCE_OUTPUT_NEW,
PA_CORE_HOOK_SOURCE_OUTPUT_FIXATE,
@@ -94,6 +112,7 @@ typedef enum pa_core_hook {
PA_CORE_HOOK_CARD_NEW,
PA_CORE_HOOK_CARD_PUT,
PA_CORE_HOOK_CARD_UNLINK,
+ PA_CORE_HOOK_CARD_PROFILE_CHANGED,
PA_CORE_HOOK_MAX
} pa_core_hook_t;
@@ -125,6 +144,8 @@ struct pa_core {
pa_channel_map default_channel_map;
pa_sample_spec default_sample_spec;
unsigned default_n_fragments, default_fragment_size_msec;
+ unsigned sync_volume_safety_margin_usec;
+ int sync_volume_extra_delay_usec;
pa_defer_event *module_defer_unload_event;
@@ -148,15 +169,19 @@ struct pa_core {
pa_bool_t realtime_scheduling:1;
pa_bool_t disable_remixing:1;
pa_bool_t disable_lfe_remixing:1;
+ pa_bool_t sync_volume:1;
pa_resample_method_t resample_method;
int realtime_priority;
+ pa_server_type_t server_type;
+ pa_cpu_info cpu_info;
+
/* hooks */
pa_hook hooks[PA_CORE_HOOK_MAX];
};
-PA_DECLARE_CLASS(pa_core);
+PA_DECLARE_PUBLIC_CLASS(pa_core);
#define PA_CORE(o) pa_core_cast(o)
enum {
@@ -173,4 +198,8 @@ int pa_core_exit(pa_core *c, pa_bool_t force, int retval);
void pa_core_maybe_vacuum(pa_core *c);
+/* wrapper for c->mainloop->time_*() RT time events */
+pa_time_event* pa_core_rttime_new(pa_core *c, pa_usec_t usec, pa_time_event_cb_t cb, void *userdata);
+void pa_core_rttime_restart(pa_core *c, pa_time_event *e, pa_usec_t usec);
+
#endif
diff --git a/src/pulsecore/cpu-arm.c b/src/pulsecore/cpu-arm.c
new file mode 100644
index 00000000..078fb04f
--- /dev/null
+++ b/src/pulsecore/cpu-arm.c
@@ -0,0 +1,147 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdint.h>
+#include <sys/types.h>
+#include <fcntl.h>
+
+#include <pulse/xmalloc.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/log.h>
+
+#include "cpu-arm.h"
+
+#if defined (__arm__) && defined (__linux__)
+
+#define MAX_BUFFER 4096
+static char *
+get_cpuinfo_line(char *cpuinfo, const char *tag) {
+ char *line, *end, *colon;
+
+ if (!(line = strstr(cpuinfo, tag)))
+ return NULL;
+
+ if (!(end = strchr(line, '\n')))
+ return NULL;
+
+ if (!(colon = strchr(line, ':')))
+ return NULL;
+
+ if (++colon >= end)
+ return NULL;
+
+ return pa_xstrndup(colon, end - colon);
+}
+
+static char *get_cpuinfo(void) {
+ char *cpuinfo;
+ int n, fd;
+
+ cpuinfo = pa_xmalloc(MAX_BUFFER);
+
+ if ((fd = pa_open_cloexec("/proc/cpuinfo", O_RDONLY, 0)) < 0) {
+ pa_xfree(cpuinfo);
+ return NULL;
+ }
+
+ if ((n = pa_read(fd, cpuinfo, MAX_BUFFER-1, NULL)) < 0) {
+ pa_xfree(cpuinfo);
+ pa_close(fd);
+ return NULL;
+ }
+ cpuinfo[n] = 0;
+ pa_close(fd);
+
+ return cpuinfo;
+}
+#endif /* defined (__arm__) && defined (__linux__) */
+
+pa_bool_t pa_cpu_init_arm(pa_cpu_arm_flag_t *flags) {
+#if defined (__arm__)
+#if defined (__linux__)
+ char *cpuinfo, *line;
+ int arch;
+
+ /* We need to read the CPU flags from /proc/cpuinfo because there is no user
+ * space support to get the CPU features. This only works on linux AFAIK. */
+ if (!(cpuinfo = get_cpuinfo())) {
+ pa_log("Can't read cpuinfo");
+ return;
+ }
+
+ *flags = 0;
+
+ /* get the CPU architecture */
+ if ((line = get_cpuinfo_line(cpuinfo, "CPU architecture"))) {
+ arch = strtoul(line, NULL, 0);
+ if (arch >= 6)
+ *flags |= PA_CPU_ARM_V6;
+ if (arch >= 7)
+ *flags |= PA_CPU_ARM_V7;
+
+ pa_xfree(line);
+ }
+ /* get the CPU features */
+ if ((line = get_cpuinfo_line(cpuinfo, "Features"))) {
+ const char *state = NULL;
+ char *current;
+
+ while ((current = pa_split_spaces(line, &state))) {
+ if (!strcmp(current, "vfp"))
+ *flags |= PA_CPU_ARM_VFP;
+ else if (!strcmp(current, "edsp"))
+ *flags |= PA_CPU_ARM_EDSP;
+ else if (!strcmp(current, "neon"))
+ *flags |= PA_CPU_ARM_NEON;
+ else if (!strcmp(current, "vfpv3"))
+ *flags |= PA_CPU_ARM_VFPV3;
+
+ pa_xfree(current);
+ }
+ }
+ pa_xfree(cpuinfo);
+
+ pa_log_info("CPU flags: %s%s%s%s%s%s",
+ (*flags & PA_CPU_ARM_V6) ? "V6 " : "",
+ (*flags & PA_CPU_ARM_V7) ? "V7 " : "",
+ (*flags & PA_CPU_ARM_VFP) ? "VFP " : "",
+ (*flags & PA_CPU_ARM_EDSP) ? "EDSP " : "",
+ (*flags & PA_CPU_ARM_NEON) ? "NEON " : "",
+ (*flags & PA_CPU_ARM_VFPV3) ? "VFPV3 " : "");
+
+ if (*flags & PA_CPU_ARM_V6)
+ pa_volume_func_init_arm(*flags);
+
+ return TRUE;
+
+#else /* defined (__linux__) */
+ pa_log ("ARM cpu features not yet supported on this OS");
+#endif /* defined (__linux__) */
+
+#else /* defined (__arm__) */
+ return FALSE;
+#endif /* defined (__arm__) */
+}
diff --git a/src/pulsecore/cpu-arm.h b/src/pulsecore/cpu-arm.h
new file mode 100644
index 00000000..0e0c3e42
--- /dev/null
+++ b/src/pulsecore/cpu-arm.h
@@ -0,0 +1,43 @@
+#ifndef foocpuarmhfoo
+#define foocpuarmhfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <stdint.h>
+#include <pulsecore/macro.h>
+
+typedef enum pa_cpu_arm_flag {
+ PA_CPU_ARM_V6 = (1 << 0),
+ PA_CPU_ARM_V7 = (1 << 1),
+ PA_CPU_ARM_VFP = (1 << 2),
+ PA_CPU_ARM_EDSP = (1 << 3),
+ PA_CPU_ARM_NEON = (1 << 4),
+ PA_CPU_ARM_VFPV3 = (1 << 5)
+} pa_cpu_arm_flag_t;
+
+pa_bool_t pa_cpu_init_arm (pa_cpu_arm_flag_t *flags);
+
+/* some optimized functions */
+void pa_volume_func_init_arm(pa_cpu_arm_flag_t flags);
+
+#endif /* foocpuarmhfoo */
diff --git a/src/pulsecore/cpu-orc.c b/src/pulsecore/cpu-orc.c
new file mode 100644
index 00000000..d4a15357
--- /dev/null
+++ b/src/pulsecore/cpu-orc.c
@@ -0,0 +1,34 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include "cpu-orc.h"
+
+void pa_cpu_init_orc(pa_cpu_info cpu_info)
+{
+#ifndef DISABLE_ORC
+ /* Update these as we test on more architectures */
+ pa_cpu_x86_flag_t x86_want_flags = PA_CPU_X86_MMX | PA_CPU_X86_SSE | PA_CPU_X86_SSE2 | PA_CPU_X86_SSE3 | PA_CPU_X86_SSSE3 | PA_CPU_X86_SSE4_1 | PA_CPU_X86_SSE4_2;
+
+ /* Enable Orc svolume optimizations */
+ if ((cpu_info.cpu_type == PA_CPU_X86) && (cpu_info.flags.x86 & x86_want_flags))
+ pa_volume_func_init_orc();
+#endif
+}
diff --git a/src/daemon/polkit.h b/src/pulsecore/cpu-orc.h
index 018f6ef1..9924d27b 100644
--- a/src/daemon/polkit.h
+++ b/src/pulsecore/cpu-orc.h
@@ -1,10 +1,10 @@
-#ifndef foopolkithfoo
-#define foopolkithfoo
+#ifndef foocpuorchfoo
+#define foocpuorchfoo
/***
This file is part of PulseAudio.
- Copyright 2007 Lennart Poettering
+ Copyright 2010 Arun Raghavan <arun.raghavan@collabora.co.uk>
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
@@ -22,6 +22,16 @@
USA.
***/
-int pa_polkit_check(const char *action);
-
+#ifdef HAVE_CONFIG_H
+#include <config.h>
#endif
+
+#include <pulsecore/cpu.h>
+
+/* Orc-optimised bits */
+
+void pa_cpu_init_orc(pa_cpu_info cpu_info);
+
+void pa_volume_func_init_orc(void);
+
+#endif /* foocpuorchfoo */
diff --git a/src/pulsecore/cpu-x86.c b/src/pulsecore/cpu-x86.c
new file mode 100644
index 00000000..05a4b2f0
--- /dev/null
+++ b/src/pulsecore/cpu-x86.c
@@ -0,0 +1,131 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdint.h>
+
+#include <pulsecore/log.h>
+
+#include "cpu-x86.h"
+
+#if defined (__i386__) || defined (__amd64__)
+static void get_cpuid(uint32_t op, uint32_t *a, uint32_t *b, uint32_t *c, uint32_t *d) {
+ __asm__ __volatile__ (
+ " push %%"PA_REG_b" \n\t"
+ " cpuid \n\t"
+ " mov %%ebx, %%esi \n\t"
+ " pop %%"PA_REG_b" \n\t"
+
+ : "=a" (*a), "=S" (*b), "=c" (*c), "=d" (*d)
+ : "0" (op)
+ );
+}
+#endif
+
+pa_bool_t pa_cpu_init_x86(pa_cpu_x86_flag_t *flags) {
+#if defined (__i386__) || defined (__amd64__)
+ uint32_t eax, ebx, ecx, edx;
+ uint32_t level;
+
+ *flags = 0;
+
+ /* get standard level */
+ get_cpuid(0x00000000, &level, &ebx, &ecx, &edx);
+ if (level >= 1) {
+ get_cpuid(0x00000001, &eax, &ebx, &ecx, &edx);
+
+ if (edx & (1<<15))
+ *flags |= PA_CPU_X86_CMOV;
+
+ if (edx & (1<<23))
+ *flags |= PA_CPU_X86_MMX;
+
+ if (edx & (1<<25))
+ *flags |= PA_CPU_X86_SSE;
+
+ if (edx & (1<<26))
+ *flags |= PA_CPU_X86_SSE2;
+
+ if (ecx & (1<<0))
+ *flags |= PA_CPU_X86_SSE3;
+
+ if (ecx & (1<<9))
+ *flags |= PA_CPU_X86_SSSE3;
+
+ if (ecx & (1<<19))
+ *flags |= PA_CPU_X86_SSE4_1;
+
+ if (ecx & (1<<20))
+ *flags |= PA_CPU_X86_SSE4_2;
+ }
+
+ /* get extended level */
+ get_cpuid(0x80000000, &level, &ebx, &ecx, &edx);
+ if (level >= 0x80000001) {
+ get_cpuid(0x80000001, &eax, &ebx, &ecx, &edx);
+
+ if (edx & (1<<22))
+ *flags |= PA_CPU_X86_MMXEXT;
+
+ if (edx & (1<<23))
+ *flags |= PA_CPU_X86_MMX;
+
+ if (edx & (1<<30))
+ *flags |= PA_CPU_X86_3DNOWEXT;
+
+ if (edx & (1<<31))
+ *flags |= PA_CPU_X86_3DNOW;
+ }
+
+ pa_log_info("CPU flags: %s%s%s%s%s%s%s%s%s%s%s",
+ (*flags & PA_CPU_X86_CMOV) ? "CMOV " : "",
+ (*flags & PA_CPU_X86_MMX) ? "MMX " : "",
+ (*flags & PA_CPU_X86_SSE) ? "SSE " : "",
+ (*flags & PA_CPU_X86_SSE2) ? "SSE2 " : "",
+ (*flags & PA_CPU_X86_SSE3) ? "SSE3 " : "",
+ (*flags & PA_CPU_X86_SSSE3) ? "SSSE3 " : "",
+ (*flags & PA_CPU_X86_SSE4_1) ? "SSE4_1 " : "",
+ (*flags & PA_CPU_X86_SSE4_2) ? "SSE4_2 " : "",
+ (*flags & PA_CPU_X86_MMXEXT) ? "MMXEXT " : "",
+ (*flags & PA_CPU_X86_3DNOW) ? "3DNOW " : "",
+ (*flags & PA_CPU_X86_3DNOWEXT) ? "3DNOWEXT " : "");
+
+ /* activate various optimisations */
+ if (*flags & PA_CPU_X86_MMX) {
+ pa_volume_func_init_mmx(*flags);
+ pa_remap_func_init_mmx(*flags);
+ }
+
+ if (*flags & (PA_CPU_X86_SSE | PA_CPU_X86_SSE2)) {
+ pa_volume_func_init_sse(*flags);
+ pa_remap_func_init_sse(*flags);
+ pa_convert_func_init_sse(*flags);
+ }
+
+ return TRUE;
+#else /* defined (__i386__) || defined (__amd64__) */
+ return FALSE;
+#endif /* defined (__i386__) || defined (__amd64__) */
+}
diff --git a/src/pulsecore/cpu-x86.h b/src/pulsecore/cpu-x86.h
new file mode 100644
index 00000000..0045ef6d
--- /dev/null
+++ b/src/pulsecore/cpu-x86.h
@@ -0,0 +1,72 @@
+#ifndef foocpux86hfoo
+#define foocpux86hfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <stdint.h>
+#include <pulsecore/macro.h>
+
+typedef enum pa_cpu_x86_flag {
+ PA_CPU_X86_MMX = (1 << 0),
+ PA_CPU_X86_MMXEXT = (1 << 1),
+ PA_CPU_X86_SSE = (1 << 2),
+ PA_CPU_X86_SSE2 = (1 << 3),
+ PA_CPU_X86_SSE3 = (1 << 4),
+ PA_CPU_X86_SSSE3 = (1 << 5),
+ PA_CPU_X86_SSE4_1 = (1 << 6),
+ PA_CPU_X86_SSE4_2 = (1 << 7),
+ PA_CPU_X86_3DNOW = (1 << 8),
+ PA_CPU_X86_3DNOWEXT = (1 << 9),
+ PA_CPU_X86_CMOV = (1 << 10)
+} pa_cpu_x86_flag_t;
+
+pa_bool_t pa_cpu_init_x86 (pa_cpu_x86_flag_t *flags);
+
+#if defined (__i386__)
+typedef int32_t pa_reg_x86;
+#define PA_REG_a "eax"
+#define PA_REG_b "ebx"
+#define PA_REG_c "ecx"
+#define PA_REG_d "edx"
+#define PA_REG_D "edi"
+#define PA_REG_S "esi"
+#elif defined (__amd64__)
+typedef int64_t pa_reg_x86;
+#define PA_REG_a "rax"
+#define PA_REG_b "rbx"
+#define PA_REG_c "rcx"
+#define PA_REG_d "rdx"
+#define PA_REG_D "rdi"
+#define PA_REG_S "rsi"
+#endif
+
+/* some optimized functions */
+void pa_volume_func_init_mmx(pa_cpu_x86_flag_t flags);
+void pa_volume_func_init_sse(pa_cpu_x86_flag_t flags);
+
+void pa_remap_func_init_mmx(pa_cpu_x86_flag_t flags);
+void pa_remap_func_init_sse(pa_cpu_x86_flag_t flags);
+
+void pa_convert_func_init_sse (pa_cpu_x86_flag_t flags);
+
+#endif /* foocpux86hfoo */
diff --git a/src/pulsecore/cpu.h b/src/pulsecore/cpu.h
new file mode 100644
index 00000000..7fe6f0b5
--- /dev/null
+++ b/src/pulsecore/cpu.h
@@ -0,0 +1,45 @@
+#ifndef foocpuhfoo
+#define foocpuhfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2010 Arun Raghavan
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <pulsecore/cpu-x86.h>
+#include <pulsecore/cpu-arm.h>
+
+typedef enum {
+ PA_CPU_UNDEFINED = 0,
+ PA_CPU_X86,
+ PA_CPU_ARM,
+} pa_cpu_type_t;
+
+typedef struct pa_cpu_info pa_cpu_info;
+
+struct pa_cpu_info {
+ pa_cpu_type_t cpu_type;
+
+ union {
+ pa_cpu_x86_flag_t x86;
+ pa_cpu_arm_flag_t arm;
+ } flags;
+};
+
+#endif /* foocpuhfoo */
diff --git a/src/pulsecore/creds.h b/src/pulsecore/creds.h
index c15c469b..aa1d5608 100644
--- a/src/pulsecore/creds.h
+++ b/src/pulsecore/creds.h
@@ -28,13 +28,7 @@
#error "Please include config.h before including this file!"
#endif
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-
-#ifdef HAVE_SYS_UN_H
-#include <sys/un.h>
-#endif
+#include <pulsecore/socket.h>
typedef struct pa_creds pa_creds;
diff --git a/src/pulsecore/database-gdbm.c b/src/pulsecore/database-gdbm.c
index aeaac64b..e65125d3 100644
--- a/src/pulsecore/database-gdbm.c
+++ b/src/pulsecore/database-gdbm.c
@@ -71,10 +71,13 @@ pa_database* pa_database_open(const char *fn, pa_bool_t for_write) {
/* We include the host identifier in the file name because gdbm
* files are CPU dependant, and we don't want things to go wrong
* if we are on a multiarch system. */
-
path = pa_sprintf_malloc("%s."CANONICAL_HOST".gdbm", fn);
errno = 0;
- f = gdbm_open((char*) path, 0, GDBM_NOLOCK | (for_write ? GDBM_WRCREAT : GDBM_READER), 0644, NULL);
+
+ /* We need to set the block size explicitly here, since otherwise
+ * gdbm takes the native block size of the underlying file system
+ * which might be incredibly large. */
+ f = gdbm_open((char*) path, 1024, GDBM_NOLOCK | (for_write ? GDBM_WRCREAT : GDBM_READER), 0644, NULL);
if (f)
pa_log_debug("Opened GDBM database '%s'", path);
diff --git a/src/pulsecore/database-simple.c b/src/pulsecore/database-simple.c
new file mode 100644
index 00000000..3538127d
--- /dev/null
+++ b/src/pulsecore/database-simple.c
@@ -0,0 +1,508 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Nokia Corporation
+ Contact: Maemo Multimedia <multimedia@maemo.org>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of the
+ License, or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <errno.h>
+#include <sys/types.h>
+#include <unistd.h>
+#include <stdio.h>
+
+#include <pulse/xmalloc.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/log.h>
+#include <pulsecore/core-error.h>
+#include <pulsecore/hashmap.h>
+
+#include "database.h"
+
+
+typedef struct simple_data {
+ char *filename;
+ char *tmp_filename;
+ pa_hashmap *map;
+ pa_bool_t read_only;
+} simple_data;
+
+typedef struct entry {
+ pa_datum key;
+ pa_datum data;
+} entry;
+
+void pa_datum_free(pa_datum *d) {
+ pa_assert(d);
+
+ pa_xfree(d->data);
+ d->data = NULL;
+ d->size = 0;
+}
+
+static int compare_func(const void *a, const void *b) {
+ const pa_datum *aa, *bb;
+
+ aa = (const pa_datum*)a;
+ bb = (const pa_datum*)b;
+
+ if (aa->size != bb->size)
+ return aa->size > bb->size ? 1 : -1;
+
+ return memcmp(aa->data, bb->data, aa->size);
+}
+
+/* pa_idxset_string_hash_func modified for our use */
+static unsigned hash_func(const void *p) {
+ const pa_datum *d;
+ unsigned hash = 0;
+ const char *c;
+ unsigned i;
+
+ d = (const pa_datum*)p;
+ c = d->data;
+
+ for (i = 0; i < d->size; i++) {
+ hash = 31 * hash + (unsigned) *c;
+ c++;
+ }
+
+ return hash;
+}
+
+static entry* new_entry(const pa_datum *key, const pa_datum *data) {
+ entry *e;
+
+ pa_assert(key);
+ pa_assert(data);
+
+ e = pa_xnew0(entry, 1);
+ e->key.data = key->size > 0 ? pa_xmemdup(key->data, key->size) : NULL;
+ e->key.size = key->size;
+ e->data.data = data->size > 0 ? pa_xmemdup(data->data, data->size) : NULL;
+ e->data.size = data->size;
+ return e;
+}
+
+static void free_entry(entry *e) {
+ if (e) {
+ if (e->key.data)
+ pa_xfree(e->key.data);
+ if (e->data.data)
+ pa_xfree(e->data.data);
+ pa_xfree(e);
+ }
+}
+
+static int read_uint(FILE *f, uint32_t *res) {
+ size_t items = 0;
+ uint8_t values[4];
+ uint32_t tmp;
+ int i;
+
+ items = fread(&values, sizeof(values), sizeof(uint8_t), f);
+
+ if (feof(f)) /* EOF */
+ return 0;
+
+ if (ferror(f))
+ return -1;
+
+ for (i = 0; i < 4; ++i) {
+ tmp = values[i];
+ *res += (tmp << (i*8));
+ }
+
+ return items;
+}
+
+static int read_data(FILE *f, void **data, ssize_t *length) {
+ size_t items = 0;
+ uint32_t data_len = 0;
+
+ pa_assert(f);
+
+ *data = NULL;
+ *length = 0;
+
+ if ((items = read_uint(f, &data_len)) <= 0)
+ return -1;
+
+ if (data_len > 0) {
+ *data = pa_xmalloc0(data_len);
+ items = fread(*data, data_len, 1, f);
+
+ if (feof(f)) /* EOF */
+ goto reset;
+
+ if (ferror(f))
+ goto reset;
+
+ *length = data_len;
+
+ } else { /* no data? */
+ return -1;
+ }
+
+ return 0;
+
+reset:
+ pa_xfree(*data);
+ *data = NULL;
+ *length = 0;
+ return -1;
+}
+
+static int fill_data(simple_data *db, FILE *f) {
+ pa_datum key;
+ pa_datum data;
+ void *d = NULL;
+ ssize_t l = 0;
+ pa_bool_t append = FALSE;
+ enum { FIELD_KEY = 0, FIELD_DATA } field = FIELD_KEY;
+
+ pa_assert(db);
+ pa_assert(db->map);
+
+ errno = 0;
+
+ key.size = 0;
+ key.data = NULL;
+
+ while (!read_data(f, &d, &l)) {
+
+ switch (field) {
+ case FIELD_KEY:
+ key.data = d;
+ key.size = l;
+ field = FIELD_DATA;
+ break;
+ case FIELD_DATA:
+ data.data = d;
+ data.size = l;
+ append = TRUE;
+ break;
+ }
+
+ if (append) {
+ entry *e = pa_xnew0(entry, 1);
+ e->key.data = key.data;
+ e->key.size = key.size;
+ e->data.data = data.data;
+ e->data.size = data.size;
+ pa_hashmap_put(db->map, &e->key, e);
+ append = FALSE;
+ field = FIELD_KEY;
+ }
+ }
+
+ if (ferror(f)) {
+ pa_log_warn("read error. %s", pa_cstrerror(errno));
+ pa_database_clear((pa_database*)db);
+ }
+
+ if (field == FIELD_DATA && d)
+ pa_xfree(d);
+
+ return pa_hashmap_size(db->map);
+}
+
+pa_database* pa_database_open(const char *fn, pa_bool_t for_write) {
+ FILE *f;
+ char *path;
+ simple_data *db;
+
+ pa_assert(fn);
+
+ path = pa_sprintf_malloc("%s."CANONICAL_HOST".simple", fn);
+ errno = 0;
+
+ f = pa_fopen_cloexec(path, "r");
+
+ if (f || errno == ENOENT) { /* file not found is ok */
+ db = pa_xnew0(simple_data, 1);
+ db->map = pa_hashmap_new(hash_func, compare_func);
+ db->filename = pa_xstrdup(path);
+ db->tmp_filename = pa_sprintf_malloc(".%s.tmp", db->filename);
+ db->read_only = !for_write;
+
+ if (f) {
+ fill_data(db, f);
+ fclose(f);
+ }
+ } else {
+ if (errno == 0)
+ errno = EIO;
+ db = NULL;
+ }
+
+ pa_xfree(path);
+
+ return (pa_database*) db;
+}
+
+void pa_database_close(pa_database *database) {
+ simple_data *db = (simple_data*)database;
+ pa_assert(db);
+
+ pa_database_sync(database);
+ pa_database_clear(database);
+ pa_xfree(db->filename);
+ pa_xfree(db->tmp_filename);
+ pa_hashmap_free(db->map, NULL, NULL);
+ pa_xfree(db);
+}
+
+pa_datum* pa_database_get(pa_database *database, const pa_datum *key, pa_datum* data) {
+ simple_data *db = (simple_data*)database;
+ entry *e;
+
+ pa_assert(db);
+ pa_assert(key);
+ pa_assert(data);
+
+ e = pa_hashmap_get(db->map, key);
+
+ if (!e)
+ return NULL;
+
+ data->data = e->data.size > 0 ? pa_xmemdup(e->data.data, e->data.size) : NULL;
+ data->size = e->data.size;
+
+ return data;
+}
+
+int pa_database_set(pa_database *database, const pa_datum *key, const pa_datum* data, pa_bool_t overwrite) {
+ simple_data *db = (simple_data*)database;
+ entry *e;
+ int ret = 0;
+
+ pa_assert(db);
+ pa_assert(key);
+ pa_assert(data);
+
+ if (db->read_only)
+ return -1;
+
+ e = new_entry(key, data);
+
+ if (pa_hashmap_put(db->map, &e->key, e) < 0) {
+ /* entry with same key exists in hashmap */
+ entry *r;
+ if (overwrite) {
+ r = pa_hashmap_remove(db->map, key);
+ pa_hashmap_put(db->map, &e->key, e);
+ } else {
+ /* wont't overwrite, so clean new entry */
+ r = e;
+ ret = -1;
+ }
+
+ free_entry(r);
+ }
+
+ return ret;
+}
+
+int pa_database_unset(pa_database *database, const pa_datum *key) {
+ simple_data *db = (simple_data*)database;
+ entry *e;
+
+ pa_assert(db);
+ pa_assert(key);
+
+ e = pa_hashmap_remove(db->map, key);
+ if (!e)
+ return -1;
+
+ free_entry(e);
+
+ return 0;
+}
+
+int pa_database_clear(pa_database *database) {
+ simple_data *db = (simple_data*)database;
+ entry *e;
+
+ pa_assert(db);
+
+ while ((e = pa_hashmap_steal_first(db->map)))
+ free_entry(e);
+
+ return 0;
+}
+
+signed pa_database_size(pa_database *database) {
+ simple_data *db = (simple_data*)database;
+ pa_assert(db);
+
+ return (signed) pa_hashmap_size(db->map);
+}
+
+pa_datum* pa_database_first(pa_database *database, pa_datum *key, pa_datum *data) {
+ simple_data *db = (simple_data*)database;
+ entry *e;
+
+ pa_assert(db);
+ pa_assert(key);
+
+ e = pa_hashmap_first(db->map);
+
+ if (!e)
+ return NULL;
+
+ key->data = e->key.size > 0 ? pa_xmemdup(e->key.data, e->key.size) : NULL;
+ key->size = e->key.size;
+
+ if (data) {
+ data->data = e->data.size > 0 ? pa_xmemdup(e->data.data, e->data.size) : NULL;
+ data->size = e->data.size;
+ }
+
+ return key;
+}
+
+pa_datum* pa_database_next(pa_database *database, const pa_datum *key, pa_datum *next, pa_datum *data) {
+ simple_data *db = (simple_data*)database;
+ entry *e;
+ entry *search;
+ void *state;
+ pa_bool_t pick_now;
+
+ pa_assert(db);
+ pa_assert(next);
+
+ if (!key)
+ return pa_database_first(database, next, data);
+
+ search = pa_hashmap_get(db->map, key);
+
+ state = NULL;
+ pick_now = FALSE;
+
+ while ((e = pa_hashmap_iterate(db->map, &state, NULL))) {
+ if (pick_now)
+ break;
+
+ if (search == e)
+ pick_now = TRUE;
+ }
+
+ if (!pick_now || !e)
+ return NULL;
+
+ next->data = e->key.size > 0 ? pa_xmemdup(e->key.data, e->key.size) : NULL;
+ next->size = e->key.size;
+
+ if (data) {
+ data->data = e->data.size > 0 ? pa_xmemdup(e->data.data, e->data.size) : NULL;
+ data->size = e->data.size;
+ }
+
+ return next;
+}
+
+static int write_uint(FILE *f, const uint32_t num) {
+ size_t items;
+ uint8_t values[4];
+ int i;
+ errno = 0;
+
+ for (i = 0; i < 4; i++)
+ values[i] = (num >> (i*8)) & 0xFF;
+
+ items = fwrite(&values, sizeof(values), sizeof(uint8_t), f);
+
+ if (ferror(f))
+ return -1;
+
+ return items;
+}
+
+static int write_data(FILE *f, void *data, const size_t length) {
+ size_t items;
+ uint32_t len;
+
+ len = length;
+ if ((items = write_uint(f, len)) <= 0)
+ return -1;
+
+ items = fwrite(data, length, 1, f);
+
+ if (ferror(f) || items != 1)
+ return -1;
+
+ return 0;
+}
+
+static int write_entry(FILE *f, const entry *e) {
+ pa_assert(f);
+ pa_assert(e);
+
+ if (write_data(f, e->key.data, e->key.size) < 0)
+ return -1;
+ if (write_data(f, e->data.data, e->data.size) < 0)
+ return -1;
+
+ return 0;
+}
+
+int pa_database_sync(pa_database *database) {
+ simple_data *db = (simple_data*)database;
+ FILE *f;
+ void *state;
+ entry *e;
+
+ pa_assert(db);
+
+ if (db->read_only)
+ return 0;
+
+ errno = 0;
+
+ f = pa_fopen_cloexec(db->tmp_filename, "w");
+
+ if (!f)
+ goto fail;
+
+ state = NULL;
+ while((e = pa_hashmap_iterate(db->map, &state, NULL))) {
+ if (write_entry(f, e) < 0) {
+ pa_log_warn("error while writing to file. %s", pa_cstrerror(errno));
+ goto fail;
+ }
+ }
+
+ fclose(f);
+ f = NULL;
+
+ if (rename(db->tmp_filename, db->filename) < 0) {
+ pa_log_warn("error while renaming file. %s", pa_cstrerror(errno));
+ goto fail;
+ }
+
+ return 0;
+
+fail:
+ if (f)
+ fclose(f);
+ return -1;
+}
diff --git a/src/pulsecore/database-tdb.c b/src/pulsecore/database-tdb.c
index c35fd81f..4e782d65 100644
--- a/src/pulsecore/database-tdb.c
+++ b/src/pulsecore/database-tdb.c
@@ -26,6 +26,9 @@
#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
+
+/* Some versions of tdb lack inclusion of signal.h in the header files but use sigatomic_t */
+#include <signal.h>
#include <tdb.h>
#include <pulse/xmalloc.h>
@@ -63,6 +66,39 @@ void pa_datum_free(pa_datum *d) {
pa_zero(d);
}
+static struct tdb_context *tdb_open_cloexec(
+ const char *name,
+ int hash_size,
+ int tdb_flags,
+ int open_flags,
+ mode_t mode) {
+
+ /* Mimics pa_open_cloexec() */
+
+ struct tdb_context *c;
+
+#ifdef O_NOCTTY
+ open_flags |= O_NOCTTY;
+#endif
+
+#ifdef O_CLOEXEC
+ errno = 0;
+ if ((c = tdb_open(name, hash_size, tdb_flags, open_flags | O_CLOEXEC, mode)))
+ goto finish;
+
+ if (errno != EINVAL)
+ return NULL;
+#endif
+
+ errno = 0;
+ if (!(c = tdb_open(name, hash_size, tdb_flags, open_flags, mode)))
+ return NULL;
+
+finish:
+ pa_make_fd_cloexec(tdb_fd(c));
+ return c;
+}
+
pa_database* pa_database_open(const char *fn, pa_bool_t for_write) {
struct tdb_context *c;
char *path;
@@ -70,15 +106,7 @@ pa_database* pa_database_open(const char *fn, pa_bool_t for_write) {
pa_assert(fn);
path = pa_sprintf_malloc("%s.tdb", fn);
- errno = 0;
- c = tdb_open(path, 0, TDB_NOSYNC|TDB_NOLOCK,
- (for_write ? O_RDWR|O_CREAT : O_RDONLY)|O_NOCTTY
-#ifdef O_CLOEXEC
- |O_CLOEXEC
-#endif
- , 0644);
-
- if (c)
+ if ((c = tdb_open_cloexec(path, 0, TDB_NOSYNC|TDB_NOLOCK, (for_write ? O_RDWR|O_CREAT : O_RDONLY), 0644)))
pa_log_debug("Opened TDB database '%s'", path);
pa_xfree(path);
diff --git a/src/pulsecore/dbus-shared.c b/src/pulsecore/dbus-shared.c
index 9d9445b6..34774072 100644
--- a/src/pulsecore/dbus-shared.c
+++ b/src/pulsecore/dbus-shared.c
@@ -24,11 +24,8 @@
#include <config.h>
#endif
-#include <stdarg.h>
-
#include <pulse/xmalloc.h>
-#include <pulse/timeval.h>
-#include <pulsecore/log.h>
+
#include <pulsecore/shared.h>
#include "dbus-shared.h"
@@ -70,7 +67,7 @@ pa_dbus_connection* pa_dbus_bus_get(pa_core *c, DBusBusType type, DBusError *err
if ((pconn = pa_shared_get(c, prop_name[type])))
return pa_dbus_connection_ref(pconn);
- if (!(conn = pa_dbus_wrap_connection_new(c->mainloop, type, error)))
+ if (!(conn = pa_dbus_wrap_connection_new(c->mainloop, TRUE, type, error)))
return NULL;
return dbus_connection_new(c, conn, prop_name[type]);
diff --git a/src/pulsecore/dbus-util.c b/src/pulsecore/dbus-util.c
index ece36def..09ab071b 100644
--- a/src/pulsecore/dbus-util.c
+++ b/src/pulsecore/dbus-util.c
@@ -26,9 +26,12 @@
#include <stdarg.h>
-#include <pulse/xmalloc.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
+#include <pulse/utf8.h>
+#include <pulse/xmalloc.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
@@ -38,15 +41,20 @@ struct pa_dbus_wrap_connection {
pa_mainloop_api *mainloop;
DBusConnection *connection;
pa_defer_event* dispatch_event;
+ pa_bool_t use_rtclock:1;
+};
+
+struct timeout_data {
+ pa_dbus_wrap_connection *connection;
+ DBusTimeout *timeout;
};
static void dispatch_cb(pa_mainloop_api *ea, pa_defer_event *ev, void *userdata) {
DBusConnection *conn = userdata;
- if (dbus_connection_dispatch(conn) == DBUS_DISPATCH_COMPLETE) {
+ if (dbus_connection_dispatch(conn) == DBUS_DISPATCH_COMPLETE)
/* no more data to process, disable the deferred */
ea->defer_enable(ev, 0);
- }
}
/* DBusDispatchStatusFunction callback for the pa mainloop */
@@ -118,16 +126,22 @@ static void handle_io_event(pa_mainloop_api *ea, pa_io_event *e, int fd, pa_io_e
}
/* pa_time_event_cb_t timer event handler */
-static void handle_time_event(pa_mainloop_api *ea, pa_time_event* e, const struct timeval *tv, void *userdata) {
- DBusTimeout *timeout = userdata;
+static void handle_time_event(pa_mainloop_api *ea, pa_time_event* e, const struct timeval *t, void *userdata) {
+ struct timeval tv;
+ struct timeout_data *d = userdata;
+
+ pa_assert(d);
+ pa_assert(d->connection);
- if (dbus_timeout_get_enabled(timeout)) {
- struct timeval next = *tv;
- dbus_timeout_handle(timeout);
+ if (dbus_timeout_get_enabled(d->timeout)) {
+ /* Restart it for the next scheduled time. We do this before
+ * calling dbus_timeout_handle() to make sure that the time
+ * event is still around. */
+ ea->time_restart(e, pa_timeval_rtstore(&tv,
+ pa_timeval_load(t) + dbus_timeout_get_interval(d->timeout) * PA_USEC_PER_MSEC,
+ d->connection->use_rtclock));
- /* restart it for the next scheduled time */
- pa_timeval_add(&next, (pa_usec_t) dbus_timeout_get_interval(timeout) * 1000);
- ea->time_restart(e, &next);
+ dbus_timeout_handle(d->timeout);
}
}
@@ -179,11 +193,16 @@ static void toggle_watch(DBusWatch *watch, void *data) {
c->mainloop->io_enable(ev, get_watch_flags(watch));
}
+static void time_event_destroy_cb(pa_mainloop_api *a, pa_time_event *e, void *userdata) {
+ pa_xfree(userdata);
+}
+
/* DBusAddTimeoutFunction callback for pa mainloop */
static dbus_bool_t add_timeout(DBusTimeout *timeout, void *data) {
pa_dbus_wrap_connection *c = data;
pa_time_event *ev;
struct timeval tv;
+ struct timeout_data *d;
pa_assert(timeout);
pa_assert(c);
@@ -191,10 +210,11 @@ static dbus_bool_t add_timeout(DBusTimeout *timeout, void *data) {
if (!dbus_timeout_get_enabled(timeout))
return FALSE;
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, (pa_usec_t) dbus_timeout_get_interval(timeout) * 1000);
-
- ev = c->mainloop->time_new(c->mainloop, &tv, handle_time_event, timeout);
+ d = pa_xnew(struct timeout_data, 1);
+ d->connection = c;
+ d->timeout = timeout;
+ ev = c->mainloop->time_new(c->mainloop, pa_timeval_rtstore(&tv, pa_rtclock_now() + dbus_timeout_get_interval(timeout) * PA_USEC_PER_MSEC, c->use_rtclock), handle_time_event, d);
+ c->mainloop->time_set_destroy(ev, time_event_destroy_cb);
dbus_timeout_set_data(timeout, ev, NULL);
@@ -215,23 +235,20 @@ static void remove_timeout(DBusTimeout *timeout, void *data) {
/* DBusTimeoutToggledFunction callback for pa mainloop */
static void toggle_timeout(DBusTimeout *timeout, void *data) {
- pa_dbus_wrap_connection *c = data;
+ struct timeout_data *d = data;
pa_time_event *ev;
+ struct timeval tv;
+ pa_assert(d);
+ pa_assert(d->connection);
pa_assert(timeout);
- pa_assert(c);
pa_assert_se(ev = dbus_timeout_get_data(timeout));
- if (dbus_timeout_get_enabled(timeout)) {
- struct timeval tv;
-
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, (pa_usec_t) dbus_timeout_get_interval(timeout) * 1000);
-
- c->mainloop->time_restart(ev, &tv);
- } else
- c->mainloop->time_restart(ev, NULL);
+ if (dbus_timeout_get_enabled(timeout))
+ d->connection->mainloop->time_restart(ev, pa_timeval_rtstore(&tv, pa_rtclock_now() + dbus_timeout_get_interval(timeout) * PA_USEC_PER_MSEC, d->connection->use_rtclock));
+ else
+ d->connection->mainloop->time_restart(ev, pa_timeval_rtstore(&tv, PA_USEC_INVALID, d->connection->use_rtclock));
}
static void wakeup_main(void *userdata) {
@@ -244,7 +261,7 @@ static void wakeup_main(void *userdata) {
c->mainloop->defer_enable(c->dispatch_event, 1);
}
-pa_dbus_wrap_connection* pa_dbus_wrap_connection_new(pa_mainloop_api *m, DBusBusType type, DBusError *error) {
+pa_dbus_wrap_connection* pa_dbus_wrap_connection_new(pa_mainloop_api *m, pa_bool_t use_rtclock, DBusBusType type, DBusError *error) {
DBusConnection *conn;
pa_dbus_wrap_connection *pconn;
char *id;
@@ -257,6 +274,7 @@ pa_dbus_wrap_connection* pa_dbus_wrap_connection_new(pa_mainloop_api *m, DBusBus
pconn = pa_xnew(pa_dbus_wrap_connection, 1);
pconn->mainloop = m;
pconn->connection = conn;
+ pconn->use_rtclock = use_rtclock;
dbus_connection_set_exit_on_disconnect(conn, FALSE);
dbus_connection_set_dispatch_status_function(conn, dispatch_status, pconn, NULL);
@@ -276,6 +294,31 @@ pa_dbus_wrap_connection* pa_dbus_wrap_connection_new(pa_mainloop_api *m, DBusBus
return pconn;
}
+pa_dbus_wrap_connection* pa_dbus_wrap_connection_new_from_existing(
+ pa_mainloop_api *m,
+ pa_bool_t use_rtclock,
+ DBusConnection *conn) {
+ pa_dbus_wrap_connection *pconn;
+
+ pa_assert(m);
+ pa_assert(conn);
+
+ pconn = pa_xnew(pa_dbus_wrap_connection, 1);
+ pconn->mainloop = m;
+ pconn->connection = dbus_connection_ref(conn);
+ pconn->use_rtclock = use_rtclock;
+
+ dbus_connection_set_exit_on_disconnect(conn, FALSE);
+ dbus_connection_set_dispatch_status_function(conn, dispatch_status, pconn, NULL);
+ dbus_connection_set_watch_functions(conn, add_watch, remove_watch, toggle_watch, pconn, NULL);
+ dbus_connection_set_timeout_functions(conn, add_timeout, remove_timeout, toggle_timeout, pconn, NULL);
+ dbus_connection_set_wakeup_main_function(conn, wakeup_main, pconn, NULL);
+
+ pconn->dispatch_event = pconn->mainloop->defer_new(pconn->mainloop, dispatch_cb, conn);
+
+ return pconn;
+}
+
void pa_dbus_wrap_connection_free(pa_dbus_wrap_connection* c) {
pa_assert(c);
@@ -408,3 +451,329 @@ void pa_dbus_free_pending_list(pa_dbus_pending **p) {
pa_dbus_pending_free(i);
}
}
+
+void pa_dbus_send_error(DBusConnection *c, DBusMessage *in_reply_to, const char *name, const char *format, ...) {
+ va_list ap;
+ char *message;
+ DBusMessage *reply = NULL;
+
+ pa_assert(c);
+ pa_assert(in_reply_to);
+ pa_assert(name);
+ pa_assert(format);
+
+ va_start(ap, format);
+ message = pa_vsprintf_malloc(format, ap);
+ va_end(ap);
+ pa_assert_se((reply = dbus_message_new_error(in_reply_to, name, message)));
+ pa_assert_se(dbus_connection_send(c, reply, NULL));
+
+ dbus_message_unref(reply);
+
+ pa_xfree(message);
+}
+
+void pa_dbus_send_empty_reply(DBusConnection *c, DBusMessage *in_reply_to) {
+ DBusMessage *reply = NULL;
+
+ pa_assert(c);
+ pa_assert(in_reply_to);
+
+ pa_assert_se((reply = dbus_message_new_method_return(in_reply_to)));
+ pa_assert_se(dbus_connection_send(c, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+void pa_dbus_send_basic_value_reply(DBusConnection *c, DBusMessage *in_reply_to, int type, void *data) {
+ DBusMessage *reply = NULL;
+
+ pa_assert(c);
+ pa_assert(in_reply_to);
+ pa_assert(dbus_type_is_basic(type));
+ pa_assert(data);
+
+ pa_assert_se((reply = dbus_message_new_method_return(in_reply_to)));
+ pa_assert_se(dbus_message_append_args(reply, type, data, DBUS_TYPE_INVALID));
+ pa_assert_se(dbus_connection_send(c, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+static const char *signature_from_basic_type(int type) {
+ switch (type) {
+ case DBUS_TYPE_BOOLEAN: return DBUS_TYPE_BOOLEAN_AS_STRING;
+ case DBUS_TYPE_BYTE: return DBUS_TYPE_BYTE_AS_STRING;
+ case DBUS_TYPE_INT16: return DBUS_TYPE_INT16_AS_STRING;
+ case DBUS_TYPE_UINT16: return DBUS_TYPE_UINT16_AS_STRING;
+ case DBUS_TYPE_INT32: return DBUS_TYPE_INT32_AS_STRING;
+ case DBUS_TYPE_UINT32: return DBUS_TYPE_UINT32_AS_STRING;
+ case DBUS_TYPE_INT64: return DBUS_TYPE_INT64_AS_STRING;
+ case DBUS_TYPE_UINT64: return DBUS_TYPE_UINT64_AS_STRING;
+ case DBUS_TYPE_DOUBLE: return DBUS_TYPE_DOUBLE_AS_STRING;
+ case DBUS_TYPE_STRING: return DBUS_TYPE_STRING_AS_STRING;
+ case DBUS_TYPE_OBJECT_PATH: return DBUS_TYPE_OBJECT_PATH_AS_STRING;
+ case DBUS_TYPE_SIGNATURE: return DBUS_TYPE_SIGNATURE_AS_STRING;
+ default: pa_assert_not_reached();
+ }
+}
+
+void pa_dbus_send_basic_variant_reply(DBusConnection *c, DBusMessage *in_reply_to, int type, void *data) {
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter variant_iter;
+
+ pa_assert(c);
+ pa_assert(in_reply_to);
+ pa_assert(dbus_type_is_basic(type));
+ pa_assert(data);
+
+ pa_assert_se((reply = dbus_message_new_method_return(in_reply_to)));
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter,
+ DBUS_TYPE_VARIANT,
+ signature_from_basic_type(type),
+ &variant_iter));
+ pa_assert_se(dbus_message_iter_append_basic(&variant_iter, type, data));
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &variant_iter));
+ pa_assert_se(dbus_connection_send(c, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+/* Note: returns sizeof(char*) for strings, object paths and signatures. */
+static unsigned basic_type_size(int type) {
+ switch (type) {
+ case DBUS_TYPE_BOOLEAN: return sizeof(dbus_bool_t);
+ case DBUS_TYPE_BYTE: return 1;
+ case DBUS_TYPE_INT16: return sizeof(dbus_int16_t);
+ case DBUS_TYPE_UINT16: return sizeof(dbus_uint16_t);
+ case DBUS_TYPE_INT32: return sizeof(dbus_int32_t);
+ case DBUS_TYPE_UINT32: return sizeof(dbus_uint32_t);
+ case DBUS_TYPE_INT64: return sizeof(dbus_int64_t);
+ case DBUS_TYPE_UINT64: return sizeof(dbus_uint64_t);
+ case DBUS_TYPE_DOUBLE: return sizeof(double);
+ case DBUS_TYPE_STRING:
+ case DBUS_TYPE_OBJECT_PATH:
+ case DBUS_TYPE_SIGNATURE: return sizeof(char*);
+ default: pa_assert_not_reached();
+ }
+}
+
+void pa_dbus_send_basic_array_variant_reply(
+ DBusConnection *c,
+ DBusMessage *in_reply_to,
+ int item_type,
+ void *array,
+ unsigned n) {
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+
+ pa_assert(c);
+ pa_assert(in_reply_to);
+ pa_assert(dbus_type_is_basic(item_type));
+ pa_assert(array || n == 0);
+
+ pa_assert_se((reply = dbus_message_new_method_return(in_reply_to)));
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_dbus_append_basic_array_variant(&msg_iter, item_type, array, n);
+ pa_assert_se(dbus_connection_send(c, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+void pa_dbus_send_proplist_variant_reply(DBusConnection *c, DBusMessage *in_reply_to, pa_proplist *proplist) {
+ DBusMessage *reply = NULL;
+ DBusMessageIter msg_iter;
+
+ pa_assert(c);
+ pa_assert(in_reply_to);
+ pa_assert(proplist);
+
+ pa_assert_se((reply = dbus_message_new_method_return(in_reply_to)));
+ dbus_message_iter_init_append(reply, &msg_iter);
+ pa_dbus_append_proplist_variant(&msg_iter, proplist);
+ pa_assert_se(dbus_connection_send(c, reply, NULL));
+ dbus_message_unref(reply);
+}
+
+void pa_dbus_append_basic_array(DBusMessageIter *iter, int item_type, const void *array, unsigned n) {
+ DBusMessageIter array_iter;
+ unsigned i;
+ unsigned item_size;
+
+ pa_assert(iter);
+ pa_assert(dbus_type_is_basic(item_type));
+ pa_assert(array || n == 0);
+
+ item_size = basic_type_size(item_type);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_ARRAY, signature_from_basic_type(item_type), &array_iter));
+
+ for (i = 0; i < n; ++i)
+ pa_assert_se(dbus_message_iter_append_basic(&array_iter, item_type, &((uint8_t*) array)[i * item_size]));
+
+ pa_assert_se(dbus_message_iter_close_container(iter, &array_iter));
+};
+
+void pa_dbus_append_basic_variant(DBusMessageIter *iter, int type, void *data) {
+ DBusMessageIter variant_iter;
+
+ pa_assert(iter);
+ pa_assert(dbus_type_is_basic(type));
+ pa_assert(data);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_VARIANT, signature_from_basic_type(type), &variant_iter));
+ pa_assert_se(dbus_message_iter_append_basic(&variant_iter, type, data));
+ pa_assert_se(dbus_message_iter_close_container(iter, &variant_iter));
+}
+
+void pa_dbus_append_basic_array_variant(DBusMessageIter *iter, int item_type, const void *array, unsigned n) {
+ DBusMessageIter variant_iter;
+ char *array_signature;
+
+ pa_assert(iter);
+ pa_assert(dbus_type_is_basic(item_type));
+ pa_assert(array || n == 0);
+
+ array_signature = pa_sprintf_malloc("a%c", *signature_from_basic_type(item_type));
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_VARIANT, array_signature, &variant_iter));
+ pa_dbus_append_basic_array(&variant_iter, item_type, array, n);
+ pa_assert_se(dbus_message_iter_close_container(iter, &variant_iter));
+
+ pa_xfree(array_signature);
+}
+
+void pa_dbus_append_basic_variant_dict_entry(DBusMessageIter *dict_iter, const char *key, int type, void *data) {
+ DBusMessageIter dict_entry_iter;
+
+ pa_assert(dict_iter);
+ pa_assert(key);
+ pa_assert(dbus_type_is_basic(type));
+ pa_assert(data);
+
+ pa_assert_se(dbus_message_iter_open_container(dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter));
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &key));
+ pa_dbus_append_basic_variant(&dict_entry_iter, type, data);
+ pa_assert_se(dbus_message_iter_close_container(dict_iter, &dict_entry_iter));
+}
+
+void pa_dbus_append_basic_array_variant_dict_entry(
+ DBusMessageIter *dict_iter,
+ const char *key,
+ int item_type,
+ const void *array,
+ unsigned n) {
+ DBusMessageIter dict_entry_iter;
+
+ pa_assert(dict_iter);
+ pa_assert(key);
+ pa_assert(dbus_type_is_basic(item_type));
+ pa_assert(array || n == 0);
+
+ pa_assert_se(dbus_message_iter_open_container(dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter));
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &key));
+ pa_dbus_append_basic_array_variant(&dict_entry_iter, item_type, array, n);
+ pa_assert_se(dbus_message_iter_close_container(dict_iter, &dict_entry_iter));
+}
+
+void pa_dbus_append_proplist(DBusMessageIter *iter, pa_proplist *proplist) {
+ DBusMessageIter dict_iter;
+ DBusMessageIter dict_entry_iter;
+ DBusMessageIter array_iter;
+ void *state = NULL;
+ const char *key;
+
+ pa_assert(iter);
+ pa_assert(proplist);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_ARRAY, "{say}", &dict_iter));
+
+ while ((key = pa_proplist_iterate(proplist, &state))) {
+ const void *value = NULL;
+ size_t nbytes;
+
+ pa_assert_se(pa_proplist_get(proplist, key, &value, &nbytes) >= 0);
+
+ pa_assert_se(dbus_message_iter_open_container(&dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter));
+
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &key));
+
+ pa_assert_se(dbus_message_iter_open_container(&dict_entry_iter, DBUS_TYPE_ARRAY, "y", &array_iter));
+ pa_assert_se(dbus_message_iter_append_fixed_array(&array_iter, DBUS_TYPE_BYTE, &value, nbytes));
+ pa_assert_se(dbus_message_iter_close_container(&dict_entry_iter, &array_iter));
+
+ pa_assert_se(dbus_message_iter_close_container(&dict_iter, &dict_entry_iter));
+ }
+
+ pa_assert_se(dbus_message_iter_close_container(iter, &dict_iter));
+}
+
+void pa_dbus_append_proplist_variant(DBusMessageIter *iter, pa_proplist *proplist) {
+ DBusMessageIter variant_iter;
+
+ pa_assert(iter);
+ pa_assert(proplist);
+
+ pa_assert_se(dbus_message_iter_open_container(iter, DBUS_TYPE_VARIANT, "a{say}", &variant_iter));
+ pa_dbus_append_proplist(&variant_iter, proplist);
+ pa_assert_se(dbus_message_iter_close_container(iter, &variant_iter));
+}
+
+void pa_dbus_append_proplist_variant_dict_entry(DBusMessageIter *dict_iter, const char *key, pa_proplist *proplist) {
+ DBusMessageIter dict_entry_iter;
+
+ pa_assert(dict_iter);
+ pa_assert(key);
+ pa_assert(proplist);
+
+ pa_assert_se(dbus_message_iter_open_container(dict_iter, DBUS_TYPE_DICT_ENTRY, NULL, &dict_entry_iter));
+ pa_assert_se(dbus_message_iter_append_basic(&dict_entry_iter, DBUS_TYPE_STRING, &key));
+ pa_dbus_append_proplist_variant(&dict_entry_iter, proplist);
+ pa_assert_se(dbus_message_iter_close_container(dict_iter, &dict_entry_iter));
+}
+
+pa_proplist *pa_dbus_get_proplist_arg(DBusConnection *c, DBusMessage *msg, DBusMessageIter *iter) {
+ DBusMessageIter dict_iter;
+ DBusMessageIter dict_entry_iter;
+ pa_proplist *proplist = NULL;
+ const char *key = NULL;
+ const uint8_t *value = NULL;
+ int value_length = 0;
+
+ pa_assert(c);
+ pa_assert(msg);
+ pa_assert(iter);
+ pa_assert(pa_streq(dbus_message_iter_get_signature(iter), "a{say}"));
+
+ proplist = pa_proplist_new();
+
+ dbus_message_iter_recurse(iter, &dict_iter);
+
+ while (dbus_message_iter_get_arg_type(&dict_iter) != DBUS_TYPE_INVALID) {
+ dbus_message_iter_recurse(&dict_iter, &dict_entry_iter);
+
+ dbus_message_iter_get_basic(&dict_entry_iter, &key);
+ dbus_message_iter_next(&dict_entry_iter);
+
+ if (strlen(key) <= 0 || !pa_ascii_valid(key)) {
+ pa_dbus_send_error(c, msg, DBUS_ERROR_INVALID_ARGS, "Invalid property list key: '%s'.", key);
+ goto fail;
+ }
+
+ dbus_message_iter_get_fixed_array(&dict_entry_iter, &value, &value_length);
+
+ pa_assert(value_length >= 0);
+
+ pa_assert_se(pa_proplist_set(proplist, key, value, value_length) >= 0);
+
+ dbus_message_iter_next(&dict_iter);
+ }
+
+ dbus_message_iter_next(iter);
+
+ return proplist;
+
+fail:
+ if (proplist)
+ pa_proplist_free(proplist);
+
+ return NULL;
+}
diff --git a/src/pulsecore/dbus-util.h b/src/pulsecore/dbus-util.h
index 55cda7a0..347f9f3e 100644
--- a/src/pulsecore/dbus-util.h
+++ b/src/pulsecore/dbus-util.h
@@ -24,13 +24,20 @@
#include <dbus/dbus.h>
-#include <pulsecore/llist.h>
+#include <pulse/gccmacro.h>
#include <pulse/mainloop-api.h>
+#include <pulse/proplist.h>
+
+#include <pulsecore/llist.h>
/* A wrap connection is not shared or refcounted, it is available in client side */
typedef struct pa_dbus_wrap_connection pa_dbus_wrap_connection;
-pa_dbus_wrap_connection* pa_dbus_wrap_connection_new(pa_mainloop_api *mainloop, DBusBusType type, DBusError *error);
+pa_dbus_wrap_connection* pa_dbus_wrap_connection_new(pa_mainloop_api *mainloop, pa_bool_t use_rtclock, DBusBusType type, DBusError *error);
+pa_dbus_wrap_connection* pa_dbus_wrap_connection_new_from_existing(
+ pa_mainloop_api *mainloop,
+ pa_bool_t use_rtclock,
+ DBusConnection *conn);
void pa_dbus_wrap_connection_free(pa_dbus_wrap_connection* conn);
DBusConnection* pa_dbus_wrap_connection_get(pa_dbus_wrap_connection *conn);
@@ -60,4 +67,42 @@ void pa_dbus_sync_pending_list(pa_dbus_pending **p);
/* Free up a list of pa_dbus_pending_call objects */
void pa_dbus_free_pending_list(pa_dbus_pending **p);
+/* Sends an error message as the reply to the given message. */
+void pa_dbus_send_error(
+ DBusConnection *c,
+ DBusMessage *in_reply_to,
+ const char *name,
+ const char *format, ...) PA_GCC_PRINTF_ATTR(4, 5);
+
+void pa_dbus_send_empty_reply(DBusConnection *c, DBusMessage *in_reply_to);
+void pa_dbus_send_basic_value_reply(DBusConnection *c, DBusMessage *in_reply_to, int type, void *data);
+void pa_dbus_send_basic_variant_reply(DBusConnection *c, DBusMessage *in_reply_to, int type, void *data);
+void pa_dbus_send_basic_array_variant_reply(
+ DBusConnection *c,
+ DBusMessage *in_reply_to,
+ int item_type,
+ void *array,
+ unsigned n);
+void pa_dbus_send_proplist_variant_reply(DBusConnection *c, DBusMessage *in_reply_to, pa_proplist *proplist);
+
+void pa_dbus_append_basic_array(DBusMessageIter *iter, int item_type, const void *array, unsigned n);
+void pa_dbus_append_basic_array_variant(DBusMessageIter *iter, int item_type, const void *array, unsigned n);
+void pa_dbus_append_basic_variant(DBusMessageIter *iter, int type, void *data);
+void pa_dbus_append_basic_variant_dict_entry(DBusMessageIter *dict_iter, const char *key, int type, void *data);
+void pa_dbus_append_basic_array_variant_dict_entry(
+ DBusMessageIter *dict_iter,
+ const char *key,
+ int item_type,
+ const void *array,
+ unsigned n);
+void pa_dbus_append_proplist(DBusMessageIter *iter, pa_proplist *proplist);
+void pa_dbus_append_proplist_variant(DBusMessageIter *iter, pa_proplist *proplist);
+void pa_dbus_append_proplist_variant_dict_entry(DBusMessageIter *dict_iter, const char *key, pa_proplist *proplist);
+
+/* Returns a new proplist that the caller has to free. If the proplist contains
+ * invalid keys, an error reply is sent and NULL is returned. The iterator must
+ * point to "a{say}" element. This function calls dbus_message_iter_next(iter)
+ * before returning. */
+pa_proplist *pa_dbus_get_proplist_arg(DBusConnection *c, DBusMessage *msg, DBusMessageIter *iter);
+
#endif
diff --git a/src/pulsecore/dllmain.c b/src/pulsecore/dllmain.c
index 491ec75f..d2de73d9 100644
--- a/src/pulsecore/dllmain.c
+++ b/src/pulsecore/dllmain.c
@@ -27,11 +27,11 @@
#include <stdlib.h>
#include <stdio.h>
-#include <string.h>
#include <windows.h>
+#include <winsock2.h>
-extern pa_set_root(HANDLE handle);
+extern char *pa_win32_get_toplevel(HANDLE handle);
BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) {
WSADATA data;
@@ -39,7 +39,7 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) {
switch (fdwReason) {
case DLL_PROCESS_ATTACH:
- if (!pa_set_root(hinstDLL))
+ if (!pa_win32_get_toplevel(hinstDLL))
return FALSE;
WSAStartup(MAKEWORD(2, 0), &data);
break;
diff --git a/src/pulsecore/envelope.c b/src/pulsecore/envelope.c
deleted file mode 100644
index fd6a9487..00000000
--- a/src/pulsecore/envelope.c
+++ /dev/null
@@ -1,786 +0,0 @@
-/***
- This file is part of PulseAudio.
-
- Copyright 2007 Lennart Poettering
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of the
- License, or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdio.h>
-
-#include <pulse/sample.h>
-#include <pulse/xmalloc.h>
-
-#include <pulsecore/endianmacros.h>
-#include <pulsecore/memchunk.h>
-#include <pulsecore/macro.h>
-#include <pulsecore/flist.h>
-#include <pulsecore/semaphore.h>
-#include <pulsecore/g711.h>
-
-#include "envelope.h"
-
-/*
- Envelope subsystem for applying linear interpolated volume
- envelopes on audio data. If multiple enevelopes shall be applied
- at the same time, the "minimum" envelope is determined and
- applied.
-
- Envelopes are defined in a statically allocated constant structure
- pa_envelope_def. It may be activated using pa_envelope_add(). And
- already active envelope may be replaced with pa_envelope_replace()
- and removed with pa_envelope_remove().The combined "minimum"
- envelope can be applied to audio data with pa_envelope_apply().
-
- _apply() on one hand and _add()/_replace()/_remove() on the other
- can be executed in seperate threads, in which case no locking is
- used.
-*/
-
-PA_STATIC_FLIST_DECLARE(items, 0, pa_xfree);
-
-struct pa_envelope_item {
- PA_LLIST_FIELDS(pa_envelope_item);
- const pa_envelope_def *def;
- pa_usec_t start_x;
- union {
- int32_t i;
- float f;
- } start_y;
- unsigned j;
-};
-
-enum envelope_state {
- STATE_VALID0,
- STATE_VALID1,
- STATE_READ0,
- STATE_READ1,
- STATE_WAIT0,
- STATE_WAIT1,
- STATE_WRITE0,
- STATE_WRITE1
-};
-
-struct pa_envelope {
- pa_sample_spec sample_spec;
-
- PA_LLIST_HEAD(pa_envelope_item, items);
-
- pa_atomic_t state;
-
- size_t x;
-
- struct {
- unsigned n_points, n_allocated, n_current;
-
- size_t *x;
- union {
- int32_t *i;
- float *f;
- } y;
-
- size_t cached_dx;
- int32_t cached_dy_i;
- float cached_dy_dx;
- pa_bool_t cached_valid;
- } points[2];
-
- pa_bool_t is_float;
-
- pa_semaphore *semaphore;
-};
-
-pa_envelope *pa_envelope_new(const pa_sample_spec *ss) {
- pa_envelope *e;
- pa_assert(ss);
-
- e = pa_xnew(pa_envelope, 1);
-
- e->sample_spec = *ss;
- PA_LLIST_HEAD_INIT(pa_envelope_item, e->items);
-
- e->x = 0;
-
- e->points[0].n_points = e->points[1].n_points = 0;
- e->points[0].n_allocated = e->points[1].n_allocated = 0;
- e->points[0].n_current = e->points[1].n_current = 0;
- e->points[0].x = e->points[1].x = NULL;
- e->points[0].y.i = e->points[1].y.i = NULL;
- e->points[0].cached_valid = e->points[1].cached_valid = FALSE;
-
- pa_atomic_store(&e->state, STATE_VALID0);
-
- e->is_float =
- ss->format == PA_SAMPLE_FLOAT32LE ||
- ss->format == PA_SAMPLE_FLOAT32BE;
-
- e->semaphore = pa_semaphore_new(0);
-
- return e;
-}
-
-void pa_envelope_free(pa_envelope *e) {
- pa_assert(e);
-
- while (e->items)
- pa_envelope_remove(e, e->items);
-
- pa_xfree(e->points[0].x);
- pa_xfree(e->points[1].x);
- pa_xfree(e->points[0].y.i);
- pa_xfree(e->points[1].y.i);
-
- pa_semaphore_free(e->semaphore);
-
- pa_xfree(e);
-}
-
-static int32_t linear_interpolate_int(pa_usec_t x1, int32_t _y1, pa_usec_t x2, int32_t y2, pa_usec_t x3) {
- return (int32_t) ((double) _y1 + (double) (x3 - x1) * (double) (y2 - _y1) / (double) (x2 - x1));
-}
-
-static float linear_interpolate_float(pa_usec_t x1, float _y1, pa_usec_t x2, float y2, pa_usec_t x3) {
- return _y1 + ((float) x3 - (float) x1) * (y2 - _y1) / ((float) x2 - (float) x1);
-}
-
-static int32_t item_get_int(pa_envelope_item *i, pa_usec_t x) {
- pa_assert(i);
-
- if (x <= i->start_x)
- return i->start_y.i;
-
- x -= i->start_x;
-
- if (x <= i->def->points_x[0])
- return linear_interpolate_int(0, i->start_y.i,
- i->def->points_x[0], i->def->points_y.i[0], x);
-
- if (x >= i->def->points_x[i->def->n_points-1])
- return i->def->points_y.i[i->def->n_points-1];
-
- pa_assert(i->j > 0);
- pa_assert(i->def->points_x[i->j-1] <= x);
- pa_assert(x < i->def->points_x[i->j]);
-
- return linear_interpolate_int(i->def->points_x[i->j-1], i->def->points_y.i[i->j-1],
- i->def->points_x[i->j], i->def->points_y.i[i->j], x);
-}
-
-static float item_get_float(pa_envelope_item *i, pa_usec_t x) {
- pa_assert(i);
-
- if (x <= i->start_x)
- return i->start_y.f;
-
- x -= i->start_x;
-
- if (x <= i->def->points_x[0])
- return linear_interpolate_float(0, i->start_y.f,
- i->def->points_x[0], i->def->points_y.f[0], x);
-
- if (x >= i->def->points_x[i->def->n_points-1])
- return i->def->points_y.f[i->def->n_points-1];
-
- pa_assert(i->j > 0);
- pa_assert(i->def->points_x[i->j-1] <= x);
- pa_assert(x < i->def->points_x[i->j]);
-
- return linear_interpolate_float(i->def->points_x[i->j-1], i->def->points_y.f[i->j-1],
- i->def->points_x[i->j], i->def->points_y.f[i->j], x);
-}
-
-static void envelope_begin_write(pa_envelope *e, int *v) {
- enum envelope_state new_state, old_state;
- pa_bool_t wait_sem;
-
- pa_assert(e);
- pa_assert(v);
-
- for (;;) {
- do {
- wait_sem = FALSE;
- old_state = pa_atomic_load(&e->state);
-
- switch (old_state) {
- case STATE_VALID0:
- *v = 1;
- new_state = STATE_WRITE0;
- break;
- case STATE_VALID1:
- *v = 0;
- new_state = STATE_WRITE1;
- break;
- case STATE_READ0:
- new_state = STATE_WAIT0;
- wait_sem = TRUE;
- break;
- case STATE_READ1:
- new_state = STATE_WAIT1;
- wait_sem = TRUE;
- break;
- default:
- pa_assert_not_reached();
- }
- } while (!pa_atomic_cmpxchg(&e->state, old_state, new_state));
-
- if (!wait_sem)
- break;
-
- pa_semaphore_wait(e->semaphore);
- }
-}
-
-static pa_bool_t envelope_commit_write(pa_envelope *e, int v) {
- enum envelope_state new_state, old_state;
-
- pa_assert(e);
-
- do {
- old_state = pa_atomic_load(&e->state);
-
- switch (old_state) {
- case STATE_WRITE0:
- pa_assert(v == 1);
- new_state = STATE_VALID1;
- break;
- case STATE_WRITE1:
- pa_assert(v == 0);
- new_state = STATE_VALID0;
- break;
- case STATE_VALID0:
- case STATE_VALID1:
- case STATE_READ0:
- case STATE_READ1:
- return FALSE;
- default:
- pa_assert_not_reached();
- }
- } while (!pa_atomic_cmpxchg(&e->state, old_state, new_state));
-
- return TRUE;
-}
-
-static void envelope_begin_read(pa_envelope *e, int *v) {
- enum envelope_state new_state, old_state;
- pa_assert(e);
- pa_assert(v);
-
- do {
- old_state = pa_atomic_load(&e->state);
-
- switch (old_state) {
- case STATE_VALID0:
- case STATE_WRITE0:
- *v = 0;
- new_state = STATE_READ0;
- break;
- case STATE_VALID1:
- case STATE_WRITE1:
- *v = 1;
- new_state = STATE_READ1;
- break;
- default:
- pa_assert_not_reached();
- }
- } while (!pa_atomic_cmpxchg(&e->state, old_state, new_state));
-}
-
-static void envelope_commit_read(pa_envelope *e, int v) {
- enum envelope_state new_state, old_state;
- pa_bool_t post_sem;
-
- pa_assert(e);
-
- do {
- post_sem = FALSE;
- old_state = pa_atomic_load(&e->state);
-
- switch (old_state) {
- case STATE_READ0:
- pa_assert(v == 0);
- new_state = STATE_VALID0;
- break;
- case STATE_READ1:
- pa_assert(v == 1);
- new_state = STATE_VALID1;
- break;
- case STATE_WAIT0:
- pa_assert(v == 0);
- new_state = STATE_VALID0;
- post_sem = TRUE;
- break;
- case STATE_WAIT1:
- pa_assert(v == 1);
- new_state = STATE_VALID1;
- post_sem = TRUE;
- break;
- default:
- pa_assert_not_reached();
- }
- } while (!pa_atomic_cmpxchg(&e->state, old_state, new_state));
-
- if (post_sem)
- pa_semaphore_post(e->semaphore);
-}
-
-static void envelope_merge(pa_envelope *e, int v) {
-
- e->points[v].n_points = 0;
-
- if (e->items) {
- pa_envelope_item *i;
- pa_usec_t x = (pa_usec_t) -1;
-
- for (i = e->items; i; i = i->next)
- i->j = 0;
-
- for (;;) {
- pa_bool_t min_is_set;
- pa_envelope_item *s = NULL;
-
- /* Let's find the next spot on the X axis to analyze */
- for (i = e->items; i; i = i->next) {
-
- for (;;) {
-
- if (i->j >= i->def->n_points)
- break;
-
- if ((x != (pa_usec_t) -1) && i->start_x + i->def->points_x[i->j] <= x) {
- i->j++;
- continue;
- }
-
- if (!s || (i->start_x + i->def->points_x[i->j] < s->start_x + s->def->points_x[s->j]))
- s = i;
-
- break;
- }
- }
-
- if (!s)
- break;
-
- if (e->points[v].n_points >= e->points[v].n_allocated) {
- e->points[v].n_allocated = PA_MAX(e->points[v].n_points*2, PA_ENVELOPE_POINTS_MAX);
-
- e->points[v].x = pa_xrealloc(e->points[v].x, sizeof(size_t) * e->points[v].n_allocated);
- e->points[v].y.i = pa_xrealloc(e->points[v].y.i, sizeof(int32_t) * e->points[v].n_allocated);
- }
-
- x = s->start_x + s->def->points_x[s->j];
- e->points[v].x[e->points[v].n_points] = pa_usec_to_bytes(x, &e->sample_spec);
-
- min_is_set = FALSE;
-
- /* Now let's find the lowest value */
- if (e->is_float) {
- float min_f;
-
- for (i = e->items; i; i = i->next) {
- float f = item_get_float(i, x);
- if (!min_is_set || f < min_f) {
- min_f = f;
- min_is_set = TRUE;
- }
- }
-
- e->points[v].y.f[e->points[v].n_points] = min_f;
- } else {
- int32_t min_k;
-
- for (i = e->items; i; i = i->next) {
- int32_t k = item_get_int(i, x);
- if (!min_is_set || k < min_k) {
- min_k = k;
- min_is_set = TRUE;
- }
- }
-
- e->points[v].y.i[e->points[v].n_points] = min_k;
- }
-
- pa_assert_se(min_is_set);
- e->points[v].n_points++;
- }
- }
-
- e->points[v].n_current = 0;
- e->points[v].cached_valid = FALSE;
-}
-
-pa_envelope_item *pa_envelope_add(pa_envelope *e, const pa_envelope_def *def) {
- pa_envelope_item *i;
- int v;
-
- pa_assert(e);
- pa_assert(def);
- pa_assert(def->n_points > 0);
-
- if (!(i = pa_flist_pop(PA_STATIC_FLIST_GET(items))))
- i = pa_xnew(pa_envelope_item, 1);
-
- i->def = def;
-
- if (e->is_float)
- i->start_y.f = def->points_y.f[0];
- else
- i->start_y.i = def->points_y.i[0];
-
- PA_LLIST_PREPEND(pa_envelope_item, e->items, i);
-
- envelope_begin_write(e, &v);
-
- do {
-
- i->start_x = pa_bytes_to_usec(e->x, &e->sample_spec);
- envelope_merge(e, v);
-
- } while (!envelope_commit_write(e, v));
-
- return i;
-}
-
-pa_envelope_item *pa_envelope_replace(pa_envelope *e, pa_envelope_item *i, const pa_envelope_def *def) {
- pa_usec_t x;
- int v;
-
- pa_assert(e);
- pa_assert(i);
- pa_assert(def->n_points > 0);
-
- envelope_begin_write(e, &v);
-
- for (;;) {
- float saved_f;
- int32_t saved_i;
- uint64_t saved_start_x;
- const pa_envelope_def *saved_def;
-
- x = pa_bytes_to_usec(e->x, &e->sample_spec);
-
- if (e->is_float) {
- saved_f = i->start_y.f;
- i->start_y.f = item_get_float(i, x);
- } else {
- saved_i = i->start_y.i;
- i->start_y.i = item_get_int(i, x);
- }
-
- saved_start_x = i->start_x;
- saved_def = i->def;
-
- i->start_x = x;
- i->def = def;
-
- envelope_merge(e, v);
-
- if (envelope_commit_write(e, v))
- break;
-
- i->start_x = saved_start_x;
- i->def = saved_def;
-
- if (e->is_float)
- i->start_y.f = saved_f;
- else
- i->start_y.i = saved_i;
- }
-
- return i;
-}
-
-void pa_envelope_remove(pa_envelope *e, pa_envelope_item *i) {
- int v;
-
- pa_assert(e);
- pa_assert(i);
-
- PA_LLIST_REMOVE(pa_envelope_item, e->items, i);
-
- if (pa_flist_push(PA_STATIC_FLIST_GET(items), i) < 0)
- pa_xfree(i);
-
- envelope_begin_write(e, &v);
- do {
- envelope_merge(e, v);
- } while (!envelope_commit_write(e, v));
-}
-
-static int32_t linear_get_int(pa_envelope *e, int v) {
- pa_assert(e);
-
- /* The repeated division could be replaced by Bresenham, as an
- * optimization */
-
- if (e->x < e->points[v].x[0])
- return e->points[v].y.i[0];
-
- for (;;) {
- if (e->points[v].n_current+1 >= e->points[v].n_points)
- return e->points[v].y.i[e->points[v].n_points-1];
-
- if (e->x < e->points[v].x[e->points[v].n_current+1])
- break;
-
- e->points[v].n_current++;
- e->points[v].cached_valid = FALSE;
- }
-
- if (!e->points[v].cached_valid) {
- e->points[v].cached_dx = e->points[v].x[e->points[v].n_current+1] - e->points[v].x[e->points[v].n_current];
- e->points[v].cached_dy_i = e->points[v].y.i[e->points[v].n_current+1] - e->points[v].y.i[e->points[v].n_current];
- e->points[v].cached_valid = TRUE;
- }
-
- return e->points[v].y.i[e->points[v].n_current] + (e->points[v].cached_dy_i * (int32_t) (e->x - e->points[v].x[e->points[v].n_current])) / (int32_t) e->points[v].cached_dx;
-}
-
-static float linear_get_float(pa_envelope *e, int v) {
- pa_assert(e);
-
- if (e->x < e->points[v].x[0])
- return e->points[v].y.f[0];
-
- for (;;) {
- if (e->points[v].n_current+1 >= e->points[v].n_points)
- return e->points[v].y.f[e->points[v].n_points-1];
-
- if (e->x < e->points[v].x[e->points[v].n_current+1])
- break;
-
- e->points[v].n_current++;
- e->points[v].cached_valid = FALSE;
- }
-
- if (!e->points[v].cached_valid) {
- e->points[v].cached_dy_dx =
- (e->points[v].y.f[e->points[v].n_current+1] - e->points[v].y.f[e->points[v].n_current]) /
- ((float) e->points[v].x[e->points[v].n_current+1] - (float) e->points[v].x[e->points[v].n_current]);
- e->points[v].cached_valid = TRUE;
- }
-
- return e->points[v].y.f[e->points[v].n_current] + (float) (e->x - e->points[v].x[e->points[v].n_current]) * e->points[v].cached_dy_dx;
-}
-
-void pa_envelope_apply(pa_envelope *e, pa_memchunk *chunk) {
- int v;
-
- pa_assert(e);
- pa_assert(chunk);
-
- envelope_begin_read(e, &v);
-
- if (e->points[v].n_points > 0) {
- void *p;
- size_t fs, n;
-
- pa_memchunk_make_writable(chunk, 0);
- p = (uint8_t*) pa_memblock_acquire(chunk->memblock) + chunk->index;
- fs = pa_frame_size(&e->sample_spec);
- n = chunk->length;
-
- switch (e->sample_spec.format) {
-
- case PA_SAMPLE_U8: {
- uint8_t *t;
-
- for (t = p; n > 0; n -= fs) {
- int32_t factor = linear_get_int(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++)
- *t = (uint8_t) (((factor * ((int16_t) *t - 0x80)) / 0x10000) + 0x80);
- }
-
- break;
- }
-
- case PA_SAMPLE_ULAW: {
- uint8_t *t;
-
- for (t = p; n > 0; n -= fs) {
- int32_t factor = linear_get_int(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++) {
- int16_t k = st_ulaw2linear16(*t);
- *t = (uint8_t) st_14linear2ulaw((int16_t) (((factor * k) / 0x10000) >> 2));
- }
- }
-
- break;
- }
-
- case PA_SAMPLE_ALAW: {
- uint8_t *t;
-
- for (t = p; n > 0; n -= fs) {
- int32_t factor = linear_get_int(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++) {
- int16_t k = st_alaw2linear16(*t);
- *t = (uint8_t) st_13linear2alaw((int16_t) (((factor * k) / 0x10000) >> 3));
- }
- }
-
- break;
- }
-
- case PA_SAMPLE_S16NE: {
- int16_t *t;
-
- for (t = p; n > 0; n -= fs) {
- int32_t factor = linear_get_int(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++)
- *t = (int16_t) ((factor * *t) / 0x10000);
- }
-
- break;
- }
-
- case PA_SAMPLE_S16RE: {
- int16_t *t;
-
- for (t = p; n > 0; n -= fs) {
- int32_t factor = linear_get_int(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++) {
- int16_t r = (int16_t) ((factor * PA_INT16_SWAP(*t)) / 0x10000);
- *t = PA_INT16_SWAP(r);
- }
- }
-
- break;
- }
-
- case PA_SAMPLE_S32NE: {
- int32_t *t;
-
- for (t = p; n > 0; n -= fs) {
- int32_t factor = linear_get_int(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++)
- *t = (int32_t) (((int64_t) factor * (int64_t) *t) / 0x10000);
- }
-
- break;
- }
-
- case PA_SAMPLE_S32RE: {
- int32_t *t;
-
- for (t = p; n > 0; n -= fs) {
- int32_t factor = linear_get_int(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++) {
- int32_t r = (int32_t) (((int64_t) factor * (int64_t) PA_INT32_SWAP(*t)) / 0x10000);
- *t = PA_INT32_SWAP(r);
- }
- }
-
- break;
- }
-
- case PA_SAMPLE_FLOAT32NE: {
- float *t;
-
- for (t = p; n > 0; n -= fs) {
- float factor = linear_get_float(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++)
- *t = *t * factor;
- }
-
- break;
- }
-
- case PA_SAMPLE_FLOAT32RE: {
- float *t;
-
- for (t = p; n > 0; n -= fs) {
- float factor = linear_get_float(e, v);
- unsigned c;
- e->x += fs;
-
- for (c = 0; c < e->sample_spec.channels; c++, t++) {
- float r = PA_FLOAT32_SWAP(*t) * factor;
- *t = PA_FLOAT32_SWAP(r);
- }
- }
-
- break;
- }
-
- case PA_SAMPLE_S24LE:
- case PA_SAMPLE_S24BE:
- case PA_SAMPLE_S24_32LE:
- case PA_SAMPLE_S24_32BE:
- /* FIXME */
- pa_assert_not_reached();
-
- case PA_SAMPLE_MAX:
- case PA_SAMPLE_INVALID:
- pa_assert_not_reached();
- }
-
- pa_memblock_release(chunk->memblock);
-
- e->x += chunk->length;
- } else {
- /* When we have no envelope to apply we reset our origin */
- e->x = 0;
- }
-
- envelope_commit_read(e, v);
-}
-
-void pa_envelope_rewind(pa_envelope *e, size_t n_bytes) {
- int v;
-
- pa_assert(e);
-
- envelope_begin_read(e, &v);
-
- if (n_bytes < e->x)
- e->x -= n_bytes;
- else
- e->x = 0;
-
- e->points[v].n_current = 0;
- e->points[v].cached_valid = FALSE;
-
- envelope_commit_read(e, v);
-}
diff --git a/src/pulsecore/envelope.h b/src/pulsecore/envelope.h
deleted file mode 100644
index 5296415a..00000000
--- a/src/pulsecore/envelope.h
+++ /dev/null
@@ -1,53 +0,0 @@
-#ifndef foopulseenvelopehfoo
-#define foopulseenvelopehfoo
-
-/***
- This file is part of PulseAudio.
-
- Copyright 2007 Lennart Poettering
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of the
- License, or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#include <pulsecore/macro.h>
-#include <pulsecore/memchunk.h>
-
-#include <pulse/sample.h>
-
-#define PA_ENVELOPE_POINTS_MAX 4U
-
-typedef struct pa_envelope pa_envelope;
-typedef struct pa_envelope_item pa_envelope_item;
-
-typedef struct pa_envelope_def {
- unsigned n_points;
-
- pa_usec_t points_x[PA_ENVELOPE_POINTS_MAX];
- struct {
- int32_t i[PA_ENVELOPE_POINTS_MAX];
- float f[PA_ENVELOPE_POINTS_MAX];
- } points_y;
-} pa_envelope_def;
-
-pa_envelope *pa_envelope_new(const pa_sample_spec *ss);
-void pa_envelope_free(pa_envelope *e);
-pa_envelope_item *pa_envelope_add(pa_envelope *e, const pa_envelope_def *def);
-pa_envelope_item *pa_envelope_replace(pa_envelope *e, pa_envelope_item *i, const pa_envelope_def *def);
-void pa_envelope_remove(pa_envelope *e, pa_envelope_item *i);
-void pa_envelope_apply(pa_envelope *e, pa_memchunk *chunk);
-void pa_envelope_rewind(pa_envelope *e, size_t n_bytes);
-
-#endif
diff --git a/src/pulsecore/fdsem.c b/src/pulsecore/fdsem.c
index 380f34f5..14fcbd6b 100644
--- a/src/pulsecore/fdsem.c
+++ b/src/pulsecore/fdsem.c
@@ -32,9 +32,9 @@
#include <pulsecore/atomic.h>
#include <pulsecore/log.h>
-#include <pulsecore/thread.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-util.h>
+#include <pulsecore/core-error.h>
#include <pulse/xmalloc.h>
#ifndef HAVE_PIPE
@@ -62,19 +62,15 @@ pa_fdsem *pa_fdsem_new(void) {
f = pa_xmalloc(PA_ALIGN(sizeof(pa_fdsem)) + PA_ALIGN(sizeof(pa_fdsem_data)));
#ifdef HAVE_SYS_EVENTFD_H
- if ((f->efd = eventfd(0, 0)) >= 0) {
- pa_make_fd_cloexec(f->efd);
+ if ((f->efd = eventfd(0, EFD_CLOEXEC)) >= 0)
f->fds[0] = f->fds[1] = -1;
- } else
+ else
#endif
{
- if (pipe(f->fds) < 0) {
+ if (pa_pipe_cloexec(f->fds) < 0) {
pa_xfree(f);
return NULL;
}
-
- pa_make_fd_cloexec(f->fds[0]);
- pa_make_fd_cloexec(f->fds[1]);
}
f->data = (pa_fdsem_data*) ((uint8_t*) f + PA_ALIGN(sizeof(pa_fdsem)));
@@ -114,12 +110,11 @@ pa_fdsem *pa_fdsem_new_shm(pa_fdsem_data *data, int* event_fd) {
f = pa_xnew(pa_fdsem, 1);
- if ((f->efd = eventfd(0, 0)) < 0) {
+ if ((f->efd = eventfd(0, EFD_CLOEXEC)) < 0) {
pa_xfree(f);
return NULL;
}
- pa_make_fd_cloexec(f->efd);
f->fds[0] = f->fds[1] = -1;
f->data = data;
@@ -158,16 +153,26 @@ static void flush(pa_fdsem *f) {
if (f->efd >= 0) {
uint64_t u;
- if ((r = read(f->efd, &u, sizeof(u))) != sizeof(u)) {
- pa_assert(r < 0 && errno == EINTR);
+ if ((r = pa_read(f->efd, &u, sizeof(u), NULL)) != sizeof(u)) {
+
+ if (r >= 0 || errno != EINTR) {
+ pa_log_error("Invalid read from eventfd: %s", r < 0 ? pa_cstrerror(errno) : "EOF");
+ pa_assert_not_reached();
+ }
+
continue;
}
r = (ssize_t) u;
} else
#endif
- if ((r = read(f->fds[0], &x, sizeof(x))) <= 0) {
- pa_assert(r < 0 && errno == EINTR);
+ if ((r = pa_read(f->fds[0], &x, sizeof(x), NULL)) <= 0) {
+
+ if (r >= 0 || errno != EINTR) {
+ pa_log_error("Invalid read from pipe: %s", r < 0 ? pa_cstrerror(errno) : "EOF");
+ pa_assert_not_reached();
+ }
+
continue;
}
@@ -191,15 +196,23 @@ void pa_fdsem_post(pa_fdsem *f) {
if (f->efd >= 0) {
uint64_t u = 1;
- if ((r = write(f->efd, &u, sizeof(u))) != sizeof(u)) {
- pa_assert(r < 0 && errno == EINTR);
+ if ((r = pa_write(f->efd, &u, sizeof(u), NULL)) != sizeof(u)) {
+ if (r >= 0 || errno != EINTR) {
+ pa_log_error("Invalid write to eventfd: %s", r < 0 ? pa_cstrerror(errno) : "EOF");
+ pa_assert_not_reached();
+ }
+
continue;
}
} else
#endif
- if ((r = write(f->fds[1], &x, 1)) != 1) {
- pa_assert(r < 0 && errno == EINTR);
+ if ((r = pa_write(f->fds[1], &x, 1, NULL)) != 1) {
+ if (r >= 0 || errno != EINTR) {
+ pa_log_error("Invalid write to pipe: %s", r < 0 ? pa_cstrerror(errno) : "EOF");
+ pa_assert_not_reached();
+ }
+
continue;
}
@@ -227,8 +240,13 @@ void pa_fdsem_wait(pa_fdsem *f) {
if (f->efd >= 0) {
uint64_t u;
- if ((r = read(f->efd, &u, sizeof(u))) != sizeof(u)) {
- pa_assert(r < 0 && errno == EINTR);
+ if ((r = pa_read(f->efd, &u, sizeof(u), NULL)) != sizeof(u)) {
+
+ if (r >= 0 || errno != EINTR) {
+ pa_log_error("Invalid read from eventfd: %s", r < 0 ? pa_cstrerror(errno) : "EOF");
+ pa_assert_not_reached();
+ }
+
continue;
}
@@ -236,8 +254,13 @@ void pa_fdsem_wait(pa_fdsem *f) {
} else
#endif
- if ((r = read(f->fds[0], &x, sizeof(x))) <= 0) {
- pa_assert(r < 0 && errno == EINTR);
+ if ((r = pa_read(f->fds[0], &x, sizeof(x), NULL)) <= 0) {
+
+ if (r >= 0 || errno != EINTR) {
+ pa_log_error("Invalid read from pipe: %s", r < 0 ? pa_cstrerror(errno) : "EOF");
+ pa_assert_not_reached();
+ }
+
continue;
}
diff --git a/src/pulsecore/fdsem.h b/src/pulsecore/fdsem.h
index 48a77c49..90e8599a 100644
--- a/src/pulsecore/fdsem.h
+++ b/src/pulsecore/fdsem.h
@@ -23,7 +23,6 @@
***/
#include <sys/types.h>
-#include <pulse/def.h>
/* A simple, asynchronous semaphore which uses fds for sleeping. In
* the best case all functions are lock-free unless sleeping is
diff --git a/src/pulsecore/ffmpeg/Makefile b/src/pulsecore/ffmpeg/Makefile
deleted file mode 100644
index 316beb72..00000000
--- a/src/pulsecore/ffmpeg/Makefile
+++ /dev/null
@@ -1,13 +0,0 @@
-# This is a dirty trick just to ease compilation with emacs
-#
-# This file is not intended to be distributed or anything
-#
-# So: don't touch it, even better ignore it!
-
-all:
- $(MAKE) -C ../..
-
-clean:
- $(MAKE) -C ../.. clean
-
-.PHONY: all clean
diff --git a/src/pulsecore/flist.c b/src/pulsecore/flist.c
index 6fb944f9..add3aa20 100644
--- a/src/pulsecore/flist.c
+++ b/src/pulsecore/flist.c
@@ -2,6 +2,9 @@
This file is part of PulseAudio.
Copyright 2006-2008 Lennart Poettering
+ Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
+
+ Contact: Jyri Sarha <Jyri.Sarha@nokia.com>
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as
@@ -27,191 +30,121 @@
#include <pulsecore/atomic.h>
#include <pulsecore/log.h>
-#include <pulsecore/thread.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
#include "flist.h"
-/* Algorithm is not perfect, in a few corner cases it will fail to pop
- * from the flist although it isn't empty, and fail to push into the
- * flist, although it isn't full.
- *
- * We keep a fixed size array of entries, each item is an atomic
- * pointer.
- *
- * To accelerate finding of used/unused cells we maintain a read and a
- * write index which is used like a ring buffer. After each push we
- * increase the write index and after each pop we increase the read
- * index.
- *
- * The indexes are incremented atomically and are never truncated to
- * the buffer size. Instead we assume that the buffer size is a power
- * of two and that the truncation can thus be done by applying a
- * simple AND on read.
- *
- * To make sure that we do not look for empty cells indefinitely we
- * maintain a length value which stores the number of used cells. From
- * this value the number of unused cells is easily calculated. Please
- * note that the length value is not updated atomically with the read
- * and write index and might thus be a few cells off the real
- * value. To deal with this we always look for N_EXTRA_SCAN extra
- * cells when pushing/popping entries.
- *
- * It might make sense to replace this implementation with a link list
- * stack or queue, which however requires DCAS to be simple. Patches
- * welcome.
- *
- * Please note that this algorithm is home grown.*/
-
#define FLIST_SIZE 128
-#define N_EXTRA_SCAN 3
-/* For debugging purposes we can define _Y to put and extra thread
- * yield between each operation. */
+/* Lock free single linked list element. */
+struct pa_flist_elem {
+ pa_atomic_ptr_t next;
+ pa_atomic_ptr_t ptr;
+};
-#ifdef PROFILE
-#define _Y pa_thread_yield()
-#else
-#define _Y do { } while(0)
-#endif
+typedef struct pa_flist_elem pa_flist_elem;
struct pa_flist {
+ const char *name;
unsigned size;
- pa_atomic_t length;
- pa_atomic_t read_idx;
- pa_atomic_t write_idx;
+ /* Stack that contains pointers stored into free list */
+ pa_atomic_ptr_t stored;
+ /* Stack that contains empty list elements */
+ pa_atomic_ptr_t empty;
+ pa_flist_elem table[0];
};
-#define PA_FLIST_CELLS(x) ((pa_atomic_ptr_t*) ((uint8_t*) (x) + PA_ALIGN(sizeof(struct pa_flist))))
+/* Lock free pop from linked list stack */
+static pa_flist_elem *stack_pop(pa_atomic_ptr_t *list) {
+ pa_flist_elem *poped;
+ pa_assert(list);
-pa_flist *pa_flist_new(unsigned size) {
+ do {
+ poped = (pa_flist_elem *) pa_atomic_ptr_load(list);
+ } while (poped != NULL && !pa_atomic_ptr_cmpxchg(list, poped, pa_atomic_ptr_load(&poped->next)));
+
+ return poped;
+}
+
+/* Lock free push to linked list stack */
+static void stack_push(pa_atomic_ptr_t *list, pa_flist_elem *new_elem) {
+ pa_flist_elem *next;
+ pa_assert(list);
+
+ do {
+ next = pa_atomic_ptr_load(list);
+ pa_atomic_ptr_store(&new_elem->next, next);
+ } while (!pa_atomic_ptr_cmpxchg(list, next, new_elem));
+}
+
+pa_flist *pa_flist_new_with_name(unsigned size, const char *name) {
pa_flist *l;
+ unsigned i;
+ pa_assert(name);
if (!size)
size = FLIST_SIZE;
- pa_assert(pa_is_power_of_two(size));
-
- l = pa_xmalloc0(PA_ALIGN(sizeof(pa_flist)) + (sizeof(pa_atomic_ptr_t) * size));
+ l = pa_xmalloc0(sizeof(pa_flist) + sizeof(pa_flist_elem) * size);
+ l->name = pa_xstrdup(name);
l->size = size;
-
- pa_atomic_store(&l->read_idx, 0);
- pa_atomic_store(&l->write_idx, 0);
- pa_atomic_store(&l->length, 0);
-
+ pa_atomic_ptr_store(&l->stored, NULL);
+ pa_atomic_ptr_store(&l->empty, NULL);
+ for (i=0; i < size; i++) {
+ stack_push(&l->empty, &l->table[i]);
+ }
return l;
}
-static unsigned reduce(pa_flist *l, unsigned value) {
- return value & (l->size - 1);
+pa_flist *pa_flist_new(unsigned size) {
+ return pa_flist_new_with_name(size, "unknown");
}
void pa_flist_free(pa_flist *l, pa_free_cb_t free_cb) {
pa_assert(l);
+ pa_assert(l->name);
if (free_cb) {
- pa_atomic_ptr_t*cells;
- unsigned idx;
-
- cells = PA_FLIST_CELLS(l);
-
- for (idx = 0; idx < l->size; idx ++) {
- void *p;
-
- if ((p = pa_atomic_ptr_load(&cells[idx])))
- free_cb(p);
- }
+ pa_flist_elem *elem;
+ while((elem = stack_pop(&l->stored)))
+ free_cb(pa_atomic_ptr_load(&elem->ptr));
}
pa_xfree(l);
}
-int pa_flist_push(pa_flist*l, void *p) {
- unsigned idx, n, len;
- pa_atomic_ptr_t*cells;
-
+int pa_flist_push(pa_flist *l, void *p) {
+ pa_flist_elem *elem;
pa_assert(l);
pa_assert(p);
- cells = PA_FLIST_CELLS(l);
-
- n = len = l->size + N_EXTRA_SCAN - (unsigned) pa_atomic_load(&l->length);
-
- _Y;
- idx = reduce(l, (unsigned) pa_atomic_load(&l->write_idx));
-
- for (; n > 0 ; n--) {
-
- _Y;
-
- if (pa_atomic_ptr_cmpxchg(&cells[idx], NULL, p)) {
-
- _Y;
- pa_atomic_inc(&l->write_idx);
-
- _Y;
- pa_atomic_inc(&l->length);
-
- return 0;
- }
-
- _Y;
- idx = reduce(l, idx + 1);
+ elem = stack_pop(&l->empty);
+ if (elem == NULL) {
+ if (pa_log_ratelimit(PA_LOG_DEBUG))
+ pa_log_debug("%s flist is full (don't worry)", l->name);
+ return -1;
}
+ pa_atomic_ptr_store(&elem->ptr, p);
+ stack_push(&l->stored, elem);
-#ifdef PROFILE
- if (len > N_EXTRA_SCAN)
- pa_log_warn("Didn't find free cell after %u iterations.", len);
-#endif
-
- return -1;
+ return 0;
}
-void* pa_flist_pop(pa_flist*l) {
- unsigned idx, len, n;
- pa_atomic_ptr_t *cells;
-
+void* pa_flist_pop(pa_flist *l) {
+ pa_flist_elem *elem;
+ void *ptr;
pa_assert(l);
- cells = PA_FLIST_CELLS(l);
-
- n = len = (unsigned) pa_atomic_load(&l->length) + N_EXTRA_SCAN;
+ elem = stack_pop(&l->stored);
+ if (elem == NULL)
+ return NULL;
- _Y;
- idx = reduce(l, (unsigned) pa_atomic_load(&l->read_idx));
+ ptr = pa_atomic_ptr_load(&elem->ptr);
- for (; n > 0 ; n--) {
- void *p;
-
- _Y;
- p = pa_atomic_ptr_load(&cells[idx]);
-
- if (p) {
-
- _Y;
- if (!pa_atomic_ptr_cmpxchg(&cells[idx], p, NULL))
- continue;
-
- _Y;
- pa_atomic_inc(&l->read_idx);
-
- _Y;
- pa_atomic_dec(&l->length);
-
- return p;
- }
-
- _Y;
- idx = reduce(l, idx+1);
- }
-
-#ifdef PROFILE
- if (len > N_EXTRA_SCAN)
- pa_log_warn("Didn't find used cell after %u iterations.", len);
-#endif
+ stack_push(&l->empty, elem);
- return NULL;
+ return ptr;
}
diff --git a/src/pulsecore/flist.h b/src/pulsecore/flist.h
index e147486e..915b1135 100644
--- a/src/pulsecore/flist.h
+++ b/src/pulsecore/flist.h
@@ -32,8 +32,10 @@
typedef struct pa_flist pa_flist;
-/* Size is required to be a power of two, or 0 for the default size */
pa_flist * pa_flist_new(unsigned size);
+/* Name string is copied and added to flist structure. The original is
+ * responsibility of the caller. The name is only used for debug printing. */
+pa_flist * pa_flist_new_with_name(unsigned size, const char *name);
void pa_flist_free(pa_flist *l, pa_free_cb_t free_cb);
/* Please note that this routine might fail! */
@@ -45,11 +47,12 @@ void* pa_flist_pop(pa_flist*l);
#define PA_STATIC_FLIST_DECLARE(name, size, free_cb) \
static struct { \
- pa_flist *flist; \
+ pa_flist *volatile flist; \
pa_once once; \
} name##_flist = { NULL, PA_ONCE_INIT }; \
static void name##_flist_init(void) { \
- name##_flist.flist = pa_flist_new(size); \
+ name##_flist.flist = \
+ pa_flist_new_with_name(size, __FILE__ ": " #name); \
} \
static inline pa_flist* name##_flist_get(void) { \
pa_run_once(&name##_flist.once, name##_flist_init); \
diff --git a/src/pulsecore/hashmap.c b/src/pulsecore/hashmap.c
index e957c5ba..e368512b 100644
--- a/src/pulsecore/hashmap.c
+++ b/src/pulsecore/hashmap.c
@@ -24,11 +24,9 @@
#endif
#include <stdlib.h>
-#include <string.h>
#include <pulse/xmalloc.h>
#include <pulsecore/idxset.h>
-#include <pulsecore/log.h>
#include <pulsecore/flist.h>
#include <pulsecore/macro.h>
@@ -237,6 +235,39 @@ at_end:
return NULL;
}
+void *pa_hashmap_iterate_backwards(pa_hashmap *h, void **state, const void **key) {
+ struct hashmap_entry *e;
+
+ pa_assert(h);
+ pa_assert(state);
+
+ if (*state == (void*) -1)
+ goto at_beginning;
+
+ if (!*state && !h->iterate_list_tail)
+ goto at_beginning;
+
+ e = *state ? *state : h->iterate_list_tail;
+
+ if (e->iterate_previous)
+ *state = e->iterate_previous;
+ else
+ *state = (void*) -1;
+
+ if (key)
+ *key = e->key;
+
+ return e->value;
+
+at_beginning:
+ *state = (void *) -1;
+
+ if (key)
+ *key = NULL;
+
+ return NULL;
+}
+
void* pa_hashmap_first(pa_hashmap *h) {
pa_assert(h);
@@ -246,6 +277,15 @@ void* pa_hashmap_first(pa_hashmap *h) {
return h->iterate_list_head->value;
}
+void* pa_hashmap_last(pa_hashmap *h) {
+ pa_assert(h);
+
+ if (!h->iterate_list_tail)
+ return NULL;
+
+ return h->iterate_list_tail->value;
+}
+
void* pa_hashmap_steal_first(pa_hashmap *h) {
void *data;
diff --git a/src/pulsecore/hashmap.h b/src/pulsecore/hashmap.h
index 08e18ead..ac2092a6 100644
--- a/src/pulsecore/hashmap.h
+++ b/src/pulsecore/hashmap.h
@@ -26,7 +26,8 @@
/* Simple Implementation of a hash table. Memory management is the
* user's job. It's a good idea to have the key pointer point to a
- * string in the value data. */
+ * string in the value data. The insertion order is preserved when
+ * iterating. */
typedef struct pa_hashmap pa_hashmap;
@@ -59,10 +60,24 @@ pa_bool_t pa_hashmap_isempty(pa_hashmap *h);
returned. */
void *pa_hashmap_iterate(pa_hashmap *h, void **state, const void**key);
+/* Same as pa_hashmap_iterate() but goes backwards */
+void *pa_hashmap_iterate_backwards(pa_hashmap *h, void **state, const void**key);
+
/* Remove the oldest entry in the hashmap and return it */
void *pa_hashmap_steal_first(pa_hashmap *h);
/* Return the oldest entry in the hashmap */
void* pa_hashmap_first(pa_hashmap *h);
+/* Return the newest entry in the hashmap */
+void* pa_hashmap_last(pa_hashmap *h);
+
+/* A macro to ease iteration through all entries */
+#define PA_HASHMAP_FOREACH(e, h, state) \
+ for ((state) = NULL, (e) = pa_hashmap_iterate((h), &(state), NULL); (e); (e) = pa_hashmap_iterate((h), &(state), NULL))
+
+/* A macro to ease iteration through all entries, backwards */
+#define PA_HASHMAP_FOREACH_BACKWARDS(e, h, state) \
+ for ((state) = NULL, (e) = pa_hashmap_iterate_backwards((h), &(state), NULL); (e); (e) = pa_hashmap_iterate_backwards((h), &(state), NULL))
+
#endif
diff --git a/src/pulsecore/hook-list.c b/src/pulsecore/hook-list.c
index a00116d1..00981be3 100644
--- a/src/pulsecore/hook-list.c
+++ b/src/pulsecore/hook-list.c
@@ -23,6 +23,8 @@
#include <config.h>
#endif
+#include <pulse/xmalloc.h>
+
#include <pulsecore/macro.h>
#include "hook-list.h"
@@ -97,7 +99,7 @@ pa_hook_result_t pa_hook_fire(pa_hook *hook, void *data) {
hook->n_firing ++;
- for (slot = hook->slots; slot; slot = slot->next) {
+ PA_LLIST_FOREACH(slot, hook->slots) {
if (slot->dead)
continue;
diff --git a/src/pulsecore/hook-list.h b/src/pulsecore/hook-list.h
index 86ce9d25..e4b70d3c 100644
--- a/src/pulsecore/hook-list.h
+++ b/src/pulsecore/hook-list.h
@@ -22,9 +22,6 @@
USA.
***/
-#include <pulse/xmalloc.h>
-#include <pulse/gccmacro.h>
-
#include <pulsecore/llist.h>
typedef struct pa_hook_slot pa_hook_slot;
diff --git a/src/pulsecore/idxset.c b/src/pulsecore/idxset.c
index 352ac977..2b6af90b 100644
--- a/src/pulsecore/idxset.c
+++ b/src/pulsecore/idxset.c
@@ -29,7 +29,6 @@
#include <string.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/log.h>
#include <pulsecore/flist.h>
#include <pulsecore/macro.h>
@@ -453,3 +452,17 @@ pa_bool_t pa_idxset_isempty(pa_idxset *s) {
return s->n_entries == 0;
}
+
+pa_idxset *pa_idxset_copy(pa_idxset *s) {
+ pa_idxset *copy;
+ struct idxset_entry *i;
+
+ pa_assert(s);
+
+ copy = pa_idxset_new(s->hash_func, s->compare_func);
+
+ for (i = s->iterate_list_head; i; i = i->iterate_next)
+ pa_idxset_put(copy, i->data, NULL);
+
+ return copy;
+}
diff --git a/src/pulsecore/idxset.h b/src/pulsecore/idxset.h
index 6b9ff472..2d01fb47 100644
--- a/src/pulsecore/idxset.h
+++ b/src/pulsecore/idxset.h
@@ -65,7 +65,7 @@ int pa_idxset_put(pa_idxset*s, void *p, uint32_t *idx);
/* Get the entry by its idx */
void* pa_idxset_get_by_index(pa_idxset*s, uint32_t idx);
-/* Get the entry by its data. The idx is returned in *index */
+/* Get the entry by its data. The index is returned in *idx */
void* pa_idxset_get_by_data(pa_idxset*s, const void *p, uint32_t *idx);
/* Similar to pa_idxset_get_by_index(), but removes the entry from the idxset. */
@@ -103,7 +103,10 @@ unsigned pa_idxset_size(pa_idxset*s);
/* Return TRUE of the idxset is empty */
pa_bool_t pa_idxset_isempty(pa_idxset *s);
+/* Duplicate the idxset. This will not copy the actual indexes */
+pa_idxset *pa_idxset_copy(pa_idxset *s);
+/* A macro to ease iteration through all entries */
#define PA_IDXSET_FOREACH(e, s, idx) \
for ((e) = pa_idxset_first((s), &(idx)); (e); (e) = pa_idxset_next((s), &(idx)))
diff --git a/src/pulsecore/inet_ntop.h b/src/pulsecore/inet_ntop.h
deleted file mode 100644
index 7fb67b44..00000000
--- a/src/pulsecore/inet_ntop.h
+++ /dev/null
@@ -1,12 +0,0 @@
-#ifndef fooinet_ntophfoo
-#define fooinet_ntophfoo
-
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-
-#include "winsock.h"
-
-const char *inet_ntop(int af, const void *src, char *dst, socklen_t cnt);
-
-#endif
diff --git a/src/pulsecore/inet_pton.c b/src/pulsecore/inet_pton.c
deleted file mode 100644
index abdfa467..00000000
--- a/src/pulsecore/inet_pton.c
+++ /dev/null
@@ -1,65 +0,0 @@
-/***
- This file is part of PulseAudio.
-
- Copyright 2006 Pierre Ossman <ossman@cendio.se> for Cendio AB
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of the
- License, or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdio.h>
-#include <errno.h>
-
-#ifndef HAVE_INET_PTON
-
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-
-#include "winsock.h"
-
-#include "inet_pton.h"
-
-int inet_pton(int af, const char *src, void *dst) {
- struct in_addr *in = (struct in_addr*)dst;
-#ifdef HAVE_IPV6
- struct in6_addr *in6 = (struct in6_addr*)dst;
-#endif
-
- assert(src && dst);
-
- switch (af) {
- case AF_INET:
- in->s_addr = inet_addr(src);
- if (in->s_addr == INADDR_NONE)
- return 0;
- break;
-#ifdef HAVE_IPV6
- case AF_INET6:
- /* FIXME */
-#endif
- default:
- errno = EAFNOSUPPORT;
- return -1;
- }
-
- return 1;
-}
-
-#endif /* INET_PTON */
diff --git a/src/pulsecore/inet_pton.h b/src/pulsecore/inet_pton.h
deleted file mode 100644
index 111b4a07..00000000
--- a/src/pulsecore/inet_pton.h
+++ /dev/null
@@ -1,12 +0,0 @@
-#ifndef fooinet_ptonhfoo
-#define fooinet_ptonhfoo
-
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-
-#include "winsock.h"
-
-int inet_pton(int af, const char *src, void *dst);
-
-#endif
diff --git a/src/pulsecore/iochannel.c b/src/pulsecore/iochannel.c
index b40c9815..4b0fb3a5 100644
--- a/src/pulsecore/iochannel.c
+++ b/src/pulsecore/iochannel.c
@@ -25,23 +25,18 @@
#endif
#include <stdlib.h>
-#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
#ifdef HAVE_SYS_UN_H
#include <sys/un.h>
#endif
-#include "winsock.h"
-
#include <pulse/xmalloc.h>
#include <pulsecore/core-error.h>
#include <pulsecore/core-util.h>
+#include <pulsecore/socket.h>
#include <pulsecore/socket-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
@@ -56,33 +51,79 @@ struct pa_iochannel {
pa_iochannel_cb_t callback;
void*userdata;
- pa_bool_t readable;
- pa_bool_t writable;
- pa_bool_t hungup;
-
- pa_bool_t no_close;
+ pa_bool_t readable:1;
+ pa_bool_t writable:1;
+ pa_bool_t hungup:1;
+ pa_bool_t no_close:1;
pa_io_event* input_event, *output_event;
};
-static void enable_mainloop_sources(pa_iochannel *io) {
+static void callback(pa_mainloop_api* m, pa_io_event *e, int fd, pa_io_event_flags_t f, void *userdata);
+
+static void delete_events(pa_iochannel *io) {
+ pa_assert(io);
+
+ if (io->input_event)
+ io->mainloop->io_free(io->input_event);
+
+ if (io->output_event && io->output_event != io->input_event)
+ io->mainloop->io_free(io->output_event);
+
+ io->input_event = io->output_event = NULL;
+}
+
+static void enable_events(pa_iochannel *io) {
pa_assert(io);
- if (io->input_event == io->output_event && io->input_event) {
+ if (io->hungup) {
+ delete_events(io);
+ return;
+ }
+
+ if (io->ifd == io->ofd && io->ifd >= 0) {
pa_io_event_flags_t f = PA_IO_EVENT_NULL;
- pa_assert(io->input_event);
if (!io->readable)
f |= PA_IO_EVENT_INPUT;
if (!io->writable)
f |= PA_IO_EVENT_OUTPUT;
- io->mainloop->io_enable(io->input_event, f);
+ pa_assert(io->input_event == io->output_event);
+
+ if (f != PA_IO_EVENT_NULL) {
+ if (io->input_event)
+ io->mainloop->io_enable(io->input_event, f);
+ else
+ io->input_event = io->output_event = io->mainloop->io_new(io->mainloop, io->ifd, f, callback, io);
+ } else
+ delete_events(io);
+
} else {
- if (io->input_event)
- io->mainloop->io_enable(io->input_event, io->readable ? PA_IO_EVENT_NULL : PA_IO_EVENT_INPUT);
- if (io->output_event)
- io->mainloop->io_enable(io->output_event, io->writable ? PA_IO_EVENT_NULL : PA_IO_EVENT_OUTPUT);
+
+ if (io->ifd >= 0) {
+ if (!io->readable) {
+ if (io->input_event)
+ io->mainloop->io_enable(io->input_event, PA_IO_EVENT_INPUT);
+ else
+ io->input_event = io->mainloop->io_new(io->mainloop, io->ifd, PA_IO_EVENT_INPUT, callback, io);
+ } else if (io->input_event) {
+ io->mainloop->io_free(io->input_event);
+ io->input_event = NULL;
+ }
+ }
+
+ if (io->ofd >= 0) {
+ if (!io->writable) {
+ if (io->output_event)
+ io->mainloop->io_enable(io->output_event, PA_IO_EVENT_OUTPUT);
+ else
+ io->output_event = io->mainloop->io_new(io->mainloop, io->ofd, PA_IO_EVENT_OUTPUT, callback, io);
+ } else if (io->input_event) {
+ io->mainloop->io_free(io->output_event);
+ io->output_event = NULL;
+ }
+ }
}
}
@@ -113,7 +154,7 @@ static void callback(pa_mainloop_api* m, pa_io_event *e, int fd, pa_io_event_fla
}
if (changed) {
- enable_mainloop_sources(io);
+ enable_events(io);
if (io->callback)
io->callback(io, io->userdata);
@@ -126,49 +167,25 @@ pa_iochannel* pa_iochannel_new(pa_mainloop_api*m, int ifd, int ofd) {
pa_assert(m);
pa_assert(ifd >= 0 || ofd >= 0);
- io = pa_xnew(pa_iochannel, 1);
+ io = pa_xnew0(pa_iochannel, 1);
io->ifd = ifd;
io->ofd = ofd;
- io->ifd_type = io->ofd_type = 0;
io->mainloop = m;
- io->userdata = NULL;
- io->callback = NULL;
- io->readable = FALSE;
- io->writable = FALSE;
- io->hungup = FALSE;
- io->no_close = FALSE;
-
- io->input_event = io->output_event = NULL;
-
- if (ifd == ofd) {
- pa_assert(ifd >= 0);
+ if (io->ifd >= 0)
pa_make_fd_nonblock(io->ifd);
- io->input_event = io->output_event = m->io_new(m, ifd, PA_IO_EVENT_INPUT|PA_IO_EVENT_OUTPUT, callback, io);
- } else {
-
- if (ifd >= 0) {
- pa_make_fd_nonblock(io->ifd);
- io->input_event = m->io_new(m, ifd, PA_IO_EVENT_INPUT, callback, io);
- }
- if (ofd >= 0) {
- pa_make_fd_nonblock(io->ofd);
- io->output_event = m->io_new(m, ofd, PA_IO_EVENT_OUTPUT, callback, io);
- }
- }
+ if (io->ofd >= 0 && io->ofd != io->ifd)
+ pa_make_fd_nonblock(io->ofd);
+ enable_events(io);
return io;
}
void pa_iochannel_free(pa_iochannel*io) {
pa_assert(io);
- if (io->input_event)
- io->mainloop->io_free(io->input_event);
-
- if (io->output_event && (io->output_event != io->input_event))
- io->mainloop->io_free(io->output_event);
+ delete_events(io);
if (!io->no_close) {
if (io->ifd >= 0)
@@ -207,8 +224,8 @@ ssize_t pa_iochannel_write(pa_iochannel*io, const void*data, size_t l) {
pa_assert(io->ofd >= 0);
if ((r = pa_write(io->ofd, data, l, &io->ofd_type)) >= 0) {
- io->writable = FALSE;
- enable_mainloop_sources(io);
+ io->writable = io->hungup = FALSE;
+ enable_events(io);
}
return r;
@@ -222,8 +239,12 @@ ssize_t pa_iochannel_read(pa_iochannel*io, void*data, size_t l) {
pa_assert(io->ifd >= 0);
if ((r = pa_read(io->ifd, data, l, &io->ifd_type)) >= 0) {
- io->readable = FALSE;
- enable_mainloop_sources(io);
+
+ /* We also reset the hangup flag here to ensure that another
+ * IO callback is triggered so that we will again call into
+ * user code */
+ io->readable = io->hungup = FALSE;
+ enable_events(io);
}
return r;
@@ -232,7 +253,12 @@ ssize_t pa_iochannel_read(pa_iochannel*io, void*data, size_t l) {
#ifdef HAVE_CREDS
pa_bool_t pa_iochannel_creds_supported(pa_iochannel *io) {
- struct sockaddr_un sa;
+ struct {
+ struct sockaddr sa;
+ struct sockaddr_un un;
+ struct sockaddr_storage storage;
+ } sa;
+
socklen_t l;
pa_assert(io);
@@ -240,11 +266,10 @@ pa_bool_t pa_iochannel_creds_supported(pa_iochannel *io) {
pa_assert(io->ofd == io->ifd);
l = sizeof(sa);
+ if (getsockname(io->ifd, &sa.sa, &l) < 0)
+ return FALSE;
- if (getsockname(io->ifd, (struct sockaddr*) &sa, &l) < 0)
- return 0;
-
- return sa.sun_family == AF_UNIX;
+ return sa.sa.sa_family == AF_UNIX;
}
int pa_iochannel_creds_enable(pa_iochannel *io) {
@@ -276,11 +301,11 @@ ssize_t pa_iochannel_write_with_creds(pa_iochannel*io, const void*data, size_t l
pa_assert(l);
pa_assert(io->ofd >= 0);
- memset(&iov, 0, sizeof(iov));
+ pa_zero(iov);
iov.iov_base = (void*) data;
iov.iov_len = l;
- memset(&cmsg, 0, sizeof(cmsg));
+ pa_zero(cmsg);
cmsg.hdr.cmsg_len = CMSG_LEN(sizeof(struct ucred));
cmsg.hdr.cmsg_level = SOL_SOCKET;
cmsg.hdr.cmsg_type = SCM_CREDENTIALS;
@@ -296,18 +321,15 @@ ssize_t pa_iochannel_write_with_creds(pa_iochannel*io, const void*data, size_t l
u->gid = getgid();
}
- memset(&mh, 0, sizeof(mh));
- mh.msg_name = NULL;
- mh.msg_namelen = 0;
+ pa_zero(mh);
mh.msg_iov = &iov;
mh.msg_iovlen = 1;
mh.msg_control = &cmsg;
mh.msg_controllen = sizeof(cmsg);
- mh.msg_flags = 0;
if ((r = sendmsg(io->ofd, &mh, MSG_NOSIGNAL)) >= 0) {
- io->writable = FALSE;
- enable_mainloop_sources(io);
+ io->writable = io->hungup = FALSE;
+ enable_events(io);
}
return r;
@@ -329,25 +351,21 @@ ssize_t pa_iochannel_read_with_creds(pa_iochannel*io, void*data, size_t l, pa_cr
pa_assert(creds);
pa_assert(creds_valid);
- memset(&iov, 0, sizeof(iov));
+ pa_zero(iov);
iov.iov_base = data;
iov.iov_len = l;
- memset(&cmsg, 0, sizeof(cmsg));
-
- memset(&mh, 0, sizeof(mh));
- mh.msg_name = NULL;
- mh.msg_namelen = 0;
+ pa_zero(cmsg);
+ pa_zero(mh);
mh.msg_iov = &iov;
mh.msg_iovlen = 1;
mh.msg_control = &cmsg;
mh.msg_controllen = sizeof(cmsg);
- mh.msg_flags = 0;
if ((r = recvmsg(io->ifd, &mh, 0)) >= 0) {
struct cmsghdr *cmh;
- *creds_valid = 0;
+ *creds_valid = FALSE;
for (cmh = CMSG_FIRSTHDR(&mh); cmh; cmh = CMSG_NXTHDR(&mh, cmh)) {
@@ -363,8 +381,8 @@ ssize_t pa_iochannel_read_with_creds(pa_iochannel*io, void*data, size_t l, pa_cr
}
}
- io->readable = FALSE;
- enable_mainloop_sources(io);
+ io->readable = io->hungup = FALSE;
+ enable_events(io);
}
return r;
diff --git a/src/pulsecore/iochannel.h b/src/pulsecore/iochannel.h
index 9050df90..180245b8 100644
--- a/src/pulsecore/iochannel.h
+++ b/src/pulsecore/iochannel.h
@@ -38,11 +38,6 @@
the channel a callback function is called. It is safe to destroy
the calling iochannel object from the callback */
-/* When pa_iochannel_is_readable() returns non-zero, the user has to
- * call this function in a loop until it is no longer set or EOF
- * reached. Otherwise strange things may happen when an EOF is
- * reached. */
-
typedef struct pa_iochannel pa_iochannel;
/* Create a new IO channel for the specified file descriptors for
diff --git a/src/pulsecore/ioline.c b/src/pulsecore/ioline.c
index 7afdb08c..a18188df 100644
--- a/src/pulsecore/ioline.c
+++ b/src/pulsecore/ioline.c
@@ -30,8 +30,9 @@
#include <pulse/xmalloc.h>
-#include <pulsecore/winsock.h>
+#include <pulsecore/socket.h>
#include <pulsecore/core-error.h>
+#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/refcnt.h>
diff --git a/src/pulsecore/ioline.h b/src/pulsecore/ioline.h
index d973a3c7..12f6dead 100644
--- a/src/pulsecore/ioline.h
+++ b/src/pulsecore/ioline.h
@@ -22,8 +22,9 @@
USA.
***/
+#include <pulse/gccmacro.h>
+
#include <pulsecore/iochannel.h>
-#include <pulsecore/core-util.h>
/* An ioline wraps an iochannel for line based communication. A
* callback function is called whenever a new line has been recieved
diff --git a/src/pulsecore/ipacl.c b/src/pulsecore/ipacl.c
index 312e0403..5455d0e8 100644
--- a/src/pulsecore/ipacl.c
+++ b/src/pulsecore/ipacl.c
@@ -28,9 +28,6 @@
#include <sys/types.h>
#include <string.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
@@ -40,9 +37,6 @@
#ifdef HAVE_NETINET_IP_H
#include <netinet/ip.h>
#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
#include <pulse/xmalloc.h>
@@ -50,11 +44,8 @@
#include <pulsecore/llist.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
-#include <pulsecore/winsock.h>
-
-#ifndef HAVE_INET_PTON
-#include "inet_pton.h"
-#endif
+#include <pulsecore/socket.h>
+#include <pulsecore/arpa-inet.h>
#include "ipacl.h"
@@ -178,7 +169,7 @@ void pa_ip_acl_free(pa_ip_acl *acl) {
int pa_ip_acl_check(pa_ip_acl *acl, int fd) {
struct sockaddr_storage sa;
struct acl_entry *e;
- socklen_t salen;
+ socklen_t salen;
pa_assert(acl);
pa_assert(fd >= 0);
@@ -215,7 +206,7 @@ int pa_ip_acl_check(pa_ip_acl *acl, int fd) {
return 1;
#ifdef HAVE_IPV6
} else if (e->family == AF_INET6) {
- int i, bits ;
+ int i, bits;
struct sockaddr_in6 *sai = (struct sockaddr_in6*) &sa;
if (e->bits == 128)
diff --git a/src/pulsecore/llist.h b/src/pulsecore/llist.h
index 58b51c68..27f174a9 100644
--- a/src/pulsecore/llist.h
+++ b/src/pulsecore/llist.h
@@ -107,4 +107,7 @@
#define PA_LLIST_FOREACH(i,head) \
for (i = (head); i; i = i->next)
+#define PA_LLIST_FOREACH_SAFE(i,n,head) \
+ for (i = (head); i && ((n = i->next), 1); i = n)
+
#endif
diff --git a/src/pulsecore/lock-autospawn.c b/src/pulsecore/lock-autospawn.c
index 4436974d..40aa5e92 100644
--- a/src/pulsecore/lock-autospawn.c
+++ b/src/pulsecore/lock-autospawn.c
@@ -23,16 +23,19 @@
#include <config.h>
#endif
-#include <fcntl.h>
#include <errno.h>
#include <string.h>
-#include <sys/poll.h>
#include <signal.h>
+
+#ifdef HAVE_PTHREAD
#include <pthread.h>
+#endif
+#include <pulse/gccmacro.h>
#include <pulse/i18n.h>
#include <pulse/xmalloc.h>
+#include <pulsecore/poll.h>
#include <pulsecore/mutex.h>
#include <pulsecore/thread.h>
#include <pulsecore/core-util.h>
@@ -55,10 +58,16 @@ static pa_mutex *mutex;
static unsigned n_ref = 0;
static int lock_fd = -1;
static pa_mutex *lock_fd_mutex = NULL;
-static pa_bool_t taken = FALSE;
-static pa_thread *thread;
+static pa_thread *thread = NULL;
static int pipe_fd[2] = { -1, -1 };
+static enum {
+ STATE_IDLE,
+ STATE_OWNING,
+ STATE_TAKEN,
+ STATE_FAILED
+} state = STATE_IDLE;
+
static void destroy_mutex(void) PA_GCC_DESTRUCTOR;
static int ref(void) {
@@ -67,30 +76,28 @@ static int ref(void) {
pa_assert(pipe_fd[0] >= 0);
pa_assert(pipe_fd[1] >= 0);
+ pa_assert(lock_fd_mutex);
n_ref++;
return 0;
}
- pa_assert(lock_fd < 0);
pa_assert(!lock_fd_mutex);
- pa_assert(!taken);
+ pa_assert(state == STATE_IDLE);
+ pa_assert(lock_fd < 0);
pa_assert(!thread);
pa_assert(pipe_fd[0] < 0);
pa_assert(pipe_fd[1] < 0);
- if (pipe(pipe_fd) < 0)
+ if (pa_pipe_cloexec(pipe_fd) < 0)
return -1;
- lock_fd_mutex = pa_mutex_new(FALSE, FALSE);
-
- pa_make_fd_cloexec(pipe_fd[0]);
- pa_make_fd_cloexec(pipe_fd[1]);
-
pa_make_fd_nonblock(pipe_fd[1]);
pa_make_fd_nonblock(pipe_fd[0]);
+ lock_fd_mutex = pa_mutex_new(FALSE, FALSE);
+
n_ref = 1;
return 0;
}
@@ -107,15 +114,18 @@ static void unref(pa_bool_t after_fork) {
if (n_ref > 0)
return;
- pa_assert(!taken);
-
if (thread) {
pa_thread_free(thread);
thread = NULL;
}
pa_mutex_lock(lock_fd_mutex);
- if (lock_fd >= 0) {
+
+ pa_assert(state != STATE_TAKEN);
+
+ if (state == STATE_OWNING) {
+
+ pa_assert(lock_fd >= 0);
if (after_fork)
pa_close(lock_fd);
@@ -127,10 +137,12 @@ static void unref(pa_bool_t after_fork) {
pa_unlock_lockfile(lf, lock_fd);
pa_xfree(lf);
-
- lock_fd = -1;
}
}
+
+ lock_fd = -1;
+ state = STATE_IDLE;
+
pa_mutex_unlock(lock_fd_mutex);
pa_mutex_free(lock_fd_mutex);
@@ -149,7 +161,7 @@ static void ping(void) {
for (;;) {
char x = 'x';
- if ((s = write(pipe_fd[1], &x, 1)) == 1)
+ if ((s = pa_write(pipe_fd[1], &x, 1, NULL)) == 1)
break;
pa_assert(s < 0);
@@ -173,10 +185,10 @@ static void wait_for_ping(void) {
pfd.fd = pipe_fd[0];
pfd.events = POLLIN;
- if ((k = poll(&pfd, 1, -1)) != 1) {
+ if ((k = pa_poll(&pfd, 1, -1)) != 1) {
pa_assert(k < 0);
pa_assert(errno == EINTR);
- } else if ((s = read(pipe_fd[0], &x, 1)) != 1) {
+ } else if ((s = pa_read(pipe_fd[0], &x, 1, NULL)) != 1) {
pa_assert(s < 0);
pa_assert(errno == EAGAIN);
}
@@ -188,7 +200,7 @@ static void empty_pipe(void) {
pa_assert(pipe_fd[0] >= 0);
- if ((s = read(pipe_fd[0], &x, sizeof(x))) < 1) {
+ if ((s = pa_read(pipe_fd[0], &x, sizeof(x), NULL)) < 1) {
pa_assert(s < 0);
pa_assert(errno == EAGAIN);
}
@@ -197,23 +209,35 @@ static void empty_pipe(void) {
static void thread_func(void *u) {
int fd;
char *lf;
+
+#ifdef HAVE_PTHREAD
sigset_t fullset;
/* No signals in this thread please */
sigfillset(&fullset);
pthread_sigmask(SIG_BLOCK, &fullset, NULL);
+#endif
if (!(lf = pa_runtime_path(AUTOSPAWN_LOCK))) {
pa_log_warn(_("Cannot access autospawn lock."));
- goto finish;
+ goto fail;
}
if ((fd = pa_lock_lockfile(lf)) < 0)
- goto finish;
+ goto fail;
pa_mutex_lock(lock_fd_mutex);
- pa_assert(lock_fd < 0);
+ pa_assert(state == STATE_IDLE);
lock_fd = fd;
+ state = STATE_OWNING;
+ pa_mutex_unlock(lock_fd_mutex);
+
+ goto finish;
+
+fail:
+ pa_mutex_lock(lock_fd_mutex);
+ pa_assert(state == STATE_IDLE);
+ state = STATE_FAILED;
pa_mutex_unlock(lock_fd_mutex);
finish:
@@ -225,7 +249,7 @@ finish:
static int start_thread(void) {
if (!thread)
- if (!(thread = pa_thread_new(thread_func, NULL)))
+ if (!(thread = pa_thread_new("autospawn", thread_func, NULL)))
return -1;
return 0;
@@ -238,12 +262,10 @@ static void create_mutex(void) {
}
static void destroy_mutex(void) {
-
if (mutex)
pa_mutex_free(mutex);
}
-
int pa_autospawn_lock_init(void) {
int ret = -1;
@@ -273,13 +295,18 @@ int pa_autospawn_lock_acquire(pa_bool_t block) {
empty_pipe();
- if (lock_fd >= 0 && !taken) {
- taken = TRUE;
+ if (state == STATE_OWNING) {
+ state = STATE_TAKEN;
ret = 1;
break;
}
- if (lock_fd < 0)
+ if (state == STATE_FAILED) {
+ ret = -1;
+ break;
+ }
+
+ if (state == STATE_IDLE)
if (start_thread() < 0)
break;
@@ -310,8 +337,8 @@ void pa_autospawn_lock_release(void) {
pa_mutex_lock(mutex);
pa_assert(n_ref >= 1);
- pa_assert(taken);
- taken = FALSE;
+ pa_assert(state == STATE_TAKEN);
+ state = STATE_OWNING;
ping();
diff --git a/src/pulsecore/log.c b/src/pulsecore/log.c
index 15d192d6..13038148 100644
--- a/src/pulsecore/log.c
+++ b/src/pulsecore/log.c
@@ -38,6 +38,8 @@
#include <syslog.h>
#endif
+#include <pulse/gccmacro.h>
+#include <pulse/rtclock.h>
#include <pulse/utf8.h>
#include <pulse/xmalloc.h>
#include <pulse/util.h>
@@ -45,7 +47,6 @@
#include <pulsecore/macro.h>
#include <pulsecore/core-util.h>
-#include <pulsecore/rtclock.h>
#include <pulsecore/once.h>
#include <pulsecore/ratelimit.h>
@@ -60,6 +61,7 @@
#define ENV_LOG_PRINT_LEVEL "PULSE_LOG_LEVEL"
#define ENV_LOG_BACKTRACE "PULSE_LOG_BACKTRACE"
#define ENV_LOG_BACKTRACE_SKIP "PULSE_LOG_BACKTRACE_SKIP"
+#define ENV_LOG_NO_RATELIMIT "PULSE_LOG_NO_RATE_LIMIT"
static char *ident = NULL; /* in local charset format */
static pa_log_target_t target = PA_LOG_STDERR, target_override;
@@ -67,6 +69,8 @@ static pa_bool_t target_override_set = FALSE;
static pa_log_level_t maximum_level = PA_LOG_ERROR, maximum_level_override = PA_LOG_ERROR;
static unsigned show_backtrace = 0, show_backtrace_override = 0, skip_backtrace = 0;
static pa_log_flags_t flags = 0, flags_override = 0;
+static pa_bool_t no_rate_limit = FALSE;
+static int log_fd = -1;
#ifdef HAVE_SYSLOG_H
static const int level_to_syslog[] = {
@@ -125,6 +129,15 @@ void pa_log_set_flags(pa_log_flags_t _flags, pa_log_merge_t merge) {
flags = _flags;
}
+void pa_log_set_fd(int fd) {
+ if (fd >= 0)
+ log_fd = fd;
+ else if (log_fd >= 0) {
+ pa_close(log_fd);
+ log_fd = -1;
+ }
+}
+
void pa_log_set_show_backtrace(unsigned nlevels) {
show_backtrace = nlevels;
}
@@ -194,54 +207,61 @@ static char* get_backtrace(unsigned show_nframes) {
#endif
static void init_defaults(void) {
- const char *e;
+ PA_ONCE_BEGIN {
- if (!ident) {
- char binary[256];
- if (pa_get_binary_name(binary, sizeof(binary)))
- pa_log_set_ident(binary);
- }
+ const char *e;
- if (getenv(ENV_LOG_SYSLOG)) {
- target_override = PA_LOG_SYSLOG;
- target_override_set = TRUE;
- }
+ if (!ident) {
+ char binary[256];
+ if (pa_get_binary_name(binary, sizeof(binary)))
+ pa_log_set_ident(binary);
+ }
- if ((e = getenv(ENV_LOG_LEVEL))) {
- maximum_level_override = (pa_log_level_t) atoi(e);
+ if (getenv(ENV_LOG_SYSLOG)) {
+ target_override = PA_LOG_SYSLOG;
+ target_override_set = TRUE;
+ }
- if (maximum_level_override >= PA_LOG_LEVEL_MAX)
- maximum_level_override = PA_LOG_LEVEL_MAX-1;
- }
+ if ((e = getenv(ENV_LOG_LEVEL))) {
+ maximum_level_override = (pa_log_level_t) atoi(e);
- if (getenv(ENV_LOG_COLORS))
- flags_override |= PA_LOG_COLORS;
+ if (maximum_level_override >= PA_LOG_LEVEL_MAX)
+ maximum_level_override = PA_LOG_LEVEL_MAX-1;
+ }
- if (getenv(ENV_LOG_PRINT_TIME))
- flags_override |= PA_LOG_PRINT_TIME;
+ if (getenv(ENV_LOG_COLORS))
+ flags_override |= PA_LOG_COLORS;
- if (getenv(ENV_LOG_PRINT_FILE))
- flags_override |= PA_LOG_PRINT_FILE;
+ if (getenv(ENV_LOG_PRINT_TIME))
+ flags_override |= PA_LOG_PRINT_TIME;
- if (getenv(ENV_LOG_PRINT_META))
- flags_override |= PA_LOG_PRINT_META;
+ if (getenv(ENV_LOG_PRINT_FILE))
+ flags_override |= PA_LOG_PRINT_FILE;
- if (getenv(ENV_LOG_PRINT_LEVEL))
- flags_override |= PA_LOG_PRINT_LEVEL;
+ if (getenv(ENV_LOG_PRINT_META))
+ flags_override |= PA_LOG_PRINT_META;
- if ((e = getenv(ENV_LOG_BACKTRACE))) {
- show_backtrace_override = (unsigned) atoi(e);
+ if (getenv(ENV_LOG_PRINT_LEVEL))
+ flags_override |= PA_LOG_PRINT_LEVEL;
- if (show_backtrace_override <= 0)
- show_backtrace_override = 0;
- }
+ if ((e = getenv(ENV_LOG_BACKTRACE))) {
+ show_backtrace_override = (unsigned) atoi(e);
- if ((e = getenv(ENV_LOG_BACKTRACE_SKIP))) {
- skip_backtrace = (unsigned) atoi(e);
+ if (show_backtrace_override <= 0)
+ show_backtrace_override = 0;
+ }
- if (skip_backtrace <= 0)
- skip_backtrace = 0;
- }
+ if ((e = getenv(ENV_LOG_BACKTRACE_SKIP))) {
+ skip_backtrace = (unsigned) atoi(e);
+
+ if (skip_backtrace <= 0)
+ skip_backtrace = 0;
+ }
+
+ if (getenv(ENV_LOG_NO_RATELIMIT))
+ no_rate_limit = TRUE;
+
+ } PA_ONCE_END;
}
void pa_log_levelv_meta(
@@ -267,9 +287,7 @@ void pa_log_levelv_meta(
pa_assert(level < PA_LOG_LEVEL_MAX);
pa_assert(format);
- PA_ONCE_BEGIN {
- init_defaults();
- } PA_ONCE_END;
+ init_defaults();
_target = target_override_set ? target_override : target;
_maximum_level = PA_MAX(maximum_level, maximum_level_override);
@@ -294,7 +312,7 @@ void pa_log_levelv_meta(
static pa_usec_t start, last;
pa_usec_t u, a, r;
- u = pa_rtclock_usec();
+ u = pa_rtclock_now();
PA_ONCE_BEGIN {
start = u;
@@ -366,6 +384,9 @@ void pa_log_levelv_meta(
fprintf(stderr, "%s%c: %s%s%s%s%s%s\n", timestamp, level_to_char[level], location, prefix, t, grey, pa_strempty(bt), suffix);
else
fprintf(stderr, "%s%s%s%s%s%s%s\n", timestamp, location, prefix, t, grey, pa_strempty(bt), suffix);
+#ifdef OS_IS_WIN32
+ fflush(stderr);
+#endif
pa_xfree(local_t);
@@ -388,6 +409,23 @@ void pa_log_levelv_meta(
}
#endif
+ case PA_LOG_FD: {
+ if (log_fd >= 0) {
+ char metadata[256];
+
+ pa_snprintf(metadata, sizeof(metadata), "\n%c %s %s", level_to_char[level], timestamp, location);
+
+ if ((write(log_fd, metadata, strlen(metadata)) < 0) || (write(log_fd, t, strlen(t)) < 0)) {
+ saved_errno = errno;
+ pa_log_set_fd(-1);
+ fprintf(stderr, "%s\n", "Error writing logs to a file descriptor. Redirect log messages to console.");
+ fprintf(stderr, "%s %s\n", metadata, t);
+ pa_log_set_target(PA_LOG_STDERR);
+ }
+ }
+
+ break;
+ }
case PA_LOG_NULL:
default:
break;
@@ -423,9 +461,14 @@ void pa_log_level(pa_log_level_t level, const char *format, ...) {
va_end(ap);
}
-pa_bool_t pa_log_ratelimit(void) {
+pa_bool_t pa_log_ratelimit(pa_log_level_t level) {
/* Not more than 10 messages every 5s */
static PA_DEFINE_RATELIMIT(ratelimit, 5 * PA_USEC_PER_SEC, 10);
- return pa_ratelimit_test(&ratelimit);
+ init_defaults();
+
+ if (no_rate_limit)
+ return TRUE;
+
+ return pa_ratelimit_test(&ratelimit, level);
}
diff --git a/src/pulsecore/log.h b/src/pulsecore/log.h
index 2f379f68..ad04e7bd 100644
--- a/src/pulsecore/log.h
+++ b/src/pulsecore/log.h
@@ -36,6 +36,7 @@ typedef enum pa_log_target {
PA_LOG_STDERR, /* default */
PA_LOG_SYSLOG,
PA_LOG_NULL, /* to /dev/null */
+ PA_LOG_FD, /* to a file descriptor, e.g. a char device */
PA_LOG_TARGET_MAX
} pa_log_target_t;
@@ -74,6 +75,10 @@ void pa_log_set_level(pa_log_level_t l);
/* Set flags */
void pa_log_set_flags(pa_log_flags_t flags, pa_log_merge_t merge);
+/* Set the file descriptor of the logging device.
+ Daemon conf is in charge of opening this device */
+void pa_log_set_fd(int fd);
+
/* Enable backtrace */
void pa_log_set_show_backtrace(unsigned nlevels);
@@ -135,6 +140,6 @@ LOG_FUNC(error, PA_LOG_ERROR)
#define pa_log pa_log_error
-pa_bool_t pa_log_ratelimit(void);
+pa_bool_t pa_log_ratelimit(pa_log_level_t level);
#endif
diff --git a/src/pulsecore/ltdl-helper.c b/src/pulsecore/ltdl-helper.c
index be200ca2..bdb5a5dc 100644
--- a/src/pulsecore/ltdl-helper.c
+++ b/src/pulsecore/ltdl-helper.c
@@ -28,7 +28,6 @@
#include <ctype.h>
#include <pulse/xmalloc.h>
-#include <pulse/util.h>
#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
@@ -42,7 +41,7 @@ pa_void_func_t pa_load_sym(lt_dlhandle handle, const char *module, const char *s
pa_assert(handle);
pa_assert(symbol);
- *(void**) &f = lt_dlsym(handle, symbol);
+ f = (pa_void_func_t) lt_dlsym(handle, symbol);
if (f)
return f;
@@ -59,7 +58,7 @@ pa_void_func_t pa_load_sym(lt_dlhandle handle, const char *module, const char *s
if (!isalnum(*c))
*c = '_';
- *(void**) &f = lt_dlsym(handle, sn);
+ f = (pa_void_func_t) lt_dlsym(handle, sn);
pa_xfree(sn);
return f;
diff --git a/src/pulsecore/macro.h b/src/pulsecore/macro.h
index cf662510..1207a108 100644
--- a/src/pulsecore/macro.h
+++ b/src/pulsecore/macro.h
@@ -31,8 +31,6 @@
#include <stdlib.h>
#include <string.h>
-#include <pulse/gccmacro.h>
-
#ifndef PACKAGE
#error "Please include config.h before including this file!"
#endif
@@ -59,39 +57,42 @@
#endif
/* Rounds down */
-static inline void* pa_align_ptr(const void *p) {
- return (void*) (((size_t) p) & ~(sizeof(void*)-1));
+static inline void* PA_ALIGN_PTR(const void *p) {
+ return (void*) (((size_t) p) & ~(sizeof(void*) - 1));
}
-#define PA_ALIGN_PTR(x) (pa_align_ptr(x))
/* Rounds up */
-static inline size_t pa_align(size_t l) {
- return (((l + sizeof(void*) - 1) / sizeof(void*)) * sizeof(void*));
+static inline size_t PA_ALIGN(size_t l) {
+ return ((l + sizeof(void*) - 1) & ~(sizeof(void*) - 1));
}
-#define PA_ALIGN(x) (pa_align(x))
/* Rounds down */
-static inline void* pa_page_align_ptr(const void *p) {
- return (void*) (((size_t) p) & ~(PA_PAGE_SIZE-1));
+static inline void* PA_PAGE_ALIGN_PTR(const void *p) {
+ return (void*) (((size_t) p) & ~(PA_PAGE_SIZE - 1));
}
-#define PA_PAGE_ALIGN_PTR(x) (pa_page_align_ptr(x))
/* Rounds up */
-static inline size_t pa_page_align(size_t l) {
- return ((l + PA_PAGE_SIZE - 1) / PA_PAGE_SIZE) * PA_PAGE_SIZE;
+static inline size_t PA_PAGE_ALIGN(size_t l) {
+ return (l + PA_PAGE_SIZE - 1) & ~(PA_PAGE_SIZE - 1);
}
-#define PA_PAGE_ALIGN(x) (pa_page_align(x))
#define PA_ELEMENTSOF(x) (sizeof(x)/sizeof((x)[0]))
-/* The users of PA_MIN and PA_MAX should be aware that these macros on
- * non-GCC executed code with side effects twice. It is thus
- * considered misuse to use code with side effects as arguments to MIN
- * and MAX. */
+#if defined(__GNUC__)
+ #define PA_DECLARE_ALIGNED(n,t,v) t v __attribute__ ((aligned (n)))
+#else
+ #define PA_DECLARE_ALIGNED(n,t,v) t v
+#endif
+
+/* The users of PA_MIN and PA_MAX, PA_CLAMP, PA_ROUND_UP should be
+ * aware that these macros on non-GCC executed code with side effects
+ * twice. It is thus considered misuse to use code with side effects
+ * as arguments to MIN and MAX. */
#ifdef __GNUC__
#define PA_MAX(a,b) \
- __extension__ ({ typeof(a) _a = (a); \
+ __extension__ ({ \
+ typeof(a) _a = (a); \
typeof(b) _b = (b); \
_a > _b ? _a : _b; \
})
@@ -101,7 +102,8 @@ static inline size_t pa_page_align(size_t l) {
#ifdef __GNUC__
#define PA_MIN(a,b) \
- __extension__ ({ typeof(a) _a = (a); \
+ __extension__ ({ \
+ typeof(a) _a = (a); \
typeof(b) _b = (b); \
_a < _b ? _a : _b; \
})
@@ -111,7 +113,8 @@ static inline size_t pa_page_align(size_t l) {
#ifdef __GNUC__
#define PA_CLAMP(x, low, high) \
- __extension__ ({ typeof(x) _x = (x); \
+ __extension__ ({ \
+ typeof(x) _x = (x); \
typeof(low) _low = (low); \
typeof(high) _high = (high); \
((_x > _high) ? _high : ((_x < _low) ? _low : _x)); \
@@ -122,7 +125,8 @@ static inline size_t pa_page_align(size_t l) {
#ifdef __GNUC__
#define PA_CLAMP_UNLIKELY(x, low, high) \
- __extension__ ({ typeof(x) _x = (x); \
+ __extension__ ({ \
+ typeof(x) _x = (x); \
typeof(low) _low = (low); \
typeof(high) _high = (high); \
(PA_UNLIKELY(_x > _high) ? _high : (PA_UNLIKELY(_x < _low) ? _low : _x)); \
@@ -135,6 +139,39 @@ static inline size_t pa_page_align(size_t l) {
* make sense: we cannot know if it is more likely that the values is
* lower or greater than the boundaries.*/
+#ifdef __GNUC__
+#define PA_ROUND_UP(a, b) \
+ __extension__ ({ \
+ typeof(a) _a = (a); \
+ typeof(b) _b = (b); \
+ ((_a + _b - 1) / _b) * _b; \
+ })
+#else
+#define PA_ROUND_UP(a, b) ((((a) + (b) - 1) / (b)) * (b))
+#endif
+
+#ifdef __GNUC__
+#define PA_ROUND_DOWN(a, b) \
+ __extension__ ({ \
+ typeof(a) _a = (a); \
+ typeof(b) _b = (b); \
+ (_a / _b) * _b; \
+ })
+#else
+#define PA_ROUND_DOWN(a, b) (((a) / (b)) * (b))
+#endif
+
+#ifdef __GNUC__
+#define PA_CLIP_SUB(a, b) \
+ __extension__ ({ \
+ typeof(a) _a = (a); \
+ typeof(b) _b = (b); \
+ _a > _b ? _a - _b : 0; \
+ })
+#else
+#define PA_CLIP_SUB(a, b) ((a) > (b) ? (a) - (b) : 0)
+#endif
+
/* This type is not intended to be used in exported APIs! Use classic "int" there! */
#ifdef HAVE_STD_BOOL
typedef _Bool pa_bool_t;
@@ -265,6 +302,18 @@ typedef int pa_bool_t;
#define pa_memzero(x,l) (memset((x), 0, (l)))
#define pa_zero(x) (pa_memzero(&(x), sizeof(x)))
+#define PA_INT_TYPE_SIGNED(type) (!!((type) 0 > (type) -1))
+
+#define PA_INT_TYPE_MAX(type) \
+ ((type) (PA_INT_TYPE_SIGNED(type) \
+ ? ~(~(type) 0 << (8*sizeof(type)-1)) \
+ : (type) -1))
+
+#define PA_INT_TYPE_MIN(type) \
+ ((type) (PA_INT_TYPE_SIGNED(type) \
+ ? (~(type) 0 << (8*sizeof(type)-1)) \
+ : (type) 0))
+
/* We include this at the very last place */
#include <pulsecore/log.h>
diff --git a/src/pulsecore/memblock.c b/src/pulsecore/memblock.c
index 9a57895b..e34a7395 100644
--- a/src/pulsecore/memblock.c
+++ b/src/pulsecore/memblock.c
@@ -42,7 +42,10 @@
#include <pulsecore/log.h>
#include <pulsecore/hashmap.h>
#include <pulsecore/semaphore.h>
+#include <pulsecore/mutex.h>
#include <pulsecore/macro.h>
+#include <pulsecore/refcnt.h>
+#include <pulsecore/llist.h>
#include <pulsecore/flist.h>
#include <pulsecore/core-util.h>
#include <pulsecore/memtrap.h>
@@ -82,7 +85,7 @@ struct pa_memblock {
pa_free_cb_t free_cb;
} user;
- struct {
+ struct {
uint32_t id;
pa_memimport_segment *segment;
} imported;
@@ -96,6 +99,7 @@ struct pa_memimport_segment {
unsigned n_blocks;
};
+/* A collection of multiple segments */
struct pa_memimport {
pa_mutex *mutex;
@@ -257,7 +261,8 @@ static struct mempool_slot* mempool_allocate_slot(pa_mempool *p) {
slot = (struct mempool_slot*) ((uint8_t*) p->memory.ptr + (p->block_size * (size_t) idx));
if (!slot) {
- pa_log_info("Pool full");
+ if (pa_log_ratelimit(PA_LOG_DEBUG))
+ pa_log_debug("Pool full");
pa_atomic_inc(&p->stat.n_pool_full);
return NULL;
}
@@ -301,10 +306,17 @@ static struct mempool_slot* mempool_slot_by_ptr(pa_mempool *p, void *ptr) {
pa_memblock *pa_memblock_new_pool(pa_mempool *p, size_t length) {
pa_memblock *b = NULL;
struct mempool_slot *slot;
+ static int mempool_disable = 0;
pa_assert(p);
pa_assert(length);
+ if (mempool_disable == 0)
+ mempool_disable = getenv("PULSE_MEMPOOL_DISABLE") ? 1 : -1;
+
+ if (mempool_disable > 0)
+ return NULL;
+
/* If -1 is passed as length we choose the size for the caller: we
* take the largest size that fits in one of our slots. */
@@ -359,6 +371,7 @@ pa_memblock *pa_memblock_new_fixed(pa_mempool *p, void *d, size_t length, pa_boo
if (!(b = pa_flist_pop(PA_STATIC_FLIST_GET(unused_memblocks))))
b = pa_xnew(pa_memblock, 1);
+
PA_REFCNT_INIT(b);
b->pool = p;
b->type = PA_MEMBLOCK_FIXED;
@@ -385,6 +398,7 @@ pa_memblock *pa_memblock_new_user(pa_mempool *p, void *d, size_t length, pa_free
if (!(b = pa_flist_pop(PA_STATIC_FLIST_GET(unused_memblocks))))
b = pa_xnew(pa_memblock, 1);
+
PA_REFCNT_INIT(b);
b->pool = p;
b->type = PA_MEMBLOCK_USER;
@@ -497,25 +511,32 @@ static void memblock_free(pa_memblock *b) {
/* Fall through */
case PA_MEMBLOCK_FIXED:
- case PA_MEMBLOCK_APPENDED :
if (pa_flist_push(PA_STATIC_FLIST_GET(unused_memblocks), b) < 0)
pa_xfree(b);
break;
- case PA_MEMBLOCK_IMPORTED : {
+ case PA_MEMBLOCK_APPENDED:
+
+ /* We could attached it unused_memblocks, but that would
+ * probably waste some considerable memory */
+ pa_xfree(b);
+ break;
+
+ case PA_MEMBLOCK_IMPORTED: {
pa_memimport_segment *segment;
pa_memimport *import;
/* FIXME! This should be implemented lock-free */
- segment = b->per_type.imported.segment;
- pa_assert(segment);
- import = segment->import;
- pa_assert(import);
+ pa_assert_se(segment = b->per_type.imported.segment);
+ pa_assert_se(import = segment->import);
pa_mutex_lock(import->mutex);
- pa_hashmap_remove(import->blocks, PA_UINT32_TO_PTR(b->per_type.imported.id));
+
+ pa_assert_se(pa_hashmap_remove(import->blocks, PA_UINT32_TO_PTR(b->per_type.imported.id)));
+
+ pa_assert(segment->n_blocks >= 1);
if (-- segment->n_blocks <= 0)
segment_detach(segment);
@@ -525,6 +546,7 @@ static void memblock_free(pa_memblock *b) {
if (pa_flist_push(PA_STATIC_FLIST_GET(unused_memblocks), b) < 0)
pa_xfree(b);
+
break;
}
@@ -533,8 +555,7 @@ static void memblock_free(pa_memblock *b) {
struct mempool_slot *slot;
pa_bool_t call_free;
- slot = mempool_slot_by_ptr(b->pool, pa_atomic_ptr_load(&b->data));
- pa_assert(slot);
+ pa_assert_se(slot = mempool_slot_by_ptr(b->pool, pa_atomic_ptr_load(&b->data)));
call_free = b->type == PA_MEMBLOCK_POOL_EXTERNAL;
@@ -657,7 +678,8 @@ pa_memblock *pa_memblock_will_need(pa_memblock *b) {
/* Self-locked. This function is not multiple-caller safe */
static void memblock_replace_import(pa_memblock *b) {
- pa_memimport_segment *seg;
+ pa_memimport_segment *segment;
+ pa_memimport *import;
pa_assert(b);
pa_assert(b->type == PA_MEMBLOCK_IMPORTED);
@@ -667,28 +689,25 @@ static void memblock_replace_import(pa_memblock *b) {
pa_atomic_dec(&b->pool->stat.n_imported);
pa_atomic_sub(&b->pool->stat.imported_size, (int) b->length);
- seg = b->per_type.imported.segment;
- pa_assert(seg);
- pa_assert(seg->import);
+ pa_assert_se(segment = b->per_type.imported.segment);
+ pa_assert_se(import = segment->import);
- pa_mutex_lock(seg->import->mutex);
+ pa_mutex_lock(import->mutex);
- pa_hashmap_remove(
- seg->import->blocks,
- PA_UINT32_TO_PTR(b->per_type.imported.id));
+ pa_assert_se(pa_hashmap_remove(import->blocks, PA_UINT32_TO_PTR(b->per_type.imported.id)));
memblock_make_local(b);
- if (-- seg->n_blocks <= 0) {
- pa_mutex_unlock(seg->import->mutex);
- segment_detach(seg);
- } else
- pa_mutex_unlock(seg->import->mutex);
+ pa_assert(segment->n_blocks >= 1);
+ if (-- segment->n_blocks <= 0)
+ segment_detach(segment);
+
+ pa_mutex_unlock(import->mutex);
}
pa_mempool* pa_mempool_new(pa_bool_t shared, size_t size) {
pa_mempool *p;
- char t1[64], t2[64];
+ char t1[PA_BYTES_SNPRINT_MAX], t2[PA_BYTES_SNPRINT_MAX];
p = pa_xnew(pa_mempool, 1);
@@ -885,7 +904,7 @@ static pa_memimport_segment* segment_attach(pa_memimport *i, uint32_t shm_id) {
if (pa_hashmap_size(i->segments) >= PA_MEMIMPORT_SEGMENTS_MAX)
return NULL;
- seg = pa_xnew(pa_memimport_segment, 1);
+ seg = pa_xnew0(pa_memimport_segment, 1);
if (pa_shm_attach_ro(&seg->memory, shm_id) < 0) {
pa_xfree(seg);
@@ -893,10 +912,9 @@ static pa_memimport_segment* segment_attach(pa_memimport *i, uint32_t shm_id) {
}
seg->import = i;
- seg->n_blocks = 0;
seg->trap = pa_memtrap_add(seg->memory.ptr, seg->memory.size);
- pa_hashmap_put(i->segments, PA_UINT32_TO_PTR(shm_id), seg);
+ pa_hashmap_put(i->segments, PA_UINT32_TO_PTR(seg->memory.id), seg);
return seg;
}
@@ -956,6 +974,11 @@ pa_memblock* pa_memimport_get(pa_memimport *i, uint32_t block_id, uint32_t shm_i
pa_mutex_lock(i->mutex);
+ if ((b = pa_hashmap_get(i->blocks, PA_UINT32_TO_PTR(block_id)))) {
+ pa_memblock_ref(b);
+ goto finish;
+ }
+
if (pa_hashmap_size(i->blocks) >= PA_MEMIMPORT_SLOTS_MAX)
goto finish;
@@ -985,12 +1008,11 @@ pa_memblock* pa_memimport_get(pa_memimport *i, uint32_t block_id, uint32_t shm_i
seg->n_blocks++;
+ stat_add(b);
+
finish:
pa_mutex_unlock(i->mutex);
- if (b)
- stat_add(b);
-
return b;
}
diff --git a/src/pulsecore/memblock.h b/src/pulsecore/memblock.h
index b1eab2a9..ca108ccd 100644
--- a/src/pulsecore/memblock.h
+++ b/src/pulsecore/memblock.h
@@ -27,8 +27,6 @@
#include <inttypes.h>
#include <pulse/def.h>
-#include <pulsecore/llist.h>
-#include <pulsecore/refcnt.h>
#include <pulsecore/atomic.h>
/* A pa_memblock is a reference counted memory block. PulseAudio
diff --git a/src/pulsecore/memblockq.c b/src/pulsecore/memblockq.c
index 77f9efc9..c76ca841 100644
--- a/src/pulsecore/memblockq.c
+++ b/src/pulsecore/memblockq.c
@@ -23,8 +23,6 @@
#include <config.h>
#endif
-#include <sys/time.h>
-#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -55,8 +53,7 @@ struct pa_memblockq {
pa_bool_t in_prebuf;
pa_memchunk silence;
pa_mcalign *mcalign;
- int64_t missing;
- size_t requested;
+ int64_t missing, requested;
};
pa_memblockq* pa_memblockq_new(
@@ -84,8 +81,8 @@ pa_memblockq* pa_memblockq_new(
pa_log_debug("memblockq requested: maxlength=%lu, tlength=%lu, base=%lu, prebuf=%lu, minreq=%lu maxrewind=%lu",
(unsigned long) maxlength, (unsigned long) tlength, (unsigned long) base, (unsigned long) prebuf, (unsigned long) minreq, (unsigned long) maxrewind);
- bq->missing = 0;
- bq->requested = bq->maxlength = bq->tlength = bq->prebuf = bq->minreq = bq->maxrewind = 0;
+ bq->missing = bq->requested = 0;
+ bq->maxlength = bq->tlength = bq->prebuf = bq->minreq = bq->maxrewind = 0;
bq->in_prebuf = TRUE;
pa_memblockq_set_maxlength(bq, maxlength);
@@ -246,10 +243,36 @@ static pa_bool_t can_push(pa_memblockq *bq, size_t l) {
return TRUE;
}
+static void write_index_changed(pa_memblockq *bq, int64_t old_write_index, pa_bool_t account) {
+ int64_t delta;
+
+ pa_assert(bq);
+
+ delta = bq->write_index - old_write_index;
+
+ if (account)
+ bq->requested -= delta;
+ else
+ bq->missing -= delta;
+
+ /* pa_log("pushed/seeked %lli: requested counter at %lli, account=%i", (long long) delta, (long long) bq->requested, account); */
+}
+
+static void read_index_changed(pa_memblockq *bq, int64_t old_read_index) {
+ int64_t delta;
+
+ pa_assert(bq);
+
+ delta = bq->read_index - old_read_index;
+ bq->missing += delta;
+
+ /* pa_log("popped %lli: missing counter at %lli", (long long) delta, (long long) bq->missing); */
+}
+
int pa_memblockq_push(pa_memblockq* bq, const pa_memchunk *uchunk) {
struct list_item *q, *n;
pa_memchunk chunk;
- int64_t old, delta;
+ int64_t old;
pa_assert(bq);
pa_assert(uchunk);
@@ -353,8 +376,8 @@ int pa_memblockq_push(pa_memblockq* bq, const pa_memchunk *uchunk) {
size_t d;
pa_assert(bq->write_index + (int64_t)chunk.length > q->index &&
- bq->write_index + (int64_t)chunk.length < q->index + (int64_t)q->chunk.length &&
- bq->write_index < q->index);
+ bq->write_index + (int64_t)chunk.length < q->index + (int64_t)q->chunk.length &&
+ bq->write_index < q->index);
/* The job overwrites the current entry at the end, so let's drop the beginning of this entry */
@@ -409,18 +432,7 @@ int pa_memblockq_push(pa_memblockq* bq, const pa_memchunk *uchunk) {
finish:
- delta = bq->write_index - old;
-
- if (delta >= (int64_t) bq->requested) {
- delta -= (int64_t) bq->requested;
- bq->requested = 0;
- } else {
- bq->requested -= (size_t) delta;
- delta = 0;
- }
-
- bq->missing -= delta;
-
+ write_index_changed(bq, old, TRUE);
return 0;
}
@@ -467,7 +479,6 @@ int pa_memblockq_peek(pa_memblockq* bq, pa_memchunk *chunk) {
/* Do we need to spit out silence? */
if (!bq->current_read || bq->current_read->index > bq->read_index) {
-
size_t length;
/* How much silence shall we return? */
@@ -513,8 +524,78 @@ int pa_memblockq_peek(pa_memblockq* bq, pa_memchunk *chunk) {
return 0;
}
+int pa_memblockq_peek_fixed_size(pa_memblockq *bq, size_t block_size, pa_memchunk *chunk) {
+ pa_memchunk tchunk, rchunk;
+ int64_t ri;
+ struct list_item *item;
+
+ pa_assert(bq);
+ pa_assert(block_size > 0);
+ pa_assert(chunk);
+ pa_assert(bq->silence.memblock);
+
+ if (pa_memblockq_peek(bq, &tchunk) < 0)
+ return -1;
+
+ if (tchunk.length >= block_size) {
+ *chunk = tchunk;
+ chunk->length = block_size;
+ return 0;
+ }
+
+ rchunk.memblock = pa_memblock_new(pa_memblock_get_pool(tchunk.memblock), block_size);
+ rchunk.index = 0;
+ rchunk.length = tchunk.length;
+
+ pa_memchunk_memcpy(&rchunk, &tchunk);
+ pa_memblock_unref(tchunk.memblock);
+
+ rchunk.index += tchunk.length;
+
+ /* We don't need to call fix_current_read() here, since
+ * pa_memblock_peek() already did that */
+ item = bq->current_read;
+ ri = bq->read_index + tchunk.length;
+
+ while (rchunk.index < block_size) {
+
+ if (!item || item->index > ri) {
+ /* Do we need to append silence? */
+ tchunk = bq->silence;
+
+ if (item)
+ tchunk.length = PA_MIN(tchunk.length, (size_t) (item->index - ri));
+
+ } else {
+ int64_t d;
+
+ /* We can append real data! */
+ tchunk = item->chunk;
+
+ d = ri - item->index;
+ tchunk.index += (size_t) d;
+ tchunk.length -= (size_t) d;
+
+ /* Go to next item for the next iteration */
+ item = item->next;
+ }
+
+ rchunk.length = tchunk.length = PA_MIN(tchunk.length, block_size - rchunk.index);
+ pa_memchunk_memcpy(&rchunk, &tchunk);
+
+ rchunk.index += rchunk.length;
+ ri += rchunk.length;
+ }
+
+ rchunk.index = 0;
+ rchunk.length = block_size;
+
+ *chunk = rchunk;
+ return 0;
+}
+
void pa_memblockq_drop(pa_memblockq *bq, size_t length) {
- int64_t old, delta;
+ int64_t old;
pa_assert(bq);
pa_assert(length % bq->base == 0);
@@ -553,19 +634,21 @@ void pa_memblockq_drop(pa_memblockq *bq, size_t length) {
}
drop_backlog(bq);
-
- delta = bq->read_index - old;
- bq->missing += delta;
+ read_index_changed(bq, old);
}
void pa_memblockq_rewind(pa_memblockq *bq, size_t length) {
+ int64_t old;
pa_assert(bq);
pa_assert(length % bq->base == 0);
+ old = bq->read_index;
+
/* This is kind of the inverse of pa_memblockq_drop() */
bq->read_index -= (int64_t) length;
- bq->missing -= (int64_t) length;
+
+ read_index_changed(bq, old);
}
pa_bool_t pa_memblockq_is_readable(pa_memblockq *bq) {
@@ -602,7 +685,7 @@ size_t pa_memblockq_missing(pa_memblockq *bq) {
}
void pa_memblockq_seek(pa_memblockq *bq, int64_t offset, pa_seek_mode_t seek, pa_bool_t account) {
- int64_t old, delta;
+ int64_t old;
pa_assert(bq);
old = bq->write_index;
@@ -625,24 +708,11 @@ void pa_memblockq_seek(pa_memblockq *bq, int64_t offset, pa_seek_mode_t seek, pa
}
drop_backlog(bq);
-
- delta = bq->write_index - old;
-
- if (account) {
- if (delta >= (int64_t) bq->requested) {
- delta -= (int64_t) bq->requested;
- bq->requested = 0;
- } else if (delta >= 0) {
- bq->requested -= (size_t) delta;
- delta = 0;
- }
- }
-
- bq->missing -= delta;
+ write_index_changed(bq, old, account);
}
-void pa_memblockq_flush_write(pa_memblockq *bq) {
- int64_t old, delta;
+void pa_memblockq_flush_write(pa_memblockq *bq, pa_bool_t account) {
+ int64_t old;
pa_assert(bq);
pa_memblockq_silence(bq);
@@ -651,22 +721,11 @@ void pa_memblockq_flush_write(pa_memblockq *bq) {
bq->write_index = bq->read_index;
pa_memblockq_prebuf_force(bq);
-
- delta = bq->write_index - old;
-
- if (delta >= (int64_t) bq->requested) {
- delta -= (int64_t) bq->requested;
- bq->requested = 0;
- } else if (delta >= 0) {
- bq->requested -= (size_t) delta;
- delta = 0;
- }
-
- bq->missing -= delta;
+ write_index_changed(bq, old, account);
}
void pa_memblockq_flush_read(pa_memblockq *bq) {
- int64_t old, delta;
+ int64_t old;
pa_assert(bq);
pa_memblockq_silence(bq);
@@ -675,9 +734,7 @@ void pa_memblockq_flush_read(pa_memblockq *bq) {
bq->read_index = bq->write_index;
pa_memblockq_prebuf_force(bq);
-
- delta = bq->read_index - old;
- bq->missing += delta;
+ read_index_changed(bq, old);
}
size_t pa_memblockq_get_tlength(pa_memblockq *bq) {
@@ -692,6 +749,12 @@ size_t pa_memblockq_get_minreq(pa_memblockq *bq) {
return bq->minreq;
}
+size_t pa_memblockq_get_maxrewind(pa_memblockq *bq) {
+ pa_assert(bq);
+
+ return bq->maxrewind;
+}
+
int64_t pa_memblockq_get_read_index(pa_memblockq *bq) {
pa_assert(bq);
@@ -768,8 +831,11 @@ size_t pa_memblockq_pop_missing(pa_memblockq *bq) {
return 0;
l = (size_t) bq->missing;
+
+ bq->requested += bq->missing;
bq->missing = 0;
- bq->requested += l;
+
+ /* pa_log("sent %lli: request counter is at %lli", (long long) l, (long long) bq->requested); */
return l;
}
diff --git a/src/pulsecore/memblockq.h b/src/pulsecore/memblockq.h
index 146d261b..e12f5f7d 100644
--- a/src/pulsecore/memblockq.h
+++ b/src/pulsecore/memblockq.h
@@ -95,6 +95,11 @@ void pa_memblockq_seek(pa_memblockq *bq, int64_t offset, pa_seek_mode_t seek, pa
* was passed we return the length of the hole in chunk->length. */
int pa_memblockq_peek(pa_memblockq* bq, pa_memchunk *chunk);
+/* Much like pa_memblockq_peek, but guarantees that the returned chunk
+ * will have a length of the block size passed. You must configure a
+ * silence memchunk for this memblockq if you use this call. */
+int pa_memblockq_peek_fixed_size(pa_memblockq *bq, size_t block_size, pa_memchunk *chunk);
+
/* Drop the specified bytes from the queue. */
void pa_memblockq_drop(pa_memblockq *bq, size_t length);
@@ -118,7 +123,7 @@ size_t pa_memblockq_pop_missing(pa_memblockq *bq);
int pa_memblockq_splice(pa_memblockq *bq, pa_memblockq *source);
/* Set the queue to silence, set write index to read index */
-void pa_memblockq_flush_write(pa_memblockq *bq);
+void pa_memblockq_flush_write(pa_memblockq *bq, pa_bool_t account);
/* Set the queue to silence, set write read index to write index*/
void pa_memblockq_flush_read(pa_memblockq *bq);
@@ -141,6 +146,9 @@ size_t pa_memblockq_get_prebuf(pa_memblockq *bq);
/* Returns the minimal request value */
size_t pa_memblockq_get_minreq(pa_memblockq *bq);
+/* Returns the maximal rewind value */
+size_t pa_memblockq_get_maxrewind(pa_memblockq *bq);
+
/* Return the base unit in bytes */
size_t pa_memblockq_get_base(pa_memblockq *bq);
@@ -162,7 +170,7 @@ void pa_memblockq_set_silence(pa_memblockq *memblockq, pa_memchunk *silence);
void pa_memblockq_apply_attr(pa_memblockq *memblockq, const pa_buffer_attr *a);
void pa_memblockq_get_attr(pa_memblockq *bq, pa_buffer_attr *a);
-/* Call pa_memchunk_willneed() for every chunk in the queue from the current read pointer to the end */
+/* Call pa_memchunk_will_need() for every chunk in the queue from the current read pointer to the end */
void pa_memblockq_willneed(pa_memblockq *bq);
/* Check whether the memblockq is completely empty, i.e. no data
diff --git a/src/pulsecore/memchunk.c b/src/pulsecore/memchunk.c
index 0bbf8590..cc242e4e 100644
--- a/src/pulsecore/memchunk.c
+++ b/src/pulsecore/memchunk.c
@@ -28,7 +28,6 @@
#include <string.h>
#include <errno.h>
-#include <pulse/xmalloc.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-util.h>
@@ -110,3 +109,12 @@ pa_memchunk* pa_memchunk_memcpy(pa_memchunk *dst, pa_memchunk *src) {
return dst;
}
+
+pa_bool_t pa_memchunk_isset(pa_memchunk *chunk) {
+ assert(chunk);
+
+ return
+ chunk->memblock ||
+ chunk->index > 0 ||
+ chunk->length > 0;
+}
diff --git a/src/pulsecore/memchunk.h b/src/pulsecore/memchunk.h
index 9458f4ff..d7d82400 100644
--- a/src/pulsecore/memchunk.h
+++ b/src/pulsecore/memchunk.h
@@ -50,4 +50,7 @@ pa_memchunk *pa_memchunk_will_need(const pa_memchunk *c);
/* Copy the data in the src memchunk to the dst memchunk */
pa_memchunk* pa_memchunk_memcpy(pa_memchunk *dst, pa_memchunk *src);
+/* Return TRUE if any field is set != 0 */
+pa_bool_t pa_memchunk_isset(pa_memchunk *c);
+
#endif
diff --git a/src/pulsecore/memtrap.c b/src/pulsecore/memtrap.c
index e06f60ca..4df1fb71 100644
--- a/src/pulsecore/memtrap.c
+++ b/src/pulsecore/memtrap.c
@@ -24,7 +24,10 @@
#endif
#include <signal.h>
+
+#ifdef HAVE_SYS_MMAN_H
#include <sys/mman.h>
+#endif
/* This is deprecated on glibc but is still used by FreeBSD */
#if !defined(MAP_ANONYMOUS) && defined(MAP_ANON)
@@ -37,6 +40,7 @@
#include <pulsecore/aupdate.h>
#include <pulsecore/atomic.h>
#include <pulsecore/once.h>
+#include <pulsecore/mutex.h>
#include "memtrap.h"
@@ -49,6 +53,7 @@ struct pa_memtrap {
static pa_memtrap *memtraps[2] = { NULL, NULL };
static pa_aupdate *aupdate;
+static pa_static_mutex mutex = PA_STATIC_MUTEX_INIT; /* only required to serialize access to the write side */
static void allocate_aupdate(void) {
PA_ONCE_BEGIN {
@@ -62,8 +67,9 @@ pa_bool_t pa_memtrap_is_good(pa_memtrap *m) {
return !pa_atomic_load(&m->bad);
}
+#ifdef HAVE_SIGACTION
static void sigsafe_error(const char *s) {
- write(STDERR_FILENO, s, strlen(s));
+ (void) write(STDERR_FILENO, s, strlen(s));
}
static void signal_handler(int sig, siginfo_t* si, void *data) {
@@ -100,12 +106,16 @@ fail:
sigsafe_error("Failed to handle SIGBUS.\n");
abort();
}
+#endif
static void memtrap_link(pa_memtrap *m, unsigned j) {
pa_assert(m);
m->prev[j] = NULL;
- m->next[j] = memtraps[j];
+
+ if ((m->next[j] = memtraps[j]))
+ m->next[j]->prev[j] = m;
+
memtraps[j] = m;
}
@@ -124,6 +134,7 @@ static void memtrap_unlink(pa_memtrap *m, unsigned j) {
pa_memtrap* pa_memtrap_add(const void *start, size_t size) {
pa_memtrap *m = NULL;
unsigned j;
+ pa_mutex *mx;
pa_assert(start);
pa_assert(size > 0);
@@ -138,33 +149,45 @@ pa_memtrap* pa_memtrap_add(const void *start, size_t size) {
allocate_aupdate();
+ mx = pa_static_mutex_get(&mutex, FALSE, TRUE);
+ pa_mutex_lock(mx);
+
j = pa_aupdate_write_begin(aupdate);
memtrap_link(m, j);
j = pa_aupdate_write_swap(aupdate);
memtrap_link(m, j);
pa_aupdate_write_end(aupdate);
+ pa_mutex_unlock(mx);
+
return m;
}
void pa_memtrap_remove(pa_memtrap *m) {
unsigned j;
+ pa_mutex *mx;
pa_assert(m);
allocate_aupdate();
+ mx = pa_static_mutex_get(&mutex, FALSE, TRUE);
+ pa_mutex_lock(mx);
+
j = pa_aupdate_write_begin(aupdate);
memtrap_unlink(m, j);
j = pa_aupdate_write_swap(aupdate);
memtrap_unlink(m, j);
pa_aupdate_write_end(aupdate);
+ pa_mutex_unlock(mx);
+
pa_xfree(m);
}
pa_memtrap *pa_memtrap_update(pa_memtrap *m, const void *start, size_t size) {
unsigned j;
+ pa_mutex *mx;
pa_assert(m);
@@ -176,28 +199,34 @@ pa_memtrap *pa_memtrap_update(pa_memtrap *m, const void *start, size_t size) {
allocate_aupdate();
+ mx = pa_static_mutex_get(&mutex, FALSE, TRUE);
+ pa_mutex_lock(mx);
+
j = pa_aupdate_write_begin(aupdate);
if (m->start == start && m->size == size)
goto unlock;
memtrap_unlink(m, j);
- j = pa_aupdate_write_swap(aupdate);
+ pa_aupdate_write_swap(aupdate);
m->start = (void*) start;
m->size = size;
pa_atomic_store(&m->bad, 0);
- j = pa_aupdate_write_swap(aupdate);
+ pa_assert_se(pa_aupdate_write_swap(aupdate) == j);
memtrap_link(m, j);
unlock:
pa_aupdate_write_end(aupdate);
+ pa_mutex_unlock(mx);
+
return m;
}
void pa_memtrap_install(void) {
+#ifdef HAVE_SIGACTION
struct sigaction sa;
allocate_aupdate();
@@ -207,4 +236,5 @@ void pa_memtrap_install(void) {
sa.sa_flags = SA_RESTART|SA_SIGINFO;
pa_assert_se(sigaction(SIGBUS, &sa, NULL) == 0);
+#endif
}
diff --git a/src/pulsecore/modargs.c b/src/pulsecore/modargs.c
index c7d734d9..45ffba23 100644
--- a/src/pulsecore/modargs.c
+++ b/src/pulsecore/modargs.c
@@ -31,10 +31,6 @@
#include <pulsecore/hashmap.h>
#include <pulsecore/idxset.h>
-#include <pulsecore/sample-util.h>
-#include <pulsecore/namereg.h>
-#include <pulsecore/sink.h>
-#include <pulsecore/source.h>
#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
@@ -124,7 +120,7 @@ pa_modargs *pa_modargs_new(const char *args, const char* const* valid_keys) {
key_len++;
break;
- case VALUE_START:
+ case VALUE_START:
if (*p == '\'') {
state = VALUE_TICKS;
value = p+1;
@@ -415,3 +411,13 @@ int pa_modargs_get_proplist(pa_modargs *ma, const char *name, pa_proplist *p, pa
return 0;
}
+
+const char *pa_modargs_iterate(pa_modargs *ma, void **state) {
+ pa_hashmap *map = (pa_hashmap*) ma;
+ struct entry *e;
+
+ if (!(e = pa_hashmap_iterate(map, state, NULL)))
+ return NULL;
+
+ return e->key;
+}
diff --git a/src/pulsecore/modargs.h b/src/pulsecore/modargs.h
index b3125b10..9a81e8d6 100644
--- a/src/pulsecore/modargs.h
+++ b/src/pulsecore/modargs.h
@@ -25,7 +25,7 @@
#include <inttypes.h>
#include <pulse/sample.h>
#include <pulse/channelmap.h>
-#include <pulsecore/core.h>
+#include <pulse/proplist.h>
#include <pulsecore/macro.h>
typedef struct pa_modargs pa_modargs;
@@ -60,4 +60,13 @@ int pa_modargs_get_sample_spec_and_channel_map(pa_modargs *ma, pa_sample_spec *s
int pa_modargs_get_proplist(pa_modargs *ma, const char *name, pa_proplist *p, pa_update_mode_t m);
+/* Iterate through the module argument list. The user should allocate a
+ * state variable of type void* and initialize it with NULL. A pointer
+ * to this variable should then be passed to pa_modargs_iterate()
+ * which should be called in a loop until it returns NULL which
+ * signifies EOL. On each invication this function will return the
+ * key string for the next entry. The keys in the argument list do not
+ * have any particular order. */
+const char *pa_modargs_iterate(pa_modargs *ma, void **state);
+
#endif
diff --git a/src/pulsecore/modinfo.c b/src/pulsecore/modinfo.c
index b5ee9f56..860b8064 100644
--- a/src/pulsecore/modinfo.c
+++ b/src/pulsecore/modinfo.c
@@ -27,7 +27,6 @@
#include <pulse/xmalloc.h>
-#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/ltdl-helper.h>
diff --git a/src/pulsecore/module.c b/src/pulsecore/module.c
index 5bcdd898..8b3ff8f5 100644
--- a/src/pulsecore/module.c
+++ b/src/pulsecore/module.c
@@ -24,14 +24,11 @@
#include <config.h>
#endif
-#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
-#include <ctype.h>
-#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
#include <pulse/proplist.h>
@@ -110,7 +107,7 @@ pa_module* pa_module_load(pa_core *c, const char *name, const char *argument) {
m->unload_requested = FALSE;
if (m->init(m) < 0) {
- pa_log_error("Failed to load module \"%s\" (argument: \"%s\"): initialization failed.", name, argument ? argument : "");
+ pa_log_error("Failed to load module \"%s\" (argument: \"%s\"): initialization failed.", name, argument ? argument : "");
goto fail;
}
@@ -263,3 +260,12 @@ int pa_module_get_n_used(pa_module*m) {
return m->get_n_used(m);
}
+
+void pa_module_update_proplist(pa_module *m, pa_update_mode_t mode, pa_proplist *p) {
+ pa_assert(m);
+
+ if (p)
+ pa_proplist_update(m->proplist, mode, p);
+
+ pa_subscription_post(m->core, PA_SUBSCRIPTION_EVENT_MODULE|PA_SUBSCRIPTION_EVENT_CHANGE, m->index);
+}
diff --git a/src/pulsecore/module.h b/src/pulsecore/module.h
index af89d793..0b6cb7c4 100644
--- a/src/pulsecore/module.h
+++ b/src/pulsecore/module.h
@@ -62,6 +62,8 @@ void pa_module_unload_all(pa_core *c);
int pa_module_get_n_used(pa_module*m);
+void pa_module_update_proplist(pa_module *m, pa_update_mode_t mode, pa_proplist *p);
+
#define PA_MODULE_AUTHOR(s) \
const char *pa__get_author(void) { return s; } \
struct __stupid_useless_struct_to_allow_trailing_semicolon
diff --git a/src/pulsecore/msgobject.c b/src/pulsecore/msgobject.c
index 6a2a612d..075a28c5 100644
--- a/src/pulsecore/msgobject.c
+++ b/src/pulsecore/msgobject.c
@@ -26,22 +26,22 @@
#include "msgobject.h"
-PA_DEFINE_CHECK_TYPE(pa_msgobject, pa_object);
+PA_DEFINE_PUBLIC_CLASS(pa_msgobject, pa_object);
-pa_msgobject *pa_msgobject_new_internal(size_t size, const char *type_name, int (*check_type)(const char *type_name)) {
+pa_msgobject *pa_msgobject_new_internal(size_t size, const char *type_id, pa_bool_t (*check_type)(const char *type_name)) {
pa_msgobject *o;
pa_assert(size > sizeof(pa_msgobject));
- pa_assert(type_name);
+ pa_assert(type_id);
if (!check_type)
check_type = pa_msgobject_check_type;
- pa_assert(check_type(type_name));
- pa_assert(check_type("pa_object"));
- pa_assert(check_type("pa_msgobject"));
+ pa_assert(check_type(type_id));
+ pa_assert(check_type(pa_object_type_id));
+ pa_assert(check_type(pa_msgobject_type_id));
- o = PA_MSGOBJECT(pa_object_new_internal(size, type_name, check_type));
+ o = PA_MSGOBJECT(pa_object_new_internal(size, type_id, check_type));
o->process_msg = NULL;
return o;
}
diff --git a/src/pulsecore/msgobject.h b/src/pulsecore/msgobject.h
index a35a23b5..9b5712b4 100644
--- a/src/pulsecore/msgobject.h
+++ b/src/pulsecore/msgobject.h
@@ -25,8 +25,6 @@
#include <sys/types.h>
-#include <pulse/xmalloc.h>
-#include <pulsecore/refcnt.h>
#include <pulsecore/macro.h>
#include <pulsecore/object.h>
#include <pulsecore/memchunk.h>
@@ -38,15 +36,13 @@ struct pa_msgobject {
int (*process_msg)(pa_msgobject *o, int code, void *userdata, int64_t offset, pa_memchunk *chunk);
};
-pa_msgobject *pa_msgobject_new_internal(size_t size, const char *type_name, int (*check_type)(const char *type_name));
+pa_msgobject *pa_msgobject_new_internal(size_t size, const char *type_id, pa_bool_t (*check_type)(const char *type_name));
-int pa_msgobject_check_type(const char *type);
-
-#define pa_msgobject_new(type) ((type*) pa_msgobject_new_internal(sizeof(type), #type, type##_check_type))
+#define pa_msgobject_new(type) ((type*) pa_msgobject_new_internal(sizeof(type), type##_type_id, type##_check_type))
#define pa_msgobject_free ((void (*) (pa_msgobject* o)) pa_object_free)
#define PA_MSGOBJECT(o) pa_msgobject_cast(o)
-PA_DECLARE_CLASS(pa_msgobject);
+PA_DECLARE_PUBLIC_CLASS(pa_msgobject);
#endif
diff --git a/src/pulsecore/mutex-posix.c b/src/pulsecore/mutex-posix.c
index 0ff4bee6..634087d9 100644
--- a/src/pulsecore/mutex-posix.c
+++ b/src/pulsecore/mutex-posix.c
@@ -28,8 +28,6 @@
#include <pulse/xmalloc.h>
#include <pulsecore/macro.h>
-#include <pulsecore/log.h>
-#include <pulsecore/core-error.h>
#include "mutex.h"
diff --git a/src/pulsecore/mutex-win32.c b/src/pulsecore/mutex-win32.c
index 3a910b03..f4652a90 100644
--- a/src/pulsecore/mutex-win32.c
+++ b/src/pulsecore/mutex-win32.c
@@ -91,7 +91,7 @@ void pa_cond_signal(pa_cond *c, int broadcast) {
return;
if (broadcast)
- SetEvent(pa_hashmap_get_first(c->wait_events));
+ SetEvent(pa_hashmap_first(c->wait_events));
else {
void *iter;
const void *key;
@@ -131,3 +131,26 @@ int pa_cond_wait(pa_cond *c, pa_mutex *m) {
return 0;
}
+
+/* This is a copy of the function in mutex-posix.c */
+pa_mutex* pa_static_mutex_get(pa_static_mutex *s, pa_bool_t recursive, pa_bool_t inherit_priority) {
+ pa_mutex *m;
+
+ pa_assert(s);
+
+ /* First, check if already initialized and short cut */
+ if ((m = pa_atomic_ptr_load(&s->ptr)))
+ return m;
+
+ /* OK, not initialized, so let's allocate, and fill in */
+ m = pa_mutex_new(recursive, inherit_priority);
+ if ((pa_atomic_ptr_cmpxchg(&s->ptr, NULL, m)))
+ return m;
+
+ pa_mutex_free(m);
+
+ /* Him, filling in failed, so someone else must have filled in
+ * already */
+ pa_assert_se(m = pa_atomic_ptr_load(&s->ptr));
+ return m;
+}
diff --git a/src/pulsecore/namereg.c b/src/pulsecore/namereg.c
index 9df2f583..d9821876 100644
--- a/src/pulsecore/namereg.c
+++ b/src/pulsecore/namereg.c
@@ -57,6 +57,8 @@ static pa_bool_t is_valid_char(char c) {
pa_bool_t pa_namereg_is_valid_name(const char *name) {
const char *c;
+ pa_assert(name);
+
if (*name == 0)
return FALSE;
@@ -70,6 +72,25 @@ pa_bool_t pa_namereg_is_valid_name(const char *name) {
return TRUE;
}
+pa_bool_t pa_namereg_is_valid_name_or_wildcard(const char *name, pa_namereg_type_t type) {
+
+ pa_assert(name);
+
+ if (pa_namereg_is_valid_name(name))
+ return TRUE;
+
+ if (type == PA_NAMEREG_SINK &&
+ pa_streq(name, "@DEFAULT_SINK@"))
+ return TRUE;
+
+ if (type == PA_NAMEREG_SOURCE &&
+ (pa_streq(name, "@DEFAULT_SOURCE@") ||
+ pa_streq(name, "@DEFAULT_MONITOR@")))
+ return TRUE;
+
+ return FALSE;
+}
+
char* pa_namereg_make_valid_name(const char *name) {
const char *a;
char *b, *n;
@@ -77,7 +98,7 @@ char* pa_namereg_make_valid_name(const char *name) {
if (*name == 0)
return NULL;
- n = pa_xmalloc(strlen(name)+1);
+ n = pa_xnew(char, strlen(name)+1);
for (a = name, b = n; *a && (a-name < PA_NAME_MAX); a++, b++)
*b = (char) (is_valid_char(*a) ? *a : '_');
@@ -149,6 +170,17 @@ const char *pa_namereg_register(pa_core *c, const char *name, pa_namereg_type_t
pa_assert_se(pa_hashmap_put(c->namereg, e->name, e) >= 0);
+ /* If a sink or source is registered and there was none registered
+ * before we inform the clients which then can ask for the default
+ * sink/source which is then assigned. We don't adjust the default
+ * sink/source here right away to give the module the chance to
+ * register more sinks/sources before we choose a new default
+ * sink/source. */
+
+ if ((!c->default_sink && type == PA_NAMEREG_SINK) ||
+ (!c->default_source && type == PA_NAMEREG_SOURCE))
+ pa_subscription_post(c, PA_SUBSCRIPTION_EVENT_SERVER|PA_SUBSCRIPTION_EVENT_CHANGE, PA_INVALID_INDEX);
+
return e->name;
}
@@ -191,7 +223,6 @@ void* pa_namereg_get(pa_core *c, const char *name, pa_namereg_type_t type) {
if ((s = pa_namereg_get(c, NULL, PA_NAMEREG_SINK)))
return s->monitor_source;
-
}
if (!name)
@@ -223,6 +254,9 @@ void* pa_namereg_get(pa_core *c, const char *name, pa_namereg_type_t type) {
pa_sink* pa_namereg_set_default_sink(pa_core*c, pa_sink *s) {
pa_assert(c);
+ if (s && !PA_SINK_IS_LINKED(pa_sink_get_state(s)))
+ return NULL;
+
if (c->default_sink != s) {
c->default_sink = s;
pa_subscription_post(c, PA_SUBSCRIPTION_EVENT_SERVER|PA_SUBSCRIPTION_EVENT_CHANGE, PA_INVALID_INDEX);
@@ -234,6 +268,9 @@ pa_sink* pa_namereg_set_default_sink(pa_core*c, pa_sink *s) {
pa_source* pa_namereg_set_default_source(pa_core*c, pa_source *s) {
pa_assert(c);
+ if (s && !PA_SOURCE_IS_LINKED(pa_source_get_state(s)))
+ return NULL;
+
if (c->default_source != s) {
c->default_source = s;
pa_subscription_post(c, PA_SUBSCRIPTION_EVENT_SERVER|PA_SUBSCRIPTION_EVENT_CHANGE, PA_INVALID_INDEX);
@@ -243,34 +280,57 @@ pa_source* pa_namereg_set_default_source(pa_core*c, pa_source *s) {
}
pa_sink *pa_namereg_get_default_sink(pa_core *c) {
- pa_sink *s;
+ pa_sink *s, *best = NULL;
+ uint32_t idx;
pa_assert(c);
- if (c->default_sink)
+ if (c->default_sink && PA_SINK_IS_LINKED(pa_sink_get_state(c->default_sink)))
return c->default_sink;
- if ((s = pa_idxset_first(c->sinks, NULL)))
- return pa_namereg_set_default_sink(c, s);
+ PA_IDXSET_FOREACH(s, c->sinks, idx)
+ if (PA_SINK_IS_LINKED(pa_sink_get_state(s)))
+ if (!best || s->priority > best->priority)
+ best = s;
+
+ if (best)
+ return pa_namereg_set_default_sink(c, best);
return NULL;
}
pa_source *pa_namereg_get_default_source(pa_core *c) {
- pa_source *s;
+ pa_source *s, *best = NULL;
uint32_t idx;
pa_assert(c);
- if (c->default_source)
+ if (c->default_source && PA_SOURCE_IS_LINKED(pa_source_get_state(c->default_source)))
return c->default_source;
- for (s = PA_SOURCE(pa_idxset_first(c->sources, &idx)); s; s = PA_SOURCE(pa_idxset_next(c->sources, &idx)))
- if (!s->monitor_of)
- return pa_namereg_set_default_source(c, s);
-
- if ((s = pa_idxset_first(c->sources, NULL)))
- return pa_namereg_set_default_source(c, s);
+ /* First, try to find one that isn't a monitor */
+ PA_IDXSET_FOREACH(s, c->sources, idx)
+ if (!s->monitor_of && PA_SOURCE_IS_LINKED(pa_source_get_state(s)))
+ if (!best ||
+ s->priority > best->priority)
+ best = s;
+
+ if (best)
+ return pa_namereg_set_default_source(c, best);
+
+ /* Then, fallback to a monitor */
+ PA_IDXSET_FOREACH(s, c->sources, idx)
+ if (PA_SOURCE_IS_LINKED(pa_source_get_state(s)))
+ if (!best ||
+ s->priority > best->priority ||
+ (s->priority == best->priority &&
+ s->monitor_of &&
+ best->monitor_of &&
+ s->monitor_of->priority > best->monitor_of->priority))
+ best = s;
+
+ if (best)
+ return pa_namereg_set_default_source(c, best);
return NULL;
}
diff --git a/src/pulsecore/namereg.h b/src/pulsecore/namereg.h
index 38fae6f5..b5a976d7 100644
--- a/src/pulsecore/namereg.h
+++ b/src/pulsecore/namereg.h
@@ -45,6 +45,7 @@ pa_sink *pa_namereg_get_default_sink(pa_core *c);
pa_source *pa_namereg_get_default_source(pa_core *c);
pa_bool_t pa_namereg_is_valid_name(const char *name);
+pa_bool_t pa_namereg_is_valid_name_or_wildcard(const char *name, pa_namereg_type_t type);
char* pa_namereg_make_valid_name(const char *name);
#endif
diff --git a/src/pulsecore/native-common.h b/src/pulsecore/native-common.h
index d4d7f3ee..5d1ba6a6 100644
--- a/src/pulsecore/native-common.h
+++ b/src/pulsecore/native-common.h
@@ -165,6 +165,14 @@ enum {
PA_COMMAND_PLAYBACK_BUFFER_ATTR_CHANGED,
PA_COMMAND_RECORD_BUFFER_ATTR_CHANGED,
+ /* Supported since protocol v16 (0.9.16) */
+ PA_COMMAND_SET_SINK_PORT,
+ PA_COMMAND_SET_SOURCE_PORT,
+
+ /* Supported since protocol v22 (1.0) */
+ PA_COMMAND_SET_SOURCE_OUTPUT_VOLUME,
+ PA_COMMAND_SET_SOURCE_OUTPUT_MUTE,
+
PA_COMMAND_MAX
};
diff --git a/src/pulsecore/object.c b/src/pulsecore/object.c
index f3ead9c5..0dc8198a 100644
--- a/src/pulsecore/object.c
+++ b/src/pulsecore/object.c
@@ -24,25 +24,25 @@
#include <config.h>
#endif
-#include <pulsecore/core-util.h>
-
#include "object.h"
-pa_object *pa_object_new_internal(size_t size, const char *type_name, int (*check_type)(const char *type_name)) {
+const char pa_object_type_id[] = "pa_object";
+
+pa_object *pa_object_new_internal(size_t size, const char *type_id, pa_bool_t (*check_type)(const char *type_id)) {
pa_object *o;
pa_assert(size > sizeof(pa_object));
- pa_assert(type_name);
+ pa_assert(type_id);
if (!check_type)
check_type = pa_object_check_type;
- pa_assert(check_type(type_name));
- pa_assert(check_type("pa_object"));
+ pa_assert(check_type(type_id));
+ pa_assert(check_type(pa_object_type_id));
o = pa_xmalloc(size);
PA_REFCNT_INIT(o);
- o->type_name = type_name;
+ o->type_id = type_id;
o->free = pa_object_free;
o->check_type = check_type;
@@ -65,8 +65,8 @@ void pa_object_unref(pa_object *o) {
}
}
-int pa_object_check_type(const char *type_name) {
- pa_assert(type_name);
+pa_bool_t pa_object_check_type(const char *type_id) {
+ pa_assert(type_id);
- return pa_streq(type_name, "pa_object");
+ return type_id == pa_object_type_id;
}
diff --git a/src/pulsecore/object.h b/src/pulsecore/object.h
index 43e79327..1ddce3b4 100644
--- a/src/pulsecore/object.h
+++ b/src/pulsecore/object.h
@@ -23,7 +23,6 @@
USA.
***/
-#include <string.h>
#include <sys/types.h>
#include <pulse/xmalloc.h>
@@ -34,21 +33,23 @@ typedef struct pa_object pa_object;
struct pa_object {
PA_REFCNT_DECLARE;
- const char *type_name;
+ const char *type_id;
void (*free)(pa_object *o);
- int (*check_type)(const char *type_name);
+ pa_bool_t (*check_type)(const char *type_name);
};
-pa_object *pa_object_new_internal(size_t size, const char *type_name, int (*check_type)(const char *type_name));
-#define pa_object_new(type) ((type*) pa_object_new_internal(sizeof(type), #type, type##_check_type)
+pa_object *pa_object_new_internal(size_t size, const char *type_id, pa_bool_t (*check_type)(const char *type_id));
+#define pa_object_new(type) ((type*) pa_object_new_internal(sizeof(type), type##_type_id, type##_check_type)
#define pa_object_free ((void (*) (pa_object* _obj)) pa_xfree)
-int pa_object_check_type(const char *type);
+pa_bool_t pa_object_check_type(const char *type_id);
-static inline int pa_object_isinstance(void *o) {
+extern const char pa_object_type_id[];
+
+static inline pa_bool_t pa_object_isinstance(void *o) {
pa_object *obj = (pa_object*) o;
- return obj ? obj->check_type("pa_object") : 0;
+ return obj ? obj->check_type(pa_object_type_id) : TRUE;
}
pa_object *pa_object_ref(pa_object *o);
@@ -60,7 +61,7 @@ static inline int pa_object_refcnt(pa_object *o) {
static inline pa_object* pa_object_cast(void *o) {
pa_object *obj = (pa_object*) o;
- pa_assert(!obj || obj->check_type("pa_object"));
+ pa_assert(!obj || obj->check_type(pa_object_type_id));
return obj;
}
@@ -68,10 +69,10 @@ static inline pa_object* pa_object_cast(void *o) {
#define PA_OBJECT(o) pa_object_cast(o)
-#define PA_DECLARE_CLASS(c) \
- static inline int c##_isinstance(void *o) { \
+#define PA_DECLARE_CLASS_COMMON(c) \
+ static inline pa_bool_t c##_isinstance(void *o) { \
pa_object *obj = (pa_object*) o; \
- return obj ? obj->check_type(#c) : 1; \
+ return obj ? obj->check_type(c##_type_id) : TRUE; \
} \
static inline c* c##_cast(void *o) { \
pa_assert(c##_isinstance(o)); \
@@ -91,12 +92,27 @@ static inline pa_object* pa_object_cast(void *o) {
} \
struct __stupid_useless_struct_to_allow_trailing_semicolon
-#define PA_DEFINE_CHECK_TYPE(c, parent) \
- int c##_check_type(const char *type) { \
- pa_assert(type); \
- if (strcmp(type, #c) == 0) \
- return 1; \
- return parent##_check_type(type); \
+#define PA_DECLARE_PUBLIC_CLASS(c) \
+ extern const char c##_type_id[]; \
+ PA_DECLARE_CLASS_COMMON(c); \
+ pa_bool_t c##_check_type(const char *type_id)
+
+#define PA_DEFINE_PUBLIC_CLASS(c, parent) \
+ const char c##_type_id[] = #c; \
+ pa_bool_t c##_check_type(const char *type_id) { \
+ if (type_id == c##_type_id) \
+ return TRUE; \
+ return parent##_check_type(type_id); \
+ } \
+ struct __stupid_useless_struct_to_allow_trailing_semicolon
+
+#define PA_DEFINE_PRIVATE_CLASS(c, parent) \
+ static const char c##_type_id[] = #c; \
+ PA_DECLARE_CLASS_COMMON(c); \
+ static pa_bool_t c##_check_type(const char *type_id) { \
+ if (type_id == c##_type_id) \
+ return TRUE; \
+ return parent##_check_type(type_id); \
} \
struct __stupid_useless_struct_to_allow_trailing_semicolon
diff --git a/src/pulsecore/once.c b/src/pulsecore/once.c
index 05a3ad2c..4e509e0c 100644
--- a/src/pulsecore/once.c
+++ b/src/pulsecore/once.c
@@ -29,8 +29,6 @@
#include "once.h"
pa_bool_t pa_once_begin(pa_once *control) {
- pa_mutex *m;
-
pa_assert(control);
if (pa_atomic_load(&control->done))
@@ -43,6 +41,7 @@ pa_bool_t pa_once_begin(pa_once *control) {
* executed by us. Hence the awkward locking. */
for (;;) {
+ pa_mutex *m;
if ((m = pa_atomic_ptr_load(&control->mutex))) {
diff --git a/src/pulsecore/once.h b/src/pulsecore/once.h
index 50ac18c1..edc81881 100644
--- a/src/pulsecore/once.h
+++ b/src/pulsecore/once.h
@@ -22,7 +22,6 @@
USA.
***/
-#include <pulsecore/mutex.h>
#include <pulsecore/atomic.h>
typedef struct pa_once {
diff --git a/src/pulsecore/parseaddr.c b/src/pulsecore/parseaddr.c
index 44cd9a05..7ec068a4 100644
--- a/src/pulsecore/parseaddr.c
+++ b/src/pulsecore/parseaddr.c
@@ -25,14 +25,12 @@
#include <string.h>
#include <stdlib.h>
-#include <arpa/inet.h>
-#include <sys/socket.h>
#include <pulse/xmalloc.h>
-#include <pulse/util.h>
#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
+#include <pulsecore/arpa-inet.h>
#include "parseaddr.h"
diff --git a/src/pulsecore/pdispatch.c b/src/pulsecore/pdispatch.c
index d00106b4..9a9ef4e1 100644
--- a/src/pulsecore/pdispatch.c
+++ b/src/pulsecore/pdispatch.c
@@ -27,6 +27,7 @@
#include <stdio.h>
#include <stdlib.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
@@ -37,6 +38,7 @@
#include <pulsecore/macro.h>
#include <pulsecore/refcnt.h>
#include <pulsecore/flist.h>
+#include <pulsecore/core-rtclock.h>
#include "pdispatch.h"
@@ -88,7 +90,7 @@ static const char *command_names[PA_COMMAND_MAX] = {
[PA_COMMAND_SET_SINK_VOLUME] = "SET_SINK_VOLUME",
[PA_COMMAND_SET_SINK_INPUT_VOLUME] = "SET_SINK_INPUT_VOLUME",
- [PA_COMMAND_SET_SOURCE_VOLUME] = "SET_SOURCE_VOLME",
+ [PA_COMMAND_SET_SOURCE_VOLUME] = "SET_SOURCE_VOLUME",
[PA_COMMAND_SET_SINK_MUTE] = "SET_SINK_MUTE",
[PA_COMMAND_SET_SOURCE_MUTE] = "SET_SOURCE_MUTE",
@@ -167,7 +169,7 @@ static const char *command_names[PA_COMMAND_MAX] = {
/* Supported since protocol v14 (0.9.12) */
[PA_COMMAND_EXTENSION] = "EXTENSION",
-
+ /* Supported since protocol v15 (0.9.15) */
[PA_COMMAND_GET_CARD_INFO] = "GET_CARD_INFO",
[PA_COMMAND_GET_CARD_INFO_LIST] = "GET_CARD_INFO_LIST",
[PA_COMMAND_SET_CARD_PROFILE] = "SET_CARD_PROFILE",
@@ -178,7 +180,16 @@ static const char *command_names[PA_COMMAND_MAX] = {
/* SERVER->CLIENT */
[PA_COMMAND_PLAYBACK_BUFFER_ATTR_CHANGED] = "PLAYBACK_BUFFER_ATTR_CHANGED",
- [PA_COMMAND_RECORD_BUFFER_ATTR_CHANGED] = "RECORD_BUFFER_ATTR_CHANGED"
+ [PA_COMMAND_RECORD_BUFFER_ATTR_CHANGED] = "RECORD_BUFFER_ATTR_CHANGED",
+
+ /* Supported since protocol v16 (0.9.16) */
+ [PA_COMMAND_SET_SINK_PORT] = "SET_SINK_PORT",
+ [PA_COMMAND_SET_SOURCE_PORT] = "SET_SOURCE_PORT",
+
+ /* Supported since protocol v22 (1.0) */
+ [PA_COMMAND_SET_SOURCE_OUTPUT_VOLUME] = "SET_SOURCE_OUTPUT_VOLUME",
+ [PA_COMMAND_SET_SOURCE_OUTPUT_MUTE] = "SET_SOURCE_OUTPUT_MUTE",
+
};
#endif
@@ -201,9 +212,10 @@ struct pa_pdispatch {
const pa_pdispatch_cb_t *callback_table;
unsigned n_commands;
PA_LLIST_HEAD(struct reply_info, replies);
- pa_pdispatch_drain_callback drain_callback;
+ pa_pdispatch_drain_cb_t drain_callback;
void *drain_userdata;
const pa_creds *creds;
+ pa_bool_t use_rtclock;
};
static void reply_info_free(struct reply_info *r) {
@@ -220,21 +232,19 @@ static void reply_info_free(struct reply_info *r) {
pa_xfree(r);
}
-pa_pdispatch* pa_pdispatch_new(pa_mainloop_api *mainloop, const pa_pdispatch_cb_t*table, unsigned entries) {
+pa_pdispatch* pa_pdispatch_new(pa_mainloop_api *mainloop, pa_bool_t use_rtclock, const pa_pdispatch_cb_t *table, unsigned entries) {
pa_pdispatch *pd;
- pa_assert(mainloop);
+ pa_assert(mainloop);
pa_assert((entries && table) || (!entries && !table));
- pd = pa_xnew(pa_pdispatch, 1);
+ pd = pa_xnew0(pa_pdispatch, 1);
PA_REFCNT_INIT(pd);
pd->mainloop = mainloop;
pd->callback_table = table;
pd->n_commands = entries;
PA_LLIST_HEAD_INIT(struct reply_info, pd->replies);
- pd->drain_callback = NULL;
- pd->drain_userdata = NULL;
- pd->creds = NULL;
+ pd->use_rtclock = use_rtclock;
return pd;
}
@@ -304,7 +314,7 @@ int pa_pdispatch_run(pa_pdispatch *pd, pa_packet*packet, const pa_creds *creds,
if (command >= PA_COMMAND_MAX || !(p = command_names[command]))
pa_snprintf((char*) (p = t), sizeof(t), "%u", command);
- pa_log("[%p] Recieved opcode <%s>", pd, p);
+ pa_log("[%p] Received opcode <%s>", pd, p);
}
#endif
@@ -313,7 +323,7 @@ int pa_pdispatch_run(pa_pdispatch *pd, pa_packet*packet, const pa_creds *creds,
if (command == PA_COMMAND_ERROR || command == PA_COMMAND_REPLY) {
struct reply_info *r;
- for (r = pd->replies; r; r = r->next)
+ PA_LLIST_FOREACH(r, pd->replies)
if (r->tag == tag)
break;
@@ -321,11 +331,11 @@ int pa_pdispatch_run(pa_pdispatch *pd, pa_packet*packet, const pa_creds *creds,
run_action(pd, r, command, ts);
} else if (pd->callback_table && (command < pd->n_commands) && pd->callback_table[command]) {
- const pa_pdispatch_cb_t *c = pd->callback_table+command;
+ const pa_pdispatch_cb_t *cb = pd->callback_table+command;
- (*c)(pd, command, tag, ts, userdata);
+ (*cb)(pd, command, tag, ts, userdata);
} else {
- pa_log("Recieved unsupported command %u", command);
+ pa_log("Received unsupported command %u", command);
goto finish;
}
@@ -342,7 +352,7 @@ finish:
return ret;
}
-static void timeout_callback(pa_mainloop_api*m, pa_time_event*e, const struct timeval *tv, void *userdata) {
+static void timeout_callback(pa_mainloop_api*m, pa_time_event*e, const struct timeval *t, void *userdata) {
struct reply_info*r = userdata;
pa_assert(r);
@@ -371,10 +381,9 @@ void pa_pdispatch_register_reply(pa_pdispatch *pd, uint32_t tag, int timeout, pa
r->free_cb = free_cb;
r->tag = tag;
- pa_gettimeofday(&tv);
- tv.tv_sec += timeout;
-
- pa_assert_se(r->time_event = pd->mainloop->time_new(pd->mainloop, &tv, timeout_callback, r));
+ pa_assert_se(r->time_event = pd->mainloop->time_new(pd->mainloop,
+ pa_timeval_rtstore(&tv, pa_rtclock_now() + timeout * PA_USEC_PER_SEC, pd->use_rtclock),
+ timeout_callback, r));
PA_LLIST_PREPEND(struct reply_info, pd->replies, r);
}
@@ -386,7 +395,7 @@ int pa_pdispatch_is_pending(pa_pdispatch *pd) {
return !!pd->replies;
}
-void pa_pdispatch_set_drain_callback(pa_pdispatch *pd, void (*cb)(pa_pdispatch *pd, void *userdata), void *userdata) {
+void pa_pdispatch_set_drain_callback(pa_pdispatch *pd, pa_pdispatch_drain_cb_t cb, void *userdata) {
pa_assert(pd);
pa_assert(PA_REFCNT_VALUE(pd) >= 1);
pa_assert(!cb || pa_pdispatch_is_pending(pd));
@@ -401,12 +410,9 @@ void pa_pdispatch_unregister_reply(pa_pdispatch *pd, void *userdata) {
pa_assert(pd);
pa_assert(PA_REFCNT_VALUE(pd) >= 1);
- for (r = pd->replies; r; r = n) {
- n = r->next;
-
+ PA_LLIST_FOREACH_SAFE(r, n, pd->replies)
if (r->userdata == userdata)
reply_info_free(r);
- }
}
void pa_pdispatch_unref(pa_pdispatch *pd) {
diff --git a/src/pulsecore/pdispatch.h b/src/pulsecore/pdispatch.h
index 5c31d80e..c5431c2e 100644
--- a/src/pulsecore/pdispatch.h
+++ b/src/pulsecore/pdispatch.h
@@ -35,9 +35,9 @@
typedef struct pa_pdispatch pa_pdispatch;
typedef void (*pa_pdispatch_cb_t)(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata);
-typedef void (*pa_pdispatch_drain_callback)(pa_pdispatch *pd, void *userdata);
+typedef void (*pa_pdispatch_drain_cb_t)(pa_pdispatch *pd, void *userdata);
-pa_pdispatch* pa_pdispatch_new(pa_mainloop_api *m, const pa_pdispatch_cb_t*table, unsigned entries);
+pa_pdispatch* pa_pdispatch_new(pa_mainloop_api *m, pa_bool_t use_rtclock, const pa_pdispatch_cb_t *table, unsigned entries);
void pa_pdispatch_unref(pa_pdispatch *pd);
pa_pdispatch* pa_pdispatch_ref(pa_pdispatch *pd);
@@ -47,7 +47,7 @@ void pa_pdispatch_register_reply(pa_pdispatch *pd, uint32_t tag, int timeout, pa
int pa_pdispatch_is_pending(pa_pdispatch *pd);
-void pa_pdispatch_set_drain_callback(pa_pdispatch *pd, pa_pdispatch_drain_callback callback, void *userdata);
+void pa_pdispatch_set_drain_callback(pa_pdispatch *pd, pa_pdispatch_drain_cb_t callback, void *userdata);
/* Remove all reply slots with the give userdata parameter */
void pa_pdispatch_unregister_reply(pa_pdispatch *pd, void *userdata);
diff --git a/src/pulsecore/pid.c b/src/pulsecore/pid.c
index 00878462..50968dea 100644
--- a/src/pulsecore/pid.c
+++ b/src/pulsecore/pid.c
@@ -40,7 +40,6 @@
#endif
#include <pulse/xmalloc.h>
-#include <pulse/util.h>
#include <pulsecore/core-error.h>
#include <pulsecore/core-util.h>
@@ -81,17 +80,14 @@ static pid_t read_pid(const char *fn, int fd) {
}
static int open_pid_file(const char *fn, int mode) {
- int fd = -1;
+ int fd;
pa_assert(fn);
for (;;) {
struct stat st;
- if ((fd = open(fn, mode
-#ifdef O_NOCTTY
- |O_NOCTTY
-#endif
+ if ((fd = pa_open_cloexec(fn, mode
#ifdef O_NOFOLLOW
|O_NOFOLLOW
#endif
@@ -123,8 +119,6 @@ static int open_pid_file(const char *fn, int mode) {
fd = -1;
goto fail;
}
-
- fd = -1;
}
return fd;
@@ -148,7 +142,7 @@ static int proc_name_ours(pid_t pid, const char *procname) {
pa_snprintf(bn, sizeof(bn), "/proc/%lu/stat", (unsigned long) pid);
- if (!(f = fopen(bn, "r"))) {
+ if (!(f = pa_fopen_cloexec(bn, "r"))) {
pa_log_info("Failed to open %s: %s", bn, pa_cstrerror(errno));
return -1;
} else {
@@ -223,7 +217,7 @@ int pa_pid_file_create(const char *procname) {
if (procname)
if ((ours = proc_name_ours(pid, procname)) < 0) {
pa_log_warn("Could not check to see if pid %lu is a pulseaudio process. "
- "Asssuming it is and the daemon is already running.", (unsigned long) pid);
+ "Assuming it is and the daemon is already running.", (unsigned long) pid);
goto fail;
}
diff --git a/src/pulsecore/pipe.c b/src/pulsecore/pipe.c
index c21e4b1f..f873ef6b 100644
--- a/src/pulsecore/pipe.c
+++ b/src/pulsecore/pipe.c
@@ -29,11 +29,8 @@
#include <sys/types.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-
-#include "winsock.h"
+#include <pulsecore/socket.h>
+#include <pulsecore/core-util.h>
#include "pipe.h"
diff --git a/src/pulsecore/play-memblockq.c b/src/pulsecore/play-memblockq.c
index fceb2ca1..b0932612 100644
--- a/src/pulsecore/play-memblockq.c
+++ b/src/pulsecore/play-memblockq.c
@@ -25,14 +25,11 @@
#include <stdlib.h>
#include <stdio.h>
-#include <string.h>
#include <pulse/xmalloc.h>
-#include <pulse/gccmacro.h>
#include <pulsecore/sink-input.h>
#include <pulsecore/thread-mq.h>
-#include <pulsecore/sample-util.h>
#include "play-memblockq.h"
@@ -47,9 +44,8 @@ enum {
MEMBLOCKQ_STREAM_MESSAGE_UNLINK,
};
-PA_DECLARE_CLASS(memblockq_stream);
+PA_DEFINE_PRIVATE_CLASS(memblockq_stream, pa_msgobject);
#define MEMBLOCKQ_STREAM(o) (memblockq_stream_cast(o))
-static PA_DEFINE_CHECK_TYPE(memblockq_stream, pa_msgobject);
static void memblockq_stream_unlink(memblockq_stream *u) {
pa_assert(u);
@@ -136,6 +132,15 @@ static int sink_input_pop_cb(pa_sink_input *i, size_t nbytes, pa_memchunk *chunk
return -1;
}
+ /* If there's no memblock, there's going to be data in the memblockq after
+ * a gap with length chunk->length. Drop the the gap and peek the actual
+ * data. There should always be some data coming - hence the assert. The
+ * gap will occur if the memblockq is rewound beyond index 0.*/
+ if (!chunk->memblock) {
+ pa_memblockq_drop(u->memblockq, chunk->length);
+ pa_assert_se(pa_memblockq_peek(u->memblockq, chunk) >= 0);
+ }
+
chunk->length = PA_MIN(chunk->length, nbytes);
pa_memblockq_drop(u->memblockq, chunk->length);
@@ -174,7 +179,8 @@ pa_sink_input* pa_memblockq_sink_input_new(
const pa_channel_map *map,
pa_memblockq *q,
pa_cvolume *volume,
- pa_proplist *p) {
+ pa_proplist *p,
+ pa_sink_input_flags_t flags) {
memblockq_stream *u = NULL;
pa_sink_input_new_data data;
@@ -193,14 +199,15 @@ pa_sink_input* pa_memblockq_sink_input_new(
u->memblockq = NULL;
pa_sink_input_new_data_init(&data);
- data.sink = sink;
+ pa_sink_input_new_data_set_sink(&data, sink, FALSE);
data.driver = __FILE__;
pa_sink_input_new_data_set_sample_spec(&data, ss);
pa_sink_input_new_data_set_channel_map(&data, map);
pa_sink_input_new_data_set_volume(&data, volume);
pa_proplist_update(data.proplist, PA_UPDATE_REPLACE, p);
+ data.flags |= flags;
- pa_sink_input_new(&u->sink_input, sink->core, &data, 0);
+ pa_sink_input_new(&u->sink_input, sink->core, &data);
pa_sink_input_new_data_done(&data);
if (!u->sink_input)
@@ -238,6 +245,7 @@ int pa_play_memblockq(
pa_memblockq *q,
pa_cvolume *volume,
pa_proplist *p,
+ pa_sink_input_flags_t flags,
uint32_t *sink_input_index) {
pa_sink_input *i;
@@ -246,7 +254,7 @@ int pa_play_memblockq(
pa_assert(ss);
pa_assert(q);
- if (!(i = pa_memblockq_sink_input_new(sink, ss, map, q, volume, p)))
+ if (!(i = pa_memblockq_sink_input_new(sink, ss, map, q, volume, p, flags)))
return -1;
pa_sink_input_put(i);
diff --git a/src/pulsecore/play-memblockq.h b/src/pulsecore/play-memblockq.h
index 9d5f40fd..a55fed0d 100644
--- a/src/pulsecore/play-memblockq.h
+++ b/src/pulsecore/play-memblockq.h
@@ -31,17 +31,19 @@ pa_sink_input* pa_memblockq_sink_input_new(
const pa_channel_map *map,
pa_memblockq *q,
pa_cvolume *volume,
- pa_proplist *p);
+ pa_proplist *p,
+ pa_sink_input_flags_t flags);
void pa_memblockq_sink_input_set_queue(pa_sink_input *i, pa_memblockq *q);
int pa_play_memblockq(
- pa_sink *sink,
- const pa_sample_spec *ss,
- const pa_channel_map *map,
- pa_memblockq *q,
- pa_cvolume *cvolume,
- pa_proplist *p,
- uint32_t *sink_input_index);
+ pa_sink *sink,
+ const pa_sample_spec *ss,
+ const pa_channel_map *map,
+ pa_memblockq *q,
+ pa_cvolume *cvolume,
+ pa_proplist *p,
+ pa_sink_input_flags_t flags,
+ uint32_t *sink_input_index);
#endif
diff --git a/src/pulsecore/play-memchunk.c b/src/pulsecore/play-memchunk.c
index f127d7a4..ee25958f 100644
--- a/src/pulsecore/play-memchunk.c
+++ b/src/pulsecore/play-memchunk.c
@@ -25,13 +25,8 @@
#include <stdlib.h>
#include <stdio.h>
-#include <string.h>
-
-#include <pulse/xmalloc.h>
-#include <pulse/gccmacro.h>
#include <pulsecore/sink-input.h>
-#include <pulsecore/thread-mq.h>
#include <pulsecore/play-memblockq.h>
#include "play-memchunk.h"
@@ -43,19 +38,24 @@ int pa_play_memchunk(
const pa_memchunk *chunk,
pa_cvolume *volume,
pa_proplist *p,
+ pa_sink_input_flags_t flags,
uint32_t *sink_input_index) {
pa_memblockq *q;
int r;
+ pa_memchunk silence;
pa_assert(sink);
pa_assert(ss);
pa_assert(chunk);
- q = pa_memblockq_new(0, chunk->length, 0, pa_frame_size(ss), 1, 1, 0, NULL);
+ pa_silence_memchunk_get(&sink->core->silence_cache, sink->core->mempool, &silence, ss, 0);
+ q = pa_memblockq_new(0, chunk->length, 0, pa_frame_size(ss), 1, 1, 0, &silence);
+ pa_memblock_unref(silence.memblock);
+
pa_assert_se(pa_memblockq_push(q, chunk) >= 0);
- if ((r = pa_play_memblockq(sink, ss, map, q, volume, p, sink_input_index)) < 0) {
+ if ((r = pa_play_memblockq(sink, ss, map, q, volume, p, flags, sink_input_index)) < 0) {
pa_memblockq_free(q);
return r;
}
diff --git a/src/pulsecore/play-memchunk.h b/src/pulsecore/play-memchunk.h
index c813611e..068add1f 100644
--- a/src/pulsecore/play-memchunk.h
+++ b/src/pulsecore/play-memchunk.h
@@ -26,12 +26,13 @@
#include <pulsecore/memchunk.h>
int pa_play_memchunk(
- pa_sink *sink,
- const pa_sample_spec *ss,
- const pa_channel_map *map,
- const pa_memchunk *chunk,
- pa_cvolume *cvolume,
- pa_proplist *p,
- uint32_t *sink_input_index);
+ pa_sink *sink,
+ const pa_sample_spec *ss,
+ const pa_channel_map *map,
+ const pa_memchunk *chunk,
+ pa_cvolume *cvolume,
+ pa_proplist *p,
+ pa_sink_input_flags_t flags,
+ uint32_t *sink_input_index);
#endif
diff --git a/src/pulsecore/poll.c b/src/pulsecore/poll.c
index 46a69c5f..d5abb04d 100644
--- a/src/pulsecore/poll.c
+++ b/src/pulsecore/poll.c
@@ -35,27 +35,38 @@
#include <config.h>
#endif
+#ifdef HAVE_SYS_IOCTL_H
+#include <sys/ioctl.h>
+#endif
+
#include <errno.h>
+#include <fcntl.h>
#ifdef HAVE_SYS_SELECT_H
#include <sys/select.h>
#endif
-#include "winsock.h"
-
-#ifndef HAVE_POLL_H
-
+#include <pulsecore/socket.h>
#include <pulsecore/core-util.h>
+#include <pulse/util.h>
#include "poll.h"
-int poll (struct pollfd *fds, unsigned long int nfds, int timeout) {
+/* Mac OSX fails to implement poll() in a working way since 10.4. IOW, for
+ * several years. We need to enable a dirty workaround and emulate that call
+ * with select(), just like for Windows. sic! */
+
+#if !defined(HAVE_POLL_H) || defined(OS_IS_DARWIN)
+
+int pa_poll (struct pollfd *fds, unsigned long int nfds, int timeout) {
struct timeval tv;
fd_set rset, wset, xset;
struct pollfd *f;
int ready;
int maxfd = 0;
+#ifdef OS_IS_WIN32
char data[64];
+#endif
FD_ZERO (&rset);
FD_ZERO (&wset);
@@ -95,18 +106,24 @@ int poll (struct pollfd *fds, unsigned long int nfds, int timeout) {
tv.tv_sec = timeout / 1000;
tv.tv_usec = (timeout % 1000) * 1000;
- ready = select ((SELECT_TYPE_ARG1) maxfd + 1, SELECT_TYPE_ARG234 &rset,
+ ready = select((SELECT_TYPE_ARG1) maxfd + 1, SELECT_TYPE_ARG234 &rset,
SELECT_TYPE_ARG234 &wset, SELECT_TYPE_ARG234 &xset,
SELECT_TYPE_ARG5 (timeout == -1 ? NULL : &tv));
+
if ((ready == -1) && (errno == EBADF)) {
ready = 0;
+ maxfd = -1;
+
+#ifdef OS_IS_WIN32
+ /*
+ * Windows has no fcntl(), so we have to trick around with more
+ * select() calls to find out what went wrong
+ */
FD_ZERO (&rset);
FD_ZERO (&wset);
FD_ZERO (&xset);
- maxfd = -1;
-
for (f = fds; f < &fds[nfds]; ++f) {
if (f->fd != -1) {
fd_set sngl_rset, sngl_wset, sngl_xset;
@@ -145,11 +162,30 @@ int poll (struct pollfd *fds, unsigned long int nfds, int timeout) {
}
}
+#else /* !OS_IS_WIN32 */
+
+ for (f = fds; f < &fds[nfds]; f++)
+ if (f->fd != -1) {
+ /* use fcntl() to find out whether the descriptor is valid */
+ if (fcntl(f->fd, F_GETFL) != -1) {
+ if (f->fd > maxfd && (f->events & (POLLIN|POLLOUT|POLLPRI))) {
+ maxfd = f->fd;
+ ready++;
+ }
+ } else {
+ FD_CLR(f->fd, &rset);
+ FD_CLR(f->fd, &wset);
+ FD_CLR(f->fd, &xset);
+ }
+ }
+
+#endif
+
if (ready) {
/* Linux alters the tv struct... but it shouldn't matter here ...
* as we're going to be a little bit out anyway as we've just eaten
* more than a couple of cpu cycles above */
- ready = select ((SELECT_TYPE_ARG1) maxfd + 1, SELECT_TYPE_ARG234 &rset,
+ ready = select((SELECT_TYPE_ARG1) maxfd + 1, SELECT_TYPE_ARG234 &rset,
SELECT_TYPE_ARG234 &wset, SELECT_TYPE_ARG234 &xset,
SELECT_TYPE_ARG5 (timeout == -1 ? NULL : &tv));
}
@@ -160,6 +196,8 @@ int poll (struct pollfd *fds, unsigned long int nfds, int timeout) {
#endif
if (ready > 0) {
+ int r;
+
ready = 0;
for (f = fds; f < &fds[nfds]; ++f) {
f->revents = 0;
@@ -167,6 +205,18 @@ int poll (struct pollfd *fds, unsigned long int nfds, int timeout) {
if (FD_ISSET (f->fd, &rset)) {
/* support for POLLHUP. An hung up descriptor does not
increase the return value! */
+#ifdef OS_IS_DARWIN
+ /* There is a bug in Mac OS X that causes it to ignore MSG_PEEK
+ * for some kinds of descriptors. Detect if this descriptor is a
+ * connected socket, a server socket, or something else using a
+ * 0-byte recv, and use ioctl(2) to detect POLLHUP. */
+ r = recv(f->fd, NULL, 0, MSG_PEEK);
+ if (r == 0 || (r < 0 && errno == ENOTSOCK))
+ ioctl(f->fd, FIONREAD, &r);
+
+ if (r == 0)
+ f->revents |= POLLHUP;
+#else /* !OS_IS_DARWIN */
if (recv (f->fd, data, 64, MSG_PEEK) == -1) {
if (errno == ESHUTDOWN || errno == ECONNRESET ||
errno == ECONNABORTED || errno == ENETRESET) {
@@ -174,6 +224,7 @@ int poll (struct pollfd *fds, unsigned long int nfds, int timeout) {
f->revents |= POLLHUP;
}
}
+#endif
if (f->revents == 0)
f->revents |= POLLIN;
diff --git a/src/pulsecore/poll.h b/src/pulsecore/poll.h
index fe0c6af6..dc741e5e 100644
--- a/src/pulsecore/poll.h
+++ b/src/pulsecore/poll.h
@@ -24,6 +24,10 @@
Copyright (C) 1994,96,97,98,99,2000,2001,2004 Free Software Foundation, Inc.
***/
+#if defined(HAVE_POLL_H)
+#include <poll.h>
+#else
+
/* Event types that can be polled for. These bits may be set in `events'
to indicate the interesting event types; they will appear in `revents'
to indicate the status of the file descriptor. */
@@ -38,21 +42,24 @@
#define POLLHUP 0x010 /* Hung up. */
#define POLLNVAL 0x020 /* Invalid polling request. */
-
-/* Type used for the number of file descriptors. */
-typedef unsigned long int nfds_t;
-
/* Data structure describing a polling request. */
-struct pollfd
- {
+struct pollfd {
int fd; /* File descriptor to poll. */
short int events; /* Types of events poller cares about. */
short int revents; /* Types of events that actually occurred. */
- };
+};
+
/* Poll the file descriptors described by the NFDS structures starting at
FDS. If TIMEOUT is nonzero and not -1, allow TIMEOUT milliseconds for
an event to occur; if TIMEOUT is -1, block until an event occurs.
Returns the number of file descriptors with events, zero if timed out,
or -1 for errors. */
-extern int poll (struct pollfd *__fds, nfds_t __nfds, int __timeout);
+
+#endif /* HAVE_POLL_H */
+
+#if defined(HAVE_POLL_H) && !defined(OS_IS_DARWIN)
+#define pa_poll(fds,nfds,timeout) poll((fds),(nfds),(timeout))
+#else
+int pa_poll(struct pollfd *fds, unsigned long nfds, int timeout);
+#endif
diff --git a/src/pulsecore/prioq.h b/src/pulsecore/prioq.h
index fd3550b7..4df5e04b 100644
--- a/src/pulsecore/prioq.h
+++ b/src/pulsecore/prioq.h
@@ -22,8 +22,6 @@
USA.
***/
-#include <inttypes.h>
-
#include <pulsecore/macro.h>
#include <pulsecore/idxset.h>
diff --git a/src/pulsecore/proplist-util.c b/src/pulsecore/proplist-util.c
index d9769bc7..642c498c 100644
--- a/src/pulsecore/proplist-util.c
+++ b/src/pulsecore/proplist-util.c
@@ -25,7 +25,7 @@
#include <string.h>
#include <locale.h>
-#include <dlfcn.h>
+#include <libintl.h>
#ifdef __APPLE__
#include <crt_externs.h>
@@ -186,10 +186,12 @@ void pa_init_proplist(pa_proplist *p) {
}
if (!pa_proplist_contains(p, PA_PROP_APPLICATION_PROCESS_BINARY)) {
- char t[PATH_MAX];
- if (pa_get_binary_name(t, sizeof(t))) {
+ char *t;
+
+ if ((t = pa_get_binary_name_malloc())) {
char *c = pa_utf8_filter(t);
pa_proplist_sets(p, PA_PROP_APPLICATION_PROCESS_BINARY, c);
+ pa_xfree(t);
pa_xfree(c);
}
}
diff --git a/src/pulsecore/protocol-dbus.c b/src/pulsecore/protocol-dbus.c
new file mode 100644
index 00000000..8784c345
--- /dev/null
+++ b/src/pulsecore/protocol-dbus.c
@@ -0,0 +1,1167 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <dbus/dbus.h>
+
+#include <pulse/xmalloc.h>
+
+#include <pulsecore/core-util.h>
+#include <pulsecore/dbus-util.h>
+#include <pulsecore/hashmap.h>
+#include <pulsecore/idxset.h>
+#include <pulsecore/shared.h>
+#include <pulsecore/strbuf.h>
+
+#include "protocol-dbus.h"
+
+struct pa_dbus_protocol {
+ PA_REFCNT_DECLARE;
+
+ pa_core *core;
+ pa_hashmap *objects; /* Object path -> struct object_entry */
+ pa_hashmap *connections; /* DBusConnection -> struct connection_entry */
+ pa_idxset *extensions; /* Strings */
+
+ pa_hook hooks[PA_DBUS_PROTOCOL_HOOK_MAX];
+};
+
+struct object_entry {
+ char *path;
+ pa_hashmap *interfaces; /* Interface name -> struct interface_entry */
+ char *introspection;
+};
+
+struct connection_entry {
+ DBusConnection *connection;
+ pa_client *client;
+
+ pa_bool_t listening_for_all_signals;
+
+ /* Contains object paths. If this is empty, then signals from all objects
+ * are accepted. Only used when listening_for_all_signals == TRUE. */
+ pa_idxset *all_signals_objects;
+
+ /* Signal name -> signal paths entry. The entries contain object paths. If
+ * a path set is empty, then that signal is accepted from all objects. This
+ * variable is only used when listening_for_all_signals == FALSE. */
+ pa_hashmap *listening_signals;
+};
+
+/* Only used in connection entries' listening_signals hashmap. */
+struct signal_paths_entry {
+ char *signal;
+ pa_idxset *paths;
+};
+
+struct interface_entry {
+ char *name;
+ pa_hashmap *method_handlers;
+ pa_hashmap *method_signatures; /* Derived from method_handlers. Contains only "in" arguments. */
+ pa_hashmap *property_handlers;
+ pa_dbus_receive_cb_t get_all_properties_cb;
+ pa_dbus_signal_info *signals;
+ unsigned n_signals;
+ void *userdata;
+};
+
+char *pa_get_dbus_address_from_server_type(pa_server_type_t server_type) {
+ char *address = NULL;
+ char *runtime_path = NULL;
+ char *escaped_path = NULL;
+
+ switch (server_type) {
+ case PA_SERVER_TYPE_USER:
+ pa_assert_se((runtime_path = pa_runtime_path(PA_DBUS_SOCKET_NAME)));
+ pa_assert_se((escaped_path = dbus_address_escape_value(runtime_path)));
+ address = pa_sprintf_malloc("unix:path=%s", escaped_path);
+ break;
+
+ case PA_SERVER_TYPE_SYSTEM:
+ pa_assert_se((escaped_path = dbus_address_escape_value(PA_DBUS_SYSTEM_SOCKET_PATH)));
+ address = pa_sprintf_malloc("unix:path=%s", escaped_path);
+ break;
+
+ case PA_SERVER_TYPE_NONE:
+ address = pa_xnew0(char, 1);
+ break;
+
+ default:
+ pa_assert_not_reached();
+ }
+
+ pa_xfree(runtime_path);
+ pa_xfree(escaped_path);
+
+ return address;
+}
+
+static pa_dbus_protocol *dbus_protocol_new(pa_core *c) {
+ pa_dbus_protocol *p;
+ unsigned i;
+
+ pa_assert(c);
+
+ p = pa_xnew(pa_dbus_protocol, 1);
+ PA_REFCNT_INIT(p);
+ p->core = c;
+ p->objects = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ p->connections = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
+ p->extensions = pa_idxset_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ for (i = 0; i < PA_DBUS_PROTOCOL_HOOK_MAX; ++i)
+ pa_hook_init(&p->hooks[i], p);
+
+ pa_assert_se(pa_shared_set(c, "dbus-protocol", p) >= 0);
+
+ return p;
+}
+
+pa_dbus_protocol* pa_dbus_protocol_get(pa_core *c) {
+ pa_dbus_protocol *p;
+
+ if ((p = pa_shared_get(c, "dbus-protocol")))
+ return pa_dbus_protocol_ref(p);
+
+ return dbus_protocol_new(c);
+}
+
+pa_dbus_protocol* pa_dbus_protocol_ref(pa_dbus_protocol *p) {
+ pa_assert(p);
+ pa_assert(PA_REFCNT_VALUE(p) >= 1);
+
+ PA_REFCNT_INC(p);
+
+ return p;
+}
+
+void pa_dbus_protocol_unref(pa_dbus_protocol *p) {
+ unsigned i;
+
+ pa_assert(p);
+ pa_assert(PA_REFCNT_VALUE(p) >= 1);
+
+ if (PA_REFCNT_DEC(p) > 0)
+ return;
+
+ pa_assert(pa_hashmap_isempty(p->objects));
+ pa_assert(pa_hashmap_isempty(p->connections));
+ pa_assert(pa_idxset_isempty(p->extensions));
+
+ pa_hashmap_free(p->objects, NULL, NULL);
+ pa_hashmap_free(p->connections, NULL, NULL);
+ pa_idxset_free(p->extensions, NULL, NULL);
+
+ for (i = 0; i < PA_DBUS_PROTOCOL_HOOK_MAX; ++i)
+ pa_hook_done(&p->hooks[i]);
+
+ pa_assert_se(pa_shared_remove(p->core, "dbus-protocol") >= 0);
+
+ pa_xfree(p);
+}
+
+static void update_introspection(struct object_entry *oe) {
+ pa_strbuf *buf;
+ void *interfaces_state = NULL;
+ struct interface_entry *iface_entry = NULL;
+
+ pa_assert(oe);
+
+ buf = pa_strbuf_new();
+ pa_strbuf_puts(buf, DBUS_INTROSPECT_1_0_XML_DOCTYPE_DECL_NODE);
+ pa_strbuf_puts(buf, "<node>\n");
+
+ PA_HASHMAP_FOREACH(iface_entry, oe->interfaces, interfaces_state) {
+ pa_dbus_method_handler *method_handler;
+ pa_dbus_property_handler *property_handler;
+ void *handlers_state = NULL;
+ unsigned i;
+ unsigned j;
+
+ pa_strbuf_printf(buf, " <interface name=\"%s\">\n", iface_entry->name);
+
+ PA_HASHMAP_FOREACH(method_handler, iface_entry->method_handlers, handlers_state) {
+ pa_strbuf_printf(buf, " <method name=\"%s\">\n", method_handler->method_name);
+
+ for (i = 0; i < method_handler->n_arguments; ++i)
+ pa_strbuf_printf(buf, " <arg name=\"%s\" type=\"%s\" direction=\"%s\"/>\n",
+ method_handler->arguments[i].name,
+ method_handler->arguments[i].type,
+ method_handler->arguments[i].direction);
+
+ pa_strbuf_puts(buf, " </method>\n");
+ }
+
+ handlers_state = NULL;
+
+ PA_HASHMAP_FOREACH(property_handler, iface_entry->property_handlers, handlers_state)
+ pa_strbuf_printf(buf, " <property name=\"%s\" type=\"%s\" access=\"%s\"/>\n",
+ property_handler->property_name,
+ property_handler->type,
+ property_handler->get_cb ? (property_handler->set_cb ? "readwrite" : "read") : "write");
+
+ for (i = 0; i < iface_entry->n_signals; ++i) {
+ pa_strbuf_printf(buf, " <signal name=\"%s\">\n", iface_entry->signals[i].name);
+
+ for (j = 0; j < iface_entry->signals[i].n_arguments; ++j)
+ pa_strbuf_printf(buf, " <arg name=\"%s\" type=\"%s\"/>\n", iface_entry->signals[i].arguments[j].name,
+ iface_entry->signals[i].arguments[j].type);
+
+ pa_strbuf_puts(buf, " </signal>\n");
+ }
+
+ pa_strbuf_puts(buf, " </interface>\n");
+ }
+
+ pa_strbuf_puts(buf, " <interface name=\"" DBUS_INTERFACE_INTROSPECTABLE "\">\n"
+ " <method name=\"Introspect\">\n"
+ " <arg name=\"data\" type=\"s\" direction=\"out\"/>\n"
+ " </method>\n"
+ " </interface>\n"
+ " <interface name=\"" DBUS_INTERFACE_PROPERTIES "\">\n"
+ " <method name=\"Get\">\n"
+ " <arg name=\"interface_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"property_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"value\" type=\"v\" direction=\"out\"/>\n"
+ " </method>\n"
+ " <method name=\"Set\">\n"
+ " <arg name=\"interface_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"property_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"value\" type=\"v\" direction=\"in\"/>\n"
+ " </method>\n"
+ " <method name=\"GetAll\">\n"
+ " <arg name=\"interface_name\" type=\"s\" direction=\"in\"/>\n"
+ " <arg name=\"props\" type=\"a{sv}\" direction=\"out\"/>\n"
+ " </method>\n"
+ " </interface>\n");
+
+ pa_strbuf_puts(buf, "</node>\n");
+
+ pa_xfree(oe->introspection);
+ oe->introspection = pa_strbuf_tostring_free(buf);
+}
+
+/* Return value of find_handler() and its subfunctions. */
+enum find_result_t {
+ /* The received message is a valid .Get call. */
+ FOUND_GET_PROPERTY,
+
+ /* The received message is a valid .Set call. */
+ FOUND_SET_PROPERTY,
+
+ /* The received message is a valid .GetAll call. */
+ FOUND_GET_ALL,
+
+ /* The received message is a valid method call. */
+ FOUND_METHOD,
+
+ /* The interface of the received message hasn't been registered for the
+ * destination object. */
+ NO_SUCH_INTERFACE,
+
+ /* No property handler was found for the received .Get or .Set call. */
+ NO_SUCH_PROPERTY,
+
+ /* The interface argument of a property call didn't match any registered
+ * interface. */
+ NO_SUCH_PROPERTY_INTERFACE,
+
+ /* The received message called .Get or .Set for a property whose access
+ * mode doesn't match the call. */
+ PROPERTY_ACCESS_DENIED,
+
+ /* The new value signature of a .Set call didn't match the expexted
+ * signature. */
+ INVALID_PROPERTY_SIG,
+
+ /* No method handler was found for the received message. */
+ NO_SUCH_METHOD,
+
+ /* The signature of the received message didn't match the expected
+ * signature. Despite the name, this can also be returned for a property
+ * call if its message signature is invalid. */
+ INVALID_METHOD_SIG
+};
+
+/* Data for resolving the correct reaction to a received message. */
+struct call_info {
+ DBusMessage *message; /* The received message. */
+ struct object_entry *obj_entry;
+ const char *interface; /* Destination interface name (extracted from the message). */
+ struct interface_entry *iface_entry;
+
+ const char *property; /* Property name (extracted from the message). */
+ const char *property_interface; /* The interface argument of a property call is stored here. */
+ pa_dbus_property_handler *property_handler;
+ const char *expected_property_sig; /* Property signature from the introspection data. */
+ const char *property_sig; /* The signature of the new value in the received .Set message. */
+ DBusMessageIter variant_iter; /* Iterator pointing to the beginning of the new value variant of a .Set call. */
+
+ const char *method; /* Method name (extracted from the message). */
+ pa_dbus_method_handler *method_handler;
+ const char *expected_method_sig; /* Method signature from the introspection data. */
+ const char *method_sig; /* The signature of the received message. */
+};
+
+/* Called when call_info->property has been set and the property interface has
+ * not been given. In case of a Set call, call_info->property_sig is also set,
+ * which is checked against the expected value in this function. */
+static enum find_result_t find_handler_by_property(struct call_info *call_info) {
+ void *state = NULL;
+
+ pa_assert(call_info);
+
+ PA_HASHMAP_FOREACH(call_info->iface_entry, call_info->obj_entry->interfaces, state) {
+ if ((call_info->property_handler = pa_hashmap_get(call_info->iface_entry->property_handlers, call_info->property))) {
+ if (pa_streq(call_info->method, "Get"))
+ return call_info->property_handler->get_cb ? FOUND_GET_PROPERTY : PROPERTY_ACCESS_DENIED;
+
+ else if (pa_streq(call_info->method, "Set")) {
+ call_info->expected_property_sig = call_info->property_handler->type;
+
+ if (pa_streq(call_info->property_sig, call_info->expected_property_sig))
+ return call_info->property_handler->set_cb ? FOUND_SET_PROPERTY : PROPERTY_ACCESS_DENIED;
+ else
+ return INVALID_PROPERTY_SIG;
+
+ } else
+ pa_assert_not_reached();
+ }
+ }
+
+ return NO_SUCH_PROPERTY;
+}
+
+static enum find_result_t find_handler_by_method(struct call_info *call_info) {
+ void *state = NULL;
+
+ pa_assert(call_info);
+
+ PA_HASHMAP_FOREACH(call_info->iface_entry, call_info->obj_entry->interfaces, state) {
+ if ((call_info->method_handler = pa_hashmap_get(call_info->iface_entry->method_handlers, call_info->method))) {
+ call_info->expected_method_sig = pa_hashmap_get(call_info->iface_entry->method_signatures, call_info->method);
+
+ if (pa_streq(call_info->method_sig, call_info->expected_method_sig))
+ return FOUND_METHOD;
+ else
+ return INVALID_METHOD_SIG;
+ }
+ }
+
+ return NO_SUCH_METHOD;
+}
+
+static enum find_result_t find_handler_from_properties_call(struct call_info *call_info) {
+ pa_assert(call_info);
+
+ if (pa_streq(call_info->method, "GetAll")) {
+ call_info->expected_method_sig = "s";
+ if (!pa_streq(call_info->method_sig, call_info->expected_method_sig))
+ return INVALID_METHOD_SIG;
+
+ pa_assert_se(dbus_message_get_args(call_info->message, NULL,
+ DBUS_TYPE_STRING, &call_info->property_interface,
+ DBUS_TYPE_INVALID));
+
+ if (*call_info->property_interface) {
+ if ((call_info->iface_entry = pa_hashmap_get(call_info->obj_entry->interfaces, call_info->property_interface)))
+ return FOUND_GET_ALL;
+ else
+ return NO_SUCH_PROPERTY_INTERFACE;
+
+ } else {
+ pa_assert_se(call_info->iface_entry = pa_hashmap_first(call_info->obj_entry->interfaces));
+ return FOUND_GET_ALL;
+ }
+
+ } else if (pa_streq(call_info->method, "Get")) {
+ call_info->expected_method_sig = "ss";
+ if (!pa_streq(call_info->method_sig, call_info->expected_method_sig))
+ return INVALID_METHOD_SIG;
+
+ pa_assert_se(dbus_message_get_args(call_info->message, NULL,
+ DBUS_TYPE_STRING, &call_info->property_interface,
+ DBUS_TYPE_STRING, &call_info->property,
+ DBUS_TYPE_INVALID));
+
+ if (*call_info->property_interface) {
+ if (!(call_info->iface_entry = pa_hashmap_get(call_info->obj_entry->interfaces, call_info->property_interface)))
+ return NO_SUCH_PROPERTY_INTERFACE;
+ else if ((call_info->property_handler =
+ pa_hashmap_get(call_info->iface_entry->property_handlers, call_info->property)))
+ return call_info->property_handler->get_cb ? FOUND_GET_PROPERTY : PROPERTY_ACCESS_DENIED;
+ else
+ return NO_SUCH_PROPERTY;
+
+ } else
+ return find_handler_by_property(call_info);
+
+ } else if (pa_streq(call_info->method, "Set")) {
+ DBusMessageIter msg_iter;
+
+ call_info->expected_method_sig = "ssv";
+ if (!pa_streq(call_info->method_sig, call_info->expected_method_sig))
+ return INVALID_METHOD_SIG;
+
+ pa_assert_se(dbus_message_iter_init(call_info->message, &msg_iter));
+
+ dbus_message_iter_get_basic(&msg_iter, &call_info->property_interface);
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+ dbus_message_iter_get_basic(&msg_iter, &call_info->property);
+ pa_assert_se(dbus_message_iter_next(&msg_iter));
+
+ dbus_message_iter_recurse(&msg_iter, &call_info->variant_iter);
+
+ call_info->property_sig = dbus_message_iter_get_signature(&call_info->variant_iter);
+
+ if (*call_info->property_interface) {
+ if (!(call_info->iface_entry = pa_hashmap_get(call_info->obj_entry->interfaces, call_info->property_interface)))
+ return NO_SUCH_PROPERTY_INTERFACE;
+
+ else if ((call_info->property_handler =
+ pa_hashmap_get(call_info->iface_entry->property_handlers, call_info->property))) {
+ call_info->expected_property_sig = call_info->property_handler->type;
+
+ if (pa_streq(call_info->property_sig, call_info->expected_property_sig))
+ return call_info->property_handler->set_cb ? FOUND_SET_PROPERTY : PROPERTY_ACCESS_DENIED;
+ else
+ return INVALID_PROPERTY_SIG;
+
+ } else
+ return NO_SUCH_PROPERTY;
+
+ } else
+ return find_handler_by_property(call_info);
+
+ } else
+ pa_assert_not_reached();
+}
+
+static enum find_result_t find_handler(struct call_info *call_info) {
+ pa_assert(call_info);
+
+ if (call_info->interface) {
+ if (pa_streq(call_info->interface, DBUS_INTERFACE_PROPERTIES))
+ return find_handler_from_properties_call(call_info);
+
+ else if (!(call_info->iface_entry = pa_hashmap_get(call_info->obj_entry->interfaces, call_info->interface)))
+ return NO_SUCH_INTERFACE;
+
+ else if ((call_info->method_handler = pa_hashmap_get(call_info->iface_entry->method_handlers, call_info->method)))
+ return FOUND_METHOD;
+
+ else
+ return NO_SUCH_METHOD;
+
+ } else { /* The method call doesn't contain an interface. */
+ if (pa_streq(call_info->method, "Get") || pa_streq(call_info->method, "Set") || pa_streq(call_info->method, "GetAll")) {
+ if (find_handler_by_method(call_info) == FOUND_METHOD)
+ /* The object has a method named Get, Set or GetAll in some other interface than .Properties. */
+ return FOUND_METHOD;
+ else
+ /* Assume this is a .Properties call. */
+ return find_handler_from_properties_call(call_info);
+
+ } else /* This is not a .Properties call. */
+ return find_handler_by_method(call_info);
+ }
+}
+
+static DBusHandlerResult handle_message_cb(DBusConnection *connection, DBusMessage *message, void *user_data) {
+ pa_dbus_protocol *p = user_data;
+ struct call_info call_info;
+
+ pa_assert(connection);
+ pa_assert(message);
+ pa_assert(p);
+ pa_assert(p->objects);
+
+ if (dbus_message_get_type(message) != DBUS_MESSAGE_TYPE_METHOD_CALL)
+ return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
+
+ pa_log_debug("Received message: destination = %s, interface = %s, member = %s",
+ dbus_message_get_path(message),
+ dbus_message_get_interface(message),
+ dbus_message_get_member(message));
+
+ call_info.message = message;
+ pa_assert_se(call_info.obj_entry = pa_hashmap_get(p->objects, dbus_message_get_path(message)));
+ call_info.interface = dbus_message_get_interface(message);
+ pa_assert_se(call_info.method = dbus_message_get_member(message));
+ pa_assert_se(call_info.method_sig = dbus_message_get_signature(message));
+
+ if (dbus_message_is_method_call(message, "org.freedesktop.DBus.Introspectable", "Introspect") ||
+ (!dbus_message_get_interface(message) && dbus_message_has_member(message, "Introspect"))) {
+ pa_dbus_send_basic_value_reply(connection, message, DBUS_TYPE_STRING, &call_info.obj_entry->introspection);
+ goto finish;
+ }
+
+ switch (find_handler(&call_info)) {
+ case FOUND_GET_PROPERTY:
+ call_info.property_handler->get_cb(connection, message, call_info.iface_entry->userdata);
+ break;
+
+ case FOUND_SET_PROPERTY:
+ call_info.property_handler->set_cb(connection, message, &call_info.variant_iter, call_info.iface_entry->userdata);
+ break;
+
+ case FOUND_METHOD:
+ call_info.method_handler->receive_cb(connection, message, call_info.iface_entry->userdata);
+ break;
+
+ case FOUND_GET_ALL:
+ if (call_info.iface_entry->get_all_properties_cb)
+ call_info.iface_entry->get_all_properties_cb(connection, message, call_info.iface_entry->userdata);
+ else {
+ DBusMessage *dummy_reply = NULL;
+ DBusMessageIter msg_iter;
+ DBusMessageIter dict_iter;
+
+ pa_assert_se(dummy_reply = dbus_message_new_method_return(message));
+ dbus_message_iter_init_append(dummy_reply, &msg_iter);
+ pa_assert_se(dbus_message_iter_open_container(&msg_iter, DBUS_TYPE_ARRAY, "{sv}", &dict_iter));
+ pa_assert_se(dbus_message_iter_close_container(&msg_iter, &dict_iter));
+ pa_assert_se(dbus_connection_send(connection, dummy_reply, NULL));
+ dbus_message_unref(dummy_reply);
+ }
+ break;
+
+ case PROPERTY_ACCESS_DENIED:
+ pa_dbus_send_error(connection, message, DBUS_ERROR_ACCESS_DENIED,
+ "%s access denied for property %s", call_info.method, call_info.property);
+ break;
+
+ case NO_SUCH_METHOD:
+ pa_dbus_send_error(connection, message, DBUS_ERROR_UNKNOWN_METHOD, "No such method: %s", call_info.method);
+ break;
+
+ case NO_SUCH_INTERFACE:
+ pa_dbus_send_error(connection, message, PA_DBUS_ERROR_NO_SUCH_INTERFACE, "No such interface: %s", call_info.interface);
+ break;
+
+ case NO_SUCH_PROPERTY:
+ pa_dbus_send_error(connection, message, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "No such property: %s", call_info.property);
+ break;
+
+ case NO_SUCH_PROPERTY_INTERFACE:
+ pa_dbus_send_error(connection, message, PA_DBUS_ERROR_NO_SUCH_INTERFACE, "No such property interface: %s", call_info.property_interface);
+ break;
+
+ case INVALID_METHOD_SIG:
+ pa_dbus_send_error(connection, message, DBUS_ERROR_INVALID_ARGS,
+ "Invalid signature for method %s: '%s'. Expected '%s'.",
+ call_info.method, call_info.method_sig, call_info.expected_method_sig);
+ break;
+
+ case INVALID_PROPERTY_SIG:
+ pa_dbus_send_error(connection, message, DBUS_ERROR_INVALID_ARGS,
+ "Invalid signature for property %s: '%s'. Expected '%s'.",
+ call_info.property, call_info.property_sig, call_info.expected_property_sig);
+ break;
+
+ default:
+ pa_assert_not_reached();
+ }
+
+finish:
+ return DBUS_HANDLER_RESULT_HANDLED;
+}
+
+static DBusObjectPathVTable vtable = {
+ .unregister_function = NULL,
+ .message_function = handle_message_cb,
+ .dbus_internal_pad1 = NULL,
+ .dbus_internal_pad2 = NULL,
+ .dbus_internal_pad3 = NULL,
+ .dbus_internal_pad4 = NULL
+};
+
+static void register_object(pa_dbus_protocol *p, struct object_entry *obj_entry) {
+ struct connection_entry *conn_entry;
+ void *state = NULL;
+
+ pa_assert(p);
+ pa_assert(obj_entry);
+
+ PA_HASHMAP_FOREACH(conn_entry, p->connections, state)
+ pa_assert_se(dbus_connection_register_object_path(conn_entry->connection, obj_entry->path, &vtable, p));
+}
+
+static pa_dbus_arg_info *copy_args(const pa_dbus_arg_info *src, unsigned n) {
+ pa_dbus_arg_info *dst;
+ unsigned i;
+
+ if (n == 0)
+ return NULL;
+
+ pa_assert(src);
+
+ dst = pa_xnew0(pa_dbus_arg_info, n);
+
+ for (i = 0; i < n; ++i) {
+ dst[i].name = pa_xstrdup(src[i].name);
+ dst[i].type = pa_xstrdup(src[i].type);
+ dst[i].direction = pa_xstrdup(src[i].direction);
+ }
+
+ return dst;
+}
+
+static pa_hashmap *create_method_handlers(const pa_dbus_interface_info *info) {
+ pa_hashmap *handlers;
+ unsigned i;
+
+ pa_assert(info);
+ pa_assert(info->method_handlers || info->n_method_handlers == 0);
+
+ handlers = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ for (i = 0; i < info->n_method_handlers; ++i) {
+ pa_dbus_method_handler *h = pa_xnew(pa_dbus_method_handler, 1);
+ h->method_name = pa_xstrdup(info->method_handlers[i].method_name);
+ h->arguments = copy_args(info->method_handlers[i].arguments, info->method_handlers[i].n_arguments);
+ h->n_arguments = info->method_handlers[i].n_arguments;
+ h->receive_cb = info->method_handlers[i].receive_cb;
+
+ pa_hashmap_put(handlers, h->method_name, h);
+ }
+
+ return handlers;
+}
+
+static pa_hashmap *extract_method_signatures(pa_hashmap *method_handlers) {
+ pa_hashmap *signatures = NULL;
+ pa_dbus_method_handler *handler = NULL;
+ void *state = NULL;
+ pa_strbuf *sig_buf = NULL;
+ unsigned i = 0;
+
+ pa_assert(method_handlers);
+
+ signatures = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ PA_HASHMAP_FOREACH(handler, method_handlers, state) {
+ sig_buf = pa_strbuf_new();
+
+ for (i = 0; i < handler->n_arguments; ++i) {
+ if (pa_streq(handler->arguments[i].direction, "in"))
+ pa_strbuf_puts(sig_buf, handler->arguments[i].type);
+ }
+
+ pa_hashmap_put(signatures, handler->method_name, pa_strbuf_tostring_free(sig_buf));
+ }
+
+ return signatures;
+}
+
+static pa_hashmap *create_property_handlers(const pa_dbus_interface_info *info) {
+ pa_hashmap *handlers;
+ unsigned i = 0;
+
+ pa_assert(info);
+ pa_assert(info->property_handlers || info->n_property_handlers == 0);
+
+ handlers = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ for (i = 0; i < info->n_property_handlers; ++i) {
+ pa_dbus_property_handler *h = pa_xnew(pa_dbus_property_handler, 1);
+ h->property_name = pa_xstrdup(info->property_handlers[i].property_name);
+ h->type = pa_xstrdup(info->property_handlers[i].type);
+ h->get_cb = info->property_handlers[i].get_cb;
+ h->set_cb = info->property_handlers[i].set_cb;
+
+ pa_hashmap_put(handlers, h->property_name, h);
+ }
+
+ return handlers;
+}
+
+static pa_dbus_signal_info *copy_signals(const pa_dbus_interface_info *info) {
+ pa_dbus_signal_info *dst;
+ unsigned i;
+
+ pa_assert(info);
+
+ if (info->n_signals == 0)
+ return NULL;
+
+ pa_assert(info->signals);
+
+ dst = pa_xnew(pa_dbus_signal_info, info->n_signals);
+
+ for (i = 0; i < info->n_signals; ++i) {
+ dst[i].name = pa_xstrdup(info->signals[i].name);
+ dst[i].arguments = copy_args(info->signals[i].arguments, info->signals[i].n_arguments);
+ dst[i].n_arguments = info->signals[i].n_arguments;
+ }
+
+ return dst;
+}
+
+int pa_dbus_protocol_add_interface(pa_dbus_protocol *p,
+ const char *path,
+ const pa_dbus_interface_info *info,
+ void *userdata) {
+ struct object_entry *obj_entry;
+ struct interface_entry *iface_entry;
+ pa_bool_t obj_entry_created = FALSE;
+
+ pa_assert(p);
+ pa_assert(path);
+ pa_assert(info);
+ pa_assert(info->name);
+ pa_assert(info->method_handlers || info->n_method_handlers == 0);
+ pa_assert(info->property_handlers || info->n_property_handlers == 0);
+ pa_assert(info->get_all_properties_cb || info->n_property_handlers == 0);
+ pa_assert(info->signals || info->n_signals == 0);
+
+ if (!(obj_entry = pa_hashmap_get(p->objects, path))) {
+ obj_entry = pa_xnew(struct object_entry, 1);
+ obj_entry->path = pa_xstrdup(path);
+ obj_entry->interfaces = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ obj_entry->introspection = NULL;
+
+ pa_hashmap_put(p->objects, obj_entry->path, obj_entry);
+ obj_entry_created = TRUE;
+ }
+
+ if (pa_hashmap_get(obj_entry->interfaces, info->name) != NULL)
+ goto fail; /* The interface was already registered. */
+
+ iface_entry = pa_xnew(struct interface_entry, 1);
+ iface_entry->name = pa_xstrdup(info->name);
+ iface_entry->method_handlers = create_method_handlers(info);
+ iface_entry->method_signatures = extract_method_signatures(iface_entry->method_handlers);
+ iface_entry->property_handlers = create_property_handlers(info);
+ iface_entry->get_all_properties_cb = info->get_all_properties_cb;
+ iface_entry->signals = copy_signals(info);
+ iface_entry->n_signals = info->n_signals;
+ iface_entry->userdata = userdata;
+ pa_hashmap_put(obj_entry->interfaces, iface_entry->name, iface_entry);
+
+ update_introspection(obj_entry);
+
+ if (obj_entry_created)
+ register_object(p, obj_entry);
+
+ pa_log_debug("Interface %s added for object %s", iface_entry->name, obj_entry->path);
+
+ return 0;
+
+fail:
+ return -1;
+}
+
+static void unregister_object(pa_dbus_protocol *p, struct object_entry *obj_entry) {
+ struct connection_entry *conn_entry;
+ void *state = NULL;
+
+ pa_assert(p);
+ pa_assert(obj_entry);
+
+ PA_HASHMAP_FOREACH(conn_entry, p->connections, state)
+ pa_assert_se(dbus_connection_unregister_object_path(conn_entry->connection, obj_entry->path));
+}
+
+static void method_handler_free_cb(void *p, void *userdata) {
+ pa_dbus_method_handler *h = p;
+ unsigned i;
+
+ pa_assert(h);
+
+ pa_xfree((char *) h->method_name);
+
+ for (i = 0; i < h->n_arguments; ++i) {
+ pa_xfree((char *) h->arguments[i].name);
+ pa_xfree((char *) h->arguments[i].type);
+ pa_xfree((char *) h->arguments[i].direction);
+ }
+
+ pa_xfree((pa_dbus_arg_info *) h->arguments);
+ pa_xfree(h);
+}
+
+static void method_signature_free_cb(void *p, void *userdata) {
+ pa_assert(p);
+
+ pa_xfree(p);
+}
+
+static void property_handler_free_cb(void *p, void *userdata) {
+ pa_dbus_property_handler *h = p;
+
+ pa_assert(h);
+
+ pa_xfree((char *) h->property_name);
+ pa_xfree((char *) h->type);
+
+ pa_xfree(h);
+}
+
+int pa_dbus_protocol_remove_interface(pa_dbus_protocol *p, const char* path, const char* interface) {
+ struct object_entry *obj_entry;
+ struct interface_entry *iface_entry;
+ unsigned i;
+
+ pa_assert(p);
+ pa_assert(path);
+ pa_assert(interface);
+
+ if (!(obj_entry = pa_hashmap_get(p->objects, path)))
+ return -1;
+
+ if (!(iface_entry = pa_hashmap_remove(obj_entry->interfaces, interface)))
+ return -1;
+
+ update_introspection(obj_entry);
+
+ pa_log_debug("Interface %s removed from object %s", iface_entry->name, obj_entry->path);
+
+ pa_xfree(iface_entry->name);
+ pa_hashmap_free(iface_entry->method_handlers, method_handler_free_cb, NULL);
+ pa_hashmap_free(iface_entry->method_signatures, method_signature_free_cb, NULL);
+ pa_hashmap_free(iface_entry->property_handlers, property_handler_free_cb, NULL);
+
+ for (i = 0; i < iface_entry->n_signals; ++i) {
+ unsigned j;
+
+ pa_xfree((char *) iface_entry->signals[i].name);
+
+ for (j = 0; j < iface_entry->signals[i].n_arguments; ++j) {
+ pa_xfree((char *) iface_entry->signals[i].arguments[j].name);
+ pa_xfree((char *) iface_entry->signals[i].arguments[j].type);
+ pa_assert(iface_entry->signals[i].arguments[j].direction == NULL);
+ }
+
+ pa_xfree((pa_dbus_arg_info *) iface_entry->signals[i].arguments);
+ }
+
+ pa_xfree(iface_entry->signals);
+ pa_xfree(iface_entry);
+
+ if (pa_hashmap_isempty(obj_entry->interfaces)) {
+ unregister_object(p, obj_entry);
+
+ pa_hashmap_remove(p->objects, path);
+ pa_xfree(obj_entry->path);
+ pa_hashmap_free(obj_entry->interfaces, NULL, NULL);
+ pa_xfree(obj_entry->introspection);
+ pa_xfree(obj_entry);
+ }
+
+ return 0;
+}
+
+static void register_all_objects(pa_dbus_protocol *p, DBusConnection *conn) {
+ struct object_entry *obj_entry;
+ void *state = NULL;
+
+ pa_assert(p);
+ pa_assert(conn);
+
+ PA_HASHMAP_FOREACH(obj_entry, p->objects, state)
+ pa_assert_se(dbus_connection_register_object_path(conn, obj_entry->path, &vtable, p));
+}
+
+int pa_dbus_protocol_register_connection(pa_dbus_protocol *p, DBusConnection *conn, pa_client *client) {
+ struct connection_entry *conn_entry;
+
+ pa_assert(p);
+ pa_assert(conn);
+ pa_assert(client);
+
+ if (pa_hashmap_get(p->connections, conn))
+ return -1; /* The connection was already registered. */
+
+ register_all_objects(p, conn);
+
+ conn_entry = pa_xnew(struct connection_entry, 1);
+ conn_entry->connection = dbus_connection_ref(conn);
+ conn_entry->client = client;
+ conn_entry->listening_for_all_signals = FALSE;
+ conn_entry->all_signals_objects = pa_idxset_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+ conn_entry->listening_signals = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ pa_hashmap_put(p->connections, conn, conn_entry);
+
+ return 0;
+}
+
+static void unregister_all_objects(pa_dbus_protocol *p, DBusConnection *conn) {
+ struct object_entry *obj_entry;
+ void *state = NULL;
+
+ pa_assert(p);
+ pa_assert(conn);
+
+ PA_HASHMAP_FOREACH(obj_entry, p->objects, state)
+ pa_assert_se(dbus_connection_unregister_object_path(conn, obj_entry->path));
+}
+
+static struct signal_paths_entry *signal_paths_entry_new(const char *signal_name) {
+ struct signal_paths_entry *e = NULL;
+
+ pa_assert(signal_name);
+
+ e = pa_xnew0(struct signal_paths_entry, 1);
+ e->signal = pa_xstrdup(signal_name);
+ e->paths = pa_idxset_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
+
+ return e;
+}
+
+static void signal_paths_entry_free(struct signal_paths_entry *e) {
+ char *path = NULL;
+
+ pa_assert(e);
+
+ pa_xfree(e->signal);
+
+ while ((path = pa_idxset_steal_first(e->paths, NULL)))
+ pa_xfree(path);
+
+ pa_idxset_free(e->paths, NULL, NULL);
+ pa_xfree(e);
+}
+
+int pa_dbus_protocol_unregister_connection(pa_dbus_protocol *p, DBusConnection *conn) {
+ struct connection_entry *conn_entry = NULL;
+ struct signal_paths_entry *signal_paths_entry = NULL;
+ char *object_path = NULL;
+
+ pa_assert(p);
+ pa_assert(conn);
+
+ if (!(conn_entry = pa_hashmap_remove(p->connections, conn)))
+ return -1;
+
+ unregister_all_objects(p, conn);
+
+ dbus_connection_unref(conn_entry->connection);
+
+ while ((object_path = pa_idxset_steal_first(conn_entry->all_signals_objects, NULL)))
+ pa_xfree(object_path);
+
+ pa_idxset_free(conn_entry->all_signals_objects, NULL, NULL);
+
+ while ((signal_paths_entry = pa_hashmap_steal_first(conn_entry->listening_signals)))
+ signal_paths_entry_free(signal_paths_entry);
+
+ pa_hashmap_free(conn_entry->listening_signals, NULL, NULL);
+ pa_xfree(conn_entry);
+
+ return 0;
+}
+
+pa_client *pa_dbus_protocol_get_client(pa_dbus_protocol *p, DBusConnection *conn) {
+ struct connection_entry *conn_entry;
+
+ pa_assert(p);
+ pa_assert(conn);
+
+ if (!(conn_entry = pa_hashmap_get(p->connections, conn)))
+ return NULL;
+
+ return conn_entry->client;
+}
+
+void pa_dbus_protocol_add_signal_listener(
+ pa_dbus_protocol *p,
+ DBusConnection *conn,
+ const char *signal_name,
+ char **objects,
+ unsigned n_objects) {
+ struct connection_entry *conn_entry = NULL;
+ struct signal_paths_entry *signal_paths_entry = NULL;
+ char *object_path = NULL;
+ unsigned i = 0;
+
+ pa_assert(p);
+ pa_assert(conn);
+ pa_assert(objects || n_objects == 0);
+
+ pa_assert_se((conn_entry = pa_hashmap_get(p->connections, conn)));
+
+ /* all_signals_objects will either be emptied or replaced with new objects,
+ * so we empty it here unconditionally. If listening_for_all_signals is
+ * currently FALSE, the idxset is empty already so this does nothing. */
+ while ((object_path = pa_idxset_steal_first(conn_entry->all_signals_objects, NULL)))
+ pa_xfree(object_path);
+
+ if (signal_name) {
+ conn_entry->listening_for_all_signals = FALSE;
+
+ /* Replace the old signal paths entry for this signal with a new
+ * one. */
+ if ((signal_paths_entry = pa_hashmap_remove(conn_entry->listening_signals, signal_name)))
+ signal_paths_entry_free(signal_paths_entry);
+ signal_paths_entry = signal_paths_entry_new(signal_name);
+
+ for (i = 0; i < n_objects; ++i)
+ pa_idxset_put(signal_paths_entry->paths, pa_xstrdup(objects[i]), NULL);
+
+ pa_hashmap_put(conn_entry->listening_signals, signal_paths_entry->signal, signal_paths_entry);
+
+ } else {
+ conn_entry->listening_for_all_signals = TRUE;
+
+ /* We're not interested in individual signals anymore, so let's empty
+ * listening_signals. */
+ while ((signal_paths_entry = pa_hashmap_steal_first(conn_entry->listening_signals)))
+ signal_paths_entry_free(signal_paths_entry);
+
+ for (i = 0; i < n_objects; ++i)
+ pa_idxset_put(conn_entry->all_signals_objects, pa_xstrdup(objects[i]), NULL);
+ }
+}
+
+void pa_dbus_protocol_remove_signal_listener(pa_dbus_protocol *p, DBusConnection *conn, const char *signal_name) {
+ struct connection_entry *conn_entry = NULL;
+ struct signal_paths_entry *signal_paths_entry = NULL;
+
+ pa_assert(p);
+ pa_assert(conn);
+
+ pa_assert_se((conn_entry = pa_hashmap_get(p->connections, conn)));
+
+ if (signal_name) {
+ if ((signal_paths_entry = pa_hashmap_get(conn_entry->listening_signals, signal_name)))
+ signal_paths_entry_free(signal_paths_entry);
+
+ } else {
+ char *object_path;
+
+ conn_entry->listening_for_all_signals = FALSE;
+
+ while ((object_path = pa_idxset_steal_first(conn_entry->all_signals_objects, NULL)))
+ pa_xfree(object_path);
+
+ while ((signal_paths_entry = pa_hashmap_steal_first(conn_entry->listening_signals)))
+ signal_paths_entry_free(signal_paths_entry);
+ }
+}
+
+void pa_dbus_protocol_send_signal(pa_dbus_protocol *p, DBusMessage *signal_msg) {
+ struct connection_entry *conn_entry;
+ struct signal_paths_entry *signal_paths_entry;
+ void *state = NULL;
+ DBusMessage *signal_copy;
+ char *signal_string;
+
+ pa_assert(p);
+ pa_assert(signal_msg);
+ pa_assert(dbus_message_get_type(signal_msg) == DBUS_MESSAGE_TYPE_SIGNAL);
+ pa_assert(dbus_message_get_path(signal_msg));
+ pa_assert(dbus_message_get_interface(signal_msg));
+ pa_assert(dbus_message_get_member(signal_msg));
+
+ signal_string = pa_sprintf_malloc("%s.%s", dbus_message_get_interface(signal_msg), dbus_message_get_member(signal_msg));
+
+ PA_HASHMAP_FOREACH(conn_entry, p->connections, state) {
+ if ((conn_entry->listening_for_all_signals /* Case 1: listening for all signals */
+ && (pa_idxset_get_by_data(conn_entry->all_signals_objects, dbus_message_get_path(signal_msg), NULL)
+ || pa_idxset_isempty(conn_entry->all_signals_objects)))
+
+ || (!conn_entry->listening_for_all_signals /* Case 2: not listening for all signals */
+ && (signal_paths_entry = pa_hashmap_get(conn_entry->listening_signals, signal_string))
+ && (pa_idxset_get_by_data(signal_paths_entry->paths, dbus_message_get_path(signal_msg), NULL)
+ || pa_idxset_isempty(signal_paths_entry->paths)))) {
+
+ pa_assert_se(signal_copy = dbus_message_copy(signal_msg));
+ pa_assert_se(dbus_connection_send(conn_entry->connection, signal_copy, NULL));
+ dbus_message_unref(signal_copy);
+ }
+ }
+
+ pa_xfree(signal_string);
+}
+
+const char **pa_dbus_protocol_get_extensions(pa_dbus_protocol *p, unsigned *n) {
+ const char **extensions;
+ const char *ext_name;
+ void *state = NULL;
+ unsigned i = 0;
+
+ pa_assert(p);
+ pa_assert(n);
+
+ *n = pa_idxset_size(p->extensions);
+
+ if (*n <= 0)
+ return NULL;
+
+ extensions = pa_xnew(const char *, *n);
+
+ while ((ext_name = pa_idxset_iterate(p->extensions, &state, NULL)))
+ extensions[i++] = ext_name;
+
+ return extensions;
+}
+
+int pa_dbus_protocol_register_extension(pa_dbus_protocol *p, const char *name) {
+ char *internal_name;
+
+ pa_assert(p);
+ pa_assert(name);
+
+ internal_name = pa_xstrdup(name);
+
+ if (pa_idxset_put(p->extensions, internal_name, NULL) < 0) {
+ pa_xfree(internal_name);
+ return -1;
+ }
+
+ pa_hook_fire(&p->hooks[PA_DBUS_PROTOCOL_HOOK_EXTENSION_REGISTERED], internal_name);
+
+ return 0;
+}
+
+int pa_dbus_protocol_unregister_extension(pa_dbus_protocol *p, const char *name) {
+ char *internal_name;
+
+ pa_assert(p);
+ pa_assert(name);
+
+ if (!(internal_name = pa_idxset_remove_by_data(p->extensions, name, NULL)))
+ return -1;
+
+ pa_hook_fire(&p->hooks[PA_DBUS_PROTOCOL_HOOK_EXTENSION_UNREGISTERED], internal_name);
+
+ pa_xfree(internal_name);
+
+ return 0;
+}
+
+pa_hook_slot *pa_dbus_protocol_hook_connect(
+ pa_dbus_protocol *p,
+ pa_dbus_protocol_hook_t hook,
+ pa_hook_priority_t prio,
+ pa_hook_cb_t cb,
+ void *data) {
+ pa_assert(p);
+ pa_assert(hook < PA_DBUS_PROTOCOL_HOOK_MAX);
+ pa_assert(cb);
+
+ return pa_hook_connect(&p->hooks[hook], prio, cb, data);
+}
diff --git a/src/pulsecore/protocol-dbus.h b/src/pulsecore/protocol-dbus.h
new file mode 100644
index 00000000..89999337
--- /dev/null
+++ b/src/pulsecore/protocol-dbus.h
@@ -0,0 +1,218 @@
+#ifndef fooprotocoldbushfoo
+#define fooprotocoldbushfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Tanu Kaskinen
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <dbus/dbus.h>
+
+#include <pulsecore/core.h>
+#include <pulsecore/macro.h>
+
+#define PA_DBUS_DEFAULT_PORT 24883
+#define PA_DBUS_SOCKET_NAME "dbus-socket"
+
+#define PA_DBUS_SYSTEM_SOCKET_PATH PA_SYSTEM_RUNTIME_PATH PA_PATH_SEP PA_DBUS_SOCKET_NAME
+
+#define PA_DBUS_CORE_INTERFACE "org.PulseAudio.Core1"
+#define PA_DBUS_CORE_OBJECT_PATH "/org/pulseaudio/core1"
+
+#define PA_DBUS_ERROR_NO_SUCH_INTERFACE PA_DBUS_CORE_INTERFACE ".NoSuchInterfaceError"
+#define PA_DBUS_ERROR_NO_SUCH_PROPERTY PA_DBUS_CORE_INTERFACE ".NoSuchPropertyError"
+#define PA_DBUS_ERROR_NOT_FOUND PA_DBUS_CORE_INTERFACE ".NotFoundError"
+
+/* Returns the default address of the server type in the escaped form. For
+ * PA_SERVER_TYPE_NONE an empty string is returned. The caller frees the
+ * string. */
+char *pa_get_dbus_address_from_server_type(pa_server_type_t server_type);
+
+typedef struct pa_dbus_protocol pa_dbus_protocol;
+
+/* This function either creates a new pa_dbus_protocol object, or if one
+ * already exists, increases the reference count. */
+pa_dbus_protocol* pa_dbus_protocol_get(pa_core *c);
+
+pa_dbus_protocol* pa_dbus_protocol_ref(pa_dbus_protocol *p);
+void pa_dbus_protocol_unref(pa_dbus_protocol *p);
+
+/* Called when a received message needs handling. Completely ignoring the
+ * message isn't a good idea; if you can't handle the message, reply with an
+ * error.
+ *
+ * The message signature is already checked against the introspection data, so
+ * you don't have to do that yourself.
+ *
+ * All messages are method calls. */
+typedef void (*pa_dbus_receive_cb_t)(DBusConnection *conn, DBusMessage *msg, void *userdata);
+
+/* A specialized version of pa_dbus_receive_cb_t: the additional iterator
+ * argument points to the element inside the new value variant.
+ *
+ * The new value signature is checked against the introspection data, so you
+ * don't have to do that yourself. */
+typedef void (*pa_dbus_set_property_cb_t)(DBusConnection *conn, DBusMessage *msg, DBusMessageIter *iter, void *userdata);
+
+typedef struct pa_dbus_arg_info {
+ const char *name;
+ const char *type;
+ const char *direction; /* NULL for signal arguments. */
+} pa_dbus_arg_info;
+
+typedef struct pa_dbus_signal_info {
+ const char *name;
+ const pa_dbus_arg_info *arguments; /* NULL, if the signal has no args. */
+ unsigned n_arguments;
+} pa_dbus_signal_info;
+
+typedef struct pa_dbus_method_handler {
+ const char *method_name;
+ const pa_dbus_arg_info *arguments; /* NULL, if the method has no args. */
+ unsigned n_arguments;
+ pa_dbus_receive_cb_t receive_cb;
+} pa_dbus_method_handler;
+
+typedef struct pa_dbus_property_handler {
+ const char *property_name;
+ const char *type;
+
+ /* The access mode for the property is determined by checking whether
+ * get_cb or set_cb is NULL. */
+ pa_dbus_receive_cb_t get_cb;
+ pa_dbus_set_property_cb_t set_cb;
+} pa_dbus_property_handler;
+
+typedef struct pa_dbus_interface_info {
+ const char* name;
+ const pa_dbus_method_handler *method_handlers; /* NULL, if the interface has no methods. */
+ unsigned n_method_handlers;
+ const pa_dbus_property_handler *property_handlers; /* NULL, if the interface has no properties. */
+ unsigned n_property_handlers;
+ const pa_dbus_receive_cb_t get_all_properties_cb; /* May be NULL, in which case GetAll returns an error. */
+ const pa_dbus_signal_info *signals; /* NULL, if the interface has no signals. */
+ unsigned n_signals;
+} pa_dbus_interface_info;
+
+
+/* The following functions may only be called from the main thread. */
+
+/* Registers the given interface to the given object path. It doesn't matter
+ * whether or not the object has already been registered; if it is, then its
+ * interface set is extended.
+ *
+ * Introspection requests are handled automatically.
+ *
+ * Userdata is passed to all the callbacks.
+ *
+ * Fails and returns a negative number if the object already has the interface
+ * registered. */
+int pa_dbus_protocol_add_interface(pa_dbus_protocol *p, const char *path, const pa_dbus_interface_info *info, void *userdata);
+
+/* Returns a negative number if the given object doesn't have the given
+ * interface registered. */
+int pa_dbus_protocol_remove_interface(pa_dbus_protocol *p, const char* path, const char* interface);
+
+/* Fails and returns a negative number if the connection is already
+ * registered. */
+int pa_dbus_protocol_register_connection(pa_dbus_protocol *p, DBusConnection *conn, pa_client *client);
+
+/* Returns a negative number if the connection isn't registered. */
+int pa_dbus_protocol_unregister_connection(pa_dbus_protocol *p, DBusConnection *conn);
+
+/* Returns NULL if the connection isn't registered. */
+pa_client *pa_dbus_protocol_get_client(pa_dbus_protocol *p, DBusConnection *conn);
+
+/* Enables signal receiving for the given connection. The connection must have
+ * been registered earlier. The signal string must contain both the signal
+ * interface and the signal name, concatenated using a period as the separator.
+ *
+ * If the signal argument is NULL, all signals will be sent to the connection,
+ * otherwise calling this function only adds the given signal to the list of
+ * signals that will be delivered to the connection.
+ *
+ * The objects argument is a list of object paths. If the list is not empty,
+ * only signals from the given objects are delivered. If this function is
+ * called multiple time for the same connection and signal, the latest call
+ * always replaces the previous object list. */
+void pa_dbus_protocol_add_signal_listener(
+ pa_dbus_protocol *p,
+ DBusConnection *conn,
+ const char *signal,
+ char **objects,
+ unsigned n_objects);
+
+/* Disables the delivery of the signal for the given connection. The connection
+ * must have been registered. If signal is NULL, all signals are disabled. If
+ * signal is non-NULL and _add_signal_listener() was previously called with
+ * NULL signal (causing all signals to be enabled), this function doesn't do
+ * anything. Also, if the signal wasn't enabled before, this function doesn't
+ * do anything in that case either. */
+void pa_dbus_protocol_remove_signal_listener(pa_dbus_protocol *p, DBusConnection *conn, const char *signal);
+
+/* Sends the given signal to all interested clients. By default no signals are
+ * sent - clients have to explicitly to request signals by calling
+ * .Core1.ListenForSignal. That method's handler then calls
+ * pa_dbus_protocol_add_signal_listener(). */
+void pa_dbus_protocol_send_signal(pa_dbus_protocol *p, DBusMessage *signal);
+
+/* Returns an array of extension identifier strings. The strings pointers point
+ * to the internal copies, so don't free the strings. The caller must free the
+ * array, however. Also, do not save the returned pointer or any of the string
+ * pointers, because the contained strings may be freed at any time. If you
+ * need to save the array, copy it. */
+const char **pa_dbus_protocol_get_extensions(pa_dbus_protocol *p, unsigned *n);
+
+/* Modules that want to provide a D-Bus interface for clients should register
+ * an identifier that the clients can use to check whether the additional
+ * functionality is available.
+ *
+ * This function registers the extension with the given name. It is recommended
+ * that the name follows the D-Bus interface naming convention, so that the
+ * names remain unique in case there will be at some point in the future
+ * extensions that aren't included with the main PulseAudio source tree. For
+ * in-tree extensions the convention is to use the org.PulseAudio.Ext
+ * namespace.
+ *
+ * It is suggested that the name contains a version number, and whenever the
+ * extension interface is modified in non-backwards compatible way, the version
+ * number is incremented.
+ *
+ * Fails and returns a negative number if the extension is already registered.
+ */
+int pa_dbus_protocol_register_extension(pa_dbus_protocol *p, const char *name);
+
+/* Returns a negative number if the extension isn't registered. */
+int pa_dbus_protocol_unregister_extension(pa_dbus_protocol *p, const char *name);
+
+/* All hooks have the pa_dbus_protocol object as hook data. */
+typedef enum pa_dbus_protocol_hook {
+ PA_DBUS_PROTOCOL_HOOK_EXTENSION_REGISTERED, /* Extension name as call data. */
+ PA_DBUS_PROTOCOL_HOOK_EXTENSION_UNREGISTERED, /* Extension name as call data. */
+ PA_DBUS_PROTOCOL_HOOK_MAX
+} pa_dbus_protocol_hook_t;
+
+pa_hook_slot *pa_dbus_protocol_hook_connect(
+ pa_dbus_protocol *p,
+ pa_dbus_protocol_hook_t hook,
+ pa_hook_priority_t prio,
+ pa_hook_cb_t cb,
+ void *data);
+
+#endif
diff --git a/src/pulsecore/protocol-esound.c b/src/pulsecore/protocol-esound.c
index 7e7126ea..95355bf6 100644
--- a/src/pulsecore/protocol-esound.c
+++ b/src/pulsecore/protocol-esound.c
@@ -28,8 +28,8 @@
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
-#include <limits.h>
+#include <pulse/rtclock.h>
#include <pulse/sample.h>
#include <pulse/timeval.h>
#include <pulse/utf8.h>
@@ -45,7 +45,6 @@
#include <pulsecore/source.h>
#include <pulsecore/core-scache.h>
#include <pulsecore/sample-util.h>
-#include <pulsecore/authkey.h>
#include <pulsecore/namereg.h>
#include <pulsecore/log.h>
#include <pulsecore/core-util.h>
@@ -54,8 +53,7 @@
#include <pulsecore/macro.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/shared.h>
-
-#include "endianmacros.h"
+#include <pulsecore/endianmacros.h>
#include "protocol-esound.h"
@@ -63,7 +61,7 @@
#define MAX_CONNECTIONS 64
/* Kick a client if it doesn't authenticate within this time */
-#define AUTH_TIMEOUT 5
+#define AUTH_TIMEOUT (5*PA_USEC_PER_SEC)
#define DEFAULT_COOKIE_FILE ".esd_auth"
@@ -119,9 +117,8 @@ typedef struct connection {
pa_time_event *auth_timeout_event;
} connection;
-PA_DECLARE_CLASS(connection);
+PA_DEFINE_PRIVATE_CLASS(connection, pa_msgobject);
#define CONNECTION(o) (connection_cast(o))
-static PA_DEFINE_CHECK_TYPE(connection, pa_msgobject);
struct pa_esound_protocol {
PA_REFCNT_DECLARE;
@@ -328,12 +325,12 @@ static int format_native2esd(pa_sample_spec *ss) {
return format;
}
-#define CHECK_VALIDITY(expression, ...) do { \
- if (!(expression)) { \
- pa_log_warn(__FILE__ ": " __VA_ARGS__); \
- return -1; \
- } \
-} while(0);
+#define CHECK_VALIDITY(expression, ...) do { \
+ if (PA_UNLIKELY(!(expression))) { \
+ pa_log_warn(__FILE__ ": " __VA_ARGS__); \
+ return -1; \
+ } \
+ } while(0);
/*** esound commands ***/
@@ -389,6 +386,7 @@ static int esd_proto_stream_play(connection *c, esd_proto_t request, const void
size_t l;
pa_sink *sink = NULL;
pa_sink_input_new_data sdata;
+ pa_memchunk silence;
connection_assert_ref(c);
pa_assert(data);
@@ -426,15 +424,17 @@ static int esd_proto_stream_play(connection *c, esd_proto_t request, const void
sdata.driver = __FILE__;
sdata.module = c->options->module;
sdata.client = c->client;
- sdata.sink = sink;
+ if (sink)
+ pa_sink_input_new_data_set_sink(&sdata, sink, FALSE);
pa_sink_input_new_data_set_sample_spec(&sdata, &ss);
- pa_sink_input_new(&c->sink_input, c->protocol->core, &sdata, 0);
+ pa_sink_input_new(&c->sink_input, c->protocol->core, &sdata);
pa_sink_input_new_data_done(&sdata);
CHECK_VALIDITY(c->sink_input, "Failed to create sink input.");
l = (size_t) ((double) pa_bytes_per_second(&ss)*PLAYBACK_BUFFER_SECONDS);
+ pa_sink_input_get_silence(c->sink_input, &silence);
c->input_memblockq = pa_memblockq_new(
0,
l,
@@ -443,7 +443,8 @@ static int esd_proto_stream_play(connection *c, esd_proto_t request, const void
(size_t) -1,
l/PLAYBACK_BUFFER_FRAGMENTS,
0,
- NULL);
+ &silence);
+ pa_memblock_unref(silence.memblock);
pa_iochannel_socket_set_rcvbuf(c->io, l);
c->sink_input->parent.process_msg = sink_input_process_msg;
@@ -459,7 +460,7 @@ static int esd_proto_stream_play(connection *c, esd_proto_t request, const void
c->protocol->n_player++;
- pa_atomic_store(&c->playback.missing, (int) pa_memblockq_missing(c->input_memblockq));
+ pa_atomic_store(&c->playback.missing, (int) pa_memblockq_pop_missing(c->input_memblockq));
pa_sink_input_put(c->sink_input);
@@ -522,10 +523,11 @@ static int esd_proto_stream_record(connection *c, esd_proto_t request, const voi
sdata.driver = __FILE__;
sdata.module = c->options->module;
sdata.client = c->client;
- sdata.source = source;
+ if (source)
+ pa_source_output_new_data_set_source(&sdata, source, FALSE);
pa_source_output_new_data_set_sample_spec(&sdata, &ss);
- pa_source_output_new(&c->source_output, c->protocol->core, &sdata, 0);
+ pa_source_output_new(&c->source_output, c->protocol->core, &sdata);
pa_source_output_new_data_done(&sdata);
CHECK_VALIDITY(c->source_output, "Failed to create source output.");
@@ -628,7 +630,7 @@ static int esd_proto_all_info(connection *c, esd_proto_t request, const void *da
memset(terminator, 0, sizeof(terminator));
- for (conn = pa_idxset_first(c->protocol->connections, &idx); conn; conn = pa_idxset_next(c->protocol->connections, &idx)) {
+ PA_IDXSET_FOREACH(conn, c->protocol->connections, idx) {
int32_t id, format = ESD_BITS16 | ESD_STEREO, rate = 44100, lvolume = ESD_VOLUME_BASE, rvolume = ESD_VOLUME_BASE;
char name[ESD_NAME_MAX];
@@ -686,7 +688,8 @@ static int esd_proto_all_info(connection *c, esd_proto_t request, const void *da
pa_scache_entry *ce;
idx = PA_IDXSET_INVALID;
- for (ce = pa_idxset_first(c->protocol->core->scache, &idx); ce; ce = pa_idxset_next(c->protocol->core->scache, &idx)) {
+
+ PA_IDXSET_FOREACH(ce, c->protocol->core->scache, idx) {
int32_t id, rate, lvolume, rvolume, format, len;
char name[ESD_NAME_MAX];
pa_channel_map stereo = { .channels = 2, .map = { PA_CHANNEL_POSITION_LEFT, PA_CHANNEL_POSITION_RIGHT } };
@@ -771,7 +774,6 @@ static int esd_proto_stream_pan(connection *c, esd_proto_t request, const void *
memcpy(&rvolume, data, sizeof(uint32_t));
rvolume = PA_MAYBE_UINT32_SWAP(c->swap_byte_order, rvolume);
- data = (const char*)data + sizeof(uint32_t);
if ((conn = pa_idxset_get_by_index(c->protocol->connections, idx)) && conn->sink_input) {
pa_cvolume volume;
@@ -809,7 +811,6 @@ static int esd_proto_sample_pan(connection *c, esd_proto_t request, const void *
memcpy(&rvolume, data, sizeof(uint32_t));
rvolume = PA_MAYBE_UINT32_SWAP(c->swap_byte_order, rvolume);
- data = (const char*)data + sizeof(uint32_t);
volume.values[0] = (lvolume*PA_VOLUME_NORM)/ESD_VOLUME_BASE;
volume.values[1] = (rvolume*PA_VOLUME_NORM)/ESD_VOLUME_BASE;
@@ -947,10 +948,10 @@ static int esd_proto_standby_or_resume(connection *c, esd_proto_t request, const
connection_write(c, &ok, sizeof(int32_t));
if (request == ESD_PROTO_STANDBY)
- ok = pa_sink_suspend_all(c->protocol->core, TRUE) >= 0;
+ ok = pa_sink_suspend_all(c->protocol->core, TRUE, PA_SUSPEND_USER) >= 0;
else {
pa_assert(request == ESD_PROTO_RESUME);
- ok = pa_sink_suspend_all(c->protocol->core, FALSE) >= 0;
+ ok = pa_sink_suspend_all(c->protocol->core, FALSE, PA_SUSPEND_USER) >= 0;
}
connection_write(c, &ok, sizeof(int32_t));
@@ -1123,13 +1124,13 @@ static int do_read(connection *c) {
ssize_t r;
size_t l;
void *p;
- size_t space;
+ size_t space = 0;
pa_assert(c->input_memblockq);
/* pa_log("STREAMING_DATA"); */
- if (!(l = (size_t) pa_atomic_load(&c->playback.missing)))
+ if ((l = (size_t) pa_atomic_load(&c->playback.missing)) <= 0)
return 0;
if (c->playback.current_memblock) {
@@ -1171,8 +1172,8 @@ static int do_read(connection *c) {
c->playback.memblock_index += (size_t) r;
- pa_asyncmsgq_post(c->sink_input->sink->asyncmsgq, PA_MSGOBJECT(c->sink_input), SINK_INPUT_MESSAGE_POST_DATA, NULL, 0, &chunk, NULL);
pa_atomic_sub(&c->playback.missing, (int) r);
+ pa_asyncmsgq_post(c->sink_input->sink->asyncmsgq, PA_MSGOBJECT(c->sink_input), SINK_INPUT_MESSAGE_POST_DATA, NULL, 0, &chunk, NULL);
}
return 0;
@@ -1380,10 +1381,9 @@ static int sink_input_pop_cb(pa_sink_input *i, size_t length, pa_memchunk *chunk
} else {
size_t m;
- chunk->length = PA_MIN(length, chunk->length);
-
c->playback.underrun = FALSE;
+ chunk->length = PA_MIN(length, chunk->length);
pa_memblockq_drop(c->input_memblockq, chunk->length);
m = pa_memblockq_pop_missing(c->input_memblockq);
@@ -1459,11 +1459,10 @@ static pa_usec_t source_output_get_latency_cb(pa_source_output *o) {
/*** entry points ***/
-static void auth_timeout(pa_mainloop_api*m, pa_time_event *e, const struct timeval *tv, void *userdata) {
+static void auth_timeout(pa_mainloop_api *m, pa_time_event *e, const struct timeval *t, void *userdata) {
connection *c = CONNECTION(userdata);
pa_assert(m);
- pa_assert(tv);
connection_assert_ref(c);
pa_assert(c->auth_timeout_event == e);
@@ -1553,12 +1552,9 @@ void pa_esound_protocol_connect(pa_esound_protocol *p, pa_iochannel *io, pa_esou
c->authorized = TRUE;
}
- if (!c->authorized) {
- struct timeval tv;
- pa_gettimeofday(&tv);
- tv.tv_sec += AUTH_TIMEOUT;
- c->auth_timeout_event = p->core->mainloop->time_new(p->core->mainloop, &tv, auth_timeout, c);
- } else
+ if (!c->authorized)
+ c->auth_timeout_event = pa_core_rttime_new(p->core, pa_rtclock_now() + AUTH_TIMEOUT, auth_timeout, c);
+ else
c->auth_timeout_event = NULL;
c->defer_event = p->core->mainloop->defer_new(p->core->mainloop, defer_callback, c);
diff --git a/src/pulsecore/protocol-http.c b/src/pulsecore/protocol-http.c
index 5220cc91..d085e618 100644
--- a/src/pulsecore/protocol-http.c
+++ b/src/pulsecore/protocol-http.c
@@ -32,6 +32,7 @@
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
+#include <pulsecore/core-util.h>
#include <pulsecore/ioline.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/macro.h>
@@ -80,6 +81,11 @@ enum state {
STATE_DATA
};
+enum method {
+ METHOD_GET,
+ METHOD_HEAD
+};
+
struct connection {
pa_http_protocol *protocol;
pa_iochannel *io;
@@ -89,6 +95,7 @@ struct connection {
pa_client *client;
enum state state;
char *url;
+ enum method method;
pa_module *module;
};
@@ -327,6 +334,11 @@ static void html_response(
http_response(c, code, msg, MIME_HTML);
+ if (c->method == METHOD_HEAD) {
+ pa_ioline_defer_close(c->line);
+ return;
+ }
+
if (!text)
text = msg;
@@ -363,6 +375,11 @@ static void handle_root(struct connection *c) {
http_response(c, 200, "OK", MIME_HTML);
+ if (c->method == METHOD_HEAD) {
+ pa_ioline_defer_close(c->line);
+ return;
+ }
+
pa_ioline_puts(c->line,
HTML_HEADER(PACKAGE_NAME" "PACKAGE_VERSION)
"<h1>"PACKAGE_NAME" "PACKAGE_VERSION"</h1>\n"
@@ -402,6 +419,11 @@ static void handle_css(struct connection *c) {
http_response(c, 200, "OK", MIME_CSS);
+ if (c->method == METHOD_HEAD) {
+ pa_ioline_defer_close(c->line);
+ return;
+ }
+
pa_ioline_puts(c->line,
"body { color: black; background-color: white; }\n"
"a:link, a:visited { color: #900000; }\n"
@@ -420,6 +442,12 @@ static void handle_status(struct connection *c) {
pa_assert(c);
http_response(c, 200, "OK", MIME_TEXT);
+
+ if (c->method == METHOD_HEAD) {
+ pa_ioline_defer_close(c->line);
+ return;
+ }
+
r = pa_full_status_string(c->protocol->core);
pa_ioline_puts(c->line, r);
pa_xfree(r);
@@ -439,6 +467,11 @@ static void handle_listen(struct connection *c) {
"<h2>Sinks</h2>\n"
"<p>\n");
+ if (c->method == METHOD_HEAD) {
+ pa_ioline_defer_close(c->line);
+ return;
+ }
+
PA_IDXSET_FOREACH(sink, c->protocol->core->sinks, idx) {
char *t, *m;
@@ -528,12 +561,12 @@ static void handle_listen_prefix(struct connection *c, const char *source_name)
data.driver = __FILE__;
data.module = c->module;
data.client = c->client;
- data.source = source;
+ pa_source_output_new_data_set_source(&data, source, FALSE);
pa_proplist_update(data.proplist, PA_UPDATE_MERGE, c->client->proplist);
pa_source_output_new_data_set_sample_spec(&data, &ss);
pa_source_output_new_data_set_channel_map(&data, &cm);
- pa_source_output_new(&c->source_output, c->protocol->core, &data, 0);
+ pa_source_output_new(&c->source_output, c->protocol->core, &data);
pa_source_output_new_data_done(&data);
if (!c->source_output) {
@@ -566,6 +599,10 @@ static void handle_listen_prefix(struct connection *c, const char *source_name)
http_response(c, 200, "OK", t);
pa_xfree(t);
+ if(c->method == METHOD_HEAD) {
+ connection_unlink(c);
+ return;
+ }
pa_ioline_set_callback(c->line, NULL, NULL);
if (pa_ioline_is_drained(c->line))
@@ -606,10 +643,15 @@ static void line_callback(pa_ioline *line, const char *s, void *userdata) {
switch (c->state) {
case STATE_REQUEST_LINE: {
- if (!pa_startswith(s, "GET "))
+ if (pa_startswith(s, "GET ")) {
+ c->method = METHOD_GET;
+ s +=4;
+ } else if (pa_startswith(s, "HEAD ")) {
+ c->method = METHOD_HEAD;
+ s +=5;
+ } else {
goto fail;
-
- s +=4;
+ }
c->url = pa_xstrndup(s, strcspn(s, " \r\n\t?"));
c->state = STATE_MIME_HEADER;
diff --git a/src/pulsecore/protocol-native.c b/src/pulsecore/protocol-native.c
index d4a9952a..6b981754 100644
--- a/src/pulsecore/protocol-native.c
+++ b/src/pulsecore/protocol-native.c
@@ -29,11 +29,13 @@
#include <stdlib.h>
#include <unistd.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/version.h>
#include <pulse/utf8.h>
#include <pulse/util.h>
#include <pulse/xmalloc.h>
+#include <pulse/internal.h>
#include <pulsecore/native-common.h>
#include <pulsecore/packet.h>
@@ -44,7 +46,6 @@
#include <pulsecore/tagstruct.h>
#include <pulsecore/pdispatch.h>
#include <pulsecore/pstream-util.h>
-#include <pulsecore/authkey.h>
#include <pulsecore/namereg.h>
#include <pulsecore/core-scache.h>
#include <pulsecore/core-subscribe.h>
@@ -52,7 +53,6 @@
#include <pulsecore/strlist.h>
#include <pulsecore/shared.h>
#include <pulsecore/sample-util.h>
-#include <pulsecore/llist.h>
#include <pulsecore/creds.h>
#include <pulsecore/core-util.h>
#include <pulsecore/ipacl.h>
@@ -61,7 +61,7 @@
#include "protocol-native.h"
/* Kick a client if it doesn't authenticate within this time */
-#define AUTH_TIMEOUT 60
+#define AUTH_TIMEOUT (60 * PA_USEC_PER_SEC)
/* Don't accept more connection than this */
#define MAX_CONNECTIONS 64
@@ -85,6 +85,9 @@ typedef struct record_stream {
pa_bool_t adjust_latency:1;
pa_bool_t early_requests:1;
+ /* Requested buffer attributes */
+ pa_buffer_attr buffer_attr_req;
+ /* Fixed-up and adjusted buffer attributes */
pa_buffer_attr buffer_attr;
pa_atomic_t on_the_fly;
@@ -97,17 +100,15 @@ typedef struct record_stream {
pa_usec_t current_source_latency;
} record_stream;
-PA_DECLARE_CLASS(record_stream);
#define RECORD_STREAM(o) (record_stream_cast(o))
-static PA_DEFINE_CHECK_TYPE(record_stream, pa_msgobject);
+PA_DEFINE_PRIVATE_CLASS(record_stream, pa_msgobject);
typedef struct output_stream {
pa_msgobject parent;
} output_stream;
-PA_DECLARE_CLASS(output_stream);
#define OUTPUT_STREAM(o) (output_stream_cast(o))
-static PA_DEFINE_CHECK_TYPE(output_stream, pa_msgobject);
+PA_DEFINE_PRIVATE_CLASS(output_stream, pa_msgobject);
typedef struct playback_stream {
output_stream parent;
@@ -126,8 +127,15 @@ typedef struct playback_stream {
uint32_t drain_tag;
uint32_t syncid;
+ /* Optimization to avoid too many rewinds with a lot of small blocks */
+ pa_atomic_t seek_or_post_in_queue;
+ int64_t seek_windex;
+
pa_atomic_t missing;
pa_usec_t configured_sink_latency;
+ /* Requested buffer attributes */
+ pa_buffer_attr buffer_attr_req;
+ /* Fixed-up and adjusted buffer attributes */
pa_buffer_attr buffer_attr;
/* Only updated after SINK_INPUT_MESSAGE_UPDATE_LATENCY */
@@ -137,9 +145,8 @@ typedef struct playback_stream {
uint64_t playing_for, underrun_for;
} playback_stream;
-PA_DECLARE_CLASS(playback_stream);
#define PLAYBACK_STREAM(o) (playback_stream_cast(o))
-static PA_DEFINE_CHECK_TYPE(playback_stream, output_stream);
+PA_DEFINE_PRIVATE_CLASS(playback_stream, output_stream);
typedef struct upload_stream {
output_stream parent;
@@ -155,9 +162,8 @@ typedef struct upload_stream {
pa_proplist *proplist;
} upload_stream;
-PA_DECLARE_CLASS(upload_stream);
#define UPLOAD_STREAM(o) (upload_stream_cast(o))
-static PA_DEFINE_CHECK_TYPE(upload_stream, output_stream);
+PA_DEFINE_PRIVATE_CLASS(upload_stream, output_stream);
struct pa_native_connection {
pa_msgobject parent;
@@ -175,9 +181,8 @@ struct pa_native_connection {
pa_time_event *auth_timeout_event;
};
-PA_DECLARE_CLASS(pa_native_connection);
#define PA_NATIVE_CONNECTION(o) (pa_native_connection_cast(o))
-static PA_DEFINE_CHECK_TYPE(pa_native_connection, pa_msgobject);
+PA_DEFINE_PRIVATE_CLASS(pa_native_connection, pa_msgobject);
struct pa_native_protocol {
PA_REFCNT_DECLARE;
@@ -284,6 +289,7 @@ static void command_update_proplist(pa_pdispatch *pd, uint32_t command, uint32_t
static void command_remove_proplist(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata);
static void command_extension(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata);
static void command_set_card_profile(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata);
+static void command_set_sink_or_source_port(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata);
static const pa_pdispatch_cb_t command_table[PA_COMMAND_MAX] = {
[PA_COMMAND_ERROR] = NULL,
@@ -330,10 +336,12 @@ static const pa_pdispatch_cb_t command_table[PA_COMMAND_MAX] = {
[PA_COMMAND_SET_SINK_VOLUME] = command_set_volume,
[PA_COMMAND_SET_SINK_INPUT_VOLUME] = command_set_volume,
[PA_COMMAND_SET_SOURCE_VOLUME] = command_set_volume,
+ [PA_COMMAND_SET_SOURCE_OUTPUT_VOLUME] = command_set_volume,
[PA_COMMAND_SET_SINK_MUTE] = command_set_mute,
[PA_COMMAND_SET_SINK_INPUT_MUTE] = command_set_mute,
[PA_COMMAND_SET_SOURCE_MUTE] = command_set_mute,
+ [PA_COMMAND_SET_SOURCE_OUTPUT_MUTE] = command_set_mute,
[PA_COMMAND_SUSPEND_SINK] = command_suspend,
[PA_COMMAND_SUSPEND_SOURCE] = command_suspend,
@@ -380,6 +388,9 @@ static const pa_pdispatch_cb_t command_table[PA_COMMAND_MAX] = {
[PA_COMMAND_SET_CARD_PROFILE] = command_set_card_profile,
+ [PA_COMMAND_SET_SINK_PORT] = command_set_sink_or_source_port,
+ [PA_COMMAND_SET_SOURCE_PORT] = command_set_sink_or_source_port,
+
[PA_COMMAND_EXTENSION] = command_extension
};
@@ -521,6 +532,7 @@ static void fix_record_buffer_attr_pre(record_stream *s) {
* ->thread_info data! */
frame_size = pa_frame_size(&s->source_output->sample_spec);
+ s->buffer_attr = s->buffer_attr_req;
if (s->buffer_attr.maxlength == (uint32_t) -1 || s->buffer_attr.maxlength > MAX_MEMBLOCKQ_LENGTH)
s->buffer_attr.maxlength = MAX_MEMBLOCKQ_LENGTH;
@@ -617,18 +629,22 @@ static record_stream* record_stream_new(
pa_source *source,
pa_sample_spec *ss,
pa_channel_map *map,
- pa_bool_t peak_detect,
+ pa_idxset *formats,
pa_buffer_attr *attr,
+ pa_cvolume *volume,
+ pa_bool_t muted,
+ pa_bool_t muted_set,
pa_source_output_flags_t flags,
pa_proplist *p,
pa_bool_t adjust_latency,
- pa_sink_input *direct_on_input,
pa_bool_t early_requests,
+ pa_bool_t relative_volume,
+ pa_bool_t peak_detect,
+ pa_sink_input *direct_on_input,
int *ret) {
record_stream *s;
pa_source_output *source_output = NULL;
- size_t base;
pa_source_output_new_data data;
pa_assert(c);
@@ -642,14 +658,29 @@ static record_stream* record_stream_new(
data.driver = __FILE__;
data.module = c->options->module;
data.client = c->client;
- data.source = source;
+ if (source)
+ pa_source_output_new_data_set_source(&data, source, TRUE);
+ if (pa_sample_spec_valid(ss))
+ pa_source_output_new_data_set_sample_spec(&data, ss);
+ if (pa_channel_map_valid(map))
+ pa_source_output_new_data_set_channel_map(&data, map);
+ if (formats)
+ pa_source_output_new_data_set_formats(&data, formats);
data.direct_on_input = direct_on_input;
- pa_source_output_new_data_set_sample_spec(&data, ss);
- pa_source_output_new_data_set_channel_map(&data, map);
+ if (volume) {
+ pa_source_output_new_data_set_volume(&data, volume);
+ data.volume_is_absolute = !relative_volume;
+ data.save_volume = TRUE;
+ }
+ if (muted_set) {
+ pa_source_output_new_data_set_muted(&data, muted);
+ data.save_muted = TRUE;
+ }
if (peak_detect)
data.resample_method = PA_RESAMPLER_PEAKS;
+ data.flags = flags;
- *ret = -pa_source_output_new(&source_output, c->protocol->core, &data, flags);
+ *ret = -pa_source_output_new(&source_output, c->protocol->core, &data);
pa_source_output_new_data_done(&data);
@@ -661,7 +692,7 @@ static record_stream* record_stream_new(
s->parent.process_msg = record_stream_process_msg;
s->connection = c;
s->source_output = source_output;
- s->buffer_attr = *attr;
+ s->buffer_attr_req = *attr;
s->adjust_latency = adjust_latency;
s->early_requests = early_requests;
pa_atomic_store(&s->on_the_fly, 0);
@@ -681,7 +712,7 @@ static record_stream* record_stream_new(
0,
s->buffer_attr.maxlength,
0,
- base = pa_frame_size(&source_output->sample_spec),
+ pa_frame_size(&source_output->sample_spec),
1,
0,
0,
@@ -757,6 +788,7 @@ static int playback_stream_process_msg(pa_msgobject *o, int code, void*userdata,
return -1;
switch (code) {
+
case PLAYBACK_STREAM_MESSAGE_REQUEST_DATA: {
pa_tagstruct *t;
int l = 0;
@@ -825,24 +857,26 @@ static int playback_stream_process_msg(pa_msgobject *o, int code, void*userdata,
pa_pstream_send_simple_ack(s->connection->pstream, PA_PTR_TO_UINT(userdata));
break;
- case PLAYBACK_STREAM_MESSAGE_UPDATE_TLENGTH: {
- pa_tagstruct *t;
+ case PLAYBACK_STREAM_MESSAGE_UPDATE_TLENGTH:
s->buffer_attr.tlength = (uint32_t) offset;
- t = pa_tagstruct_new(NULL, 0);
- pa_tagstruct_putu32(t, PA_COMMAND_PLAYBACK_BUFFER_ATTR_CHANGED);
- pa_tagstruct_putu32(t, (uint32_t) -1); /* tag */
- pa_tagstruct_putu32(t, s->index);
- pa_tagstruct_putu32(t, s->buffer_attr.maxlength);
- pa_tagstruct_putu32(t, s->buffer_attr.tlength);
- pa_tagstruct_putu32(t, s->buffer_attr.prebuf);
- pa_tagstruct_putu32(t, s->buffer_attr.minreq);
- pa_tagstruct_put_usec(t, s->configured_sink_latency);
- pa_pstream_send_tagstruct(s->connection->pstream, t);
+ if (s->connection->version >= 15) {
+ pa_tagstruct *t;
+
+ t = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu32(t, PA_COMMAND_PLAYBACK_BUFFER_ATTR_CHANGED);
+ pa_tagstruct_putu32(t, (uint32_t) -1); /* tag */
+ pa_tagstruct_putu32(t, s->index);
+ pa_tagstruct_putu32(t, s->buffer_attr.maxlength);
+ pa_tagstruct_putu32(t, s->buffer_attr.tlength);
+ pa_tagstruct_putu32(t, s->buffer_attr.prebuf);
+ pa_tagstruct_putu32(t, s->buffer_attr.minreq);
+ pa_tagstruct_put_usec(t, s->configured_sink_latency);
+ pa_pstream_send_tagstruct(s->connection->pstream, t);
+ }
break;
- }
}
return 0;
@@ -855,12 +889,25 @@ static void fix_playback_buffer_attr(playback_stream *s) {
pa_assert(s);
+ /* pa_log("Client requested: maxlength=%li bytes tlength=%li bytes minreq=%li bytes prebuf=%li bytes", */
+ /* (long) s->buffer_attr.maxlength, */
+ /* (long) s->buffer_attr.tlength, */
+ /* (long) s->buffer_attr.minreq, */
+ /* (long) s->buffer_attr.prebuf); */
+
+ /* pa_log("Client requested: maxlength=%lu ms tlength=%lu ms minreq=%lu ms prebuf=%lu ms", */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.maxlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.tlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.minreq, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.prebuf, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC)); */
+
/* This function will be called from the main thread, before as
* well as after the sink input has been activated using
* pa_sink_input_put()! That means it may not touch any
* ->thread_info data, such as the memblockq! */
frame_size = pa_frame_size(&s->sink_input->sample_spec);
+ s->buffer_attr = s->buffer_attr_req;
if (s->buffer_attr.maxlength == (uint32_t) -1 || s->buffer_attr.maxlength > MAX_MEMBLOCKQ_LENGTH)
s->buffer_attr.maxlength = MAX_MEMBLOCKQ_LENGTH;
@@ -981,6 +1028,12 @@ static void fix_playback_buffer_attr(playback_stream *s) {
if (s->buffer_attr.prebuf == (uint32_t) -1 ||
s->buffer_attr.prebuf > max_prebuf)
s->buffer_attr.prebuf = max_prebuf;
+
+ /* pa_log("Client accepted: maxlength=%lu ms tlength=%lu ms minreq=%lu ms prebuf=%lu ms", */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.maxlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.tlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.minreq, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+ /* (unsigned long) (pa_bytes_to_usec(s->buffer_attr.prebuf, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC)); */
}
/* Called from main context */
@@ -989,18 +1042,23 @@ static playback_stream* playback_stream_new(
pa_sink *sink,
pa_sample_spec *ss,
pa_channel_map *map,
+ pa_idxset *formats,
pa_buffer_attr *a,
pa_cvolume *volume,
pa_bool_t muted,
pa_bool_t muted_set,
- uint32_t syncid,
- uint32_t *missing,
pa_sink_input_flags_t flags,
pa_proplist *p,
pa_bool_t adjust_latency,
pa_bool_t early_requests,
+ pa_bool_t relative_volume,
+ uint32_t syncid,
+ uint32_t *missing,
int *ret) {
+ /* Note: This function takes ownership of the 'formats' param, so we need
+ * to take extra care to not leak it */
+
playback_stream *s, *ssync;
pa_sink_input *sink_input = NULL;
pa_memchunk silence;
@@ -1015,7 +1073,7 @@ static playback_stream* playback_stream_new(
pa_assert(ret);
/* Find syncid group */
- for (ssync = pa_idxset_first(c->output_streams, &idx); ssync; ssync = pa_idxset_next(c->output_streams, &idx)) {
+ PA_IDXSET_FOREACH(ssync, c->output_streams, idx) {
if (!playback_stream_isinstance(ssync))
continue;
@@ -1031,7 +1089,7 @@ static playback_stream* playback_stream_new(
sink = ssync->sink_input->sink;
else if (sink != ssync->sink_input->sink) {
*ret = PA_ERR_INVALID;
- return NULL;
+ goto out;
}
}
@@ -1041,21 +1099,35 @@ static playback_stream* playback_stream_new(
data.driver = __FILE__;
data.module = c->options->module;
data.client = c->client;
- data.sink = sink;
- pa_sink_input_new_data_set_sample_spec(&data, ss);
- pa_sink_input_new_data_set_channel_map(&data, map);
- if (volume)
+ if (sink)
+ pa_sink_input_new_data_set_sink(&data, sink, TRUE);
+ if (pa_sample_spec_valid(ss))
+ pa_sink_input_new_data_set_sample_spec(&data, ss);
+ if (pa_channel_map_valid(map))
+ pa_sink_input_new_data_set_channel_map(&data, map);
+ if (formats) {
+ pa_sink_input_new_data_set_formats(&data, formats);
+ /* Ownership transferred to new_data, so we don't free it ourseleves */
+ formats = NULL;
+ }
+ if (volume) {
pa_sink_input_new_data_set_volume(&data, volume);
- if (muted_set)
+ data.volume_is_absolute = !relative_volume;
+ data.save_volume = TRUE;
+ }
+ if (muted_set) {
pa_sink_input_new_data_set_muted(&data, muted);
+ data.save_muted = TRUE;
+ }
data.sync_base = ssync ? ssync->sink_input : NULL;
+ data.flags = flags;
- *ret = -pa_sink_input_new(&sink_input, c->protocol->core, &data, flags);
+ *ret = -pa_sink_input_new(&sink_input, c->protocol->core, &data);
pa_sink_input_new_data_done(&data);
if (!sink_input)
- return NULL;
+ goto out;
s = pa_msgobject_new(playback_stream);
s->parent.parent.parent.free = playback_stream_free;
@@ -1066,9 +1138,11 @@ static playback_stream* playback_stream_new(
s->is_underrun = TRUE;
s->drain_request = FALSE;
pa_atomic_store(&s->missing, 0);
- s->buffer_attr = *a;
+ s->buffer_attr_req = *a;
s->adjust_latency = adjust_latency;
s->early_requests = early_requests;
+ pa_atomic_store(&s->seek_or_post_in_queue, 0);
+ s->seek_windex = -1;
s->sink_input->parent.process_msg = sink_input_process_msg;
s->sink_input->pop = sink_input_pop_cb;
@@ -1101,6 +1175,8 @@ static playback_stream* playback_stream_new(
*missing = (uint32_t) pa_memblockq_pop_missing(s->memblockq);
+ /* pa_log("missing original: %li", (long int) *missing); */
+
*ss = s->sink_input->sample_spec;
*map = s->sink_input->channel_map;
@@ -1113,6 +1189,11 @@ static playback_stream* playback_stream_new(
(double) s->configured_sink_latency / PA_USEC_PER_MSEC);
pa_sink_input_put(s->sink_input);
+
+out:
+ if (formats)
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
return s;
}
@@ -1125,6 +1206,13 @@ static void playback_stream_request_bytes(playback_stream *s) {
m = pa_memblockq_pop_missing(s->memblockq);
+ /* pa_log("request_bytes(%lu) (tlength=%lu minreq=%lu length=%lu really missing=%lli)", */
+ /* (unsigned long) m, */
+ /* pa_memblockq_get_tlength(s->memblockq), */
+ /* pa_memblockq_get_minreq(s->memblockq), */
+ /* pa_memblockq_get_length(s->memblockq), */
+ /* (long long) pa_memblockq_get_tlength(s->memblockq) - (long long) pa_memblockq_get_length(s->memblockq)); */
+
if (m <= 0)
return;
@@ -1138,7 +1226,6 @@ static void playback_stream_request_bytes(playback_stream *s) {
pa_asyncmsgq_post(pa_thread_mq_get()->outq, PA_MSGOBJECT(s), PLAYBACK_STREAM_MESSAGE_REQUEST_DATA, NULL, 0, NULL, NULL);
}
-
/* Called from main context */
static void playback_stream_send_killed(playback_stream *p) {
pa_tagstruct *t;
@@ -1248,7 +1335,7 @@ static void native_connection_send_memblock(pa_native_connection *c) {
else if (start == c->rrobin_index)
return;
- if (pa_memblockq_peek(r->memblockq, &chunk) >= 0) {
+ if (pa_memblockq_peek(r->memblockq, &chunk) >= 0) {
pa_memchunk schunk = chunk;
if (schunk.length > r->buffer_attr.fragsize)
@@ -1283,7 +1370,8 @@ static void handle_seek(playback_stream *s, int64_t indexw) {
pa_log_debug("Requesting rewind due to end of underrun.");
pa_sink_input_request_rewind(s->sink_input,
- (size_t) (s->sink_input->thread_info.underrun_for == (size_t) -1 ? 0 : s->sink_input->thread_info.underrun_for),
+ (size_t) (s->sink_input->thread_info.underrun_for == (uint64_t) -1 ? 0 :
+ s->sink_input->thread_info.underrun_for),
FALSE, TRUE, FALSE);
}
@@ -1304,6 +1392,10 @@ static void handle_seek(playback_stream *s, int64_t indexw) {
playback_stream_request_bytes(s);
}
+static void flush_write_no_account(pa_memblockq *q) {
+ pa_memblockq_flush_write(q, FALSE);
+}
+
/* Called from thread context */
static int sink_input_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offset, pa_memchunk *chunk) {
pa_sink_input *i = PA_SINK_INPUT(o);
@@ -1315,40 +1407,35 @@ static int sink_input_process_msg(pa_msgobject *o, int code, void *userdata, int
switch (code) {
- case SINK_INPUT_MESSAGE_SEEK: {
- int64_t windex;
-
- windex = pa_memblockq_get_write_index(s->memblockq);
-
- /* The client side is incapable of accounting correctly
- * for seeks of a type != PA_SEEK_RELATIVE. We need to be
- * able to deal with that. */
-
- pa_memblockq_seek(s->memblockq, offset, PA_PTR_TO_UINT(userdata), PA_PTR_TO_UINT(userdata) == PA_SEEK_RELATIVE);
-
- handle_seek(s, windex);
- return 0;
- }
-
+ case SINK_INPUT_MESSAGE_SEEK:
case SINK_INPUT_MESSAGE_POST_DATA: {
- int64_t windex;
+ int64_t windex = pa_memblockq_get_write_index(s->memblockq);
- pa_assert(chunk);
-
- windex = pa_memblockq_get_write_index(s->memblockq);
+ if (code == SINK_INPUT_MESSAGE_SEEK) {
+ /* The client side is incapable of accounting correctly
+ * for seeks of a type != PA_SEEK_RELATIVE. We need to be
+ * able to deal with that. */
-/* pa_log("sink input post: %lu %lli", (unsigned long) chunk->length, (long long) windex); */
+ pa_memblockq_seek(s->memblockq, offset, PA_PTR_TO_UINT(userdata), PA_PTR_TO_UINT(userdata) == PA_SEEK_RELATIVE);
+ windex = PA_MIN(windex, pa_memblockq_get_write_index(s->memblockq));
+ }
- if (pa_memblockq_push_align(s->memblockq, chunk) < 0) {
- pa_log_warn("Failed to push data into queue");
+ if (chunk && pa_memblockq_push_align(s->memblockq, chunk) < 0) {
+ if (pa_log_ratelimit(PA_LOG_WARN))
+ pa_log_warn("Failed to push data into queue");
pa_asyncmsgq_post(pa_thread_mq_get()->outq, PA_MSGOBJECT(s), PLAYBACK_STREAM_MESSAGE_OVERFLOW, NULL, 0, NULL, NULL);
pa_memblockq_seek(s->memblockq, (int64_t) chunk->length, PA_SEEK_RELATIVE, TRUE);
}
- handle_seek(s, windex);
-
-/* pa_log("sink input post2: %lu", (unsigned long) pa_memblockq_get_length(s->memblockq)); */
-
+ /* If more data is in queue, we rewind later instead. */
+ if (s->seek_windex != -1)
+ windex = PA_MIN(windex, s->seek_windex);
+ if (pa_atomic_dec(&s->seek_or_post_in_queue) > 1)
+ s->seek_windex = windex;
+ else {
+ s->seek_windex = -1;
+ handle_seek(s, windex);
+ }
return 0;
}
@@ -1361,9 +1448,9 @@ static int sink_input_process_msg(pa_msgobject *o, int code, void *userdata, int
pa_sink_input *isync;
void (*func)(pa_memblockq *bq);
- switch (code) {
+ switch (code) {
case SINK_INPUT_MESSAGE_FLUSH:
- func = pa_memblockq_flush_write;
+ func = flush_write_no_account;
break;
case SINK_INPUT_MESSAGE_PREBUF_FORCE:
@@ -1612,6 +1699,9 @@ static void sink_input_moving_cb(pa_sink_input *i, pa_sink *dest) {
s = PLAYBACK_STREAM(i->userdata);
playback_stream_assert_ref(s);
+ if (!dest)
+ return;
+
fix_playback_buffer_attr(s);
pa_memblockq_apply_attr(s->memblockq, &s->buffer_attr);
pa_memblockq_get_attr(s->memblockq, &s->buffer_attr);
@@ -1747,6 +1837,9 @@ static void source_output_moving_cb(pa_source_output *o, pa_source *dest) {
s = RECORD_STREAM(o->userdata);
record_stream_assert_ref(s);
+ if (!dest)
+ return;
+
fix_record_buffer_attr_pre(s);
pa_memblockq_set_maxlength(s->memblockq, s->buffer_attr.maxlength);
pa_memblockq_get_attr(s->memblockq, &s->buffer_attr);
@@ -1786,6 +1879,13 @@ if (!(expression)) { \
} \
} while(0);
+#define CHECK_VALIDITY_GOTO(pstream, expression, tag, error, label) do { \
+if (!(expression)) { \
+ pa_pstream_send_error((pstream), (tag), (error)); \
+ goto label; \
+} \
+} while(0);
+
static pa_tagstruct *reply_new(uint32_t tag) {
pa_tagstruct *reply;
@@ -1819,12 +1919,19 @@ static void command_create_playback_stream(pa_pdispatch *pd, uint32_t command, u
adjust_latency = FALSE,
early_requests = FALSE,
dont_inhibit_auto_suspend = FALSE,
+ volume_set = TRUE,
muted_set = FALSE,
- fail_on_suspend = FALSE;
+ fail_on_suspend = FALSE,
+ relative_volume = FALSE,
+ passthrough = FALSE;
+
pa_sink_input_flags_t flags = 0;
- pa_proplist *p;
- pa_bool_t volume_set = TRUE;
+ pa_proplist *p = NULL;
int ret = PA_ERR_INVALID;
+ uint8_t n_formats = 0;
+ pa_format_info *format;
+ pa_idxset *formats = NULL;
+ uint32_t i;
pa_native_connection_assert_ref(c);
pa_assert(t);
@@ -1847,24 +1954,21 @@ static void command_create_playback_stream(pa_pdispatch *pd, uint32_t command, u
PA_TAG_INVALID) < 0) {
protocol_error(c);
- return;
+ goto finish;
}
- CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
- CHECK_VALIDITY(c->pstream, !sink_name || pa_namereg_is_valid_name(sink_name), tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, sink_index == PA_INVALID_INDEX || !sink_name, tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, !sink_name || sink_index == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, pa_channel_map_valid(&map), tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, pa_sample_spec_valid(&ss), tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, pa_cvolume_valid(&volume), tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, map.channels == ss.channels && volume.channels == ss.channels, tag, PA_ERR_INVALID);
+ CHECK_VALIDITY_GOTO(c->pstream, c->authorized, tag, PA_ERR_ACCESS, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, !sink_name || pa_namereg_is_valid_name_or_wildcard(sink_name, PA_NAMEREG_SINK), tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, sink_index == PA_INVALID_INDEX || !sink_name, tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, !sink_name || sink_index == PA_INVALID_INDEX, tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, pa_cvolume_valid(&volume), tag, PA_ERR_INVALID, finish);
p = pa_proplist_new();
if (name)
pa_proplist_sets(p, PA_PROP_MEDIA_NAME, name);
- if (c->version >= 12) {
+ if (c->version >= 12) {
/* Since 0.9.8 the user can ask for a couple of additional flags */
if (pa_tagstruct_get_boolean(t, &no_remap) < 0 ||
@@ -1876,8 +1980,7 @@ static void command_create_playback_stream(pa_pdispatch *pd, uint32_t command, u
pa_tagstruct_get_boolean(t, &variable_rate) < 0) {
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
@@ -1886,9 +1989,9 @@ static void command_create_playback_stream(pa_pdispatch *pd, uint32_t command, u
if (pa_tagstruct_get_boolean(t, &muted) < 0 ||
pa_tagstruct_get_boolean(t, &adjust_latency) < 0 ||
pa_tagstruct_get_proplist(t, p) < 0) {
+
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
@@ -1896,9 +1999,9 @@ static void command_create_playback_stream(pa_pdispatch *pd, uint32_t command, u
if (pa_tagstruct_get_boolean(t, &volume_set) < 0 ||
pa_tagstruct_get_boolean(t, &early_requests) < 0) {
+
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
@@ -1907,55 +2010,101 @@ static void command_create_playback_stream(pa_pdispatch *pd, uint32_t command, u
if (pa_tagstruct_get_boolean(t, &muted_set) < 0 ||
pa_tagstruct_get_boolean(t, &dont_inhibit_auto_suspend) < 0 ||
pa_tagstruct_get_boolean(t, &fail_on_suspend) < 0) {
+
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
+ }
+ }
+
+ if (c->version >= 17) {
+
+ if (pa_tagstruct_get_boolean(t, &relative_volume) < 0) {
+
+ protocol_error(c);
+ goto finish;
+ }
+ }
+
+ if (c->version >= 18) {
+
+ if (pa_tagstruct_get_boolean(t, &passthrough) < 0 ) {
+ protocol_error(c);
+ goto finish;
+ }
+ }
+
+ if (c->version >= 21) {
+
+ if (pa_tagstruct_getu8(t, &n_formats) < 0) {
+ protocol_error(c);
+ goto finish;
+ }
+
+ if (n_formats)
+ formats = pa_idxset_new(NULL, NULL);
+
+ for (i = 0; i < n_formats; i++) {
+ format = pa_format_info_new();
+ if (pa_tagstruct_get_format_info(t, format) < 0) {
+ protocol_error(c);
+ goto finish;
+ }
+ pa_idxset_put(formats, format, NULL);
+ }
+ }
+
+ if (n_formats == 0) {
+ CHECK_VALIDITY_GOTO(c->pstream, pa_sample_spec_valid(&ss), tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, map.channels == ss.channels && volume.channels == ss.channels, tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, pa_channel_map_valid(&map), tag, PA_ERR_INVALID, finish);
+ } else {
+ PA_IDXSET_FOREACH(format, formats, i) {
+ CHECK_VALIDITY_GOTO(c->pstream, pa_format_info_valid(format), tag, PA_ERR_INVALID, finish);
}
}
if (!pa_tagstruct_eof(t)) {
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
if (sink_index != PA_INVALID_INDEX) {
if (!(sink = pa_idxset_get_by_index(c->protocol->core->sinks, sink_index))) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_NOENTITY);
- pa_proplist_free(p);
- return;
+ goto finish;
}
} else if (sink_name) {
if (!(sink = pa_namereg_get(c->protocol->core, sink_name, PA_NAMEREG_SINK))) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_NOENTITY);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
flags =
- (corked ? PA_SINK_INPUT_START_CORKED : 0) |
- (no_remap ? PA_SINK_INPUT_NO_REMAP : 0) |
- (no_remix ? PA_SINK_INPUT_NO_REMIX : 0) |
- (fix_format ? PA_SINK_INPUT_FIX_FORMAT : 0) |
- (fix_rate ? PA_SINK_INPUT_FIX_RATE : 0) |
- (fix_channels ? PA_SINK_INPUT_FIX_CHANNELS : 0) |
- (no_move ? PA_SINK_INPUT_DONT_MOVE : 0) |
- (variable_rate ? PA_SINK_INPUT_VARIABLE_RATE : 0) |
+ (corked ? PA_SINK_INPUT_START_CORKED : 0) |
+ (no_remap ? PA_SINK_INPUT_NO_REMAP : 0) |
+ (no_remix ? PA_SINK_INPUT_NO_REMIX : 0) |
+ (fix_format ? PA_SINK_INPUT_FIX_FORMAT : 0) |
+ (fix_rate ? PA_SINK_INPUT_FIX_RATE : 0) |
+ (fix_channels ? PA_SINK_INPUT_FIX_CHANNELS : 0) |
+ (no_move ? PA_SINK_INPUT_DONT_MOVE : 0) |
+ (variable_rate ? PA_SINK_INPUT_VARIABLE_RATE : 0) |
(dont_inhibit_auto_suspend ? PA_SINK_INPUT_DONT_INHIBIT_AUTO_SUSPEND : 0) |
- (fail_on_suspend ? PA_SINK_INPUT_FAIL_ON_SUSPEND : 0);
+ (fail_on_suspend ? PA_SINK_INPUT_NO_CREATE_ON_SUSPEND|PA_SINK_INPUT_KILL_ON_SUSPEND : 0) |
+ (passthrough ? PA_SINK_INPUT_PASSTHROUGH : 0);
/* Only since protocol version 15 there's a seperate muted_set
* flag. For older versions we synthesize it here */
muted_set = muted_set || muted;
- s = playback_stream_new(c, sink, &ss, &map, &attr, volume_set ? &volume : NULL, muted, muted_set, syncid, &missing, flags, p, adjust_latency, early_requests, &ret);
- pa_proplist_free(p);
+ s = playback_stream_new(c, sink, &ss, &map, formats, &attr, volume_set ? &volume : NULL, muted, muted_set, flags, p, adjust_latency, early_requests, relative_volume, syncid, &missing, &ret);
+ /* We no longer own the formats idxset */
+ formats = NULL;
- CHECK_VALIDITY(c->pstream, s, tag, ret);
+ CHECK_VALIDITY_GOTO(c->pstream, s, tag, ret, finish);
reply = reply_new(tag);
pa_tagstruct_putu32(reply, s->index);
@@ -1991,7 +2140,24 @@ static void command_create_playback_stream(pa_pdispatch *pd, uint32_t command, u
if (c->version >= 13)
pa_tagstruct_put_usec(reply, s->configured_sink_latency);
+ if (c->version >= 21) {
+ /* Send back the format we negotiated */
+ if (s->sink_input->format)
+ pa_tagstruct_put_format_info(reply, s->sink_input->format);
+ else {
+ pa_format_info *f = pa_format_info_new();
+ pa_tagstruct_put_format_info(reply, f);
+ pa_format_info_free(f);
+ }
+ }
+
pa_pstream_send_tagstruct(c->pstream, reply);
+
+finish:
+ if (p)
+ pa_proplist_free(p);
+ if (formats)
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
}
static void command_delete_stream(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
@@ -2062,6 +2228,7 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
pa_channel_map map;
pa_tagstruct *reply;
pa_source *source = NULL;
+ pa_cvolume volume;
pa_bool_t
corked = FALSE,
no_remap = FALSE,
@@ -2071,16 +2238,26 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
fix_channels = FALSE,
no_move = FALSE,
variable_rate = FALSE,
+ muted = FALSE,
adjust_latency = FALSE,
peak_detect = FALSE,
early_requests = FALSE,
dont_inhibit_auto_suspend = FALSE,
- fail_on_suspend = FALSE;
+ volume_set = TRUE,
+ muted_set = FALSE,
+ fail_on_suspend = FALSE,
+ relative_volume = FALSE,
+ passthrough = FALSE;
+
pa_source_output_flags_t flags = 0;
- pa_proplist *p;
+ pa_proplist *p = NULL;
uint32_t direct_on_input_idx = PA_INVALID_INDEX;
pa_sink_input *direct_on_input = NULL;
int ret = PA_ERR_INVALID;
+ uint8_t n_formats = 0;
+ pa_format_info *format;
+ pa_idxset *formats = NULL;
+ uint32_t i;
pa_native_connection_assert_ref(c);
pa_assert(t);
@@ -2095,24 +2272,22 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
pa_tagstruct_getu32(t, &attr.maxlength) < 0 ||
pa_tagstruct_get_boolean(t, &corked) < 0 ||
pa_tagstruct_getu32(t, &attr.fragsize) < 0) {
+
protocol_error(c);
- return;
+ goto finish;
}
- CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
- CHECK_VALIDITY(c->pstream, !source_name || pa_namereg_is_valid_name(source_name), tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, source_index == PA_INVALID_INDEX || !source_name, tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, !source_name || source_index == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, pa_sample_spec_valid(&ss), tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, pa_channel_map_valid(&map), tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, map.channels == ss.channels, tag, PA_ERR_INVALID);
+ CHECK_VALIDITY_GOTO(c->pstream, c->authorized, tag, PA_ERR_ACCESS, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, !source_name || pa_namereg_is_valid_name_or_wildcard(source_name, PA_NAMEREG_SOURCE), tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, source_index == PA_INVALID_INDEX || !source_name, tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, !source_name || source_index == PA_INVALID_INDEX, tag, PA_ERR_INVALID, finish);
p = pa_proplist_new();
if (name)
pa_proplist_sets(p, PA_PROP_MEDIA_NAME, name);
- if (c->version >= 12) {
+ if (c->version >= 12) {
/* Since 0.9.8 the user can ask for a couple of additional flags */
if (pa_tagstruct_get_boolean(t, &no_remap) < 0 ||
@@ -2124,8 +2299,7 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
pa_tagstruct_get_boolean(t, &variable_rate) < 0) {
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
@@ -2135,9 +2309,9 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
pa_tagstruct_get_boolean(t, &adjust_latency) < 0 ||
pa_tagstruct_get_proplist(t, p) < 0 ||
pa_tagstruct_getu32(t, &direct_on_input_idx) < 0) {
+
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
@@ -2145,8 +2319,7 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
if (pa_tagstruct_get_boolean(t, &early_requests) < 0) {
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
@@ -2154,32 +2327,73 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
if (pa_tagstruct_get_boolean(t, &dont_inhibit_auto_suspend) < 0 ||
pa_tagstruct_get_boolean(t, &fail_on_suspend) < 0) {
+
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
+ }
+ }
+
+ if (c->version >= 22) {
+
+ if (pa_tagstruct_getu8(t, &n_formats) < 0) {
+ protocol_error(c);
+ goto finish;
+ }
+
+ if (n_formats)
+ formats = pa_idxset_new(NULL, NULL);
+
+ for (i = 0; i < n_formats; i++) {
+ format = pa_format_info_new();
+ if (pa_tagstruct_get_format_info(t, format) < 0) {
+ protocol_error(c);
+ goto finish;
+ }
+ pa_idxset_put(formats, format, NULL);
}
+
+ if (pa_tagstruct_get_cvolume(t, &volume) < 0 ||
+ pa_tagstruct_get_boolean(t, &muted) < 0 ||
+ pa_tagstruct_get_boolean(t, &volume_set) < 0 ||
+ pa_tagstruct_get_boolean(t, &muted_set) < 0 ||
+ pa_tagstruct_get_boolean(t, &relative_volume) < 0 ||
+ pa_tagstruct_get_boolean(t, &passthrough) < 0) {
+
+ protocol_error(c);
+ goto finish;
+ }
+
+ CHECK_VALIDITY_GOTO(c->pstream, pa_cvolume_valid(&volume), tag, PA_ERR_INVALID, finish);
}
+ if (n_formats == 0) {
+ CHECK_VALIDITY_GOTO(c->pstream, pa_sample_spec_valid(&ss), tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, map.channels == ss.channels && volume.channels == ss.channels, tag, PA_ERR_INVALID, finish);
+ CHECK_VALIDITY_GOTO(c->pstream, pa_channel_map_valid(&map), tag, PA_ERR_INVALID, finish);
+ } else {
+ PA_IDXSET_FOREACH(format, formats, i) {
+ CHECK_VALIDITY_GOTO(c->pstream, pa_format_info_valid(format), tag, PA_ERR_INVALID, finish);
+ }
+ }
+
+
if (!pa_tagstruct_eof(t)) {
protocol_error(c);
- pa_proplist_free(p);
- return;
+ goto finish;
}
if (source_index != PA_INVALID_INDEX) {
if (!(source = pa_idxset_get_by_index(c->protocol->core->sources, source_index))) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_NOENTITY);
- pa_proplist_free(p);
- return;
+ goto finish;
}
} else if (source_name) {
if (!(source = pa_namereg_get(c->protocol->core, source_name, PA_NAMEREG_SOURCE))) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_NOENTITY);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
@@ -2187,27 +2401,26 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
if (!(direct_on_input = pa_idxset_get_by_index(c->protocol->core->sink_inputs, direct_on_input_idx))) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_NOENTITY);
- pa_proplist_free(p);
- return;
+ goto finish;
}
}
flags =
- (corked ? PA_SOURCE_OUTPUT_START_CORKED : 0) |
- (no_remap ? PA_SOURCE_OUTPUT_NO_REMAP : 0) |
- (no_remix ? PA_SOURCE_OUTPUT_NO_REMIX : 0) |
- (fix_format ? PA_SOURCE_OUTPUT_FIX_FORMAT : 0) |
- (fix_rate ? PA_SOURCE_OUTPUT_FIX_RATE : 0) |
- (fix_channels ? PA_SOURCE_OUTPUT_FIX_CHANNELS : 0) |
- (no_move ? PA_SOURCE_OUTPUT_DONT_MOVE : 0) |
- (variable_rate ? PA_SOURCE_OUTPUT_VARIABLE_RATE : 0) |
+ (corked ? PA_SOURCE_OUTPUT_START_CORKED : 0) |
+ (no_remap ? PA_SOURCE_OUTPUT_NO_REMAP : 0) |
+ (no_remix ? PA_SOURCE_OUTPUT_NO_REMIX : 0) |
+ (fix_format ? PA_SOURCE_OUTPUT_FIX_FORMAT : 0) |
+ (fix_rate ? PA_SOURCE_OUTPUT_FIX_RATE : 0) |
+ (fix_channels ? PA_SOURCE_OUTPUT_FIX_CHANNELS : 0) |
+ (no_move ? PA_SOURCE_OUTPUT_DONT_MOVE : 0) |
+ (variable_rate ? PA_SOURCE_OUTPUT_VARIABLE_RATE : 0) |
(dont_inhibit_auto_suspend ? PA_SOURCE_OUTPUT_DONT_INHIBIT_AUTO_SUSPEND : 0) |
- (fail_on_suspend ? PA_SOURCE_OUTPUT_FAIL_ON_SUSPEND : 0);
+ (fail_on_suspend ? PA_SOURCE_OUTPUT_NO_CREATE_ON_SUSPEND|PA_SOURCE_OUTPUT_KILL_ON_SUSPEND : 0) |
+ (passthrough ? PA_SOURCE_OUTPUT_PASSTHROUGH : 0);
- s = record_stream_new(c, source, &ss, &map, peak_detect, &attr, flags, p, adjust_latency, direct_on_input, early_requests, &ret);
- pa_proplist_free(p);
+ s = record_stream_new(c, source, &ss, &map, formats, &attr, volume_set ? &volume : NULL, muted, muted_set, flags, p, adjust_latency, early_requests, relative_volume, peak_detect, direct_on_input, &ret);
- CHECK_VALIDITY(c->pstream, s, tag, ret);
+ CHECK_VALIDITY_GOTO(c->pstream, s, tag, ret, finish);
reply = reply_new(tag);
pa_tagstruct_putu32(reply, s->index);
@@ -2238,7 +2451,24 @@ static void command_create_record_stream(pa_pdispatch *pd, uint32_t command, uin
if (c->version >= 13)
pa_tagstruct_put_usec(reply, s->configured_source_latency);
+ if (c->version >= 22) {
+ /* Send back the format we negotiated */
+ if (s->source_output->format)
+ pa_tagstruct_put_format_info(reply, s->source_output->format);
+ else {
+ pa_format_info *f = pa_format_info_new();
+ pa_tagstruct_put_format_info(reply, f);
+ pa_format_info_free(f);
+ }
+ }
+
pa_pstream_send_tagstruct(c->pstream, reply);
+
+finish:
+ if (p)
+ pa_proplist_free(p);
+ if (formats)
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
}
static void command_exit(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
@@ -2257,6 +2487,8 @@ static void command_exit(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_ta
ret = pa_core_exit(c->protocol->core, FALSE, 0);
CHECK_VALIDITY(c->pstream, ret >= 0, tag, PA_ERR_ACCESS);
+ pa_log_debug("Client %s asks us to terminate.", pa_strnull(pa_proplist_gets(c->client->proplist, PA_PROP_APPLICATION_PROCESS_BINARY)));
+
pa_pstream_send_simple_ack(c->pstream, tag); /* nonsense */
}
@@ -2446,7 +2678,7 @@ static void command_lookup(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_
}
CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
- CHECK_VALIDITY(c->pstream, name && pa_namereg_is_valid_name(name), tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, name && pa_namereg_is_valid_name_or_wildcard(name, command == PA_COMMAND_LOOKUP_SINK ? PA_NAMEREG_SINK : PA_NAMEREG_SOURCE), tag, PA_ERR_INVALID);
if (command == PA_COMMAND_LOOKUP_SINK) {
pa_sink *sink;
@@ -2545,7 +2777,7 @@ static void command_get_playback_latency(pa_pdispatch *pd, uint32_t command, uin
reply = reply_new(tag);
pa_tagstruct_put_usec(reply,
s->current_sink_latency +
- pa_bytes_to_usec(s->render_memblockq_length, &s->sink_input->sample_spec));
+ pa_bytes_to_usec(s->render_memblockq_length, &s->sink_input->sink->sample_spec));
pa_tagstruct_put_usec(reply, 0);
pa_tagstruct_put_boolean(reply,
s->playing_for > 0 &&
@@ -2592,7 +2824,7 @@ static void command_get_record_latency(pa_pdispatch *pd, uint32_t command, uint3
pa_tagstruct_put_usec(reply, s->current_monitor_latency);
pa_tagstruct_put_usec(reply,
s->current_source_latency +
- pa_bytes_to_usec(s->on_the_fly_snapshot, &s->source_output->sample_spec));
+ pa_bytes_to_usec(s->on_the_fly_snapshot, &s->source_output->source->sample_spec));
pa_tagstruct_put_boolean(reply,
pa_source_get_state(s->source_output->source) == PA_SOURCE_RUNNING &&
pa_source_output_get_state(s->source_output) == PA_SOURCE_OUTPUT_RUNNING);
@@ -2684,7 +2916,9 @@ static void command_finish_upload_stream(pa_pdispatch *pd, uint32_t command, uin
CHECK_VALIDITY(c->pstream, s, tag, PA_ERR_NOENTITY);
CHECK_VALIDITY(c->pstream, upload_stream_isinstance(s), tag, PA_ERR_NOENTITY);
- if (pa_scache_add_item(c->protocol->core, s->name, &s->sample_spec, &s->channel_map, &s->memchunk, s->proplist, &idx) < 0)
+ if (!s->memchunk.memblock)
+ pa_pstream_send_error(c->pstream, tag, PA_ERR_TOOLARGE);
+ else if (pa_scache_add_item(c->protocol->core, s->name, &s->sample_spec, &s->channel_map, &s->memchunk, s->proplist, &idx) < 0)
pa_pstream_send_error(c->pstream, tag, PA_ERR_INTERNAL);
else
pa_pstream_send_simple_ack(c->pstream, tag);
@@ -2715,7 +2949,7 @@ static void command_play_sample(pa_pdispatch *pd, uint32_t command, uint32_t tag
return;
}
- CHECK_VALIDITY(c->pstream, !sink_name || pa_namereg_is_valid_name(sink_name), tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, !sink_name || pa_namereg_is_valid_name_or_wildcard(sink_name, PA_NAMEREG_SINK), tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, sink_index == PA_INVALID_INDEX || !sink_name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, !sink_name || sink_index == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, name && pa_namereg_is_valid_name(name), tag, PA_ERR_INVALID);
@@ -2819,13 +3053,13 @@ static void sink_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t, pa_sin
PA_TAG_SAMPLE_SPEC, &fixed_ss,
PA_TAG_CHANNEL_MAP, &sink->channel_map,
PA_TAG_U32, sink->module ? sink->module->index : PA_INVALID_INDEX,
- PA_TAG_CVOLUME, pa_sink_get_volume(sink, FALSE, FALSE),
+ PA_TAG_CVOLUME, pa_sink_get_volume(sink, FALSE),
PA_TAG_BOOLEAN, pa_sink_get_mute(sink, FALSE),
PA_TAG_U32, sink->monitor_source ? sink->monitor_source->index : PA_INVALID_INDEX,
PA_TAG_STRING, sink->monitor_source ? sink->monitor_source->name : NULL,
PA_TAG_USEC, pa_sink_get_latency(sink),
PA_TAG_STRING, sink->driver,
- PA_TAG_U32, sink->flags,
+ PA_TAG_U32, sink->flags & ~PA_SINK_SHARE_VOLUME_WITH_MASTER,
PA_TAG_INVALID);
if (c->version >= 13) {
@@ -2841,6 +3075,36 @@ static void sink_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t, pa_sin
pa_tagstruct_putu32(t, sink->n_volume_steps);
pa_tagstruct_putu32(t, sink->card ? sink->card->index : PA_INVALID_INDEX);
}
+
+ if (c->version >= 16) {
+ pa_tagstruct_putu32(t, sink->ports ? pa_hashmap_size(sink->ports) : 0);
+
+ if (sink->ports) {
+ void *state;
+ pa_device_port *p;
+
+ PA_HASHMAP_FOREACH(p, sink->ports, state) {
+ pa_tagstruct_puts(t, p->name);
+ pa_tagstruct_puts(t, p->description);
+ pa_tagstruct_putu32(t, p->priority);
+ }
+ }
+
+ pa_tagstruct_puts(t, sink->active_port ? sink->active_port->name : NULL);
+ }
+
+ if (c->version >= 21) {
+ uint32_t i;
+ pa_format_info *f;
+ pa_idxset *formats = pa_sink_get_formats(sink);
+
+ pa_tagstruct_putu8(t, (uint8_t) pa_idxset_size(formats));
+ PA_IDXSET_FOREACH(f, formats, i) {
+ pa_tagstruct_put_format_info(t, f);
+ }
+
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ }
}
static void source_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t, pa_source *source) {
@@ -2881,6 +3145,37 @@ static void source_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t, pa_s
pa_tagstruct_putu32(t, source->n_volume_steps);
pa_tagstruct_putu32(t, source->card ? source->card->index : PA_INVALID_INDEX);
}
+
+ if (c->version >= 16) {
+
+ pa_tagstruct_putu32(t, source->ports ? pa_hashmap_size(source->ports) : 0);
+
+ if (source->ports) {
+ void *state;
+ pa_device_port *p;
+
+ PA_HASHMAP_FOREACH(p, source->ports, state) {
+ pa_tagstruct_puts(t, p->name);
+ pa_tagstruct_puts(t, p->description);
+ pa_tagstruct_putu32(t, p->priority);
+ }
+ }
+
+ pa_tagstruct_puts(t, source->active_port ? source->active_port->name : NULL);
+ }
+
+ if (c->version >= 22) {
+ uint32_t i;
+ pa_format_info *f;
+ pa_idxset *formats = pa_source_get_formats(source);
+
+ pa_tagstruct_putu8(t, (uint8_t) pa_idxset_size(formats));
+ PA_IDXSET_FOREACH(f, formats, i) {
+ pa_tagstruct_put_format_info(t, f);
+ }
+
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ }
}
static void client_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t, pa_client *client) {
@@ -2944,12 +3239,19 @@ static void sink_input_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t,
pa_sample_spec fixed_ss;
pa_usec_t sink_latency;
pa_cvolume v;
+ pa_bool_t has_volume = FALSE;
pa_assert(t);
pa_sink_input_assert_ref(s);
fixup_sample_spec(c, &fixed_ss, &s->sample_spec);
+ has_volume = pa_sink_input_is_volume_readable(s);
+ if (has_volume)
+ pa_sink_input_get_volume(s, &v, TRUE);
+ else
+ pa_cvolume_reset(&v, fixed_ss.channels);
+
pa_tagstruct_putu32(t, s->index);
pa_tagstruct_puts(t, pa_strnull(pa_proplist_gets(s->proplist, PA_PROP_MEDIA_NAME)));
pa_tagstruct_putu32(t, s->module ? s->module->index : PA_INVALID_INDEX);
@@ -2957,7 +3259,7 @@ static void sink_input_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t,
pa_tagstruct_putu32(t, s->sink->index);
pa_tagstruct_put_sample_spec(t, &fixed_ss);
pa_tagstruct_put_channel_map(t, &s->channel_map);
- pa_tagstruct_put_cvolume(t, pa_sink_input_get_volume(s, &v, TRUE));
+ pa_tagstruct_put_cvolume(t, &v);
pa_tagstruct_put_usec(t, pa_sink_input_get_latency(s, &sink_latency));
pa_tagstruct_put_usec(t, sink_latency);
pa_tagstruct_puts(t, pa_resample_method_to_string(pa_sink_input_get_resample_method(s)));
@@ -2966,17 +3268,33 @@ static void sink_input_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t,
pa_tagstruct_put_boolean(t, pa_sink_input_get_mute(s));
if (c->version >= 13)
pa_tagstruct_put_proplist(t, s->proplist);
+ if (c->version >= 19)
+ pa_tagstruct_put_boolean(t, (pa_sink_input_get_state(s) == PA_SINK_INPUT_CORKED));
+ if (c->version >= 20) {
+ pa_tagstruct_put_boolean(t, has_volume);
+ pa_tagstruct_put_boolean(t, s->volume_writable);
+ }
+ if (c->version >= 21)
+ pa_tagstruct_put_format_info(t, s->format);
}
static void source_output_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t, pa_source_output *s) {
pa_sample_spec fixed_ss;
pa_usec_t source_latency;
+ pa_cvolume v;
+ pa_bool_t has_volume = FALSE;
pa_assert(t);
pa_source_output_assert_ref(s);
fixup_sample_spec(c, &fixed_ss, &s->sample_spec);
+ has_volume = pa_source_output_is_volume_readable(s);
+ if (has_volume)
+ pa_source_output_get_volume(s, &v, TRUE);
+ else
+ pa_cvolume_reset(&v, fixed_ss.channels);
+
pa_tagstruct_putu32(t, s->index);
pa_tagstruct_puts(t, pa_strnull(pa_proplist_gets(s->proplist, PA_PROP_MEDIA_NAME)));
pa_tagstruct_putu32(t, s->module ? s->module->index : PA_INVALID_INDEX);
@@ -2988,9 +3306,17 @@ static void source_output_fill_tagstruct(pa_native_connection *c, pa_tagstruct *
pa_tagstruct_put_usec(t, source_latency);
pa_tagstruct_puts(t, pa_resample_method_to_string(pa_source_output_get_resample_method(s)));
pa_tagstruct_puts(t, s->driver);
-
if (c->version >= 13)
pa_tagstruct_put_proplist(t, s->proplist);
+ if (c->version >= 19)
+ pa_tagstruct_put_boolean(t, (pa_source_output_get_state(s) == PA_SOURCE_OUTPUT_CORKED));
+ if (c->version >= 22) {
+ pa_tagstruct_put_cvolume(t, &v);
+ pa_tagstruct_put_boolean(t, pa_source_output_get_mute(s));
+ pa_tagstruct_put_boolean(t, has_volume);
+ pa_tagstruct_put_boolean(t, s->volume_writable);
+ pa_tagstruct_put_format_info(t, s->format);
+ }
}
static void scache_fill_tagstruct(pa_native_connection *c, pa_tagstruct *t, pa_scache_entry *e) {
@@ -3054,7 +3380,12 @@ static void command_get_info(pa_pdispatch *pd, uint32_t command, uint32_t tag, p
}
CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
- CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name(name), tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, !name ||
+ (command == PA_COMMAND_GET_SINK_INFO &&
+ pa_namereg_is_valid_name_or_wildcard(name, PA_NAMEREG_SINK)) ||
+ (command == PA_COMMAND_GET_SOURCE_INFO &&
+ pa_namereg_is_valid_name_or_wildcard(name, PA_NAMEREG_SOURCE)) ||
+ pa_namereg_is_valid_name(name), tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx != PA_INVALID_INDEX || name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx == PA_INVALID_INDEX || !name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, !name || idx == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
@@ -3280,7 +3611,9 @@ static void command_set_volume(
pa_sink *sink = NULL;
pa_source *source = NULL;
pa_sink_input *si = NULL;
+ pa_source_output *so = NULL;
const char *name = NULL;
+ const char *client_name;
pa_native_connection_assert_ref(c);
pa_assert(t);
@@ -3295,7 +3628,7 @@ static void command_set_volume(
}
CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
- CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name(name), tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name_or_wildcard(name, command == PA_COMMAND_SET_SINK_VOLUME ? PA_NAMEREG_SINK : PA_NAMEREG_SOURCE), tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx != PA_INVALID_INDEX || name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx == PA_INVALID_INDEX || !name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, !name || idx == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
@@ -3321,18 +3654,44 @@ static void command_set_volume(
si = pa_idxset_get_by_index(c->protocol->core->sink_inputs, idx);
break;
+ case PA_COMMAND_SET_SOURCE_OUTPUT_VOLUME:
+ so = pa_idxset_get_by_index(c->protocol->core->source_outputs, idx);
+ break;
+
default:
pa_assert_not_reached();
}
- CHECK_VALIDITY(c->pstream, si || sink || source, tag, PA_ERR_NOENTITY);
+ CHECK_VALIDITY(c->pstream, si || so || sink || source, tag, PA_ERR_NOENTITY);
- if (sink)
- pa_sink_set_volume(sink, &volume, TRUE, TRUE, TRUE);
- else if (source)
- pa_source_set_volume(source, &volume);
- else if (si)
+ client_name = pa_strnull(pa_proplist_gets(c->client->proplist, PA_PROP_APPLICATION_PROCESS_BINARY));
+
+ if (sink) {
+ CHECK_VALIDITY(c->pstream, volume.channels == 1 || pa_cvolume_compatible(&volume, &sink->sample_spec), tag, PA_ERR_INVALID);
+
+ pa_log_debug("Client %s changes volume of sink %s.", client_name, sink->name);
+ pa_sink_set_volume(sink, &volume, TRUE, TRUE);
+ } else if (source) {
+ CHECK_VALIDITY(c->pstream, volume.channels == 1 || pa_cvolume_compatible(&volume, &source->sample_spec), tag, PA_ERR_INVALID);
+
+ pa_log_debug("Client %s changes volume of source %s.", client_name, source->name);
+ pa_source_set_volume(source, &volume, TRUE, TRUE);
+ } else if (si) {
+ CHECK_VALIDITY(c->pstream, si->volume_writable, tag, PA_ERR_BADSTATE);
+ CHECK_VALIDITY(c->pstream, volume.channels == 1 || pa_cvolume_compatible(&volume, &si->sample_spec), tag, PA_ERR_INVALID);
+
+ pa_log_debug("Client %s changes volume of sink input %s.",
+ client_name,
+ pa_strnull(pa_proplist_gets(si->proplist, PA_PROP_MEDIA_NAME)));
pa_sink_input_set_volume(si, &volume, TRUE, TRUE);
+ } else if (so) {
+ CHECK_VALIDITY(c->pstream, volume.channels == 1 || pa_cvolume_compatible(&volume, &so->sample_spec), tag, PA_ERR_INVALID);
+
+ pa_log_debug("Client %s changes volume of source output %s.",
+ client_name,
+ pa_strnull(pa_proplist_gets(so->proplist, PA_PROP_MEDIA_NAME)));
+ pa_source_output_set_volume(so, &volume, TRUE, TRUE);
+ }
pa_pstream_send_simple_ack(c->pstream, tag);
}
@@ -3350,7 +3709,8 @@ static void command_set_mute(
pa_sink *sink = NULL;
pa_source *source = NULL;
pa_sink_input *si = NULL;
- const char *name = NULL;
+ pa_source_output *so = NULL;
+ const char *name = NULL, *client_name;
pa_native_connection_assert_ref(c);
pa_assert(t);
@@ -3365,7 +3725,7 @@ static void command_set_mute(
}
CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
- CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name(name), tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name_or_wildcard(name, command == PA_COMMAND_SET_SINK_MUTE ? PA_NAMEREG_SINK : PA_NAMEREG_SOURCE), tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx != PA_INVALID_INDEX || name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx == PA_INVALID_INDEX || !name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, !name || idx == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
@@ -3373,7 +3733,6 @@ static void command_set_mute(
switch (command) {
case PA_COMMAND_SET_SINK_MUTE:
-
if (idx != PA_INVALID_INDEX)
sink = pa_idxset_get_by_index(c->protocol->core->sinks, idx);
else
@@ -3393,18 +3752,35 @@ static void command_set_mute(
si = pa_idxset_get_by_index(c->protocol->core->sink_inputs, idx);
break;
+ case PA_COMMAND_SET_SOURCE_OUTPUT_MUTE:
+ so = pa_idxset_get_by_index(c->protocol->core->source_outputs, idx);
+ break;
+
default:
pa_assert_not_reached();
}
- CHECK_VALIDITY(c->pstream, si || sink || source, tag, PA_ERR_NOENTITY);
+ CHECK_VALIDITY(c->pstream, si || so || sink || source, tag, PA_ERR_NOENTITY);
- if (sink)
- pa_sink_set_mute(sink, mute);
- else if (source)
- pa_source_set_mute(source, mute);
- else if (si)
+ client_name = pa_strnull(pa_proplist_gets(c->client->proplist, PA_PROP_APPLICATION_PROCESS_BINARY));
+
+ if (sink) {
+ pa_log_debug("Client %s changes mute of sink %s.", client_name, sink->name);
+ pa_sink_set_mute(sink, mute, TRUE);
+ } else if (source) {
+ pa_log_debug("Client %s changes mute of source %s.", client_name, source->name);
+ pa_source_set_mute(source, mute, TRUE);
+ } else if (si) {
+ pa_log_debug("Client %s changes mute of sink input %s.",
+ client_name,
+ pa_strnull(pa_proplist_gets(si->proplist, PA_PROP_MEDIA_NAME)));
pa_sink_input_set_mute(si, mute, TRUE);
+ } else if (so) {
+ pa_log_debug("Client %s changes mute of source output %s.",
+ client_name,
+ pa_strnull(pa_proplist_gets(so->proplist, PA_PROP_MEDIA_NAME)));
+ pa_source_output_set_mute(so, mute, TRUE);
+ }
pa_pstream_send_simple_ack(c->pstream, tag);
}
@@ -3568,7 +3944,7 @@ static void command_set_stream_buffer_attr(pa_pdispatch *pd, uint32_t command, u
s->adjust_latency = adjust_latency;
s->early_requests = early_requests;
- s->buffer_attr = a;
+ s->buffer_attr_req = a;
fix_playback_buffer_attr(s);
pa_assert_se(pa_asyncmsgq_send(s->sink_input->sink->asyncmsgq, PA_MSGOBJECT(s->sink_input), SINK_INPUT_MESSAGE_UPDATE_BUFFER_ATTR, NULL, 0, NULL) == 0);
@@ -3604,7 +3980,7 @@ static void command_set_stream_buffer_attr(pa_pdispatch *pd, uint32_t command, u
s->adjust_latency = adjust_latency;
s->early_requests = early_requests;
- s->buffer_attr = a;
+ s->buffer_attr_req = a;
fix_record_buffer_attr_pre(s);
pa_memblockq_set_maxlength(s->memblockq, s->buffer_attr.maxlength);
@@ -4023,7 +4399,7 @@ static void command_move_stream(pa_pdispatch *pd, uint32_t command, uint32_t tag
CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
CHECK_VALIDITY(c->pstream, idx != PA_INVALID_INDEX, tag, PA_ERR_INVALID);
- CHECK_VALIDITY(c->pstream, !name_device || pa_namereg_is_valid_name(name_device), tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, !name_device || pa_namereg_is_valid_name_or_wildcard(name_device, command == PA_COMMAND_MOVE_SINK_INPUT ? PA_NAMEREG_SINK : PA_NAMEREG_SOURCE), tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx_device != PA_INVALID_INDEX || name_device, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx_device == PA_INVALID_INDEX || !name_device, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, !name_device || idx_device == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
@@ -4087,7 +4463,7 @@ static void command_suspend(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
}
CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
- CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name(name) || *name == 0, tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name_or_wildcard(name, command == PA_COMMAND_SUSPEND_SINK ? PA_NAMEREG_SINK : PA_NAMEREG_SOURCE) || *name == 0, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx != PA_INVALID_INDEX || name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, idx == PA_INVALID_INDEX || !name, tag, PA_ERR_INVALID);
CHECK_VALIDITY(c->pstream, !name || idx == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
@@ -4098,7 +4474,7 @@ static void command_suspend(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
pa_log_debug("%s all sinks", b ? "Suspending" : "Resuming");
- if (pa_sink_suspend_all(c->protocol->core, b) < 0) {
+ if (pa_sink_suspend_all(c->protocol->core, b, PA_SUSPEND_USER) < 0) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_INVALID);
return;
}
@@ -4112,7 +4488,7 @@ static void command_suspend(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
CHECK_VALIDITY(c->pstream, sink, tag, PA_ERR_NOENTITY);
- if (pa_sink_suspend(sink, b) < 0) {
+ if (pa_sink_suspend(sink, b, PA_SUSPEND_USER) < 0) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_INVALID);
return;
}
@@ -4125,7 +4501,7 @@ static void command_suspend(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
pa_log_debug("%s all sources", b ? "Suspending" : "Resuming");
- if (pa_source_suspend_all(c->protocol->core, b) < 0) {
+ if (pa_source_suspend_all(c->protocol->core, b, PA_SUSPEND_USER) < 0) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_INVALID);
return;
}
@@ -4140,7 +4516,7 @@ static void command_suspend(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa
CHECK_VALIDITY(c->pstream, source, tag, PA_ERR_NOENTITY);
- if (pa_source_suspend(source, b) < 0) {
+ if (pa_source_suspend(source, b, PA_SUSPEND_USER) < 0) {
pa_pstream_send_error(c->pstream, tag, PA_ERR_INVALID);
return;
}
@@ -4195,6 +4571,7 @@ static void command_set_card_profile(pa_pdispatch *pd, uint32_t command, uint32_
uint32_t idx = PA_INVALID_INDEX;
const char *name = NULL, *profile = NULL;
pa_card *card = NULL;
+ int ret;
pa_native_connection_assert_ref(c);
pa_assert(t);
@@ -4220,14 +4597,72 @@ static void command_set_card_profile(pa_pdispatch *pd, uint32_t command, uint32_
CHECK_VALIDITY(c->pstream, card, tag, PA_ERR_NOENTITY);
- if (pa_card_set_profile(card, profile, TRUE) < 0) {
- pa_pstream_send_error(c->pstream, tag, PA_ERR_INVALID);
+ if ((ret = pa_card_set_profile(card, profile, TRUE)) < 0) {
+ pa_pstream_send_error(c->pstream, tag, -ret);
return;
}
pa_pstream_send_simple_ack(c->pstream, tag);
}
+static void command_set_sink_or_source_port(pa_pdispatch *pd, uint32_t command, uint32_t tag, pa_tagstruct *t, void *userdata) {
+ pa_native_connection *c = PA_NATIVE_CONNECTION(userdata);
+ uint32_t idx = PA_INVALID_INDEX;
+ const char *name = NULL, *port = NULL;
+ int ret;
+
+ pa_native_connection_assert_ref(c);
+ pa_assert(t);
+
+ if (pa_tagstruct_getu32(t, &idx) < 0 ||
+ pa_tagstruct_gets(t, &name) < 0 ||
+ pa_tagstruct_gets(t, &port) < 0 ||
+ !pa_tagstruct_eof(t)) {
+ protocol_error(c);
+ return;
+ }
+
+ CHECK_VALIDITY(c->pstream, c->authorized, tag, PA_ERR_ACCESS);
+ CHECK_VALIDITY(c->pstream, !name || pa_namereg_is_valid_name_or_wildcard(name, command == PA_COMMAND_SET_SINK_PORT ? PA_NAMEREG_SINK : PA_NAMEREG_SOURCE), tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, idx != PA_INVALID_INDEX || name, tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, idx == PA_INVALID_INDEX || !name, tag, PA_ERR_INVALID);
+ CHECK_VALIDITY(c->pstream, !name || idx == PA_INVALID_INDEX, tag, PA_ERR_INVALID);
+
+ if (command == PA_COMMAND_SET_SINK_PORT) {
+ pa_sink *sink;
+
+ if (idx != PA_INVALID_INDEX)
+ sink = pa_idxset_get_by_index(c->protocol->core->sinks, idx);
+ else
+ sink = pa_namereg_get(c->protocol->core, name, PA_NAMEREG_SINK);
+
+ CHECK_VALIDITY(c->pstream, sink, tag, PA_ERR_NOENTITY);
+
+ if ((ret = pa_sink_set_port(sink, port, TRUE)) < 0) {
+ pa_pstream_send_error(c->pstream, tag, -ret);
+ return;
+ }
+ } else {
+ pa_source *source;
+
+ pa_assert(command = PA_COMMAND_SET_SOURCE_PORT);
+
+ if (idx != PA_INVALID_INDEX)
+ source = pa_idxset_get_by_index(c->protocol->core->sources, idx);
+ else
+ source = pa_namereg_get(c->protocol->core, name, PA_NAMEREG_SOURCE);
+
+ CHECK_VALIDITY(c->pstream, source, tag, PA_ERR_NOENTITY);
+
+ if ((ret = pa_source_set_port(source, port, TRUE)) < 0) {
+ pa_pstream_send_error(c->pstream, tag, -ret);
+ return;
+ }
+ }
+
+ pa_pstream_send_simple_ack(c->pstream, tag);
+}
+
/*** pstream callbacks ***/
static void pstream_packet_callback(pa_pstream *p, pa_packet *packet, const pa_creds *creds, void *userdata) {
@@ -4262,11 +4697,12 @@ static void pstream_memblock_callback(pa_pstream *p, uint32_t channel, int64_t o
if (playback_stream_isinstance(stream)) {
playback_stream *ps = PLAYBACK_STREAM(stream);
+ pa_atomic_inc(&ps->seek_or_post_in_queue);
if (chunk->memblock) {
if (seek != PA_SEEK_RELATIVE || offset != 0)
- pa_asyncmsgq_post(ps->sink_input->sink->asyncmsgq, PA_MSGOBJECT(ps->sink_input), SINK_INPUT_MESSAGE_SEEK, PA_UINT_TO_PTR(seek), offset, NULL, NULL);
-
- pa_asyncmsgq_post(ps->sink_input->sink->asyncmsgq, PA_MSGOBJECT(ps->sink_input), SINK_INPUT_MESSAGE_POST_DATA, NULL, 0, chunk, NULL);
+ pa_asyncmsgq_post(ps->sink_input->sink->asyncmsgq, PA_MSGOBJECT(ps->sink_input), SINK_INPUT_MESSAGE_SEEK, PA_UINT_TO_PTR(seek), offset, chunk, NULL);
+ else
+ pa_asyncmsgq_post(ps->sink_input->sink->asyncmsgq, PA_MSGOBJECT(ps->sink_input), SINK_INPUT_MESSAGE_POST_DATA, NULL, 0, chunk, NULL);
} else
pa_asyncmsgq_post(ps->sink_input->sink->asyncmsgq, PA_MSGOBJECT(ps->sink_input), SINK_INPUT_MESSAGE_SEEK, PA_UINT_TO_PTR(seek), offset+chunk->length, NULL, NULL);
@@ -4381,11 +4817,10 @@ static void client_send_event_cb(pa_client *client, const char*event, pa_proplis
/*** module entry points ***/
-static void auth_timeout(pa_mainloop_api*m, pa_time_event *e, const struct timeval *tv, void *userdata) {
+static void auth_timeout(pa_mainloop_api*m, pa_time_event *e, const struct timeval *t, void *userdata) {
pa_native_connection *c = PA_NATIVE_CONNECTION(userdata);
pa_assert(m);
- pa_assert(tv);
pa_native_connection_assert_ref(c);
pa_assert(c->auth_timeout_event == e);
@@ -4443,12 +4878,9 @@ void pa_native_protocol_connect(pa_native_protocol *p, pa_iochannel *io, pa_nati
c->authorized = TRUE;
}
- if (!c->authorized) {
- struct timeval tv;
- pa_gettimeofday(&tv);
- tv.tv_sec += AUTH_TIMEOUT;
- c->auth_timeout_event = p->core->mainloop->time_new(p->core->mainloop, &tv, auth_timeout, c);
- } else
+ if (!c->authorized)
+ c->auth_timeout_event = pa_core_rttime_new(p->core, pa_rtclock_now() + AUTH_TIMEOUT, auth_timeout, c);
+ else
c->auth_timeout_event = NULL;
c->is_local = pa_iochannel_socket_is_local(io);
@@ -4467,7 +4899,7 @@ void pa_native_protocol_connect(pa_native_protocol *p, pa_iochannel *io, pa_nati
pa_pstream_set_revoke_callback(c->pstream, pstream_revoke_callback, c);
pa_pstream_set_release_callback(c->pstream, pstream_release_callback, c);
- c->pdispatch = pa_pdispatch_new(p->core->mainloop, command_table, PA_COMMAND_MAX);
+ c->pdispatch = pa_pdispatch_new(p->core->mainloop, TRUE, command_table, PA_COMMAND_MAX);
c->record_streams = pa_idxset_new(NULL, NULL);
c->output_streams = pa_idxset_new(NULL, NULL);
@@ -4727,3 +5159,9 @@ pa_pstream* pa_native_connection_get_pstream(pa_native_connection *c) {
return c->pstream;
}
+
+pa_client* pa_native_connection_get_client(pa_native_connection *c) {
+ pa_native_connection_assert_ref(c);
+
+ return c->client;
+}
diff --git a/src/pulsecore/protocol-native.h b/src/pulsecore/protocol-native.h
index 8a8d601c..97126274 100644
--- a/src/pulsecore/protocol-native.h
+++ b/src/pulsecore/protocol-native.h
@@ -47,7 +47,6 @@ typedef struct pa_native_options {
char *auth_group;
pa_ip_acl *auth_ip_acl;
pa_auth_cookie *auth_cookie;
-
} pa_native_options;
typedef enum pa_native_hook {
@@ -80,6 +79,7 @@ int pa_native_protocol_install_ext(pa_native_protocol *p, pa_module *m, pa_nativ
void pa_native_protocol_remove_ext(pa_native_protocol *p, pa_module *m);
pa_pstream* pa_native_connection_get_pstream(pa_native_connection *c);
+pa_client* pa_native_connection_get_client(pa_native_connection *c);
pa_native_options* pa_native_options_new(void);
pa_native_options* pa_native_options_ref(pa_native_options *o);
diff --git a/src/pulsecore/protocol-simple.c b/src/pulsecore/protocol-simple.c
index 776d74b6..6def27fd 100644
--- a/src/pulsecore/protocol-simple.c
+++ b/src/pulsecore/protocol-simple.c
@@ -24,10 +24,8 @@
#endif
#include <stdlib.h>
-#include <limits.h>
#include <stdio.h>
#include <errno.h>
-#include <string.h>
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
@@ -69,9 +67,8 @@ typedef struct connection {
} playback;
} connection;
-PA_DECLARE_CLASS(connection);
+PA_DEFINE_PRIVATE_CLASS(connection, pa_msgobject);
#define CONNECTION(o) (connection_cast(o))
-static PA_DEFINE_CHECK_TYPE(connection, pa_msgobject);
struct pa_simple_protocol {
PA_REFCNT_DECLARE;
@@ -155,7 +152,7 @@ static int do_read(connection *c) {
ssize_t r;
size_t l;
void *p;
- size_t space;
+ size_t space = 0;
connection_assert_ref(c);
@@ -526,6 +523,7 @@ void pa_simple_protocol_connect(pa_simple_protocol *p, pa_iochannel *io, pa_simp
if (o->playback) {
pa_sink_input_new_data data;
+ pa_memchunk silence;
size_t l;
pa_sink *sink;
@@ -538,11 +536,11 @@ void pa_simple_protocol_connect(pa_simple_protocol *p, pa_iochannel *io, pa_simp
data.driver = __FILE__;
data.module = o->module;
data.client = c->client;
- data.sink = sink;
+ pa_sink_input_new_data_set_sink(&data, sink, FALSE);
pa_proplist_update(data.proplist, PA_UPDATE_MERGE, c->client->proplist);
pa_sink_input_new_data_set_sample_spec(&data, &o->sample_spec);
- pa_sink_input_new(&c->sink_input, p->core, &data, 0);
+ pa_sink_input_new(&c->sink_input, p->core, &data);
pa_sink_input_new_data_done(&data);
if (!c->sink_input) {
@@ -560,6 +558,7 @@ void pa_simple_protocol_connect(pa_simple_protocol *p, pa_iochannel *io, pa_simp
pa_sink_input_set_requested_latency(c->sink_input, DEFAULT_SINK_LATENCY);
l = (size_t) ((double) pa_bytes_per_second(&o->sample_spec)*PLAYBACK_BUFFER_SECONDS);
+ pa_sink_input_get_silence(c->sink_input, &silence);
c->input_memblockq = pa_memblockq_new(
0,
l,
@@ -568,10 +567,12 @@ void pa_simple_protocol_connect(pa_simple_protocol *p, pa_iochannel *io, pa_simp
(size_t) -1,
l/PLAYBACK_BUFFER_FRAGMENTS,
0,
- NULL);
+ &silence);
+ pa_memblock_unref(silence.memblock);
+
pa_iochannel_socket_set_rcvbuf(io, l);
- pa_atomic_store(&c->playback.missing, (int) pa_memblockq_missing(c->input_memblockq));
+ pa_atomic_store(&c->playback.missing, (int) pa_memblockq_pop_missing(c->input_memblockq));
pa_sink_input_put(c->sink_input);
}
@@ -590,11 +591,11 @@ void pa_simple_protocol_connect(pa_simple_protocol *p, pa_iochannel *io, pa_simp
data.driver = __FILE__;
data.module = o->module;
data.client = c->client;
- data.source = source;
+ pa_source_output_new_data_set_source(&data, source, FALSE);
pa_proplist_update(data.proplist, PA_UPDATE_MERGE, c->client->proplist);
pa_source_output_new_data_set_sample_spec(&data, &o->sample_spec);
- pa_source_output_new(&c->source_output, p->core, &data, 0);
+ pa_source_output_new(&c->source_output, p->core, &data);
pa_source_output_new_data_done(&data);
if (!c->source_output) {
@@ -628,8 +629,7 @@ void pa_simple_protocol_connect(pa_simple_protocol *p, pa_iochannel *io, pa_simp
return;
fail:
- if (c)
- connection_unlink(c);
+ connection_unlink(c);
}
void pa_simple_protocol_disconnect(pa_simple_protocol *p, pa_module *m) {
diff --git a/src/pulsecore/pstream.c b/src/pulsecore/pstream.c
index ef1105ba..3e59fc45 100644
--- a/src/pulsecore/pstream.c
+++ b/src/pulsecore/pstream.c
@@ -28,20 +28,13 @@
#include <stdlib.h>
#include <unistd.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#ifdef HAVE_SYS_UN_H
-#include <sys/un.h>
-#endif
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
-
#include <pulse/xmalloc.h>
-#include <pulsecore/winsock.h>
+#include <pulsecore/socket.h>
#include <pulsecore/queue.h>
#include <pulsecore/log.h>
#include <pulsecore/core-scache.h>
@@ -684,7 +677,7 @@ static int do_read(pa_pstream *p) {
flags = ntohl(p->read.descriptor[PA_PSTREAM_DESCRIPTOR_FLAGS]);
if (!p->use_shm && (flags & PA_FLAG_SHMMASK) != 0) {
- pa_log_warn("Recieved SHM frame on a socket where SHM is disabled.");
+ pa_log_warn("Received SHM frame on a socket where SHM is disabled.");
return -1;
}
@@ -714,7 +707,7 @@ static int do_read(pa_pstream *p) {
length = ntohl(p->read.descriptor[PA_PSTREAM_DESCRIPTOR_LENGTH]);
if (length > FRAME_SIZE_MAX_ALLOW || length <= 0) {
- pa_log_warn("Recieved invalid frame size: %lu", (unsigned long) length);
+ pa_log_warn("Received invalid frame size: %lu", (unsigned long) length);
return -1;
}
@@ -743,7 +736,7 @@ static int do_read(pa_pstream *p) {
if ((flags & PA_FLAG_SHMMASK) == PA_FLAG_SHMDATA) {
if (length != sizeof(p->read.shm_info)) {
- pa_log_warn("Recieved SHM memblock frame with Invalid frame length.");
+ pa_log_warn("Received SHM memblock frame with Invalid frame length.");
return -1;
}
@@ -758,7 +751,7 @@ static int do_read(pa_pstream *p) {
p->read.data = NULL;
} else {
- pa_log_warn("Recieved memblock frame with invalid flags value.");
+ pa_log_warn("Received memblock frame with invalid flags value.");
return -1;
}
}
@@ -832,7 +825,7 @@ static int do_read(pa_pstream *p) {
ntohl(p->read.shm_info[PA_PSTREAM_SHM_INDEX]),
ntohl(p->read.shm_info[PA_PSTREAM_SHM_LENGTH])))) {
- if (pa_log_ratelimit())
+ if (pa_log_ratelimit(PA_LOG_DEBUG))
pa_log_debug("Failed to import memory block.");
}
diff --git a/src/pulsecore/random.c b/src/pulsecore/random.c
index 518c281a..b2ec19f0 100644
--- a/src/pulsecore/random.c
+++ b/src/pulsecore/random.c
@@ -27,26 +27,40 @@
#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
-#include <string.h>
#include <stdlib.h>
#include <time.h>
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#include <wincrypt.h>
+#endif
+
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include "random.h"
-static pa_bool_t has_whined = TRUE;
+static pa_bool_t has_whined = FALSE;
static const char * const devices[] = { "/dev/urandom", "/dev/random", NULL };
static int random_proper(void *ret_data, size_t length) {
#ifdef OS_IS_WIN32
+ int ret = -1;
+
+ HCRYPTPROV hCryptProv = 0;
+
pa_assert(ret_data);
pa_assert(length > 0);
- return -1;
+ if (CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_VERIFYCONTEXT | CRYPT_SILENT)) {
+ if(CryptGenRandom(hCryptProv, length, ret_data))
+ ret = 0;
+ CryptReleaseContext(hCryptProv, 0);
+ }
+
+ return ret;
#else /* OS_IS_WIN32 */
@@ -62,11 +76,7 @@ static int random_proper(void *ret_data, size_t length) {
while (*device) {
ret = 0;
- if ((fd = open(*device, O_RDONLY
-#ifdef O_NOCTTY
- | O_NOCTTY
-#endif
- )) >= 0) {
+ if ((fd = pa_open_cloexec(*device, O_RDONLY, 0)) >= 0) {
if ((r = pa_loop_read(fd, ret_data, length, NULL)) < 0 || (size_t) r != length)
ret = -1;
diff --git a/src/pulsecore/ratelimit.c b/src/pulsecore/ratelimit.c
index e913ca19..a274d2cc 100644
--- a/src/pulsecore/ratelimit.c
+++ b/src/pulsecore/ratelimit.c
@@ -23,7 +23,8 @@
#include <config.h>
#endif
-#include <pulsecore/rtclock.h>
+#include <pulse/rtclock.h>
+
#include <pulsecore/log.h>
#include <pulsecore/mutex.h>
@@ -34,11 +35,11 @@ static pa_static_mutex mutex = PA_STATIC_MUTEX_INIT;
/* Modelled after Linux' lib/ratelimit.c by Dave Young
* <hidave.darkstar@gmail.com>, which is licensed GPLv2. */
-pa_bool_t pa_ratelimit_test(pa_ratelimit *r) {
+pa_bool_t pa_ratelimit_test(pa_ratelimit *r, pa_log_level_t t) {
pa_usec_t now;
pa_mutex *m;
- now = pa_rtclock_usec();
+ now = pa_rtclock_now();
m = pa_static_mutex_get(&mutex, FALSE, FALSE);
pa_mutex_lock(m);
@@ -51,7 +52,7 @@ pa_bool_t pa_ratelimit_test(pa_ratelimit *r) {
r->begin + r->interval < now) {
if (r->n_missed > 0)
- pa_log_warn("%u events suppressed", r->n_missed);
+ pa_logl(t, "%u events suppressed", r->n_missed);
r->begin = now;
diff --git a/src/pulsecore/ratelimit.h b/src/pulsecore/ratelimit.h
index ec3b5a38..9a36195d 100644
--- a/src/pulsecore/ratelimit.h
+++ b/src/pulsecore/ratelimit.h
@@ -23,24 +23,35 @@
***/
#include <pulse/sample.h>
+#include <pulsecore/log.h>
#include <pulsecore/macro.h>
typedef struct pa_ratelimit {
- const pa_usec_t interval;
- const unsigned burst;
+ pa_usec_t interval;
+ unsigned burst;
unsigned n_printed, n_missed;
pa_usec_t begin;
} pa_ratelimit;
#define PA_DEFINE_RATELIMIT(_name, _interval, _burst) \
pa_ratelimit _name = { \
- .interval = _interval, \
- .burst = _burst, \
+ .interval = (_interval), \
+ .burst = (_burst), \
.n_printed = 0, \
.n_missed = 0, \
.begin = 0 \
}
-pa_bool_t pa_ratelimit_test(pa_ratelimit *r);
+#define PA_INIT_RATELIMIT(v, _interval, _burst) \
+ do { \
+ pa_ratelimit *r = &(v); \
+ r->interval = (_interval); \
+ r->burst = (_burst); \
+ r->n_printed = 0; \
+ r->n_missed = 0; \
+ r->begin = 0; \
+ } while (FALSE);
+
+pa_bool_t pa_ratelimit_test(pa_ratelimit *r, pa_log_level_t t);
#endif
diff --git a/src/pulsecore/remap.c b/src/pulsecore/remap.c
new file mode 100644
index 00000000..b831f78c
--- /dev/null
+++ b/src/pulsecore/remap.c
@@ -0,0 +1,204 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <string.h>
+
+#include <pulse/sample.h>
+#include <pulsecore/log.h>
+#include <pulsecore/macro.h>
+
+#include "remap.h"
+
+static void remap_mono_to_stereo_c(pa_remap_t *m, void *dst, const void *src, unsigned n) {
+ unsigned i;
+
+ switch (*m->format) {
+ case PA_SAMPLE_FLOAT32NE:
+ {
+ float *d, *s;
+
+ d = (float *) dst;
+ s = (float *) src;
+
+ for (i = n >> 2; i; i--) {
+ d[0] = d[1] = s[0];
+ d[2] = d[3] = s[1];
+ d[4] = d[5] = s[2];
+ d[6] = d[7] = s[3];
+ s += 4;
+ d += 8;
+ }
+ for (i = n & 3; i; i--) {
+ d[0] = d[1] = s[0];
+ s++;
+ d += 2;
+ }
+ break;
+ }
+ case PA_SAMPLE_S16NE:
+ {
+ int16_t *d, *s;
+
+ d = (int16_t *) dst;
+ s = (int16_t *) src;
+
+ for (i = n >> 2; i; i--) {
+ d[0] = d[1] = s[0];
+ d[2] = d[3] = s[1];
+ d[4] = d[5] = s[2];
+ d[6] = d[7] = s[3];
+ s += 4;
+ d += 8;
+ }
+ for (i = n & 3; i; i--) {
+ d[0] = d[1] = s[0];
+ s++;
+ d += 2;
+ }
+ break;
+ }
+ default:
+ pa_assert_not_reached();
+ }
+}
+
+static void remap_channels_matrix_c(pa_remap_t *m, void *dst, const void *src, unsigned n) {
+ unsigned oc, ic, i;
+ unsigned n_ic, n_oc;
+
+ n_ic = m->i_ss->channels;
+ n_oc = m->o_ss->channels;
+
+ switch (*m->format) {
+ case PA_SAMPLE_FLOAT32NE:
+ {
+ float *d, *s;
+
+ memset(dst, 0, n * sizeof(float) * n_oc);
+
+ for (oc = 0; oc < n_oc; oc++) {
+
+ for (ic = 0; ic < n_ic; ic++) {
+ float vol;
+
+ vol = m->map_table_f[oc][ic];
+
+ if (vol <= 0.0)
+ continue;
+
+ d = (float *)dst + oc;
+ s = (float *)src + ic;
+
+ if (vol >= 1.0) {
+ for (i = n; i > 0; i--, s += n_ic, d += n_oc)
+ *d += *s;
+ } else {
+ for (i = n; i > 0; i--, s += n_ic, d += n_oc)
+ *d += *s * vol;
+ }
+ }
+ }
+
+ break;
+ }
+ case PA_SAMPLE_S16NE:
+ {
+ int16_t *d, *s;
+
+ memset(dst, 0, n * sizeof(int16_t) * n_oc);
+
+ for (oc = 0; oc < n_oc; oc++) {
+
+ for (ic = 0; ic < n_ic; ic++) {
+ int32_t vol;
+
+ vol = m->map_table_i[oc][ic];
+
+ if (vol <= 0)
+ continue;
+
+ d = (int16_t *)dst + oc;
+ s = (int16_t *)src + ic;
+
+ if (vol >= 0x10000) {
+ for (i = n; i > 0; i--, s += n_ic, d += n_oc)
+ *d += *s;
+ } else {
+ for (i = n; i > 0; i--, s += n_ic, d += n_oc)
+ *d += (int16_t) (((int32_t)*s * vol) >> 16);
+ }
+ }
+ }
+ break;
+ }
+ default:
+ pa_assert_not_reached();
+ }
+}
+
+/* set the function that will execute the remapping based on the matrices */
+static void init_remap_c(pa_remap_t *m) {
+ unsigned n_oc, n_ic;
+
+ n_oc = m->o_ss->channels;
+ n_ic = m->i_ss->channels;
+
+ /* find some common channel remappings, fall back to full matrix operation. */
+ if (n_ic == 1 && n_oc == 2 &&
+ m->map_table_f[0][0] >= 1.0 && m->map_table_f[1][0] >= 1.0) {
+ m->do_remap = (pa_do_remap_func_t) remap_mono_to_stereo_c;
+ pa_log_info("Using mono to stereo remapping");
+ } else {
+ m->do_remap = (pa_do_remap_func_t) remap_channels_matrix_c;
+ pa_log_info("Using generic matrix remapping");
+ }
+}
+
+
+/* default C implementation */
+static pa_init_remap_func_t remap_func = init_remap_c;
+
+void pa_init_remap(pa_remap_t *m) {
+ pa_assert(remap_func);
+
+ m->do_remap = NULL;
+
+ /* call the installed remap init function */
+ remap_func(m);
+
+ if (m->do_remap == NULL) {
+ /* nothing was installed, fallback to C version */
+ init_remap_c(m);
+ }
+}
+
+pa_init_remap_func_t pa_get_init_remap_func(void) {
+ return remap_func;
+}
+
+void pa_set_init_remap_func(pa_init_remap_func_t func) {
+ remap_func = func;
+}
diff --git a/src/pulsecore/remap.h b/src/pulsecore/remap.h
new file mode 100644
index 00000000..32a67cdd
--- /dev/null
+++ b/src/pulsecore/remap.h
@@ -0,0 +1,48 @@
+#ifndef fooremapfoo
+#define fooremapfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <pulse/sample.h>
+
+typedef struct pa_remap pa_remap_t;
+
+typedef void (*pa_do_remap_func_t) (pa_remap_t *m, void *d, const void *s, unsigned n);
+
+struct pa_remap {
+ pa_sample_format_t *format;
+ pa_sample_spec *i_ss, *o_ss;
+ float map_table_f[PA_CHANNELS_MAX][PA_CHANNELS_MAX];
+ int32_t map_table_i[PA_CHANNELS_MAX][PA_CHANNELS_MAX];
+ pa_do_remap_func_t do_remap;
+};
+
+void pa_init_remap (pa_remap_t *m);
+
+/* custom installation of init functions */
+typedef void (*pa_init_remap_func_t) (pa_remap_t *m);
+
+pa_init_remap_func_t pa_get_init_remap_func(void);
+void pa_set_init_remap_func(pa_init_remap_func_t func);
+
+#endif /* fooremapfoo */
diff --git a/src/pulsecore/remap_mmx.c b/src/pulsecore/remap_mmx.c
new file mode 100644
index 00000000..9a69ada4
--- /dev/null
+++ b/src/pulsecore/remap_mmx.c
@@ -0,0 +1,159 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/sample.h>
+#include <pulsecore/log.h>
+#include <pulsecore/macro.h>
+
+#include "cpu-x86.h"
+#include "remap.h"
+
+#define LOAD_SAMPLES \
+ " movq (%1), %%mm0 \n\t" \
+ " movq 8(%1), %%mm2 \n\t" \
+ " movq 16(%1), %%mm4 \n\t" \
+ " movq 24(%1), %%mm6 \n\t" \
+ " movq %%mm0, %%mm1 \n\t" \
+ " movq %%mm2, %%mm3 \n\t" \
+ " movq %%mm4, %%mm5 \n\t" \
+ " movq %%mm6, %%mm7 \n\t"
+
+#define UNPACK_SAMPLES(s) \
+ " punpckl"#s" %%mm0, %%mm0 \n\t" \
+ " punpckh"#s" %%mm1, %%mm1 \n\t" \
+ " punpckl"#s" %%mm2, %%mm2 \n\t" \
+ " punpckh"#s" %%mm3, %%mm3 \n\t" \
+ " punpckl"#s" %%mm4, %%mm4 \n\t" \
+ " punpckh"#s" %%mm5, %%mm5 \n\t" \
+ " punpckl"#s" %%mm6, %%mm6 \n\t" \
+ " punpckh"#s" %%mm7, %%mm7 \n\t"
+
+#define STORE_SAMPLES \
+ " movq %%mm0, (%0) \n\t" \
+ " movq %%mm1, 8(%0) \n\t" \
+ " movq %%mm2, 16(%0) \n\t" \
+ " movq %%mm3, 24(%0) \n\t" \
+ " movq %%mm4, 32(%0) \n\t" \
+ " movq %%mm5, 40(%0) \n\t" \
+ " movq %%mm6, 48(%0) \n\t" \
+ " movq %%mm7, 56(%0) \n\t" \
+ " add $32, %1 \n\t" \
+ " add $64, %0 \n\t"
+
+#define HANDLE_SINGLE_dq() \
+ " movd (%1), %%mm0 \n\t" \
+ " punpckldq %%mm0, %%mm0 \n\t" \
+ " movq %%mm0, (%0) \n\t" \
+ " add $4, %1 \n\t" \
+ " add $8, %0 \n\t"
+
+#define HANDLE_SINGLE_wd() \
+ " movw (%1), %w3 \n\t" \
+ " movd %3, %%mm0 \n\t" \
+ " punpcklwd %%mm0, %%mm0 \n\t" \
+ " movd %%mm0, (%0) \n\t" \
+ " add $2, %1 \n\t" \
+ " add $4, %0 \n\t"
+
+#define MONO_TO_STEREO(s,shift,mask) \
+ " mov %4, %2 \n\t" \
+ " sar $"#shift", %2 \n\t" \
+ " cmp $0, %2 \n\t" \
+ " je 2f \n\t" \
+ "1: \n\t" \
+ LOAD_SAMPLES \
+ UNPACK_SAMPLES(s) \
+ STORE_SAMPLES \
+ " dec %2 \n\t" \
+ " jne 1b \n\t" \
+ "2: \n\t" \
+ " mov %4, %2 \n\t" \
+ " and $"#mask", %2 \n\t" \
+ " je 4f \n\t" \
+ "3: \n\t" \
+ HANDLE_SINGLE_##s() \
+ " dec %2 \n\t" \
+ " jne 3b \n\t" \
+ "4: \n\t" \
+ " emms \n\t"
+
+#if defined (__i386__) || defined (__amd64__)
+static void remap_mono_to_stereo_mmx(pa_remap_t *m, void *dst, const void *src, unsigned n) {
+ pa_reg_x86 temp, temp2;
+
+ switch (*m->format) {
+ case PA_SAMPLE_FLOAT32NE:
+ {
+ __asm__ __volatile__ (
+ MONO_TO_STEREO(dq,3,7) /* do doubles to quads */
+ : "+r" (dst), "+r" (src), "=&r" (temp), "=&r" (temp2)
+ : "r" ((pa_reg_x86)n)
+ : "cc"
+ );
+ break;
+ }
+ case PA_SAMPLE_S16NE:
+ {
+ __asm__ __volatile__ (
+ MONO_TO_STEREO(wd,4,15) /* do words to doubles */
+ : "+r" (dst), "+r" (src), "=&r" (temp), "=&r" (temp2)
+ : "r" ((pa_reg_x86)n)
+ : "cc"
+ );
+ break;
+ }
+ default:
+ pa_assert_not_reached();
+ }
+}
+
+/* set the function that will execute the remapping based on the matrices */
+static void init_remap_mmx(pa_remap_t *m) {
+ unsigned n_oc, n_ic;
+
+ n_oc = m->o_ss->channels;
+ n_ic = m->i_ss->channels;
+
+ /* find some common channel remappings, fall back to full matrix operation. */
+ if (n_ic == 1 && n_oc == 2 &&
+ m->map_table_f[0][0] >= 1.0 && m->map_table_f[1][0] >= 1.0) {
+ m->do_remap = (pa_do_remap_func_t) remap_mono_to_stereo_mmx;
+ pa_log_info("Using MMX mono to stereo remapping");
+ }
+}
+#endif /* defined (__i386__) || defined (__amd64__) */
+
+void pa_remap_func_init_mmx(pa_cpu_x86_flag_t flags) {
+#if defined (__i386__) || defined (__amd64__)
+
+ if (flags & PA_CPU_X86_MMX) {
+ pa_log_info("Initialising MMX optimized remappers.");
+
+ pa_set_init_remap_func((pa_init_remap_func_t) init_remap_mmx);
+ }
+
+#endif /* defined (__i386__) || defined (__amd64__) */
+}
diff --git a/src/pulsecore/remap_sse.c b/src/pulsecore/remap_sse.c
new file mode 100644
index 00000000..8344a275
--- /dev/null
+++ b/src/pulsecore/remap_sse.c
@@ -0,0 +1,157 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk.com>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/sample.h>
+#include <pulsecore/log.h>
+#include <pulsecore/macro.h>
+
+#include "cpu-x86.h"
+#include "remap.h"
+
+#define LOAD_SAMPLES \
+ " movdqu (%1), %%xmm0 \n\t" \
+ " movdqu 16(%1), %%xmm2 \n\t" \
+ " movdqu 32(%1), %%xmm4 \n\t" \
+ " movdqu 48(%1), %%xmm6 \n\t" \
+ " movdqa %%xmm0, %%xmm1 \n\t" \
+ " movdqa %%xmm2, %%xmm3 \n\t" \
+ " movdqa %%xmm4, %%xmm5 \n\t" \
+ " movdqa %%xmm6, %%xmm7 \n\t"
+
+#define UNPACK_SAMPLES(s) \
+ " punpckl"#s" %%xmm0, %%xmm0 \n\t" \
+ " punpckh"#s" %%xmm1, %%xmm1 \n\t" \
+ " punpckl"#s" %%xmm2, %%xmm2 \n\t" \
+ " punpckh"#s" %%xmm3, %%xmm3 \n\t" \
+ " punpckl"#s" %%xmm4, %%xmm4 \n\t" \
+ " punpckh"#s" %%xmm5, %%xmm5 \n\t" \
+ " punpckl"#s" %%xmm6, %%xmm6 \n\t" \
+ " punpckh"#s" %%xmm7, %%xmm7 \n\t"
+
+#define STORE_SAMPLES \
+ " movdqu %%xmm0, (%0) \n\t" \
+ " movdqu %%xmm1, 16(%0) \n\t" \
+ " movdqu %%xmm2, 32(%0) \n\t" \
+ " movdqu %%xmm3, 48(%0) \n\t" \
+ " movdqu %%xmm4, 64(%0) \n\t" \
+ " movdqu %%xmm5, 80(%0) \n\t" \
+ " movdqu %%xmm6, 96(%0) \n\t" \
+ " movdqu %%xmm7, 112(%0) \n\t" \
+ " add $64, %1 \n\t" \
+ " add $128, %0 \n\t"
+
+#define HANDLE_SINGLE_dq() \
+ " movd (%1), %%xmm0 \n\t" \
+ " punpckldq %%xmm0, %%xmm0 \n\t" \
+ " movq %%xmm0, (%0) \n\t" \
+ " add $4, %1 \n\t" \
+ " add $8, %0 \n\t"
+
+#define HANDLE_SINGLE_wd() \
+ " movw (%1), %w3 \n\t" \
+ " movd %3, %%xmm0 \n\t" \
+ " punpcklwd %%xmm0, %%xmm0 \n\t" \
+ " movd %%xmm0, (%0) \n\t" \
+ " add $2, %1 \n\t" \
+ " add $4, %0 \n\t"
+
+#define MONO_TO_STEREO(s,shift,mask) \
+ " mov %4, %2 \n\t" \
+ " sar $"#shift", %2 \n\t" \
+ " cmp $0, %2 \n\t" \
+ " je 2f \n\t" \
+ "1: \n\t" \
+ LOAD_SAMPLES \
+ UNPACK_SAMPLES(s) \
+ STORE_SAMPLES \
+ " dec %2 \n\t" \
+ " jne 1b \n\t" \
+ "2: \n\t" \
+ " mov %4, %2 \n\t" \
+ " and $"#mask", %2 \n\t" \
+ " je 4f \n\t" \
+ "3: \n\t" \
+ HANDLE_SINGLE_##s() \
+ " dec %2 \n\t" \
+ " jne 3b \n\t" \
+ "4: \n\t"
+
+#if defined (__i386__) || defined (__amd64__)
+static void remap_mono_to_stereo_sse2(pa_remap_t *m, void *dst, const void *src, unsigned n) {
+ pa_reg_x86 temp, temp2;
+
+ switch (*m->format) {
+ case PA_SAMPLE_FLOAT32NE:
+ {
+ __asm__ __volatile__ (
+ MONO_TO_STEREO(dq, 4, 15) /* do doubles to quads */
+ : "+r" (dst), "+r" (src), "=&r" (temp), "=&r" (temp2)
+ : "r" ((pa_reg_x86)n)
+ : "cc"
+ );
+ break;
+ }
+ case PA_SAMPLE_S16NE:
+ {
+ __asm__ __volatile__ (
+ MONO_TO_STEREO(wd, 5, 31) /* do words to doubles */
+ : "+r" (dst), "+r" (src), "=&r" (temp), "=&r" (temp2)
+ : "r" ((pa_reg_x86)n)
+ : "cc"
+ );
+ break;
+ }
+ default:
+ pa_assert_not_reached();
+ }
+}
+
+/* set the function that will execute the remapping based on the matrices */
+static void init_remap_sse2(pa_remap_t *m) {
+ unsigned n_oc, n_ic;
+
+ n_oc = m->o_ss->channels;
+ n_ic = m->i_ss->channels;
+
+ /* find some common channel remappings, fall back to full matrix operation. */
+ if (n_ic == 1 && n_oc == 2 &&
+ m->map_table_f[0][0] >= 1.0 && m->map_table_f[1][0] >= 1.0) {
+ m->do_remap = (pa_do_remap_func_t) remap_mono_to_stereo_sse2;
+ pa_log_info("Using SSE mono to stereo remapping");
+ }
+}
+#endif /* defined (__i386__) || defined (__amd64__) */
+
+void pa_remap_func_init_sse(pa_cpu_x86_flag_t flags) {
+#if defined (__i386__) || defined (__amd64__)
+
+ if (flags & PA_CPU_X86_SSE2) {
+ pa_log_info("Initialising SSE2 optimized remappers.");
+ pa_set_init_remap_func ((pa_init_remap_func_t) init_remap_sse2);
+ }
+
+#endif /* defined (__i386__) || defined (__amd64__) */
+}
diff --git a/src/pulsecore/resampler.c b/src/pulsecore/resampler.c
index 17fb8480..b5c1611c 100644
--- a/src/pulsecore/resampler.c
+++ b/src/pulsecore/resampler.c
@@ -31,14 +31,12 @@
#include <speex/speex_resampler.h>
-#include <liboil/liboilfuncs.h>
-#include <liboil/liboil.h>
-
#include <pulse/xmalloc.h>
#include <pulsecore/sconv.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/strbuf.h>
+#include <pulsecore/remap.h>
#include "ffmpeg/avcodec.h"
@@ -64,7 +62,7 @@ struct pa_resampler {
pa_convert_func_t to_work_format_func;
pa_convert_func_t from_work_format_func;
- float map_table[PA_CHANNELS_MAX][PA_CHANNELS_MAX];
+ pa_remap_t remap;
pa_bool_t map_required;
void (*impl_free)(pa_resampler *r);
@@ -214,6 +212,11 @@ pa_resampler* pa_resampler_new(
r->i_ss = *a;
r->o_ss = *b;
+ /* set up the remap structure */
+ r->remap.i_ss = &r->i_ss;
+ r->remap.o_ss = &r->o_ss;
+ r->remap.format = &r->work_format;
+
if (am)
r->i_cm = *am;
else if (!pa_channel_map_init_auto(&r->i_cm, r->i_ss.channels, PA_CHANNEL_MAP_DEFAULT))
@@ -296,8 +299,7 @@ pa_resampler* pa_resampler_new(
return r;
fail:
- if (r)
- pa_xfree(r);
+ pa_xfree(r);
return NULL;
}
@@ -347,13 +349,17 @@ void pa_resampler_set_output_rate(pa_resampler *r, uint32_t rate) {
size_t pa_resampler_request(pa_resampler *r, size_t out_length) {
pa_assert(r);
- return (((out_length / r->o_fz)*r->i_ss.rate)/r->o_ss.rate) * r->i_fz;
+ /* Let's round up here */
+
+ return (((((out_length + r->o_fz-1) / r->o_fz) * r->i_ss.rate) + r->o_ss.rate-1) / r->o_ss.rate) * r->i_fz;
}
size_t pa_resampler_result(pa_resampler *r, size_t in_length) {
pa_assert(r);
- return (((in_length / r->i_fz)*r->o_ss.rate)/r->i_ss.rate) * r->o_fz;
+ /* Let's round up here */
+
+ return (((((in_length + r->i_fz-1) / r->i_fz) * r->o_ss.rate) + r->i_ss.rate-1) / r->i_ss.rate) * r->o_fz;
}
size_t pa_resampler_max_block_size(pa_resampler *r) {
@@ -576,32 +582,41 @@ static int front_rear_side(pa_channel_position_t p) {
static void calc_map_table(pa_resampler *r) {
unsigned oc, ic;
+ unsigned n_oc, n_ic;
pa_bool_t ic_connected[PA_CHANNELS_MAX];
pa_bool_t remix;
pa_strbuf *s;
char *t;
+ pa_remap_t *m;
pa_assert(r);
if (!(r->map_required = (r->i_ss.channels != r->o_ss.channels || (!(r->flags & PA_RESAMPLER_NO_REMAP) && !pa_channel_map_equal(&r->i_cm, &r->o_cm)))))
return;
- memset(r->map_table, 0, sizeof(r->map_table));
+ m = &r->remap;
+
+ n_oc = r->o_ss.channels;
+ n_ic = r->i_ss.channels;
+
+ memset(m->map_table_f, 0, sizeof(m->map_table_f));
+ memset(m->map_table_i, 0, sizeof(m->map_table_i));
+
memset(ic_connected, 0, sizeof(ic_connected));
remix = (r->flags & (PA_RESAMPLER_NO_REMAP|PA_RESAMPLER_NO_REMIX)) == 0;
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
pa_bool_t oc_connected = FALSE;
pa_channel_position_t b = r->o_cm.map[oc];
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
pa_channel_position_t a = r->i_cm.map[ic];
if (r->flags & PA_RESAMPLER_NO_REMAP) {
/* We shall not do any remapping. Hence, just check by index */
if (ic == oc)
- r->map_table[oc][ic] = 1.0;
+ m->map_table_f[oc][ic] = 1.0;
continue;
}
@@ -610,7 +625,7 @@ static void calc_map_table(pa_resampler *r) {
/* We shall not do any remixing. Hence, just check by name */
if (a == b)
- r->map_table[oc][ic] = 1.0;
+ m->map_table_f[oc][ic] = 1.0;
continue;
}
@@ -685,7 +700,7 @@ static void calc_map_table(pa_resampler *r) {
*/
if (a == b || a == PA_CHANNEL_POSITION_MONO || b == PA_CHANNEL_POSITION_MONO) {
- r->map_table[oc][ic] = 1.0;
+ m->map_table_f[oc][ic] = 1.0;
oc_connected = TRUE;
ic_connected[ic] = TRUE;
@@ -703,14 +718,14 @@ static void calc_map_table(pa_resampler *r) {
/* We are not connected and on the left side, let's
* average all left side input channels. */
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_left(r->i_cm.map[ic]))
n++;
if (n > 0)
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_left(r->i_cm.map[ic])) {
- r->map_table[oc][ic] = 1.0f / (float) n;
+ m->map_table_f[oc][ic] = 1.0f / (float) n;
ic_connected[ic] = TRUE;
}
@@ -724,14 +739,14 @@ static void calc_map_table(pa_resampler *r) {
/* We are not connected and on the right side, let's
* average all right side input channels. */
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_right(r->i_cm.map[ic]))
n++;
if (n > 0)
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_right(r->i_cm.map[ic])) {
- r->map_table[oc][ic] = 1.0f / (float) n;
+ m->map_table_f[oc][ic] = 1.0f / (float) n;
ic_connected[ic] = TRUE;
}
@@ -745,14 +760,14 @@ static void calc_map_table(pa_resampler *r) {
/* We are not connected and at the center. Let's
* average all center input channels. */
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_center(r->i_cm.map[ic]))
n++;
if (n > 0) {
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_center(r->i_cm.map[ic])) {
- r->map_table[oc][ic] = 1.0f / (float) n;
+ m->map_table_f[oc][ic] = 1.0f / (float) n;
ic_connected[ic] = TRUE;
}
} else {
@@ -762,14 +777,14 @@ static void calc_map_table(pa_resampler *r) {
n = 0;
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_left(r->i_cm.map[ic]) || on_right(r->i_cm.map[ic]))
n++;
if (n > 0)
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
if (on_left(r->i_cm.map[ic]) || on_right(r->i_cm.map[ic])) {
- r->map_table[oc][ic] = 1.0f / (float) n;
+ m->map_table_f[oc][ic] = 1.0f / (float) n;
ic_connected[ic] = TRUE;
}
@@ -783,12 +798,12 @@ static void calc_map_table(pa_resampler *r) {
/* We are not connected and an LFE. Let's average all
* channels for LFE. */
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
if (!(r->flags & PA_RESAMPLER_NO_LFE))
- r->map_table[oc][ic] = 1.0f / (float) r->i_ss.channels;
+ m->map_table_f[oc][ic] = 1.0f / (float) n_ic;
else
- r->map_table[oc][ic] = 0;
+ m->map_table_f[oc][ic] = 0;
/* Please note that a channel connected to LFE
* doesn't really count as connected. */
@@ -804,7 +819,7 @@ static void calc_map_table(pa_resampler *r) {
ic_unconnected_center = 0,
ic_unconnected_lfe = 0;
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
pa_channel_position_t a = r->i_cm.map[ic];
if (ic_connected[ic])
@@ -827,20 +842,20 @@ static void calc_map_table(pa_resampler *r) {
* the left side by .9 and add in our averaged unconnected
* channels multplied by .1 */
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
if (!on_left(r->o_cm.map[oc]))
continue;
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
if (ic_connected[ic]) {
- r->map_table[oc][ic] *= .9f;
+ m->map_table_f[oc][ic] *= .9f;
continue;
}
if (on_left(r->i_cm.map[ic]))
- r->map_table[oc][ic] = .1f / (float) ic_unconnected_left;
+ m->map_table_f[oc][ic] = .1f / (float) ic_unconnected_left;
}
}
}
@@ -852,20 +867,20 @@ static void calc_map_table(pa_resampler *r) {
* the right side by .9 and add in our averaged unconnected
* channels multplied by .1 */
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
if (!on_right(r->o_cm.map[oc]))
continue;
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
if (ic_connected[ic]) {
- r->map_table[oc][ic] *= .9f;
+ m->map_table_f[oc][ic] *= .9f;
continue;
}
if (on_right(r->i_cm.map[ic]))
- r->map_table[oc][ic] = .1f / (float) ic_unconnected_right;
+ m->map_table_f[oc][ic] = .1f / (float) ic_unconnected_right;
}
}
}
@@ -878,20 +893,20 @@ static void calc_map_table(pa_resampler *r) {
* the center side by .9 and add in our averaged unconnected
* channels multplied by .1 */
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
if (!on_center(r->o_cm.map[oc]))
continue;
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
if (ic_connected[ic]) {
- r->map_table[oc][ic] *= .9f;
+ m->map_table_f[oc][ic] *= .9f;
continue;
}
if (on_center(r->i_cm.map[ic])) {
- r->map_table[oc][ic] = .1f / (float) ic_unconnected_center;
+ m->map_table_f[oc][ic] = .1f / (float) ic_unconnected_center;
mixed_in = TRUE;
}
}
@@ -909,7 +924,7 @@ static void calc_map_table(pa_resampler *r) {
it into left and right. Using .375 and 0.75 as
factors. */
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
if (ic_connected[ic])
continue;
@@ -917,7 +932,7 @@ static void calc_map_table(pa_resampler *r) {
if (!on_center(r->i_cm.map[ic]))
continue;
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
if (!on_left(r->o_cm.map[oc]) && !on_right(r->o_cm.map[oc]))
continue;
@@ -928,7 +943,7 @@ static void calc_map_table(pa_resampler *r) {
}
}
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
if (!on_left(r->o_cm.map[oc]) && !on_right(r->o_cm.map[oc]))
continue;
@@ -938,7 +953,7 @@ static void calc_map_table(pa_resampler *r) {
}
}
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
if (!on_left(r->o_cm.map[oc]) && !on_right(r->o_cm.map[oc]))
continue;
@@ -946,10 +961,10 @@ static void calc_map_table(pa_resampler *r) {
if (ncenter[oc] <= 0)
continue;
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
if (ic_connected[ic]) {
- r->map_table[oc][ic] *= .75f;
+ m->map_table_f[oc][ic] *= .75f;
continue;
}
@@ -957,7 +972,7 @@ static void calc_map_table(pa_resampler *r) {
continue;
if (!found_frs[ic] || front_rear_side(r->i_cm.map[ic]) == front_rear_side(r->o_cm.map[oc]))
- r->map_table[oc][ic] = .375f / (float) ncenter[oc];
+ m->map_table_f[oc][ic] = .375f / (float) ncenter[oc];
}
}
}
@@ -968,40 +983,46 @@ static void calc_map_table(pa_resampler *r) {
/* OK, so there is an unconnected LFE channel. Let's mix
* it into all channels, with factor 0.375 */
- for (ic = 0; ic < r->i_ss.channels; ic++) {
+ for (ic = 0; ic < n_ic; ic++) {
if (!on_lfe(r->i_cm.map[ic]))
continue;
- for (oc = 0; oc < r->o_ss.channels; oc++)
- r->map_table[oc][ic] = 0.375f / (float) ic_unconnected_lfe;
+ for (oc = 0; oc < n_oc; oc++)
+ m->map_table_f[oc][ic] = 0.375f / (float) ic_unconnected_lfe;
}
}
}
-
+ /* make an 16:16 int version of the matrix */
+ for (oc = 0; oc < n_oc; oc++)
+ for (ic = 0; ic < n_ic; ic++)
+ m->map_table_i[oc][ic] = (int32_t) (m->map_table_f[oc][ic] * 0x10000);
s = pa_strbuf_new();
pa_strbuf_printf(s, " ");
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
pa_strbuf_printf(s, " I%02u ", ic);
pa_strbuf_puts(s, "\n +");
- for (ic = 0; ic < r->i_ss.channels; ic++)
+ for (ic = 0; ic < n_ic; ic++)
pa_strbuf_printf(s, "------");
pa_strbuf_puts(s, "\n");
- for (oc = 0; oc < r->o_ss.channels; oc++) {
+ for (oc = 0; oc < n_oc; oc++) {
pa_strbuf_printf(s, "O%02u |", oc);
- for (ic = 0; ic < r->i_ss.channels; ic++)
- pa_strbuf_printf(s, " %1.3f", r->map_table[oc][ic]);
+ for (ic = 0; ic < n_ic; ic++)
+ pa_strbuf_printf(s, " %1.3f", m->map_table_f[oc][ic]);
pa_strbuf_puts(s, "\n");
}
pa_log_debug("Channel matrix:\n%s", t = pa_strbuf_tostring_free(s));
pa_xfree(t);
+
+ /* initialize the remapping function */
+ pa_init_remap(m);
}
static pa_memchunk* convert_to_work_format(pa_resampler *r, pa_memchunk *input) {
@@ -1041,41 +1062,10 @@ static pa_memchunk* convert_to_work_format(pa_resampler *r, pa_memchunk *input)
return &r->buf1;
}
-static void vectoradd_s16_with_fraction(
- int16_t *d, int dstr,
- const int16_t *s1, int sstr1,
- const int16_t *s2, int sstr2,
- int n,
- float s3, float s4) {
-
- int32_t i3, i4;
-
- i3 = (int32_t) (s3 * 0x10000);
- i4 = (int32_t) (s4 * 0x10000);
-
- for (; n > 0; n--) {
- int32_t a, b;
-
- a = *s1;
- b = *s2;
-
- a = (a * i3) / 0x10000;
- b = (b * i4) / 0x10000;
-
- *d = (int16_t) (a + b);
-
- s1 = (const int16_t*) ((const uint8_t*) s1 + sstr1);
- s2 = (const int16_t*) ((const uint8_t*) s2 + sstr2);
- d = (int16_t*) ((uint8_t*) d + dstr);
-
- }
-}
-
static pa_memchunk *remap_channels(pa_resampler *r, pa_memchunk *input) {
unsigned in_n_samples, out_n_samples, n_frames;
- int i_skip, o_skip;
- unsigned oc;
void *src, *dst;
+ pa_remap_t *remap;
pa_assert(r);
pa_assert(input);
@@ -1104,76 +1094,14 @@ static pa_memchunk *remap_channels(pa_resampler *r, pa_memchunk *input) {
src = ((uint8_t*) pa_memblock_acquire(input->memblock) + input->index);
dst = pa_memblock_acquire(r->buf2.memblock);
- memset(dst, 0, r->buf2.length);
-
- o_skip = (int) (r->w_sz * r->o_ss.channels);
- i_skip = (int) (r->w_sz * r->i_ss.channels);
-
- switch (r->work_format) {
- case PA_SAMPLE_FLOAT32NE:
-
- for (oc = 0; oc < r->o_ss.channels; oc++) {
- unsigned ic;
- static const float one = 1.0;
+ remap = &r->remap;
- for (ic = 0; ic < r->i_ss.channels; ic++) {
-
- if (r->map_table[oc][ic] <= 0.0)
- continue;
-
- oil_vectoradd_f32(
- (float*) dst + oc, o_skip,
- (float*) dst + oc, o_skip,
- (float*) src + ic, i_skip,
- (int) n_frames,
- &one, &r->map_table[oc][ic]);
- }
- }
-
- break;
-
- case PA_SAMPLE_S16NE:
-
- for (oc = 0; oc < r->o_ss.channels; oc++) {
- unsigned ic;
-
- for (ic = 0; ic < r->i_ss.channels; ic++) {
-
- if (r->map_table[oc][ic] <= 0.0)
- continue;
-
- if (r->map_table[oc][ic] >= 1.0) {
- static const int16_t one = 1;
-
- oil_vectoradd_s16(
- (int16_t*) dst + oc, o_skip,
- (int16_t*) dst + oc, o_skip,
- (int16_t*) src + ic, i_skip,
- (int) n_frames,
- &one, &one);
-
- } else
-
- vectoradd_s16_with_fraction(
- (int16_t*) dst + oc, o_skip,
- (int16_t*) dst + oc, o_skip,
- (int16_t*) src + ic, i_skip,
- (int) n_frames,
- 1.0f, r->map_table[oc][ic]);
- }
- }
-
- break;
-
- default:
- pa_assert_not_reached();
- }
+ pa_assert(remap->do_remap);
+ remap->do_remap(remap, dst, src, n_frames);
pa_memblock_release(input->memblock);
pa_memblock_release(r->buf2.memblock);
- r->buf2.length = out_n_samples * r->w_sz;
-
return &r->buf2;
}
@@ -1465,7 +1393,7 @@ static void trivial_resample(pa_resampler *r, const pa_memchunk *input, unsigned
pa_assert(o_index * fz < pa_memblock_get_length(output->memblock));
- oil_memcpy((uint8_t*) dst + fz * o_index,
+ memcpy((uint8_t*) dst + fz * o_index,
(uint8_t*) src + fz * j, (int) fz);
}
diff --git a/src/pulsecore/rtkit.c b/src/pulsecore/rtkit.c
new file mode 100644
index 00000000..aecc4e32
--- /dev/null
+++ b/src/pulsecore/rtkit.c
@@ -0,0 +1,189 @@
+/*-*- Mode: C; c-basic-offset: 8 -*-*/
+
+/***
+ Copyright 2009 Lennart Poettering
+
+ Permission is hereby granted, free of charge, to any person
+ obtaining a copy of this software and associated documentation files
+ (the "Software"), to deal in the Software without restriction,
+ including without limitation the rights to use, copy, modify, merge,
+ publish, distribute, sublicense, and/or sell copies of the Software,
+ and to permit persons to whom the Software is furnished to do so,
+ subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be
+ included in all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+ BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ SOFTWARE.
+***/
+
+#include <errno.h>
+
+#include "rtkit.h"
+
+#ifdef __linux__
+
+#ifndef _GNU_SOURCE
+#define _GNU_SOURCE
+#endif
+
+#include <string.h>
+#include <unistd.h>
+#include <sys/types.h>
+#include <sys/syscall.h>
+
+static pid_t _gettid(void) {
+ return (pid_t) syscall(SYS_gettid);
+}
+
+static int translate_error(const char *name) {
+ if (strcmp(name, DBUS_ERROR_NO_MEMORY) == 0)
+ return -ENOMEM;
+ if (strcmp(name, DBUS_ERROR_SERVICE_UNKNOWN) == 0 ||
+ strcmp(name, DBUS_ERROR_NAME_HAS_NO_OWNER) == 0)
+ return -ENOENT;
+ if (strcmp(name, DBUS_ERROR_ACCESS_DENIED) == 0 ||
+ strcmp(name, DBUS_ERROR_AUTH_FAILED) == 0)
+ return -EACCES;
+
+ return -EIO;
+}
+
+int rtkit_make_realtime(DBusConnection *connection, pid_t thread, int priority) {
+ DBusMessage *m = NULL, *r = NULL;
+ dbus_uint64_t u64;
+ dbus_uint32_t u32;
+ DBusError error;
+ int ret;
+
+ dbus_error_init(&error);
+
+ if (thread == 0)
+ thread = _gettid();
+
+ if (!(m = dbus_message_new_method_call(
+ RTKIT_SERVICE_NAME,
+ RTKIT_OBJECT_PATH,
+ "org.freedesktop.RealtimeKit1",
+ "MakeThreadRealtime"))) {
+ ret = -ENOMEM;
+ goto finish;
+ }
+
+ u64 = (dbus_uint64_t) thread;
+ u32 = (dbus_uint32_t) priority;
+
+ if (!dbus_message_append_args(
+ m,
+ DBUS_TYPE_UINT64, &u64,
+ DBUS_TYPE_UINT32, &u32,
+ DBUS_TYPE_INVALID)) {
+ ret = -ENOMEM;
+ goto finish;
+ }
+
+ if (!(r = dbus_connection_send_with_reply_and_block(connection, m, -1, &error))) {
+ ret = translate_error(error.name);
+ goto finish;
+ }
+
+
+ if (dbus_set_error_from_message(&error, r)) {
+ ret = translate_error(error.name);
+ goto finish;
+ }
+
+ ret = 0;
+
+finish:
+
+ if (m)
+ dbus_message_unref(m);
+
+ if (r)
+ dbus_message_unref(r);
+
+ dbus_error_free(&error);
+
+ return ret;
+}
+
+int rtkit_make_high_priority(DBusConnection *connection, pid_t thread, int nice_level) {
+ DBusMessage *m = NULL, *r = NULL;
+ dbus_uint64_t u64;
+ dbus_int32_t s32;
+ DBusError error;
+ int ret;
+
+ dbus_error_init(&error);
+
+ if (thread == 0)
+ thread = _gettid();
+
+ if (!(m = dbus_message_new_method_call(
+ RTKIT_SERVICE_NAME,
+ RTKIT_OBJECT_PATH,
+ "org.freedesktop.RealtimeKit1",
+ "MakeThreadHighPriority"))) {
+ ret = -ENOMEM;
+ goto finish;
+ }
+
+ u64 = (dbus_uint64_t) thread;
+ s32 = (dbus_int32_t) nice_level;
+
+ if (!dbus_message_append_args(
+ m,
+ DBUS_TYPE_UINT64, &u64,
+ DBUS_TYPE_INT32, &s32,
+ DBUS_TYPE_INVALID)) {
+ ret = -ENOMEM;
+ goto finish;
+ }
+
+
+
+ if (!(r = dbus_connection_send_with_reply_and_block(connection, m, -1, &error))) {
+ ret = translate_error(error.name);
+ goto finish;
+ }
+
+
+ if (dbus_set_error_from_message(&error, r)) {
+ ret = translate_error(error.name);
+ goto finish;
+ }
+
+ ret = 0;
+
+finish:
+
+ if (m)
+ dbus_message_unref(m);
+
+ if (r)
+ dbus_message_unref(r);
+
+ dbus_error_free(&error);
+
+ return ret;
+}
+
+#else
+
+int rtkit_make_realtime(DBusConnection *connection, pid_t thread, int priority) {
+ return -ENOTSUP;
+}
+
+int rtkit_make_high_priority(DBusConnection *connection, pid_t thread, int nice_level) {
+ return -ENOTSUP;
+}
+
+#endif
diff --git a/src/pulsecore/rtkit.h b/src/pulsecore/rtkit.h
new file mode 100644
index 00000000..2081b4e9
--- /dev/null
+++ b/src/pulsecore/rtkit.h
@@ -0,0 +1,62 @@
+/*-*- Mode: C; c-basic-offset: 8 -*-*/
+
+#ifndef foortkithfoo
+#define foortkithfoo
+
+/***
+ Copyright 2009 Lennart Poettering
+
+ Permission is hereby granted, free of charge, to any person
+ obtaining a copy of this software and associated documentation files
+ (the "Software"), to deal in the Software without restriction,
+ including without limitation the rights to use, copy, modify, merge,
+ publish, distribute, sublicense, and/or sell copies of the Software,
+ and to permit persons to whom the Software is furnished to do so,
+ subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be
+ included in all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+ BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ SOFTWARE.
+***/
+
+#include <sys/types.h>
+#include <dbus/dbus.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/* This is the reference implementation for a client for
+ * RealtimeKit. You don't have to use this, but if do, just copy these
+ * sources into your repository */
+
+#define RTKIT_SERVICE_NAME "org.freedesktop.RealtimeKit1"
+#define RTKIT_OBJECT_PATH "/org/freedesktop/RealtimeKit1"
+
+/* This is mostly equivalent to sched_setparam(thread, SCHED_RR, {
+ * .sched_priority = priority }). 'thread' needs to be a kernel thread
+ * id as returned by gettid(), not a pthread_t! If 'thread' is 0 the
+ * current thread is used. The returned value is a negative errno
+ * style error code, or 0 on success. */
+int rtkit_make_realtime(DBusConnection *system_bus, pid_t thread, int priority);
+
+/* This is mostly equivalent to setpriority(PRIO_PROCESS, thread,
+ * nice_level). 'thread' needs to be a kernel thread id as returned by
+ * gettid(), not a pthread_t! If 'thread' is 0 the current thread is
+ * used. The returned value is a negative errno style error code, or 0
+ * on success.*/
+int rtkit_make_high_priority(DBusConnection *system_bus, pid_t thread, int nice_level);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
diff --git a/src/pulsecore/rtpoll.c b/src/pulsecore/rtpoll.c
index aa8ca321..d90c996c 100644
--- a/src/pulsecore/rtpoll.c
+++ b/src/pulsecore/rtpoll.c
@@ -26,32 +26,21 @@
#include <sys/types.h>
#include <stdio.h>
-#include <signal.h>
#include <string.h>
#include <errno.h>
-#ifdef __linux__
-#include <sys/utsname.h>
-#endif
-
-#ifdef HAVE_POLL_H
-#include <poll.h>
-#else
-#include <pulsecore/poll.h>
-#endif
-
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
+#include <pulsecore/poll.h>
#include <pulsecore/core-error.h>
-#include <pulsecore/rtclock.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/macro.h>
#include <pulsecore/llist.h>
-#include <pulsecore/rtsig.h>
#include <pulsecore/flist.h>
#include <pulsecore/core-util.h>
-#include <pulsecore/winsock.h>
#include <pulsecore/ratelimit.h>
+#include <pulse/rtclock.h>
#include "rtpoll.h"
@@ -66,19 +55,9 @@ struct pa_rtpoll {
pa_bool_t scan_for_dead:1;
pa_bool_t running:1;
- pa_bool_t installed:1;
pa_bool_t rebuild_needed:1;
pa_bool_t quit:1;
-
-#ifdef HAVE_PPOLL
- pa_bool_t timer_armed:1;
-#ifdef __linux__
- pa_bool_t dont_use_ppoll:1;
-#endif
- int rtsig;
- sigset_t sigset_unblocked;
- timer_t timer;
-#endif
+ pa_bool_t timer_elapsed:1;
#ifdef DEBUG_TIMING
pa_usec_t timestamp;
@@ -107,106 +86,22 @@ struct pa_rtpoll_item {
PA_STATIC_FLIST_DECLARE(items, 0, pa_xfree);
-static void signal_handler_noop(int s) { /* write(2, "signal\n", 7); */ }
-
pa_rtpoll *pa_rtpoll_new(void) {
pa_rtpoll *p;
- p = pa_xnew(pa_rtpoll, 1);
-
-#ifdef HAVE_PPOLL
-
-#ifdef __linux__
- /* ppoll is broken on Linux < 2.6.16 */
- p->dont_use_ppoll = FALSE;
-
- {
- struct utsname u;
- unsigned major, minor, micro;
-
- pa_assert_se(uname(&u) == 0);
-
- if (sscanf(u.release, "%u.%u.%u", &major, &minor, &micro) != 3 ||
- (major < 2) ||
- (major == 2 && minor < 6) ||
- (major == 2 && minor == 6 && micro < 16))
-
- p->dont_use_ppoll = TRUE;
- }
-
-#endif
-
- p->rtsig = -1;
- sigemptyset(&p->sigset_unblocked);
- p->timer = (timer_t) -1;
- p->timer_armed = FALSE;
-
-#endif
+ p = pa_xnew0(pa_rtpoll, 1);
p->n_pollfd_alloc = 32;
p->pollfd = pa_xnew(struct pollfd, p->n_pollfd_alloc);
p->pollfd2 = pa_xnew(struct pollfd, p->n_pollfd_alloc);
- p->n_pollfd_used = 0;
-
- memset(&p->next_elapse, 0, sizeof(p->next_elapse));
- p->timer_enabled = FALSE;
-
- p->running = FALSE;
- p->installed = FALSE;
- p->scan_for_dead = FALSE;
- p->rebuild_needed = FALSE;
- p->quit = FALSE;
-
- PA_LLIST_HEAD_INIT(pa_rtpoll_item, p->items);
#ifdef DEBUG_TIMING
- p->timestamp = pa_rtclock_usec();
- p->slept = p->awake = 0;
+ p->timestamp = pa_rtclock_now();
#endif
return p;
}
-void pa_rtpoll_install(pa_rtpoll *p) {
- pa_assert(p);
- pa_assert(!p->installed);
-
- p->installed = TRUE;
-
-#ifdef HAVE_PPOLL
-# ifdef __linux__
- if (p->dont_use_ppoll)
- return;
-# endif
-
- if ((p->rtsig = pa_rtsig_get_for_thread()) < 0) {
- pa_log_warn("Failed to reserve POSIX realtime signal.");
- return;
- }
-
- pa_log_debug("Acquired POSIX realtime signal %s", pa_sig2str(p->rtsig));
-
- {
- sigset_t ss;
- struct sigaction sa;
-
- pa_assert_se(sigemptyset(&ss) == 0);
- pa_assert_se(sigaddset(&ss, p->rtsig) == 0);
- pa_assert_se(pthread_sigmask(SIG_BLOCK, &ss, &p->sigset_unblocked) == 0);
- pa_assert_se(sigdelset(&p->sigset_unblocked, p->rtsig) == 0);
-
- memset(&sa, 0, sizeof(sa));
- sa.sa_handler = signal_handler_noop;
- pa_assert_se(sigemptyset(&sa.sa_mask) == 0);
-
- pa_assert_se(sigaction(p->rtsig, &sa, NULL) == 0);
-
- /* We never reset the signal handler. Why should we? */
- }
-
-#endif
-}
-
static void rtpoll_rebuild(pa_rtpoll *p) {
struct pollfd *e, *t;
@@ -228,7 +123,7 @@ static void rtpoll_rebuild(pa_rtpoll *p) {
for (i = p->items; i; i = i->next) {
- if (i->n_pollfd > 0) {
+ if (i->n_pollfd > 0) {
size_t l = i->n_pollfd * sizeof(struct pollfd);
if (i->pollfd)
@@ -250,7 +145,6 @@ static void rtpoll_rebuild(pa_rtpoll *p) {
if (ra)
p->pollfd2 = pa_xrealloc(p->pollfd2, p->n_pollfd_alloc * sizeof(struct pollfd));
-
}
static void rtpoll_item_destroy(pa_rtpoll_item *i) {
@@ -279,11 +173,6 @@ void pa_rtpoll_free(pa_rtpoll *p) {
pa_xfree(p->pollfd);
pa_xfree(p->pollfd2);
-#ifdef HAVE_PPOLL
- if (p->timer != (timer_t) -1)
- timer_delete(p->timer);
-#endif
-
pa_xfree(p);
}
@@ -314,16 +203,20 @@ static void reset_all_revents(pa_rtpoll *p) {
}
}
-int pa_rtpoll_run(pa_rtpoll *p, pa_bool_t wait) {
+int pa_rtpoll_run(pa_rtpoll *p, pa_bool_t wait_op) {
pa_rtpoll_item *i;
int r = 0;
struct timeval timeout;
pa_assert(p);
pa_assert(!p->running);
- pa_assert(p->installed);
+
+#ifdef DEBUG_TIMING
+ pa_log("rtpoll_run");
+#endif
p->running = TRUE;
+ p->timer_elapsed = FALSE;
/* First, let's do some work */
for (i = p->items; i && i->priority < PA_RTPOLL_NEVER; i = i->next) {
@@ -335,13 +228,19 @@ int pa_rtpoll_run(pa_rtpoll *p, pa_bool_t wait) {
if (!i->work_cb)
continue;
- if (p->quit)
+ if (p->quit) {
+#ifdef DEBUG_TIMING
+ pa_log("rtpoll finish");
+#endif
goto finish;
+ }
if ((k = i->work_cb(i)) != 0) {
if (k < 0)
r = k;
-
+#ifdef DEBUG_TIMING
+ pa_log("rtpoll finish");
+#endif
goto finish;
}
}
@@ -373,7 +272,9 @@ int pa_rtpoll_run(pa_rtpoll *p, pa_bool_t wait) {
if (k < 0)
r = k;
-
+#ifdef DEBUG_TIMING
+ pa_log("rtpoll finish");
+#endif
goto finish;
}
}
@@ -381,10 +282,10 @@ int pa_rtpoll_run(pa_rtpoll *p, pa_bool_t wait) {
if (p->rebuild_needed)
rtpoll_rebuild(p);
- memset(&timeout, 0, sizeof(timeout));
+ pa_zero(timeout);
/* Calculate timeout */
- if (wait && !p->quit && p->timer_enabled) {
+ if (wait_op && !p->quit && p->timer_enabled) {
struct timeval now;
pa_rtclock_get(&now);
@@ -394,34 +295,33 @@ int pa_rtpoll_run(pa_rtpoll *p, pa_bool_t wait) {
#ifdef DEBUG_TIMING
{
- pa_usec_t now = pa_rtclock_usec();
+ pa_usec_t now = pa_rtclock_now();
p->awake = now - p->timestamp;
p->timestamp = now;
+ if (!wait_op || p->quit || p->timer_enabled)
+ pa_log("poll timeout: %d ms ",(int) ((timeout.tv_sec*1000) + (timeout.tv_usec / 1000)));
+ else
+ pa_log("poll timeout is ZERO");
}
#endif
/* OK, now let's sleep */
#ifdef HAVE_PPOLL
-
-#ifdef __linux__
- if (!p->dont_use_ppoll)
-#endif
{
struct timespec ts;
ts.tv_sec = timeout.tv_sec;
ts.tv_nsec = timeout.tv_usec * 1000;
- r = ppoll(p->pollfd, p->n_pollfd_used, (!wait || p->quit || p->timer_enabled) ? &ts : NULL, p->rtsig < 0 ? NULL : &p->sigset_unblocked);
+ r = ppoll(p->pollfd, p->n_pollfd_used, (!wait_op || p->quit || p->timer_enabled) ? &ts : NULL, NULL);
}
-#ifdef __linux__
- else
+#else
+ r = pa_poll(p->pollfd, p->n_pollfd_used, (!wait_op || p->quit || p->timer_enabled) ? (int) ((timeout.tv_sec*1000) + (timeout.tv_usec / 1000)) : -1);
#endif
-#endif
- r = poll(p->pollfd, p->n_pollfd_used, (!wait || p->quit || p->timer_enabled) ? (int) ((timeout.tv_sec*1000) + (timeout.tv_usec / 1000)) : -1);
+ p->timer_elapsed = r == 0;
#ifdef DEBUG_TIMING
{
- pa_usec_t now = pa_rtclock_usec();
+ pa_usec_t now = pa_rtclock_now();
p->slept = now - p->timestamp;
p->timestamp = now;
@@ -472,73 +372,11 @@ finish:
return r < 0 ? r : !p->quit;
}
-static void update_timer(pa_rtpoll *p) {
- pa_assert(p);
-
-#ifdef HAVE_PPOLL
-
-#ifdef __linux__
- if (p->dont_use_ppoll)
- return;
-#endif
-
- if (p->timer == (timer_t) -1) {
- struct sigevent se;
-
- memset(&se, 0, sizeof(se));
- se.sigev_notify = SIGEV_SIGNAL;
- se.sigev_signo = p->rtsig;
-
- if (timer_create(CLOCK_MONOTONIC, &se, &p->timer) < 0)
- if (timer_create(CLOCK_REALTIME, &se, &p->timer) < 0) {
- pa_log_warn("Failed to allocate POSIX timer: %s", pa_cstrerror(errno));
- p->timer = (timer_t) -1;
- }
- }
-
- if (p->timer != (timer_t) -1) {
- struct itimerspec its;
- struct timespec ts = { .tv_sec = 0, .tv_nsec = 0 };
- sigset_t ss;
-
- if (p->timer_armed) {
- /* First disarm timer */
- memset(&its, 0, sizeof(its));
- pa_assert_se(timer_settime(p->timer, TIMER_ABSTIME, &its, NULL) == 0);
-
- /* Remove a signal that might be waiting in the signal q */
- pa_assert_se(sigemptyset(&ss) == 0);
- pa_assert_se(sigaddset(&ss, p->rtsig) == 0);
- sigtimedwait(&ss, NULL, &ts);
- }
-
- /* And install the new timer */
- if (p->timer_enabled) {
- memset(&its, 0, sizeof(its));
-
- its.it_value.tv_sec = p->next_elapse.tv_sec;
- its.it_value.tv_nsec = p->next_elapse.tv_usec*1000;
-
- /* Make sure that 0,0 is not understood as
- * "disarming" */
- if (its.it_value.tv_sec == 0 && its.it_value.tv_nsec == 0)
- its.it_value.tv_nsec = 1;
- pa_assert_se(timer_settime(p->timer, TIMER_ABSTIME, &its, NULL) == 0);
- }
-
- p->timer_armed = p->timer_enabled;
- }
-
-#endif
-}
-
void pa_rtpoll_set_timer_absolute(pa_rtpoll *p, pa_usec_t usec) {
pa_assert(p);
pa_timeval_store(&p->next_elapse, usec);
p->timer_enabled = TRUE;
-
- update_timer(p);
}
void pa_rtpoll_set_timer_relative(pa_rtpoll *p, pa_usec_t usec) {
@@ -550,8 +388,6 @@ void pa_rtpoll_set_timer_relative(pa_rtpoll *p, pa_usec_t usec) {
pa_rtclock_get(&p->next_elapse);
pa_timeval_add(&p->next_elapse, usec);
p->timer_enabled = TRUE;
-
- update_timer(p);
}
void pa_rtpoll_set_timer_disabled(pa_rtpoll *p) {
@@ -559,8 +395,6 @@ void pa_rtpoll_set_timer_disabled(pa_rtpoll *p) {
memset(&p->next_elapse, 0, sizeof(p->next_elapse));
p->timer_enabled = FALSE;
-
- update_timer(p);
}
pa_rtpoll_item *pa_rtpoll_item_new(pa_rtpoll *p, pa_rtpoll_priority_t prio, unsigned n_fds) {
@@ -796,3 +630,9 @@ void pa_rtpoll_quit(pa_rtpoll *p) {
p->quit = TRUE;
}
+
+pa_bool_t pa_rtpoll_timer_elapsed(pa_rtpoll *p) {
+ pa_assert(p);
+
+ return p->timer_elapsed;
+}
diff --git a/src/pulsecore/rtpoll.h b/src/pulsecore/rtpoll.h
index 08776ef0..b2a87fca 100644
--- a/src/pulsecore/rtpoll.h
+++ b/src/pulsecore/rtpoll.h
@@ -62,9 +62,6 @@ typedef enum pa_rtpoll_priority {
pa_rtpoll *pa_rtpoll_new(void);
void pa_rtpoll_free(pa_rtpoll *p);
-/* Install the rtpoll in the current thread */
-void pa_rtpoll_install(pa_rtpoll *p);
-
/* Sleep on the rtpoll until the time event, or any of the fd events
* is triggered. If "wait" is 0 we don't sleep but only update the
* struct pollfd. Returns negative on error, positive if the loop
@@ -76,6 +73,10 @@ void pa_rtpoll_set_timer_absolute(pa_rtpoll *p, pa_usec_t usec);
void pa_rtpoll_set_timer_relative(pa_rtpoll *p, pa_usec_t usec);
void pa_rtpoll_set_timer_disabled(pa_rtpoll *p);
+/* Return TRUE when the elapsed timer was the reason for
+ * the last pa_rtpoll_run() invocation to finish */
+pa_bool_t pa_rtpoll_timer_elapsed(pa_rtpoll *p);
+
/* A new fd wakeup item for pa_rtpoll */
pa_rtpoll_item *pa_rtpoll_item_new(pa_rtpoll *p, pa_rtpoll_priority_t prio, unsigned n_fds);
void pa_rtpoll_item_free(pa_rtpoll_item *i);
diff --git a/src/pulsecore/rtsig.c b/src/pulsecore/rtsig.c
deleted file mode 100644
index 4cd6aa8f..00000000
--- a/src/pulsecore/rtsig.c
+++ /dev/null
@@ -1,131 +0,0 @@
-/***
- This file is part of PulseAudio.
-
- Copyright 2004-2006 Lennart Poettering
- Copyright 2006 Pierre Ossman <ossman@cendio.se> for Cendio AB
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of the
- License, or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <signal.h>
-
-#include <pulsecore/macro.h>
-#include <pulsecore/flist.h>
-#include <pulsecore/once.h>
-#include <pulsecore/thread.h>
-#include <pulsecore/core-util.h>
-
-#include "rtsig.h"
-
-#ifdef SIGRTMIN
-
-static void _free_rtsig(void *p) {
- pa_rtsig_put(PA_PTR_TO_INT(p));
-}
-
-PA_STATIC_FLIST_DECLARE(rtsig_flist, pa_make_power_of_two((unsigned) (SIGRTMAX-SIGRTMIN+1)), NULL);
-PA_STATIC_TLS_DECLARE(rtsig_tls, _free_rtsig);
-
-static pa_atomic_t rtsig_current = PA_ATOMIC_INIT(-1);
-
-static int rtsig_start = -1, rtsig_end = -1;
-
-int pa_rtsig_get(void) {
- void *p;
- int sig;
-
- if ((p = pa_flist_pop(PA_STATIC_FLIST_GET(rtsig_flist))))
- return PA_PTR_TO_INT(p);
-
- sig = pa_atomic_dec(&rtsig_current);
-
- pa_assert(sig <= SIGRTMAX);
- pa_assert(sig <= rtsig_end);
-
- if (sig < rtsig_start) {
- pa_atomic_inc(&rtsig_current);
- return -1;
- }
-
- return sig;
-}
-
-int pa_rtsig_get_for_thread(void) {
- int sig;
- void *p;
-
- if ((p = PA_STATIC_TLS_GET(rtsig_tls)))
- return PA_PTR_TO_INT(p);
-
- if ((sig = pa_rtsig_get()) < 0)
- return -1;
-
- PA_STATIC_TLS_SET(rtsig_tls, PA_INT_TO_PTR(sig));
- return sig;
-}
-
-void pa_rtsig_put(int sig) {
- pa_assert(sig >= rtsig_start);
- pa_assert(sig <= rtsig_end);
-
- pa_assert_se(pa_flist_push(PA_STATIC_FLIST_GET(rtsig_flist), PA_INT_TO_PTR(sig)) >= 0);
-}
-
-void pa_rtsig_configure(int start, int end) {
- int s;
- sigset_t ss;
-
- pa_assert(pa_atomic_load(&rtsig_current) == -1);
-
- pa_assert(SIGRTMIN <= start);
- pa_assert(start <= end);
- pa_assert(end <= SIGRTMAX);
-
- rtsig_start = start;
- rtsig_end = end;
-
- sigemptyset(&ss);
-
- for (s = rtsig_start; s <= rtsig_end; s++)
- pa_assert_se(sigaddset(&ss, s) == 0);
-
- pa_assert(pthread_sigmask(SIG_BLOCK, &ss, NULL) == 0);
-
- /* We allocate starting from the end */
- pa_atomic_store(&rtsig_current, rtsig_end);
-}
-
-#else /* SIGRTMIN */
-
-int pa_rtsig_get(void) {
- return -1;
-}
-
-int pa_rtsig_get_for_thread(void) {
- return -1;
-}
-
-void pa_rtsig_put(int sig) {
-}
-
-void pa_rtsig_configure(int start, int end) {
-}
-
-#endif /* SIGRTMIN */
diff --git a/src/pulsecore/sample-util.c b/src/pulsecore/sample-util.c
index dda38834..8a13495c 100644
--- a/src/pulsecore/sample-util.c
+++ b/src/pulsecore/sample-util.c
@@ -29,9 +29,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <errno.h>
-
-#include <liboil/liboilfuncs.h>
-#include <liboil/liboil.h>
+#include <math.h>
#include <pulse/timeval.h>
@@ -40,9 +38,9 @@
#include <pulsecore/macro.h>
#include <pulsecore/g711.h>
#include <pulsecore/core-util.h>
+#include <pulsecore/endianmacros.h>
#include "sample-util.h"
-#include "endianmacros.h"
#define PA_SILENCE_MAX (PA_PAGE_SIZE*16)
@@ -106,29 +104,41 @@ void* pa_silence_memory(void *p, size_t length, const pa_sample_spec *spec) {
return p;
}
+#define VOLUME_PADDING 32
+
static void calc_linear_integer_volume(int32_t linear[], const pa_cvolume *volume) {
- unsigned channel;
+ unsigned channel, nchannels, padding;
pa_assert(linear);
pa_assert(volume);
- for (channel = 0; channel < volume->channels; channel++)
+ nchannels = volume->channels;
+
+ for (channel = 0; channel < nchannels; channel++)
linear[channel] = (int32_t) lrint(pa_sw_volume_to_linear(volume->values[channel]) * 0x10000);
+
+ for (padding = 0; padding < VOLUME_PADDING; padding++, channel++)
+ linear[channel] = linear[padding];
}
static void calc_linear_float_volume(float linear[], const pa_cvolume *volume) {
- unsigned channel;
+ unsigned channel, nchannels, padding;
pa_assert(linear);
pa_assert(volume);
- for (channel = 0; channel < volume->channels; channel++)
+ nchannels = volume->channels;
+
+ for (channel = 0; channel < nchannels; channel++)
linear[channel] = (float) pa_sw_volume_to_linear(volume->values[channel]);
+
+ for (padding = 0; padding < VOLUME_PADDING; padding++, channel++)
+ linear[channel] = linear[padding];
}
static void calc_linear_integer_stream_volumes(pa_mix_info streams[], unsigned nstreams, const pa_cvolume *volume, const pa_sample_spec *spec) {
unsigned k, channel;
- float linear[PA_CHANNELS_MAX];
+ float linear[PA_CHANNELS_MAX + VOLUME_PADDING];
pa_assert(streams);
pa_assert(spec);
@@ -147,7 +157,7 @@ static void calc_linear_integer_stream_volumes(pa_mix_info streams[], unsigned n
static void calc_linear_float_stream_volumes(pa_mix_info streams[], unsigned nstreams, const pa_cvolume *volume, const pa_sample_spec *spec) {
unsigned k, channel;
- float linear[PA_CHANNELS_MAX];
+ float linear[PA_CHANNELS_MAX + VOLUME_PADDING];
pa_assert(streams);
pa_assert(spec);
@@ -690,6 +700,28 @@ size_t pa_mix(
return length;
}
+typedef union {
+ float f;
+ uint32_t i;
+} volume_val;
+
+typedef void (*pa_calc_volume_func_t) (void *volumes, const pa_cvolume *volume);
+
+static const pa_calc_volume_func_t calc_volume_table[] = {
+ [PA_SAMPLE_U8] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_ALAW] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_ULAW] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_S16LE] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_S16BE] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_FLOAT32LE] = (pa_calc_volume_func_t) calc_linear_float_volume,
+ [PA_SAMPLE_FLOAT32BE] = (pa_calc_volume_func_t) calc_linear_float_volume,
+ [PA_SAMPLE_S32LE] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_S32BE] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_S24LE] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_S24BE] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_S24_32LE] = (pa_calc_volume_func_t) calc_linear_integer_volume,
+ [PA_SAMPLE_S24_32BE] = (pa_calc_volume_func_t) calc_linear_integer_volume
+};
void pa_volume_memchunk(
pa_memchunk*c,
@@ -697,6 +729,8 @@ void pa_volume_memchunk(
const pa_cvolume *volume) {
void *ptr;
+ volume_val linear[PA_CHANNELS_MAX + VOLUME_PADDING];
+ pa_do_volume_func_t do_volume;
pa_assert(c);
pa_assert(spec);
@@ -714,337 +748,19 @@ void pa_volume_memchunk(
return;
}
- ptr = (uint8_t*) pa_memblock_acquire(c->memblock) + c->index;
-
- switch (spec->format) {
-
- case PA_SAMPLE_S16NE: {
- int16_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (int16_t*) ptr + c->length/sizeof(int16_t);
-
- for (channel = 0, d = ptr; d < e; d++) {
- int32_t t, hi, lo;
-
- /* Multiplying the 32bit volume factor with the 16bit
- * sample might result in an 48bit value. We want to
- * do without 64 bit integers and hence do the
- * multiplication independantly for the HI and LO part
- * of the volume. */
-
- hi = linear[channel] >> 16;
- lo = linear[channel] & 0xFFFF;
-
- t = (int32_t)(*d);
- t = ((t * lo) >> 16) + (t * hi);
- t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
- *d = (int16_t) t;
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
-
- break;
- }
-
- case PA_SAMPLE_S16RE: {
- int16_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (int16_t*) ptr + c->length/sizeof(int16_t);
-
- for (channel = 0, d = ptr; d < e; d++) {
- int32_t t, hi, lo;
-
- hi = linear[channel] >> 16;
- lo = linear[channel] & 0xFFFF;
-
- t = (int32_t) PA_INT16_SWAP(*d);
- t = ((t * lo) >> 16) + (t * hi);
- t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
- *d = PA_INT16_SWAP((int16_t) t);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
-
- break;
- }
-
- case PA_SAMPLE_S32NE: {
- int32_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (int32_t*) ptr + c->length/sizeof(int32_t);
-
- for (channel = 0, d = ptr; d < e; d++) {
- int64_t t;
-
- t = (int64_t)(*d);
- t = (t * linear[channel]) >> 16;
- t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
- *d = (int32_t) t;
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_S32RE: {
- int32_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (int32_t*) ptr + c->length/sizeof(int32_t);
-
- for (channel = 0, d = ptr; d < e; d++) {
- int64_t t;
-
- t = (int64_t) PA_INT32_SWAP(*d);
- t = (t * linear[channel]) >> 16;
- t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
- *d = PA_INT32_SWAP((int32_t) t);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_S24NE: {
- uint8_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (uint8_t*) ptr + c->length;
-
- for (channel = 0, d = ptr; d < e; d += 3) {
- int64_t t;
-
- t = (int64_t)((int32_t) (PA_READ24NE(d) << 8));
- t = (t * linear[channel]) >> 16;
- t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
- PA_WRITE24NE(d, ((uint32_t) (int32_t) t) >> 8);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_S24RE: {
- uint8_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (uint8_t*) ptr + c->length;
-
- for (channel = 0, d = ptr; d < e; d += 3) {
- int64_t t;
-
- t = (int64_t)((int32_t) (PA_READ24RE(d) << 8));
- t = (t * linear[channel]) >> 16;
- t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
- PA_WRITE24RE(d, ((uint32_t) (int32_t) t) >> 8);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_S24_32NE: {
- uint32_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (uint32_t*) ptr + c->length/sizeof(uint32_t);
-
- for (channel = 0, d = ptr; d < e; d++) {
- int64_t t;
-
- t = (int64_t) ((int32_t) (*d << 8));
- t = (t * linear[channel]) >> 16;
- t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
- *d = ((uint32_t) ((int32_t) t)) >> 8;
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_S24_32RE: {
- uint32_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (uint32_t*) ptr + c->length/sizeof(uint32_t);
-
- for (channel = 0, d = ptr; d < e; d++) {
- int64_t t;
-
- t = (int64_t) ((int32_t) (PA_UINT32_SWAP(*d) << 8));
- t = (t * linear[channel]) >> 16;
- t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
- *d = PA_UINT32_SWAP(((uint32_t) ((int32_t) t)) >> 8);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_U8: {
- uint8_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (uint8_t*) ptr + c->length;
-
- for (channel = 0, d = ptr; d < e; d++) {
- int32_t t, hi, lo;
-
- hi = linear[channel] >> 16;
- lo = linear[channel] & 0xFFFF;
-
- t = (int32_t) *d - 0x80;
- t = ((t * lo) >> 16) + (t * hi);
- t = PA_CLAMP_UNLIKELY(t, -0x80, 0x7F);
- *d = (uint8_t) (t + 0x80);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_ULAW: {
- uint8_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (uint8_t*) ptr + c->length;
-
- for (channel = 0, d = ptr; d < e; d++) {
- int32_t t, hi, lo;
-
- hi = linear[channel] >> 16;
- lo = linear[channel] & 0xFFFF;
-
- t = (int32_t) st_ulaw2linear16(*d);
- t = ((t * lo) >> 16) + (t * hi);
- t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
- *d = (uint8_t) st_14linear2ulaw((int16_t) t >> 2);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_ALAW: {
- uint8_t *d, *e;
- unsigned channel;
- int32_t linear[PA_CHANNELS_MAX];
-
- calc_linear_integer_volume(linear, volume);
-
- e = (uint8_t*) ptr + c->length;
-
- for (channel = 0, d = ptr; d < e; d++) {
- int32_t t, hi, lo;
-
- hi = linear[channel] >> 16;
- lo = linear[channel] & 0xFFFF;
-
- t = (int32_t) st_alaw2linear16(*d);
- t = ((t * lo) >> 16) + (t * hi);
- t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
- *d = (uint8_t) st_13linear2alaw((int16_t) t >> 3);
-
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
- break;
- }
-
- case PA_SAMPLE_FLOAT32NE: {
- float *d;
- int skip;
- unsigned n;
- unsigned channel;
-
- d = ptr;
- skip = (int) (spec->channels * sizeof(float));
- n = (unsigned) (c->length/sizeof(float)/spec->channels);
-
- for (channel = 0; channel < spec->channels; channel ++) {
- float v, *t;
-
- if (PA_UNLIKELY(volume->values[channel] == PA_VOLUME_NORM))
- continue;
-
- v = (float) pa_sw_volume_to_linear(volume->values[channel]);
- t = d + channel;
- oil_scalarmult_f32(t, skip, t, skip, &v, (int) n);
- }
- break;
- }
-
- case PA_SAMPLE_FLOAT32RE: {
- float *d, *e;
- unsigned channel;
- float linear[PA_CHANNELS_MAX];
-
- calc_linear_float_volume(linear, volume);
-
- e = (float*) ptr + c->length/sizeof(float);
-
- for (channel = 0, d = ptr; d < e; d++) {
- float t;
+ if (spec->format < 0 || spec->format > PA_SAMPLE_MAX) {
+ pa_log_warn(" Unable to change volume of format %s.", pa_sample_format_to_string(spec->format));
+ return;
+ }
- t = PA_FLOAT32_SWAP(*d);
- t *= linear[channel];
- *d = PA_FLOAT32_SWAP(t);
+ do_volume = pa_get_volume_func(spec->format);
+ pa_assert(do_volume);
- if (PA_UNLIKELY(++channel >= spec->channels))
- channel = 0;
- }
-
- break;
- }
+ calc_volume_table[spec->format] ((void *)linear, volume);
+ ptr = (uint8_t*) pa_memblock_acquire(c->memblock) + c->index;
- default:
- pa_log_warn(" Unable to change volume of format %s.", pa_sample_format_to_string(spec->format));
- /* If we cannot change the volume, we just don't do it */
- }
+ do_volume (ptr, (void *)linear, spec->channels, c->length);
pa_memblock_release(c->memblock);
}
@@ -1090,7 +806,7 @@ void pa_interleave(const void *src[], unsigned channels, void *dst, size_t ss, u
d = (uint8_t*) dst + c * ss;
for (j = 0; j < n; j ++) {
- oil_memcpy(d, s, (int) ss);
+ memcpy(d, s, (int) ss);
s = (uint8_t*) s + ss;
d = (uint8_t*) d + fs;
}
@@ -1118,7 +834,7 @@ void pa_deinterleave(const void *src, void *dst[], unsigned channels, size_t ss,
d = dst[c];
for (j = 0; j < n; j ++) {
- oil_memcpy(d, s, (int) ss);
+ memcpy(d, s, (int) ss);
s = (uint8_t*) s + fs;
d = (uint8_t*) d + ss;
}
@@ -1182,7 +898,7 @@ pa_memchunk* pa_silence_memchunk_get(pa_silence_cache *cache, pa_mempool *pool,
case PA_SAMPLE_S24LE:
case PA_SAMPLE_S24BE:
case PA_SAMPLE_S24_32LE:
- case PA_SAMPLE_S24_32RE:
+ case PA_SAMPLE_S24_32BE:
case PA_SAMPLE_FLOAT32LE:
case PA_SAMPLE_FLOAT32BE:
cache->blocks[PA_SAMPLE_S16LE] = b = silence_memblock_new(pool, 0);
@@ -1227,10 +943,15 @@ void pa_sample_clamp(pa_sample_format_t format, void *dst, size_t dstr, const vo
s = src; d = dst;
if (format == PA_SAMPLE_FLOAT32NE) {
+ for (; n > 0; n--) {
+ float f;
- float minus_one = -1.0, plus_one = 1.0;
- oil_clip_f32(d, (int) dstr, s, (int) sstr, (int) n, &minus_one, &plus_one);
+ f = *s;
+ *d = PA_CLAMP_UNLIKELY(f, -1.0f, 1.0f);
+ s = (const float*) ((const uint8_t*) s + sstr);
+ d = (float*) ((uint8_t*) d + dstr);
+ }
} else {
pa_assert(format == PA_SAMPLE_FLOAT32RE);
@@ -1287,7 +1008,7 @@ void pa_memchunk_dump_to_file(pa_memchunk *c, const char *fn) {
/* Only for debugging purposes */
- f = fopen(fn, "a");
+ f = pa_fopen_cloexec(fn, "a");
if (!f) {
pa_log_warn("Failed to open '%s': %s", fn, pa_cstrerror(errno));
@@ -1336,3 +1057,13 @@ void pa_memchunk_sine(pa_memchunk *c, pa_mempool *pool, unsigned rate, unsigned
calc_sine(p, c->length, freq * l / rate);
pa_memblock_release(c->memblock);
}
+
+size_t pa_convert_size(size_t size, const pa_sample_spec *from, const pa_sample_spec *to) {
+ pa_usec_t usec;
+
+ pa_assert(from);
+ pa_assert(to);
+
+ usec = pa_bytes_to_usec_round_up(size, from);
+ return pa_usec_to_bytes_round_up(usec, to);
+}
diff --git a/src/pulsecore/sample-util.h b/src/pulsecore/sample-util.h
index 79af9efc..cf79d433 100644
--- a/src/pulsecore/sample-util.h
+++ b/src/pulsecore/sample-util.h
@@ -23,8 +23,11 @@
USA.
***/
+#include <pulse/gccmacro.h>
#include <pulse/sample.h>
#include <pulse/volume.h>
+#include <pulse/channelmap.h>
+
#include <pulsecore/memblock.h>
#include <pulsecore/memchunk.h>
@@ -85,4 +88,69 @@ void pa_memchunk_dump_to_file(pa_memchunk *c, const char *fn);
void pa_memchunk_sine(pa_memchunk *c, pa_mempool *pool, unsigned rate, unsigned freq);
+typedef void (*pa_do_volume_func_t) (void *samples, void *volumes, unsigned channels, unsigned length);
+
+pa_do_volume_func_t pa_get_volume_func(pa_sample_format_t f);
+void pa_set_volume_func(pa_sample_format_t f, pa_do_volume_func_t func);
+
+size_t pa_convert_size(size_t size, const pa_sample_spec *from, const pa_sample_spec *to);
+
+#define PA_CHANNEL_POSITION_MASK_LEFT \
+ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_REAR_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_SIDE_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_LEFT)) \
+
+#define PA_CHANNEL_POSITION_MASK_RIGHT \
+ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_REAR_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_SIDE_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_RIGHT))
+
+#define PA_CHANNEL_POSITION_MASK_CENTER \
+ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_REAR_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_CENTER))
+
+#define PA_CHANNEL_POSITION_MASK_FRONT \
+ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_CENTER))
+
+#define PA_CHANNEL_POSITION_MASK_REAR \
+ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_REAR_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_REAR_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_REAR_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_CENTER))
+
+#define PA_CHANNEL_POSITION_MASK_SIDE_OR_TOP_CENTER \
+ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_SIDE_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_SIDE_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_CENTER))
+
+#define PA_CHANNEL_POSITION_MASK_TOP \
+ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_FRONT_CENTER) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_LEFT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_RIGHT) \
+ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_TOP_REAR_CENTER))
+
+#define PA_CHANNEL_POSITION_MASK_ALL \
+ ((pa_channel_position_mask_t) (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_MAX)-1))
+
#endif
diff --git a/src/pulsecore/sconv-s16le.c b/src/pulsecore/sconv-s16le.c
index 43b8cb3e..138e4185 100644
--- a/src/pulsecore/sconv-s16le.c
+++ b/src/pulsecore/sconv-s16le.c
@@ -27,14 +27,11 @@
#include <inttypes.h>
#include <stdio.h>
-
-#include <liboil/liboilfuncs.h>
+#include <math.h>
#include <pulsecore/sconv.h>
#include <pulsecore/macro.h>
-#include <pulsecore/log.h>
-
-#include "endianmacros.h"
+#include <pulsecore/endianmacros.h>
#include "sconv-s16le.h"
@@ -86,17 +83,13 @@ void pa_sconv_s16le_to_float32ne(unsigned n, const int16_t *a, float *b) {
pa_assert(b);
#if SWAP_WORDS == 1
-
for (; n > 0; n--) {
int16_t s = *(a++);
*(b++) = ((float) INT16_FROM(s))/(float) 0x7FFF;
}
-
#else
-{
- static const double add = 0, factor = 1.0/0x7FFF;
- oil_scaleconv_f32_s16(b, a, (int) n, &add, &factor);
-}
+ for (; n > 0; n--)
+ *(b++) = ((float) (*(a++)))/(float) 0x7FFF;
#endif
}
@@ -105,17 +98,13 @@ void pa_sconv_s32le_to_float32ne(unsigned n, const int32_t *a, float *b) {
pa_assert(b);
#if SWAP_WORDS == 1
-
for (; n > 0; n--) {
int32_t s = *(a++);
*(b++) = (float) (((double) INT32_FROM(s))/0x7FFFFFFF);
}
-
#else
-{
- static const double add = 0, factor = 1.0/0x7FFFFFFF;
- oil_scaleconv_f32_s32(b, a, (int) n, &add, &factor);
-}
+ for (; n > 0; n--)
+ *(b++) = (float) (((double) (*(a++)))/0x7FFFFFFF);
#endif
}
@@ -124,7 +113,6 @@ void pa_sconv_s16le_from_float32ne(unsigned n, const float *a, int16_t *b) {
pa_assert(b);
#if SWAP_WORDS == 1
-
for (; n > 0; n--) {
int16_t s;
float v = *(a++);
@@ -133,12 +121,13 @@ void pa_sconv_s16le_from_float32ne(unsigned n, const float *a, int16_t *b) {
s = (int16_t) lrintf(v * 0x7FFF);
*(b++) = INT16_TO(s);
}
-
#else
-{
- static const double add = 0, factor = 0x7FFF;
- oil_scaleconv_s16_f32(b, a, (int) n, &add, &factor);
-}
+ for (; n > 0; n--) {
+ float v = *(a++);
+
+ v = PA_CLAMP_UNLIKELY(v, -1.0f, 1.f);
+ *(b++) = (int16_t) lrintf(v * 0x7FFF);
+ }
#endif
}
@@ -147,7 +136,6 @@ void pa_sconv_s32le_from_float32ne(unsigned n, const float *a, int32_t *b) {
pa_assert(b);
#if SWAP_WORDS == 1
-
for (; n > 0; n--) {
int32_t s;
float v = *(a++);
@@ -156,12 +144,13 @@ void pa_sconv_s32le_from_float32ne(unsigned n, const float *a, int32_t *b) {
s = (int32_t) lrint((double) v * (double) 0x7FFFFFFF);
*(b++) = INT32_TO(s);
}
-
#else
-{
- static const double add = 0, factor = 0x7FFFFFFF;
- oil_scaleconv_s32_f32(b, a, (int) n, &add, &factor);
-}
+ for (; n > 0; n--) {
+ float v = *(a++);
+
+ v = PA_CLAMP_UNLIKELY(v, -1.0f, 1.0f);
+ *(b++) = (int32_t) lrint((double) v * (double) 0x7FFFFFFF);
+ }
#endif
}
diff --git a/src/pulsecore/sconv.c b/src/pulsecore/sconv.c
index d89f4283..f0f154f5 100644
--- a/src/pulsecore/sconv.c
+++ b/src/pulsecore/sconv.c
@@ -26,47 +26,44 @@
#include <stdio.h>
#include <stdlib.h>
-
-#include <liboil/liboilfuncs.h>
-#include <liboil/liboil.h>
+#include <math.h>
#include <pulsecore/g711.h>
#include <pulsecore/macro.h>
+#include <pulsecore/endianmacros.h>
-#include "endianmacros.h"
-#include "sconv-s16le.h"
-#include "sconv-s16be.h"
+#include <pulsecore/sconv-s16le.h>
+#include <pulsecore/sconv-s16be.h>
#include "sconv.h"
/* u8 */
static void u8_to_float32ne(unsigned n, const uint8_t *a, float *b) {
- static const double add = -1, factor = 1.0/128.0;
-
pa_assert(a);
pa_assert(b);
- oil_scaleconv_f32_u8(b, a, (int) n, &add, &factor);
+ for (; n > 0; n--, a++, b++)
+ *b = (*a * 1.0/128.0) - 1.0;
}
static void u8_from_float32ne(unsigned n, const float *a, uint8_t *b) {
- static const double add = 128, factor = 127.0;
-
pa_assert(a);
pa_assert(b);
- oil_scaleconv_u8_f32(b, a, (int) n, &add, &factor);
+ for (; n > 0; n--, a++, b++) {
+ float v;
+ v = (*a * 127.0) + 128.0;
+ v = PA_CLAMP_UNLIKELY (v, 0.0, 255.0);
+ *b = rint (v);
+ }
}
static void u8_to_s16ne(unsigned n, const uint8_t *a, int16_t *b) {
- static const int16_t add = -0x80, factor = 0x100;
-
pa_assert(a);
pa_assert(b);
- oil_conv_s16_u8(b, 2, a, 1, (int) n);
- oil_scalaradd_s16(b, 2, b, 2, &add, (int) n);
- oil_scalarmult_s16(b, 2, b, 2, &factor, (int) n);
+ for (; n > 0; n--, a++, b++)
+ *b = (((int16_t)*a) - 128) << 8;
}
static void u8_from_s16ne(unsigned n, const int16_t *a, uint8_t *b) {
@@ -84,7 +81,7 @@ static void float32ne_to_float32ne(unsigned n, const float *a, float *b) {
pa_assert(a);
pa_assert(b);
- oil_memcpy(b, a, (int) (sizeof(float) * n));
+ memcpy(b, a, (int) (sizeof(float) * n));
}
static void float32re_to_float32ne(unsigned n, const float *a, float *b) {
@@ -101,7 +98,7 @@ static void s16ne_to_s16ne(unsigned n, const int16_t *a, int16_t *b) {
pa_assert(a);
pa_assert(b);
- oil_memcpy(b, a, (int) (sizeof(int16_t) * n));
+ memcpy(b, a, (int) (sizeof(int16_t) * n));
}
static void s16re_to_s16ne(unsigned n, const int16_t *a, int16_t *b) {
@@ -188,98 +185,130 @@ static void alaw_from_s16ne(unsigned n, const int16_t *a, uint8_t *b) {
*b = st_13linear2alaw(*a >> 3);
}
+static pa_convert_func_t to_float32ne_table[] = {
+ [PA_SAMPLE_U8] = (pa_convert_func_t) u8_to_float32ne,
+ [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_to_float32ne,
+ [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_to_float32ne,
+ [PA_SAMPLE_S16LE] = (pa_convert_func_t) pa_sconv_s16le_to_float32ne,
+ [PA_SAMPLE_S16BE] = (pa_convert_func_t) pa_sconv_s16be_to_float32ne,
+ [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_to_float32ne,
+ [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_to_float32ne,
+ [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_to_float32ne,
+ [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_to_float32ne,
+ [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_to_float32ne,
+ [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_to_float32ne,
+ [PA_SAMPLE_FLOAT32NE] = (pa_convert_func_t) float32ne_to_float32ne,
+ [PA_SAMPLE_FLOAT32RE] = (pa_convert_func_t) float32re_to_float32ne,
+};
+
pa_convert_func_t pa_get_convert_to_float32ne_function(pa_sample_format_t f) {
- static const pa_convert_func_t table[] = {
- [PA_SAMPLE_U8] = (pa_convert_func_t) u8_to_float32ne,
- [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_to_float32ne,
- [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_to_float32ne,
- [PA_SAMPLE_S16LE] = (pa_convert_func_t) pa_sconv_s16le_to_float32ne,
- [PA_SAMPLE_S16BE] = (pa_convert_func_t) pa_sconv_s16be_to_float32ne,
- [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_to_float32ne,
- [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_to_float32ne,
- [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_to_float32ne,
- [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_to_float32ne,
- [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_to_float32ne,
- [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_to_float32ne,
- [PA_SAMPLE_FLOAT32NE] = (pa_convert_func_t) float32ne_to_float32ne,
- [PA_SAMPLE_FLOAT32RE] = (pa_convert_func_t) float32re_to_float32ne,
- };
+ pa_assert(f >= 0);
+ pa_assert(f < PA_SAMPLE_MAX);
+
+ return to_float32ne_table[f];
+}
+
+void pa_set_convert_to_float32ne_function(pa_sample_format_t f, pa_convert_func_t func) {
pa_assert(f >= 0);
pa_assert(f < PA_SAMPLE_MAX);
- return table[f];
+ to_float32ne_table[f] = func;
}
+static pa_convert_func_t from_float32ne_table[] = {
+ [PA_SAMPLE_U8] = (pa_convert_func_t) u8_from_float32ne,
+ [PA_SAMPLE_S16LE] = (pa_convert_func_t) pa_sconv_s16le_from_float32ne,
+ [PA_SAMPLE_S16BE] = (pa_convert_func_t) pa_sconv_s16be_from_float32ne,
+ [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_from_float32ne,
+ [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_from_float32ne,
+ [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_from_float32ne,
+ [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_from_float32ne,
+ [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_from_float32ne,
+ [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_from_float32ne,
+ [PA_SAMPLE_FLOAT32NE] = (pa_convert_func_t) float32ne_to_float32ne,
+ [PA_SAMPLE_FLOAT32RE] = (pa_convert_func_t) float32re_to_float32ne,
+ [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_from_float32ne,
+ [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_from_float32ne
+};
+
pa_convert_func_t pa_get_convert_from_float32ne_function(pa_sample_format_t f) {
- static const pa_convert_func_t table[] = {
- [PA_SAMPLE_U8] = (pa_convert_func_t) u8_from_float32ne,
- [PA_SAMPLE_S16LE] = (pa_convert_func_t) pa_sconv_s16le_from_float32ne,
- [PA_SAMPLE_S16BE] = (pa_convert_func_t) pa_sconv_s16be_from_float32ne,
- [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_from_float32ne,
- [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_from_float32ne,
- [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_from_float32ne,
- [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_from_float32ne,
- [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_from_float32ne,
- [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_from_float32ne,
- [PA_SAMPLE_FLOAT32NE] = (pa_convert_func_t) float32ne_to_float32ne,
- [PA_SAMPLE_FLOAT32RE] = (pa_convert_func_t) float32re_to_float32ne,
- [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_from_float32ne,
- [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_from_float32ne
- };
+ pa_assert(f >= 0);
+ pa_assert(f < PA_SAMPLE_MAX);
+
+ return from_float32ne_table[f];
+}
+
+void pa_set_convert_from_float32ne_function(pa_sample_format_t f, pa_convert_func_t func) {
pa_assert(f >= 0);
pa_assert(f < PA_SAMPLE_MAX);
- return table[f];
+ from_float32ne_table[f] = func;
}
+static pa_convert_func_t to_s16ne_table[] = {
+ [PA_SAMPLE_U8] = (pa_convert_func_t) u8_to_s16ne,
+ [PA_SAMPLE_S16NE] = (pa_convert_func_t) s16ne_to_s16ne,
+ [PA_SAMPLE_S16RE] = (pa_convert_func_t) s16re_to_s16ne,
+ [PA_SAMPLE_FLOAT32BE] = (pa_convert_func_t) pa_sconv_float32be_to_s16ne,
+ [PA_SAMPLE_FLOAT32LE] = (pa_convert_func_t) pa_sconv_float32le_to_s16ne,
+ [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_to_s16ne,
+ [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_to_s16ne,
+ [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_to_s16ne,
+ [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_to_s16ne,
+ [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_to_s16ne,
+ [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_to_s16ne,
+ [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_to_s16ne,
+ [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_to_s16ne
+};
+
pa_convert_func_t pa_get_convert_to_s16ne_function(pa_sample_format_t f) {
- static const pa_convert_func_t table[] = {
- [PA_SAMPLE_U8] = (pa_convert_func_t) u8_to_s16ne,
- [PA_SAMPLE_S16NE] = (pa_convert_func_t) s16ne_to_s16ne,
- [PA_SAMPLE_S16RE] = (pa_convert_func_t) s16re_to_s16ne,
- [PA_SAMPLE_FLOAT32BE] = (pa_convert_func_t) pa_sconv_float32be_to_s16ne,
- [PA_SAMPLE_FLOAT32LE] = (pa_convert_func_t) pa_sconv_float32le_to_s16ne,
- [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_to_s16ne,
- [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_to_s16ne,
- [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_to_s16ne,
- [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_to_s16ne,
- [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_to_s16ne,
- [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_to_s16ne,
- [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_to_s16ne,
- [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_to_s16ne
- };
+ pa_assert(f >= 0);
+ pa_assert(f < PA_SAMPLE_MAX);
+
+ return to_s16ne_table[f];
+}
+
+void pa_set_convert_to_s16ne_function(pa_sample_format_t f, pa_convert_func_t func) {
pa_assert(f >= 0);
pa_assert(f < PA_SAMPLE_MAX);
- return table[f];
+ to_s16ne_table[f] = func;
}
+static pa_convert_func_t from_s16ne_table[] = {
+ [PA_SAMPLE_U8] = (pa_convert_func_t) u8_from_s16ne,
+ [PA_SAMPLE_S16NE] = (pa_convert_func_t) s16ne_to_s16ne,
+ [PA_SAMPLE_S16RE] = (pa_convert_func_t) s16re_to_s16ne,
+ [PA_SAMPLE_FLOAT32BE] = (pa_convert_func_t) pa_sconv_float32be_from_s16ne,
+ [PA_SAMPLE_FLOAT32LE] = (pa_convert_func_t) pa_sconv_float32le_from_s16ne,
+ [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_from_s16ne,
+ [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_from_s16ne,
+ [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_from_s16ne,
+ [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_from_s16ne,
+ [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_from_s16ne,
+ [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_from_s16ne,
+ [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_from_s16ne,
+ [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_from_s16ne,
+};
+
pa_convert_func_t pa_get_convert_from_s16ne_function(pa_sample_format_t f) {
- static const pa_convert_func_t table[] = {
- [PA_SAMPLE_U8] = (pa_convert_func_t) u8_from_s16ne,
- [PA_SAMPLE_S16NE] = (pa_convert_func_t) s16ne_to_s16ne,
- [PA_SAMPLE_S16RE] = (pa_convert_func_t) s16re_to_s16ne,
- [PA_SAMPLE_FLOAT32BE] = (pa_convert_func_t) pa_sconv_float32be_from_s16ne,
- [PA_SAMPLE_FLOAT32LE] = (pa_convert_func_t) pa_sconv_float32le_from_s16ne,
- [PA_SAMPLE_S32BE] = (pa_convert_func_t) pa_sconv_s32be_from_s16ne,
- [PA_SAMPLE_S32LE] = (pa_convert_func_t) pa_sconv_s32le_from_s16ne,
- [PA_SAMPLE_S24BE] = (pa_convert_func_t) pa_sconv_s24be_from_s16ne,
- [PA_SAMPLE_S24LE] = (pa_convert_func_t) pa_sconv_s24le_from_s16ne,
- [PA_SAMPLE_S24_32BE] = (pa_convert_func_t) pa_sconv_s24_32be_from_s16ne,
- [PA_SAMPLE_S24_32LE] = (pa_convert_func_t) pa_sconv_s24_32le_from_s16ne,
- [PA_SAMPLE_ALAW] = (pa_convert_func_t) alaw_from_s16ne,
- [PA_SAMPLE_ULAW] = (pa_convert_func_t) ulaw_from_s16ne,
- };
+ pa_assert(f >= 0);
+ pa_assert(f < PA_SAMPLE_MAX);
+
+ return from_s16ne_table[f];
+}
+
+void pa_set_convert_from_s16ne_function(pa_sample_format_t f, pa_convert_func_t func) {
pa_assert(f >= 0);
pa_assert(f < PA_SAMPLE_MAX);
- return table[f];
+ from_s16ne_table[f] = func;
}
diff --git a/src/pulsecore/sconv.h b/src/pulsecore/sconv.h
index b00a16a4..204887f3 100644
--- a/src/pulsecore/sconv.h
+++ b/src/pulsecore/sconv.h
@@ -23,6 +23,7 @@
USA.
***/
+#include <pulse/gccmacro.h>
#include <pulse/sample.h>
typedef void (*pa_convert_func_t)(unsigned n, const void *a, void *b);
@@ -33,4 +34,10 @@ pa_convert_func_t pa_get_convert_from_float32ne_function(pa_sample_format_t f) P
pa_convert_func_t pa_get_convert_to_s16ne_function(pa_sample_format_t f) PA_GCC_PURE;
pa_convert_func_t pa_get_convert_from_s16ne_function(pa_sample_format_t f) PA_GCC_PURE;
+void pa_set_convert_to_float32ne_function(pa_sample_format_t f, pa_convert_func_t func);
+void pa_set_convert_from_float32ne_function(pa_sample_format_t f, pa_convert_func_t func);
+
+void pa_set_convert_to_s16ne_function(pa_sample_format_t f, pa_convert_func_t func);
+void pa_set_convert_from_s16ne_function(pa_sample_format_t f, pa_convert_func_t func);
+
#endif
diff --git a/src/pulsecore/sconv_sse.c b/src/pulsecore/sconv_sse.c
new file mode 100644
index 00000000..ac99bf67
--- /dev/null
+++ b/src/pulsecore/sconv_sse.c
@@ -0,0 +1,233 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2006 Pierre Ossman <ossman@cendio.se> for Cendio AB
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdio.h>
+#include <stdlib.h>
+
+#include <pulsecore/macro.h>
+#include <pulsecore/endianmacros.h>
+
+#include "cpu-x86.h"
+#include "sconv.h"
+
+#if !defined(__APPLE__) && defined (__i386__) || defined (__amd64__)
+
+static const PA_DECLARE_ALIGNED (16, float, one[4]) = { 1.0, 1.0, 1.0, 1.0 };
+static const PA_DECLARE_ALIGNED (16, float, mone[4]) = { -1.0, -1.0, -1.0, -1.0 };
+static const PA_DECLARE_ALIGNED (16, float, scale[4]) = { 0x7fff, 0x7fff, 0x7fff, 0x7fff };
+
+static void pa_sconv_s16le_from_f32ne_sse(unsigned n, const float *a, int16_t *b) {
+ pa_reg_x86 temp, i;
+
+ __asm__ __volatile__ (
+ " movaps %5, %%xmm5 \n\t"
+ " movaps %6, %%xmm6 \n\t"
+ " movaps %7, %%xmm7 \n\t"
+ " xor %0, %0 \n\t"
+
+ " mov %4, %1 \n\t"
+ " sar $3, %1 \n\t" /* 8 floats at a time */
+ " cmp $0, %1 \n\t"
+ " je 2f \n\t"
+
+ "1: \n\t"
+ " movups (%2, %0, 2), %%xmm0 \n\t" /* read 8 floats */
+ " movups 16(%2, %0, 2), %%xmm2 \n\t"
+ " minps %%xmm5, %%xmm0 \n\t" /* clamp to 1.0 */
+ " minps %%xmm5, %%xmm2 \n\t"
+ " maxps %%xmm6, %%xmm0 \n\t" /* clamp to -1.0 */
+ " maxps %%xmm6, %%xmm2 \n\t"
+ " mulps %%xmm7, %%xmm0 \n\t" /* *= 0x7fff */
+ " mulps %%xmm7, %%xmm2 \n\t"
+
+ " cvtps2pi %%xmm0, %%mm0 \n\t" /* low part to int */
+ " cvtps2pi %%xmm2, %%mm2 \n\t"
+ " movhlps %%xmm0, %%xmm0 \n\t" /* bring high part in position */
+ " movhlps %%xmm2, %%xmm2 \n\t"
+ " cvtps2pi %%xmm0, %%mm1 \n\t" /* high part to int */
+ " cvtps2pi %%xmm2, %%mm3 \n\t"
+
+ " packssdw %%mm1, %%mm0 \n\t" /* pack parts */
+ " packssdw %%mm3, %%mm2 \n\t"
+ " movq %%mm0, (%3, %0) \n\t"
+ " movq %%mm2, 8(%3, %0) \n\t"
+
+ " add $16, %0 \n\t"
+ " dec %1 \n\t"
+ " jne 1b \n\t"
+
+ "2: \n\t"
+ " mov %4, %1 \n\t" /* prepare for leftovers */
+ " and $7, %1 \n\t"
+ " je 4f \n\t"
+
+ "3: \n\t"
+ " movss (%2, %0, 2), %%xmm0 \n\t"
+ " minss %%xmm5, %%xmm0 \n\t"
+ " maxss %%xmm6, %%xmm0 \n\t"
+ " mulss %%xmm7, %%xmm0 \n\t"
+ " cvtss2si %%xmm0, %4 \n\t"
+ " movw %w4, (%3, %0) \n\t"
+ " add $2, %0 \n\t"
+ " dec %1 \n\t"
+ " jne 3b \n\t"
+
+ "4: \n\t"
+ " emms \n\t"
+
+ : "=&r" (i), "=&r" (temp)
+ : "r" (a), "r" (b), "r" ((pa_reg_x86)n), "m" (*one), "m" (*mone), "m" (*scale)
+ : "cc", "memory"
+ );
+}
+
+static void pa_sconv_s16le_from_f32ne_sse2(unsigned n, const float *a, int16_t *b) {
+ pa_reg_x86 temp, i;
+
+ __asm__ __volatile__ (
+ " movaps %5, %%xmm5 \n\t"
+ " movaps %6, %%xmm6 \n\t"
+ " movaps %7, %%xmm7 \n\t"
+ " xor %0, %0 \n\t"
+
+ " mov %4, %1 \n\t"
+ " sar $3, %1 \n\t" /* 8 floats at a time */
+ " cmp $0, %1 \n\t"
+ " je 2f \n\t"
+
+ "1: \n\t"
+ " movups (%2, %0, 2), %%xmm0 \n\t" /* read 8 floats */
+ " movups 16(%2, %0, 2), %%xmm2 \n\t"
+ " minps %%xmm5, %%xmm0 \n\t" /* clamp to 1.0 */
+ " minps %%xmm5, %%xmm2 \n\t"
+ " maxps %%xmm6, %%xmm0 \n\t" /* clamp to -1.0 */
+ " maxps %%xmm6, %%xmm2 \n\t"
+ " mulps %%xmm7, %%xmm0 \n\t" /* *= 0x7fff */
+ " mulps %%xmm7, %%xmm2 \n\t"
+
+ " cvtps2dq %%xmm0, %%xmm0 \n\t"
+ " cvtps2dq %%xmm2, %%xmm2 \n\t"
+
+ " packssdw %%xmm2, %%xmm0 \n\t"
+ " movdqu %%xmm0, (%3, %0) \n\t"
+
+ " add $16, %0 \n\t"
+ " dec %1 \n\t"
+ " jne 1b \n\t"
+
+ "2: \n\t"
+ " mov %4, %1 \n\t" /* prepare for leftovers */
+ " and $7, %1 \n\t"
+ " je 4f \n\t"
+
+ "3: \n\t"
+ " movss (%2, %0, 2), %%xmm0 \n\t"
+ " minss %%xmm5, %%xmm0 \n\t"
+ " maxss %%xmm6, %%xmm0 \n\t"
+ " mulss %%xmm7, %%xmm0 \n\t"
+ " cvtss2si %%xmm0, %4 \n\t"
+ " movw %w4, (%3, %0) \n\t"
+ " add $2, %0 \n\t"
+ " dec %1 \n\t"
+ " jne 3b \n\t"
+
+ "4: \n\t"
+
+ : "=&r" (i), "=&r" (temp)
+ : "r" (a), "r" (b), "r" ((pa_reg_x86)n), "m" (*one), "m" (*mone), "m" (*scale)
+ : "cc", "memory"
+ );
+}
+
+#undef RUN_TEST
+
+#ifdef RUN_TEST
+#define SAMPLES 1019
+#define TIMES 1000
+
+static void run_test(void) {
+ int16_t samples[SAMPLES];
+ int16_t samples_ref[SAMPLES];
+ float floats[SAMPLES];
+ int i;
+ pa_usec_t start, stop;
+ pa_convert_func_t func;
+
+ printf("checking SSE %zd\n", sizeof(samples));
+
+ memset(samples_ref, 0, sizeof(samples_ref));
+ memset(samples, 0, sizeof(samples));
+
+ for (i = 0; i < SAMPLES; i++) {
+ floats[i] = (rand()/(RAND_MAX+2.2)) - 1.1;
+ }
+
+ func = pa_get_convert_from_float32ne_function(PA_SAMPLE_S16LE);
+ func(SAMPLES, floats, samples_ref);
+ pa_sconv_s16le_from_f32ne_sse2(SAMPLES, floats, samples);
+
+ for (i = 0; i < SAMPLES; i++) {
+ if (samples[i] != samples_ref[i]) {
+ printf ("%d: %04x != %04x (%f)\n", i, samples[i], samples_ref[i],
+ floats[i]);
+ }
+ }
+
+ start = pa_rtclock_now();
+ for (i = 0; i < TIMES; i++) {
+ pa_sconv_s16le_from_f32ne_sse2(SAMPLES, floats, samples);
+ }
+ stop = pa_rtclock_now();
+ pa_log_info("SSE: %llu usec.", (long long unsigned int)(stop - start));
+
+ start = pa_rtclock_now();
+ for (i = 0; i < TIMES; i++) {
+ func(SAMPLES, floats, samples_ref);
+ }
+ stop = pa_rtclock_now();
+ pa_log_info("ref: %llu usec.", (long long unsigned int)(stop - start));
+}
+#endif
+#endif /* defined (__i386__) || defined (__amd64__) */
+
+
+void pa_convert_func_init_sse(pa_cpu_x86_flag_t flags) {
+#if !defined(__APPLE__) && defined (__i386__) || defined (__amd64__)
+
+#ifdef RUN_TEST
+ run_test();
+#endif
+
+ if (flags & PA_CPU_X86_SSE2) {
+ pa_log_info("Initialising SSE2 optimized conversions.");
+ pa_set_convert_from_float32ne_function(PA_SAMPLE_S16LE, (pa_convert_func_t) pa_sconv_s16le_from_f32ne_sse2);
+ } else {
+ pa_log_info("Initialising SSE optimized conversions.");
+ pa_set_convert_from_float32ne_function(PA_SAMPLE_S16LE, (pa_convert_func_t) pa_sconv_s16le_from_f32ne_sse);
+ }
+
+#endif /* defined (__i386__) || defined (__amd64__) */
+}
diff --git a/src/pulsecore/semaphore-osx.c b/src/pulsecore/semaphore-osx.c
new file mode 100644
index 00000000..42afd154
--- /dev/null
+++ b/src/pulsecore/semaphore-osx.c
@@ -0,0 +1,62 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Kim Lester <kim@dfusion.com.au>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <Multiprocessing.h>
+
+#include <pulse/xmalloc.h>
+#include <pulsecore/macro.h>
+
+#include "semaphore.h"
+
+struct pa_semaphore {
+ MPSemaphoreID sema;
+};
+
+pa_semaphore* pa_semaphore_new(unsigned int value) {
+ /* NOTE: Can't assume boolean - ie value = 0,1, so use UINT_MAX (boolean more efficient ?) */
+ pa_semaphore *s;
+
+ s = pa_xnew(pa_semaphore, 1);
+ pa_assert_se(MPCreateSemaphore(UINT_MAX, value, &s->sema) == 0);
+
+ return s;
+}
+
+void pa_semaphore_free(pa_semaphore *s) {
+ pa_assert(s);
+ pa_assert_se(MPDeleteSemaphore(s->sema) == 0);
+ pa_xfree(s);
+}
+
+void pa_semaphore_post(pa_semaphore *s) {
+ pa_assert(s);
+ pa_assert_se(MPSignalSemaphore(s->sema) == 0);
+}
+
+void pa_semaphore_wait(pa_semaphore *s) {
+ pa_assert(s);
+ /* should probably check return value (-ve is error), noErr is ok. */
+ pa_assert_se(MPWaitOnSemaphore(s->sema, kDurationForever) == 0);
+}
diff --git a/src/pulsecore/semaphore-win32.c b/src/pulsecore/semaphore-win32.c
index 9ffbde66..c2e00c63 100644
--- a/src/pulsecore/semaphore-win32.c
+++ b/src/pulsecore/semaphore-win32.c
@@ -30,8 +30,7 @@
#include "semaphore.h"
-struct pa_semaphore
-{
+struct pa_semaphore {
HANDLE sema;
};
diff --git a/src/pulsecore/shared.c b/src/pulsecore/shared.c
index edd7b7fe..368a6c3d 100644
--- a/src/pulsecore/shared.c
+++ b/src/pulsecore/shared.c
@@ -24,7 +24,6 @@
#endif
#include <pulse/xmalloc.h>
-#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include "shared.h"
diff --git a/src/pulsecore/shm.c b/src/pulsecore/shm.c
index fab2b3b6..442b698e 100644
--- a/src/pulsecore/shm.c
+++ b/src/pulsecore/shm.c
@@ -39,6 +39,11 @@
#include <sys/mman.h>
#endif
+/* This is deprecated on glibc but is still used by FreeBSD */
+#if !defined(MAP_ANONYMOUS) && defined(MAP_ANON)
+# define MAP_ANONYMOUS MAP_ANON
+#endif
+
#include <pulse/xmalloc.h>
#include <pulse/gccmacro.h>
@@ -55,7 +60,8 @@
#define MADV_REMOVE 9
#endif
-#define MAX_SHM_SIZE (PA_ALIGN(1024*1024*64))
+/* 1 GiB at max */
+#define MAX_SHM_SIZE (PA_ALIGN(1024*1024*1024))
#ifdef __linux__
/* On Linux we know that the shared memory blocks are files in
@@ -84,14 +90,18 @@ struct shm_marker {
#define SHM_MARKER_SIZE PA_ALIGN(sizeof(struct shm_marker))
+#ifdef HAVE_SHM_OPEN
static char *segment_name(char *fn, size_t l, unsigned id) {
pa_snprintf(fn, l, "/pulse-shm-%u", id);
return fn;
}
+#endif
int pa_shm_create_rw(pa_shm *m, size_t size, pa_bool_t shared, mode_t mode) {
+#ifdef HAVE_SHM_OPEN
char fn[32];
int fd = -1;
+#endif
pa_assert(m);
pa_assert(size > 0);
@@ -148,7 +158,11 @@ int pa_shm_create_rw(pa_shm *m, size_t size, pa_bool_t shared, mode_t mode) {
goto fail;
}
- if ((m->ptr = mmap(NULL, PA_PAGE_ALIGN(m->size), PROT_READ|PROT_WRITE, MAP_SHARED, fd, (off_t) 0)) == MAP_FAILED) {
+#ifndef MAP_NORESERVE
+#define MAP_NORESERVE 0
+#endif
+
+ if ((m->ptr = mmap(NULL, PA_PAGE_ALIGN(m->size), PROT_READ|PROT_WRITE, MAP_SHARED|MAP_NORESERVE, fd, (off_t) 0)) == MAP_FAILED) {
pa_log("mmap() failed: %s", pa_cstrerror(errno));
goto fail;
}
@@ -280,7 +294,7 @@ int pa_shm_attach_ro(pa_shm *m, unsigned id) {
segment_name(fn, sizeof(fn), m->id = id);
if ((fd = shm_open(fn, O_RDONLY, 0)) < 0) {
- if (errno != EACCES)
+ if (errno != EACCES && errno != ENOENT)
pa_log("shm_open() failed: %s", pa_cstrerror(errno));
goto fail;
}
diff --git a/src/pulsecore/shmasyncq.h b/src/pulsecore/shmasyncq.h
index 9845c391..4212055e 100644
--- a/src/pulsecore/shmasyncq.h
+++ b/src/pulsecore/shmasyncq.h
@@ -24,7 +24,6 @@
#include <sys/types.h>
-#include <pulse/def.h>
#include <pulsecore/macro.h>
/* Similar to pa_asyncq, but stores data in a shared memory segment */
diff --git a/src/pulsecore/sink-input.c b/src/pulsecore/sink-input.c
index 0d05b00a..d386b005 100644
--- a/src/pulsecore/sink-input.c
+++ b/src/pulsecore/sink-input.c
@@ -26,11 +26,11 @@
#include <stdio.h>
#include <stdlib.h>
-#include <string.h>
#include <pulse/utf8.h>
#include <pulse/xmalloc.h>
#include <pulse/util.h>
+#include <pulse/internal.h>
#include <pulsecore/sample-util.h>
#include <pulsecore/core-subscribe.h>
@@ -44,16 +44,33 @@
#define MEMBLOCKQ_MAXLENGTH (32*1024*1024)
#define CONVERT_BUFFER_LENGTH (PA_PAGE_SIZE)
-static PA_DEFINE_CHECK_TYPE(pa_sink_input, pa_msgobject);
+PA_DEFINE_PUBLIC_CLASS(pa_sink_input, pa_msgobject);
static void sink_input_free(pa_object *o);
+static void set_real_ratio(pa_sink_input *i, const pa_cvolume *v);
+
+static int check_passthrough_connection(pa_bool_t passthrough, pa_sink *dest) {
+ if (pa_sink_is_passthrough(dest)) {
+ pa_log_warn("Sink is already connected to PASSTHROUGH input");
+ return -PA_ERR_BUSY;
+ }
+
+ /* If current input(s) exist, check new input is not PASSTHROUGH */
+ if (pa_idxset_size(dest->inputs) > 0 && passthrough) {
+ pa_log_warn("Sink is already connected, cannot accept new PASSTHROUGH INPUT");
+ return -PA_ERR_BUSY;
+ }
+
+ return PA_OK;
+}
pa_sink_input_new_data* pa_sink_input_new_data_init(pa_sink_input_new_data *data) {
pa_assert(data);
- memset(data, 0, sizeof(*data));
+ pa_zero(*data);
data->resample_method = PA_RESAMPLER_INVALID;
data->proplist = pa_proplist_new();
+ data->volume_writable = TRUE;
return data;
}
@@ -72,8 +89,21 @@ void pa_sink_input_new_data_set_channel_map(pa_sink_input_new_data *data, const
data->channel_map = *map;
}
+pa_bool_t pa_sink_input_new_data_is_passthrough(pa_sink_input_new_data *data) {
+ pa_assert(data);
+
+ if (PA_LIKELY(data->format) && PA_UNLIKELY(!pa_format_info_is_pcm(data->format)))
+ return TRUE;
+
+ if (PA_UNLIKELY(data->flags & PA_SINK_INPUT_PASSTHROUGH))
+ return TRUE;
+
+ return FALSE;
+}
+
void pa_sink_input_new_data_set_volume(pa_sink_input_new_data *data, const pa_cvolume *volume) {
pa_assert(data);
+ pa_assert(data->volume_writable);
if ((data->volume_is_set = !!volume))
data->volume = *volume;
@@ -91,6 +121,18 @@ void pa_sink_input_new_data_apply_volume_factor(pa_sink_input_new_data *data, co
}
}
+void pa_sink_input_new_data_apply_volume_factor_sink(pa_sink_input_new_data *data, const pa_cvolume *volume_factor) {
+ pa_assert(data);
+ pa_assert(volume_factor);
+
+ if (data->volume_factor_sink_is_set)
+ pa_sw_cvolume_multiply(&data->volume_factor_sink, &data->volume_factor_sink, volume_factor);
+ else {
+ data->volume_factor_sink_is_set = TRUE;
+ data->volume_factor_sink = *volume_factor;
+ }
+}
+
void pa_sink_input_new_data_set_muted(pa_sink_input_new_data *data, pa_bool_t mute) {
pa_assert(data);
@@ -98,9 +140,68 @@ void pa_sink_input_new_data_set_muted(pa_sink_input_new_data *data, pa_bool_t mu
data->muted = !!mute;
}
+pa_bool_t pa_sink_input_new_data_set_sink(pa_sink_input_new_data *data, pa_sink *s, pa_bool_t save) {
+ pa_bool_t ret = TRUE;
+ pa_idxset *formats = NULL;
+
+ pa_assert(data);
+ pa_assert(s);
+
+ if (!data->req_formats) {
+ /* We're not working with the extended API */
+ data->sink = s;
+ data->save_sink = save;
+ } else {
+ /* Extended API: let's see if this sink supports the formats the client can provide */
+ formats = pa_sink_check_formats(s, data->req_formats);
+
+ if (formats && !pa_idxset_isempty(formats)) {
+ /* Sink supports at least one of the requested formats */
+ data->sink = s;
+ data->save_sink = save;
+ if (data->nego_formats)
+ pa_idxset_free(data->nego_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ data->nego_formats = formats;
+ } else {
+ /* Sink doesn't support any of the formats requested by the client */
+ if (formats)
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ ret = FALSE;
+ }
+ }
+
+ return ret;
+}
+
+pa_bool_t pa_sink_input_new_data_set_formats(pa_sink_input_new_data *data, pa_idxset *formats) {
+ pa_assert(data);
+ pa_assert(formats);
+
+ if (data->req_formats)
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ data->req_formats = formats;
+
+ if (data->sink) {
+ /* Trigger format negotiation */
+ return pa_sink_input_new_data_set_sink(data, data->sink, data->save_sink);
+ }
+
+ return TRUE;
+}
+
void pa_sink_input_new_data_done(pa_sink_input_new_data *data) {
pa_assert(data);
+ if (data->req_formats)
+ pa_idxset_free(data->req_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ if (data->nego_formats)
+ pa_idxset_free(data->nego_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ if (data->format)
+ pa_format_info_free(data->format);
+
pa_proplist_free(data->proplist);
}
@@ -114,6 +215,7 @@ static void reset_callbacks(pa_sink_input *i) {
i->update_max_request = NULL;
i->update_sink_requested_latency = NULL;
i->update_sink_latency_range = NULL;
+ i->update_sink_fixed_latency = NULL;
i->attach = NULL;
i->detach = NULL;
i->suspend = NULL;
@@ -124,42 +226,86 @@ static void reset_callbacks(pa_sink_input *i) {
i->state_change = NULL;
i->may_move_to = NULL;
i->send_event = NULL;
+ i->volume_changed = NULL;
+ i->mute_changed = NULL;
}
/* Called from main context */
int pa_sink_input_new(
pa_sink_input **_i,
pa_core *core,
- pa_sink_input_new_data *data,
- pa_sink_input_flags_t flags) {
+ pa_sink_input_new_data *data) {
pa_sink_input *i;
pa_resampler *resampler = NULL;
char st[PA_SAMPLE_SPEC_SNPRINT_MAX], cm[PA_CHANNEL_MAP_SNPRINT_MAX];
pa_channel_map original_cm;
int r;
+ char *pt;
+ pa_sample_spec ss;
+ pa_channel_map map;
pa_assert(_i);
pa_assert(core);
pa_assert(data);
+ pa_assert_ctl_context();
if (data->client)
pa_proplist_update(data->proplist, PA_UPDATE_MERGE, data->client->proplist);
+ if (data->origin_sink && (data->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
+ data->volume_writable = FALSE;
+
+ if (!data->req_formats) {
+ /* From this point on, we want to work only with formats, and get back
+ * to using the sample spec and channel map after all decisions w.r.t.
+ * routing are complete. */
+ pa_idxset *tmp = pa_idxset_new(NULL, NULL);
+ pa_format_info *f = pa_format_info_from_sample_spec(&data->sample_spec,
+ data->channel_map_is_set ? &data->channel_map : NULL);
+ pa_idxset_put(tmp, f, NULL);
+ pa_sink_input_new_data_set_formats(data, tmp);
+ }
+
if ((r = pa_hook_fire(&core->hooks[PA_CORE_HOOK_SINK_INPUT_NEW], data)) < 0)
return r;
pa_return_val_if_fail(!data->driver || pa_utf8_valid(data->driver), -PA_ERR_INVALID);
if (!data->sink) {
- data->sink = pa_namereg_get(core, NULL, PA_NAMEREG_SINK);
- data->save_sink = FALSE;
+ pa_sink *sink = pa_namereg_get(core, NULL, PA_NAMEREG_SINK);
+ pa_return_val_if_fail(sink, -PA_ERR_NOENTITY);
+ pa_sink_input_new_data_set_sink(data, sink, FALSE);
+ }
+ /* Routing's done, we have a sink. Now let's fix the format and set up the
+ * sample spec */
+
+ /* If something didn't pick a format for us, pick the top-most format since
+ * we assume this is sorted in priority order */
+ if (!data->format && data->nego_formats && !pa_idxset_isempty(data->nego_formats))
+ data->format = pa_format_info_copy(pa_idxset_first(data->nego_formats, NULL));
+
+ pa_return_val_if_fail(data->format, -PA_ERR_NOTSUPPORTED);
+
+ /* Now populate the sample spec and format according to the final
+ * format that we've negotiated */
+ if (PA_LIKELY(data->format->encoding == PA_ENCODING_PCM)) {
+ pa_return_val_if_fail(pa_format_info_to_sample_spec(data->format, &ss, &map), -PA_ERR_INVALID);
+ pa_sink_input_new_data_set_sample_spec(data, &ss);
+ if (pa_channel_map_valid(&map))
+ pa_sink_input_new_data_set_channel_map(data, &map);
+ } else {
+ pa_return_val_if_fail(pa_format_info_to_sample_spec_fake(data->format, &ss), -PA_ERR_INVALID);
+ pa_sink_input_new_data_set_sample_spec(data, &ss);
}
- pa_return_val_if_fail(data->sink, -PA_ERR_NOENTITY);
pa_return_val_if_fail(PA_SINK_IS_LINKED(pa_sink_get_state(data->sink)), -PA_ERR_BADSTATE);
pa_return_val_if_fail(!data->sync_base || (data->sync_base->sink == data->sink && pa_sink_input_get_state(data->sync_base) == PA_SINK_INPUT_CORKED), -PA_ERR_INVALID);
+ r = check_passthrough_connection(pa_sink_input_new_data_is_passthrough(data), data->sink);
+ if (r != PA_OK)
+ return r;
+
if (!data->sample_spec_is_set)
data->sample_spec = data->sink->sample_spec;
@@ -172,36 +318,44 @@ int pa_sink_input_new(
pa_channel_map_init_extend(&data->channel_map, data->sample_spec.channels, PA_CHANNEL_MAP_DEFAULT);
}
- pa_return_val_if_fail(pa_channel_map_valid(&data->channel_map), -PA_ERR_INVALID);
pa_return_val_if_fail(pa_channel_map_compatible(&data->channel_map, &data->sample_spec), -PA_ERR_INVALID);
+ /* Don't restore (or save) stream volume for passthrough streams */
+ if (!pa_format_info_is_pcm(data->format)) {
+ data->volume_is_set = FALSE;
+ data->volume_factor_is_set = FALSE;
+ }
+
if (!data->volume_is_set) {
pa_cvolume_reset(&data->volume, data->sample_spec.channels);
data->volume_is_absolute = FALSE;
data->save_volume = FALSE;
}
- pa_return_val_if_fail(pa_cvolume_valid(&data->volume), -PA_ERR_INVALID);
pa_return_val_if_fail(pa_cvolume_compatible(&data->volume, &data->sample_spec), -PA_ERR_INVALID);
if (!data->volume_factor_is_set)
pa_cvolume_reset(&data->volume_factor, data->sample_spec.channels);
- pa_return_val_if_fail(pa_cvolume_valid(&data->volume_factor), -PA_ERR_INVALID);
pa_return_val_if_fail(pa_cvolume_compatible(&data->volume_factor, &data->sample_spec), -PA_ERR_INVALID);
+ if (!data->volume_factor_sink_is_set)
+ pa_cvolume_reset(&data->volume_factor_sink, data->sink->sample_spec.channels);
+
+ pa_return_val_if_fail(pa_cvolume_compatible(&data->volume_factor_sink, &data->sink->sample_spec), -PA_ERR_INVALID);
+
if (!data->muted_is_set)
data->muted = FALSE;
- if (flags & PA_SINK_INPUT_FIX_FORMAT)
+ if (data->flags & PA_SINK_INPUT_FIX_FORMAT)
data->sample_spec.format = data->sink->sample_spec.format;
- if (flags & PA_SINK_INPUT_FIX_RATE)
+ if (data->flags & PA_SINK_INPUT_FIX_RATE)
data->sample_spec.rate = data->sink->sample_spec.rate;
original_cm = data->channel_map;
- if (flags & PA_SINK_INPUT_FIX_CHANNELS) {
+ if (data->flags & PA_SINK_INPUT_FIX_CHANNELS) {
data->sample_spec.channels = data->sink->sample_spec.channels;
data->channel_map = data->sink->channel_map;
}
@@ -220,7 +374,7 @@ int pa_sink_input_new(
if ((r = pa_hook_fire(&core->hooks[PA_CORE_HOOK_SINK_INPUT_FIXATE], data)) < 0)
return r;
- if ((flags & PA_SINK_INPUT_FAIL_ON_SUSPEND) &&
+ if ((data->flags & PA_SINK_INPUT_NO_CREATE_ON_SUSPEND) &&
pa_sink_get_state(data->sink) == PA_SINK_SUSPENDED) {
pa_log_warn("Failed to create sink input: sink is suspended.");
return -PA_ERR_BADSTATE;
@@ -231,22 +385,24 @@ int pa_sink_input_new(
return -PA_ERR_TOOLARGE;
}
- if ((flags & PA_SINK_INPUT_VARIABLE_RATE) ||
+ if ((data->flags & PA_SINK_INPUT_VARIABLE_RATE) ||
!pa_sample_spec_equal(&data->sample_spec, &data->sink->sample_spec) ||
!pa_channel_map_equal(&data->channel_map, &data->sink->channel_map)) {
- if (!(resampler = pa_resampler_new(
- core->mempool,
- &data->sample_spec, &data->channel_map,
- &data->sink->sample_spec, &data->sink->channel_map,
- data->resample_method,
- ((flags & PA_SINK_INPUT_VARIABLE_RATE) ? PA_RESAMPLER_VARIABLE_RATE : 0) |
- ((flags & PA_SINK_INPUT_NO_REMAP) ? PA_RESAMPLER_NO_REMAP : 0) |
- (core->disable_remixing || (flags & PA_SINK_INPUT_NO_REMIX) ? PA_RESAMPLER_NO_REMIX : 0) |
- (core->disable_lfe_remixing ? PA_RESAMPLER_NO_LFE : 0)))) {
- pa_log_warn("Unsupported resampling operation.");
- return -PA_ERR_NOTSUPPORTED;
- }
+ /* Note: for passthrough content we need to adjust the output rate to that of the current sink-input */
+ if (!pa_sink_input_new_data_is_passthrough(data)) /* no resampler for passthrough content */
+ if (!(resampler = pa_resampler_new(
+ core->mempool,
+ &data->sample_spec, &data->channel_map,
+ &data->sink->sample_spec, &data->sink->channel_map,
+ data->resample_method,
+ ((data->flags & PA_SINK_INPUT_VARIABLE_RATE) ? PA_RESAMPLER_VARIABLE_RATE : 0) |
+ ((data->flags & PA_SINK_INPUT_NO_REMAP) ? PA_RESAMPLER_NO_REMAP : 0) |
+ (core->disable_remixing || (data->flags & PA_SINK_INPUT_NO_REMIX) ? PA_RESAMPLER_NO_REMIX : 0) |
+ (core->disable_lfe_remixing ? PA_RESAMPLER_NO_LFE : 0)))) {
+ pa_log_warn("Unsupported resampling operation.");
+ return -PA_ERR_NOTSUPPORTED;
+ }
}
i = pa_msgobject_new(pa_sink_input);
@@ -255,31 +411,37 @@ int pa_sink_input_new(
i->core = core;
i->state = PA_SINK_INPUT_INIT;
- i->flags = flags;
+ i->flags = data->flags;
i->proplist = pa_proplist_copy(data->proplist);
i->driver = pa_xstrdup(pa_path_get_filename(data->driver));
i->module = data->module;
i->sink = data->sink;
+ i->origin_sink = data->origin_sink;
i->client = data->client;
i->requested_resample_method = data->resample_method;
i->actual_resample_method = resampler ? pa_resampler_get_method(resampler) : PA_RESAMPLER_INVALID;
i->sample_spec = data->sample_spec;
i->channel_map = data->channel_map;
+ i->format = pa_format_info_copy(data->format);
+
+ if (!data->volume_is_absolute && pa_sink_flat_volume_enabled(i->sink)) {
+ pa_cvolume remapped;
- if ((i->sink->flags & PA_SINK_FLAT_VOLUME) && !data->volume_is_absolute) {
/* When the 'absolute' bool is not set then we'll treat the volume
* as relative to the sink volume even in flat volume mode */
-
- pa_cvolume v = data->sink->reference_volume;
- pa_cvolume_remap(&v, &data->sink->channel_map, &data->channel_map);
- pa_sw_cvolume_multiply(&i->virtual_volume, &data->volume, &v);
+ remapped = data->sink->reference_volume;
+ pa_cvolume_remap(&remapped, &data->sink->channel_map, &data->channel_map);
+ pa_sw_cvolume_multiply(&i->volume, &data->volume, &remapped);
} else
- i->virtual_volume = data->volume;
+ i->volume = data->volume;
i->volume_factor = data->volume_factor;
- pa_cvolume_init(&i->soft_volume);
- memset(i->relative_volume, 0, sizeof(i->relative_volume));
+ i->volume_factor_sink = data->volume_factor_sink;
+ i->real_ratio = i->reference_ratio = data->volume;
+ pa_cvolume_reset(&i->soft_volume, i->sample_spec.channels);
+ pa_cvolume_reset(&i->real_ratio, i->sample_spec.channels);
+ i->volume_writable = data->volume_writable;
i->save_volume = data->save_volume;
i->save_sink = data->save_sink;
i->save_muted = data->save_muted;
@@ -332,12 +494,15 @@ int pa_sink_input_new(
if (i->client)
pa_assert_se(pa_idxset_put(i->client->sink_inputs, i, NULL) >= 0);
- pa_log_info("Created input %u \"%s\" on %s with sample spec %s and channel map %s",
+ pt = pa_proplist_to_string_sep(i->proplist, "\n ");
+ pa_log_info("Created input %u \"%s\" on %s with sample spec %s and channel map %s\n %s",
i->index,
pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_MEDIA_NAME)),
i->sink->name,
pa_sample_spec_snprint(st, sizeof(st), &i->sample_spec),
- pa_channel_map_snprint(cm, sizeof(cm), &i->channel_map));
+ pa_channel_map_snprint(cm, sizeof(cm), &i->channel_map),
+ pt);
+ pa_xfree(pt);
/* Don't forget to call pa_sink_input_put! */
@@ -348,6 +513,7 @@ int pa_sink_input_new(
/* Called from main context */
static void update_n_corked(pa_sink_input *i, pa_sink_input_state_t state) {
pa_assert(i);
+ pa_assert_ctl_context();
if (!i->sink)
return;
@@ -362,6 +528,7 @@ static void update_n_corked(pa_sink_input *i, pa_sink_input_state_t state) {
static void sink_input_set_state(pa_sink_input *i, pa_sink_input_state_t state) {
pa_sink_input *ssync;
pa_assert(i);
+ pa_assert_ctl_context();
if (state == PA_SINK_INPUT_DRAINED)
state = PA_SINK_INPUT_RUNNING;
@@ -391,6 +558,9 @@ static void sink_input_set_state(pa_sink_input *i, pa_sink_input_state_t state)
for (ssync = i->sync_next; ssync; ssync = ssync->sync_next)
pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_STATE_CHANGED], ssync);
+
+ if (PA_SINK_INPUT_IS_LINKED(state))
+ pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
}
pa_sink_update_status(i->sink);
@@ -399,8 +569,10 @@ static void sink_input_set_state(pa_sink_input *i, pa_sink_input_state_t state)
/* Called from main context */
void pa_sink_input_unlink(pa_sink_input *i) {
pa_bool_t linked;
- pa_source_output *o, *p = NULL;
+ pa_source_output *o, *p = NULL;
+
pa_assert(i);
+ pa_assert_ctl_context();
/* See pa_sink_unlink() for a couple of comments how this function
* works */
@@ -439,14 +611,15 @@ void pa_sink_input_unlink(pa_sink_input *i) {
if (linked && i->sink) {
/* We might need to update the sink's volume if we are in flat volume mode. */
- if (i->sink->flags & PA_SINK_FLAT_VOLUME) {
- pa_cvolume new_volume;
- pa_sink_update_flat_volume(i->sink, &new_volume);
- pa_sink_set_volume(i->sink, &new_volume, FALSE, FALSE, FALSE);
- }
+ if (pa_sink_flat_volume_enabled(i->sink))
+ pa_sink_set_volume(i->sink, NULL, FALSE, FALSE);
if (i->sink->asyncmsgq)
pa_assert_se(pa_asyncmsgq_send(i->sink->asyncmsgq, PA_MSGOBJECT(i->sink), PA_SINK_MESSAGE_REMOVE_INPUT, i, 0, NULL) == 0);
+
+ /* We suspend the monitor if there was a passthrough sink, unsuspend now if required */
+ if (pa_sink_input_is_passthrough(i) && i->sink->monitor_source)
+ pa_source_suspend(i->sink->monitor_source, FALSE, PA_SUSPEND_PASSTHROUGH);
}
reset_callbacks(i);
@@ -471,6 +644,7 @@ static void sink_input_free(pa_object *o) {
pa_sink_input* i = PA_SINK_INPUT(o);
pa_assert(i);
+ pa_assert_ctl_context();
pa_assert(pa_sink_input_refcnt(i) == 0);
if (PA_SINK_INPUT_IS_LINKED(i->state))
@@ -478,7 +652,10 @@ static void sink_input_free(pa_object *o) {
pa_log_info("Freeing input %u \"%s\"", i->index, pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_MEDIA_NAME)));
- pa_assert(!i->thread_info.attached);
+ /* Side note: this function must be able to destruct properly any
+ * kind of sink input in any state, even those which are
+ * "half-moved" or are connected to sinks that have no asyncmsgq
+ * and are hence half-destructed themselves! */
if (i->thread_info.render_memblockq)
pa_memblockq_free(i->thread_info.render_memblockq);
@@ -486,6 +663,9 @@ static void sink_input_free(pa_object *o) {
if (i->thread_info.resampler)
pa_resampler_free(i->thread_info.resampler);
+ if (i->format)
+ pa_format_info_free(i->format);
+
if (i->proplist)
pa_proplist_free(i->proplist);
@@ -502,7 +682,9 @@ static void sink_input_free(pa_object *o) {
/* Called from main context */
void pa_sink_input_put(pa_sink_input *i) {
pa_sink_input_state_t state;
+
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(i->state == PA_SINK_INPUT_INIT);
@@ -517,12 +699,20 @@ void pa_sink_input_put(pa_sink_input *i) {
i->state = state;
/* We might need to update the sink's volume if we are in flat volume mode. */
- if (i->sink->flags & PA_SINK_FLAT_VOLUME) {
- pa_cvolume new_volume;
- pa_sink_update_flat_volume(i->sink, &new_volume);
- pa_sink_set_volume(i->sink, &new_volume, FALSE, FALSE, FALSE);
- } else
- pa_sink_input_set_relative_volume(i, &i->virtual_volume);
+ if (pa_sink_flat_volume_enabled(i->sink))
+ pa_sink_set_volume(i->sink, NULL, FALSE, i->save_volume);
+ else {
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)) {
+ pa_assert(pa_cvolume_is_norm(&i->volume));
+ pa_assert(pa_cvolume_is_norm(&i->reference_ratio));
+ }
+
+ set_real_ratio(i, &i->volume);
+ }
+
+ /* If we're entering passthrough mode, disable the monitor */
+ if (pa_sink_input_is_passthrough(i) && i->sink->monitor_source)
+ pa_source_suspend(i->sink->monitor_source, TRUE, PA_SUSPEND_PASSTHROUGH);
i->thread_info.soft_volume = i->soft_volume;
i->thread_info.muted = i->muted;
@@ -538,6 +728,7 @@ void pa_sink_input_put(pa_sink_input *i) {
/* Called from main context */
void pa_sink_input_kill(pa_sink_input*i) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
i->kill(i);
@@ -548,6 +739,7 @@ pa_usec_t pa_sink_input_get_latency(pa_sink_input *i, pa_usec_t *sink_latency) {
pa_usec_t r[2] = { 0, 0 };
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
pa_assert_se(pa_asyncmsgq_send(i->sink->asyncmsgq, PA_MSGOBJECT(i), PA_SINK_INPUT_MESSAGE_GET_LATENCY, r, 0, NULL) == 0);
@@ -563,12 +755,13 @@ pa_usec_t pa_sink_input_get_latency(pa_sink_input *i, pa_usec_t *sink_latency) {
/* Called from thread context */
void pa_sink_input_peek(pa_sink_input *i, size_t slength /* in sink frames */, pa_memchunk *chunk, pa_cvolume *volume) {
- pa_bool_t do_volume_adj_here;
+ pa_bool_t do_volume_adj_here, need_volume_factor_sink;
pa_bool_t volume_is_norm;
size_t block_size_max_sink, block_size_max_sink_input;
size_t ilength;
pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
pa_assert(PA_SINK_INPUT_IS_LINKED(i->thread_info.state));
pa_assert(pa_frame_aligned(slength, &i->sink->sample_spec));
pa_assert(chunk);
@@ -610,6 +803,7 @@ void pa_sink_input_peek(pa_sink_input *i, size_t slength /* in sink frames */, p
do_volume_adj_here = !pa_channel_map_equal(&i->channel_map, &i->sink->channel_map);
volume_is_norm = pa_cvolume_is_norm(&i->thread_info.soft_volume) && !i->thread_info.muted;
+ need_volume_factor_sink = !pa_cvolume_is_norm(&i->volume_factor_sink);
while (!pa_memblockq_is_readable(i->thread_info.render_memblockq)) {
pa_memchunk tchunk;
@@ -641,6 +835,7 @@ void pa_sink_input_peek(pa_sink_input *i, size_t slength /* in sink frames */, p
while (tchunk.length > 0) {
pa_memchunk wchunk;
+ pa_bool_t nvfs = need_volume_factor_sink;
wchunk = tchunk;
pa_memblock_ref(wchunk.memblock);
@@ -652,21 +847,45 @@ void pa_sink_input_peek(pa_sink_input *i, size_t slength /* in sink frames */, p
if (do_volume_adj_here && !volume_is_norm) {
pa_memchunk_make_writable(&wchunk, 0);
- if (i->thread_info.muted)
+ if (i->thread_info.muted) {
pa_silence_memchunk(&wchunk, &i->thread_info.sample_spec);
- else
+ nvfs = FALSE;
+
+ } else if (!i->thread_info.resampler && nvfs) {
+ pa_cvolume v;
+
+ /* If we don't need a resampler we can merge the
+ * post and the pre volume adjustment into one */
+
+ pa_sw_cvolume_multiply(&v, &i->thread_info.soft_volume, &i->volume_factor_sink);
+ pa_volume_memchunk(&wchunk, &i->thread_info.sample_spec, &v);
+ nvfs = FALSE;
+
+ } else
pa_volume_memchunk(&wchunk, &i->thread_info.sample_spec, &i->thread_info.soft_volume);
}
- if (!i->thread_info.resampler)
+ if (!i->thread_info.resampler) {
+
+ if (nvfs) {
+ pa_memchunk_make_writable(&wchunk, 0);
+ pa_volume_memchunk(&wchunk, &i->sink->sample_spec, &i->volume_factor_sink);
+ }
+
pa_memblockq_push_align(i->thread_info.render_memblockq, &wchunk);
- else {
+ } else {
pa_memchunk rchunk;
pa_resampler_run(i->thread_info.resampler, &wchunk, &rchunk);
/* pa_log_debug("pushing %lu", (unsigned long) rchunk.length); */
if (rchunk.memblock) {
+
+ if (nvfs) {
+ pa_memchunk_make_writable(&rchunk, 0);
+ pa_volume_memchunk(&rchunk, &i->sink->sample_spec, &i->volume_factor_sink);
+ }
+
pa_memblockq_push_align(i->thread_info.render_memblockq, &rchunk);
pa_memblock_unref(rchunk.memblock);
}
@@ -706,8 +925,9 @@ void pa_sink_input_peek(pa_sink_input *i, size_t slength /* in sink frames */, p
/* Called from thread context */
void pa_sink_input_drop(pa_sink_input *i, size_t nbytes /* in sink sample spec */) {
- pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
pa_assert(PA_SINK_INPUT_IS_LINKED(i->thread_info.state));
pa_assert(pa_frame_aligned(nbytes, &i->sink->sample_spec));
pa_assert(nbytes > 0);
@@ -721,8 +941,9 @@ void pa_sink_input_drop(pa_sink_input *i, size_t nbytes /* in sink sample spec *
void pa_sink_input_process_rewind(pa_sink_input *i, size_t nbytes /* in sink sample spec */) {
size_t lbq;
pa_bool_t called = FALSE;
- pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
pa_assert(PA_SINK_INPUT_IS_LINKED(i->thread_info.state));
pa_assert(pa_frame_aligned(nbytes, &i->sink->sample_spec));
@@ -740,7 +961,7 @@ void pa_sink_input_process_rewind(pa_sink_input *i, size_t nbytes /* in sink sam
/* We were asked to drop all buffered data, and rerequest new
* data from implementor the next time push() is called */
- pa_memblockq_flush_write(i->thread_info.render_memblockq);
+ pa_memblockq_flush_write(i->thread_info.render_memblockq, TRUE);
} else if (i->thread_info.rewrite_nbytes > 0) {
size_t max_rewrite, amount;
@@ -790,8 +1011,28 @@ void pa_sink_input_process_rewind(pa_sink_input *i, size_t nbytes /* in sink sam
}
/* Called from thread context */
+size_t pa_sink_input_get_max_rewind(pa_sink_input *i) {
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+
+ return i->thread_info.resampler ? pa_resampler_request(i->thread_info.resampler, i->sink->thread_info.max_rewind) : i->sink->thread_info.max_rewind;
+}
+
+/* Called from thread context */
+size_t pa_sink_input_get_max_request(pa_sink_input *i) {
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+
+ /* We're not verifying the status here, to allow this to be called
+ * in the state change handler between _INIT and _RUNNING */
+
+ return i->thread_info.resampler ? pa_resampler_request(i->thread_info.resampler, i->sink->thread_info.max_request) : i->sink->thread_info.max_request;
+}
+
+/* Called from thread context */
void pa_sink_input_update_max_rewind(pa_sink_input *i, size_t nbytes /* in the sink's sample spec */) {
pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
pa_assert(PA_SINK_INPUT_IS_LINKED(i->thread_info.state));
pa_assert(pa_frame_aligned(nbytes, &i->sink->sample_spec));
@@ -804,6 +1045,7 @@ void pa_sink_input_update_max_rewind(pa_sink_input *i, size_t nbytes /* in the
/* Called from thread context */
void pa_sink_input_update_max_request(pa_sink_input *i, size_t nbytes /* in the sink's sample spec */) {
pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
pa_assert(PA_SINK_INPUT_IS_LINKED(i->thread_info.state));
pa_assert(pa_frame_aligned(nbytes, &i->sink->sample_spec));
@@ -814,15 +1056,16 @@ void pa_sink_input_update_max_request(pa_sink_input *i, size_t nbytes /* in the
/* Called from thread context */
pa_usec_t pa_sink_input_set_requested_latency_within_thread(pa_sink_input *i, pa_usec_t usec) {
pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
if (!(i->sink->flags & PA_SINK_DYNAMIC_LATENCY))
- usec = i->sink->fixed_latency;
+ usec = i->sink->thread_info.fixed_latency;
if (usec != (pa_usec_t) -1)
usec = PA_CLAMP(usec, i->sink->thread_info.min_latency, i->sink->thread_info.max_latency);
i->thread_info.requested_sink_latency = usec;
- pa_sink_invalidate_requested_latency(i->sink);
+ pa_sink_invalidate_requested_latency(i->sink, TRUE);
return usec;
}
@@ -830,6 +1073,7 @@ pa_usec_t pa_sink_input_set_requested_latency_within_thread(pa_sink_input *i, pa
/* Called from main context */
pa_usec_t pa_sink_input_set_requested_latency(pa_sink_input *i, pa_usec_t usec) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
if (PA_SINK_INPUT_IS_LINKED(i->state) && i->sink) {
pa_assert_se(pa_asyncmsgq_send(i->sink->asyncmsgq, PA_MSGOBJECT(i), PA_SINK_INPUT_MESSAGE_SET_REQUESTED_LATENCY, &usec, 0, NULL) == 0);
@@ -841,12 +1085,12 @@ pa_usec_t pa_sink_input_set_requested_latency(pa_sink_input *i, pa_usec_t usec)
if (i->sink) {
if (!(i->sink->flags & PA_SINK_DYNAMIC_LATENCY))
- usec = i->sink->fixed_latency;
+ usec = pa_sink_get_fixed_latency(i->sink);
if (usec != (pa_usec_t) -1) {
pa_usec_t min_latency, max_latency;
pa_sink_get_latency_range(i->sink, &min_latency, &max_latency);
- usec = PA_CLAMP(usec, min_latency, max_latency);
+ usec = PA_CLAMP(usec, min_latency, max_latency);
}
}
@@ -858,6 +1102,7 @@ pa_usec_t pa_sink_input_set_requested_latency(pa_sink_input *i, pa_usec_t usec)
/* Called from main context */
pa_usec_t pa_sink_input_get_requested_latency(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
if (PA_SINK_INPUT_IS_LINKED(i->state) && i->sink) {
pa_usec_t usec = 0;
@@ -876,132 +1121,143 @@ void pa_sink_input_set_volume(pa_sink_input *i, const pa_cvolume *volume, pa_boo
pa_cvolume v;
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
pa_assert(volume);
pa_assert(pa_cvolume_valid(volume));
- pa_assert(pa_cvolume_compatible(volume, &i->sample_spec));
+ pa_assert(volume->channels == 1 || pa_cvolume_compatible(volume, &i->sample_spec));
+ pa_assert(i->volume_writable);
- if ((i->sink->flags & PA_SINK_FLAT_VOLUME) && !absolute) {
+ if (!absolute && pa_sink_flat_volume_enabled(i->sink)) {
v = i->sink->reference_volume;
pa_cvolume_remap(&v, &i->sink->channel_map, &i->channel_map);
- volume = pa_sw_cvolume_multiply(&v, &v, volume);
+
+ if (pa_cvolume_compatible(volume, &i->sample_spec))
+ volume = pa_sw_cvolume_multiply(&v, &v, volume);
+ else
+ volume = pa_sw_cvolume_multiply_scalar(&v, &v, pa_cvolume_max(volume));
+ } else {
+ if (!pa_cvolume_compatible(volume, &i->sample_spec)) {
+ v = i->volume;
+ volume = pa_cvolume_scale(&v, pa_cvolume_max(volume));
+ }
}
- if (pa_cvolume_equal(volume, &i->virtual_volume))
+ if (pa_cvolume_equal(volume, &i->volume)) {
+ i->save_volume = i->save_volume || save;
return;
+ }
- i->virtual_volume = *volume;
+ i->volume = *volume;
i->save_volume = save;
- if (i->sink->flags & PA_SINK_FLAT_VOLUME) {
- pa_cvolume new_volume;
-
+ if (pa_sink_flat_volume_enabled(i->sink)) {
/* We are in flat volume mode, so let's update all sink input
* volumes and update the flat volume of the sink */
- pa_sink_update_flat_volume(i->sink, &new_volume);
- pa_sink_set_volume(i->sink, &new_volume, FALSE, TRUE, FALSE);
+ pa_sink_set_volume(i->sink, NULL, TRUE, save);
} else {
-
/* OK, we are in normal volume mode. The volume only affects
* ourselves */
- pa_sink_input_set_relative_volume(i, volume);
-
- /* Hooks have the ability to play games with i->soft_volume */
- pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_SET_VOLUME], i);
+ set_real_ratio(i, volume);
/* Copy the new soft_volume to the thread_info struct */
pa_assert_se(pa_asyncmsgq_send(i->sink->asyncmsgq, PA_MSGOBJECT(i), PA_SINK_INPUT_MESSAGE_SET_SOFT_VOLUME, NULL, 0, NULL) == 0);
}
+ /* The volume changed, let's tell people so */
+ if (i->volume_changed)
+ i->volume_changed(i);
+
/* The virtual volume changed, let's tell people so */
pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
}
/* Called from main context */
-pa_cvolume *pa_sink_input_get_volume(pa_sink_input *i, pa_cvolume *volume, pa_bool_t absolute) {
+static void set_real_ratio(pa_sink_input *i, const pa_cvolume *v) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
+ pa_assert(!v || pa_cvolume_compatible(v, &i->sample_spec));
- if ((i->sink->flags & PA_SINK_FLAT_VOLUME) && !absolute) {
- pa_cvolume v = i->sink->reference_volume;
- pa_cvolume_remap(&v, &i->sink->channel_map, &i->channel_map);
- pa_sw_cvolume_divide(volume, &i->virtual_volume, &v);
- } else
- *volume = i->virtual_volume;
+ /* This basically calculates:
+ *
+ * i->real_ratio := v
+ * i->soft_volume := i->real_ratio * i->volume_factor */
- return volume;
-}
+ if (v)
+ i->real_ratio = *v;
+ else
+ pa_cvolume_reset(&i->real_ratio, i->sample_spec.channels);
-/* Called from main context */
-pa_cvolume *pa_sink_input_get_relative_volume(pa_sink_input *i, pa_cvolume *v) {
- unsigned c;
+ pa_sw_cvolume_multiply(&i->soft_volume, &i->real_ratio, &i->volume_factor);
+ /* We don't copy the data to the thread_info data. That's left for someone else to do */
+}
+/* Called from main or I/O context */
+pa_bool_t pa_sink_input_is_passthrough(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
- pa_assert(v);
- pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
- /* This always returns the relative volume. Converts the float
- * version into a pa_cvolume */
-
- v->channels = i->sample_spec.channels;
+ if (PA_UNLIKELY(!pa_format_info_is_pcm(i->format)))
+ return TRUE;
- for (c = 0; c < v->channels; c++)
- v->values[c] = pa_sw_volume_from_linear(i->relative_volume[c]);
+ if (PA_UNLIKELY(i->flags & PA_SINK_INPUT_PASSTHROUGH))
+ return TRUE;
- return v;
+ return FALSE;
}
/* Called from main context */
-void pa_sink_input_set_relative_volume(pa_sink_input *i, const pa_cvolume *v) {
- unsigned c;
- pa_cvolume _v;
-
+pa_bool_t pa_sink_input_is_volume_readable(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
- pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
- pa_assert(!v || pa_cvolume_compatible(v, &i->sample_spec));
-
- if (!v)
- v = pa_cvolume_reset(&_v, i->sample_spec.channels);
-
- /* This basically calculates:
- *
- * i->relative_volume := v
- * i->soft_volume := i->relative_volume * i->volume_factor */
+ pa_assert_ctl_context();
- i->soft_volume.channels = i->sample_spec.channels;
+ return !pa_sink_input_is_passthrough(i);
+}
- for (c = 0; c < i->sample_spec.channels; c++) {
- i->relative_volume[c] = pa_sw_volume_to_linear(v->values[c]);
+/* Called from main context */
+pa_cvolume *pa_sink_input_get_volume(pa_sink_input *i, pa_cvolume *volume, pa_bool_t absolute) {
+ pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
+ pa_assert(pa_sink_input_is_volume_readable(i));
- i->soft_volume.values[c] = pa_sw_volume_from_linear(
- i->relative_volume[c] *
- pa_sw_volume_to_linear(i->volume_factor.values[c]));
- }
+ if (absolute || !pa_sink_flat_volume_enabled(i->sink))
+ *volume = i->volume;
+ else
+ *volume = i->reference_ratio;
- /* We don't copy the data to the thread_info data. That's left for someone else to do */
+ return volume;
}
/* Called from main context */
void pa_sink_input_set_mute(pa_sink_input *i, pa_bool_t mute, pa_bool_t save) {
- pa_assert(i);
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
- if (!i->muted == !mute)
+ if (!i->muted == !mute) {
+ i->save_muted = i->save_muted || mute;
return;
+ }
i->muted = mute;
i->save_muted = save;
pa_assert_se(pa_asyncmsgq_send(i->sink->asyncmsgq, PA_MSGOBJECT(i), PA_SINK_INPUT_MESSAGE_SET_SOFT_MUTE, NULL, 0, NULL) == 0);
+
+ /* The mute status changed, let's tell people so */
+ if (i->mute_changed)
+ i->mute_changed(i);
+
pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
}
/* Called from main context */
pa_bool_t pa_sink_input_get_mute(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
return i->muted;
@@ -1010,11 +1266,12 @@ pa_bool_t pa_sink_input_get_mute(pa_sink_input *i) {
/* Called from main thread */
void pa_sink_input_update_proplist(pa_sink_input *i, pa_update_mode_t mode, pa_proplist *p) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
if (p)
pa_proplist_update(i->proplist, mode, p);
- if (PA_SINK_IS_LINKED(i->state)) {
+ if (PA_SINK_INPUT_IS_LINKED(i->state)) {
pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_PROPLIST_CHANGED], i);
pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
}
@@ -1023,6 +1280,7 @@ void pa_sink_input_update_proplist(pa_sink_input *i, pa_update_mode_t mode, pa_p
/* Called from main context */
void pa_sink_input_cork(pa_sink_input *i, pa_bool_t b) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
sink_input_set_state(i, b ? PA_SINK_INPUT_CORKED : PA_SINK_INPUT_RUNNING);
@@ -1031,6 +1289,7 @@ void pa_sink_input_cork(pa_sink_input *i, pa_bool_t b) {
/* Called from main context */
int pa_sink_input_set_rate(pa_sink_input *i, uint32_t rate) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
pa_return_val_if_fail(i->thread_info.resampler, -PA_ERR_BADSTATE);
@@ -1049,13 +1308,14 @@ int pa_sink_input_set_rate(pa_sink_input *i, uint32_t rate) {
void pa_sink_input_set_name(pa_sink_input *i, const char *name) {
const char *old;
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
if (!name && !pa_proplist_contains(i->proplist, PA_PROP_MEDIA_NAME))
return;
old = pa_proplist_gets(i->proplist, PA_PROP_MEDIA_NAME);
- if (old && name && !strcmp(old, name))
+ if (old && name && pa_streq(old, name))
return;
if (name)
@@ -1072,6 +1332,7 @@ void pa_sink_input_set_name(pa_sink_input *i, const char *name) {
/* Called from main context */
pa_resample_method_t pa_sink_input_get_resample_method(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
return i->actual_resample_method;
}
@@ -1079,13 +1340,14 @@ pa_resample_method_t pa_sink_input_get_resample_method(pa_sink_input *i) {
/* Called from main context */
pa_bool_t pa_sink_input_may_move(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
if (i->flags & PA_SINK_INPUT_DONT_MOVE)
return FALSE;
if (i->sync_next || i->sync_prev) {
- pa_log_warn("Moving synchronised streams not supported.");
+ pa_log_warn("Moving synchronized streams not supported.");
return FALSE;
}
@@ -1095,6 +1357,7 @@ pa_bool_t pa_sink_input_may_move(pa_sink_input *i) {
/* Called from main context */
pa_bool_t pa_sink_input_may_move_to(pa_sink_input *i, pa_sink *dest) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
pa_sink_assert_ref(dest);
@@ -1109,6 +1372,9 @@ pa_bool_t pa_sink_input_may_move_to(pa_sink_input *i, pa_sink *dest) {
return FALSE;
}
+ if (check_passthrough_connection(pa_sink_input_is_passthrough(i), dest) < 0)
+ return FALSE;
+
if (i->may_move_to)
if (!i->may_move_to(i, dest))
return FALSE;
@@ -1119,10 +1385,10 @@ pa_bool_t pa_sink_input_may_move_to(pa_sink_input *i, pa_sink *dest) {
/* Called from main context */
int pa_sink_input_start_move(pa_sink_input *i) {
pa_source_output *o, *p = NULL;
- pa_sink *origin;
int r;
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
pa_assert(i->sink);
@@ -1132,8 +1398,6 @@ int pa_sink_input_start_move(pa_sink_input *i) {
if ((r = pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_MOVE_START], i)) < 0)
return r;
- origin = i->sink;
-
/* Kill directly connected outputs */
while ((o = pa_idxset_first(i->direct_outputs, NULL))) {
pa_assert(o != p);
@@ -1147,24 +1411,19 @@ int pa_sink_input_start_move(pa_sink_input *i) {
if (pa_sink_input_get_state(i) == PA_SINK_INPUT_CORKED)
pa_assert_se(i->sink->n_corked-- >= 1);
- if (i->sink->flags & PA_SINK_FLAT_VOLUME) {
- pa_cvolume new_volume;
-
- /* Make the virtual volume relative */
- pa_sink_input_get_relative_volume(i, &i->virtual_volume);
-
- /* And reset the the relative volume */
- pa_sink_input_set_relative_volume(i, NULL);
-
+ if (pa_sink_flat_volume_enabled(i->sink))
/* We might need to update the sink's volume if we are in flat
* volume mode. */
- pa_sink_update_flat_volume(i->sink, &new_volume);
- pa_sink_set_volume(i->sink, &new_volume, FALSE, FALSE, FALSE);
- }
+ pa_sink_set_volume(i->sink, NULL, FALSE, FALSE);
pa_assert_se(pa_asyncmsgq_send(i->sink->asyncmsgq, PA_MSGOBJECT(i->sink), PA_SINK_MESSAGE_START_MOVE, i, 0, NULL) == 0);
+ /* We suspend the monitor if there was a passthrough sink, unsuspend now if required */
+ if (pa_sink_input_is_passthrough(i) && i->sink->monitor_source)
+ pa_source_suspend(i->sink->monitor_source, FALSE, PA_SUSPEND_PASSTHROUGH);
+
pa_sink_update_status(i->sink);
+ pa_cvolume_remap(&i->volume_factor_sink, &i->sink->channel_map, &i->channel_map);
i->sink = NULL;
pa_sink_input_unref(i);
@@ -1172,11 +1431,162 @@ int pa_sink_input_start_move(pa_sink_input *i) {
return 0;
}
+/* Called from main context. If i has an origin sink that uses volume sharing,
+ * then also the origin sink and all streams connected to it need to update
+ * their volume - this function does all that by using recursion. */
+static void update_volume_due_to_moving(pa_sink_input *i, pa_sink *dest) {
+ pa_cvolume old_volume;
+
+ pa_assert(i);
+ pa_assert(dest);
+ pa_assert(i->sink); /* The destination sink should already be set. */
+
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)) {
+ pa_sink *root_sink = i->sink;
+ pa_sink_input *origin_sink_input;
+ uint32_t idx;
+
+ while (root_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)
+ root_sink = root_sink->input_to_master->sink;
+
+ if (pa_sink_flat_volume_enabled(i->sink)) {
+ /* Ok, so the origin sink uses volume sharing, and flat volume is
+ * enabled. The volume will have to be updated as follows:
+ *
+ * i->volume := i->sink->real_volume
+ * (handled later by pa_sink_set_volume)
+ * i->reference_ratio := i->volume / i->sink->reference_volume
+ * (handled later by pa_sink_set_volume)
+ * i->real_ratio stays unchanged
+ * (streams whose origin sink uses volume sharing should
+ * always have real_ratio of 0 dB)
+ * i->soft_volume stays unchanged
+ * (streams whose origin sink uses volume sharing should
+ * always have volume_factor as soft_volume, so no change
+ * should be needed) */
+
+ pa_assert(pa_cvolume_is_norm(&i->real_ratio));
+ pa_assert(pa_cvolume_equal(&i->soft_volume, &i->volume_factor));
+
+ /* Notifications will be sent by pa_sink_set_volume(). */
+
+ } else {
+ /* Ok, so the origin sink uses volume sharing, and flat volume is
+ * disabled. The volume will have to be updated as follows:
+ *
+ * i->volume := 0 dB
+ * i->reference_ratio := 0 dB
+ * i->real_ratio stays unchanged
+ * (streams whose origin sink uses volume sharing should
+ * always have real_ratio of 0 dB)
+ * i->soft_volume stays unchanged
+ * (streams whose origin sink uses volume sharing should
+ * always have volume_factor as soft_volume, so no change
+ * should be needed) */
+
+ old_volume = i->volume;
+ pa_cvolume_reset(&i->volume, i->volume.channels);
+ pa_cvolume_reset(&i->reference_ratio, i->reference_ratio.channels);
+ pa_assert(pa_cvolume_is_norm(&i->real_ratio));
+ pa_assert(pa_cvolume_equal(&i->soft_volume, &i->volume_factor));
+
+ /* Notify others about the changed sink input volume. */
+ if (!pa_cvolume_equal(&i->volume, &old_volume)) {
+ if (i->volume_changed)
+ i->volume_changed(i);
+
+ pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
+ }
+ }
+
+ /* Additionally, the origin sink volume needs updating:
+ *
+ * i->origin_sink->reference_volume := root_sink->reference_volume
+ * i->origin_sink->real_volume := root_sink->real_volume
+ * i->origin_sink->soft_volume stays unchanged
+ * (sinks that use volume sharing should always have
+ * soft_volume of 0 dB) */
+
+ old_volume = i->origin_sink->reference_volume;
+
+ i->origin_sink->reference_volume = root_sink->reference_volume;
+ pa_cvolume_remap(&i->origin_sink->reference_volume, &root_sink->channel_map, &i->origin_sink->channel_map);
+
+ i->origin_sink->real_volume = root_sink->real_volume;
+ pa_cvolume_remap(&i->origin_sink->real_volume, &root_sink->channel_map, &i->origin_sink->channel_map);
+
+ pa_assert(pa_cvolume_is_norm(&i->origin_sink->soft_volume));
+
+ /* Notify others about the changed sink volume. If you wonder whether
+ * i->origin_sink->set_volume() should be called somewhere, that's not
+ * the case, because sinks that use volume sharing shouldn't have any
+ * internal volume that set_volume() would update. If you wonder
+ * whether the thread_info variables should be synced, yes, they
+ * should, and it's done by the PA_SINK_MESSAGE_FINISH_MOVE message
+ * handler. */
+ if (!pa_cvolume_equal(&i->origin_sink->reference_volume, &old_volume))
+ pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, i->origin_sink->index);
+
+ /* Recursively update origin sink inputs. */
+ PA_IDXSET_FOREACH(origin_sink_input, i->origin_sink->inputs, idx)
+ update_volume_due_to_moving(origin_sink_input, dest);
+
+ } else {
+ old_volume = i->volume;
+
+ if (pa_sink_flat_volume_enabled(i->sink)) {
+ /* Ok, so this is a regular stream, and flat volume is enabled. The
+ * volume will have to be updated as follows:
+ *
+ * i->volume := i->reference_ratio * i->sink->reference_volume
+ * i->reference_ratio stays unchanged
+ * i->real_ratio := i->volume / i->sink->real_volume
+ * (handled later by pa_sink_set_volume)
+ * i->soft_volume := i->real_ratio * i->volume_factor
+ * (handled later by pa_sink_set_volume) */
+
+ i->volume = i->sink->reference_volume;
+ pa_cvolume_remap(&i->volume, &i->sink->channel_map, &i->channel_map);
+ pa_sw_cvolume_multiply(&i->volume, &i->volume, &i->reference_ratio);
+
+ } else {
+ /* Ok, so this is a regular stream, and flat volume is disabled.
+ * The volume will have to be updated as follows:
+ *
+ * i->volume := i->reference_ratio
+ * i->reference_ratio stays unchanged
+ * i->real_ratio := i->reference_ratio
+ * i->soft_volume := i->real_ratio * i->volume_factor */
+
+ i->volume = i->reference_ratio;
+ i->real_ratio = i->reference_ratio;
+ pa_sw_cvolume_multiply(&i->soft_volume, &i->real_ratio, &i->volume_factor);
+ }
+
+ /* Notify others about the changed sink input volume. */
+ if (!pa_cvolume_equal(&i->volume, &old_volume)) {
+ /* XXX: In case i->sink has flat volume enabled, then real_ratio
+ * and soft_volume are not updated yet. Let's hope that the
+ * callback implementation doesn't care about those variables... */
+ if (i->volume_changed)
+ i->volume_changed(i);
+
+ pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
+ }
+ }
+
+ /* If i->sink == dest, then recursion has finished, and we can finally call
+ * pa_sink_set_volume(), which will do the rest of the updates. */
+ if ((i->sink == dest) && pa_sink_flat_volume_enabled(i->sink))
+ pa_sink_set_volume(i->sink, NULL, FALSE, i->save_volume);
+}
+
/* Called from main context */
int pa_sink_input_finish_move(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
pa_resampler *new_resampler;
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
pa_assert(!i->sink);
pa_sink_assert_ref(dest);
@@ -1184,6 +1594,17 @@ int pa_sink_input_finish_move(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
if (!pa_sink_input_may_move_to(i, dest))
return -PA_ERR_NOTSUPPORTED;
+ if (pa_sink_input_is_passthrough(i) && !pa_sink_check_format(dest, i->format)) {
+ pa_proplist *p = pa_proplist_new();
+ pa_log_debug("New sink doesn't support stream format, sending format-changed and killing");
+ /* Tell the client what device we want to be on if it is going to
+ * reconnect */
+ pa_proplist_sets(p, "device", dest->name);
+ pa_sink_input_send_event(i, PA_STREAM_EVENT_FORMAT_LOST, p);
+ pa_proplist_free(p);
+ return -PA_ERR_NOTSUPPORTED;
+ }
+
if (i->thread_info.resampler &&
pa_sample_spec_equal(pa_resampler_output_sample_spec(i->thread_info.resampler), &dest->sample_spec) &&
pa_channel_map_equal(pa_resampler_output_channel_map(i->thread_info.resampler), &dest->channel_map))
@@ -1195,7 +1616,7 @@ int pa_sink_input_finish_move(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
!pa_sample_spec_equal(&i->sample_spec, &dest->sample_spec) ||
!pa_channel_map_equal(&i->channel_map, &dest->channel_map)) {
- /* Okey, we need a new resampler for the new sink */
+ /* Okay, we need a new resampler for the new sink */
if (!(new_resampler = pa_resampler_new(
i->core->mempool,
@@ -1218,6 +1639,8 @@ int pa_sink_input_finish_move(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
i->save_sink = save;
pa_idxset_put(dest->inputs, pa_sink_input_ref(i), NULL);
+ pa_cvolume_remap(&i->volume_factor_sink, &i->channel_map, &i->sink->channel_map);
+
if (pa_sink_input_get_state(i) == PA_SINK_INPUT_CORKED)
i->sink->n_corked++;
@@ -1239,24 +1662,19 @@ int pa_sink_input_finish_move(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
1,
0,
&i->sink->silence);
+ i->actual_resample_method = new_resampler ? pa_resampler_get_method(new_resampler) : PA_RESAMPLER_INVALID;
}
- pa_sink_update_status(dest);
-
- if (i->sink->flags & PA_SINK_FLAT_VOLUME) {
- pa_cvolume new_volume;
- /* Make relative volume absolute again */
- pa_cvolume t = dest->reference_volume;
- pa_cvolume_remap(&t, &dest->channel_map, &i->channel_map);
- pa_sw_cvolume_multiply(&i->virtual_volume, &i->virtual_volume, &t);
+ pa_sink_update_status(dest);
- /* We might need to update the sink's volume if we are in flat volume mode. */
- pa_sink_update_flat_volume(i->sink, &new_volume);
- pa_sink_set_volume(i->sink, &new_volume, FALSE, FALSE, FALSE);
- }
+ update_volume_due_to_moving(i, dest);
pa_assert_se(pa_asyncmsgq_send(i->sink->asyncmsgq, PA_MSGOBJECT(i->sink), PA_SINK_MESSAGE_FINISH_MOVE, i, 0, NULL) == 0);
+ /* If we're entering passthrough mode, disable the monitor */
+ if (pa_sink_input_is_passthrough(i) && i->sink->monitor_source)
+ pa_source_suspend(i->sink->monitor_source, TRUE, PA_SUSPEND_PASSTHROUGH);
+
pa_log_debug("Successfully moved sink input %i to %s.", i->index, dest->name);
/* Notify everyone */
@@ -1267,10 +1685,29 @@ int pa_sink_input_finish_move(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
}
/* Called from main context */
+void pa_sink_input_fail_move(pa_sink_input *i) {
+
+ pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
+ pa_assert(!i->sink);
+
+ /* Check if someone wants this sink input? */
+ if (pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_MOVE_FAIL], i) == PA_HOOK_STOP)
+ return;
+
+ if (i->moving)
+ i->moving(i, NULL);
+
+ pa_sink_input_kill(i);
+}
+
+/* Called from main context */
int pa_sink_input_move_to(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
int r;
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_INPUT_IS_LINKED(i->state));
pa_assert(i->sink);
pa_sink_assert_ref(dest);
@@ -1289,6 +1726,7 @@ int pa_sink_input_move_to(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
}
if ((r = pa_sink_input_finish_move(i, dest, save)) < 0) {
+ pa_sink_input_fail_move(i);
pa_sink_input_unref(i);
return r;
}
@@ -1301,7 +1739,9 @@ int pa_sink_input_move_to(pa_sink_input *i, pa_sink *dest, pa_bool_t save) {
/* Called from IO thread context */
void pa_sink_input_set_state_within_thread(pa_sink_input *i, pa_sink_input_state_t state) {
pa_bool_t corking, uncorking;
+
pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
if (state == i->thread_info.state)
return;
@@ -1411,6 +1851,7 @@ int pa_sink_input_process_msg(pa_msgobject *o, int code, void *userdata, int64_t
/* Called from main thread */
pa_sink_input_state_t pa_sink_input_get_state(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
if (i->state == PA_SINK_INPUT_RUNNING || i->state == PA_SINK_INPUT_DRAINED)
return pa_atomic_load(&i->thread_info.drained) ? PA_SINK_INPUT_DRAINED : PA_SINK_INPUT_RUNNING;
@@ -1421,6 +1862,7 @@ pa_sink_input_state_t pa_sink_input_get_state(pa_sink_input *i) {
/* Called from IO context */
pa_bool_t pa_sink_input_safe_to_remove(pa_sink_input *i) {
pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
if (PA_SINK_INPUT_IS_LINKED(i->thread_info.state))
return pa_memblockq_is_empty(i->thread_info.render_memblockq);
@@ -1429,7 +1871,13 @@ pa_bool_t pa_sink_input_safe_to_remove(pa_sink_input *i) {
}
/* Called from IO context */
-void pa_sink_input_request_rewind(pa_sink_input *i, size_t nbytes /* in our sample spec */, pa_bool_t rewrite, pa_bool_t flush, pa_bool_t dont_rewind_render) {
+void pa_sink_input_request_rewind(
+ pa_sink_input *i,
+ size_t nbytes /* in our sample spec */,
+ pa_bool_t rewrite,
+ pa_bool_t flush,
+ pa_bool_t dont_rewind_render) {
+
size_t lbq;
/* If 'rewrite' is TRUE the sink is rewound as far as requested
@@ -1444,18 +1892,20 @@ void pa_sink_input_request_rewind(pa_sink_input *i, size_t nbytes /* in our sam
* dont_rewind_render is TRUE then the render memblockq is not
* rewound. */
- pa_sink_input_assert_ref(i);
-
- nbytes = PA_MAX(i->thread_info.rewrite_nbytes, nbytes);
+ /* nbytes = 0 means maximum rewind request */
-/* pa_log_debug("request rewrite %lu", (unsigned long) nbytes); */
+ pa_sink_input_assert_ref(i);
+ pa_sink_input_assert_io_context(i);
+ pa_assert(rewrite || flush);
+ pa_assert(!dont_rewind_render || !rewrite);
/* We don't take rewind requests while we are corked */
if (i->thread_info.state == PA_SINK_INPUT_CORKED)
return;
- pa_assert(rewrite || flush);
- pa_assert(!dont_rewind_render || !rewrite);
+ nbytes = PA_MAX(i->thread_info.rewrite_nbytes, nbytes);
+
+ /* pa_log_debug("request rewrite %zu", nbytes); */
/* Calculate how much we can rewind locally without having to
* touch the sink */
@@ -1475,6 +1925,7 @@ void pa_sink_input_request_rewind(pa_sink_input *i, size_t nbytes /* in our sam
nbytes = pa_resampler_request(i->thread_info.resampler, nbytes);
}
+ /* Remember how much we actually want to rewrite */
if (i->thread_info.rewrite_nbytes != (size_t) -1) {
if (rewrite) {
/* Make sure to not overwrite over underruns */
@@ -1511,8 +1962,11 @@ void pa_sink_input_request_rewind(pa_sink_input *i, size_t nbytes /* in our sam
/* Called from main context */
pa_memchunk* pa_sink_input_get_silence(pa_sink_input *i, pa_memchunk *ret) {
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(ret);
+ /* FIXME: Shouldn't access resampler object from main context! */
+
pa_silence_memchunk_get(
&i->core->silence_cache,
i->core->mempool,
@@ -1529,6 +1983,7 @@ void pa_sink_input_send_event(pa_sink_input *i, const char *event, pa_proplist *
pa_sink_input_send_event_hook_data hook_data;
pa_sink_input_assert_ref(i);
+ pa_assert_ctl_context();
pa_assert(event);
if (!i->send_event)
diff --git a/src/pulsecore/sink-input.h b/src/pulsecore/sink-input.h
index 98144d41..a2330fa4 100644
--- a/src/pulsecore/sink-input.h
+++ b/src/pulsecore/sink-input.h
@@ -28,7 +28,7 @@
typedef struct pa_sink_input pa_sink_input;
#include <pulse/sample.h>
-#include <pulsecore/hook-list.h>
+#include <pulse/format.h>
#include <pulsecore/memblockq.h>
#include <pulsecore/resampler.h>
#include <pulsecore/module.h>
@@ -37,11 +37,12 @@ typedef struct pa_sink_input pa_sink_input;
#include <pulsecore/core.h>
typedef enum pa_sink_input_state {
- PA_SINK_INPUT_INIT, /*< The stream is not active yet, because pa_sink_put() has not been called yet */
+ PA_SINK_INPUT_INIT, /*< The stream is not active yet, because pa_sink_input_put() has not been called yet */
PA_SINK_INPUT_DRAINED, /*< The stream stopped playing because there was no data to play */
PA_SINK_INPUT_RUNNING, /*< The stream is alive and kicking */
PA_SINK_INPUT_CORKED, /*< The stream was corked on user request */
PA_SINK_INPUT_UNLINKED /*< The stream is dead */
+ /* FIXME: we need a state for MOVING here */
} pa_sink_input_state_t;
static inline pa_bool_t PA_SINK_INPUT_IS_LINKED(pa_sink_input_state_t x) {
@@ -58,7 +59,9 @@ typedef enum pa_sink_input_flags {
PA_SINK_INPUT_FIX_RATE = 64,
PA_SINK_INPUT_FIX_CHANNELS = 128,
PA_SINK_INPUT_DONT_INHIBIT_AUTO_SUSPEND = 256,
- PA_SINK_INPUT_FAIL_ON_SUSPEND = 512
+ PA_SINK_INPUT_NO_CREATE_ON_SUSPEND = 512,
+ PA_SINK_INPUT_KILL_ON_SUSPEND = 1024,
+ PA_SINK_INPUT_PASSTHROUGH = 2048
} pa_sink_input_flags_t;
struct pa_sink_input {
@@ -79,7 +82,8 @@ struct pa_sink_input {
pa_module *module; /* may be NULL */
pa_client *client; /* may be NULL */
- pa_sink *sink; /* NULL while we are being moved */
+ pa_sink *sink; /* NULL while we are being moved */
+ pa_sink *origin_sink; /* only set by filter sinks */
/* A sink input may be connected to multiple source outputs
* directly, so that they don't get mixed data of the entire
@@ -88,17 +92,24 @@ struct pa_sink_input {
pa_sample_spec sample_spec;
pa_channel_map channel_map;
+ pa_format_info *format;
pa_sink_input *sync_prev, *sync_next;
/* Also see http://pulseaudio.org/wiki/InternalVolumes */
- pa_cvolume virtual_volume; /* The volume clients are informed about */
- pa_cvolume volume_factor; /* An internally used volume factor that can be used by modules to apply effects and suchlike without having that visible to the outside */
- double relative_volume[PA_CHANNELS_MAX]; /* The calculated volume relative to the sink volume as linear factors. */
- pa_cvolume soft_volume; /* The internal software volume we apply to all PCM data while it passes through. Usually calculated as relative_volume * volume_factor */
+ pa_cvolume volume; /* The volume clients are informed about */
+ pa_cvolume reference_ratio; /* The ratio of the stream's volume to the sink's reference volume */
+ pa_cvolume real_ratio; /* The ratio of the stream's volume to the sink's real volume */
+ pa_cvolume volume_factor; /* An internally used volume factor that can be used by modules to apply effects and suchlike without having that visible to the outside */
+ pa_cvolume soft_volume; /* The internal software volume we apply to all PCM data while it passes through. Usually calculated as real_ratio * volume_factor */
+
+ pa_cvolume volume_factor_sink; /* A second volume factor in format of the sink this stream is connected to */
+
+ pa_bool_t volume_writable:1;
+
pa_bool_t muted:1;
- /* if TRUE then the source we are connected to and/or the volume
+ /* if TRUE then the sink we are connected to and/or the volume
* set is worth remembering, i.e. was explicitly chosen by the
* user and not automatically. module-stream-restore looks for
* this.*/
@@ -137,6 +148,10 @@ struct pa_sink_input {
* from IO context. */
void (*update_sink_latency_range) (pa_sink_input *i); /* may be NULL */
+ /* Called whenver the fixed latency of the sink changes, if there
+ * is one. Called from IO context. */
+ void (*update_sink_fixed_latency) (pa_sink_input *i); /* may be NULL */
+
/* If non-NULL this function is called when the input is first
* connected to a sink or when the rtpoll/asyncmsgq fields
* change. You usually don't need to implement this function
@@ -159,7 +174,9 @@ struct pa_sink_input {
/* If non-NULL called whenever the sink input is moved to a new
* sink. Called from main context after the sink input has been
* detached from the old sink and before it has been attached to
- * the new sink. */
+ * the new sink. If dest is NULL the move was executed in two
+ * phases and the second one failed; the stream will be destroyed
+ * after this call. */
void (*moving) (pa_sink_input *i, pa_sink *dest); /* may be NULL */
/* Supposed to unlink and destroy this stream. Called from main
@@ -182,8 +199,16 @@ struct pa_sink_input {
pa_bool_t (*may_move_to) (pa_sink_input *i, pa_sink *s); /* may be NULL */
/* If non-NULL this function is used to dispatch asynchronous
- * control events. */
- void (*send_event)(pa_sink_input *i, const char *event, pa_proplist* data);
+ * control events. Called from main context. */
+ void (*send_event)(pa_sink_input *i, const char *event, pa_proplist* data); /* may be NULL */
+
+ /* If non-NULL this function is called whenever the sink input
+ * volume changes. Called from main context */
+ void (*volume_changed)(pa_sink_input *i); /* may be NULL */
+
+ /* If non-NULL this function is called whenever the sink input
+ * mute status changes. Called from main context */
+ void (*mute_changed)(pa_sink_input *i); /* may be NULL */
struct {
pa_sink_input_state_t state;
@@ -194,7 +219,7 @@ struct pa_sink_input {
pa_bool_t attached:1; /* True only between ->attach() and ->detach() calls */
- /* 0: rewrite nothing, (size_t) -1: rewrite everything, otherwise how many bytes to rewrite */
+ /* rewrite_nbytes: 0: rewrite nothing, (size_t) -1: rewrite everything, otherwise how many bytes to rewrite */
pa_bool_t rewrite_flush:1, dont_rewind_render:1;
size_t rewrite_nbytes;
uint64_t underrun_for, playing_for;
@@ -217,7 +242,7 @@ struct pa_sink_input {
void *userdata;
};
-PA_DECLARE_CLASS(pa_sink_input);
+PA_DECLARE_PUBLIC_CLASS(pa_sink_input);
#define PA_SINK_INPUT(o) pa_sink_input_cast(o)
enum {
@@ -238,6 +263,8 @@ typedef struct pa_sink_input_send_event_hook_data {
} pa_sink_input_send_event_hook_data;
typedef struct pa_sink_input_new_data {
+ pa_sink_input_flags_t flags;
+
pa_proplist *proplist;
const char *driver;
@@ -245,6 +272,7 @@ typedef struct pa_sink_input_new_data {
pa_client *client;
pa_sink *sink;
+ pa_sink *origin_sink;
pa_resample_method_t resample_method;
@@ -252,27 +280,36 @@ typedef struct pa_sink_input_new_data {
pa_sample_spec sample_spec;
pa_channel_map channel_map;
+ pa_format_info *format;
+ pa_idxset *req_formats;
+ pa_idxset *nego_formats;
- pa_cvolume volume, volume_factor;
+ pa_cvolume volume, volume_factor, volume_factor_sink;
pa_bool_t muted:1;
pa_bool_t sample_spec_is_set:1;
pa_bool_t channel_map_is_set:1;
- pa_bool_t volume_is_set:1, volume_factor_is_set:1;
+ pa_bool_t volume_is_set:1, volume_factor_is_set:1, volume_factor_sink_is_set:1;
pa_bool_t muted_is_set:1;
pa_bool_t volume_is_absolute:1;
+ pa_bool_t volume_writable:1;
+
pa_bool_t save_sink:1, save_volume:1, save_muted:1;
} pa_sink_input_new_data;
pa_sink_input_new_data* pa_sink_input_new_data_init(pa_sink_input_new_data *data);
void pa_sink_input_new_data_set_sample_spec(pa_sink_input_new_data *data, const pa_sample_spec *spec);
void pa_sink_input_new_data_set_channel_map(pa_sink_input_new_data *data, const pa_channel_map *map);
+pa_bool_t pa_sink_input_new_data_is_passthrough(pa_sink_input_new_data *data);
void pa_sink_input_new_data_set_volume(pa_sink_input_new_data *data, const pa_cvolume *volume);
void pa_sink_input_new_data_apply_volume_factor(pa_sink_input_new_data *data, const pa_cvolume *volume_factor);
+void pa_sink_input_new_data_apply_volume_factor_sink(pa_sink_input_new_data *data, const pa_cvolume *volume_factor);
void pa_sink_input_new_data_set_muted(pa_sink_input_new_data *data, pa_bool_t mute);
+pa_bool_t pa_sink_input_new_data_set_sink(pa_sink_input_new_data *data, pa_sink *s, pa_bool_t save);
+pa_bool_t pa_sink_input_new_data_set_formats(pa_sink_input_new_data *data, pa_idxset *formats);
void pa_sink_input_new_data_done(pa_sink_input_new_data *data);
/* To be called by the implementing module only */
@@ -280,8 +317,7 @@ void pa_sink_input_new_data_done(pa_sink_input_new_data *data);
int pa_sink_input_new(
pa_sink_input **i,
pa_core *core,
- pa_sink_input_new_data *data,
- pa_sink_input_flags_t flags);
+ pa_sink_input_new_data *data);
void pa_sink_input_put(pa_sink_input *i);
void pa_sink_input_unlink(pa_sink_input* i);
@@ -303,6 +339,10 @@ void pa_sink_input_cork(pa_sink_input *i, pa_bool_t b);
int pa_sink_input_set_rate(pa_sink_input *i, uint32_t rate);
+/* This returns the sink's fields converted into out sample type */
+size_t pa_sink_input_get_max_rewind(pa_sink_input *i);
+size_t pa_sink_input_get_max_request(pa_sink_input *i);
+
/* Callable by everyone from main thread*/
/* External code may request disconnection with this function */
@@ -310,11 +350,11 @@ void pa_sink_input_kill(pa_sink_input*i);
pa_usec_t pa_sink_input_get_latency(pa_sink_input *i, pa_usec_t *sink_latency);
+pa_bool_t pa_sink_input_is_passthrough(pa_sink_input *i);
+pa_bool_t pa_sink_input_is_volume_readable(pa_sink_input *i);
void pa_sink_input_set_volume(pa_sink_input *i, const pa_cvolume *volume, pa_bool_t save, pa_bool_t absolute);
pa_cvolume *pa_sink_input_get_volume(pa_sink_input *i, pa_cvolume *volume, pa_bool_t absolute);
-pa_cvolume *pa_sink_input_get_relative_volume(pa_sink_input *i, pa_cvolume *v);
-
void pa_sink_input_set_mute(pa_sink_input *i, pa_bool_t mute, pa_bool_t save);
pa_bool_t pa_sink_input_get_mute(pa_sink_input *i);
@@ -333,6 +373,7 @@ pa_bool_t pa_sink_input_may_move_to(pa_sink_input *i, pa_sink *dest); /* may thi
* new sink */
int pa_sink_input_start_move(pa_sink_input *i);
int pa_sink_input_finish_move(pa_sink_input *i, pa_sink *dest, pa_bool_t save);
+void pa_sink_input_fail_move(pa_sink_input *i);
pa_sink_input_state_t pa_sink_input_get_state(pa_sink_input *i);
@@ -356,7 +397,7 @@ pa_bool_t pa_sink_input_safe_to_remove(pa_sink_input *i);
pa_memchunk* pa_sink_input_get_silence(pa_sink_input *i, pa_memchunk *ret);
-/* To be used by sink.c only */
-void pa_sink_input_set_relative_volume(pa_sink_input *i, const pa_cvolume *v);
+#define pa_sink_input_assert_io_context(s) \
+ pa_assert(pa_thread_mq_get() || !PA_SINK_INPUT_IS_LINKED((s)->state))
#endif
diff --git a/src/pulsecore/sink.c b/src/pulsecore/sink.c
index 28b3440c..45761a6c 100644
--- a/src/pulsecore/sink.c
+++ b/src/pulsecore/sink.c
@@ -24,9 +24,9 @@
#include <config.h>
#endif
+#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <stdio.h>
#include <pulse/introspect.h>
#include <pulse/utf8.h>
@@ -34,6 +34,8 @@
#include <pulse/timeval.h>
#include <pulse/util.h>
#include <pulse/i18n.h>
+#include <pulse/rtclock.h>
+#include <pulse/internal.h>
#include <pulsecore/sink-input.h>
#include <pulsecore/namereg.h>
@@ -43,6 +45,7 @@
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/play-memblockq.h>
+#include <pulsecore/flist.h>
#include "sink.h"
@@ -52,14 +55,30 @@
#define ABSOLUTE_MAX_LATENCY (10*PA_USEC_PER_SEC)
#define DEFAULT_FIXED_LATENCY (250*PA_USEC_PER_MSEC)
-static PA_DEFINE_CHECK_TYPE(pa_sink, pa_msgobject);
+PA_DEFINE_PUBLIC_CLASS(pa_sink, pa_msgobject);
+
+struct pa_sink_volume_change {
+ pa_usec_t at;
+ pa_cvolume hw_volume;
+
+ PA_LLIST_FIELDS(pa_sink_volume_change);
+};
+
+struct sink_message_set_port {
+ pa_device_port *port;
+ int ret;
+};
static void sink_free(pa_object *s);
+static void pa_sink_volume_change_push(pa_sink *s);
+static void pa_sink_volume_change_flush(pa_sink *s);
+static void pa_sink_volume_change_rewind(pa_sink *s, size_t nbytes);
+
pa_sink_new_data* pa_sink_new_data_init(pa_sink_new_data *data) {
pa_assert(data);
- memset(data, 0, sizeof(*data));
+ pa_zero(*data);
data->proplist = pa_proplist_new();
return data;
@@ -100,11 +119,51 @@ void pa_sink_new_data_set_muted(pa_sink_new_data *data, pa_bool_t mute) {
data->muted = !!mute;
}
+void pa_sink_new_data_set_port(pa_sink_new_data *data, const char *port) {
+ pa_assert(data);
+
+ pa_xfree(data->active_port);
+ data->active_port = pa_xstrdup(port);
+}
+
void pa_sink_new_data_done(pa_sink_new_data *data) {
pa_assert(data);
- pa_xfree(data->name);
pa_proplist_free(data->proplist);
+
+ if (data->ports) {
+ pa_device_port *p;
+
+ while ((p = pa_hashmap_steal_first(data->ports)))
+ pa_device_port_free(p);
+
+ pa_hashmap_free(data->ports, NULL, NULL);
+ }
+
+ pa_xfree(data->name);
+ pa_xfree(data->active_port);
+}
+
+pa_device_port *pa_device_port_new(const char *name, const char *description, size_t extra) {
+ pa_device_port *p;
+
+ pa_assert(name);
+
+ p = pa_xmalloc(PA_ALIGN(sizeof(pa_device_port)) + extra);
+ p->name = pa_xstrdup(name);
+ p->description = pa_xstrdup(description);
+
+ p->priority = 0;
+
+ return p;
+}
+
+void pa_device_port_free(pa_device_port *p) {
+ pa_assert(p);
+
+ pa_xfree(p->name);
+ pa_xfree(p->description);
+ pa_xfree(p);
}
/* Called from main context */
@@ -118,6 +177,8 @@ static void reset_callbacks(pa_sink *s) {
s->set_mute = NULL;
s->request_rewind = NULL;
s->update_requested_latency = NULL;
+ s->set_port = NULL;
+ s->get_formats = NULL;
}
/* Called from main context */
@@ -136,10 +197,12 @@ pa_sink* pa_sink_new(
pa_assert(core);
pa_assert(data);
pa_assert(data->name);
+ pa_assert_ctl_context();
s = pa_msgobject_new(pa_sink);
if (!(name = pa_namereg_register(core, data->name, PA_NAMEREG_SINK, s, data->namereg_fail))) {
+ pa_log_debug("Failed to register name %s.", data->name);
pa_xfree(s);
return NULL;
}
@@ -152,6 +215,8 @@ pa_sink* pa_sink_new(
return NULL;
}
+ /* FIXME, need to free s here on failure */
+
pa_return_null_if_fail(!data->driver || pa_utf8_valid(data->driver));
pa_return_null_if_fail(data->name && pa_utf8_valid(data->name) && data->name[0]);
@@ -163,11 +228,17 @@ pa_sink* pa_sink_new(
pa_return_null_if_fail(pa_channel_map_valid(&data->channel_map));
pa_return_null_if_fail(data->channel_map.channels == data->sample_spec.channels);
- if (!data->volume_is_set)
+ /* FIXME: There should probably be a general function for checking whether
+ * the sink volume is allowed to be set, like there is for sink inputs. */
+ pa_assert(!data->volume_is_set || !(flags & PA_SINK_SHARE_VOLUME_WITH_MASTER));
+
+ if (!data->volume_is_set) {
pa_cvolume_reset(&data->volume, data->sample_spec.channels);
+ data->save_volume = FALSE;
+ }
pa_return_null_if_fail(pa_cvolume_valid(&data->volume));
- pa_return_null_if_fail(data->volume.channels == data->sample_spec.channels);
+ pa_return_null_if_fail(pa_cvolume_compatible(&data->volume, &data->sample_spec));
if (!data->muted_is_set)
data->muted = FALSE;
@@ -177,6 +248,7 @@ pa_sink* pa_sink_new(
pa_device_init_description(data->proplist);
pa_device_init_icon(data->proplist, TRUE);
+ pa_device_init_intended_roles(data->proplist);
if (pa_hook_fire(&core->hooks[PA_CORE_HOOK_SINK_FIXATE], data) < 0) {
pa_xfree(s);
@@ -190,32 +262,58 @@ pa_sink* pa_sink_new(
s->core = core;
s->state = PA_SINK_INIT;
s->flags = flags;
+ s->priority = 0;
+ s->suspend_cause = 0;
s->name = pa_xstrdup(name);
s->proplist = pa_proplist_copy(data->proplist);
s->driver = pa_xstrdup(pa_path_get_filename(data->driver));
s->module = data->module;
s->card = data->card;
+ s->priority = pa_device_init_priority(s->proplist);
+
s->sample_spec = data->sample_spec;
s->channel_map = data->channel_map;
s->inputs = pa_idxset_new(NULL, NULL);
s->n_corked = 0;
+ s->input_to_master = NULL;
- s->reference_volume = s->virtual_volume = data->volume;
+ s->reference_volume = s->real_volume = data->volume;
pa_cvolume_reset(&s->soft_volume, s->sample_spec.channels);
s->base_volume = PA_VOLUME_NORM;
s->n_volume_steps = PA_VOLUME_NORM+1;
s->muted = data->muted;
s->refresh_volume = s->refresh_muted = FALSE;
- s->fixed_latency = flags & PA_SINK_DYNAMIC_LATENCY ? 0 : DEFAULT_FIXED_LATENCY;
-
reset_callbacks(s);
s->userdata = NULL;
s->asyncmsgq = NULL;
- s->rtpoll = NULL;
+
+ /* As a minor optimization we just steal the list instead of
+ * copying it here */
+ s->ports = data->ports;
+ data->ports = NULL;
+
+ s->active_port = NULL;
+ s->save_port = FALSE;
+
+ if (data->active_port && s->ports)
+ if ((s->active_port = pa_hashmap_get(s->ports, data->active_port)))
+ s->save_port = data->save_port;
+
+ if (!s->active_port && s->ports) {
+ void *state;
+ pa_device_port *p;
+
+ PA_HASHMAP_FOREACH(p, s->ports, state)
+ if (!s->active_port || p->priority > s->active_port->priority)
+ s->active_port = p;
+ }
+
+ s->save_volume = data->save_volume;
+ s->save_muted = data->save_muted;
pa_silence_memchunk_get(
&core->silence_cache,
@@ -224,6 +322,7 @@ pa_sink* pa_sink_new(
&s->sample_spec,
0);
+ s->thread_info.rtpoll = NULL;
s->thread_info.inputs = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
s->thread_info.soft_volume = s->soft_volume;
s->thread_info.soft_muted = s->muted;
@@ -236,7 +335,15 @@ pa_sink* pa_sink_new(
s->thread_info.requested_latency = 0;
s->thread_info.min_latency = ABSOLUTE_MIN_LATENCY;
s->thread_info.max_latency = ABSOLUTE_MAX_LATENCY;
+ s->thread_info.fixed_latency = flags & PA_SINK_DYNAMIC_LATENCY ? 0 : DEFAULT_FIXED_LATENCY;
+
+ PA_LLIST_HEAD_INIT(pa_sink_volume_change, s->thread_info.volume_changes);
+ s->thread_info.volume_changes_tail = NULL;
+ pa_sw_cvolume_multiply(&s->thread_info.current_hw_volume, &s->soft_volume, &s->real_volume);
+ s->thread_info.volume_change_safety_margin = core->sync_volume_safety_margin_usec;
+ s->thread_info.volume_change_extra_delay = core->sync_volume_extra_delay_usec;
+ /* FIXME: This should probably be moved to pa_sink_put() */
pa_assert_se(pa_idxset_put(core->sinks, s, &s->index) >= 0);
if (s->card)
@@ -278,6 +385,7 @@ pa_sink* pa_sink_new(
s->monitor_source->monitor_of = s;
pa_source_set_latency_range(s->monitor_source, s->thread_info.min_latency, s->thread_info.max_latency);
+ pa_source_set_fixed_latency(s->monitor_source, s->thread_info.fixed_latency);
pa_source_set_max_rewind(s->monitor_source, s->thread_info.max_rewind);
return s;
@@ -290,6 +398,7 @@ static int sink_set_state(pa_sink *s, pa_sink_state_t state) {
pa_sink_state_t original_state;
pa_assert(s);
+ pa_assert_ctl_context();
if (s->state == state)
return 0;
@@ -326,9 +435,9 @@ static int sink_set_state(pa_sink *s, pa_sink_state_t state) {
/* We're suspending or resuming, tell everyone about it */
- for (i = PA_SINK_INPUT(pa_idxset_first(s->inputs, &idx)); i; i = PA_SINK_INPUT(pa_idxset_next(s->inputs, &idx)))
+ PA_IDXSET_FOREACH(i, s->inputs, idx)
if (s->state == PA_SINK_SUSPENDED &&
- (i->flags & PA_SINK_INPUT_FAIL_ON_SUSPEND))
+ (i->flags & PA_SINK_INPUT_KILL_ON_SUSPEND))
pa_sink_input_kill(i);
else if (i->suspend)
i->suspend(i, state == PA_SINK_SUSPENDED);
@@ -343,34 +452,66 @@ static int sink_set_state(pa_sink *s, pa_sink_state_t state) {
/* Called from main context */
void pa_sink_put(pa_sink* s) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(s->state == PA_SINK_INIT);
+ pa_assert(!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER) || s->input_to_master);
/* The following fields must be initialized properly when calling _put() */
pa_assert(s->asyncmsgq);
- pa_assert(s->rtpoll);
pa_assert(s->thread_info.min_latency <= s->thread_info.max_latency);
/* Generally, flags should be initialized via pa_sink_new(). As a
* special exception we allow volume related flags to be set
* between _new() and _put(). */
- if (!(s->flags & PA_SINK_HW_VOLUME_CTRL))
+ /* XXX: Currently decibel volume is disabled for all sinks that use volume
+ * sharing. When the master sink supports decibel volume, it would be good
+ * to have the flag also in the filter sink, but currently we don't do that
+ * so that the flags of the filter sink never change when it's moved from
+ * a master sink to another. One solution for this problem would be to
+ * remove user-visible volume altogether from filter sinks when volume
+ * sharing is used, but the current approach was easier to implement... */
+ if (!(s->flags & PA_SINK_HW_VOLUME_CTRL) && !(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
s->flags |= PA_SINK_DECIBEL_VOLUME;
if ((s->flags & PA_SINK_DECIBEL_VOLUME) && s->core->flat_volumes)
s->flags |= PA_SINK_FLAT_VOLUME;
+ if (s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER) {
+ pa_sink *root_sink = s->input_to_master->sink;
+
+ while (root_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)
+ root_sink = root_sink->input_to_master->sink;
+
+ s->reference_volume = root_sink->reference_volume;
+ pa_cvolume_remap(&s->reference_volume, &root_sink->channel_map, &s->channel_map);
+
+ s->real_volume = root_sink->real_volume;
+ pa_cvolume_remap(&s->real_volume, &root_sink->channel_map, &s->channel_map);
+ } else
+ /* We assume that if the sink implementor changed the default
+ * volume he did so in real_volume, because that is the usual
+ * place where he is supposed to place his changes. */
+ s->reference_volume = s->real_volume;
+
s->thread_info.soft_volume = s->soft_volume;
s->thread_info.soft_muted = s->muted;
+ pa_sw_cvolume_multiply(&s->thread_info.current_hw_volume, &s->soft_volume, &s->real_volume);
- pa_assert((s->flags & PA_SINK_HW_VOLUME_CTRL) || (s->base_volume == PA_VOLUME_NORM && s->flags & PA_SINK_DECIBEL_VOLUME));
+ pa_assert((s->flags & PA_SINK_HW_VOLUME_CTRL)
+ || (s->base_volume == PA_VOLUME_NORM
+ && ((s->flags & PA_SINK_DECIBEL_VOLUME || (s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)))));
pa_assert(!(s->flags & PA_SINK_DECIBEL_VOLUME) || s->n_volume_steps == PA_VOLUME_NORM+1);
- pa_assert(!(s->flags & PA_SINK_DYNAMIC_LATENCY) == (s->fixed_latency != 0));
+ pa_assert(!(s->flags & PA_SINK_DYNAMIC_LATENCY) == (s->thread_info.fixed_latency != 0));
pa_assert(!(s->flags & PA_SINK_LATENCY) == !(s->monitor_source->flags & PA_SOURCE_LATENCY));
pa_assert(!(s->flags & PA_SINK_DYNAMIC_LATENCY) == !(s->monitor_source->flags & PA_SOURCE_DYNAMIC_LATENCY));
+ pa_assert(!(s->flags & PA_SINK_HW_VOLUME_CTRL) || s->set_volume);
+ pa_assert(!(s->flags & PA_SINK_SYNC_VOLUME) || (s->flags & PA_SINK_HW_VOLUME_CTRL));
+ pa_assert(!(s->flags & PA_SINK_SYNC_VOLUME) || s->write_volume);
+ pa_assert(!(s->flags & PA_SINK_HW_MUTE_CTRL) || s->set_mute);
- pa_assert(s->monitor_source->fixed_latency == s->fixed_latency);
+ pa_assert(s->monitor_source->thread_info.fixed_latency == s->thread_info.fixed_latency);
pa_assert(s->monitor_source->thread_info.min_latency == s->thread_info.min_latency);
pa_assert(s->monitor_source->thread_info.max_latency == s->thread_info.max_latency);
@@ -388,6 +529,7 @@ void pa_sink_unlink(pa_sink* s) {
pa_sink_input *i, *j = NULL;
pa_assert(s);
+ pa_assert_ctl_context();
/* Please note that pa_sink_unlink() does more than simply
* reversing pa_sink_put(). It also undoes the registrations
@@ -437,6 +579,7 @@ static void sink_free(pa_object *o) {
pa_sink_input *i;
pa_assert(s);
+ pa_assert_ctl_context();
pa_assert(pa_sink_refcnt(s) == 0);
if (PA_SINK_IS_LINKED(s->state))
@@ -465,12 +608,22 @@ static void sink_free(pa_object *o) {
if (s->proplist)
pa_proplist_free(s->proplist);
+ if (s->ports) {
+ pa_device_port *p;
+
+ while ((p = pa_hashmap_steal_first(s->ports)))
+ pa_device_port_free(p);
+
+ pa_hashmap_free(s->ports, NULL, NULL);
+ }
+
pa_xfree(s);
}
-/* Called from main context */
+/* Called from main context, and not while the IO thread is active, please */
void pa_sink_set_asyncmsgq(pa_sink *s, pa_asyncmsgq *q) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
s->asyncmsgq = q;
@@ -478,11 +631,33 @@ void pa_sink_set_asyncmsgq(pa_sink *s, pa_asyncmsgq *q) {
pa_source_set_asyncmsgq(s->monitor_source, q);
}
-/* Called from main context */
+/* Called from main context, and not while the IO thread is active, please */
+void pa_sink_update_flags(pa_sink *s, pa_sink_flags_t mask, pa_sink_flags_t value) {
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+
+ if (mask == 0)
+ return;
+
+ /* For now, allow only a minimal set of flags to be changed. */
+ pa_assert((mask & ~(PA_SINK_DYNAMIC_LATENCY|PA_SINK_LATENCY)) == 0);
+
+ s->flags = (s->flags & ~mask) | (value & mask);
+
+ pa_source_update_flags(s->monitor_source,
+ ((mask & PA_SINK_LATENCY) ? PA_SOURCE_LATENCY : 0) |
+ ((mask & PA_SINK_DYNAMIC_LATENCY) ? PA_SOURCE_DYNAMIC_LATENCY : 0),
+ ((value & PA_SINK_LATENCY) ? PA_SOURCE_LATENCY : 0) |
+ ((value & PA_SINK_DYNAMIC_LATENCY) ? PA_SINK_DYNAMIC_LATENCY : 0));
+}
+
+/* Called from IO context, or before _put() from main context */
void pa_sink_set_rtpoll(pa_sink *s, pa_rtpoll *p) {
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
+
+ s->thread_info.rtpoll = p;
- s->rtpoll = p;
if (s->monitor_source)
pa_source_set_rtpoll(s->monitor_source, p);
}
@@ -490,6 +665,7 @@ void pa_sink_set_rtpoll(pa_sink *s, pa_rtpoll *p) {
/* Called from main context */
int pa_sink_update_status(pa_sink*s) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
if (s->state == PA_SINK_SUSPENDED)
@@ -499,26 +675,42 @@ int pa_sink_update_status(pa_sink*s) {
}
/* Called from main context */
-int pa_sink_suspend(pa_sink *s, pa_bool_t suspend) {
+int pa_sink_suspend(pa_sink *s, pa_bool_t suspend, pa_suspend_cause_t cause) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
+ pa_assert(cause != 0);
- if (suspend)
+ if (suspend) {
+ s->suspend_cause |= cause;
+ s->monitor_source->suspend_cause |= cause;
+ } else {
+ s->suspend_cause &= ~cause;
+ s->monitor_source->suspend_cause &= ~cause;
+ }
+
+ if ((pa_sink_get_state(s) == PA_SINK_SUSPENDED) == !!s->suspend_cause)
+ return 0;
+
+ pa_log_debug("Suspend cause of sink %s is 0x%04x, %s", s->name, s->suspend_cause, s->suspend_cause ? "suspending" : "resuming");
+
+ if (s->suspend_cause)
return sink_set_state(s, PA_SINK_SUSPENDED);
else
return sink_set_state(s, pa_sink_used_by(s) ? PA_SINK_RUNNING : PA_SINK_IDLE);
}
/* Called from main context */
-pa_queue *pa_sink_move_all_start(pa_sink *s) {
- pa_queue *q;
+pa_queue *pa_sink_move_all_start(pa_sink *s, pa_queue *q) {
pa_sink_input *i, *n;
uint32_t idx;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
- q = pa_queue_new();
+ if (!q)
+ q = pa_queue_new();
for (i = PA_SINK_INPUT(pa_idxset_first(s->inputs, &idx)); i; i = n) {
n = PA_SINK_INPUT(pa_idxset_next(s->inputs, &idx));
@@ -539,12 +731,13 @@ void pa_sink_move_all_finish(pa_sink *s, pa_queue *q, pa_bool_t save) {
pa_sink_input *i;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
pa_assert(q);
while ((i = PA_SINK_INPUT(pa_queue_pop(q)))) {
if (pa_sink_input_finish_move(i, s, save) < 0)
- pa_sink_input_kill(i);
+ pa_sink_input_fail_move(i);
pa_sink_input_unref(i);
}
@@ -555,13 +748,13 @@ void pa_sink_move_all_finish(pa_sink *s, pa_queue *q, pa_bool_t save) {
/* Called from main context */
void pa_sink_move_all_fail(pa_queue *q) {
pa_sink_input *i;
+
+ pa_assert_ctl_context();
pa_assert(q);
while ((i = PA_SINK_INPUT(pa_queue_pop(q)))) {
- if (pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_MOVE_FAIL], i) == PA_HOOK_OK) {
- pa_sink_input_kill(i);
- pa_sink_input_unref(i);
- }
+ pa_sink_input_fail_move(i);
+ pa_sink_input_unref(i);
}
pa_queue_free(q, NULL, NULL);
@@ -571,11 +764,15 @@ void pa_sink_move_all_fail(pa_queue *q) {
void pa_sink_process_rewind(pa_sink *s, size_t nbytes) {
pa_sink_input *i;
void *state = NULL;
+
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
/* If nobody requested this and this is actually no real rewind
- * then we can short cut this */
+ * then we can short cut this. Please note that this means that
+ * not all rewind requests triggered upstream will always be
+ * translated in actual requests! */
if (!s->thread_info.rewind_requested && nbytes <= 0)
return;
@@ -585,17 +782,21 @@ void pa_sink_process_rewind(pa_sink *s, size_t nbytes) {
if (s->thread_info.state == PA_SINK_SUSPENDED)
return;
- if (nbytes > 0)
+ if (nbytes > 0) {
pa_log_debug("Processing rewind...");
+ if (s->flags & PA_SINK_SYNC_VOLUME)
+ pa_sink_volume_change_rewind(s, nbytes);
+ }
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL))) {
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state) {
pa_sink_input_assert_ref(i);
pa_sink_input_process_rewind(i, nbytes);
}
- if (nbytes > 0)
+ if (nbytes > 0) {
if (s->monitor_source && PA_SOURCE_IS_LINKED(s->monitor_source->thread_info.state))
pa_source_process_rewind(s->monitor_source, nbytes);
+ }
}
/* Called from IO thread context */
@@ -606,6 +807,7 @@ static unsigned fill_mix_info(pa_sink *s, size_t *length, pa_mix_info *info, uns
size_t mixlength = *length;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(info);
while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)) && maxinfo > 0) {
@@ -640,18 +842,19 @@ static unsigned fill_mix_info(pa_sink *s, size_t *length, pa_mix_info *info, uns
/* Called from IO thread context */
static void inputs_drop(pa_sink *s, pa_mix_info *info, unsigned n, pa_memchunk *result) {
pa_sink_input *i;
- void *state = NULL;
+ void *state;
unsigned p = 0;
unsigned n_unreffed = 0;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(result);
pa_assert(result->memblock);
pa_assert(result->length > 0);
/* We optimize for the case where the order of the inputs has not changed */
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL))) {
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state) {
unsigned j;
pa_mix_info* m = NULL;
@@ -740,12 +943,11 @@ void pa_sink_render(pa_sink*s, size_t length, pa_memchunk *result) {
size_t block_size_max;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
pa_assert(pa_frame_aligned(length, &s->sample_spec));
pa_assert(result);
- pa_sink_ref(s);
-
pa_assert(!s->thread_info.rewind_requested);
pa_assert(s->thread_info.rewind_nbytes == 0);
@@ -756,6 +958,8 @@ void pa_sink_render(pa_sink*s, size_t length, pa_memchunk *result) {
return;
}
+ pa_sink_ref(s);
+
if (length <= 0)
length = pa_frame_align(MIX_BUFFER_LENGTH, &s->sample_spec);
@@ -786,18 +990,16 @@ void pa_sink_render(pa_sink*s, size_t length, pa_memchunk *result) {
pa_sw_cvolume_multiply(&volume, &s->thread_info.soft_volume, &info[0].volume);
- if (s->thread_info.soft_muted || !pa_cvolume_is_norm(&volume)) {
- if (s->thread_info.soft_muted || pa_cvolume_is_muted(&volume)) {
- pa_memblock_unref(result->memblock);
- pa_silence_memchunk_get(&s->core->silence_cache,
- s->core->mempool,
- result,
- &s->sample_spec,
- result->length);
- } else {
- pa_memchunk_make_writable(result, 0);
- pa_volume_memchunk(result, &s->sample_spec, &volume);
- }
+ if (s->thread_info.soft_muted || pa_cvolume_is_muted(&volume)) {
+ pa_memblock_unref(result->memblock);
+ pa_silence_memchunk_get(&s->core->silence_cache,
+ s->core->mempool,
+ result,
+ &s->sample_spec,
+ result->length);
+ } else if (!pa_cvolume_is_norm(&volume)) {
+ pa_memchunk_make_writable(result, 0);
+ pa_volume_memchunk(result, &s->sample_spec, &volume);
}
} else {
void *ptr;
@@ -826,14 +1028,13 @@ void pa_sink_render_into(pa_sink*s, pa_memchunk *target) {
size_t length, block_size_max;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
pa_assert(target);
pa_assert(target->memblock);
pa_assert(target->length > 0);
pa_assert(pa_frame_aligned(target->length, &s->sample_spec));
- pa_sink_ref(s);
-
pa_assert(!s->thread_info.rewind_requested);
pa_assert(s->thread_info.rewind_nbytes == 0);
@@ -842,6 +1043,8 @@ void pa_sink_render_into(pa_sink*s, pa_memchunk *target) {
return;
}
+ pa_sink_ref(s);
+
length = target->length;
block_size_max = pa_mempool_block_size_max(s->core->mempool);
if (length > block_size_max)
@@ -909,17 +1112,23 @@ void pa_sink_render_into_full(pa_sink *s, pa_memchunk *target) {
size_t l, d;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
pa_assert(target);
pa_assert(target->memblock);
pa_assert(target->length > 0);
pa_assert(pa_frame_aligned(target->length, &s->sample_spec));
- pa_sink_ref(s);
-
pa_assert(!s->thread_info.rewind_requested);
pa_assert(s->thread_info.rewind_nbytes == 0);
+ if (s->thread_info.state == PA_SINK_SUSPENDED) {
+ pa_silence_memchunk(target, &s->sample_spec);
+ return;
+ }
+
+ pa_sink_ref(s);
+
l = target->length;
d = 0;
while (l > 0) {
@@ -938,93 +1147,32 @@ void pa_sink_render_into_full(pa_sink *s, pa_memchunk *target) {
/* Called from IO thread context */
void pa_sink_render_full(pa_sink *s, size_t length, pa_memchunk *result) {
- pa_mix_info info[MAX_MIX_CHANNELS];
- size_t length1st = length;
- unsigned n;
-
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
pa_assert(length > 0);
pa_assert(pa_frame_aligned(length, &s->sample_spec));
pa_assert(result);
- pa_sink_ref(s);
-
pa_assert(!s->thread_info.rewind_requested);
pa_assert(s->thread_info.rewind_nbytes == 0);
- pa_assert(length > 0);
-
- n = fill_mix_info(s, &length1st, info, MAX_MIX_CHANNELS);
-
- if (n == 0) {
- pa_silence_memchunk_get(&s->core->silence_cache,
- s->core->mempool,
- result,
- &s->sample_spec,
- length1st);
- } else if (n == 1) {
- pa_cvolume volume;
-
- *result = info[0].chunk;
- pa_memblock_ref(result->memblock);
-
- if (result->length > length)
- result->length = length;
-
- pa_sw_cvolume_multiply(&volume, &s->thread_info.soft_volume, &info[0].volume);
-
- if (s->thread_info.soft_muted || !pa_cvolume_is_norm(&volume)) {
- if (s->thread_info.soft_muted || pa_cvolume_is_muted(&volume)) {
- pa_memblock_unref(result->memblock);
- pa_silence_memchunk_get(&s->core->silence_cache,
- s->core->mempool,
- result,
- &s->sample_spec,
- result->length);
- } else {
- pa_memchunk_make_writable(result, length);
- pa_volume_memchunk(result, &s->sample_spec, &volume);
- }
- }
- } else {
- void *ptr;
-
- result->index = 0;
- result->memblock = pa_memblock_new(s->core->mempool, length);
-
- ptr = pa_memblock_acquire(result->memblock);
-
- result->length = pa_mix(info, n,
- (uint8_t*) ptr + result->index, length1st,
- &s->sample_spec,
- &s->thread_info.soft_volume,
- s->thread_info.soft_muted);
-
- pa_memblock_release(result->memblock);
- }
+ pa_sink_ref(s);
- inputs_drop(s, info, n, result);
+ pa_sink_render(s, length, result);
if (result->length < length) {
- pa_memchunk chunk;
- size_t l, d;
- pa_memchunk_make_writable(result, length);
- result->length = length;
+ pa_memchunk chunk;
+
+ pa_memchunk_make_writable(result, length);
- l = length - result->length;
- d = result->index + result->length;
- while (l > 0) {
- chunk = *result;
- chunk.index += d;
- chunk.length -= d - result->index;
+ chunk.memblock = result->memblock;
+ chunk.index = result->index + result->length;
+ chunk.length = length - result->length;
- pa_sink_render_into(s, &chunk);
+ pa_sink_render_into_full(s, &chunk);
- d += chunk.length;
- l -= chunk.length;
- }
- result->length = length;
+ result->length = length;
}
pa_sink_unref(s);
@@ -1035,6 +1183,7 @@ pa_usec_t pa_sink_get_latency(pa_sink *s) {
pa_usec_t usec = 0;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
/* The returned value is supposed to be in the time domain of the sound card! */
@@ -1056,6 +1205,7 @@ pa_usec_t pa_sink_get_latency_within_thread(pa_sink *s) {
pa_msgobject *o;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
/* The returned value is supposed to be in the time domain of the sound card! */
@@ -1068,7 +1218,7 @@ pa_usec_t pa_sink_get_latency_within_thread(pa_sink *s) {
o = PA_MSGOBJECT(s);
- /* We probably should make this a proper vtable callback instead of going through process_msg() */
+ /* FIXME: We probably should make this a proper vtable callback instead of going through process_msg() */
if (o->process_msg(o, PA_SINK_MESSAGE_GET_LATENCY, &usec, 0, NULL) < 0)
return -1;
@@ -1076,260 +1226,657 @@ pa_usec_t pa_sink_get_latency_within_thread(pa_sink *s) {
return usec;
}
-static void compute_new_soft_volume(pa_sink_input *i, const pa_cvolume *new_volume) {
- unsigned c;
+/* Called from the main thread (and also from the IO thread while the main
+ * thread is waiting).
+ *
+ * When a sink uses volume sharing, it never has the PA_SINK_FLAT_VOLUME flag
+ * set. Instead, flat volume mode is detected by checking whether the root sink
+ * has the flag set. */
+pa_bool_t pa_sink_flat_volume_enabled(pa_sink *s) {
+ pa_sink_assert_ref(s);
+
+ while (s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)
+ s = s->input_to_master->sink;
- pa_sink_input_assert_ref(i);
- pa_assert(new_volume->channels == i->sample_spec.channels);
+ return (s->flags & PA_SINK_FLAT_VOLUME);
+}
+
+/* Called from main context */
+pa_bool_t pa_sink_is_passthrough(pa_sink *s) {
+ pa_sink_input *alt_i;
+ uint32_t idx;
+
+ pa_sink_assert_ref(s);
+
+ /* one and only one PASSTHROUGH input can possibly be connected */
+ if (pa_idxset_size(s->inputs) == 1) {
+ alt_i = pa_idxset_first(s->inputs, &idx);
+
+ if (pa_sink_input_is_passthrough(alt_i))
+ return TRUE;
+ }
+
+ return FALSE;
+}
+
+/* Called from main context. */
+static void compute_reference_ratio(pa_sink_input *i) {
+ unsigned c = 0;
+ pa_cvolume remapped;
+
+ pa_assert(i);
+ pa_assert(pa_sink_flat_volume_enabled(i->sink));
/*
- * This basically calculates:
+ * Calculates the reference ratio from the sink's reference
+ * volume. This basically calculates:
*
- * i->relative_volume := i->virtual_volume / new_volume
- * i->soft_volume := i->relative_volume * i->volume_factor
+ * i->reference_ratio = i->volume / i->sink->reference_volume
*/
- /* The new sink volume passed in here must already be remapped to
- * the sink input's channel map! */
+ remapped = i->sink->reference_volume;
+ pa_cvolume_remap(&remapped, &i->sink->channel_map, &i->channel_map);
- i->soft_volume.channels = i->sample_spec.channels;
+ i->reference_ratio.channels = i->sample_spec.channels;
- for (c = 0; c < i->sample_spec.channels; c++)
+ for (c = 0; c < i->sample_spec.channels; c++) {
- if (new_volume->values[c] <= PA_VOLUME_MUTED)
- /* We leave i->relative_volume untouched */
- i->soft_volume.values[c] = PA_VOLUME_MUTED;
- else {
- i->relative_volume[c] =
- pa_sw_volume_to_linear(i->virtual_volume.values[c]) /
- pa_sw_volume_to_linear(new_volume->values[c]);
+ /* We don't update when the sink volume is 0 anyway */
+ if (remapped.values[c] <= PA_VOLUME_MUTED)
+ continue;
- i->soft_volume.values[c] = pa_sw_volume_from_linear(
- i->relative_volume[c] *
- pa_sw_volume_to_linear(i->volume_factor.values[c]));
- }
+ /* Don't update the reference ratio unless necessary */
+ if (pa_sw_volume_multiply(
+ i->reference_ratio.values[c],
+ remapped.values[c]) == i->volume.values[c])
+ continue;
- /* Hooks have the ability to play games with i->soft_volume */
- pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_SET_VOLUME], i);
+ i->reference_ratio.values[c] = pa_sw_volume_divide(
+ i->volume.values[c],
+ remapped.values[c]);
+ }
+}
+
+/* Called from main context. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. */
+static void compute_reference_ratios(pa_sink *s) {
+ uint32_t idx;
+ pa_sink_input *i;
+
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_IS_LINKED(s->state));
+ pa_assert(pa_sink_flat_volume_enabled(s));
+
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ compute_reference_ratio(i);
- /* We don't copy the soft_volume to the thread_info data
- * here. That must be done by the caller */
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
+ compute_reference_ratios(i->origin_sink);
+ }
}
-/* Called from main thread */
-void pa_sink_update_flat_volume(pa_sink *s, pa_cvolume *new_volume) {
+/* Called from main context. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. */
+static void compute_real_ratios(pa_sink *s) {
pa_sink_input *i;
uint32_t idx;
pa_sink_assert_ref(s);
- pa_assert(new_volume);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
- pa_assert(s->flags & PA_SINK_FLAT_VOLUME);
+ pa_assert(pa_sink_flat_volume_enabled(s));
- /* This is called whenever a sink input volume changes or a sink
- * input is added/removed and we might need to fix up the sink
- * volume accordingly. Please note that we don't actually update
- * the sinks volume here, we only return how it needs to be
- * updated. The caller should then call pa_sink_set_volume().*/
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ unsigned c;
+ pa_cvolume remapped;
- if (pa_idxset_isempty(s->inputs)) {
- /* In the special case that we have no sink input we leave the
- * volume unmodified. */
- *new_volume = s->reference_volume;
- return;
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)) {
+ /* The origin sink uses volume sharing, so this input's real ratio
+ * is handled as a special case - the real ratio must be 0 dB, and
+ * as a result i->soft_volume must equal i->volume_factor. */
+ pa_cvolume_reset(&i->real_ratio, i->real_ratio.channels);
+ i->soft_volume = i->volume_factor;
+
+ compute_real_ratios(i->origin_sink);
+
+ continue;
+ }
+
+ /*
+ * This basically calculates:
+ *
+ * i->real_ratio := i->volume / s->real_volume
+ * i->soft_volume := i->real_ratio * i->volume_factor
+ */
+
+ remapped = s->real_volume;
+ pa_cvolume_remap(&remapped, &s->channel_map, &i->channel_map);
+
+ i->real_ratio.channels = i->sample_spec.channels;
+ i->soft_volume.channels = i->sample_spec.channels;
+
+ for (c = 0; c < i->sample_spec.channels; c++) {
+
+ if (remapped.values[c] <= PA_VOLUME_MUTED) {
+ /* We leave i->real_ratio untouched */
+ i->soft_volume.values[c] = PA_VOLUME_MUTED;
+ continue;
+ }
+
+ /* Don't lose accuracy unless necessary */
+ if (pa_sw_volume_multiply(
+ i->real_ratio.values[c],
+ remapped.values[c]) != i->volume.values[c])
+
+ i->real_ratio.values[c] = pa_sw_volume_divide(
+ i->volume.values[c],
+ remapped.values[c]);
+
+ i->soft_volume.values[c] = pa_sw_volume_multiply(
+ i->real_ratio.values[c],
+ i->volume_factor.values[c]);
+ }
+
+ /* We don't copy the soft_volume to the thread_info data
+ * here. That must be done by the caller */
}
+}
- pa_cvolume_mute(new_volume, s->channel_map.channels);
+static pa_cvolume *cvolume_remap_minimal_impact(
+ pa_cvolume *v,
+ const pa_cvolume *template,
+ const pa_channel_map *from,
+ const pa_channel_map *to) {
- /* First let's determine the new maximum volume of all inputs
- * connected to this sink */
- for (i = PA_SINK_INPUT(pa_idxset_first(s->inputs, &idx)); i; i = PA_SINK_INPUT(pa_idxset_next(s->inputs, &idx))) {
- unsigned c;
- pa_cvolume remapped_volume;
+ pa_cvolume t;
- remapped_volume = i->virtual_volume;
- pa_cvolume_remap(&remapped_volume, &i->channel_map, &s->channel_map);
+ pa_assert(v);
+ pa_assert(template);
+ pa_assert(from);
+ pa_assert(to);
+ pa_assert(pa_cvolume_compatible_with_channel_map(v, from));
+ pa_assert(pa_cvolume_compatible_with_channel_map(template, to));
- for (c = 0; c < new_volume->channels; c++)
- if (remapped_volume.values[c] > new_volume->values[c])
- new_volume->values[c] = remapped_volume.values[c];
+ /* Much like pa_cvolume_remap(), but tries to minimize impact when
+ * mapping from sink input to sink volumes:
+ *
+ * If template is a possible remapping from v it is used instead
+ * of remapping anew.
+ *
+ * If the channel maps don't match we set an all-channel volume on
+ * the sink to ensure that changing a volume on one stream has no
+ * effect that cannot be compensated for in another stream that
+ * does not have the same channel map as the sink. */
+
+ if (pa_channel_map_equal(from, to))
+ return v;
+
+ t = *template;
+ if (pa_cvolume_equal(pa_cvolume_remap(&t, to, from), v)) {
+ *v = *template;
+ return v;
}
- /* Then, let's update the soft volumes of all inputs connected
- * to this sink */
- for (i = PA_SINK_INPUT(pa_idxset_first(s->inputs, &idx)); i; i = PA_SINK_INPUT(pa_idxset_next(s->inputs, &idx))) {
- pa_cvolume remapped_new_volume;
+ pa_cvolume_set(v, to->channels, pa_cvolume_max(v));
+ return v;
+}
+
+/* Called from main thread. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. */
+static void get_maximum_input_volume(pa_sink *s, pa_cvolume *max_volume, const pa_channel_map *channel_map) {
+ pa_sink_input *i;
+ uint32_t idx;
+
+ pa_sink_assert_ref(s);
+ pa_assert(max_volume);
+ pa_assert(channel_map);
+ pa_assert(pa_sink_flat_volume_enabled(s));
+
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ pa_cvolume remapped;
- remapped_new_volume = *new_volume;
- pa_cvolume_remap(&remapped_new_volume, &s->channel_map, &i->channel_map);
- compute_new_soft_volume(i, &remapped_new_volume);
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)) {
+ get_maximum_input_volume(i->origin_sink, max_volume, channel_map);
- /* We don't copy soft_volume to the thread_info data here
- * (i.e. issue PA_SINK_INPUT_MESSAGE_SET_VOLUME) because we
- * want the update to be atomically with the sink volume
- * update, hence we do it within the pa_sink_set_volume() call
- * below */
+ /* Ignore this input. The origin sink uses volume sharing, so this
+ * input's volume will be set to be equal to the root sink's real
+ * volume. Obviously this input's current volume must not then
+ * affect what the root sink's real volume will be. */
+ continue;
+ }
+
+ remapped = i->volume;
+ cvolume_remap_minimal_impact(&remapped, max_volume, &i->channel_map, channel_map);
+ pa_cvolume_merge(max_volume, max_volume, &remapped);
}
}
-/* Called from main thread */
-void pa_sink_propagate_flat_volume(pa_sink *s) {
+/* Called from main thread. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. */
+static pa_bool_t has_inputs(pa_sink *s) {
pa_sink_input *i;
uint32_t idx;
pa_sink_assert_ref(s);
+
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ if (!i->origin_sink || !(i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER) || has_inputs(i->origin_sink))
+ return TRUE;
+ }
+
+ return FALSE;
+}
+
+/* Called from main thread. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. */
+static void update_real_volume(pa_sink *s, const pa_cvolume *new_volume, pa_channel_map *channel_map) {
+ pa_sink_input *i;
+ uint32_t idx;
+
+ pa_sink_assert_ref(s);
+ pa_assert(new_volume);
+ pa_assert(channel_map);
+
+ s->real_volume = *new_volume;
+ pa_cvolume_remap(&s->real_volume, channel_map, &s->channel_map);
+
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)) {
+ if (pa_sink_flat_volume_enabled(s)) {
+ pa_cvolume old_volume = i->volume;
+
+ /* Follow the root sink's real volume. */
+ i->volume = *new_volume;
+ pa_cvolume_remap(&i->volume, channel_map, &i->channel_map);
+ compute_reference_ratio(i);
+
+ /* The volume changed, let's tell people so */
+ if (!pa_cvolume_equal(&old_volume, &i->volume)) {
+ if (i->volume_changed)
+ i->volume_changed(i);
+
+ pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
+ }
+ }
+
+ update_real_volume(i->origin_sink, new_volume, channel_map);
+ }
+ }
+}
+
+/* Called from main thread. Only called for the root sink in shared volume
+ * cases. */
+static void compute_real_volume(pa_sink *s) {
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
- pa_assert(s->flags & PA_SINK_FLAT_VOLUME);
+ pa_assert(pa_sink_flat_volume_enabled(s));
+ pa_assert(!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER));
+
+ /* This determines the maximum volume of all streams and sets
+ * s->real_volume accordingly. */
+
+ if (!has_inputs(s)) {
+ /* In the special case that we have no sink inputs we leave the
+ * volume unmodified. */
+ update_real_volume(s, &s->reference_volume, &s->channel_map);
+ return;
+ }
+
+ pa_cvolume_mute(&s->real_volume, s->channel_map.channels);
+
+ /* First let's determine the new maximum volume of all inputs
+ * connected to this sink */
+ get_maximum_input_volume(s, &s->real_volume, &s->channel_map);
+ update_real_volume(s, &s->real_volume, &s->channel_map);
+
+ /* Then, let's update the real ratios/soft volumes of all inputs
+ * connected to this sink */
+ compute_real_ratios(s);
+}
+
+/* Called from main thread. Only called for the root sink in shared volume
+ * cases, except for internal recursive calls. */
+static void propagate_reference_volume(pa_sink *s) {
+ pa_sink_input *i;
+ uint32_t idx;
+
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_IS_LINKED(s->state));
+ pa_assert(pa_sink_flat_volume_enabled(s));
/* This is called whenever the sink volume changes that is not
* caused by a sink input volume change. We need to fix up the
* sink input volumes accordingly */
- for (i = PA_SINK_INPUT(pa_idxset_first(s->inputs, &idx)); i; i = PA_SINK_INPUT(pa_idxset_next(s->inputs, &idx))) {
- pa_cvolume sink_volume, new_virtual_volume;
- unsigned c;
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ pa_cvolume old_volume;
- /* This basically calculates i->virtual_volume := i->relative_volume * s->virtual_volume */
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)) {
+ propagate_reference_volume(i->origin_sink);
- sink_volume = s->virtual_volume;
- pa_cvolume_remap(&sink_volume, &s->channel_map, &i->channel_map);
+ /* Since the origin sink uses volume sharing, this input's volume
+ * needs to be updated to match the root sink's real volume, but
+ * that will be done later in update_shared_real_volume(). */
+ continue;
+ }
- for (c = 0; c < i->sample_spec.channels; c++)
- new_virtual_volume.values[c] = pa_sw_volume_from_linear(
- i->relative_volume[c] *
- pa_sw_volume_to_linear(sink_volume.values[c]));
+ old_volume = i->volume;
+
+ /* This basically calculates:
+ *
+ * i->volume := s->reference_volume * i->reference_ratio */
- new_virtual_volume.channels = i->sample_spec.channels;
+ i->volume = s->reference_volume;
+ pa_cvolume_remap(&i->volume, &s->channel_map, &i->channel_map);
+ pa_sw_cvolume_multiply(&i->volume, &i->volume, &i->reference_ratio);
- if (!pa_cvolume_equal(&new_virtual_volume, &i->virtual_volume)) {
- i->virtual_volume = new_virtual_volume;
+ /* The volume changed, let's tell people so */
+ if (!pa_cvolume_equal(&old_volume, &i->volume)) {
- /* Hmm, the soft volume might no longer actually match
- * what has been chosen as new virtual volume here,
- * especially when the old volume was
- * PA_VOLUME_MUTED. Hence let's recalculate the soft
- * volumes here. */
- compute_new_soft_volume(i, &sink_volume);
+ if (i->volume_changed)
+ i->volume_changed(i);
- /* The virtual volume changed, let's tell people so */
pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
}
}
+}
+
+/* Called from main thread. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. The return value indicates
+ * whether any reference volume actually changed. */
+static pa_bool_t update_reference_volume(pa_sink *s, const pa_cvolume *v, const pa_channel_map *channel_map, pa_bool_t save) {
+ pa_cvolume volume;
+ pa_bool_t reference_volume_changed;
+ pa_sink_input *i;
+ uint32_t idx;
+
+ pa_sink_assert_ref(s);
+ pa_assert(PA_SINK_IS_LINKED(s->state));
+ pa_assert(v);
+ pa_assert(channel_map);
+ pa_assert(pa_cvolume_valid(v));
+
+ volume = *v;
+ pa_cvolume_remap(&volume, channel_map, &s->channel_map);
+
+ reference_volume_changed = !pa_cvolume_equal(&volume, &s->reference_volume);
+ s->reference_volume = volume;
+
+ s->save_volume = (!reference_volume_changed && s->save_volume) || save;
+
+ if (reference_volume_changed)
+ pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+ else if (!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
+ /* If the root sink's volume doesn't change, then there can't be any
+ * changes in the other sinks in the sink tree either.
+ *
+ * It's probably theoretically possible that even if the root sink's
+ * volume changes slightly, some filter sink doesn't change its volume
+ * due to rounding errors. If that happens, we still want to propagate
+ * the changed root sink volume to the sinks connected to the
+ * intermediate sink that didn't change its volume. This theoretical
+ * possiblity is the reason why we have that !(s->flags &
+ * PA_SINK_SHARE_VOLUME_WITH_MASTER) condition. Probably nobody would
+ * notice even if we returned here FALSE always if
+ * reference_volume_changed is FALSE. */
+ return FALSE;
+
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
+ update_reference_volume(i->origin_sink, v, channel_map, FALSE);
+ }
- /* If the soft_volume of any of the sink inputs got changed, let's
- * make sure the thread copies are synced up. */
- pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SYNC_VOLUMES, NULL, 0, NULL) == 0);
+ return TRUE;
}
/* Called from main thread */
-void pa_sink_set_volume(pa_sink *s, const pa_cvolume *volume, pa_bool_t propagate, pa_bool_t sendmsg, pa_bool_t become_reference) {
- pa_bool_t virtual_volume_changed;
+void pa_sink_set_volume(
+ pa_sink *s,
+ const pa_cvolume *volume,
+ pa_bool_t send_msg,
+ pa_bool_t save) {
+
+ pa_cvolume new_reference_volume;
+ pa_sink *root_sink = s;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
- pa_assert(volume);
- pa_assert(pa_cvolume_valid(volume));
- pa_assert(pa_cvolume_compatible(volume, &s->sample_spec));
+ pa_assert(!volume || pa_cvolume_valid(volume));
+ pa_assert(volume || pa_sink_flat_volume_enabled(s));
+ pa_assert(!volume || volume->channels == 1 || pa_cvolume_compatible(volume, &s->sample_spec));
+
+ /* make sure we don't change the volume when a PASSTHROUGH input is connected */
+ if (pa_sink_is_passthrough(s)) {
+ /* FIXME: Need to notify client that volume control is disabled */
+ pa_log_warn("Cannot change volume, Sink is connected to PASSTHROUGH input");
+ return;
+ }
- virtual_volume_changed = !pa_cvolume_equal(volume, &s->virtual_volume);
- s->virtual_volume = *volume;
+ /* In case of volume sharing, the volume is set for the root sink first,
+ * from which it's then propagated to the sharing sinks. */
+ while (root_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)
+ root_sink = root_sink->input_to_master->sink;
- if (become_reference)
- s->reference_volume = s->virtual_volume;
+ /* As a special exception we accept mono volumes on all sinks --
+ * even on those with more complex channel maps */
- /* Propagate this volume change back to the inputs */
- if (virtual_volume_changed)
- if (propagate && (s->flags & PA_SINK_FLAT_VOLUME))
- pa_sink_propagate_flat_volume(s);
+ if (volume) {
+ if (pa_cvolume_compatible(volume, &s->sample_spec))
+ new_reference_volume = *volume;
+ else {
+ new_reference_volume = s->reference_volume;
+ pa_cvolume_scale(&new_reference_volume, pa_cvolume_max(volume));
+ }
+
+ pa_cvolume_remap(&new_reference_volume, &s->channel_map, &root_sink->channel_map);
+ }
+
+ /* If volume is NULL we synchronize the sink's real and reference
+ * volumes with the stream volumes. If it is not NULL we update
+ * the reference_volume with it. */
+
+ if (volume) {
+ if (update_reference_volume(root_sink, &new_reference_volume, &root_sink->channel_map, save)) {
+ if (pa_sink_flat_volume_enabled(root_sink)) {
+ /* OK, propagate this volume change back to the inputs */
+ propagate_reference_volume(root_sink);
+
+ /* And now recalculate the real volume */
+ compute_real_volume(root_sink);
+ } else
+ update_real_volume(root_sink, &root_sink->reference_volume, &root_sink->channel_map);
+ }
- if (s->set_volume) {
+ } else {
+ pa_assert(pa_sink_flat_volume_enabled(root_sink));
+
+ /* Ok, let's determine the new real volume */
+ compute_real_volume(root_sink);
+
+ /* Let's 'push' the reference volume if necessary */
+ pa_cvolume_merge(&new_reference_volume, &s->reference_volume, &root_sink->real_volume);
+ update_reference_volume(root_sink, &new_reference_volume, &root_sink->channel_map, save);
+
+ /* Now that the reference volume is updated, we can update the streams'
+ * reference ratios. */
+ compute_reference_ratios(root_sink);
+ }
+
+ if (root_sink->set_volume) {
/* If we have a function set_volume(), then we do not apply a
* soft volume by default. However, set_volume() is free to
- * apply one to s->soft_volume */
+ * apply one to root_sink->soft_volume */
- pa_cvolume_reset(&s->soft_volume, s->sample_spec.channels);
- s->set_volume(s);
+ pa_cvolume_reset(&root_sink->soft_volume, root_sink->sample_spec.channels);
+ if (!(root_sink->flags & PA_SINK_SYNC_VOLUME))
+ root_sink->set_volume(root_sink);
} else
/* If we have no function set_volume(), then the soft volume
- * becomes the virtual volume */
- s->soft_volume = s->virtual_volume;
-
- /* This tells the sink that soft and/or virtual volume changed */
- if (sendmsg)
- pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_VOLUME, NULL, 0, NULL) == 0);
+ * becomes the real volume */
+ root_sink->soft_volume = root_sink->real_volume;
- if (virtual_volume_changed)
- pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+ /* This tells the sink that soft volume and/or real volume changed */
+ if (send_msg)
+ pa_assert_se(pa_asyncmsgq_send(root_sink->asyncmsgq, PA_MSGOBJECT(root_sink), PA_SINK_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL) == 0);
}
-/* Called from main thread. Only to be called by sink implementor */
+/* Called from the io thread if sync volume is used, otherwise from the main thread.
+ * Only to be called by sink implementor */
void pa_sink_set_soft_volume(pa_sink *s, const pa_cvolume *volume) {
+
pa_sink_assert_ref(s);
- pa_assert(volume);
+ pa_assert(!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER));
- s->soft_volume = *volume;
+ if (s->flags & PA_SINK_SYNC_VOLUME)
+ pa_sink_assert_io_context(s);
+ else
+ pa_assert_ctl_context();
- if (PA_SINK_IS_LINKED(s->state))
+ if (!volume)
+ pa_cvolume_reset(&s->soft_volume, s->sample_spec.channels);
+ else
+ s->soft_volume = *volume;
+
+ if (PA_SINK_IS_LINKED(s->state) && !(s->flags & PA_SINK_SYNC_VOLUME))
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_VOLUME, NULL, 0, NULL) == 0);
else
- s->thread_info.soft_volume = *volume;
+ s->thread_info.soft_volume = s->soft_volume;
}
-/* Called from main thread */
-const pa_cvolume *pa_sink_get_volume(pa_sink *s, pa_bool_t force_refresh, pa_bool_t reference) {
+/* Called from the main thread. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. */
+static void propagate_real_volume(pa_sink *s, const pa_cvolume *old_real_volume) {
+ pa_sink_input *i;
+ uint32_t idx;
+
pa_sink_assert_ref(s);
+ pa_assert(old_real_volume);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_IS_LINKED(s->state));
- if (s->refresh_volume || force_refresh) {
- struct pa_cvolume old_virtual_volume = s->virtual_volume;
+ /* This is called when the hardware's real volume changes due to
+ * some external event. We copy the real volume into our
+ * reference volume and then rebuild the stream volumes based on
+ * i->real_ratio which should stay fixed. */
- if (s->get_volume)
- s->get_volume(s);
+ if (!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)) {
+ if (pa_cvolume_equal(old_real_volume, &s->real_volume))
+ return;
- pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_VOLUME, NULL, 0, NULL) == 0);
+ /* 1. Make the real volume the reference volume */
+ update_reference_volume(s, &s->real_volume, &s->channel_map, TRUE);
+ }
- if (!pa_cvolume_equal(&old_virtual_volume, &s->virtual_volume)) {
+ if (pa_sink_flat_volume_enabled(s)) {
- s->reference_volume = s->virtual_volume;
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
+ pa_cvolume old_volume = i->volume;
- if (s->flags & PA_SINK_FLAT_VOLUME)
- pa_sink_propagate_flat_volume(s);
+ /* 2. Since the sink's reference and real volumes are equal
+ * now our ratios should be too. */
+ i->reference_ratio = i->real_ratio;
- pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+ /* 3. Recalculate the new stream reference volume based on the
+ * reference ratio and the sink's reference volume.
+ *
+ * This basically calculates:
+ *
+ * i->volume = s->reference_volume * i->reference_ratio
+ *
+ * This is identical to propagate_reference_volume() */
+ i->volume = s->reference_volume;
+ pa_cvolume_remap(&i->volume, &s->channel_map, &i->channel_map);
+ pa_sw_cvolume_multiply(&i->volume, &i->volume, &i->reference_ratio);
+
+ /* Notify if something changed */
+ if (!pa_cvolume_equal(&old_volume, &i->volume)) {
+
+ if (i->volume_changed)
+ i->volume_changed(i);
+
+ pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
+ }
+
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
+ propagate_real_volume(i->origin_sink, old_real_volume);
}
}
- return reference ? &s->reference_volume : &s->virtual_volume;
+ /* Something got changed in the hardware. It probably makes sense
+ * to save changed hw settings given that hw volume changes not
+ * triggered by PA are almost certainly done by the user. */
+ if (!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
+ s->save_volume = TRUE;
+}
+
+/* Called from io thread */
+void pa_sink_update_volume_and_mute(pa_sink *s) {
+ pa_assert(s);
+ pa_sink_assert_io_context(s);
+
+ pa_asyncmsgq_post(pa_thread_mq_get()->outq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_UPDATE_VOLUME_AND_MUTE, NULL, 0, NULL, NULL);
}
/* Called from main thread */
-void pa_sink_volume_changed(pa_sink *s, const pa_cvolume *new_volume) {
+const pa_cvolume *pa_sink_get_volume(pa_sink *s, pa_bool_t force_refresh) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_IS_LINKED(s->state));
- /* The sink implementor may call this if the volume changed to make sure everyone is notified */
+ if (s->refresh_volume || force_refresh) {
+ struct pa_cvolume old_real_volume;
- if (pa_cvolume_equal(&s->virtual_volume, new_volume))
- return;
+ pa_assert(!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER));
- s->reference_volume = s->virtual_volume = *new_volume;
+ old_real_volume = s->real_volume;
- if (s->flags & PA_SINK_FLAT_VOLUME)
- pa_sink_propagate_flat_volume(s);
+ if (!(s->flags & PA_SINK_SYNC_VOLUME) && s->get_volume)
+ s->get_volume(s);
- pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_VOLUME, NULL, 0, NULL) == 0);
+
+ update_real_volume(s, &s->real_volume, &s->channel_map);
+ propagate_real_volume(s, &old_real_volume);
+ }
+
+ return &s->reference_volume;
+}
+
+/* Called from main thread. In volume sharing cases, only the root sink may
+ * call this. */
+void pa_sink_volume_changed(pa_sink *s, const pa_cvolume *new_real_volume) {
+ pa_cvolume old_real_volume;
+
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_IS_LINKED(s->state));
+ pa_assert(!(s->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER));
+
+ /* The sink implementor may call this if the volume changed to make sure everyone is notified */
+
+ old_real_volume = s->real_volume;
+ update_real_volume(s, new_real_volume, &s->channel_map);
+ propagate_real_volume(s, &old_real_volume);
}
/* Called from main thread */
-void pa_sink_set_mute(pa_sink *s, pa_bool_t mute) {
+void pa_sink_set_mute(pa_sink *s, pa_bool_t mute, pa_bool_t save) {
pa_bool_t old_muted;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
old_muted = s->muted;
s->muted = mute;
+ s->save_muted = (old_muted == s->muted && s->save_muted) || save;
- if (s->set_mute)
+ if (!(s->flags & PA_SINK_SYNC_VOLUME) && s->set_mute)
s->set_mute(s);
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_MUTE, NULL, 0, NULL) == 0);
@@ -1342,17 +1889,25 @@ void pa_sink_set_mute(pa_sink *s, pa_bool_t mute) {
pa_bool_t pa_sink_get_mute(pa_sink *s, pa_bool_t force_refresh) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_IS_LINKED(s->state));
if (s->refresh_muted || force_refresh) {
pa_bool_t old_muted = s->muted;
- if (s->get_mute)
+ if (!(s->flags & PA_SINK_SYNC_VOLUME) && s->get_mute)
s->get_mute(s);
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_MUTE, NULL, 0, NULL) == 0);
- if (old_muted != s->muted)
+ if (old_muted != s->muted) {
+ s->save_muted = TRUE;
+
pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+
+ /* Make sure the soft mute status stays in sync */
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_MUTE, NULL, 0, NULL) == 0);
+ }
}
return s->muted;
@@ -1361,6 +1916,8 @@ pa_bool_t pa_sink_get_mute(pa_sink *s, pa_bool_t force_refresh) {
/* Called from main thread */
void pa_sink_mute_changed(pa_sink *s, pa_bool_t new_muted) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SINK_IS_LINKED(s->state));
/* The sink implementor may call this if the volume changed to make sure everyone is notified */
@@ -1368,12 +1925,15 @@ void pa_sink_mute_changed(pa_sink *s, pa_bool_t new_muted) {
return;
s->muted = new_muted;
+ s->save_muted = TRUE;
+
pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
}
/* Called from main thread */
pa_bool_t pa_sink_update_proplist(pa_sink *s, pa_update_mode_t mode, pa_proplist *p) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
if (p)
pa_proplist_update(s->proplist, mode, p);
@@ -1387,16 +1947,18 @@ pa_bool_t pa_sink_update_proplist(pa_sink *s, pa_update_mode_t mode, pa_proplist
}
/* Called from main thread */
+/* FIXME -- this should be dropped and be merged into pa_sink_update_proplist() */
void pa_sink_set_description(pa_sink *s, const char *description) {
const char *old;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
if (!description && !pa_proplist_contains(s->proplist, PA_PROP_DEVICE_DESCRIPTION))
return;
old = pa_proplist_gets(s->proplist, PA_PROP_DEVICE_DESCRIPTION);
- if (old && description && !strcmp(old, description))
+ if (old && description && pa_streq(old, description))
return;
if (description)
@@ -1423,6 +1985,7 @@ unsigned pa_sink_linked_by(pa_sink *s) {
unsigned ret;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
ret = pa_idxset_size(s->inputs);
@@ -1441,6 +2004,7 @@ unsigned pa_sink_used_by(pa_sink *s) {
unsigned ret;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
ret = pa_idxset_size(s->inputs);
@@ -1459,17 +2023,25 @@ unsigned pa_sink_check_suspend(pa_sink *s) {
uint32_t idx;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
if (!PA_SINK_IS_LINKED(s->state))
return 0;
ret = 0;
- for (i = PA_SINK_INPUT(pa_idxset_first(s->inputs, &idx)); i; i = PA_SINK_INPUT(pa_idxset_next(s->inputs, &idx))) {
+ PA_IDXSET_FOREACH(i, s->inputs, idx) {
pa_sink_input_state_t st;
st = pa_sink_input_get_state(i);
- pa_assert(PA_SINK_INPUT_IS_LINKED(st));
+
+ /* We do not assert here. It is perfectly valid for a sink input to
+ * be in the INIT state (i.e. created, marked done but not yet put)
+ * and we should not care if it's unlinked as it won't contribute
+ * towarards our busy status.
+ */
+ if (!PA_SINK_INPUT_IS_LINKED(st))
+ continue;
if (st == PA_SINK_INPUT_CORKED)
continue;
@@ -1492,8 +2064,9 @@ static void sync_input_volumes_within_thread(pa_sink *s) {
void *state = NULL;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
- while ((i = PA_SINK_INPUT(pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))) {
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state) {
if (pa_cvolume_equal(&i->thread_info.soft_volume, &i->soft_volume))
continue;
@@ -1502,6 +2075,22 @@ static void sync_input_volumes_within_thread(pa_sink *s) {
}
}
+/* Called from the IO thread. Only called for the root sink in volume sharing
+ * cases, except for internal recursive calls. */
+static void set_shared_volume_within_thread(pa_sink *s) {
+ pa_sink_input *i = NULL;
+ void *state = NULL;
+
+ pa_sink_assert_ref(s);
+
+ PA_MSGOBJECT(s)->process_msg(PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_VOLUME_SYNCED, NULL, 0, NULL);
+
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state) {
+ if (i->origin_sink && (i->origin_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER))
+ set_shared_volume_within_thread(i->origin_sink);
+ }
+}
+
/* Called from IO thread, except when it is not */
int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offset, pa_memchunk *chunk) {
pa_sink *s = PA_SINK(o);
@@ -1558,7 +2147,7 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
/* In flat volume mode we need to update the volume as
* well */
- return o->process_msg(o, PA_SINK_MESSAGE_SET_VOLUME, NULL, 0, NULL);
+ return o->process_msg(o, PA_SINK_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL);
}
case PA_SINK_MESSAGE_REMOVE_INPUT: {
@@ -1566,7 +2155,7 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
/* If you change anything here, make sure to change the
* sink input handling a few lines down at
- * PA_SINK_MESSAGE_PREPAPRE_MOVE, too. */
+ * PA_SINK_MESSAGE_START_MOVE, too. */
if (i->detach)
i->detach(i);
@@ -1596,12 +2185,12 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
if (pa_hashmap_remove(s->thread_info.inputs, PA_UINT32_TO_PTR(i->index)))
pa_sink_input_unref(i);
- pa_sink_invalidate_requested_latency(s);
+ pa_sink_invalidate_requested_latency(s, TRUE);
pa_sink_request_rewind(s, (size_t) -1);
/* In flat volume mode we need to update the volume as
* well */
- return o->process_msg(o, PA_SINK_MESSAGE_SET_VOLUME, NULL, 0, NULL);
+ return o->process_msg(o, PA_SINK_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL);
}
case PA_SINK_MESSAGE_START_MOVE: {
@@ -1618,10 +2207,7 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
size_t sink_nbytes, total_nbytes;
/* Get the latency of the sink */
- if (!(s->flags & PA_SINK_LATENCY) ||
- PA_MSGOBJECT(s)->process_msg(PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_LATENCY, &usec, 0, NULL) < 0)
- usec = 0;
-
+ usec = pa_sink_get_latency_within_thread(s);
sink_nbytes = pa_usec_to_bytes(usec, &s->sample_spec);
total_nbytes = sink_nbytes + pa_memblockq_get_length(i->thread_info.render_memblockq);
@@ -1642,14 +2228,14 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
if (pa_hashmap_remove(s->thread_info.inputs, PA_UINT32_TO_PTR(i->index)))
pa_sink_input_unref(i);
- pa_sink_invalidate_requested_latency(s);
+ pa_sink_invalidate_requested_latency(s, TRUE);
pa_log_debug("Requesting rewind due to started move");
pa_sink_request_rewind(s, (size_t) -1);
/* In flat volume mode we need to update the volume as
* well */
- return o->process_msg(o, PA_SINK_MESSAGE_SET_VOLUME, NULL, 0, NULL);
+ return o->process_msg(o, PA_SINK_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL);
}
case PA_SINK_MESSAGE_FINISH_MOVE: {
@@ -1680,10 +2266,7 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
size_t nbytes;
/* Get the latency of the sink */
- if (!(s->flags & PA_SINK_LATENCY) ||
- PA_MSGOBJECT(s)->process_msg(PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_LATENCY, &usec, 0, NULL) < 0)
- usec = 0;
-
+ usec = pa_sink_get_latency_within_thread(s);
nbytes = pa_usec_to_bytes(usec, &s->sample_spec);
if (nbytes > 0)
@@ -1693,11 +2276,27 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
pa_sink_request_rewind(s, nbytes);
}
- /* In flat volume mode we need to update the volume as
- * well */
- return o->process_msg(o, PA_SINK_MESSAGE_SET_VOLUME, NULL, 0, NULL);
+ return o->process_msg(o, PA_SINK_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL);
}
+ case PA_SINK_MESSAGE_SET_SHARED_VOLUME: {
+ pa_sink *root_sink = s;
+
+ while (root_sink->flags & PA_SINK_SHARE_VOLUME_WITH_MASTER)
+ root_sink = root_sink->input_to_master->sink;
+
+ set_shared_volume_within_thread(root_sink);
+ return 0;
+ }
+
+ case PA_SINK_MESSAGE_SET_VOLUME_SYNCED:
+
+ if (s->flags & PA_SINK_SYNC_VOLUME) {
+ s->set_volume(s);
+ pa_sink_volume_change_push(s);
+ }
+ /* Fall through ... */
+
case PA_SINK_MESSAGE_SET_VOLUME:
if (!pa_cvolume_equal(&s->thread_info.soft_volume, &s->soft_volume)) {
@@ -1705,9 +2304,6 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
pa_sink_request_rewind(s, (size_t) -1);
}
- if (!(s->flags & PA_SINK_FLAT_VOLUME))
- return 0;
-
/* Fall through ... */
case PA_SINK_MESSAGE_SYNC_VOLUMES:
@@ -1715,6 +2311,19 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
return 0;
case PA_SINK_MESSAGE_GET_VOLUME:
+
+ if ((s->flags & PA_SINK_SYNC_VOLUME) && s->get_volume) {
+ s->get_volume(s);
+ pa_sink_volume_change_flush(s);
+ pa_sw_cvolume_divide(&s->thread_info.current_hw_volume, &s->real_volume, &s->soft_volume);
+ }
+
+ /* In case sink implementor reset SW volume. */
+ if (!pa_cvolume_equal(&s->thread_info.soft_volume, &s->soft_volume)) {
+ s->thread_info.soft_volume = s->soft_volume;
+ pa_sink_request_rewind(s, (size_t) -1);
+ }
+
return 0;
case PA_SINK_MESSAGE_SET_MUTE:
@@ -1724,9 +2333,16 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
pa_sink_request_rewind(s, (size_t) -1);
}
+ if (s->flags & PA_SINK_SYNC_VOLUME && s->set_mute)
+ s->set_mute(s);
+
return 0;
case PA_SINK_MESSAGE_GET_MUTE:
+
+ if (s->flags & PA_SINK_SYNC_VOLUME && s->get_mute)
+ s->get_mute(s);
+
return 0;
case PA_SINK_MESSAGE_SET_STATE: {
@@ -1771,6 +2387,9 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
pa_usec_t *usec = userdata;
*usec = pa_sink_get_requested_latency_within_thread(s);
+ /* Yes, that's right, the IO thread will see -1 when no
+ * explicit requested latency is configured, the main
+ * thread will see max_latency */
if (*usec == (pa_usec_t) -1)
*usec = s->thread_info.max_latency;
@@ -1794,6 +2413,16 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
return 0;
}
+ case PA_SINK_MESSAGE_GET_FIXED_LATENCY:
+
+ *((pa_usec_t*) userdata) = s->thread_info.fixed_latency;
+ return 0;
+
+ case PA_SINK_MESSAGE_SET_FIXED_LATENCY:
+
+ pa_sink_set_fixed_latency_within_thread(s, (pa_usec_t) offset);
+ return 0;
+
case PA_SINK_MESSAGE_GET_MAX_REWIND:
*((size_t*) userdata) = s->thread_info.max_rewind;
@@ -1814,6 +2443,23 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
pa_sink_set_max_request_within_thread(s, (size_t) offset);
return 0;
+ case PA_SINK_MESSAGE_SET_PORT:
+
+ pa_assert(userdata);
+ if (s->set_port) {
+ struct sink_message_set_port *msg_data = userdata;
+ msg_data->ret = s->set_port(s, msg_data->port);
+ }
+ return 0;
+
+ case PA_SINK_MESSAGE_UPDATE_VOLUME_AND_MUTE:
+ /* This message is sent from IO-thread and handled in main thread. */
+ pa_assert_ctl_context();
+
+ pa_sink_get_volume(s, TRUE);
+ pa_sink_get_mute(s, TRUE);
+ return 0;
+
case PA_SINK_MESSAGE_GET_LATENCY:
case PA_SINK_MESSAGE_MAX:
;
@@ -1823,17 +2469,19 @@ int pa_sink_process_msg(pa_msgobject *o, int code, void *userdata, int64_t offse
}
/* Called from main thread */
-int pa_sink_suspend_all(pa_core *c, pa_bool_t suspend) {
+int pa_sink_suspend_all(pa_core *c, pa_bool_t suspend, pa_suspend_cause_t cause) {
pa_sink *sink;
uint32_t idx;
int ret = 0;
pa_core_assert_ref(c);
+ pa_assert_ctl_context();
+ pa_assert(cause != 0);
- for (sink = PA_SINK(pa_idxset_first(c->sinks, &idx)); sink; sink = PA_SINK(pa_idxset_next(c->sinks, &idx))) {
+ PA_IDXSET_FOREACH(sink, c->sinks, idx) {
int r;
- if ((r = pa_sink_suspend(sink, suspend)) < 0)
+ if ((r = pa_sink_suspend(sink, suspend, cause)) < 0)
ret = r;
}
@@ -1843,6 +2491,7 @@ int pa_sink_suspend_all(pa_core *c, pa_bool_t suspend) {
/* Called from main thread */
void pa_sink_detach(pa_sink *s) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_DETACH, NULL, 0, NULL) == 0);
@@ -1851,6 +2500,7 @@ void pa_sink_detach(pa_sink *s) {
/* Called from main thread */
void pa_sink_attach(pa_sink *s) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_ATTACH, NULL, 0, NULL) == 0);
@@ -1862,9 +2512,10 @@ void pa_sink_detach_within_thread(pa_sink *s) {
void *state = NULL;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
if (i->detach)
i->detach(i);
@@ -1878,9 +2529,10 @@ void pa_sink_attach_within_thread(pa_sink *s) {
void *state = NULL;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
if (i->attach)
i->attach(i);
@@ -1891,6 +2543,7 @@ void pa_sink_attach_within_thread(pa_sink *s) {
/* Called from IO thread */
void pa_sink_request_rewind(pa_sink*s, size_t nbytes) {
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(PA_SINK_IS_LINKED(s->thread_info.state));
if (s->thread_info.state == PA_SINK_SUSPENDED)
@@ -1920,15 +2573,15 @@ pa_usec_t pa_sink_get_requested_latency_within_thread(pa_sink *s) {
pa_usec_t monitor_latency;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
if (!(s->flags & PA_SINK_DYNAMIC_LATENCY))
- return PA_CLAMP(s->fixed_latency, s->thread_info.min_latency, s->thread_info.max_latency);
+ return PA_CLAMP(s->thread_info.fixed_latency, s->thread_info.min_latency, s->thread_info.max_latency);
if (s->thread_info.requested_latency_valid)
return s->thread_info.requested_latency;
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))
-
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
if (i->thread_info.requested_sink_latency != (pa_usec_t) -1 &&
(result == (pa_usec_t) -1 || result > i->thread_info.requested_sink_latency))
result = i->thread_info.requested_sink_latency;
@@ -1956,12 +2609,14 @@ pa_usec_t pa_sink_get_requested_latency(pa_sink *s) {
pa_usec_t usec = 0;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SINK_IS_LINKED(s->state));
if (s->state == PA_SINK_SUSPENDED)
return 0;
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_REQUESTED_LATENCY, &usec, 0, NULL) == 0);
+
return usec;
}
@@ -1971,16 +2626,16 @@ void pa_sink_set_max_rewind_within_thread(pa_sink *s, size_t max_rewind) {
void *state = NULL;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
if (max_rewind == s->thread_info.max_rewind)
return;
s->thread_info.max_rewind = max_rewind;
- if (PA_SINK_IS_LINKED(s->thread_info.state)) {
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))
+ if (PA_SINK_IS_LINKED(s->thread_info.state))
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
pa_sink_input_update_max_rewind(i, s->thread_info.max_rewind);
- }
if (s->monitor_source)
pa_source_set_max_rewind_within_thread(s->monitor_source, s->thread_info.max_rewind);
@@ -1989,6 +2644,7 @@ void pa_sink_set_max_rewind_within_thread(pa_sink *s, size_t max_rewind) {
/* Called from main thread */
void pa_sink_set_max_rewind(pa_sink *s, size_t max_rewind) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
if (PA_SINK_IS_LINKED(s->state))
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_MAX_REWIND, NULL, max_rewind, NULL) == 0);
@@ -2001,6 +2657,7 @@ void pa_sink_set_max_request_within_thread(pa_sink *s, size_t max_request) {
void *state = NULL;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
if (max_request == s->thread_info.max_request)
return;
@@ -2010,7 +2667,7 @@ void pa_sink_set_max_request_within_thread(pa_sink *s, size_t max_request) {
if (PA_SINK_IS_LINKED(s->thread_info.state)) {
pa_sink_input *i;
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
pa_sink_input_update_max_request(i, s->thread_info.max_request);
}
}
@@ -2018,6 +2675,7 @@ void pa_sink_set_max_request_within_thread(pa_sink *s, size_t max_request) {
/* Called from main thread */
void pa_sink_set_max_request(pa_sink *s, size_t max_request) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
if (PA_SINK_IS_LINKED(s->state))
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_MAX_REQUEST, NULL, max_request, NULL) == 0);
@@ -2026,23 +2684,24 @@ void pa_sink_set_max_request(pa_sink *s, size_t max_request) {
}
/* Called from IO thread */
-void pa_sink_invalidate_requested_latency(pa_sink *s) {
+void pa_sink_invalidate_requested_latency(pa_sink *s, pa_bool_t dynamic) {
pa_sink_input *i;
void *state = NULL;
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
- if (!(s->flags & PA_SINK_DYNAMIC_LATENCY))
+ if ((s->flags & PA_SINK_DYNAMIC_LATENCY))
+ s->thread_info.requested_latency_valid = FALSE;
+ else if (dynamic)
return;
- s->thread_info.requested_latency_valid = FALSE;
-
if (PA_SINK_IS_LINKED(s->thread_info.state)) {
if (s->update_requested_latency)
s->update_requested_latency(s);
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
if (i->update_sink_requested_latency)
i->update_sink_requested_latency(i);
}
@@ -2051,6 +2710,7 @@ void pa_sink_invalidate_requested_latency(pa_sink *s) {
/* Called from main thread */
void pa_sink_set_latency_range(pa_sink *s, pa_usec_t min_latency, pa_usec_t max_latency) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
/* min_latency == 0: no limit
* min_latency anything else: specified limit
@@ -2084,28 +2744,28 @@ void pa_sink_set_latency_range(pa_sink *s, pa_usec_t min_latency, pa_usec_t max_
/* Called from main thread */
void pa_sink_get_latency_range(pa_sink *s, pa_usec_t *min_latency, pa_usec_t *max_latency) {
- pa_sink_assert_ref(s);
- pa_assert(min_latency);
- pa_assert(max_latency);
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(min_latency);
+ pa_assert(max_latency);
- if (PA_SINK_IS_LINKED(s->state)) {
- pa_usec_t r[2] = { 0, 0 };
+ if (PA_SINK_IS_LINKED(s->state)) {
+ pa_usec_t r[2] = { 0, 0 };
- pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_LATENCY_RANGE, r, 0, NULL) == 0);
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_LATENCY_RANGE, r, 0, NULL) == 0);
- *min_latency = r[0];
- *max_latency = r[1];
- } else {
- *min_latency = s->thread_info.min_latency;
- *max_latency = s->thread_info.max_latency;
- }
+ *min_latency = r[0];
+ *max_latency = r[1];
+ } else {
+ *min_latency = s->thread_info.min_latency;
+ *max_latency = s->thread_info.max_latency;
+ }
}
/* Called from IO thread */
void pa_sink_set_latency_range_within_thread(pa_sink *s, pa_usec_t min_latency, pa_usec_t max_latency) {
- void *state = NULL;
-
pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
pa_assert(min_latency >= ABSOLUTE_MIN_LATENCY);
pa_assert(max_latency <= ABSOLUTE_MAX_LATENCY);
@@ -2116,27 +2776,36 @@ void pa_sink_set_latency_range_within_thread(pa_sink *s, pa_usec_t min_latency,
max_latency == ABSOLUTE_MAX_LATENCY) ||
(s->flags & PA_SINK_DYNAMIC_LATENCY));
+ if (s->thread_info.min_latency == min_latency &&
+ s->thread_info.max_latency == max_latency)
+ return;
+
s->thread_info.min_latency = min_latency;
s->thread_info.max_latency = max_latency;
if (PA_SINK_IS_LINKED(s->thread_info.state)) {
pa_sink_input *i;
+ void *state = NULL;
- while ((i = pa_hashmap_iterate(s->thread_info.inputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
if (i->update_sink_latency_range)
i->update_sink_latency_range(i);
}
- pa_sink_invalidate_requested_latency(s);
+ pa_sink_invalidate_requested_latency(s, FALSE);
pa_source_set_latency_range_within_thread(s->monitor_source, min_latency, max_latency);
}
-/* Called from main thread, before the sink is put */
+/* Called from main thread */
void pa_sink_set_fixed_latency(pa_sink *s, pa_usec_t latency) {
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
- pa_assert(pa_sink_get_state(s) == PA_SINK_INIT);
+ if (s->flags & PA_SINK_DYNAMIC_LATENCY) {
+ pa_assert(latency == 0);
+ return;
+ }
if (latency < ABSOLUTE_MIN_LATENCY)
latency = ABSOLUTE_MIN_LATENCY;
@@ -2144,13 +2813,68 @@ void pa_sink_set_fixed_latency(pa_sink *s, pa_usec_t latency) {
if (latency > ABSOLUTE_MAX_LATENCY)
latency = ABSOLUTE_MAX_LATENCY;
- s->fixed_latency = latency;
+ if (PA_SINK_IS_LINKED(s->state))
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_FIXED_LATENCY, NULL, (int64_t) latency, NULL) == 0);
+ else
+ s->thread_info.fixed_latency = latency;
+
pa_source_set_fixed_latency(s->monitor_source, latency);
}
+/* Called from main thread */
+pa_usec_t pa_sink_get_fixed_latency(pa_sink *s) {
+ pa_usec_t latency;
+
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+
+ if (s->flags & PA_SINK_DYNAMIC_LATENCY)
+ return 0;
+
+ if (PA_SINK_IS_LINKED(s->state))
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_GET_FIXED_LATENCY, &latency, 0, NULL) == 0);
+ else
+ latency = s->thread_info.fixed_latency;
+
+ return latency;
+}
+
+/* Called from IO thread */
+void pa_sink_set_fixed_latency_within_thread(pa_sink *s, pa_usec_t latency) {
+ pa_sink_assert_ref(s);
+ pa_sink_assert_io_context(s);
+
+ if (s->flags & PA_SINK_DYNAMIC_LATENCY) {
+ pa_assert(latency == 0);
+ return;
+ }
+
+ pa_assert(latency >= ABSOLUTE_MIN_LATENCY);
+ pa_assert(latency <= ABSOLUTE_MAX_LATENCY);
+
+ if (s->thread_info.fixed_latency == latency)
+ return;
+
+ s->thread_info.fixed_latency = latency;
+
+ if (PA_SINK_IS_LINKED(s->thread_info.state)) {
+ pa_sink_input *i;
+ void *state = NULL;
+
+ PA_HASHMAP_FOREACH(i, s->thread_info.inputs, state)
+ if (i->update_sink_fixed_latency)
+ i->update_sink_fixed_latency(i);
+ }
+
+ pa_sink_invalidate_requested_latency(s, FALSE);
+
+ pa_source_set_fixed_latency_within_thread(s->monitor_source, latency);
+}
+
/* Called from main context */
size_t pa_sink_get_max_rewind(pa_sink *s) {
size_t r;
+ pa_assert_ctl_context();
pa_sink_assert_ref(s);
if (!PA_SINK_IS_LINKED(s->state))
@@ -2165,6 +2889,7 @@ size_t pa_sink_get_max_rewind(pa_sink *s) {
size_t pa_sink_get_max_request(pa_sink *s) {
size_t r;
pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
if (!PA_SINK_IS_LINKED(s->state))
return s->thread_info.max_request;
@@ -2175,6 +2900,52 @@ size_t pa_sink_get_max_request(pa_sink *s) {
}
/* Called from main context */
+int pa_sink_set_port(pa_sink *s, const char *name, pa_bool_t save) {
+ pa_device_port *port;
+ int ret;
+
+ pa_sink_assert_ref(s);
+ pa_assert_ctl_context();
+
+ if (!s->set_port) {
+ pa_log_debug("set_port() operation not implemented for sink %u \"%s\"", s->index, s->name);
+ return -PA_ERR_NOTIMPLEMENTED;
+ }
+
+ if (!s->ports)
+ return -PA_ERR_NOENTITY;
+
+ if (!(port = pa_hashmap_get(s->ports, name)))
+ return -PA_ERR_NOENTITY;
+
+ if (s->active_port == port) {
+ s->save_port = s->save_port || save;
+ return 0;
+ }
+
+ if (s->flags & PA_SINK_SYNC_VOLUME) {
+ struct sink_message_set_port msg = { .port = port, .ret = 0 };
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SINK_MESSAGE_SET_PORT, &msg, 0, NULL) == 0);
+ ret = msg.ret;
+ }
+ else
+ ret = s->set_port(s, port);
+
+ if (ret < 0)
+ return -PA_ERR_NOENTITY;
+
+ pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+
+ pa_log_info("Changed port of sink %u \"%s\" to %s", s->index, s->name, port->name);
+
+ s->active_port = port;
+ s->save_port = save;
+
+ pa_hook_fire(&s->core->hooks[PA_CORE_HOOK_SINK_PORT_CHANGED], s);
+
+ return 0;
+}
+
pa_bool_t pa_device_init_icon(pa_proplist *p, pa_bool_t is_sink) {
const char *ff, *c, *t = NULL, *s = "", *profile, *bus;
@@ -2243,28 +3014,341 @@ pa_bool_t pa_device_init_icon(pa_proplist *p, pa_bool_t is_sink) {
}
pa_bool_t pa_device_init_description(pa_proplist *p) {
- const char *s;
+ const char *s, *d = NULL, *k;
pa_assert(p);
if (pa_proplist_contains(p, PA_PROP_DEVICE_DESCRIPTION))
return TRUE;
if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_FORM_FACTOR)))
- if (pa_streq(s, "internal")) {
- pa_proplist_sets(p, PA_PROP_DEVICE_DESCRIPTION, _("Internal Audio"));
+ if (pa_streq(s, "internal"))
+ d = _("Internal Audio");
+
+ if (!d)
+ if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_CLASS)))
+ if (pa_streq(s, "modem"))
+ d = _("Modem");
+
+ if (!d)
+ d = pa_proplist_gets(p, PA_PROP_DEVICE_PRODUCT_NAME);
+
+ if (!d)
+ return FALSE;
+
+ k = pa_proplist_gets(p, PA_PROP_DEVICE_PROFILE_DESCRIPTION);
+
+ if (d && k)
+ pa_proplist_setf(p, PA_PROP_DEVICE_DESCRIPTION, _("%s %s"), d, k);
+ else if (d)
+ pa_proplist_sets(p, PA_PROP_DEVICE_DESCRIPTION, d);
+
+ return TRUE;
+}
+
+pa_bool_t pa_device_init_intended_roles(pa_proplist *p) {
+ const char *s;
+ pa_assert(p);
+
+ if (pa_proplist_contains(p, PA_PROP_DEVICE_INTENDED_ROLES))
+ return TRUE;
+
+ if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_FORM_FACTOR)))
+ if (pa_streq(s, "handset") || pa_streq(s, "hands-free")
+ || pa_streq(s, "headset")) {
+ pa_proplist_sets(p, PA_PROP_DEVICE_INTENDED_ROLES, "phone");
return TRUE;
}
- if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_CLASS)))
- if (pa_streq(s, "modem")) {
- pa_proplist_sets(p, PA_PROP_DEVICE_DESCRIPTION, _("Modem"));
- return TRUE;
+ return FALSE;
+}
+
+unsigned pa_device_init_priority(pa_proplist *p) {
+ const char *s;
+ unsigned priority = 0;
+
+ pa_assert(p);
+
+ if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_CLASS))) {
+
+ if (pa_streq(s, "sound"))
+ priority += 9000;
+ else if (!pa_streq(s, "modem"))
+ priority += 1000;
+ }
+
+ if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_FORM_FACTOR))) {
+
+ if (pa_streq(s, "internal"))
+ priority += 900;
+ else if (pa_streq(s, "speaker"))
+ priority += 500;
+ else if (pa_streq(s, "headphone"))
+ priority += 400;
+ }
+
+ if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_BUS))) {
+
+ if (pa_streq(s, "pci"))
+ priority += 50;
+ else if (pa_streq(s, "usb"))
+ priority += 40;
+ else if (pa_streq(s, "bluetooth"))
+ priority += 30;
+ }
+
+ if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_PROFILE_NAME))) {
+
+ if (pa_startswith(s, "analog-"))
+ priority += 9;
+ else if (pa_startswith(s, "iec958-"))
+ priority += 8;
+ }
+
+ return priority;
+}
+
+PA_STATIC_FLIST_DECLARE(pa_sink_volume_change, 0, pa_xfree);
+
+/* Called from the IO thread. */
+static pa_sink_volume_change *pa_sink_volume_change_new(pa_sink *s) {
+ pa_sink_volume_change *c;
+ if (!(c = pa_flist_pop(PA_STATIC_FLIST_GET(pa_sink_volume_change))))
+ c = pa_xnew(pa_sink_volume_change, 1);
+
+ PA_LLIST_INIT(pa_sink_volume_change, c);
+ c->at = 0;
+ pa_cvolume_reset(&c->hw_volume, s->sample_spec.channels);
+ return c;
+}
+
+/* Called from the IO thread. */
+static void pa_sink_volume_change_free(pa_sink_volume_change *c) {
+ pa_assert(c);
+ if (pa_flist_push(PA_STATIC_FLIST_GET(pa_sink_volume_change), c) < 0)
+ pa_xfree(c);
+}
+
+/* Called from the IO thread. */
+void pa_sink_volume_change_push(pa_sink *s) {
+ pa_sink_volume_change *c = NULL;
+ pa_sink_volume_change *nc = NULL;
+ uint32_t safety_margin = s->thread_info.volume_change_safety_margin;
+
+ const char *direction = NULL;
+
+ pa_assert(s);
+ nc = pa_sink_volume_change_new(s);
+
+ /* NOTE: There is already more different volumes in pa_sink that I can remember.
+ * Adding one more volume for HW would get us rid of this, but I am trying
+ * to survive with the ones we already have. */
+ pa_sw_cvolume_divide(&nc->hw_volume, &s->real_volume, &s->soft_volume);
+
+ if (!s->thread_info.volume_changes && pa_cvolume_equal(&nc->hw_volume, &s->thread_info.current_hw_volume)) {
+ pa_log_debug("Volume not changing");
+ pa_sink_volume_change_free(nc);
+ return;
+ }
+
+ nc->at = pa_sink_get_latency_within_thread(s);
+ nc->at += pa_rtclock_now() + s->thread_info.volume_change_extra_delay;
+
+ if (s->thread_info.volume_changes_tail) {
+ for (c = s->thread_info.volume_changes_tail; c; c = c->prev) {
+ /* If volume is going up let's do it a bit late. If it is going
+ * down let's do it a bit early. */
+ if (pa_cvolume_avg(&nc->hw_volume) > pa_cvolume_avg(&c->hw_volume)) {
+ if (nc->at + safety_margin > c->at) {
+ nc->at += safety_margin;
+ direction = "up";
+ break;
+ }
+ }
+ else if (nc->at - safety_margin > c->at) {
+ nc->at -= safety_margin;
+ direction = "down";
+ break;
+ }
}
+ }
- if ((s = pa_proplist_gets(p, PA_PROP_DEVICE_PRODUCT_NAME))) {
- pa_proplist_sets(p, PA_PROP_DEVICE_DESCRIPTION, s);
- return TRUE;
+ if (c == NULL) {
+ if (pa_cvolume_avg(&nc->hw_volume) > pa_cvolume_avg(&s->thread_info.current_hw_volume)) {
+ nc->at += safety_margin;
+ direction = "up";
+ } else {
+ nc->at -= safety_margin;
+ direction = "down";
+ }
+ PA_LLIST_PREPEND(pa_sink_volume_change, s->thread_info.volume_changes, nc);
+ }
+ else {
+ PA_LLIST_INSERT_AFTER(pa_sink_volume_change, s->thread_info.volume_changes, c, nc);
}
- return FALSE;
+ pa_log_debug("Volume going %s to %d at %llu", direction, pa_cvolume_avg(&nc->hw_volume), (long long unsigned) nc->at);
+
+ /* We can ignore volume events that came earlier but should happen later than this. */
+ PA_LLIST_FOREACH(c, nc->next) {
+ pa_log_debug("Volume change to %d at %llu was dropped", pa_cvolume_avg(&c->hw_volume), (long long unsigned) c->at);
+ pa_sink_volume_change_free(c);
+ }
+ nc->next = NULL;
+ s->thread_info.volume_changes_tail = nc;
+}
+
+/* Called from the IO thread. */
+static void pa_sink_volume_change_flush(pa_sink *s) {
+ pa_sink_volume_change *c = s->thread_info.volume_changes;
+ pa_assert(s);
+ s->thread_info.volume_changes = NULL;
+ s->thread_info.volume_changes_tail = NULL;
+ while (c) {
+ pa_sink_volume_change *next = c->next;
+ pa_sink_volume_change_free(c);
+ c = next;
+ }
+}
+
+/* Called from the IO thread. */
+pa_bool_t pa_sink_volume_change_apply(pa_sink *s, pa_usec_t *usec_to_next) {
+ pa_usec_t now = pa_rtclock_now();
+ pa_bool_t ret = FALSE;
+
+ pa_assert(s);
+ pa_assert(s->write_volume);
+
+ while (s->thread_info.volume_changes && now >= s->thread_info.volume_changes->at) {
+ pa_sink_volume_change *c = s->thread_info.volume_changes;
+ PA_LLIST_REMOVE(pa_sink_volume_change, s->thread_info.volume_changes, c);
+ pa_log_debug("Volume change to %d at %llu was written %llu usec late",
+ pa_cvolume_avg(&c->hw_volume), (long long unsigned) c->at, (long long unsigned) (now - c->at));
+ ret = TRUE;
+ s->thread_info.current_hw_volume = c->hw_volume;
+ pa_sink_volume_change_free(c);
+ }
+
+ if (s->write_volume && ret)
+ s->write_volume(s);
+
+ if (s->thread_info.volume_changes) {
+ if (usec_to_next)
+ *usec_to_next = s->thread_info.volume_changes->at - now;
+ if (pa_log_ratelimit(PA_LOG_DEBUG))
+ pa_log_debug("Next volume change in %lld usec", (long long) (s->thread_info.volume_changes->at - now));
+ }
+ else {
+ if (usec_to_next)
+ *usec_to_next = 0;
+ s->thread_info.volume_changes_tail = NULL;
+ }
+ return ret;
+}
+
+/* Called from the IO thread. */
+static void pa_sink_volume_change_rewind(pa_sink *s, size_t nbytes) {
+ /* All the queued volume events later than current latency are shifted to happen earlier. */
+ pa_sink_volume_change *c;
+ pa_volume_t prev_vol = pa_cvolume_avg(&s->thread_info.current_hw_volume);
+ pa_usec_t rewound = pa_bytes_to_usec(nbytes, &s->sample_spec);
+ pa_usec_t limit = pa_sink_get_latency_within_thread(s);
+
+ pa_log_debug("latency = %lld", (long long) limit);
+ limit += pa_rtclock_now() + s->thread_info.volume_change_extra_delay;
+
+ PA_LLIST_FOREACH(c, s->thread_info.volume_changes) {
+ pa_usec_t modified_limit = limit;
+ if (prev_vol > pa_cvolume_avg(&c->hw_volume))
+ modified_limit -= s->thread_info.volume_change_safety_margin;
+ else
+ modified_limit += s->thread_info.volume_change_safety_margin;
+ if (c->at > modified_limit) {
+ c->at -= rewound;
+ if (c->at < modified_limit)
+ c->at = modified_limit;
+ }
+ prev_vol = pa_cvolume_avg(&c->hw_volume);
+ }
+ pa_sink_volume_change_apply(s, NULL);
+}
+
+/* Called from the main thread */
+/* Gets the list of formats supported by the sink. The members and idxset must
+ * be freed by the caller. */
+pa_idxset* pa_sink_get_formats(pa_sink *s) {
+ pa_idxset *ret;
+
+ pa_assert(s);
+
+ if (s->get_formats) {
+ /* Sink supports format query, all is good */
+ ret = s->get_formats(s);
+ } else {
+ /* Sink doesn't support format query, so assume it does PCM */
+ pa_format_info *f = pa_format_info_new();
+ f->encoding = PA_ENCODING_PCM;
+
+ ret = pa_idxset_new(NULL, NULL);
+ pa_idxset_put(ret, f, NULL);
+ }
+
+ return ret;
+}
+
+/* Called from the main thread */
+/* Checks if the sink can accept this format */
+pa_bool_t pa_sink_check_format(pa_sink *s, pa_format_info *f)
+{
+ pa_idxset *formats = NULL;
+ pa_bool_t ret = FALSE;
+
+ pa_assert(s);
+ pa_assert(f);
+
+ formats = pa_sink_get_formats(s);
+
+ if (formats) {
+ pa_format_info *finfo_device;
+ uint32_t i;
+
+ PA_IDXSET_FOREACH(finfo_device, formats, i) {
+ if (pa_format_info_is_compatible(finfo_device, f)) {
+ ret = TRUE;
+ break;
+ }
+ }
+
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ }
+
+ return ret;
+}
+
+/* Called from the main thread */
+/* Calculates the intersection between formats supported by the sink and
+ * in_formats, and returns these, in the order of the sink's formats. */
+pa_idxset* pa_sink_check_formats(pa_sink *s, pa_idxset *in_formats) {
+ pa_idxset *out_formats = pa_idxset_new(NULL, NULL), *sink_formats = NULL;
+ pa_format_info *f_sink, *f_in;
+ uint32_t i, j;
+
+ pa_assert(s);
+
+ if (!in_formats || pa_idxset_isempty(in_formats))
+ goto done;
+
+ sink_formats = pa_sink_get_formats(s);
+
+ PA_IDXSET_FOREACH(f_sink, sink_formats, i) {
+ PA_IDXSET_FOREACH(f_in, in_formats, j) {
+ if (pa_format_info_is_compatible(f_sink, f_in))
+ pa_idxset_put(out_formats, pa_format_info_copy(f_in), NULL);
+ }
+ }
+
+done:
+ if (sink_formats)
+ pa_idxset_free(sink_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ return out_formats;
}
diff --git a/src/pulsecore/sink.h b/src/pulsecore/sink.h
index e33b3cfc..85c22ec6 100644
--- a/src/pulsecore/sink.h
+++ b/src/pulsecore/sink.h
@@ -24,6 +24,8 @@
***/
typedef struct pa_sink pa_sink;
+typedef struct pa_device_port pa_device_port;
+typedef struct pa_sink_volume_change pa_sink_volume_change;
#include <inttypes.h>
@@ -34,13 +36,16 @@ typedef struct pa_sink pa_sink;
#include <pulsecore/core.h>
#include <pulsecore/idxset.h>
+#include <pulsecore/memchunk.h>
#include <pulsecore/source.h>
#include <pulsecore/module.h>
-#include <pulsecore/refcnt.h>
+#include <pulsecore/asyncmsgq.h>
#include <pulsecore/msgobject.h>
#include <pulsecore/rtpoll.h>
#include <pulsecore/card.h>
#include <pulsecore/queue.h>
+#include <pulsecore/thread-mq.h>
+#include <pulsecore/sink-input.h>
#define PA_MAX_INPUTS_PER_SINK 32
@@ -49,13 +54,26 @@ static inline pa_bool_t PA_SINK_IS_LINKED(pa_sink_state_t x) {
return x == PA_SINK_RUNNING || x == PA_SINK_IDLE || x == PA_SINK_SUSPENDED;
}
+struct pa_device_port {
+ char *name;
+ char *description;
+
+ unsigned priority;
+
+ /* .. followed by some implementation specific data */
+};
+
+#define PA_DEVICE_PORT_DATA(d) ((void*) ((uint8_t*) d + PA_ALIGN(sizeof(pa_device_port))))
+
struct pa_sink {
pa_msgobject parent;
uint32_t index;
pa_core *core;
+
pa_sink_state_t state;
pa_sink_flags_t flags;
+ pa_suspend_cause_t suspend_cause;
char *name;
char *driver; /* may be NULL */
@@ -70,60 +88,121 @@ struct pa_sink {
pa_idxset *inputs;
unsigned n_corked;
pa_source *monitor_source;
+ pa_sink_input *input_to_master; /* non-NULL only for filter sinks */
pa_volume_t base_volume; /* shall be constant */
unsigned n_volume_steps; /* shall be constant */
/* Also see http://pulseaudio.org/wiki/InternalVolumes */
- pa_cvolume virtual_volume; /* The volume clients are informed about */
- pa_cvolume reference_volume; /* The volume taken as refernce base for relative sink input volumes */
+ pa_cvolume reference_volume; /* The volume exported and taken as reference base for relative sink input volumes */
+ pa_cvolume real_volume; /* The volume that the hardware is configured to */
pa_cvolume soft_volume; /* The internal software volume we apply to all PCM data while it passes through */
+
pa_bool_t muted:1;
pa_bool_t refresh_volume:1;
pa_bool_t refresh_muted:1;
+ pa_bool_t save_port:1;
+ pa_bool_t save_volume:1;
+ pa_bool_t save_muted:1;
pa_asyncmsgq *asyncmsgq;
- pa_rtpoll *rtpoll;
pa_memchunk silence;
- pa_usec_t fixed_latency; /* for sinks with PA_SINK_DYNAMIC_LATENCY this is 0 */
+ pa_hashmap *ports;
+ pa_device_port *active_port;
+
+ unsigned priority;
/* Called when the main loop requests a state change. Called from
* main loop context. If returns -1 the state change will be
* inhibited */
int (*set_state)(pa_sink *s, pa_sink_state_t state); /* may be NULL */
- /* Callled when the volume is queried. Called from main loop
- * context. If this is NULL a PA_SINK_MESSAGE_GET_VOLUME message
- * will be sent to the IO thread instead. If refresh_volume is
- * FALSE neither this function is called nor a message is sent. */
+ /* Sink drivers that support hardware volume may set this
+ * callback. This is called when the current volume needs to be
+ * re-read from the hardware.
+ *
+ * There are two ways for drivers to implement hardware volume
+ * query: either set this callback or handle
+ * PA_SINK_MESSAGE_GET_VOLUME. The callback implementation or the
+ * message handler must update s->real_volume and s->soft_volume
+ * (using pa_sink_set_soft_volume()) to match the current hardware
+ * volume.
+ *
+ * If PA_SINK_SYNC_VOLUME is not set, then this is called from the
+ * main thread before sending PA_SINK_MESSAGE_GET_VOLUME, so in
+ * this case the driver can choose whether to read the volume from
+ * the hardware in the main thread or in the IO thread.
+ *
+ * If PA_SINK_SYNC_VOLUME is set, then this is called from the IO
+ * thread within the default handler for
+ * PA_SINK_MESSAGE_GET_VOLUME (the main thread is waiting while
+ * the message is being processed), so there's no choice of where
+ * to do the volume reading - it has to be done in the IO thread
+ * always. */
void (*get_volume)(pa_sink *s); /* may be NULL */
- /* Called when the volume shall be changed. Called from main loop
- * context. If this is NULL a PA_SINK_MESSAGE_SET_VOLUME message
- * will be sent to the IO thread instead. */
- void (*set_volume)(pa_sink *s); /* dito */
-
- /* Called when the mute setting is queried. Called from main loop
- * context. If this is NULL a PA_SINK_MESSAGE_GET_MUTE message
- * will be sent to the IO thread instead. If refresh_mute is
- * FALSE neither this function is called nor a message is sent.*/
- void (*get_mute)(pa_sink *s); /* dito */
-
- /* Called when the mute setting shall be changed. Called from main
- * loop context. If this is NULL a PA_SINK_MESSAGE_SET_MUTE
- * message will be sent to the IO thread instead. */
- void (*set_mute)(pa_sink *s); /* dito */
+ /* Sink drivers that support hardware volume must set this
+ * callback. This is called when the hardware volume needs to be
+ * updated.
+ *
+ * If PA_SINK_SYNC_VOLUME is not set, then this is called from the
+ * main thread. The callback implementation must set the hardware
+ * volume according to s->real_volume. If the driver can't set the
+ * hardware volume to the exact requested value, it has to update
+ * s->real_volume and/or s->soft_volume so that they together
+ * match the actual hardware volume that was set.
+ *
+ * If PA_SINK_SYNC_VOLUME is set, then this is called from the IO
+ * thread. The callback implementation must not actually set the
+ * hardware volume yet, but it must check how close to the
+ * requested volume the hardware volume can be set, and update
+ * s->real_volume and/or s->soft_volume so that they together
+ * match the actual hardware volume that will be set later in the
+ * write_volume callback. */
+ void (*set_volume)(pa_sink *s); /* ditto */
+
+ /* Sink drivers that set PA_SINK_SYNC_VOLUME must provide this
+ * callback. This callback is not used with sinks that do not set
+ * PA_SINK_SYNC_VOLUME. This is called from the IO thread when a
+ * pending hardware volume change has to be written to the
+ * hardware. The requested volume is passed to the callback
+ * implementation in s->thread_info.current_hw_volume.
+ *
+ * The call is done inside pa_sink_volume_change_apply(), which is
+ * not called automatically - it is the driver's responsibility to
+ * schedule that function to be called at the right times in the
+ * IO thread. */
+ void (*write_volume)(pa_sink *s); /* ditto */
+
+ /* Called when the mute setting is queried. A PA_SINK_MESSAGE_GET_MUTE
+ * message will also be sent. Called from IO thread if PA_SINK_SYNC_VOLUME
+ * flag is set otherwise from main loop context. If refresh_mute is FALSE
+ * neither this function is called nor a message is sent.*/
+ void (*get_mute)(pa_sink *s); /* ditto */
+
+ /* Called when the mute setting shall be changed. A PA_SINK_MESSAGE_SET_MUTE
+ * message will also be sent. Called from IO thread if PA_SINK_SYNC_VOLUME
+ * flag is set otherwise from main loop context. */
+ void (*set_mute)(pa_sink *s); /* ditto */
/* Called when a rewind request is issued. Called from IO thread
* context. */
- void (*request_rewind)(pa_sink *s); /* dito */
+ void (*request_rewind)(pa_sink *s); /* ditto */
/* Called when a the requested latency is changed. Called from IO
* thread context. */
- void (*update_requested_latency)(pa_sink *s); /* dito */
+ void (*update_requested_latency)(pa_sink *s); /* ditto */
+
+ /* Called whenever the port shall be changed. Called from main
+ * thread. */
+ int (*set_port)(pa_sink *s, pa_device_port *port); /* ditto */
+
+ /* Called to get the list of formats supported by the sink, sorted
+ * in descending order of preference. */
+ pa_idxset* (*get_formats)(pa_sink *s); /* ditto */
/* Contains copies of the above data so that the real-time worker
* thread can work without access locking */
@@ -131,9 +210,14 @@ struct pa_sink {
pa_sink_state_t state;
pa_hashmap *inputs;
+ pa_rtpoll *rtpoll;
+
pa_cvolume soft_volume;
pa_bool_t soft_muted:1;
+ /* The requested latency is used for dynamic latency
+ * sinks. For fixed latency sinks it is always identical to
+ * the fixed_latency. See below. */
pa_bool_t requested_latency_valid:1;
pa_usec_t requested_latency;
@@ -149,20 +233,44 @@ struct pa_sink {
size_t rewind_nbytes;
pa_bool_t rewind_requested;
+ /* Both dynamic and fixed latencies will be clamped to this
+ * range. */
pa_usec_t min_latency; /* we won't go below this latency */
pa_usec_t max_latency; /* An upper limit for the latencies */
+
+ /* 'Fixed' simply means that the latency is exclusively
+ * decided on by the sink, and the clients have no influence
+ * in changing it */
+ pa_usec_t fixed_latency; /* for sinks with PA_SINK_DYNAMIC_LATENCY this is 0 */
+
+ /* Delayed volume change events are queued here. The events
+ * are stored in expiration order. The one expiring next is in
+ * the head of the list. */
+ PA_LLIST_HEAD(pa_sink_volume_change, volume_changes);
+ pa_sink_volume_change *volume_changes_tail;
+ /* This value is updated in pa_sink_volume_change_apply() and
+ * used only by sinks with PA_SINK_SYNC_VOLUME. */
+ pa_cvolume current_hw_volume;
+
+ /* The amount of usec volume up events are delayed and volume
+ * down events are made earlier. */
+ uint32_t volume_change_safety_margin;
+ /* Usec delay added to all volume change events, may be negative. */
+ int32_t volume_change_extra_delay;
} thread_info;
void *userdata;
};
-PA_DECLARE_CLASS(pa_sink);
+PA_DECLARE_PUBLIC_CLASS(pa_sink);
#define PA_SINK(s) (pa_sink_cast(s))
typedef enum pa_sink_message {
PA_SINK_MESSAGE_ADD_INPUT,
PA_SINK_MESSAGE_REMOVE_INPUT,
PA_SINK_MESSAGE_GET_VOLUME,
+ PA_SINK_MESSAGE_SET_SHARED_VOLUME,
+ PA_SINK_MESSAGE_SET_VOLUME_SYNCED,
PA_SINK_MESSAGE_SET_VOLUME,
PA_SINK_MESSAGE_SYNC_VOLUMES,
PA_SINK_MESSAGE_GET_MUTE,
@@ -176,10 +284,14 @@ typedef enum pa_sink_message {
PA_SINK_MESSAGE_DETACH,
PA_SINK_MESSAGE_SET_LATENCY_RANGE,
PA_SINK_MESSAGE_GET_LATENCY_RANGE,
+ PA_SINK_MESSAGE_SET_FIXED_LATENCY,
+ PA_SINK_MESSAGE_GET_FIXED_LATENCY,
PA_SINK_MESSAGE_GET_MAX_REWIND,
PA_SINK_MESSAGE_GET_MAX_REQUEST,
PA_SINK_MESSAGE_SET_MAX_REWIND,
PA_SINK_MESSAGE_SET_MAX_REQUEST,
+ PA_SINK_MESSAGE_SET_PORT,
+ PA_SINK_MESSAGE_UPDATE_VOLUME_AND_MUTE,
PA_SINK_MESSAGE_MAX
} pa_sink_message_t;
@@ -191,6 +303,9 @@ typedef struct pa_sink_new_data {
pa_module *module;
pa_card *card;
+ pa_hashmap *ports;
+ char *active_port;
+
pa_sample_spec sample_spec;
pa_channel_map channel_map;
pa_cvolume volume;
@@ -202,6 +317,10 @@ typedef struct pa_sink_new_data {
pa_bool_t muted_is_set:1;
pa_bool_t namereg_fail:1;
+
+ pa_bool_t save_port:1;
+ pa_bool_t save_volume:1;
+ pa_bool_t save_muted:1;
} pa_sink_new_data;
pa_sink_new_data* pa_sink_new_data_init(pa_sink_new_data *data);
@@ -210,6 +329,7 @@ void pa_sink_new_data_set_sample_spec(pa_sink_new_data *data, const pa_sample_sp
void pa_sink_new_data_set_channel_map(pa_sink_new_data *data, const pa_channel_map *map);
void pa_sink_new_data_set_volume(pa_sink_new_data *data, const pa_cvolume *volume);
void pa_sink_new_data_set_muted(pa_sink_new_data *data, pa_bool_t mute);
+void pa_sink_new_data_set_port(pa_sink_new_data *data, const char *port);
void pa_sink_new_data_done(pa_sink_new_data *data);
/*** To be called exclusively by the sink driver, from main context */
@@ -238,8 +358,12 @@ void pa_sink_set_soft_volume(pa_sink *s, const pa_cvolume *volume);
void pa_sink_volume_changed(pa_sink *s, const pa_cvolume *new_volume);
void pa_sink_mute_changed(pa_sink *s, pa_bool_t new_muted);
+void pa_sink_update_flags(pa_sink *s, pa_sink_flags_t mask, pa_sink_flags_t value);
+
pa_bool_t pa_device_init_description(pa_proplist *p);
pa_bool_t pa_device_init_icon(pa_proplist *p, pa_bool_t is_sink);
+pa_bool_t pa_device_init_intended_roles(pa_proplist *p);
+unsigned pa_device_init_priority(pa_proplist *p);
/**** May be called by everyone, from main context */
@@ -247,35 +371,46 @@ pa_bool_t pa_device_init_icon(pa_proplist *p, pa_bool_t is_sink);
pa_usec_t pa_sink_get_latency(pa_sink *s);
pa_usec_t pa_sink_get_requested_latency(pa_sink *s);
void pa_sink_get_latency_range(pa_sink *s, pa_usec_t *min_latency, pa_usec_t *max_latency);
+pa_usec_t pa_sink_get_fixed_latency(pa_sink *s);
size_t pa_sink_get_max_rewind(pa_sink *s);
size_t pa_sink_get_max_request(pa_sink *s);
int pa_sink_update_status(pa_sink*s);
-int pa_sink_suspend(pa_sink *s, pa_bool_t suspend);
-int pa_sink_suspend_all(pa_core *c, pa_bool_t suspend);
+int pa_sink_suspend(pa_sink *s, pa_bool_t suspend, pa_suspend_cause_t cause);
+int pa_sink_suspend_all(pa_core *c, pa_bool_t suspend, pa_suspend_cause_t cause);
+
+/* Use this instead of checking s->flags & PA_SINK_FLAT_VOLUME directly. */
+pa_bool_t pa_sink_flat_volume_enabled(pa_sink *s);
-void pa_sink_update_flat_volume(pa_sink *s, pa_cvolume *new_volume);
-void pa_sink_propagate_flat_volume(pa_sink *s);
+/* Is the sink in passthrough mode? (that is, is there a passthrough sink input
+ * connected to this sink? */
+pa_bool_t pa_sink_is_passthrough(pa_sink *s);
-void pa_sink_set_volume(pa_sink *sink, const pa_cvolume *volume, pa_bool_t propagate, pa_bool_t sendmsg, pa_bool_t become_reference);
-const pa_cvolume *pa_sink_get_volume(pa_sink *sink, pa_bool_t force_refresh, pa_bool_t reference);
+void pa_sink_set_volume(pa_sink *sink, const pa_cvolume *volume, pa_bool_t sendmsg, pa_bool_t save);
+const pa_cvolume *pa_sink_get_volume(pa_sink *sink, pa_bool_t force_refresh);
-void pa_sink_set_mute(pa_sink *sink, pa_bool_t mute);
+void pa_sink_set_mute(pa_sink *sink, pa_bool_t mute, pa_bool_t save);
pa_bool_t pa_sink_get_mute(pa_sink *sink, pa_bool_t force_refresh);
pa_bool_t pa_sink_update_proplist(pa_sink *s, pa_update_mode_t mode, pa_proplist *p);
+int pa_sink_set_port(pa_sink *s, const char *name, pa_bool_t save);
+
unsigned pa_sink_linked_by(pa_sink *s); /* Number of connected streams */
unsigned pa_sink_used_by(pa_sink *s); /* Number of connected streams which are not corked */
unsigned pa_sink_check_suspend(pa_sink *s); /* Returns how many streams are active that don't allow suspensions */
#define pa_sink_get_state(s) ((s)->state)
/* Moves all inputs away, and stores them in pa_queue */
-pa_queue *pa_sink_move_all_start(pa_sink *s);
+pa_queue *pa_sink_move_all_start(pa_sink *s, pa_queue *q);
void pa_sink_move_all_finish(pa_sink *s, pa_queue *q, pa_bool_t save);
void pa_sink_move_all_fail(pa_queue *q);
+pa_idxset* pa_sink_get_formats(pa_sink *s);
+pa_bool_t pa_sink_check_format(pa_sink *s, pa_format_info *f);
+pa_idxset* pa_sink_check_formats(pa_sink *s, pa_idxset *in_formats);
+
/*** To be called exclusively by the sink driver, from IO context */
void pa_sink_render(pa_sink*s, size_t length, pa_memchunk *result);
@@ -296,13 +431,27 @@ void pa_sink_set_max_rewind_within_thread(pa_sink *s, size_t max_rewind);
void pa_sink_set_max_request_within_thread(pa_sink *s, size_t max_request);
void pa_sink_set_latency_range_within_thread(pa_sink *s, pa_usec_t min_latency, pa_usec_t max_latency);
+void pa_sink_set_fixed_latency_within_thread(pa_sink *s, pa_usec_t latency);
+
+void pa_sink_update_volume_and_mute(pa_sink *s);
+
+pa_bool_t pa_sink_volume_change_apply(pa_sink *s, pa_usec_t *usec_to_next);
/*** To be called exclusively by sink input drivers, from IO context */
void pa_sink_request_rewind(pa_sink*s, size_t nbytes);
-void pa_sink_invalidate_requested_latency(pa_sink *s);
+void pa_sink_invalidate_requested_latency(pa_sink *s, pa_bool_t dynamic);
pa_usec_t pa_sink_get_latency_within_thread(pa_sink *s);
+pa_device_port *pa_device_port_new(const char *name, const char *description, size_t extra);
+void pa_device_port_free(pa_device_port *p);
+
+/* Verify that we called in IO context (aka 'thread context), or that
+ * the sink is not yet set up, i.e. the thread not set up yet. See
+ * pa_assert_io_context() in thread-mq.h for more information. */
+#define pa_sink_assert_io_context(s) \
+ pa_assert(pa_thread_mq_get() || !PA_SINK_IS_LINKED((s)->state))
+
#endif
diff --git a/src/pulsecore/sndfile-util.c b/src/pulsecore/sndfile-util.c
index 032aefca..ab6485d9 100644
--- a/src/pulsecore/sndfile-util.c
+++ b/src/pulsecore/sndfile-util.c
@@ -29,7 +29,6 @@
#include <pulse/utf8.h>
#include <pulsecore/macro.h>
-#include <pulsecore/core-util.h>
#include "sndfile-util.h"
@@ -51,6 +50,9 @@ int pa_sndfile_read_sample_spec(SNDFILE *sf, pa_sample_spec *ss) {
break;
case SF_FORMAT_PCM_24:
+ ss->format = PA_SAMPLE_S24NE;
+ break;
+
case SF_FORMAT_PCM_32:
ss->format = PA_SAMPLE_S32NE;
break;
@@ -106,14 +108,18 @@ int pa_sndfile_write_sample_spec(SF_INFO *sfi, pa_sample_spec *ss) {
case PA_SAMPLE_S24LE:
case PA_SAMPLE_S24BE:
+ ss->format = PA_SAMPLE_S24NE;
+ sfi->format |= SF_FORMAT_PCM_24;
+ break;
+
case PA_SAMPLE_S24_32LE:
case PA_SAMPLE_S24_32BE:
- ss->format = PA_SAMPLE_S32NE;
- sfi->format |= SF_FORMAT_PCM_24;
+ ss->format = PA_SAMPLE_S24_32NE;
+ sfi->format |= SF_FORMAT_PCM_32;
break;
case PA_SAMPLE_S32LE:
- case PA_SAMPLE_S32RE:
+ case PA_SAMPLE_S32BE:
ss->format = PA_SAMPLE_S32NE;
sfi->format |= SF_FORMAT_PCM_32;
break;
@@ -297,8 +303,7 @@ int pa_sndfile_write_channel_map(SNDFILE *sf, pa_channel_map *cm) {
channels[c] = table[cm->map[c]];
}
- if (!sf_command(sf, SFC_SET_CHANNEL_MAP_INFO,
- channels, sizeof(channels[0]) * cm->channels)) {
+ if (!sf_command(sf, SFC_SET_CHANNEL_MAP_INFO, channels, sizeof(channels[0]) * cm->channels)) {
pa_xfree(channels);
return -1;
}
@@ -362,6 +367,7 @@ pa_sndfile_readf_t pa_sndfile_readf_function(const pa_sample_spec *ss) {
return (pa_sndfile_readf_t) sf_readf_short;
case PA_SAMPLE_S32NE:
+ case PA_SAMPLE_S24_32NE:
return (pa_sndfile_readf_t) sf_readf_int;
case PA_SAMPLE_FLOAT32NE:
@@ -384,6 +390,7 @@ pa_sndfile_writef_t pa_sndfile_writef_function(const pa_sample_spec *ss) {
return (pa_sndfile_writef_t) sf_writef_short;
case PA_SAMPLE_S32NE:
+ case PA_SAMPLE_S24_32NE:
return (pa_sndfile_writef_t) sf_writef_int;
case PA_SAMPLE_FLOAT32NE:
@@ -416,7 +423,7 @@ int pa_sndfile_format_from_string(const char *name) {
pa_assert_se(sf_command(NULL, SFC_GET_FORMAT_MAJOR, &fi, sizeof(fi)) == 0);
if (strcasecmp(name, fi.name) == 0)
- return i;
+ return fi.format;
}
/* Then, try to match via the full extension */
@@ -428,7 +435,7 @@ int pa_sndfile_format_from_string(const char *name) {
pa_assert_se(sf_command(NULL, SFC_GET_FORMAT_MAJOR, &fi, sizeof(fi)) == 0);
if (strcasecmp(name, fi.extension) == 0)
- return i;
+ return fi.format;
}
/* Then, try to match via the start of the type string */
@@ -439,8 +446,8 @@ int pa_sndfile_format_from_string(const char *name) {
pa_assert_se(sf_command(NULL, SFC_GET_FORMAT_MAJOR, &fi, sizeof(fi)) == 0);
- if (strncasecmp(name, fi.extension, strlen(name)) == 0)
- return i;
+ if (strncasecmp(name, fi.name, strlen(name)) == 0)
+ return fi.format;
}
return -1;
diff --git a/src/pulsecore/socket-client.c b/src/pulsecore/socket-client.c
index dc23bff6..23d5d880 100644
--- a/src/pulsecore/socket-client.c
+++ b/src/pulsecore/socket-client.c
@@ -32,15 +32,9 @@
#include <string.h>
#include <stdlib.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
#ifdef HAVE_SYS_UN_H
#include <sys/un.h>
#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
@@ -52,18 +46,21 @@
#include <asyncns.h>
#endif
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/winsock.h>
-#include <pulsecore/core-error.h>
+#include <pulsecore/socket.h>
#include <pulsecore/socket-util.h>
+#include <pulsecore/core-error.h>
+#include <pulsecore/core-rtclock.h>
#include <pulsecore/core-util.h>
#include <pulsecore/socket-util.h>
#include <pulsecore/log.h>
#include <pulsecore/parseaddr.h>
#include <pulsecore/macro.h>
#include <pulsecore/refcnt.h>
+#include <pulsecore/arpa-inet.h>
#include "socket-client.h"
@@ -71,14 +68,18 @@
struct pa_socket_client {
PA_REFCNT_DECLARE;
- pa_mainloop_api *mainloop;
int fd;
+
+ pa_mainloop_api *mainloop;
pa_io_event *io_event;
pa_time_event *timeout_event;
pa_defer_event *defer_event;
+
pa_socket_client_cb_t callback;
void *userdata;
+
pa_bool_t local;
+
#ifdef HAVE_LIBASYNCNS
asyncns_t *asyncns;
asyncns_query_t * asyncns_query;
@@ -90,22 +91,10 @@ static pa_socket_client* socket_client_new(pa_mainloop_api *m) {
pa_socket_client *c;
pa_assert(m);
- c = pa_xnew(pa_socket_client, 1);
+ c = pa_xnew0(pa_socket_client, 1);
PA_REFCNT_INIT(c);
c->mainloop = m;
c->fd = -1;
- c->io_event = NULL;
- c->timeout_event = NULL;
- c->defer_event = NULL;
- c->callback = NULL;
- c->userdata = NULL;
- c->local = FALSE;
-
-#ifdef HAVE_LIBASYNCNS
- c->asyncns = NULL;
- c->asyncns_io_event = NULL;
- c->asyncns_query = NULL;
-#endif
return c;
}
@@ -161,7 +150,6 @@ static void do_call(pa_socket_client *c) {
}
io = pa_iochannel_new(c->mainloop, c->fd, c->fd);
- pa_assert(io);
finish:
if (!io && c->fd >= 0)
@@ -170,7 +158,6 @@ finish:
free_events(c);
- pa_assert(c->callback);
c->callback(c, io, c->userdata);
pa_socket_client_unref(c);
@@ -200,8 +187,6 @@ static void connect_io_cb(pa_mainloop_api*m, pa_io_event *e, int fd, pa_io_event
}
static int do_connect(pa_socket_client *c, const struct sockaddr *sa, socklen_t len) {
- int r;
-
pa_assert(c);
pa_assert(PA_REFCNT_VALUE(c) >= 1);
pa_assert(sa);
@@ -209,7 +194,7 @@ static int do_connect(pa_socket_client *c, const struct sockaddr *sa, socklen_t
pa_make_fd_nonblock(c->fd);
- if ((r = connect(c->fd, sa, len)) < 0) {
+ if (connect(c->fd, sa, len) < 0) {
#ifdef OS_IS_WIN32
if (WSAGetLastError() != EWOULDBLOCK) {
pa_log_debug("connect(): %d", WSAGetLastError());
@@ -220,9 +205,9 @@ static int do_connect(pa_socket_client *c, const struct sockaddr *sa, socklen_t
return -1;
}
- pa_assert_se(c->io_event = c->mainloop->io_new(c->mainloop, c->fd, PA_IO_EVENT_OUTPUT, connect_io_cb, c));
+ c->io_event = c->mainloop->io_new(c->mainloop, c->fd, PA_IO_EVENT_OUTPUT, connect_io_cb, c);
} else
- pa_assert_se(c->defer_event = c->mainloop->defer_new(c->mainloop, connect_defer_cb, c));
+ c->defer_event = c->mainloop->defer_new(c->mainloop, connect_defer_cb, c);
return 0;
}
@@ -233,7 +218,7 @@ pa_socket_client* pa_socket_client_new_ipv4(pa_mainloop_api *m, uint32_t address
pa_assert(m);
pa_assert(port > 0);
- memset(&sa, 0, sizeof(sa));
+ pa_zero(sa);
sa.sin_family = AF_INET;
sa.sin_port = htons(port);
sa.sin_addr.s_addr = htonl(address);
@@ -241,28 +226,24 @@ pa_socket_client* pa_socket_client_new_ipv4(pa_mainloop_api *m, uint32_t address
return pa_socket_client_new_sockaddr(m, (struct sockaddr*) &sa, sizeof(sa));
}
-#ifdef HAVE_SYS_UN_H
pa_socket_client* pa_socket_client_new_unix(pa_mainloop_api *m, const char *filename) {
+#ifdef HAVE_SYS_UN_H
struct sockaddr_un sa;
pa_assert(m);
pa_assert(filename);
- memset(&sa, 0, sizeof(sa));
+ pa_zero(sa);
sa.sun_family = AF_UNIX;
pa_strlcpy(sa.sun_path, filename, sizeof(sa.sun_path));
return pa_socket_client_new_sockaddr(m, (struct sockaddr*) &sa, sizeof(sa));
-}
-
#else /* HAVE_SYS_UN_H */
-pa_socket_client* pa_socket_client_new_unix(pa_mainloop_api *m, const char *filename) {
return NULL;
-}
-
#endif /* HAVE_SYS_UN_H */
+}
static int sockaddr_prepare(pa_socket_client *c, const struct sockaddr *sa, size_t salen) {
pa_assert(c);
@@ -271,13 +252,11 @@ static int sockaddr_prepare(pa_socket_client *c, const struct sockaddr *sa, size
c->local = pa_socket_address_is_local(sa);
- if ((c->fd = socket(sa->sa_family, SOCK_STREAM, 0)) < 0) {
+ if ((c->fd = pa_socket_cloexec(sa->sa_family, SOCK_STREAM, 0)) < 0) {
pa_log("socket(): %s", pa_cstrerror(errno));
return -1;
}
- pa_make_fd_cloexec(c->fd);
-
#ifdef HAVE_IPV6
if (sa->sa_family == AF_INET || sa->sa_family == AF_INET6)
#else
@@ -300,7 +279,7 @@ pa_socket_client* pa_socket_client_new_sockaddr(pa_mainloop_api *m, const struct
pa_assert(sa);
pa_assert(salen > 0);
- pa_assert_se(c = socket_client_new(m));
+ c = socket_client_new(m);
if (sockaddr_prepare(c, sa, salen) < 0)
goto fail;
@@ -357,22 +336,25 @@ void pa_socket_client_set_callback(pa_socket_client *c, pa_socket_client_cb_t on
c->userdata = userdata;
}
-#ifdef HAVE_IPV6
pa_socket_client* pa_socket_client_new_ipv6(pa_mainloop_api *m, uint8_t address[16], uint16_t port) {
+#ifdef HAVE_IPV6
struct sockaddr_in6 sa;
pa_assert(m);
pa_assert(address);
pa_assert(port > 0);
- memset(&sa, 0, sizeof(sa));
+ pa_zero(sa);
sa.sin6_family = AF_INET6;
sa.sin6_port = htons(port);
memcpy(&sa.sin6_addr, address, sizeof(sa.sin6_addr));
return pa_socket_client_new_sockaddr(m, (struct sockaddr*) &sa, sizeof(sa));
-}
+
+#else
+ return NULL;
#endif
+}
#ifdef HAVE_LIBASYNCNS
@@ -400,7 +382,8 @@ static void asyncns_cb(pa_mainloop_api*m, pa_io_event *e, int fd, pa_io_event_fl
goto fail;
if (res->ai_addr)
- sockaddr_prepare(c, res->ai_addr, res->ai_addrlen);
+ if (sockaddr_prepare(c, res->ai_addr, res->ai_addrlen) < 0)
+ goto fail;
asyncns_freeaddrinfo(res);
@@ -420,12 +403,11 @@ fail:
#endif
-static void timeout_cb(pa_mainloop_api *m, pa_time_event *e, const struct timeval *tv, void *userdata) {
+static void timeout_cb(pa_mainloop_api *m, pa_time_event *e, const struct timeval *t, void *userdata) {
pa_socket_client *c = userdata;
pa_assert(m);
pa_assert(e);
- pa_assert(tv);
pa_assert(c);
if (c->fd >= 0) {
@@ -437,17 +419,16 @@ static void timeout_cb(pa_mainloop_api *m, pa_time_event *e, const struct timeva
do_call(c);
}
-static void start_timeout(pa_socket_client *c) {
+static void start_timeout(pa_socket_client *c, pa_bool_t use_rtclock) {
struct timeval tv;
+
pa_assert(c);
pa_assert(!c->timeout_event);
- pa_gettimeofday(&tv);
- pa_timeval_add(&tv, CONNECT_TIMEOUT * PA_USEC_PER_SEC);
- c->timeout_event = c->mainloop->time_new(c->mainloop, &tv, timeout_cb, c);
+ c->timeout_event = c->mainloop->time_new(c->mainloop, pa_timeval_rtstore(&tv, pa_rtclock_now() + CONNECT_TIMEOUT * PA_USEC_PER_SEC, use_rtclock), timeout_cb, c);
}
-pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, const char*name, uint16_t default_port) {
+pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, pa_bool_t use_rtclock, const char*name, uint16_t default_port) {
pa_socket_client *c = NULL;
pa_parsed_address a;
@@ -463,19 +444,18 @@ pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, const char*nam
switch (a.type) {
case PA_PARSED_ADDRESS_UNIX:
if ((c = pa_socket_client_new_unix(m, a.path_or_host)))
- start_timeout(c);
+ start_timeout(c, use_rtclock);
break;
case PA_PARSED_ADDRESS_TCP4: /* Fallthrough */
case PA_PARSED_ADDRESS_TCP6: /* Fallthrough */
- case PA_PARSED_ADDRESS_TCP_AUTO:{
-
+ case PA_PARSED_ADDRESS_TCP_AUTO: {
struct addrinfo hints;
char port[12];
pa_snprintf(port, sizeof(port), "%u", (unsigned) a.port);
- memset(&hints, 0, sizeof(hints));
+ pa_zero(hints);
if (a.type == PA_PARSED_ADDRESS_TCP4)
hints.ai_family = PF_INET;
#ifdef HAVE_IPV6
@@ -494,12 +474,11 @@ pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, const char*nam
if (!(asyncns = asyncns_new(1)))
goto finish;
- pa_assert_se(c = socket_client_new(m));
+ c = socket_client_new(m);
c->asyncns = asyncns;
c->asyncns_io_event = m->io_new(m, asyncns_fd(c->asyncns), PA_IO_EVENT_INPUT, asyncns_cb, c);
- c->asyncns_query = asyncns_getaddrinfo(c->asyncns, a.path_or_host, port, &hints);
- pa_assert(c->asyncns_query);
- start_timeout(c);
+ pa_assert_se(c->asyncns_query = asyncns_getaddrinfo(c->asyncns, a.path_or_host, port, &hints));
+ start_timeout(c, use_rtclock);
}
#elif defined(HAVE_GETADDRINFO)
{
@@ -513,7 +492,7 @@ pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, const char*nam
if (res->ai_addr) {
if ((c = pa_socket_client_new_sockaddr(m, res->ai_addr, res->ai_addrlen)))
- start_timeout(c);
+ start_timeout(c, use_rtclock);
}
freeaddrinfo(res);
@@ -541,12 +520,13 @@ pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, const char*nam
if (!host)
goto finish;
+ pa_zero(s);
s.sin_family = AF_INET;
memcpy(&s.sin_addr, host->h_addr, sizeof(struct in_addr));
s.sin_port = htons(a.port);
if ((c = pa_socket_client_new_sockaddr(m, (struct sockaddr*)&s, sizeof(s))))
- start_timeout(c);
+ start_timeout(c, use_rtclock);
}
#endif /* HAVE_LIBASYNCNS */
}
diff --git a/src/pulsecore/socket-client.h b/src/pulsecore/socket-client.h
index ed36400c..138f658c 100644
--- a/src/pulsecore/socket-client.h
+++ b/src/pulsecore/socket-client.h
@@ -35,12 +35,10 @@ typedef struct pa_socket_client pa_socket_client;
typedef void (*pa_socket_client_cb_t)(pa_socket_client *c, pa_iochannel*io, void *userdata);
pa_socket_client* pa_socket_client_new_ipv4(pa_mainloop_api *m, uint32_t address, uint16_t port);
-#ifdef HAVE_IPV6
pa_socket_client* pa_socket_client_new_ipv6(pa_mainloop_api *m, uint8_t address[16], uint16_t port);
-#endif
pa_socket_client* pa_socket_client_new_unix(pa_mainloop_api *m, const char *filename);
pa_socket_client* pa_socket_client_new_sockaddr(pa_mainloop_api *m, const struct sockaddr *sa, size_t salen);
-pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, const char *a, uint16_t default_port);
+pa_socket_client* pa_socket_client_new_string(pa_mainloop_api *m, pa_bool_t use_rtclock, const char *a, uint16_t default_port);
pa_socket_client* pa_socket_client_ref(pa_socket_client *c);
void pa_socket_client_unref(pa_socket_client *c);
diff --git a/src/pulsecore/socket-server.c b/src/pulsecore/socket-server.c
index e660700c..23096a0d 100644
--- a/src/pulsecore/socket-server.c
+++ b/src/pulsecore/socket-server.c
@@ -32,9 +32,6 @@
#include <unistd.h>
#include <sys/stat.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
#ifdef HAVE_SYS_UN_H
#include <sys/un.h>
#ifndef SUN_LEN
@@ -42,9 +39,6 @@
((size_t)(((struct sockaddr_un *) 0)->sun_path) + strlen((ptr)->sun_path))
#endif
#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
@@ -53,25 +47,17 @@
#include <tcpd.h>
#endif
-#ifndef HAVE_INET_NTOP
-#include "inet_ntop.h"
-#endif
-
-#ifndef HAVE_INET_PTON
-#include "inet_pton.h"
-#endif
-
-#include "winsock.h"
-
#include <pulse/xmalloc.h>
#include <pulse/util.h>
+#include <pulsecore/socket.h>
#include <pulsecore/socket-util.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
#include <pulsecore/core-error.h>
#include <pulsecore/refcnt.h>
+#include <pulsecore/arpa-inet.h>
#include "socket-server.h"
@@ -86,7 +72,12 @@ struct pa_socket_server {
pa_io_event *io_event;
pa_mainloop_api *mainloop;
- enum { SOCKET_SERVER_GENERIC, SOCKET_SERVER_IPV4, SOCKET_SERVER_UNIX, SOCKET_SERVER_IPV6 } type;
+ enum {
+ SOCKET_SERVER_GENERIC,
+ SOCKET_SERVER_IPV4,
+ SOCKET_SERVER_UNIX,
+ SOCKET_SERVER_IPV6
+ } type;
};
static void callback(pa_mainloop_api *mainloop, pa_io_event *e, int fd, pa_io_event_flags_t f, void *userdata) {
@@ -104,13 +95,11 @@ static void callback(pa_mainloop_api *mainloop, pa_io_event *e, int fd, pa_io_ev
pa_socket_server_ref(s);
- if ((nfd = accept(fd, NULL, NULL)) < 0) {
+ if ((nfd = pa_accept_cloexec(fd, NULL, NULL)) < 0) {
pa_log("accept(): %s", pa_cstrerror(errno));
goto finish;
}
- pa_make_fd_cloexec(nfd);
-
if (!s->on_connection) {
pa_close(nfd);
goto finish;
@@ -152,15 +141,11 @@ pa_socket_server* pa_socket_server_new(pa_mainloop_api *m, int fd) {
pa_assert(m);
pa_assert(fd >= 0);
- s = pa_xnew(pa_socket_server, 1);
+ s = pa_xnew0(pa_socket_server, 1);
PA_REFCNT_INIT(s);
s->fd = fd;
- s->filename = NULL;
- s->on_connection = NULL;
- s->userdata = NULL;
- s->tcpwrap_service = NULL;
-
s->mainloop = m;
+
pa_assert_se(s->io_event = m->io_new(m, fd, PA_IO_EVENT_INPUT, callback, s));
s->type = SOCKET_SERVER_GENERIC;
@@ -186,13 +171,11 @@ pa_socket_server* pa_socket_server_new_unix(pa_mainloop_api *m, const char *file
pa_assert(m);
pa_assert(filename);
- if ((fd = socket(PF_UNIX, SOCK_STREAM, 0)) < 0) {
+ if ((fd = pa_socket_cloexec(PF_UNIX, SOCK_STREAM, 0)) < 0) {
pa_log("socket(): %s", pa_cstrerror(errno));
goto fail;
}
- pa_make_fd_cloexec(fd);
-
memset(&sa, 0, sizeof(sa));
sa.sun_family = AF_UNIX;
pa_strlcpy(sa.sun_path, filename, sizeof(sa.sun_path));
@@ -237,7 +220,7 @@ pa_socket_server* pa_socket_server_new_unix(pa_mainloop_api *m, const char *file
#endif /* HAVE_SYS_UN_H */
-pa_socket_server* pa_socket_server_new_ipv4(pa_mainloop_api *m, uint32_t address, uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv4(pa_mainloop_api *m, uint32_t address, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
pa_socket_server *ss;
int fd = -1;
struct sockaddr_in sa;
@@ -246,13 +229,11 @@ pa_socket_server* pa_socket_server_new_ipv4(pa_mainloop_api *m, uint32_t address
pa_assert(m);
pa_assert(port);
- if ((fd = socket(PF_INET, SOCK_STREAM, 0)) < 0) {
+ if ((fd = pa_socket_cloexec(PF_INET, SOCK_STREAM, 0)) < 0) {
pa_log("socket(PF_INET): %s", pa_cstrerror(errno));
goto fail;
}
- pa_make_fd_cloexec(fd);
-
#ifdef SO_REUSEADDR
if (setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)) < 0)
pa_log("setsockopt(): %s", pa_cstrerror(errno));
@@ -266,8 +247,19 @@ pa_socket_server* pa_socket_server_new_ipv4(pa_mainloop_api *m, uint32_t address
sa.sin_addr.s_addr = htonl(address);
if (bind(fd, (struct sockaddr *) &sa, sizeof(sa)) < 0) {
+
+ if (errno == EADDRINUSE && fallback) {
+ sa.sin_port = 0;
+
+ if (bind(fd, (struct sockaddr *) &sa, sizeof(sa)) >= 0)
+ goto good;
+ }
+
pa_log("bind(): %s", pa_cstrerror(errno));
goto fail;
+
+ good:
+ ;
}
if (listen(fd, 5) < 0) {
@@ -290,7 +282,7 @@ fail:
}
#ifdef HAVE_IPV6
-pa_socket_server* pa_socket_server_new_ipv6(pa_mainloop_api *m, const uint8_t address[16], uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv6(pa_mainloop_api *m, const uint8_t address[16], uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
pa_socket_server *ss;
int fd = -1;
struct sockaddr_in6 sa;
@@ -299,13 +291,11 @@ pa_socket_server* pa_socket_server_new_ipv6(pa_mainloop_api *m, const uint8_t ad
pa_assert(m);
pa_assert(port > 0);
- if ((fd = socket(PF_INET6, SOCK_STREAM, 0)) < 0) {
+ if ((fd = pa_socket_cloexec(PF_INET6, SOCK_STREAM, 0)) < 0) {
pa_log("socket(PF_INET6): %s", pa_cstrerror(errno));
goto fail;
}
- pa_make_fd_cloexec(fd);
-
#ifdef IPV6_V6ONLY
on = 1;
if (setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0)
@@ -326,8 +316,19 @@ pa_socket_server* pa_socket_server_new_ipv6(pa_mainloop_api *m, const uint8_t ad
memcpy(sa.sin6_addr.s6_addr, address, 16);
if (bind(fd, (struct sockaddr *) &sa, sizeof(sa)) < 0) {
+
+ if (errno == EADDRINUSE && fallback) {
+ sa.sin6_port = 0;
+
+ if (bind(fd, (struct sockaddr *) &sa, sizeof(sa)) >= 0)
+ goto good;
+ }
+
pa_log("bind(): %s", pa_cstrerror(errno));
goto fail;
+
+ good:
+ ;
}
if (listen(fd, 5) < 0) {
@@ -350,39 +351,39 @@ fail:
}
#endif
-pa_socket_server* pa_socket_server_new_ipv4_loopback(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv4_loopback(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
pa_assert(m);
pa_assert(port > 0);
- return pa_socket_server_new_ipv4(m, INADDR_LOOPBACK, port, tcpwrap_service);
+ return pa_socket_server_new_ipv4(m, INADDR_LOOPBACK, port, fallback, tcpwrap_service);
}
#ifdef HAVE_IPV6
-pa_socket_server* pa_socket_server_new_ipv6_loopback(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv6_loopback(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
pa_assert(m);
pa_assert(port > 0);
- return pa_socket_server_new_ipv6(m, in6addr_loopback.s6_addr, port, tcpwrap_service);
+ return pa_socket_server_new_ipv6(m, in6addr_loopback.s6_addr, port, fallback, tcpwrap_service);
}
#endif
-pa_socket_server* pa_socket_server_new_ipv4_any(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv4_any(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
pa_assert(m);
pa_assert(port > 0);
- return pa_socket_server_new_ipv4(m, INADDR_ANY, port, tcpwrap_service);
+ return pa_socket_server_new_ipv4(m, INADDR_ANY, port, fallback, tcpwrap_service);
}
#ifdef HAVE_IPV6
-pa_socket_server* pa_socket_server_new_ipv6_any(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv6_any(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
pa_assert(m);
pa_assert(port > 0);
- return pa_socket_server_new_ipv6(m, in6addr_any.s6_addr, port, tcpwrap_service);
+ return pa_socket_server_new_ipv6(m, in6addr_any.s6_addr, port, fallback, tcpwrap_service);
}
#endif
-pa_socket_server* pa_socket_server_new_ipv4_string(pa_mainloop_api *m, const char *name, uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv4_string(pa_mainloop_api *m, const char *name, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
struct in_addr ipv4;
pa_assert(m);
@@ -390,13 +391,13 @@ pa_socket_server* pa_socket_server_new_ipv4_string(pa_mainloop_api *m, const cha
pa_assert(port > 0);
if (inet_pton(AF_INET, name, &ipv4) > 0)
- return pa_socket_server_new_ipv4(m, ntohl(ipv4.s_addr), port, tcpwrap_service);
+ return pa_socket_server_new_ipv4(m, ntohl(ipv4.s_addr), port, fallback, tcpwrap_service);
return NULL;
}
#ifdef HAVE_IPV6
-pa_socket_server* pa_socket_server_new_ipv6_string(pa_mainloop_api *m, const char *name, uint16_t port, const char *tcpwrap_service) {
+pa_socket_server* pa_socket_server_new_ipv6_string(pa_mainloop_api *m, const char *name, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service) {
struct in6_addr ipv6;
pa_assert(m);
@@ -404,7 +405,7 @@ pa_socket_server* pa_socket_server_new_ipv6_string(pa_mainloop_api *m, const cha
pa_assert(port > 0);
if (inet_pton(AF_INET6, name, &ipv6) > 0)
- return pa_socket_server_new_ipv6(m, ipv6.s6_addr, port, tcpwrap_service);
+ return pa_socket_server_new_ipv6(m, ipv6.s6_addr, port, fallback, tcpwrap_service);
return NULL;
}
diff --git a/src/pulsecore/socket-server.h b/src/pulsecore/socket-server.h
index 72b6eda4..16da07b8 100644
--- a/src/pulsecore/socket-server.h
+++ b/src/pulsecore/socket-server.h
@@ -33,15 +33,15 @@ typedef struct pa_socket_server pa_socket_server;
pa_socket_server* pa_socket_server_new(pa_mainloop_api *m, int fd);
pa_socket_server* pa_socket_server_new_unix(pa_mainloop_api *m, const char *filename);
-pa_socket_server* pa_socket_server_new_ipv4(pa_mainloop_api *m, uint32_t address, uint16_t port, const char *tcpwrap_service);
-pa_socket_server* pa_socket_server_new_ipv4_loopback(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service);
-pa_socket_server* pa_socket_server_new_ipv4_any(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service);
-pa_socket_server* pa_socket_server_new_ipv4_string(pa_mainloop_api *m, const char *name, uint16_t port, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv4(pa_mainloop_api *m, uint32_t address, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv4_loopback(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv4_any(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv4_string(pa_mainloop_api *m, const char *name, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
#ifdef HAVE_IPV6
-pa_socket_server* pa_socket_server_new_ipv6(pa_mainloop_api *m, const uint8_t address[16], uint16_t port, const char *tcpwrap_service);
-pa_socket_server* pa_socket_server_new_ipv6_loopback(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service);
-pa_socket_server* pa_socket_server_new_ipv6_any(pa_mainloop_api *m, uint16_t port, const char *tcpwrap_service);
-pa_socket_server* pa_socket_server_new_ipv6_string(pa_mainloop_api *m, const char *name, uint16_t port, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv6(pa_mainloop_api *m, const uint8_t address[16], uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv6_loopback(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv6_any(pa_mainloop_api *m, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
+pa_socket_server* pa_socket_server_new_ipv6_string(pa_mainloop_api *m, const char *name, uint16_t port, pa_bool_t fallback, const char *tcpwrap_service);
#endif
void pa_socket_server_unref(pa_socket_server*s);
diff --git a/src/pulsecore/socket-util.c b/src/pulsecore/socket-util.c
index 5fd5dd67..00fcbc4f 100644
--- a/src/pulsecore/socket-util.c
+++ b/src/pulsecore/socket-util.c
@@ -25,20 +25,15 @@
#include <config.h>
#endif
-#include <stdarg.h>
#include <stdlib.h>
#include <signal.h>
#include <errno.h>
#include <string.h>
#include <stdio.h>
#include <sys/types.h>
-#include <fcntl.h>
#include <unistd.h>
#include <sys/stat.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
#ifdef HAVE_SYS_UN_H
#include <sys/un.h>
#endif
@@ -57,22 +52,13 @@
#ifdef HAVE_NETDB_H
#include <netdb.h>
#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
-
-#ifndef HAVE_INET_NTOP
-#include "inet_ntop.h"
-#endif
-
-#include "winsock.h"
-
-#include <pulse/xmalloc.h>
#include <pulsecore/core-error.h>
#include <pulsecore/core-util.h>
#include <pulsecore/log.h>
#include <pulsecore/macro.h>
+#include <pulsecore/socket.h>
+#include <pulsecore/arpa-inet.h>
#include "socket-util.h"
@@ -85,12 +71,12 @@ void pa_socket_peer_to_string(int fd, char *c, size_t l) {
#ifndef OS_IS_WIN32
pa_assert_se(fstat(fd, &st) == 0);
-#endif
-#ifndef OS_IS_WIN32
- if (S_ISSOCK(st.st_mode)) {
+ if (S_ISSOCK(st.st_mode))
#endif
+ {
union {
+ struct sockaddr_storage storage;
struct sockaddr sa;
struct sockaddr_in in;
#ifdef HAVE_IPV6
@@ -133,10 +119,11 @@ void pa_socket_peer_to_string(int fd, char *c, size_t l) {
}
}
-#ifndef OS_IS_WIN32
pa_snprintf(c, l, "Unknown network client");
return;
- } else if (S_ISCHR(st.st_mode) && (fd == 0 || fd == 1)) {
+ }
+#ifndef OS_IS_WIN32
+ else if (S_ISCHR(st.st_mode) && (fd == 0 || fd == 1)) {
pa_snprintf(c, l, "STDIN/STDOUT client");
return;
}
@@ -152,7 +139,7 @@ void pa_make_socket_low_delay(int fd) {
pa_assert(fd >= 0);
priority = 6;
- if (setsockopt(fd, SOL_SOCKET, SO_PRIORITY, (void*)&priority, sizeof(priority)) < 0)
+ if (setsockopt(fd, SOL_SOCKET, SO_PRIORITY, &priority, sizeof(priority)) < 0)
pa_log_warn("SO_PRIORITY failed: %s", pa_cstrerror(errno));
#endif
}
@@ -166,9 +153,9 @@ void pa_make_tcp_socket_low_delay(int fd) {
{
int on = 1;
#if defined(SOL_TCP)
- if (setsockopt(fd, SOL_TCP, TCP_NODELAY, (void*)&on, sizeof(on)) < 0)
+ if (setsockopt(fd, SOL_TCP, TCP_NODELAY, &on, sizeof(on)) < 0)
#else
- if (setsockopt(fd, IPPROTO_TCP, TCP_NODELAY, (void*)&on, sizeof(on)) < 0)
+ if (setsockopt(fd, IPPROTO_TCP, TCP_NODELAY, &on, sizeof(on)) < 0)
#endif
pa_log_warn("TCP_NODELAY failed: %s", pa_cstrerror(errno));
}
@@ -178,9 +165,9 @@ void pa_make_tcp_socket_low_delay(int fd) {
{
int tos = IPTOS_LOWDELAY;
#ifdef SOL_IP
- if (setsockopt(fd, SOL_IP, IP_TOS, (void*)&tos, sizeof(tos)) < 0)
+ if (setsockopt(fd, SOL_IP, IP_TOS, &tos, sizeof(tos)) < 0)
#else
- if (setsockopt(fd, IPPROTO_IP, IP_TOS, (void*)&tos, sizeof(tos)) < 0)
+ if (setsockopt(fd, IPPROTO_IP, IP_TOS, &tos, sizeof(tos)) < 0)
#endif
pa_log_warn("IP_TOS failed: %s", pa_cstrerror(errno));
}
@@ -196,9 +183,9 @@ void pa_make_udp_socket_low_delay(int fd) {
{
int tos = IPTOS_LOWDELAY;
#ifdef SOL_IP
- if (setsockopt(fd, SOL_IP, IP_TOS, (void*)&tos, sizeof(tos)) < 0)
+ if (setsockopt(fd, SOL_IP, IP_TOS, &tos, sizeof(tos)) < 0)
#else
- if (setsockopt(fd, IPPROTO_IP, IP_TOS, (void*)&tos, sizeof(tos)) < 0)
+ if (setsockopt(fd, IPPROTO_IP, IP_TOS, &tos, sizeof(tos)) < 0)
#endif
pa_log_warn("IP_TOS failed: %s", pa_cstrerror(errno));
}
@@ -206,11 +193,11 @@ void pa_make_udp_socket_low_delay(int fd) {
}
int pa_socket_set_rcvbuf(int fd, size_t l) {
- int bufsz = (int)l;
+ int bufsz = (int) l;
pa_assert(fd >= 0);
- if (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, (void*)&bufsz, sizeof(bufsz)) < 0) {
+ if (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &bufsz, sizeof(bufsz)) < 0) {
pa_log_warn("SO_RCVBUF: %s", pa_cstrerror(errno));
return -1;
}
@@ -219,12 +206,12 @@ int pa_socket_set_rcvbuf(int fd, size_t l) {
}
int pa_socket_set_sndbuf(int fd, size_t l) {
- int bufsz = (int)l;
+ int bufsz = (int) l;
pa_assert(fd >= 0);
- if (setsockopt(fd, SOL_SOCKET, SO_SNDBUF, (void*)&bufsz, sizeof(bufsz)) < 0) {
- pa_log("SO_SNDBUF: %s", pa_cstrerror(errno));
+ if (setsockopt(fd, SOL_SOCKET, SO_SNDBUF, &bufsz, sizeof(bufsz)) < 0) {
+ pa_log_warn("SO_SNDBUF: %s", pa_cstrerror(errno));
return -1;
}
@@ -239,7 +226,7 @@ int pa_unix_socket_is_stale(const char *fn) {
pa_assert(fn);
- if ((fd = socket(PF_UNIX, SOCK_STREAM, 0)) < 0) {
+ if ((fd = pa_socket_cloexec(PF_UNIX, SOCK_STREAM, 0)) < 0) {
pa_log("socket(): %s", pa_cstrerror(errno));
goto finish;
}
@@ -315,6 +302,7 @@ pa_bool_t pa_socket_address_is_local(const struct sockaddr *sa) {
pa_bool_t pa_socket_is_local(int fd) {
union {
+ struct sockaddr_storage storage;
struct sockaddr sa;
struct sockaddr_in in;
#ifdef HAVE_IPV6
diff --git a/src/pulsecore/socket-util.h b/src/pulsecore/socket-util.h
index f6d16376..154afd4a 100644
--- a/src/pulsecore/socket-util.h
+++ b/src/pulsecore/socket-util.h
@@ -24,8 +24,8 @@
***/
#include <sys/types.h>
-#include <sys/socket.h>
+#include <pulsecore/socket.h>
#include <pulsecore/macro.h>
void pa_socket_peer_to_string(int fd, char *c, size_t l);
diff --git a/src/pulsecore/winsock.h b/src/pulsecore/socket.h
index 0352bf4d..0d38bee6 100644
--- a/src/pulsecore/winsock.h
+++ b/src/pulsecore/socket.h
@@ -1,5 +1,9 @@
-#ifndef foowinsockhfoo
-#define foowinsockhfoo
+#ifndef foopulsecoresockethfoo
+#define foopulsecoresockethfoo
+
+#ifdef HAVE_SYS_SOCKET_H
+#include <sys/socket.h>
+#endif
#ifdef HAVE_WINSOCK2_H
#include <winsock2.h>
@@ -14,6 +18,7 @@
#define ECONNREFUSED WSAECONNREFUSED
#define EHOSTUNREACH WSAEHOSTUNREACH
#define EWOULDBLOCK WSAEWOULDBLOCK
+#define EADDRINUSE WSAEADDRINUSE
typedef long suseconds_t;
diff --git a/src/pulsecore/sound-file-stream.c b/src/pulsecore/sound-file-stream.c
index 502e5c69..96b5fb82 100644
--- a/src/pulsecore/sound-file-stream.c
+++ b/src/pulsecore/sound-file-stream.c
@@ -25,7 +25,6 @@
#include <stdlib.h>
#include <stdio.h>
-#include <string.h>
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
@@ -40,7 +39,6 @@
#include <pulsecore/log.h>
#include <pulsecore/thread-mq.h>
#include <pulsecore/core-util.h>
-#include <pulsecore/sample-util.h>
#include <pulsecore/sndfile-util.h>
#include "sound-file-stream.h"
@@ -64,9 +62,8 @@ enum {
FILE_STREAM_MESSAGE_UNLINK
};
-PA_DECLARE_CLASS(file_stream);
+PA_DEFINE_PRIVATE_CLASS(file_stream, pa_msgobject);
#define FILE_STREAM(o) (file_stream_cast(o))
-static PA_DEFINE_CHECK_TYPE(file_stream, pa_msgobject);
/* Called from main context */
static void file_stream_unlink(file_stream *u) {
@@ -201,7 +198,7 @@ static int sink_input_pop_cb(pa_sink_input *i, size_t length, pa_memchunk *chunk
}
return -1;
- }
+}
static void sink_input_process_rewind_cb(pa_sink_input *i, size_t nbytes) {
file_stream *u;
@@ -240,6 +237,7 @@ int pa_play_file(
pa_sink_input_new_data data;
int fd;
SF_INFO sfi;
+ pa_memchunk silence;
pa_assert(sink);
pa_assert(fname);
@@ -253,11 +251,7 @@ int pa_play_file(
u->readf_function = NULL;
u->memblockq = NULL;
- if ((fd = open(fname, O_RDONLY
-#ifdef O_NOCTTY
- |O_NOCTTY
-#endif
- )) < 0) {
+ if ((fd = pa_open_cloexec(fname, O_RDONLY, 0)) < 0) {
pa_log("Failed to open file %s: %s", fname, pa_cstrerror(errno));
goto fail;
}
@@ -303,7 +297,7 @@ int pa_play_file(
u->readf_function = pa_sndfile_readf_function(&ss);
pa_sink_input_new_data_init(&data);
- data.sink = sink;
+ pa_sink_input_new_data_set_sink(&data, sink, FALSE);
data.driver = __FILE__;
pa_sink_input_new_data_set_sample_spec(&data, &ss);
pa_sink_input_new_data_set_channel_map(&data, &cm);
@@ -312,7 +306,7 @@ int pa_play_file(
pa_proplist_sets(data.proplist, PA_PROP_MEDIA_FILENAME, fname);
pa_sndfile_init_proplist(u->sndfile, data.proplist);
- pa_sink_input_new(&u->sink_input, sink->core, &data, 0);
+ pa_sink_input_new(&u->sink_input, sink->core, &data);
pa_sink_input_new_data_done(&data);
if (!u->sink_input)
@@ -325,7 +319,9 @@ int pa_play_file(
u->sink_input->state_change = sink_input_state_change_cb;
u->sink_input->userdata = u;
- u->memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, pa_frame_size(&ss), 1, 1, 0, NULL);
+ pa_sink_input_get_silence(u->sink_input, &silence);
+ u->memblockq = pa_memblockq_new(0, MEMBLOCKQ_MAXLENGTH, 0, pa_frame_size(&ss), 1, 1, 0, &silence);
+ pa_memblock_unref(silence.memblock);
pa_sink_input_put(u->sink_input);
@@ -335,8 +331,7 @@ int pa_play_file(
return 0;
fail:
- if (u)
- file_stream_unref(u);
+ file_stream_unref(u);
if (fd >= 0)
pa_close(fd);
diff --git a/src/pulsecore/sound-file.c b/src/pulsecore/sound-file.c
index 2d9b76ad..3db0981f 100644
--- a/src/pulsecore/sound-file.c
+++ b/src/pulsecore/sound-file.c
@@ -23,7 +23,6 @@
#include <config.h>
#endif
-#include <string.h>
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
@@ -62,11 +61,7 @@ int pa_sound_file_load(
pa_memchunk_reset(chunk);
- if ((fd = open(fname, O_RDONLY
-#ifdef O_NOCTTY
- |O_NOCTTY
-#endif
- )) < 0) {
+ if ((fd = pa_open_cloexec(fname, O_RDONLY, 0)) < 0) {
pa_log("Failed to open file %s: %s", fname, pa_cstrerror(errno));
goto finish;
}
diff --git a/src/pulsecore/source-output.c b/src/pulsecore/source-output.c
index 4ba25ae4..59b6c2ff 100644
--- a/src/pulsecore/source-output.c
+++ b/src/pulsecore/source-output.c
@@ -30,6 +30,7 @@
#include <pulse/utf8.h>
#include <pulse/xmalloc.h>
#include <pulse/util.h>
+#include <pulse/internal.h>
#include <pulsecore/sample-util.h>
#include <pulsecore/core-subscribe.h>
@@ -41,16 +42,18 @@
#define MEMBLOCKQ_MAXLENGTH (32*1024*1024)
-static PA_DEFINE_CHECK_TYPE(pa_source_output, pa_msgobject);
+PA_DEFINE_PUBLIC_CLASS(pa_source_output, pa_msgobject);
static void source_output_free(pa_object* mo);
+static void set_real_ratio(pa_source_output *o, const pa_cvolume *v);
pa_source_output_new_data* pa_source_output_new_data_init(pa_source_output_new_data *data) {
pa_assert(data);
- memset(data, 0, sizeof(*data));
+ pa_zero(*data);
data->resample_method = PA_RESAMPLER_INVALID;
data->proplist = pa_proplist_new();
+ data->volume_writable = TRUE;
return data;
}
@@ -69,9 +72,119 @@ void pa_source_output_new_data_set_channel_map(pa_source_output_new_data *data,
data->channel_map = *map;
}
+pa_bool_t pa_source_output_new_data_is_passthrough(pa_source_output_new_data *data) {
+ pa_assert(data);
+
+ if (PA_LIKELY(data->format) && PA_UNLIKELY(!pa_format_info_is_pcm(data->format)))
+ return TRUE;
+
+ if (PA_UNLIKELY(data->flags & PA_SOURCE_OUTPUT_PASSTHROUGH))
+ return TRUE;
+
+ return FALSE;
+}
+
+void pa_source_output_new_data_set_volume(pa_source_output_new_data *data, const pa_cvolume *volume) {
+ pa_assert(data);
+ pa_assert(data->volume_writable);
+
+ if ((data->volume_is_set = !!volume))
+ data->volume = *volume;
+}
+
+void pa_source_output_new_data_apply_volume_factor(pa_source_output_new_data *data, const pa_cvolume *volume_factor) {
+ pa_assert(data);
+ pa_assert(volume_factor);
+
+ if (data->volume_factor_is_set)
+ pa_sw_cvolume_multiply(&data->volume_factor, &data->volume_factor, volume_factor);
+ else {
+ data->volume_factor_is_set = TRUE;
+ data->volume_factor = *volume_factor;
+ }
+}
+
+void pa_source_output_new_data_apply_volume_factor_source(pa_source_output_new_data *data, const pa_cvolume *volume_factor) {
+ pa_assert(data);
+ pa_assert(volume_factor);
+
+ if (data->volume_factor_source_is_set)
+ pa_sw_cvolume_multiply(&data->volume_factor_source, &data->volume_factor_source, volume_factor);
+ else {
+ data->volume_factor_source_is_set = TRUE;
+ data->volume_factor_source = *volume_factor;
+ }
+}
+
+void pa_source_output_new_data_set_muted(pa_source_output_new_data *data, pa_bool_t mute) {
+ pa_assert(data);
+
+ data->muted_is_set = TRUE;
+ data->muted = !!mute;
+}
+
+pa_bool_t pa_source_output_new_data_set_source(pa_source_output_new_data *data, pa_source *s, pa_bool_t save) {
+ pa_bool_t ret = TRUE;
+ pa_idxset *formats = NULL;
+
+ pa_assert(data);
+ pa_assert(s);
+
+ if (!data->req_formats) {
+ /* We're not working with the extended API */
+ data->source = s;
+ data->save_source = save;
+ } else {
+ /* Extended API: let's see if this source supports the formats the client would like */
+ formats = pa_source_check_formats(s, data->req_formats);
+
+ if (formats && !pa_idxset_isempty(formats)) {
+ /* Source supports at least one of the requested formats */
+ data->source = s;
+ data->save_source = save;
+ if (data->nego_formats)
+ pa_idxset_free(data->nego_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ data->nego_formats = formats;
+ } else {
+ /* Source doesn't support any of the formats requested by the client */
+ if (formats)
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ ret = FALSE;
+ }
+ }
+
+ return ret;
+}
+
+pa_bool_t pa_source_output_new_data_set_formats(pa_source_output_new_data *data, pa_idxset *formats) {
+ pa_assert(data);
+ pa_assert(formats);
+
+ if (data->req_formats)
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ data->req_formats = formats;
+
+ if (data->source) {
+ /* Trigger format negotiation */
+ return pa_source_output_new_data_set_source(data, data->source, data->save_source);
+ }
+
+ return TRUE;
+}
+
void pa_source_output_new_data_done(pa_source_output_new_data *data) {
pa_assert(data);
+ if (data->req_formats)
+ pa_idxset_free(data->req_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ if (data->nego_formats)
+ pa_idxset_free(data->nego_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ if (data->format)
+ pa_format_info_free(data->format);
+
pa_proplist_free(data->proplist);
}
@@ -84,6 +197,7 @@ static void reset_callbacks(pa_source_output *o) {
o->update_max_rewind = NULL;
o->update_source_requested_latency = NULL;
o->update_source_latency_range = NULL;
+ o->update_source_fixed_latency = NULL;
o->attach = NULL;
o->detach = NULL;
o->suspend = NULL;
@@ -94,38 +208,79 @@ static void reset_callbacks(pa_source_output *o) {
o->state_change = NULL;
o->may_move_to = NULL;
o->send_event = NULL;
+ o->volume_changed = NULL;
+ o->mute_changed = NULL;
}
/* Called from main context */
int pa_source_output_new(
pa_source_output**_o,
pa_core *core,
- pa_source_output_new_data *data,
- pa_source_output_flags_t flags) {
+ pa_source_output_new_data *data) {
pa_source_output *o;
pa_resampler *resampler = NULL;
char st[PA_SAMPLE_SPEC_SNPRINT_MAX], cm[PA_CHANNEL_MAP_SNPRINT_MAX];
+ pa_channel_map original_cm;
int r;
+ char *pt;
+ pa_sample_spec ss;
+ pa_channel_map map;
pa_assert(_o);
pa_assert(core);
pa_assert(data);
+ pa_assert_ctl_context();
if (data->client)
pa_proplist_update(data->proplist, PA_UPDATE_MERGE, data->client->proplist);
+ if (data->destination_source && (data->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
+ data->volume_writable = FALSE;
+
+ if (!data->req_formats) {
+ /* From this point on, we want to work only with formats, and get back
+ * to using the sample spec and channel map after all decisions w.r.t.
+ * routing are complete. */
+ pa_idxset *tmp = pa_idxset_new(NULL, NULL);
+ pa_format_info *f = pa_format_info_from_sample_spec(&data->sample_spec, &data->channel_map);
+ pa_idxset_put(tmp, f, NULL);
+ pa_source_output_new_data_set_formats(data, tmp);
+ }
+
if ((r = pa_hook_fire(&core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_NEW], data)) < 0)
return r;
pa_return_val_if_fail(!data->driver || pa_utf8_valid(data->driver), -PA_ERR_INVALID);
if (!data->source) {
- data->source = pa_namereg_get(core, NULL, PA_NAMEREG_SOURCE);
- data->save_source = FALSE;
+ pa_source *source = pa_namereg_get(core, NULL, PA_NAMEREG_SOURCE);
+ pa_return_val_if_fail(source, -PA_ERR_NOENTITY);
+ pa_source_output_new_data_set_source(data, source, FALSE);
+ }
+
+ /* Routing's done, we have a source. Now let's fix the format and set up the
+ * sample spec */
+
+ /* If something didn't pick a format for us, pick the top-most format since
+ * we assume this is sorted in priority order */
+ if (!data->format && data->nego_formats && !pa_idxset_isempty(data->nego_formats))
+ data->format = pa_format_info_copy(pa_idxset_first(data->nego_formats, NULL));
+
+ pa_return_val_if_fail(data->format, -PA_ERR_NOTSUPPORTED);
+
+ /* Now populate the sample spec and format according to the final
+ * format that we've negotiated */
+ if (PA_LIKELY(data->format->encoding == PA_ENCODING_PCM)) {
+ pa_return_val_if_fail(pa_format_info_to_sample_spec(data->format, &ss, &map), -PA_ERR_INVALID);
+ pa_source_output_new_data_set_sample_spec(data, &ss);
+ if (pa_channel_map_valid(&map))
+ pa_source_output_new_data_set_channel_map(data, &map);
+ } else {
+ pa_return_val_if_fail(pa_format_info_to_sample_spec_fake(data->format, &ss), -PA_ERR_INVALID);
+ pa_source_output_new_data_set_sample_spec(data, &ss);
}
- pa_return_val_if_fail(data->source, -PA_ERR_NOENTITY);
pa_return_val_if_fail(PA_SOURCE_IS_LINKED(pa_source_get_state(data->source)), -PA_ERR_BADSTATE);
pa_return_val_if_fail(!data->direct_on_input || data->direct_on_input->sink == data->source->monitor_of, -PA_ERR_INVALID);
@@ -141,16 +296,44 @@ int pa_source_output_new(
pa_channel_map_init_extend(&data->channel_map, data->sample_spec.channels, PA_CHANNEL_MAP_DEFAULT);
}
- pa_return_val_if_fail(pa_channel_map_valid(&data->channel_map), -PA_ERR_INVALID);
pa_return_val_if_fail(pa_channel_map_compatible(&data->channel_map, &data->sample_spec), -PA_ERR_INVALID);
- if (flags & PA_SOURCE_OUTPUT_FIX_FORMAT)
+ /* Don't restore (or save) stream volume for passthrough streams */
+ if (!pa_format_info_is_pcm(data->format)) {
+ data->volume_is_set = FALSE;
+ data->volume_factor_is_set = FALSE;
+ }
+
+ if (!data->volume_is_set) {
+ pa_cvolume_reset(&data->volume, data->sample_spec.channels);
+ data->volume_is_absolute = FALSE;
+ data->save_volume = FALSE;
+ }
+
+ pa_return_val_if_fail(pa_cvolume_compatible(&data->volume, &data->sample_spec), -PA_ERR_INVALID);
+
+ if (!data->volume_factor_is_set)
+ pa_cvolume_reset(&data->volume_factor, data->sample_spec.channels);
+
+ pa_return_val_if_fail(pa_cvolume_compatible(&data->volume_factor, &data->sample_spec), -PA_ERR_INVALID);
+
+ if (!data->volume_factor_source_is_set)
+ pa_cvolume_reset(&data->volume_factor_source, data->source->sample_spec.channels);
+
+ pa_return_val_if_fail(pa_cvolume_compatible(&data->volume_factor_source, &data->source->sample_spec), -PA_ERR_INVALID);
+
+ if (!data->muted_is_set)
+ data->muted = FALSE;
+
+ if (data->flags & PA_SOURCE_OUTPUT_FIX_FORMAT)
data->sample_spec.format = data->source->sample_spec.format;
- if (flags & PA_SOURCE_OUTPUT_FIX_RATE)
+ if (data->flags & PA_SOURCE_OUTPUT_FIX_RATE)
data->sample_spec.rate = data->source->sample_spec.rate;
- if (flags & PA_SOURCE_OUTPUT_FIX_CHANNELS) {
+ original_cm = data->channel_map;
+
+ if (data->flags & PA_SOURCE_OUTPUT_FIX_CHANNELS) {
data->sample_spec.channels = data->source->sample_spec.channels;
data->channel_map = data->source->channel_map;
}
@@ -158,6 +341,9 @@ int pa_source_output_new(
pa_assert(pa_sample_spec_valid(&data->sample_spec));
pa_assert(pa_channel_map_valid(&data->channel_map));
+ /* Due to the fixing of the sample spec the volume might not match anymore */
+ pa_cvolume_remap(&data->volume, &original_cm, &data->channel_map);
+
if (data->resample_method == PA_RESAMPLER_INVALID)
data->resample_method = core->resample_method;
@@ -166,7 +352,7 @@ int pa_source_output_new(
if ((r = pa_hook_fire(&core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_FIXATE], data)) < 0)
return r;
- if ((flags & PA_SOURCE_OUTPUT_FAIL_ON_SUSPEND) &&
+ if ((data->flags & PA_SOURCE_OUTPUT_NO_CREATE_ON_SUSPEND) &&
pa_source_get_state(data->source) == PA_SOURCE_SUSPENDED) {
pa_log("Failed to create source output: source is suspended.");
return -PA_ERR_BADSTATE;
@@ -177,22 +363,23 @@ int pa_source_output_new(
return -PA_ERR_TOOLARGE;
}
- if ((flags & PA_SOURCE_OUTPUT_VARIABLE_RATE) ||
+ if ((data->flags & PA_SOURCE_OUTPUT_VARIABLE_RATE) ||
!pa_sample_spec_equal(&data->sample_spec, &data->source->sample_spec) ||
!pa_channel_map_equal(&data->channel_map, &data->source->channel_map)) {
- if (!(resampler = pa_resampler_new(
- core->mempool,
- &data->source->sample_spec, &data->source->channel_map,
- &data->sample_spec, &data->channel_map,
- data->resample_method,
- ((flags & PA_SOURCE_OUTPUT_VARIABLE_RATE) ? PA_RESAMPLER_VARIABLE_RATE : 0) |
- ((flags & PA_SOURCE_OUTPUT_NO_REMAP) ? PA_RESAMPLER_NO_REMAP : 0) |
- (core->disable_remixing || (flags & PA_SOURCE_OUTPUT_NO_REMIX) ? PA_RESAMPLER_NO_REMIX : 0) |
- (core->disable_lfe_remixing ? PA_RESAMPLER_NO_LFE : 0)))) {
- pa_log_warn("Unsupported resampling operation.");
- return -PA_ERR_NOTSUPPORTED;
- }
+ if (!pa_source_output_new_data_is_passthrough(data)) /* no resampler for passthrough content */
+ if (!(resampler = pa_resampler_new(
+ core->mempool,
+ &data->source->sample_spec, &data->source->channel_map,
+ &data->sample_spec, &data->channel_map,
+ data->resample_method,
+ ((data->flags & PA_SOURCE_OUTPUT_VARIABLE_RATE) ? PA_RESAMPLER_VARIABLE_RATE : 0) |
+ ((data->flags & PA_SOURCE_OUTPUT_NO_REMAP) ? PA_RESAMPLER_NO_REMAP : 0) |
+ (core->disable_remixing || (data->flags & PA_SOURCE_OUTPUT_NO_REMIX) ? PA_RESAMPLER_NO_REMIX : 0) |
+ (core->disable_lfe_remixing ? PA_RESAMPLER_NO_LFE : 0)))) {
+ pa_log_warn("Unsupported resampling operation.");
+ return -PA_ERR_NOTSUPPORTED;
+ }
}
o = pa_msgobject_new(pa_source_output);
@@ -201,21 +388,44 @@ int pa_source_output_new(
o->core = core;
o->state = PA_SOURCE_OUTPUT_INIT;
- o->flags = flags;
+ o->flags = data->flags;
o->proplist = pa_proplist_copy(data->proplist);
o->driver = pa_xstrdup(pa_path_get_filename(data->driver));
o->module = data->module;
o->source = data->source;
+ o->destination_source = data->destination_source;
o->client = data->client;
- o->actual_resample_method = resampler ? pa_resampler_get_method(resampler) : PA_RESAMPLER_INVALID;
o->requested_resample_method = data->resample_method;
+ o->actual_resample_method = resampler ? pa_resampler_get_method(resampler) : PA_RESAMPLER_INVALID;
o->sample_spec = data->sample_spec;
o->channel_map = data->channel_map;
+ o->format = pa_format_info_copy(data->format);
- o->direct_on_input = data->direct_on_input;
+ if (!data->volume_is_absolute && pa_source_flat_volume_enabled(o->source)) {
+ pa_cvolume remapped;
+ /* When the 'absolute' bool is not set then we'll treat the volume
+ * as relative to the source volume even in flat volume mode */
+ remapped = data->source->reference_volume;
+ pa_cvolume_remap(&remapped, &data->source->channel_map, &data->channel_map);
+ pa_sw_cvolume_multiply(&o->volume, &data->volume, &remapped);
+ } else
+ o->volume = data->volume;
+
+ o->volume_factor = data->volume_factor;
+ o->volume_factor_source = data->volume_factor_source;
+ o->real_ratio = o->reference_ratio = data->volume;
+ pa_cvolume_reset(&o->soft_volume, o->sample_spec.channels);
+ pa_cvolume_reset(&o->real_ratio, o->sample_spec.channels);
+ o->volume_writable = data->volume_writable;
+ o->save_volume = data->save_volume;
o->save_source = data->save_source;
+ o->save_muted = data->save_muted;
+
+ o->muted = data->muted;
+
+ o->direct_on_input = data->direct_on_input;
reset_callbacks(o);
o->userdata = NULL;
@@ -224,6 +434,8 @@ int pa_source_output_new(
o->thread_info.attached = FALSE;
o->thread_info.sample_spec = o->sample_spec;
o->thread_info.resampler = resampler;
+ o->thread_info.soft_volume = o->soft_volume;
+ o->thread_info.muted = o->muted;
o->thread_info.requested_source_latency = (pa_usec_t) -1;
o->thread_info.direct_on_input = o->direct_on_input;
@@ -246,12 +458,15 @@ int pa_source_output_new(
if (o->direct_on_input)
pa_assert_se(pa_idxset_put(o->direct_on_input->direct_outputs, o, NULL) == 0);
- pa_log_info("Created output %u \"%s\" on %s with sample spec %s and channel map %s",
+ pt = pa_proplist_to_string_sep(o->proplist, "\n ");
+ pa_log_info("Created output %u \"%s\" on %s with sample spec %s and channel map %s\n %s",
o->index,
pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_MEDIA_NAME)),
o->source->name,
pa_sample_spec_snprint(st, sizeof(st), &o->sample_spec),
- pa_channel_map_snprint(cm, sizeof(cm), &o->channel_map));
+ pa_channel_map_snprint(cm, sizeof(cm), &o->channel_map),
+ pt);
+ pa_xfree(pt);
/* Don't forget to call pa_source_output_put! */
@@ -262,6 +477,7 @@ int pa_source_output_new(
/* Called from main context */
static void update_n_corked(pa_source_output *o, pa_source_output_state_t state) {
pa_assert(o);
+ pa_assert_ctl_context();
if (!o->source)
return;
@@ -274,7 +490,9 @@ static void update_n_corked(pa_source_output *o, pa_source_output_state_t state)
/* Called from main context */
static void source_output_set_state(pa_source_output *o, pa_source_output_state_t state) {
+
pa_assert(o);
+ pa_assert_ctl_context();
if (o->state == state)
return;
@@ -284,9 +502,13 @@ static void source_output_set_state(pa_source_output *o, pa_source_output_state_
update_n_corked(o, state);
o->state = state;
- if (state != PA_SOURCE_OUTPUT_UNLINKED)
+ if (state != PA_SOURCE_OUTPUT_UNLINKED) {
pa_hook_fire(&o->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_STATE_CHANGED], o);
+ if (PA_SOURCE_OUTPUT_IS_LINKED(state))
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+ }
+
pa_source_update_status(o->source);
}
@@ -294,6 +516,7 @@ static void source_output_set_state(pa_source_output *o, pa_source_output_state_
void pa_source_output_unlink(pa_source_output*o) {
pa_bool_t linked;
pa_assert(o);
+ pa_assert_ctl_context();
/* See pa_sink_unlink() for a couple of comments how this function
* works */
@@ -320,9 +543,14 @@ void pa_source_output_unlink(pa_source_output*o) {
update_n_corked(o, PA_SOURCE_OUTPUT_UNLINKED);
o->state = PA_SOURCE_OUTPUT_UNLINKED;
- if (linked && o->source)
+ if (linked && o->source) {
+ /* We might need to update the source's volume if we are in flat volume mode. */
+ if (pa_source_flat_volume_enabled(o->source))
+ pa_source_set_volume(o->source, NULL, FALSE, FALSE);
+
if (o->source->asyncmsgq)
pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o->source), PA_SOURCE_MESSAGE_REMOVE_OUTPUT, o, 0, NULL) == 0);
+ }
reset_callbacks(o);
@@ -346,6 +574,7 @@ static void source_output_free(pa_object* mo) {
pa_source_output *o = PA_SOURCE_OUTPUT(mo);
pa_assert(o);
+ pa_assert_ctl_context();
pa_assert(pa_source_output_refcnt(o) == 0);
if (PA_SOURCE_OUTPUT_IS_LINKED(o->state))
@@ -353,14 +582,15 @@ static void source_output_free(pa_object* mo) {
pa_log_info("Freeing output %u \"%s\"", o->index, pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_MEDIA_NAME)));
- pa_assert(!o->thread_info.attached);
-
if (o->thread_info.delay_memblockq)
pa_memblockq_free(o->thread_info.delay_memblockq);
if (o->thread_info.resampler)
pa_resampler_free(o->thread_info.resampler);
+ if (o->format)
+ pa_format_info_free(o->format);
+
if (o->proplist)
pa_proplist_free(o->proplist);
@@ -371,7 +601,9 @@ static void source_output_free(pa_object* mo) {
/* Called from main context */
void pa_source_output_put(pa_source_output *o) {
pa_source_output_state_t state;
+
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(o->state == PA_SOURCE_OUTPUT_INIT);
@@ -384,6 +616,21 @@ void pa_source_output_put(pa_source_output *o) {
update_n_corked(o, state);
o->state = state;
+ /* We might need to update the source's volume if we are in flat volume mode. */
+ if (pa_source_flat_volume_enabled(o->source))
+ pa_source_set_volume(o->source, NULL, FALSE, o->save_volume);
+ else {
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)) {
+ pa_assert(pa_cvolume_is_norm(&o->volume));
+ pa_assert(pa_cvolume_is_norm(&o->reference_ratio));
+ }
+
+ set_real_ratio(o, &o->volume);
+ }
+
+ o->thread_info.soft_volume = o->soft_volume;
+ o->thread_info.muted = o->muted;
+
pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o->source), PA_SOURCE_MESSAGE_ADD_OUTPUT, o, 0, NULL) == 0);
pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_NEW, o->index);
@@ -395,6 +642,7 @@ void pa_source_output_put(pa_source_output *o) {
/* Called from main context */
void pa_source_output_kill(pa_source_output*o) {
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
o->kill(o);
@@ -405,6 +653,7 @@ pa_usec_t pa_source_output_get_latency(pa_source_output *o, pa_usec_t *source_la
pa_usec_t r[2] = { 0, 0 };
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o), PA_SOURCE_OUTPUT_MESSAGE_GET_LATENCY, r, 0, NULL) == 0);
@@ -420,10 +669,13 @@ pa_usec_t pa_source_output_get_latency(pa_source_output *o, pa_usec_t *source_la
/* Called from thread context */
void pa_source_output_push(pa_source_output *o, const pa_memchunk *chunk) {
+ pa_bool_t need_volume_factor_source;
+ pa_bool_t volume_is_norm;
size_t length;
size_t limit, mbs = 0;
pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->thread_info.state));
pa_assert(chunk);
pa_assert(pa_frame_aligned(chunk->length, &o->source->sample_spec));
@@ -440,6 +692,9 @@ void pa_source_output_push(pa_source_output *o, const pa_memchunk *chunk) {
limit = o->process_rewind ? 0 : o->source->thread_info.max_rewind;
+ volume_is_norm = pa_cvolume_is_norm(&o->thread_info.soft_volume) && !o->thread_info.muted;
+ need_volume_factor_source = !pa_cvolume_is_norm(&o->volume_factor_source);
+
if (limit > 0 && o->source->monitor_of) {
pa_usec_t latency;
size_t n;
@@ -462,6 +717,7 @@ void pa_source_output_push(pa_source_output *o, const pa_memchunk *chunk) {
/* Implement the delay queue */
while ((length = pa_memblockq_get_length(o->thread_info.delay_memblockq)) > limit) {
pa_memchunk qchunk;
+ pa_bool_t nvfs = need_volume_factor_source;
length -= limit;
@@ -472,9 +728,36 @@ void pa_source_output_push(pa_source_output *o, const pa_memchunk *chunk) {
pa_assert(qchunk.length > 0);
- if (!o->thread_info.resampler)
+ /* It might be necessary to adjust the volume here */
+ if (!volume_is_norm) {
+ pa_memchunk_make_writable(&qchunk, 0);
+
+ if (o->thread_info.muted) {
+ pa_silence_memchunk(&qchunk, &o->thread_info.sample_spec);
+ nvfs = FALSE;
+
+ } else if (!o->thread_info.resampler && nvfs) {
+ pa_cvolume v;
+
+ /* If we don't need a resampler we can merge the
+ * post and the pre volume adjustment into one */
+
+ pa_sw_cvolume_multiply(&v, &o->thread_info.soft_volume, &o->volume_factor_source);
+ pa_volume_memchunk(&qchunk, &o->thread_info.sample_spec, &v);
+ nvfs = FALSE;
+
+ } else
+ pa_volume_memchunk(&qchunk, &o->thread_info.sample_spec, &o->thread_info.soft_volume);
+ }
+
+ if (!o->thread_info.resampler) {
+ if (nvfs) {
+ pa_memchunk_make_writable(&qchunk, 0);
+ pa_volume_memchunk(&qchunk, &o->source->sample_spec, &o->volume_factor_source);
+ }
+
o->push(o, &qchunk);
- else {
+ } else {
pa_memchunk rchunk;
if (mbs == 0)
@@ -485,8 +768,14 @@ void pa_source_output_push(pa_source_output *o, const pa_memchunk *chunk) {
pa_resampler_run(o->thread_info.resampler, &qchunk, &rchunk);
- if (rchunk.length > 0)
+ if (rchunk.length > 0) {
+ if (nvfs) {
+ pa_memchunk_make_writable(&rchunk, 0);
+ pa_volume_memchunk(&rchunk, &o->source->sample_spec, &o->volume_factor_source);
+ }
+
o->push(o, &rchunk);
+ }
if (rchunk.memblock)
pa_memblock_unref(rchunk.memblock);
@@ -499,8 +788,9 @@ void pa_source_output_push(pa_source_output *o, const pa_memchunk *chunk) {
/* Called from thread context */
void pa_source_output_process_rewind(pa_source_output *o, size_t nbytes /* in source sample spec */) {
- pa_source_output_assert_ref(o);
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->thread_info.state));
pa_assert(pa_frame_aligned(nbytes, &o->source->sample_spec));
@@ -526,8 +816,17 @@ void pa_source_output_process_rewind(pa_source_output *o, size_t nbytes /* in so
}
/* Called from thread context */
+size_t pa_source_output_get_max_rewind(pa_source_output *o) {
+ pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
+
+ return o->thread_info.resampler ? pa_resampler_request(o->thread_info.resampler, o->source->thread_info.max_rewind) : o->source->thread_info.max_rewind;
+}
+
+/* Called from thread context */
void pa_source_output_update_max_rewind(pa_source_output *o, size_t nbytes /* in the source's sample spec */) {
pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->thread_info.state));
pa_assert(pa_frame_aligned(nbytes, &o->source->sample_spec));
@@ -538,15 +837,16 @@ void pa_source_output_update_max_rewind(pa_source_output *o, size_t nbytes /* i
/* Called from thread context */
pa_usec_t pa_source_output_set_requested_latency_within_thread(pa_source_output *o, pa_usec_t usec) {
pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
if (!(o->source->flags & PA_SOURCE_DYNAMIC_LATENCY))
- usec = o->source->fixed_latency;
+ usec = o->source->thread_info.fixed_latency;
if (usec != (pa_usec_t) -1)
usec = PA_CLAMP(usec, o->source->thread_info.min_latency, o->source->thread_info.max_latency);
o->thread_info.requested_source_latency = usec;
- pa_source_invalidate_requested_latency(o->source);
+ pa_source_invalidate_requested_latency(o->source, TRUE);
return usec;
}
@@ -554,6 +854,7 @@ pa_usec_t pa_source_output_set_requested_latency_within_thread(pa_source_output
/* Called from main context */
pa_usec_t pa_source_output_set_requested_latency(pa_source_output *o, pa_usec_t usec) {
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
if (PA_SOURCE_OUTPUT_IS_LINKED(o->state) && o->source) {
pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o), PA_SOURCE_OUTPUT_MESSAGE_SET_REQUESTED_LATENCY, &usec, 0, NULL) == 0);
@@ -565,7 +866,7 @@ pa_usec_t pa_source_output_set_requested_latency(pa_source_output *o, pa_usec_t
if (o->source) {
if (!(o->source->flags & PA_SOURCE_DYNAMIC_LATENCY))
- usec = o->source->fixed_latency;
+ usec = pa_source_get_fixed_latency(o->source);
if (usec != (pa_usec_t) -1) {
pa_usec_t min_latency, max_latency;
@@ -582,6 +883,7 @@ pa_usec_t pa_source_output_set_requested_latency(pa_source_output *o, pa_usec_t
/* Called from main context */
pa_usec_t pa_source_output_get_requested_latency(pa_source_output *o) {
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
if (PA_SOURCE_OUTPUT_IS_LINKED(o->state) && o->source) {
pa_usec_t usec = 0;
@@ -596,8 +898,170 @@ pa_usec_t pa_source_output_get_requested_latency(pa_source_output *o) {
}
/* Called from main context */
+void pa_source_output_set_volume(pa_source_output *o, const pa_cvolume *volume, pa_bool_t save, pa_bool_t absolute) {
+ pa_cvolume v;
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
+ pa_assert(volume);
+ pa_assert(pa_cvolume_valid(volume));
+ pa_assert(volume->channels == 1 || pa_cvolume_compatible(volume, &o->sample_spec));
+ pa_assert(o->volume_writable);
+
+ if (!absolute && pa_source_flat_volume_enabled(o->source)) {
+ v = o->source->reference_volume;
+ pa_cvolume_remap(&v, &o->source->channel_map, &o->channel_map);
+
+ if (pa_cvolume_compatible(volume, &o->sample_spec))
+ volume = pa_sw_cvolume_multiply(&v, &v, volume);
+ else
+ volume = pa_sw_cvolume_multiply_scalar(&v, &v, pa_cvolume_max(volume));
+ } else {
+ if (!pa_cvolume_compatible(volume, &o->sample_spec)) {
+ v = o->volume;
+ volume = pa_cvolume_scale(&v, pa_cvolume_max(volume));
+ }
+ }
+
+ if (pa_cvolume_equal(volume, &o->volume)) {
+ o->save_volume = o->save_volume || save;
+ return;
+ }
+
+ o->volume = *volume;
+ o->save_volume = save;
+
+ if (pa_source_flat_volume_enabled(o->source)) {
+ /* We are in flat volume mode, so let's update all source input
+ * volumes and update the flat volume of the source */
+
+ pa_source_set_volume(o->source, NULL, TRUE, save);
+
+ } else {
+ /* OK, we are in normal volume mode. The volume only affects
+ * ourselves */
+ set_real_ratio(o, volume);
+
+ /* Copy the new soft_volume to the thread_info struct */
+ pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o), PA_SOURCE_OUTPUT_MESSAGE_SET_SOFT_VOLUME, NULL, 0, NULL) == 0);
+ }
+
+ /* The volume changed, let's tell people so */
+ if (o->volume_changed)
+ o->volume_changed(o);
+
+ /* The virtual volume changed, let's tell people so */
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+}
+
+/* Called from main context */
+static void set_real_ratio(pa_source_output *o, const pa_cvolume *v) {
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
+ pa_assert(!v || pa_cvolume_compatible(v, &o->sample_spec));
+
+ /* This basically calculates:
+ *
+ * o->real_ratio := v
+ * o->soft_volume := o->real_ratio * o->volume_factor */
+
+ if (v)
+ o->real_ratio = *v;
+ else
+ pa_cvolume_reset(&o->real_ratio, o->sample_spec.channels);
+
+ pa_sw_cvolume_multiply(&o->soft_volume, &o->real_ratio, &o->volume_factor);
+ /* We don't copy the data to the thread_info data. That's left for someone else to do */
+}
+
+/* Called from main or I/O context */
+pa_bool_t pa_source_output_is_passthrough(pa_source_output *o) {
+ pa_source_output_assert_ref(o);
+
+ if (PA_UNLIKELY(!pa_format_info_is_pcm(o->format)))
+ return TRUE;
+
+ if (PA_UNLIKELY(o->flags & PA_SOURCE_OUTPUT_PASSTHROUGH))
+ return TRUE;
+
+ return FALSE;
+}
+
+/* Called from main context */
+pa_bool_t pa_source_output_is_volume_readable(pa_source_output *o) {
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+
+ return !pa_source_output_is_passthrough(o);
+}
+
+/* Called from main context */
+pa_cvolume *pa_source_output_get_volume(pa_source_output *o, pa_cvolume *volume, pa_bool_t absolute) {
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
+ pa_assert(pa_source_output_is_volume_readable(o));
+
+ if (absolute || !pa_source_flat_volume_enabled(o->source))
+ *volume = o->volume;
+ else
+ *volume = o->reference_ratio;
+
+ return volume;
+}
+
+/* Called from main context */
+void pa_source_output_set_mute(pa_source_output *o, pa_bool_t mute, pa_bool_t save) {
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
+
+ if (!o->muted == !mute) {
+ o->save_muted = o->save_muted || mute;
+ return;
+ }
+
+ o->muted = mute;
+ o->save_muted = save;
+
+ pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o), PA_SOURCE_OUTPUT_MESSAGE_SET_SOFT_MUTE, NULL, 0, NULL) == 0);
+
+ /* The mute status changed, let's tell people so */
+ if (o->mute_changed)
+ o->mute_changed(o);
+
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+}
+
+/* Called from main context */
+pa_bool_t pa_source_output_get_mute(pa_source_output *o) {
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
+
+ return o->muted;
+}
+
+/* Called from main thread */
+void pa_source_output_update_proplist(pa_source_output *o, pa_update_mode_t mode, pa_proplist *p) {
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+
+ if (p)
+ pa_proplist_update(o->proplist, mode, p);
+
+ if (PA_SOURCE_OUTPUT_IS_LINKED(o->state)) {
+ pa_hook_fire(&o->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_PROPLIST_CHANGED], o);
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+ }
+}
+
+/* Called from main context */
void pa_source_output_cork(pa_source_output *o, pa_bool_t b) {
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
source_output_set_state(o, b ? PA_SOURCE_OUTPUT_CORKED : PA_SOURCE_OUTPUT_RUNNING);
@@ -606,6 +1070,7 @@ void pa_source_output_cork(pa_source_output *o, pa_bool_t b) {
/* Called from main context */
int pa_source_output_set_rate(pa_source_output *o, uint32_t rate) {
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
pa_return_val_if_fail(o->thread_info.resampler, -PA_ERR_BADSTATE);
@@ -623,6 +1088,7 @@ int pa_source_output_set_rate(pa_source_output *o, uint32_t rate) {
/* Called from main context */
void pa_source_output_set_name(pa_source_output *o, const char *name) {
const char *old;
+ pa_assert_ctl_context();
pa_source_output_assert_ref(o);
if (!name && !pa_proplist_contains(o->proplist, PA_PROP_MEDIA_NAME))
@@ -644,22 +1110,10 @@ void pa_source_output_set_name(pa_source_output *o, const char *name) {
}
}
-/* Called from main thread */
-void pa_source_output_update_proplist(pa_source_output *o, pa_update_mode_t mode, pa_proplist *p) {
- pa_source_output_assert_ref(o);
-
- if (p)
- pa_proplist_update(o->proplist, mode, p);
-
- if (PA_SINK_IS_LINKED(o->state)) {
- pa_hook_fire(&o->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_PROPLIST_CHANGED], o);
- pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
- }
-}
-
/* Called from main context */
pa_resample_method_t pa_source_output_get_resample_method(pa_source_output *o) {
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
return o->actual_resample_method;
}
@@ -667,6 +1121,7 @@ pa_resample_method_t pa_source_output_get_resample_method(pa_source_output *o) {
/* Called from main context */
pa_bool_t pa_source_output_may_move(pa_source_output *o) {
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
if (o->flags & PA_SOURCE_OUTPUT_DONT_MOVE)
@@ -708,6 +1163,7 @@ int pa_source_output_start_move(pa_source_output *o) {
int r;
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
pa_assert(o->source);
@@ -724,6 +1180,11 @@ int pa_source_output_start_move(pa_source_output *o) {
if (pa_source_output_get_state(o) == PA_SOURCE_OUTPUT_CORKED)
pa_assert_se(origin->n_corked-- >= 1);
+ if (pa_source_flat_volume_enabled(o->source))
+ /* We might need to update the source's volume if we are in flat
+ * volume mode. */
+ pa_source_set_volume(o->source, NULL, FALSE, FALSE);
+
pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o->source), PA_SOURCE_MESSAGE_REMOVE_OUTPUT, o, 0, NULL) == 0);
pa_source_update_status(o->source);
@@ -734,17 +1195,179 @@ int pa_source_output_start_move(pa_source_output *o) {
return 0;
}
+/* Called from main context. If it has an origin source that uses volume sharing,
+ * then also the origin source and all streams connected to it need to update
+ * their volume - this function does all that by using recursion. */
+static void update_volume_due_to_moving(pa_source_output *o, pa_source *dest) {
+ pa_cvolume old_volume;
+
+ pa_assert(o);
+ pa_assert(dest);
+ pa_assert(o->source); /* The destination source should already be set. */
+
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)) {
+ pa_source *root_source = o->source;
+ pa_source_output *destination_source_output;
+ uint32_t idx;
+
+ while (root_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)
+ root_source = root_source->output_from_master->source;
+
+ if (pa_source_flat_volume_enabled(o->source)) {
+ /* Ok, so the origin source uses volume sharing, and flat volume is
+ * enabled. The volume will have to be updated as follows:
+ *
+ * o->volume := o->source->real_volume
+ * (handled later by pa_source_set_volume)
+ * o->reference_ratio := o->volume / o->source->reference_volume
+ * (handled later by pa_source_set_volume)
+ * o->real_ratio stays unchanged
+ * (streams whose origin source uses volume sharing should
+ * always have real_ratio of 0 dB)
+ * o->soft_volume stays unchanged
+ * (streams whose origin source uses volume sharing should
+ * always have volume_factor as soft_volume, so no change
+ * should be needed) */
+
+ pa_assert(pa_cvolume_is_norm(&o->real_ratio));
+ pa_assert(pa_cvolume_equal(&o->soft_volume, &o->volume_factor));
+
+ /* Notifications will be sent by pa_source_set_volume(). */
+
+ } else {
+ /* Ok, so the origin source uses volume sharing, and flat volume is
+ * disabled. The volume will have to be updated as follows:
+ *
+ * o->volume := 0 dB
+ * o->reference_ratio := 0 dB
+ * o->real_ratio stays unchanged
+ * (streams whose origin source uses volume sharing should
+ * always have real_ratio of 0 dB)
+ * o->soft_volume stays unchanged
+ * (streams whose origin source uses volume sharing should
+ * always have volume_factor as soft_volume, so no change
+ * should be needed) */
+
+ old_volume = o->volume;
+ pa_cvolume_reset(&o->volume, o->volume.channels);
+ pa_cvolume_reset(&o->reference_ratio, o->reference_ratio.channels);
+ pa_assert(pa_cvolume_is_norm(&o->real_ratio));
+ pa_assert(pa_cvolume_equal(&o->soft_volume, &o->volume_factor));
+
+ /* Notify others about the changed source output volume. */
+ if (!pa_cvolume_equal(&o->volume, &old_volume)) {
+ if (o->volume_changed)
+ o->volume_changed(o);
+
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+ }
+ }
+
+ /* Additionally, the origin source volume needs updating:
+ *
+ * o->destination_source->reference_volume := root_source->reference_volume
+ * o->destination_source->real_volume := root_source->real_volume
+ * o->destination_source->soft_volume stays unchanged
+ * (sources that use volume sharing should always have
+ * soft_volume of 0 dB) */
+
+ old_volume = o->destination_source->reference_volume;
+
+ o->destination_source->reference_volume = root_source->reference_volume;
+ pa_cvolume_remap(&o->destination_source->reference_volume, &root_source->channel_map, &o->destination_source->channel_map);
+
+ o->destination_source->real_volume = root_source->real_volume;
+ pa_cvolume_remap(&o->destination_source->real_volume, &root_source->channel_map, &o->destination_source->channel_map);
+
+ pa_assert(pa_cvolume_is_norm(&o->destination_source->soft_volume));
+
+ /* Notify others about the changed source volume. If you wonder whether
+ * o->destination_source->set_volume() should be called somewhere, that's not
+ * the case, because sources that use volume sharing shouldn't have any
+ * internal volume that set_volume() would update. If you wonder
+ * whether the thread_info variables should be synced, yes, they
+ * should, and it's done by the PA_SOURCE_MESSAGE_FINISH_MOVE message
+ * handler. */
+ if (!pa_cvolume_equal(&o->destination_source->reference_volume, &old_volume))
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE, o->destination_source->index);
+
+ /* Recursively update origin source outputs. */
+ PA_IDXSET_FOREACH(destination_source_output, o->destination_source->outputs, idx)
+ update_volume_due_to_moving(destination_source_output, dest);
+
+ } else {
+ old_volume = o->volume;
+
+ if (pa_source_flat_volume_enabled(o->source)) {
+ /* Ok, so this is a regular stream, and flat volume is enabled. The
+ * volume will have to be updated as follows:
+ *
+ * o->volume := o->reference_ratio * o->source->reference_volume
+ * o->reference_ratio stays unchanged
+ * o->real_ratio := o->volume / o->source->real_volume
+ * (handled later by pa_source_set_volume)
+ * o->soft_volume := o->real_ratio * o->volume_factor
+ * (handled later by pa_source_set_volume) */
+
+ o->volume = o->source->reference_volume;
+ pa_cvolume_remap(&o->volume, &o->source->channel_map, &o->channel_map);
+ pa_sw_cvolume_multiply(&o->volume, &o->volume, &o->reference_ratio);
+
+ } else {
+ /* Ok, so this is a regular stream, and flat volume is disabled.
+ * The volume will have to be updated as follows:
+ *
+ * o->volume := o->reference_ratio
+ * o->reference_ratio stays unchanged
+ * o->real_ratio := o->reference_ratio
+ * o->soft_volume := o->real_ratio * o->volume_factor */
+
+ o->volume = o->reference_ratio;
+ o->real_ratio = o->reference_ratio;
+ pa_sw_cvolume_multiply(&o->soft_volume, &o->real_ratio, &o->volume_factor);
+ }
+
+ /* Notify others about the changed source output volume. */
+ if (!pa_cvolume_equal(&o->volume, &old_volume)) {
+ /* XXX: In case o->source has flat volume enabled, then real_ratio
+ * and soft_volume are not updated yet. Let's hope that the
+ * callback implementation doesn't care about those variables... */
+ if (o->volume_changed)
+ o->volume_changed(o);
+
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+ }
+ }
+
+ /* If o->source == dest, then recursion has finished, and we can finally call
+ * pa_source_set_volume(), which will do the rest of the updates. */
+ if ((o->source == dest) && pa_source_flat_volume_enabled(o->source))
+ pa_source_set_volume(o->source, NULL, FALSE, o->save_volume);
+}
+
/* Called from main context */
int pa_source_output_finish_move(pa_source_output *o, pa_source *dest, pa_bool_t save) {
pa_resampler *new_resampler;
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
pa_assert(!o->source);
pa_source_assert_ref(dest);
if (!pa_source_output_may_move_to(o, dest))
- return -1;
+ return -PA_ERR_NOTSUPPORTED;
+
+ if (pa_source_output_is_passthrough(o) && !pa_source_check_format(dest, o->format)) {
+ pa_proplist *p = pa_proplist_new();
+ pa_log_debug("New source doesn't support stream format, sending format-changed and killing");
+ /* Tell the client what device we want to be on if it is going to
+ * reconnect */
+ pa_proplist_sets(p, "device", dest->name);
+ pa_source_output_send_event(o, PA_STREAM_EVENT_FORMAT_LOST, p);
+ pa_proplist_free(p);
+ return -PA_ERR_NOTSUPPORTED;
+ }
if (o->thread_info.resampler &&
pa_sample_spec_equal(pa_resampler_input_sample_spec(o->thread_info.resampler), &dest->sample_spec) &&
@@ -757,7 +1380,7 @@ int pa_source_output_finish_move(pa_source_output *o, pa_source *dest, pa_bool_t
!pa_sample_spec_equal(&o->sample_spec, &dest->sample_spec) ||
!pa_channel_map_equal(&o->channel_map, &dest->channel_map)) {
- /* Okey, we need a new resampler for the new source */
+ /* Okay, we need a new resampler for the new source */
if (!(new_resampler = pa_resampler_new(
o->core->mempool,
@@ -780,11 +1403,14 @@ int pa_source_output_finish_move(pa_source_output *o, pa_source *dest, pa_bool_t
o->save_source = save;
pa_idxset_put(o->source->outputs, pa_source_output_ref(o), NULL);
+ pa_cvolume_remap(&o->volume_factor_source, &o->channel_map, &o->source->channel_map);
+
if (pa_source_output_get_state(o) == PA_SOURCE_OUTPUT_CORKED)
o->source->n_corked++;
/* Replace resampler */
if (new_resampler != o->thread_info.resampler) {
+
if (o->thread_info.resampler)
pa_resampler_free(o->thread_info.resampler);
o->thread_info.resampler = new_resampler;
@@ -800,10 +1426,13 @@ int pa_source_output_finish_move(pa_source_output *o, pa_source *dest, pa_bool_t
1,
0,
&o->source->silence);
+ o->actual_resample_method = new_resampler ? pa_resampler_get_method(new_resampler) : PA_RESAMPLER_INVALID;
}
pa_source_update_status(dest);
+ update_volume_due_to_moving(o, dest);
+
pa_assert_se(pa_asyncmsgq_send(o->source->asyncmsgq, PA_MSGOBJECT(o->source), PA_SOURCE_MESSAGE_ADD_OUTPUT, o, 0, NULL) == 0);
pa_log_debug("Successfully moved source output %i to %s.", o->index, dest->name);
@@ -816,10 +1445,29 @@ int pa_source_output_finish_move(pa_source_output *o, pa_source *dest, pa_bool_t
}
/* Called from main context */
+void pa_source_output_fail_move(pa_source_output *o) {
+
+ pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
+ pa_assert(!o->source);
+
+ /* Check if someone wants this source output? */
+ if (pa_hook_fire(&o->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_MOVE_FAIL], o) == PA_HOOK_STOP)
+ return;
+
+ if (o->moving)
+ o->moving(o, NULL);
+
+ pa_source_output_kill(o);
+}
+
+/* Called from main context */
int pa_source_output_move_to(pa_source_output *o, pa_source *dest, pa_bool_t save) {
int r;
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(o->state));
pa_assert(o->source);
pa_source_assert_ref(dest);
@@ -838,6 +1486,7 @@ int pa_source_output_move_to(pa_source_output *o, pa_source *dest, pa_bool_t sav
}
if ((r = pa_source_output_finish_move(o, dest, save)) < 0) {
+ pa_source_output_fail_move(o);
pa_source_output_unref(o);
return r;
}
@@ -850,6 +1499,7 @@ int pa_source_output_move_to(pa_source_output *o, pa_source *dest, pa_bool_t sav
/* Called from IO thread context */
void pa_source_output_set_state_within_thread(pa_source_output *o, pa_source_output_state_t state) {
pa_source_output_assert_ref(o);
+ pa_source_output_assert_io_context(o);
if (state == o->thread_info.state)
return;
@@ -885,6 +1535,7 @@ int pa_source_output_process_msg(pa_msgobject *mo, int code, void *userdata, int
case PA_SOURCE_OUTPUT_MESSAGE_SET_STATE:
pa_source_output_set_state_within_thread(o, PA_PTR_TO_UINT(userdata));
+
return 0;
case PA_SOURCE_OUTPUT_MESSAGE_SET_REQUESTED_LATENCY: {
@@ -901,16 +1552,30 @@ int pa_source_output_process_msg(pa_msgobject *mo, int code, void *userdata, int
*r = o->thread_info.requested_source_latency;
return 0;
}
+
+ case PA_SOURCE_OUTPUT_MESSAGE_SET_SOFT_VOLUME:
+ if (!pa_cvolume_equal(&o->thread_info.soft_volume, &o->soft_volume)) {
+ o->thread_info.soft_volume = o->soft_volume;
+ }
+ return 0;
+
+ case PA_SOURCE_OUTPUT_MESSAGE_SET_SOFT_MUTE:
+ if (o->thread_info.muted != o->muted) {
+ o->thread_info.muted = o->muted;
+ }
+ return 0;
}
return -PA_ERR_NOTIMPLEMENTED;
}
+/* Called from main context */
void pa_source_output_send_event(pa_source_output *o, const char *event, pa_proplist *data) {
pa_proplist *pl = NULL;
pa_source_output_send_event_hook_data hook_data;
pa_source_output_assert_ref(o);
+ pa_assert_ctl_context();
pa_assert(event);
if (!o->send_event)
diff --git a/src/pulsecore/source-output.h b/src/pulsecore/source-output.h
index 9824e160..b9a2b6b2 100644
--- a/src/pulsecore/source-output.h
+++ b/src/pulsecore/source-output.h
@@ -27,11 +27,13 @@
typedef struct pa_source_output pa_source_output;
#include <pulse/sample.h>
-#include <pulsecore/source.h>
+#include <pulse/format.h>
#include <pulsecore/memblockq.h>
#include <pulsecore/resampler.h>
#include <pulsecore/module.h>
#include <pulsecore/client.h>
+#include <pulsecore/source.h>
+#include <pulsecore/core.h>
#include <pulsecore/sink-input.h>
typedef enum pa_source_output_state {
@@ -55,7 +57,9 @@ typedef enum pa_source_output_flags {
PA_SOURCE_OUTPUT_FIX_RATE = 64,
PA_SOURCE_OUTPUT_FIX_CHANNELS = 128,
PA_SOURCE_OUTPUT_DONT_INHIBIT_AUTO_SUSPEND = 256,
- PA_SOURCE_OUTPUT_FAIL_ON_SUSPEND = 512
+ PA_SOURCE_OUTPUT_NO_CREATE_ON_SUSPEND = 512,
+ PA_SOURCE_OUTPUT_KILL_ON_SUSPEND = 1024,
+ PA_SOURCE_OUTPUT_PASSTHROUGH = 2048
} pa_source_output_flags_t;
struct pa_source_output {
@@ -73,18 +77,34 @@ struct pa_source_output {
pa_module *module; /* may be NULL */
pa_client *client; /* may be NULL */
- pa_source *source; /* NULL while being moved */
+ pa_source *source; /* NULL while being moved */
+ pa_source *destination_source; /* only set by filter sources */
/* A source output can monitor just a single input of a sink, in which case we find it here */
pa_sink_input *direct_on_input; /* may be NULL */
pa_sample_spec sample_spec;
pa_channel_map channel_map;
+ pa_format_info *format;
+
+ /* Also see http://pulseaudio.org/wiki/InternalVolumes */
+ pa_cvolume volume; /* The volume clients are informed about */
+ pa_cvolume reference_ratio; /* The ratio of the stream's volume to the source's reference volume */
+ pa_cvolume real_ratio; /* The ratio of the stream's volume to the source's real volume */
+ pa_cvolume volume_factor; /* An internally used volume factor that can be used by modules to apply effects and suchlike without having that visible to the outside */
+ pa_cvolume soft_volume; /* The internal software volume we apply to all PCM data while it passes through. Usually calculated as real_ratio * volume_factor */
+
+ pa_cvolume volume_factor_source; /* A second volume factor in format of the source this stream is connected to */
+
+ pa_bool_t volume_writable:1;
- /* if TRUE then the source we are connected to is worth
- * remembering, i.e. was explicitly chosen by the user and not
- * automatically. module-stream-restore looks for this.*/
- pa_bool_t save_source:1;
+ pa_bool_t muted:1;
+
+ /* if TRUE then the source we are connected to and/or the volume
+ * set is worth remembering, i.e. was explicitly chosen by the
+ * user and not automatically. module-stream-restore looks for
+ * this.*/
+ pa_bool_t save_source:1, save_volume:1, save_muted:1;
pa_resample_method_t requested_resample_method, actual_resample_method;
@@ -108,8 +128,15 @@ struct pa_source_output {
* from IO context. */
void (*update_source_latency_range) (pa_source_output *o); /* may be NULL */
+ /* Called whenver the fixed latency of the source changes, if there
+ * is one. Called from IO context. */
+ void (*update_source_fixed_latency) (pa_source_output *i); /* may be NULL */
+
/* If non-NULL this function is called when the output is first
- * connected to a source. Called from IO thread context */
+ * connected to a source or when the rtpoll/asyncmsgq fields
+ * change. You usually don't need to implement this function
+ * unless you rewrite a source that is piggy-backed onto
+ * another. Called from IO thread context */
void (*attach) (pa_source_output *o); /* may be NULL */
/* If non-NULL this function is called when the output is
@@ -125,9 +152,11 @@ struct pa_source_output {
void (*suspend_within_thread) (pa_source_output *o, pa_bool_t b); /* may be NULL */
/* If non-NULL called whenever the source output is moved to a new
- * source. Called from main context after the stream was detached
- * from the old source and before it is attached to the new
- * source. */
+ * source. Called from main context after the source output has been
+ * detached from the old source and before it has been attached to
+ * the new source. If dest is NULL the move was executed in two
+ * phases and the second one failed; the stream will be destroyed
+ * after this call. */
void (*moving) (pa_source_output *o, pa_source *dest); /* may be NULL */
/* Supposed to unlink and destroy this stream. Called from main
@@ -153,9 +182,20 @@ struct pa_source_output {
* control events. */
void (*send_event)(pa_source_output *o, const char *event, pa_proplist* data);
+ /* If non-NULL this function is called whenever the source output
+ * volume changes. Called from main context */
+ void (*volume_changed)(pa_source_output *o); /* may be NULL */
+
+ /* If non-NULL this function is called whenever the source output
+ * mute status changes. Called from main context */
+ void (*mute_changed)(pa_source_output *o); /* may be NULL */
+
struct {
pa_source_output_state_t state;
+ pa_cvolume soft_volume;
+ pa_bool_t muted:1;
+
pa_bool_t attached:1; /* True only between ->attach() and ->detach() calls */
pa_sample_spec sample_spec;
@@ -175,7 +215,7 @@ struct pa_source_output {
void *userdata;
};
-PA_DECLARE_CLASS(pa_source_output);
+PA_DECLARE_PUBLIC_CLASS(pa_source_output);
#define PA_SOURCE_OUTPUT(o) pa_source_output_cast(o)
enum {
@@ -184,6 +224,8 @@ enum {
PA_SOURCE_OUTPUT_MESSAGE_SET_STATE,
PA_SOURCE_OUTPUT_MESSAGE_SET_REQUESTED_LATENCY,
PA_SOURCE_OUTPUT_MESSAGE_GET_REQUESTED_LATENCY,
+ PA_SOURCE_OUTPUT_MESSAGE_SET_SOFT_VOLUME,
+ PA_SOURCE_OUTPUT_MESSAGE_SET_SOFT_MUTE,
PA_SOURCE_OUTPUT_MESSAGE_MAX
};
@@ -194,6 +236,8 @@ typedef struct pa_source_output_send_event_hook_data {
} pa_source_output_send_event_hook_data;
typedef struct pa_source_output_new_data {
+ pa_source_output_flags_t flags;
+
pa_proplist *proplist;
pa_sink_input *direct_on_input;
@@ -202,21 +246,42 @@ typedef struct pa_source_output_new_data {
pa_client *client;
pa_source *source;
+ pa_source *destination_source;
pa_resample_method_t resample_method;
pa_sample_spec sample_spec;
pa_channel_map channel_map;
+ pa_format_info *format;
+ pa_idxset *req_formats;
+ pa_idxset *nego_formats;
+
+ pa_cvolume volume, volume_factor, volume_factor_source;
+ pa_bool_t muted:1;
pa_bool_t sample_spec_is_set:1;
pa_bool_t channel_map_is_set:1;
- pa_bool_t save_source:1;
+ pa_bool_t volume_is_set:1, volume_factor_is_set:1, volume_factor_source_is_set:1;
+ pa_bool_t muted_is_set:1;
+
+ pa_bool_t volume_is_absolute:1;
+
+ pa_bool_t volume_writable:1;
+
+ pa_bool_t save_source:1, save_volume:1, save_muted:1;
} pa_source_output_new_data;
pa_source_output_new_data* pa_source_output_new_data_init(pa_source_output_new_data *data);
void pa_source_output_new_data_set_sample_spec(pa_source_output_new_data *data, const pa_sample_spec *spec);
void pa_source_output_new_data_set_channel_map(pa_source_output_new_data *data, const pa_channel_map *map);
+pa_bool_t pa_source_output_new_data_is_passthrough(pa_source_output_new_data *data);
+void pa_source_output_new_data_set_volume(pa_source_output_new_data *data, const pa_cvolume *volume);
+void pa_source_output_new_data_apply_volume_factor(pa_source_output_new_data *data, const pa_cvolume *volume_factor);
+void pa_source_output_new_data_apply_volume_factor_source(pa_source_output_new_data *data, const pa_cvolume *volume_factor);
+void pa_source_output_new_data_set_muted(pa_source_output_new_data *data, pa_bool_t mute);
+pa_bool_t pa_source_output_new_data_set_source(pa_source_output_new_data *data, pa_source *s, pa_bool_t save);
+pa_bool_t pa_source_output_new_data_set_formats(pa_source_output_new_data *data, pa_idxset *formats);
void pa_source_output_new_data_done(pa_source_output_new_data *data);
/* To be called by the implementing module only */
@@ -224,8 +289,7 @@ void pa_source_output_new_data_done(pa_source_output_new_data *data);
int pa_source_output_new(
pa_source_output**o,
pa_core *core,
- pa_source_output_new_data *data,
- pa_source_output_flags_t flags);
+ pa_source_output_new_data *data);
void pa_source_output_put(pa_source_output *o);
void pa_source_output_unlink(pa_source_output*o);
@@ -238,6 +302,8 @@ void pa_source_output_cork(pa_source_output *o, pa_bool_t b);
int pa_source_output_set_rate(pa_source_output *o, uint32_t rate);
+size_t pa_source_output_get_max_rewind(pa_source_output *o);
+
/* Callable by everyone */
/* External code may request disconnection with this funcion */
@@ -245,6 +311,14 @@ void pa_source_output_kill(pa_source_output*o);
pa_usec_t pa_source_output_get_latency(pa_source_output *o, pa_usec_t *source_latency);
+pa_bool_t pa_source_output_is_volume_readable(pa_source_output *o);
+pa_bool_t pa_source_output_is_passthrough(pa_source_output *o);
+void pa_source_output_set_volume(pa_source_output *o, const pa_cvolume *volume, pa_bool_t save, pa_bool_t absolute);
+pa_cvolume *pa_source_output_get_volume(pa_source_output *o, pa_cvolume *volume, pa_bool_t absolute);
+
+void pa_source_output_set_mute(pa_source_output *o, pa_bool_t mute, pa_bool_t save);
+pa_bool_t pa_source_output_get_mute(pa_source_output *o);
+
void pa_source_output_update_proplist(pa_source_output *o, pa_update_mode_t mode, pa_proplist *p);
pa_resample_method_t pa_source_output_get_resample_method(pa_source_output *o);
@@ -260,6 +334,7 @@ int pa_source_output_move_to(pa_source_output *o, pa_source *dest, pa_bool_t sav
* new source */
int pa_source_output_start_move(pa_source_output *o);
int pa_source_output_finish_move(pa_source_output *o, pa_source *dest, pa_bool_t save);
+void pa_source_output_fail_move(pa_source_output *o);
#define pa_source_output_get_state(o) ((o)->state)
@@ -277,4 +352,7 @@ int pa_source_output_process_msg(pa_msgobject *mo, int code, void *userdata, int
pa_usec_t pa_source_output_set_requested_latency_within_thread(pa_source_output *o, pa_usec_t usec);
+#define pa_source_output_assert_io_context(s) \
+ pa_assert(pa_thread_mq_get() || !PA_SOURCE_OUTPUT_IS_LINKED((s)->state))
+
#endif
diff --git a/src/pulsecore/source.c b/src/pulsecore/source.c
index 8aeb5606..70248026 100644
--- a/src/pulsecore/source.c
+++ b/src/pulsecore/source.c
@@ -26,18 +26,21 @@
#include <stdio.h>
#include <stdlib.h>
-#include <string.h>
#include <pulse/utf8.h>
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
#include <pulse/util.h>
+#include <pulse/rtclock.h>
+#include <pulse/internal.h>
+#include <pulsecore/core-util.h>
#include <pulsecore/source-output.h>
#include <pulsecore/namereg.h>
#include <pulsecore/core-subscribe.h>
#include <pulsecore/log.h>
#include <pulsecore/sample-util.h>
+#include <pulsecore/flist.h>
#include "source.h"
@@ -45,14 +48,29 @@
#define ABSOLUTE_MAX_LATENCY (10*PA_USEC_PER_SEC)
#define DEFAULT_FIXED_LATENCY (250*PA_USEC_PER_MSEC)
-static PA_DEFINE_CHECK_TYPE(pa_source, pa_msgobject);
+PA_DEFINE_PUBLIC_CLASS(pa_source, pa_msgobject);
+
+struct pa_source_volume_change {
+ pa_usec_t at;
+ pa_cvolume hw_volume;
+
+ PA_LLIST_FIELDS(pa_source_volume_change);
+};
+
+struct source_message_set_port {
+ pa_device_port *port;
+ int ret;
+};
static void source_free(pa_object *o);
+static void pa_source_volume_change_push(pa_source *s);
+static void pa_source_volume_change_flush(pa_source *s);
+
pa_source_new_data* pa_source_new_data_init(pa_source_new_data *data) {
pa_assert(data);
- memset(data, 0, sizeof(*data));
+ pa_zero(*data);
data->proplist = pa_proplist_new();
return data;
@@ -93,11 +111,29 @@ void pa_source_new_data_set_muted(pa_source_new_data *data, pa_bool_t mute) {
data->muted = !!mute;
}
+void pa_source_new_data_set_port(pa_source_new_data *data, const char *port) {
+ pa_assert(data);
+
+ pa_xfree(data->active_port);
+ data->active_port = pa_xstrdup(port);
+}
+
void pa_source_new_data_done(pa_source_new_data *data) {
pa_assert(data);
- pa_xfree(data->name);
pa_proplist_free(data->proplist);
+
+ if (data->ports) {
+ pa_device_port *p;
+
+ while ((p = pa_hashmap_steal_first(data->ports)))
+ pa_device_port_free(p);
+
+ pa_hashmap_free(data->ports, NULL, NULL);
+ }
+
+ pa_xfree(data->name);
+ pa_xfree(data->active_port);
}
/* Called from main context */
@@ -110,6 +146,8 @@ static void reset_callbacks(pa_source *s) {
s->get_mute = NULL;
s->set_mute = NULL;
s->update_requested_latency = NULL;
+ s->set_port = NULL;
+ s->get_formats = NULL;
}
/* Called from main context */
@@ -126,10 +164,12 @@ pa_source* pa_source_new(
pa_assert(core);
pa_assert(data);
pa_assert(data->name);
+ pa_assert_ctl_context();
s = pa_msgobject_new(pa_source);
if (!(name = pa_namereg_register(core, data->name, PA_NAMEREG_SOURCE, s, data->namereg_fail))) {
+ pa_log_debug("Failed to register name %s.", data->name);
pa_xfree(s);
return NULL;
}
@@ -142,6 +182,8 @@ pa_source* pa_source_new(
return NULL;
}
+ /* FIXME, need to free s here on failure */
+
pa_return_null_if_fail(!data->driver || pa_utf8_valid(data->driver));
pa_return_null_if_fail(data->name && pa_utf8_valid(data->name) && data->name[0]);
@@ -153,11 +195,17 @@ pa_source* pa_source_new(
pa_return_null_if_fail(pa_channel_map_valid(&data->channel_map));
pa_return_null_if_fail(data->channel_map.channels == data->sample_spec.channels);
- if (!data->volume_is_set)
+ /* FIXME: There should probably be a general function for checking whether
+ * the source volume is allowed to be set, like there is for source outputs. */
+ pa_assert(!data->volume_is_set || !(flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER));
+
+ if (!data->volume_is_set) {
pa_cvolume_reset(&data->volume, data->sample_spec.channels);
+ data->save_volume = FALSE;
+ }
pa_return_null_if_fail(pa_cvolume_valid(&data->volume));
- pa_return_null_if_fail(data->volume.channels == data->sample_spec.channels);
+ pa_return_null_if_fail(pa_cvolume_compatible(&data->volume, &data->sample_spec));
if (!data->muted_is_set)
data->muted = FALSE;
@@ -167,6 +215,7 @@ pa_source* pa_source_new(
pa_device_init_description(data->proplist);
pa_device_init_icon(data->proplist, FALSE);
+ pa_device_init_intended_roles(data->proplist);
if (pa_hook_fire(&core->hooks[PA_CORE_HOOK_SOURCE_FIXATE], data) < 0) {
pa_xfree(s);
@@ -180,33 +229,59 @@ pa_source* pa_source_new(
s->core = core;
s->state = PA_SOURCE_INIT;
s->flags = flags;
+ s->priority = 0;
+ s->suspend_cause = 0;
s->name = pa_xstrdup(name);
s->proplist = pa_proplist_copy(data->proplist);
s->driver = pa_xstrdup(pa_path_get_filename(data->driver));
s->module = data->module;
s->card = data->card;
+ s->priority = pa_device_init_priority(s->proplist);
+
s->sample_spec = data->sample_spec;
s->channel_map = data->channel_map;
s->outputs = pa_idxset_new(NULL, NULL);
s->n_corked = 0;
s->monitor_of = NULL;
+ s->output_from_master = NULL;
- s->virtual_volume = data->volume;
+ s->reference_volume = s->real_volume = data->volume;
pa_cvolume_reset(&s->soft_volume, s->sample_spec.channels);
s->base_volume = PA_VOLUME_NORM;
s->n_volume_steps = PA_VOLUME_NORM+1;
s->muted = data->muted;
s->refresh_volume = s->refresh_muted = FALSE;
- s->fixed_latency = flags & PA_SOURCE_DYNAMIC_LATENCY ? 0 : DEFAULT_FIXED_LATENCY;
-
reset_callbacks(s);
s->userdata = NULL;
s->asyncmsgq = NULL;
- s->rtpoll = NULL;
+
+ /* As a minor optimization we just steal the list instead of
+ * copying it here */
+ s->ports = data->ports;
+ data->ports = NULL;
+
+ s->active_port = NULL;
+ s->save_port = FALSE;
+
+ if (data->active_port && s->ports)
+ if ((s->active_port = pa_hashmap_get(s->ports, data->active_port)))
+ s->save_port = data->save_port;
+
+ if (!s->active_port && s->ports) {
+ void *state;
+ pa_device_port *p;
+
+ PA_HASHMAP_FOREACH(p, s->ports, state)
+ if (!s->active_port || p->priority > s->active_port->priority)
+ s->active_port = p;
+ }
+
+ s->save_volume = data->save_volume;
+ s->save_muted = data->save_muted;
pa_silence_memchunk_get(
&core->silence_cache,
@@ -215,6 +290,7 @@ pa_source* pa_source_new(
&s->sample_spec,
0);
+ s->thread_info.rtpoll = NULL;
s->thread_info.outputs = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
s->thread_info.soft_volume = s->soft_volume;
s->thread_info.soft_muted = s->muted;
@@ -224,7 +300,15 @@ pa_source* pa_source_new(
s->thread_info.requested_latency = 0;
s->thread_info.min_latency = ABSOLUTE_MIN_LATENCY;
s->thread_info.max_latency = ABSOLUTE_MAX_LATENCY;
+ s->thread_info.fixed_latency = flags & PA_SOURCE_DYNAMIC_LATENCY ? 0 : DEFAULT_FIXED_LATENCY;
+ PA_LLIST_HEAD_INIT(pa_source_volume_change, s->thread_info.volume_changes);
+ s->thread_info.volume_changes_tail = NULL;
+ pa_sw_cvolume_multiply(&s->thread_info.current_hw_volume, &s->soft_volume, &s->real_volume);
+ s->thread_info.volume_change_safety_margin = core->sync_volume_safety_margin_usec;
+ s->thread_info.volume_change_extra_delay = core->sync_volume_extra_delay_usec;
+
+ /* FIXME: This should probably be moved to pa_source_put() */
pa_assert_se(pa_idxset_put(core->sources, s, &s->index) >= 0);
if (s->card)
@@ -249,6 +333,7 @@ static int source_set_state(pa_source *s, pa_source_state_t state) {
pa_source_state_t original_state;
pa_assert(s);
+ pa_assert_ctl_context();
if (s->state == state)
return 0;
@@ -285,42 +370,76 @@ static int source_set_state(pa_source *s, pa_source_state_t state) {
/* We're suspending or resuming, tell everyone about it */
- for (o = PA_SOURCE_OUTPUT(pa_idxset_first(s->outputs, &idx)); o; o = PA_SOURCE_OUTPUT(pa_idxset_next(s->outputs, &idx)))
+ PA_IDXSET_FOREACH(o, s->outputs, idx)
if (s->state == PA_SOURCE_SUSPENDED &&
- (o->flags & PA_SOURCE_OUTPUT_FAIL_ON_SUSPEND))
+ (o->flags & PA_SOURCE_OUTPUT_KILL_ON_SUSPEND))
pa_source_output_kill(o);
else if (o->suspend)
o->suspend(o, state == PA_SOURCE_SUSPENDED);
}
-
return 0;
}
/* Called from main context */
void pa_source_put(pa_source *s) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(s->state == PA_SOURCE_INIT);
+ pa_assert(!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER) || s->output_from_master);
/* The following fields must be initialized properly when calling _put() */
pa_assert(s->asyncmsgq);
- pa_assert(s->rtpoll);
pa_assert(s->thread_info.min_latency <= s->thread_info.max_latency);
- /* Generally, flags should be initialized via pa_source_new(). As
- * a special exception we allow volume related flags to be set
+ /* Generally, flags should be initialized via pa_source_new(). As a
+ * special exception we allow volume related flags to be set
* between _new() and _put(). */
- if (!(s->flags & PA_SOURCE_HW_VOLUME_CTRL))
+ /* XXX: Currently decibel volume is disabled for all sources that use volume
+ * sharing. When the master source supports decibel volume, it would be good
+ * to have the flag also in the filter source, but currently we don't do that
+ * so that the flags of the filter source never change when it's moved from
+ * a master source to another. One solution for this problem would be to
+ * remove user-visible volume altogether from filter sources when volume
+ * sharing is used, but the current approach was easier to implement... */
+ if (!(s->flags & PA_SOURCE_HW_VOLUME_CTRL) && !(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
s->flags |= PA_SOURCE_DECIBEL_VOLUME;
+ if ((s->flags & PA_SOURCE_DECIBEL_VOLUME) && s->core->flat_volumes)
+ s->flags |= PA_SOURCE_FLAT_VOLUME;
+
+ if (s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER) {
+ pa_source *root_source = s->output_from_master->source;
+
+ while (root_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)
+ root_source = root_source->output_from_master->source;
+
+ s->reference_volume = root_source->reference_volume;
+ pa_cvolume_remap(&s->reference_volume, &root_source->channel_map, &s->channel_map);
+
+ s->real_volume = root_source->real_volume;
+ pa_cvolume_remap(&s->real_volume, &root_source->channel_map, &s->channel_map);
+ } else
+ /* We assume that if the sink implementor changed the default
+ * volume he did so in real_volume, because that is the usual
+ * place where he is supposed to place his changes. */
+ s->reference_volume = s->real_volume;
+
s->thread_info.soft_volume = s->soft_volume;
s->thread_info.soft_muted = s->muted;
+ pa_sw_cvolume_multiply(&s->thread_info.current_hw_volume, &s->soft_volume, &s->real_volume);
- pa_assert((s->flags & PA_SOURCE_HW_VOLUME_CTRL) || (s->base_volume == PA_VOLUME_NORM && s->flags & PA_SOURCE_DECIBEL_VOLUME));
+ pa_assert((s->flags & PA_SOURCE_HW_VOLUME_CTRL)
+ || (s->base_volume == PA_VOLUME_NORM
+ && ((s->flags & PA_SOURCE_DECIBEL_VOLUME || (s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)))));
pa_assert(!(s->flags & PA_SOURCE_DECIBEL_VOLUME) || s->n_volume_steps == PA_VOLUME_NORM+1);
- pa_assert(!(s->flags & PA_SOURCE_DYNAMIC_LATENCY) == (s->fixed_latency != 0));
+ pa_assert(!(s->flags & PA_SOURCE_DYNAMIC_LATENCY) == (s->thread_info.fixed_latency != 0));
+ pa_assert(!(s->flags & PA_SOURCE_HW_VOLUME_CTRL) || s->set_volume);
+ pa_assert(!(s->flags & PA_SOURCE_SYNC_VOLUME) || (s->flags & PA_SOURCE_HW_VOLUME_CTRL));
+ pa_assert(!(s->flags & PA_SOURCE_SYNC_VOLUME) || s->write_volume);
+ pa_assert(!(s->flags & PA_SOURCE_HW_MUTE_CTRL) || s->set_mute);
pa_assert_se(source_set_state(s, PA_SOURCE_IDLE) == 0);
@@ -334,6 +453,7 @@ void pa_source_unlink(pa_source *s) {
pa_source_output *o, *j = NULL;
pa_assert(s);
+ pa_assert_ctl_context();
/* See pa_sink_unlink() for a couple of comments how this function
* works. */
@@ -375,6 +495,7 @@ static void source_free(pa_object *o) {
pa_source *s = PA_SOURCE(o);
pa_assert(s);
+ pa_assert_ctl_context();
pa_assert(pa_source_refcnt(s) == 0);
if (PA_SOURCE_IS_LINKED(s->state))
@@ -398,26 +519,52 @@ static void source_free(pa_object *o) {
if (s->proplist)
pa_proplist_free(s->proplist);
+ if (s->ports) {
+ pa_device_port *p;
+
+ while ((p = pa_hashmap_steal_first(s->ports)))
+ pa_device_port_free(p);
+
+ pa_hashmap_free(s->ports, NULL, NULL);
+ }
+
pa_xfree(s);
}
-/* Called from main context */
+/* Called from main context, and not while the IO thread is active, please */
void pa_source_set_asyncmsgq(pa_source *s, pa_asyncmsgq *q) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
s->asyncmsgq = q;
}
-/* Called from main context */
+/* Called from main context, and not while the IO thread is active, please */
+void pa_source_update_flags(pa_source *s, pa_source_flags_t mask, pa_source_flags_t value) {
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+
+ if (mask == 0)
+ return;
+
+ /* For now, allow only a minimal set of flags to be changed. */
+ pa_assert((mask & ~(PA_SOURCE_DYNAMIC_LATENCY|PA_SOURCE_LATENCY)) == 0);
+
+ s->flags = (s->flags & ~mask) | (value & mask);
+}
+
+/* Called from IO context, or before _put() from main context */
void pa_source_set_rtpoll(pa_source *s, pa_rtpoll *p) {
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
- s->rtpoll = p;
+ s->thread_info.rtpoll = p;
}
/* Called from main context */
int pa_source_update_status(pa_source*s) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
if (s->state == PA_SOURCE_SUSPENDED)
@@ -427,14 +574,26 @@ int pa_source_update_status(pa_source*s) {
}
/* Called from main context */
-int pa_source_suspend(pa_source *s, pa_bool_t suspend) {
+int pa_source_suspend(pa_source *s, pa_bool_t suspend, pa_suspend_cause_t cause) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
+ pa_assert(cause != 0);
- if (s->monitor_of)
+ if (s->monitor_of && cause != PA_SUSPEND_PASSTHROUGH)
return -PA_ERR_NOTSUPPORTED;
if (suspend)
+ s->suspend_cause |= cause;
+ else
+ s->suspend_cause &= ~cause;
+
+ if ((pa_source_get_state(s) == PA_SOURCE_SUSPENDED) == !!s->suspend_cause)
+ return 0;
+
+ pa_log_debug("Suspend cause of source %s is 0x%04x, %s", s->name, s->suspend_cause, s->suspend_cause ? "suspending" : "resuming");
+
+ if (s->suspend_cause)
return source_set_state(s, PA_SOURCE_SUSPENDED);
else
return source_set_state(s, pa_source_used_by(s) ? PA_SOURCE_RUNNING : PA_SOURCE_IDLE);
@@ -445,6 +604,7 @@ int pa_source_sync_suspend(pa_source *s) {
pa_sink_state_t state;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
pa_assert(s->monitor_of);
@@ -459,15 +619,16 @@ int pa_source_sync_suspend(pa_source *s) {
}
/* Called from main context */
-pa_queue *pa_source_move_all_start(pa_source *s) {
- pa_queue *q;
+pa_queue *pa_source_move_all_start(pa_source *s, pa_queue *q) {
pa_source_output *o, *n;
uint32_t idx;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
- q = pa_queue_new();
+ if (!q)
+ q = pa_queue_new();
for (o = PA_SOURCE_OUTPUT(pa_idxset_first(s->outputs, &idx)); o; o = n) {
n = PA_SOURCE_OUTPUT(pa_idxset_next(s->outputs, &idx));
@@ -488,12 +649,13 @@ void pa_source_move_all_finish(pa_source *s, pa_queue *q, pa_bool_t save) {
pa_source_output *o;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
pa_assert(q);
while ((o = PA_SOURCE_OUTPUT(pa_queue_pop(q)))) {
if (pa_source_output_finish_move(o, s, save) < 0)
- pa_source_output_kill(o);
+ pa_source_output_fail_move(o);
pa_source_output_unref(o);
}
@@ -504,13 +666,13 @@ void pa_source_move_all_finish(pa_source *s, pa_queue *q, pa_bool_t save) {
/* Called from main context */
void pa_source_move_all_fail(pa_queue *q) {
pa_source_output *o;
+
+ pa_assert_ctl_context();
pa_assert(q);
while ((o = PA_SOURCE_OUTPUT(pa_queue_pop(q)))) {
- if (pa_hook_fire(&o->core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_MOVE_FAIL], o) == PA_HOOK_OK) {
- pa_source_output_kill(o);
- pa_source_output_unref(o);
- }
+ pa_source_output_fail_move(o);
+ pa_source_output_unref(o);
}
pa_queue_free(q, NULL, NULL);
@@ -522,17 +684,18 @@ void pa_source_process_rewind(pa_source *s, size_t nbytes) {
void *state = NULL;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
pa_assert(PA_SOURCE_IS_LINKED(s->thread_info.state));
- if (s->thread_info.state == PA_SOURCE_SUSPENDED)
+ if (nbytes <= 0)
return;
- if (nbytes <= 0)
+ if (s->thread_info.state == PA_SOURCE_SUSPENDED)
return;
pa_log_debug("Processing rewind...");
- while ((o = pa_hashmap_iterate(s->thread_info.outputs, &state, NULL))) {
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state) {
pa_source_output_assert_ref(o);
pa_source_output_process_rewind(o, nbytes);
}
@@ -544,6 +707,7 @@ void pa_source_post(pa_source*s, const pa_memchunk *chunk) {
void *state = NULL;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
pa_assert(PA_SOURCE_IS_LINKED(s->thread_info.state));
pa_assert(chunk);
@@ -583,6 +747,7 @@ void pa_source_post(pa_source*s, const pa_memchunk *chunk) {
/* Called from IO thread context */
void pa_source_post_direct(pa_source*s, pa_source_output *o, const pa_memchunk *chunk) {
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
pa_assert(PA_SOURCE_IS_LINKED(s->thread_info.state));
pa_source_output_assert_ref(o);
pa_assert(o->thread_info.direct_on_input);
@@ -614,6 +779,7 @@ pa_usec_t pa_source_get_latency(pa_source *s) {
pa_usec_t usec;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
if (s->state == PA_SOURCE_SUSPENDED)
@@ -633,6 +799,7 @@ pa_usec_t pa_source_get_latency_within_thread(pa_source *s) {
pa_msgobject *o;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
pa_assert(PA_SOURCE_IS_LINKED(s->thread_info.state));
/* The returned value is supposed to be in the time domain of the sound card! */
@@ -645,7 +812,7 @@ pa_usec_t pa_source_get_latency_within_thread(pa_source *s) {
o = PA_MSGOBJECT(s);
- /* We probably should make this a proper vtable callback instead of going through process_msg() */
+ /* FIXME: We probably should make this a proper vtable callback instead of going through process_msg() */
if (o->process_msg(o, PA_SOURCE_MESSAGE_GET_LATENCY, &usec, 0, NULL) < 0)
return -1;
@@ -653,88 +820,648 @@ pa_usec_t pa_source_get_latency_within_thread(pa_source *s) {
return usec;
}
-/* Called from main thread */
-void pa_source_set_volume(pa_source *s, const pa_cvolume *volume) {
- pa_cvolume old_virtual_volume;
- pa_bool_t virtual_volume_changed;
+/* Called from the main thread (and also from the IO thread while the main
+ * thread is waiting).
+ *
+ * When a source uses volume sharing, it never has the PA_SOURCE_FLAT_VOLUME flag
+ * set. Instead, flat volume mode is detected by checking whether the root source
+ * has the flag set. */
+pa_bool_t pa_source_flat_volume_enabled(pa_source *s) {
+ pa_source_assert_ref(s);
+
+ while (s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)
+ s = s->output_from_master->source;
+
+ return (s->flags & PA_SOURCE_FLAT_VOLUME);
+}
+
+/* Called from main context */
+pa_bool_t pa_source_is_passthrough(pa_source *s) {
pa_source_assert_ref(s);
+
+ /* NB Currently only monitor sources support passthrough mode */
+ return (s->monitor_of && pa_sink_is_passthrough(s->monitor_of));
+}
+
+/* Called from main context. */
+static void compute_reference_ratio(pa_source_output *o) {
+ unsigned c = 0;
+ pa_cvolume remapped;
+
+ pa_assert(o);
+ pa_assert(pa_source_flat_volume_enabled(o->source));
+
+ /*
+ * Calculates the reference ratio from the source's reference
+ * volume. This basically calculates:
+ *
+ * o->reference_ratio = o->volume / o->source->reference_volume
+ */
+
+ remapped = o->source->reference_volume;
+ pa_cvolume_remap(&remapped, &o->source->channel_map, &o->channel_map);
+
+ o->reference_ratio.channels = o->sample_spec.channels;
+
+ for (c = 0; c < o->sample_spec.channels; c++) {
+
+ /* We don't update when the source volume is 0 anyway */
+ if (remapped.values[c] <= PA_VOLUME_MUTED)
+ continue;
+
+ /* Don't update the reference ratio unless necessary */
+ if (pa_sw_volume_multiply(
+ o->reference_ratio.values[c],
+ remapped.values[c]) == o->volume.values[c])
+ continue;
+
+ o->reference_ratio.values[c] = pa_sw_volume_divide(
+ o->volume.values[c],
+ remapped.values[c]);
+ }
+}
+
+/* Called from main context. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. */
+static void compute_reference_ratios(pa_source *s) {
+ uint32_t idx;
+ pa_source_output *o;
+
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
- pa_assert(volume);
- pa_assert(pa_cvolume_valid(volume));
- pa_assert(pa_cvolume_compatible(volume, &s->sample_spec));
+ pa_assert(pa_source_flat_volume_enabled(s));
- old_virtual_volume = s->virtual_volume;
- s->virtual_volume = *volume;
- virtual_volume_changed = !pa_cvolume_equal(&old_virtual_volume, &s->virtual_volume);
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ compute_reference_ratio(o);
- if (s->set_volume) {
- pa_cvolume_reset(&s->soft_volume, s->sample_spec.channels);
- s->set_volume(s);
- } else
- s->soft_volume = s->virtual_volume;
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
+ compute_reference_ratios(o->destination_source);
+ }
+}
+
+/* Called from main context. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. */
+static void compute_real_ratios(pa_source *s) {
+ pa_source_output *o;
+ uint32_t idx;
+
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
+ pa_assert(pa_source_flat_volume_enabled(s));
+
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ unsigned c;
+ pa_cvolume remapped;
+
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)) {
+ /* The origin source uses volume sharing, so this input's real ratio
+ * is handled as a special case - the real ratio must be 0 dB, and
+ * as a result i->soft_volume must equal i->volume_factor. */
+ pa_cvolume_reset(&o->real_ratio, o->real_ratio.channels);
+ o->soft_volume = o->volume_factor;
+
+ compute_real_ratios(o->destination_source);
+
+ continue;
+ }
+
+ /*
+ * This basically calculates:
+ *
+ * i->real_ratio := i->volume / s->real_volume
+ * i->soft_volume := i->real_ratio * i->volume_factor
+ */
+
+ remapped = s->real_volume;
+ pa_cvolume_remap(&remapped, &s->channel_map, &o->channel_map);
+
+ o->real_ratio.channels = o->sample_spec.channels;
+ o->soft_volume.channels = o->sample_spec.channels;
+
+ for (c = 0; c < o->sample_spec.channels; c++) {
+
+ if (remapped.values[c] <= PA_VOLUME_MUTED) {
+ /* We leave o->real_ratio untouched */
+ o->soft_volume.values[c] = PA_VOLUME_MUTED;
+ continue;
+ }
+
+ /* Don't lose accuracy unless necessary */
+ if (pa_sw_volume_multiply(
+ o->real_ratio.values[c],
+ remapped.values[c]) != o->volume.values[c])
+
+ o->real_ratio.values[c] = pa_sw_volume_divide(
+ o->volume.values[c],
+ remapped.values[c]);
+
+ o->soft_volume.values[c] = pa_sw_volume_multiply(
+ o->real_ratio.values[c],
+ o->volume_factor.values[c]);
+ }
+
+ /* We don't copy the soft_volume to the thread_info data
+ * here. That must be done by the caller */
+ }
+}
+
+static pa_cvolume *cvolume_remap_minimal_impact(
+ pa_cvolume *v,
+ const pa_cvolume *template,
+ const pa_channel_map *from,
+ const pa_channel_map *to) {
+
+ pa_cvolume t;
+
+ pa_assert(v);
+ pa_assert(template);
+ pa_assert(from);
+ pa_assert(to);
+ pa_assert(pa_cvolume_compatible_with_channel_map(v, from));
+ pa_assert(pa_cvolume_compatible_with_channel_map(template, to));
+
+ /* Much like pa_cvolume_remap(), but tries to minimize impact when
+ * mapping from source output to source volumes:
+ *
+ * If template is a possible remapping from v it is used instead
+ * of remapping anew.
+ *
+ * If the channel maps don't match we set an all-channel volume on
+ * the source to ensure that changing a volume on one stream has no
+ * effect that cannot be compensated for in another stream that
+ * does not have the same channel map as the source. */
+
+ if (pa_channel_map_equal(from, to))
+ return v;
+
+ t = *template;
+ if (pa_cvolume_equal(pa_cvolume_remap(&t, to, from), v)) {
+ *v = *template;
+ return v;
+ }
+
+ pa_cvolume_set(v, to->channels, pa_cvolume_max(v));
+ return v;
+}
+
+/* Called from main thread. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. */
+static void get_maximum_output_volume(pa_source *s, pa_cvolume *max_volume, const pa_channel_map *channel_map) {
+ pa_source_output *o;
+ uint32_t idx;
+
+ pa_source_assert_ref(s);
+ pa_assert(max_volume);
+ pa_assert(channel_map);
+ pa_assert(pa_source_flat_volume_enabled(s));
+
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ pa_cvolume remapped;
+
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)) {
+ get_maximum_output_volume(o->destination_source, max_volume, channel_map);
+
+ /* Ignore this output. The origin source uses volume sharing, so this
+ * output's volume will be set to be equal to the root source's real
+ * volume. Obviously this outputs's current volume must not then
+ * affect what the root source's real volume will be. */
+ continue;
+ }
+
+ remapped = o->volume;
+ cvolume_remap_minimal_impact(&remapped, max_volume, &o->channel_map, channel_map);
+ pa_cvolume_merge(max_volume, max_volume, &remapped);
+ }
+}
+
+/* Called from main thread. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. */
+static pa_bool_t has_outputs(pa_source *s) {
+ pa_source_output *o;
+ uint32_t idx;
+
+ pa_source_assert_ref(s);
+
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ if (!o->destination_source || !(o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER) || has_outputs(o->destination_source))
+ return TRUE;
+ }
+
+ return FALSE;
+}
+
+/* Called from main thread. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. */
+static void update_real_volume(pa_source *s, const pa_cvolume *new_volume, pa_channel_map *channel_map) {
+ pa_source_output *o;
+ uint32_t idx;
+
+ pa_source_assert_ref(s);
+ pa_assert(new_volume);
+ pa_assert(channel_map);
+
+ s->real_volume = *new_volume;
+ pa_cvolume_remap(&s->real_volume, channel_map, &s->channel_map);
+
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)) {
+ if (pa_source_flat_volume_enabled(s)) {
+ pa_cvolume old_volume = o->volume;
+
+ /* Follow the root source's real volume. */
+ o->volume = *new_volume;
+ pa_cvolume_remap(&o->volume, channel_map, &o->channel_map);
+ compute_reference_ratio(o);
+
+ /* The volume changed, let's tell people so */
+ if (!pa_cvolume_equal(&old_volume, &o->volume)) {
+ if (o->volume_changed)
+ o->volume_changed(o);
+
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+ }
+ }
+
+ update_real_volume(o->destination_source, new_volume, channel_map);
+ }
+ }
+}
+
+/* Called from main thread. Only called for the root source in shared volume
+ * cases. */
+static void compute_real_volume(pa_source *s) {
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
+ pa_assert(pa_source_flat_volume_enabled(s));
+ pa_assert(!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER));
+
+ /* This determines the maximum volume of all streams and sets
+ * s->real_volume accordingly. */
+
+ if (!has_outputs(s)) {
+ /* In the special case that we have no source outputs we leave the
+ * volume unmodified. */
+ update_real_volume(s, &s->reference_volume, &s->channel_map);
+ return;
+ }
+
+ pa_cvolume_mute(&s->real_volume, s->channel_map.channels);
+
+ /* First let's determine the new maximum volume of all outputs
+ * connected to this source */
+ get_maximum_output_volume(s, &s->real_volume, &s->channel_map);
+ update_real_volume(s, &s->real_volume, &s->channel_map);
+
+ /* Then, let's update the real ratios/soft volumes of all outputs
+ * connected to this source */
+ compute_real_ratios(s);
+}
+
+/* Called from main thread. Only called for the root source in shared volume
+ * cases, except for internal recursive calls. */
+static void propagate_reference_volume(pa_source *s) {
+ pa_source_output *o;
+ uint32_t idx;
+
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
+ pa_assert(pa_source_flat_volume_enabled(s));
+
+ /* This is called whenever the source volume changes that is not
+ * caused by a source output volume change. We need to fix up the
+ * source output volumes accordingly */
+
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ pa_cvolume old_volume;
+
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)) {
+ propagate_reference_volume(o->destination_source);
- pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_VOLUME, NULL, 0, NULL) == 0);
+ /* Since the origin source uses volume sharing, this output's volume
+ * needs to be updated to match the root source's real volume, but
+ * that will be done later in update_shared_real_volume(). */
+ continue;
+ }
+
+ old_volume = o->volume;
+
+ /* This basically calculates:
+ *
+ * o->volume := o->reference_volume * o->reference_ratio */
+
+ o->volume = s->reference_volume;
+ pa_cvolume_remap(&o->volume, &s->channel_map, &o->channel_map);
+ pa_sw_cvolume_multiply(&o->volume, &o->volume, &o->reference_ratio);
+
+ /* The volume changed, let's tell people so */
+ if (!pa_cvolume_equal(&old_volume, &o->volume)) {
+
+ if (o->volume_changed)
+ o->volume_changed(o);
+
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+ }
+ }
+}
+
+/* Called from main thread. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. The return value indicates
+ * whether any reference volume actually changed. */
+static pa_bool_t update_reference_volume(pa_source *s, const pa_cvolume *v, const pa_channel_map *channel_map, pa_bool_t save) {
+ pa_cvolume volume;
+ pa_bool_t reference_volume_changed;
+ pa_source_output *o;
+ uint32_t idx;
- if (virtual_volume_changed)
+ pa_source_assert_ref(s);
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
+ pa_assert(v);
+ pa_assert(channel_map);
+ pa_assert(pa_cvolume_valid(v));
+
+ volume = *v;
+ pa_cvolume_remap(&volume, channel_map, &s->channel_map);
+
+ reference_volume_changed = !pa_cvolume_equal(&volume, &s->reference_volume);
+ s->reference_volume = volume;
+
+ s->save_volume = (!reference_volume_changed && s->save_volume) || save;
+
+ if (reference_volume_changed)
pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+ else if (!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
+ /* If the root source's volume doesn't change, then there can't be any
+ * changes in the other source in the source tree either.
+ *
+ * It's probably theoretically possible that even if the root source's
+ * volume changes slightly, some filter source doesn't change its volume
+ * due to rounding errors. If that happens, we still want to propagate
+ * the changed root source volume to the sources connected to the
+ * intermediate source that didn't change its volume. This theoretical
+ * possiblity is the reason why we have that !(s->flags &
+ * PA_SOURCE_SHARE_VOLUME_WITH_MASTER) condition. Probably nobody would
+ * notice even if we returned here FALSE always if
+ * reference_volume_changed is FALSE. */
+ return FALSE;
+
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
+ update_reference_volume(o->destination_source, v, channel_map, FALSE);
+ }
+
+ return TRUE;
+}
+
+/* Called from main thread */
+void pa_source_set_volume(
+ pa_source *s,
+ const pa_cvolume *volume,
+ pa_bool_t send_msg,
+ pa_bool_t save) {
+
+ pa_cvolume new_reference_volume;
+ pa_source *root_source = s;
+
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
+ pa_assert(!volume || pa_cvolume_valid(volume));
+ pa_assert(volume || pa_source_flat_volume_enabled(s));
+ pa_assert(!volume || volume->channels == 1 || pa_cvolume_compatible(volume, &s->sample_spec));
+
+ /* make sure we don't change the volume when a PASSTHROUGH output is connected */
+ if (pa_source_is_passthrough(s)) {
+ /* FIXME: Need to notify client that volume control is disabled */
+ pa_log_warn("Cannot change volume, Source is monitor of a PASSTHROUGH sink");
+ return;
+ }
+
+ /* In case of volume sharing, the volume is set for the root source first,
+ * from which it's then propagated to the sharing sources. */
+ while (root_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)
+ root_source = root_source->output_from_master->source;
+
+ /* As a special exception we accept mono volumes on all sources --
+ * even on those with more complex channel maps */
+
+ if (volume) {
+ if (pa_cvolume_compatible(volume, &s->sample_spec))
+ new_reference_volume = *volume;
+ else {
+ new_reference_volume = s->reference_volume;
+ pa_cvolume_scale(&new_reference_volume, pa_cvolume_max(volume));
+ }
+
+ pa_cvolume_remap(&new_reference_volume, &s->channel_map, &root_source->channel_map);
+ }
+
+ /* If volume is NULL we synchronize the source's real and reference
+ * volumes with the stream volumes. If it is not NULL we update
+ * the reference_volume with it. */
+
+ if (volume) {
+ if (update_reference_volume(root_source, &new_reference_volume, &root_source->channel_map, save)) {
+ if (pa_source_flat_volume_enabled(root_source)) {
+ /* OK, propagate this volume change back to the outputs */
+ propagate_reference_volume(root_source);
+
+ /* And now recalculate the real volume */
+ compute_real_volume(root_source);
+ } else
+ update_real_volume(root_source, &root_source->reference_volume, &root_source->channel_map);
+ }
+
+ } else {
+ pa_assert(pa_source_flat_volume_enabled(root_source));
+
+ /* Ok, let's determine the new real volume */
+ compute_real_volume(root_source);
+
+ /* Let's 'push' the reference volume if necessary */
+ pa_cvolume_merge(&new_reference_volume, &s->reference_volume, &root_source->real_volume);
+ update_reference_volume(root_source, &new_reference_volume, &root_source->channel_map, save);
+
+ /* Now that the reference volume is updated, we can update the streams'
+ * reference ratios. */
+ compute_reference_ratios(root_source);
+ }
+
+ if (root_source->set_volume) {
+ /* If we have a function set_volume(), then we do not apply a
+ * soft volume by default. However, set_volume() is free to
+ * apply one to root_source->soft_volume */
+
+ pa_cvolume_reset(&root_source->soft_volume, root_source->sample_spec.channels);
+ if (!(root_source->flags & PA_SOURCE_SYNC_VOLUME))
+ root_source->set_volume(root_source);
+
+ } else
+ /* If we have no function set_volume(), then the soft volume
+ * becomes the real volume */
+ root_source->soft_volume = root_source->real_volume;
+
+ /* This tells the source that soft volume and/or real volume changed */
+ if (send_msg)
+ pa_assert_se(pa_asyncmsgq_send(root_source->asyncmsgq, PA_MSGOBJECT(root_source), PA_SOURCE_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL) == 0);
}
-/* Called from main thread. Only to be called by source implementor */
+/* Called from the io thread if sync volume is used, otherwise from the main thread.
+ * Only to be called by source implementor */
void pa_source_set_soft_volume(pa_source *s, const pa_cvolume *volume) {
+
pa_source_assert_ref(s);
- pa_assert(volume);
+ pa_assert(!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER));
- if (PA_SOURCE_IS_LINKED(s->state))
+ if (s->flags & PA_SOURCE_SYNC_VOLUME)
+ pa_source_assert_io_context(s);
+ else
+ pa_assert_ctl_context();
+
+ if (!volume)
+ pa_cvolume_reset(&s->soft_volume, s->sample_spec.channels);
+ else
+ s->soft_volume = *volume;
+
+ if (PA_SOURCE_IS_LINKED(s->state) && !(s->flags & PA_SOURCE_SYNC_VOLUME))
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_VOLUME, NULL, 0, NULL) == 0);
else
- s->thread_info.soft_volume = *volume;
+ s->thread_info.soft_volume = s->soft_volume;
+}
+
+/* Called from the main thread. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. */
+static void propagate_real_volume(pa_source *s, const pa_cvolume *old_real_volume) {
+ pa_source_output *o;
+ uint32_t idx;
+
+ pa_source_assert_ref(s);
+ pa_assert(old_real_volume);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
+
+ /* This is called when the hardware's real volume changes due to
+ * some external event. We copy the real volume into our
+ * reference volume and then rebuild the stream volumes based on
+ * i->real_ratio which should stay fixed. */
+
+ if (!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)) {
+ if (pa_cvolume_equal(old_real_volume, &s->real_volume))
+ return;
+
+ /* 1. Make the real volume the reference volume */
+ update_reference_volume(s, &s->real_volume, &s->channel_map, TRUE);
+ }
+
+ if (pa_source_flat_volume_enabled(s)) {
+
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
+ pa_cvolume old_volume = o->volume;
+
+ /* 2. Since the source's reference and real volumes are equal
+ * now our ratios should be too. */
+ o->reference_ratio = o->real_ratio;
+
+ /* 3. Recalculate the new stream reference volume based on the
+ * reference ratio and the sink's reference volume.
+ *
+ * This basically calculates:
+ *
+ * o->volume = s->reference_volume * o->reference_ratio
+ *
+ * This is identical to propagate_reference_volume() */
+ o->volume = s->reference_volume;
+ pa_cvolume_remap(&o->volume, &s->channel_map, &o->channel_map);
+ pa_sw_cvolume_multiply(&o->volume, &o->volume, &o->reference_ratio);
+
+ /* Notify if something changed */
+ if (!pa_cvolume_equal(&old_volume, &o->volume)) {
+
+ if (o->volume_changed)
+ o->volume_changed(o);
+
+ pa_subscription_post(o->core, PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT|PA_SUBSCRIPTION_EVENT_CHANGE, o->index);
+ }
+
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
+ propagate_real_volume(o->destination_source, old_real_volume);
+ }
+ }
+
+ /* Something got changed in the hardware. It probably makes sense
+ * to save changed hw settings given that hw volume changes not
+ * triggered by PA are almost certainly done by the user. */
+ if (!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
+ s->save_volume = TRUE;
+}
+
+/* Called from io thread */
+void pa_source_update_volume_and_mute(pa_source *s) {
+ pa_assert(s);
+ pa_source_assert_io_context(s);
+
+ pa_asyncmsgq_post(pa_thread_mq_get()->outq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_UPDATE_VOLUME_AND_MUTE, NULL, 0, NULL, NULL);
}
/* Called from main thread */
const pa_cvolume *pa_source_get_volume(pa_source *s, pa_bool_t force_refresh) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
if (s->refresh_volume || force_refresh) {
- pa_cvolume old_virtual_volume = s->virtual_volume;
+ struct pa_cvolume old_real_volume;
+
+ pa_assert(!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER));
- if (s->get_volume)
+ old_real_volume = s->real_volume;
+
+ if (!(s->flags & PA_SOURCE_SYNC_VOLUME) && s->get_volume)
s->get_volume(s);
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_GET_VOLUME, NULL, 0, NULL) == 0);
- if (!pa_cvolume_equal(&old_virtual_volume, &s->virtual_volume))
- pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+ update_real_volume(s, &s->real_volume, &s->channel_map);
+ propagate_real_volume(s, &old_real_volume);
}
- return &s->virtual_volume;
+ return &s->reference_volume;
}
-/* Called from main thread */
-void pa_source_volume_changed(pa_source *s, const pa_cvolume *new_volume) {
+/* Called from main thread. In volume sharing cases, only the root source may
+ * call this. */
+void pa_source_volume_changed(pa_source *s, const pa_cvolume *new_real_volume) {
+ pa_cvolume old_real_volume;
+
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
+ pa_assert(!(s->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER));
/* The source implementor may call this if the volume changed to make sure everyone is notified */
- if (pa_cvolume_equal(&s->virtual_volume, new_volume))
- return;
-
- s->virtual_volume = *new_volume;
- pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+ old_real_volume = s->real_volume;
+ update_real_volume(s, new_real_volume, &s->channel_map);
+ propagate_real_volume(s, &old_real_volume);
}
/* Called from main thread */
-void pa_source_set_mute(pa_source *s, pa_bool_t mute) {
+void pa_source_set_mute(pa_source *s, pa_bool_t mute, pa_bool_t save) {
pa_bool_t old_muted;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
old_muted = s->muted;
s->muted = mute;
+ s->save_muted = (old_muted == s->muted && s->save_muted) || save;
- if (s->set_mute)
+ if (!(s->flags & PA_SOURCE_SYNC_VOLUME) && s->set_mute)
s->set_mute(s);
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_MUTE, NULL, 0, NULL) == 0);
@@ -745,19 +1472,27 @@ void pa_source_set_mute(pa_source *s, pa_bool_t mute) {
/* Called from main thread */
pa_bool_t pa_source_get_mute(pa_source *s, pa_bool_t force_refresh) {
+
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
if (s->refresh_muted || force_refresh) {
pa_bool_t old_muted = s->muted;
- if (s->get_mute)
+ if (!(s->flags & PA_SOURCE_SYNC_VOLUME) && s->get_mute)
s->get_mute(s);
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_GET_MUTE, NULL, 0, NULL) == 0);
- if (old_muted != s->muted)
+ if (old_muted != s->muted) {
+ s->save_muted = TRUE;
+
pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+
+ /* Make sure the soft mute status stays in sync */
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_MUTE, NULL, 0, NULL) == 0);
+ }
}
return s->muted;
@@ -766,6 +1501,8 @@ pa_bool_t pa_source_get_mute(pa_source *s, pa_bool_t force_refresh) {
/* Called from main thread */
void pa_source_mute_changed(pa_source *s, pa_bool_t new_muted) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(PA_SOURCE_IS_LINKED(s->state));
/* The source implementor may call this if the mute state changed to make sure everyone is notified */
@@ -773,12 +1510,15 @@ void pa_source_mute_changed(pa_source *s, pa_bool_t new_muted) {
return;
s->muted = new_muted;
+ s->save_muted = TRUE;
+
pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
}
/* Called from main thread */
pa_bool_t pa_source_update_proplist(pa_source *s, pa_update_mode_t mode, pa_proplist *p) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
if (p)
pa_proplist_update(s->proplist, mode, p);
@@ -792,16 +1532,18 @@ pa_bool_t pa_source_update_proplist(pa_source *s, pa_update_mode_t mode, pa_prop
}
/* Called from main thread */
+/* FIXME -- this should be dropped and be merged into pa_source_update_proplist() */
void pa_source_set_description(pa_source *s, const char *description) {
const char *old;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
if (!description && !pa_proplist_contains(s->proplist, PA_PROP_DEVICE_DESCRIPTION))
return;
old = pa_proplist_gets(s->proplist, PA_PROP_DEVICE_DESCRIPTION);
- if (old && description && !strcmp(old, description))
+ if (old && description && pa_streq(old, description))
return;
if (description)
@@ -818,6 +1560,7 @@ void pa_source_set_description(pa_source *s, const char *description) {
/* Called from main thread */
unsigned pa_source_linked_by(pa_source *s) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
return pa_idxset_size(s->outputs);
@@ -828,6 +1571,7 @@ unsigned pa_source_used_by(pa_source *s) {
unsigned ret;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
ret = pa_idxset_size(s->outputs);
@@ -843,17 +1587,25 @@ unsigned pa_source_check_suspend(pa_source *s) {
uint32_t idx;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
if (!PA_SOURCE_IS_LINKED(s->state))
return 0;
ret = 0;
- for (o = PA_SOURCE_OUTPUT(pa_idxset_first(s->outputs, &idx)); o; o = PA_SOURCE_OUTPUT(pa_idxset_next(s->outputs, &idx))) {
+ PA_IDXSET_FOREACH(o, s->outputs, idx) {
pa_source_output_state_t st;
st = pa_source_output_get_state(o);
- pa_assert(PA_SOURCE_OUTPUT_IS_LINKED(st));
+
+ /* We do not assert here. It is perfectly valid for a source output to
+ * be in the INIT state (i.e. created, marked done but not yet put)
+ * and we should not care if it's unlinked as it won't contribute
+ * towarards our busy status.
+ */
+ if (!PA_SOURCE_OUTPUT_IS_LINKED(st))
+ continue;
if (st == PA_SOURCE_OUTPUT_CORKED)
continue;
@@ -867,6 +1619,39 @@ unsigned pa_source_check_suspend(pa_source *s) {
return ret;
}
+/* Called from the IO thread */
+static void sync_output_volumes_within_thread(pa_source *s) {
+ pa_source_output *o;
+ void *state = NULL;
+
+ pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
+
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state) {
+ if (pa_cvolume_equal(&o->thread_info.soft_volume, &o->soft_volume))
+ continue;
+
+ o->thread_info.soft_volume = o->soft_volume;
+ //pa_source_output_request_rewind(o, 0, TRUE, FALSE, FALSE);
+ }
+}
+
+/* Called from the IO thread. Only called for the root source in volume sharing
+ * cases, except for internal recursive calls. */
+static void set_shared_volume_within_thread(pa_source *s) {
+ pa_source_output *o;
+ void *state = NULL;
+
+ pa_source_assert_ref(s);
+
+ PA_MSGOBJECT(s)->process_msg(PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_VOLUME_SYNCED, NULL, 0, NULL);
+
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state) {
+ if (o->destination_source && (o->destination_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER))
+ set_shared_volume_within_thread(o->destination_source);
+ }
+}
+
/* Called from IO thread, except when it is not */
int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_t offset, pa_memchunk *chunk) {
pa_source *s = PA_SOURCE(object);
@@ -902,7 +1687,9 @@ int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_
* requested latency. */
pa_source_output_set_requested_latency_within_thread(o, o->thread_info.requested_source_latency);
- return 0;
+ /* In flat volume mode we need to update the volume as
+ * well */
+ return object->process_msg(object, PA_SOURCE_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL);
}
case PA_SOURCE_MESSAGE_REMOVE_OUTPUT: {
@@ -924,23 +1711,74 @@ int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_
if (pa_hashmap_remove(s->thread_info.outputs, PA_UINT32_TO_PTR(o->index)))
pa_source_output_unref(o);
- pa_source_invalidate_requested_latency(s);
+ pa_source_invalidate_requested_latency(s, TRUE);
+ /* In flat volume mode we need to update the volume as
+ * well */
+ return object->process_msg(object, PA_SOURCE_MESSAGE_SET_SHARED_VOLUME, NULL, 0, NULL);
+ }
+
+ case PA_SOURCE_MESSAGE_SET_SHARED_VOLUME: {
+ pa_source *root_source = s;
+
+ while (root_source->flags & PA_SOURCE_SHARE_VOLUME_WITH_MASTER)
+ root_source = root_source->output_from_master->source;
+
+ set_shared_volume_within_thread(root_source);
return 0;
}
+ case PA_SOURCE_MESSAGE_SET_VOLUME_SYNCED:
+
+ if (s->flags & PA_SOURCE_SYNC_VOLUME) {
+ s->set_volume(s);
+ pa_source_volume_change_push(s);
+ }
+ /* Fall through ... */
+
case PA_SOURCE_MESSAGE_SET_VOLUME:
- s->thread_info.soft_volume = s->soft_volume;
+
+ if (!pa_cvolume_equal(&s->thread_info.soft_volume, &s->soft_volume)) {
+ s->thread_info.soft_volume = s->soft_volume;
+ }
+
+ /* Fall through ... */
+
+ case PA_SOURCE_MESSAGE_SYNC_VOLUMES:
+ sync_output_volumes_within_thread(s);
return 0;
case PA_SOURCE_MESSAGE_GET_VOLUME:
+
+ if ((s->flags & PA_SOURCE_SYNC_VOLUME) && s->get_volume) {
+ s->get_volume(s);
+ pa_source_volume_change_flush(s);
+ pa_sw_cvolume_divide(&s->thread_info.current_hw_volume, &s->real_volume, &s->soft_volume);
+ }
+
+ /* In case source implementor reset SW volume. */
+ if (!pa_cvolume_equal(&s->thread_info.soft_volume, &s->soft_volume)) {
+ s->thread_info.soft_volume = s->soft_volume;
+ }
+
return 0;
case PA_SOURCE_MESSAGE_SET_MUTE:
- s->thread_info.soft_muted = s->muted;
+
+ if (s->thread_info.soft_muted != s->muted) {
+ s->thread_info.soft_muted = s->muted;
+ }
+
+ if (s->flags & PA_SOURCE_SYNC_VOLUME && s->set_mute)
+ s->set_mute(s);
+
return 0;
case PA_SOURCE_MESSAGE_GET_MUTE:
+
+ if (s->flags & PA_SOURCE_SYNC_VOLUME && s->get_mute)
+ s->get_mute(s);
+
return 0;
case PA_SOURCE_MESSAGE_SET_STATE: {
@@ -960,7 +1798,6 @@ int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_
o->suspend_within_thread(o, s->thread_info.state == PA_SOURCE_SUSPENDED);
}
-
return 0;
}
@@ -981,6 +1818,9 @@ int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_
pa_usec_t *usec = userdata;
*usec = pa_source_get_requested_latency_within_thread(s);
+ /* Yes, that's right, the IO thread will see -1 when no
+ * explicit requested latency is configured, the main
+ * thread will see max_latency */
if (*usec == (pa_usec_t) -1)
*usec = s->thread_info.max_latency;
@@ -1004,6 +1844,16 @@ int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_
return 0;
}
+ case PA_SOURCE_MESSAGE_GET_FIXED_LATENCY:
+
+ *((pa_usec_t*) userdata) = s->thread_info.fixed_latency;
+ return 0;
+
+ case PA_SOURCE_MESSAGE_SET_FIXED_LATENCY:
+
+ pa_source_set_fixed_latency_within_thread(s, (pa_usec_t) offset);
+ return 0;
+
case PA_SOURCE_MESSAGE_GET_MAX_REWIND:
*((size_t*) userdata) = s->thread_info.max_rewind;
@@ -1024,6 +1874,23 @@ int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_
/* Implementors need to overwrite this implementation! */
return -1;
+ case PA_SOURCE_MESSAGE_SET_PORT:
+
+ pa_assert(userdata);
+ if (s->set_port) {
+ struct source_message_set_port *msg_data = userdata;
+ msg_data->ret = s->set_port(s, msg_data->port);
+ }
+ return 0;
+
+ case PA_SOURCE_MESSAGE_UPDATE_VOLUME_AND_MUTE:
+ /* This message is sent from IO-thread and handled in main thread. */
+ pa_assert_ctl_context();
+
+ pa_source_get_volume(s, TRUE);
+ pa_source_get_mute(s, TRUE);
+ return 0;
+
case PA_SOURCE_MESSAGE_MAX:
;
}
@@ -1032,12 +1899,14 @@ int pa_source_process_msg(pa_msgobject *object, int code, void *userdata, int64_
}
/* Called from main thread */
-int pa_source_suspend_all(pa_core *c, pa_bool_t suspend) {
- uint32_t idx;
+int pa_source_suspend_all(pa_core *c, pa_bool_t suspend, pa_suspend_cause_t cause) {
pa_source *source;
+ uint32_t idx;
int ret = 0;
pa_core_assert_ref(c);
+ pa_assert_ctl_context();
+ pa_assert(cause != 0);
for (source = PA_SOURCE(pa_idxset_first(c->sources, &idx)); source; source = PA_SOURCE(pa_idxset_next(c->sources, &idx))) {
int r;
@@ -1045,7 +1914,7 @@ int pa_source_suspend_all(pa_core *c, pa_bool_t suspend) {
if (source->monitor_of)
continue;
- if ((r = pa_source_suspend(source, suspend)) < 0)
+ if ((r = pa_source_suspend(source, suspend, cause)) < 0)
ret = r;
}
@@ -1055,6 +1924,7 @@ int pa_source_suspend_all(pa_core *c, pa_bool_t suspend) {
/* Called from main thread */
void pa_source_detach(pa_source *s) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_DETACH, NULL, 0, NULL) == 0);
@@ -1063,6 +1933,7 @@ void pa_source_detach(pa_source *s) {
/* Called from main thread */
void pa_source_attach(pa_source *s) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_ATTACH, NULL, 0, NULL) == 0);
@@ -1074,9 +1945,10 @@ void pa_source_detach_within_thread(pa_source *s) {
void *state = NULL;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
pa_assert(PA_SOURCE_IS_LINKED(s->thread_info.state));
- while ((o = pa_hashmap_iterate(s->thread_info.outputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state)
if (o->detach)
o->detach(o);
}
@@ -1087,9 +1959,10 @@ void pa_source_attach_within_thread(pa_source *s) {
void *state = NULL;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
pa_assert(PA_SOURCE_IS_LINKED(s->thread_info.state));
- while ((o = pa_hashmap_iterate(s->thread_info.outputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state)
if (o->attach)
o->attach(o);
}
@@ -1101,15 +1974,15 @@ pa_usec_t pa_source_get_requested_latency_within_thread(pa_source *s) {
void *state = NULL;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
if (!(s->flags & PA_SOURCE_DYNAMIC_LATENCY))
- return PA_CLAMP(s->fixed_latency, s->thread_info.min_latency, s->thread_info.max_latency);
+ return PA_CLAMP(s->thread_info.fixed_latency, s->thread_info.min_latency, s->thread_info.max_latency);
if (s->thread_info.requested_latency_valid)
return s->thread_info.requested_latency;
- while ((o = pa_hashmap_iterate(s->thread_info.outputs, &state, NULL)))
-
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state)
if (o->thread_info.requested_source_latency != (pa_usec_t) -1 &&
(result == (pa_usec_t) -1 || result > o->thread_info.requested_source_latency))
result = o->thread_info.requested_source_latency;
@@ -1131,6 +2004,7 @@ pa_usec_t pa_source_get_requested_latency(pa_source *s) {
pa_usec_t usec = 0;
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
pa_assert(PA_SOURCE_IS_LINKED(s->state));
if (s->state == PA_SOURCE_SUSPENDED)
@@ -1147,21 +2021,22 @@ void pa_source_set_max_rewind_within_thread(pa_source *s, size_t max_rewind) {
void *state = NULL;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
if (max_rewind == s->thread_info.max_rewind)
return;
s->thread_info.max_rewind = max_rewind;
- if (PA_SOURCE_IS_LINKED(s->thread_info.state)) {
- while ((o = pa_hashmap_iterate(s->thread_info.outputs, &state, NULL)))
+ if (PA_SOURCE_IS_LINKED(s->thread_info.state))
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state)
pa_source_output_update_max_rewind(o, s->thread_info.max_rewind);
- }
}
/* Called from main thread */
void pa_source_set_max_rewind(pa_source *s, size_t max_rewind) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
if (PA_SOURCE_IS_LINKED(s->state))
pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_MAX_REWIND, NULL, max_rewind, NULL) == 0);
@@ -1170,17 +2045,18 @@ void pa_source_set_max_rewind(pa_source *s, size_t max_rewind) {
}
/* Called from IO thread */
-void pa_source_invalidate_requested_latency(pa_source *s) {
+void pa_source_invalidate_requested_latency(pa_source *s, pa_bool_t dynamic) {
pa_source_output *o;
void *state = NULL;
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
- if (!(s->flags & PA_SOURCE_DYNAMIC_LATENCY))
+ if ((s->flags & PA_SOURCE_DYNAMIC_LATENCY))
+ s->thread_info.requested_latency_valid = FALSE;
+ else if (dynamic)
return;
- s->thread_info.requested_latency_valid = FALSE;
-
if (PA_SOURCE_IS_LINKED(s->thread_info.state)) {
if (s->update_requested_latency)
@@ -1192,12 +2068,13 @@ void pa_source_invalidate_requested_latency(pa_source *s) {
}
if (s->monitor_of)
- pa_sink_invalidate_requested_latency(s->monitor_of);
+ pa_sink_invalidate_requested_latency(s->monitor_of, dynamic);
}
/* Called from main thread */
void pa_source_set_latency_range(pa_source *s, pa_usec_t min_latency, pa_usec_t max_latency) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
/* min_latency == 0: no limit
* min_latency anything else: specified limit
@@ -1231,28 +2108,28 @@ void pa_source_set_latency_range(pa_source *s, pa_usec_t min_latency, pa_usec_t
/* Called from main thread */
void pa_source_get_latency_range(pa_source *s, pa_usec_t *min_latency, pa_usec_t *max_latency) {
- pa_source_assert_ref(s);
- pa_assert(min_latency);
- pa_assert(max_latency);
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+ pa_assert(min_latency);
+ pa_assert(max_latency);
- if (PA_SOURCE_IS_LINKED(s->state)) {
- pa_usec_t r[2] = { 0, 0 };
+ if (PA_SOURCE_IS_LINKED(s->state)) {
+ pa_usec_t r[2] = { 0, 0 };
- pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_GET_LATENCY_RANGE, r, 0, NULL) == 0);
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_GET_LATENCY_RANGE, r, 0, NULL) == 0);
- *min_latency = r[0];
- *max_latency = r[1];
- } else {
- *min_latency = s->thread_info.min_latency;
- *max_latency = s->thread_info.max_latency;
- }
+ *min_latency = r[0];
+ *max_latency = r[1];
+ } else {
+ *min_latency = s->thread_info.min_latency;
+ *max_latency = s->thread_info.max_latency;
+ }
}
/* Called from IO thread, and from main thread before pa_source_put() is called */
void pa_source_set_latency_range_within_thread(pa_source *s, pa_usec_t min_latency, pa_usec_t max_latency) {
- void *state = NULL;
-
pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
pa_assert(min_latency >= ABSOLUTE_MIN_LATENCY);
pa_assert(max_latency <= ABSOLUTE_MAX_LATENCY);
@@ -1264,25 +2141,34 @@ void pa_source_set_latency_range_within_thread(pa_source *s, pa_usec_t min_laten
(s->flags & PA_SOURCE_DYNAMIC_LATENCY) ||
s->monitor_of);
+ if (s->thread_info.min_latency == min_latency &&
+ s->thread_info.max_latency == max_latency)
+ return;
+
s->thread_info.min_latency = min_latency;
s->thread_info.max_latency = max_latency;
if (PA_SOURCE_IS_LINKED(s->thread_info.state)) {
pa_source_output *o;
+ void *state = NULL;
- while ((o = pa_hashmap_iterate(s->thread_info.outputs, &state, NULL)))
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state)
if (o->update_source_latency_range)
o->update_source_latency_range(o);
}
- pa_source_invalidate_requested_latency(s);
+ pa_source_invalidate_requested_latency(s, FALSE);
}
/* Called from main thread, before the source is put */
void pa_source_set_fixed_latency(pa_source *s, pa_usec_t latency) {
pa_source_assert_ref(s);
+ pa_assert_ctl_context();
- pa_assert(pa_source_get_state(s) == PA_SOURCE_INIT);
+ if (s->flags & PA_SOURCE_DYNAMIC_LATENCY) {
+ pa_assert(latency == 0);
+ return;
+ }
if (latency < ABSOLUTE_MIN_LATENCY)
latency = ABSOLUTE_MIN_LATENCY;
@@ -1290,12 +2176,64 @@ void pa_source_set_fixed_latency(pa_source *s, pa_usec_t latency) {
if (latency > ABSOLUTE_MAX_LATENCY)
latency = ABSOLUTE_MAX_LATENCY;
- s->fixed_latency = latency;
+ if (PA_SOURCE_IS_LINKED(s->state))
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_FIXED_LATENCY, NULL, (int64_t) latency, NULL) == 0);
+ else
+ s->thread_info.fixed_latency = latency;
+}
+
+/* Called from main thread */
+pa_usec_t pa_source_get_fixed_latency(pa_source *s) {
+ pa_usec_t latency;
+
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+
+ if (s->flags & PA_SOURCE_DYNAMIC_LATENCY)
+ return 0;
+
+ if (PA_SOURCE_IS_LINKED(s->state))
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_GET_FIXED_LATENCY, &latency, 0, NULL) == 0);
+ else
+ latency = s->thread_info.fixed_latency;
+
+ return latency;
+}
+
+/* Called from IO thread */
+void pa_source_set_fixed_latency_within_thread(pa_source *s, pa_usec_t latency) {
+ pa_source_assert_ref(s);
+ pa_source_assert_io_context(s);
+
+ if (s->flags & PA_SOURCE_DYNAMIC_LATENCY) {
+ pa_assert(latency == 0);
+ return;
+ }
+
+ pa_assert(latency >= ABSOLUTE_MIN_LATENCY);
+ pa_assert(latency <= ABSOLUTE_MAX_LATENCY);
+
+ if (s->thread_info.fixed_latency == latency)
+ return;
+
+ s->thread_info.fixed_latency = latency;
+
+ if (PA_SOURCE_IS_LINKED(s->thread_info.state)) {
+ pa_source_output *o;
+ void *state = NULL;
+
+ PA_HASHMAP_FOREACH(o, s->thread_info.outputs, state)
+ if (o->update_source_fixed_latency)
+ o->update_source_fixed_latency(o);
+ }
+
+ pa_source_invalidate_requested_latency(s, FALSE);
}
/* Called from main thread */
size_t pa_source_get_max_rewind(pa_source *s) {
size_t r;
+ pa_assert_ctl_context();
pa_source_assert_ref(s);
if (!PA_SOURCE_IS_LINKED(s->state))
@@ -1305,3 +2243,270 @@ size_t pa_source_get_max_rewind(pa_source *s) {
return r;
}
+
+/* Called from main context */
+int pa_source_set_port(pa_source *s, const char *name, pa_bool_t save) {
+ pa_device_port *port;
+ int ret;
+
+ pa_source_assert_ref(s);
+ pa_assert_ctl_context();
+
+ if (!s->set_port) {
+ pa_log_debug("set_port() operation not implemented for source %u \"%s\"", s->index, s->name);
+ return -PA_ERR_NOTIMPLEMENTED;
+ }
+
+ if (!s->ports)
+ return -PA_ERR_NOENTITY;
+
+ if (!(port = pa_hashmap_get(s->ports, name)))
+ return -PA_ERR_NOENTITY;
+
+ if (s->active_port == port) {
+ s->save_port = s->save_port || save;
+ return 0;
+ }
+
+ if (s->flags & PA_SOURCE_SYNC_VOLUME) {
+ struct source_message_set_port msg = { .port = port, .ret = 0 };
+ pa_assert_se(pa_asyncmsgq_send(s->asyncmsgq, PA_MSGOBJECT(s), PA_SOURCE_MESSAGE_SET_PORT, &msg, 0, NULL) == 0);
+ ret = msg.ret;
+ }
+ else
+ ret = s->set_port(s, port);
+
+ if (ret < 0)
+ return -PA_ERR_NOENTITY;
+
+ pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SOURCE|PA_SUBSCRIPTION_EVENT_CHANGE, s->index);
+
+ pa_log_info("Changed port of source %u \"%s\" to %s", s->index, s->name, port->name);
+
+ s->active_port = port;
+ s->save_port = save;
+
+ pa_hook_fire(&s->core->hooks[PA_CORE_HOOK_SOURCE_PORT_CHANGED], s);
+
+ return 0;
+}
+
+PA_STATIC_FLIST_DECLARE(pa_source_volume_change, 0, pa_xfree);
+
+/* Called from the IO thread. */
+static pa_source_volume_change *pa_source_volume_change_new(pa_source *s) {
+ pa_source_volume_change *c;
+ if (!(c = pa_flist_pop(PA_STATIC_FLIST_GET(pa_source_volume_change))))
+ c = pa_xnew(pa_source_volume_change, 1);
+
+ PA_LLIST_INIT(pa_source_volume_change, c);
+ c->at = 0;
+ pa_cvolume_reset(&c->hw_volume, s->sample_spec.channels);
+ return c;
+}
+
+/* Called from the IO thread. */
+static void pa_source_volume_change_free(pa_source_volume_change *c) {
+ pa_assert(c);
+ if (pa_flist_push(PA_STATIC_FLIST_GET(pa_source_volume_change), c) < 0)
+ pa_xfree(c);
+}
+
+/* Called from the IO thread. */
+void pa_source_volume_change_push(pa_source *s) {
+ pa_source_volume_change *c = NULL;
+ pa_source_volume_change *nc = NULL;
+ uint32_t safety_margin = s->thread_info.volume_change_safety_margin;
+
+ const char *direction = NULL;
+
+ pa_assert(s);
+ nc = pa_source_volume_change_new(s);
+
+ /* NOTE: There is already more different volumes in pa_source that I can remember.
+ * Adding one more volume for HW would get us rid of this, but I am trying
+ * to survive with the ones we already have. */
+ pa_sw_cvolume_divide(&nc->hw_volume, &s->real_volume, &s->soft_volume);
+
+ if (!s->thread_info.volume_changes && pa_cvolume_equal(&nc->hw_volume, &s->thread_info.current_hw_volume)) {
+ pa_log_debug("Volume not changing");
+ pa_source_volume_change_free(nc);
+ return;
+ }
+
+ nc->at = pa_source_get_latency_within_thread(s);
+ nc->at += pa_rtclock_now() + s->thread_info.volume_change_extra_delay;
+
+ if (s->thread_info.volume_changes_tail) {
+ for (c = s->thread_info.volume_changes_tail; c; c = c->prev) {
+ /* If volume is going up let's do it a bit late. If it is going
+ * down let's do it a bit early. */
+ if (pa_cvolume_avg(&nc->hw_volume) > pa_cvolume_avg(&c->hw_volume)) {
+ if (nc->at + safety_margin > c->at) {
+ nc->at += safety_margin;
+ direction = "up";
+ break;
+ }
+ }
+ else if (nc->at - safety_margin > c->at) {
+ nc->at -= safety_margin;
+ direction = "down";
+ break;
+ }
+ }
+ }
+
+ if (c == NULL) {
+ if (pa_cvolume_avg(&nc->hw_volume) > pa_cvolume_avg(&s->thread_info.current_hw_volume)) {
+ nc->at += safety_margin;
+ direction = "up";
+ } else {
+ nc->at -= safety_margin;
+ direction = "down";
+ }
+ PA_LLIST_PREPEND(pa_source_volume_change, s->thread_info.volume_changes, nc);
+ }
+ else {
+ PA_LLIST_INSERT_AFTER(pa_source_volume_change, s->thread_info.volume_changes, c, nc);
+ }
+
+ pa_log_debug("Volume going %s to %d at %llu", direction, pa_cvolume_avg(&nc->hw_volume), (long long unsigned) nc->at);
+
+ /* We can ignore volume events that came earlier but should happen later than this. */
+ PA_LLIST_FOREACH(c, nc->next) {
+ pa_log_debug("Volume change to %d at %llu was dropped", pa_cvolume_avg(&c->hw_volume), (long long unsigned) c->at);
+ pa_source_volume_change_free(c);
+ }
+ nc->next = NULL;
+ s->thread_info.volume_changes_tail = nc;
+}
+
+/* Called from the IO thread. */
+static void pa_source_volume_change_flush(pa_source *s) {
+ pa_source_volume_change *c = s->thread_info.volume_changes;
+ pa_assert(s);
+ s->thread_info.volume_changes = NULL;
+ s->thread_info.volume_changes_tail = NULL;
+ while (c) {
+ pa_source_volume_change *next = c->next;
+ pa_source_volume_change_free(c);
+ c = next;
+ }
+}
+
+/* Called from the IO thread. */
+pa_bool_t pa_source_volume_change_apply(pa_source *s, pa_usec_t *usec_to_next) {
+ pa_usec_t now = pa_rtclock_now();
+ pa_bool_t ret = FALSE;
+
+ pa_assert(s);
+ pa_assert(s->write_volume);
+
+ while (s->thread_info.volume_changes && now >= s->thread_info.volume_changes->at) {
+ pa_source_volume_change *c = s->thread_info.volume_changes;
+ PA_LLIST_REMOVE(pa_source_volume_change, s->thread_info.volume_changes, c);
+ pa_log_debug("Volume change to %d at %llu was written %llu usec late",
+ pa_cvolume_avg(&c->hw_volume), (long long unsigned) c->at, (long long unsigned) (now - c->at));
+ ret = TRUE;
+ s->thread_info.current_hw_volume = c->hw_volume;
+ pa_source_volume_change_free(c);
+ }
+
+ if (s->write_volume && ret)
+ s->write_volume(s);
+
+ if (s->thread_info.volume_changes) {
+ if (usec_to_next)
+ *usec_to_next = s->thread_info.volume_changes->at - now;
+ if (pa_log_ratelimit(PA_LOG_DEBUG))
+ pa_log_debug("Next volume change in %lld usec", (long long) (s->thread_info.volume_changes->at - now));
+ }
+ else {
+ if (usec_to_next)
+ *usec_to_next = 0;
+ s->thread_info.volume_changes_tail = NULL;
+ }
+ return ret;
+}
+
+
+/* Called from the main thread */
+/* Gets the list of formats supported by the source. The members and idxset must
+ * be freed by the caller. */
+pa_idxset* pa_source_get_formats(pa_source *s) {
+ pa_idxset *ret;
+
+ pa_assert(s);
+
+ if (s->get_formats) {
+ /* Source supports format query, all is good */
+ ret = s->get_formats(s);
+ } else {
+ /* Source doesn't support format query, so assume it does PCM */
+ pa_format_info *f = pa_format_info_new();
+ f->encoding = PA_ENCODING_PCM;
+
+ ret = pa_idxset_new(NULL, NULL);
+ pa_idxset_put(ret, f, NULL);
+ }
+
+ return ret;
+}
+
+/* Called from the main thread */
+/* Checks if the source can accept this format */
+pa_bool_t pa_source_check_format(pa_source *s, pa_format_info *f)
+{
+ pa_idxset *formats = NULL;
+ pa_bool_t ret = FALSE;
+
+ pa_assert(s);
+ pa_assert(f);
+
+ formats = pa_source_get_formats(s);
+
+ if (formats) {
+ pa_format_info *finfo_device;
+ uint32_t i;
+
+ PA_IDXSET_FOREACH(finfo_device, formats, i) {
+ if (pa_format_info_is_compatible(finfo_device, f)) {
+ ret = TRUE;
+ break;
+ }
+ }
+
+ pa_idxset_free(formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+ }
+
+ return ret;
+}
+
+/* Called from the main thread */
+/* Calculates the intersection between formats supported by the source and
+ * in_formats, and returns these, in the order of the source's formats. */
+pa_idxset* pa_source_check_formats(pa_source *s, pa_idxset *in_formats) {
+ pa_idxset *out_formats = pa_idxset_new(NULL, NULL), *source_formats = NULL;
+ pa_format_info *f_source, *f_in;
+ uint32_t i, j;
+
+ pa_assert(s);
+
+ if (!in_formats || pa_idxset_isempty(in_formats))
+ goto done;
+
+ source_formats = pa_source_get_formats(s);
+
+ PA_IDXSET_FOREACH(f_source, source_formats, i) {
+ PA_IDXSET_FOREACH(f_in, in_formats, j) {
+ if (pa_format_info_is_compatible(f_source, f_in))
+ pa_idxset_put(out_formats, pa_format_info_copy(f_in), NULL);
+ }
+ }
+
+done:
+ if (source_formats)
+ pa_idxset_free(source_formats, (pa_free2_cb_t) pa_format_info_free2, NULL);
+
+ return out_formats;
+}
diff --git a/src/pulsecore/source.h b/src/pulsecore/source.h
index 2978f57b..b68dfd59 100644
--- a/src/pulsecore/source.h
+++ b/src/pulsecore/source.h
@@ -24,25 +24,27 @@
***/
typedef struct pa_source pa_source;
+typedef struct pa_source_volume_change pa_source_volume_change;
#include <inttypes.h>
+#include <pulse/def.h>
#include <pulse/sample.h>
#include <pulse/channelmap.h>
#include <pulse/volume.h>
#include <pulsecore/core.h>
#include <pulsecore/idxset.h>
-#include <pulsecore/memblock.h>
#include <pulsecore/memchunk.h>
#include <pulsecore/sink.h>
#include <pulsecore/module.h>
#include <pulsecore/asyncmsgq.h>
#include <pulsecore/msgobject.h>
#include <pulsecore/rtpoll.h>
-#include <pulsecore/source-output.h>
#include <pulsecore/card.h>
#include <pulsecore/queue.h>
+#include <pulsecore/thread-mq.h>
+#include <pulsecore/source-output.h>
#define PA_MAX_OUTPUTS_PER_SOURCE 32
@@ -56,8 +58,10 @@ struct pa_source {
uint32_t index;
pa_core *core;
+
pa_source_state_t state;
pa_source_flags_t flags;
+ pa_suspend_cause_t suspend_cause;
char *name;
char *driver; /* may be NULL */
@@ -72,22 +76,32 @@ struct pa_source {
pa_idxset *outputs;
unsigned n_corked;
pa_sink *monitor_of; /* may be NULL */
+ pa_source_output *output_from_master; /* non-NULL only for filter sources */
pa_volume_t base_volume; /* shall be constant */
unsigned n_volume_steps; /* shall be constant */
- pa_cvolume virtual_volume, soft_volume;
+ /* Also see http://pulseaudio.org/wiki/InternalVolumes */
+ pa_cvolume reference_volume; /* The volume exported and taken as reference base for relative source output volumes */
+ pa_cvolume real_volume; /* The volume that the hardware is configured to */
+ pa_cvolume soft_volume; /* The internal software volume we apply to all PCM data while it passes through */
+
pa_bool_t muted:1;
pa_bool_t refresh_volume:1;
pa_bool_t refresh_muted:1;
+ pa_bool_t save_port:1;
+ pa_bool_t save_volume:1;
+ pa_bool_t save_muted:1;
pa_asyncmsgq *asyncmsgq;
- pa_rtpoll *rtpoll;
pa_memchunk silence;
- pa_usec_t fixed_latency; /* for sources with PA_SOURCE_DYNAMIC_LATENCY this is 0 */
+ pa_hashmap *ports;
+ pa_device_port *active_port;
+
+ unsigned priority;
/* Called when the main loop requests a state change. Called from
* main loop context. If returns -1 the state change will be
@@ -98,27 +112,48 @@ struct pa_source {
* context. If this is NULL a PA_SOURCE_MESSAGE_GET_VOLUME message
* will be sent to the IO thread instead. If refresh_volume is
* FALSE neither this function is called nor a message is sent. */
- void (*get_volume)(pa_source *s); /* dito */
+ void (*get_volume)(pa_source *s); /* ditto */
/* Called when the volume shall be changed. Called from main loop
* context. If this is NULL a PA_SOURCE_MESSAGE_SET_VOLUME message
* will be sent to the IO thread instead. */
- void (*set_volume)(pa_source *s); /* dito */
+ void (*set_volume)(pa_source *s); /* ditto */
+
+ /* Source drivers that set PA_SOURCE_SYNC_VOLUME must provide this
+ * callback. This callback is not used with source that do not set
+ * PA_SOURCE_SYNC_VOLUME. This is called from the IO thread when a
+ * pending hardware volume change has to be written to the
+ * hardware. The requested volume is passed to the callback
+ * implementation in s->thread_info.current_hw_volume.
+ *
+ * The call is done inside pa_source_volume_change_apply(), which is
+ * not called automatically - it is the driver's responsibility to
+ * schedule that function to be called at the right times in the
+ * IO thread. */
+ void (*write_volume)(pa_source *s); /* ditto */
/* Called when the mute setting is queried. Called from main loop
* context. If this is NULL a PA_SOURCE_MESSAGE_GET_MUTE message
* will be sent to the IO thread instead. If refresh_mute is
* FALSE neither this function is called nor a message is sent.*/
- void (*get_mute)(pa_source *s); /* dito */
+ void (*get_mute)(pa_source *s); /* ditto */
/* Called when the mute setting shall be changed. Called from main
* loop context. If this is NULL a PA_SOURCE_MESSAGE_SET_MUTE
* message will be sent to the IO thread instead. */
- void (*set_mute)(pa_source *s); /* dito */
+ void (*set_mute)(pa_source *s); /* ditto */
/* Called when a the requested latency is changed. Called from IO
* thread context. */
- void (*update_requested_latency)(pa_source *s); /* dito */
+ void (*update_requested_latency)(pa_source *s); /* ditto */
+
+ /* Called whenever the port shall be changed. Called from main
+ * thread. */
+ int (*set_port)(pa_source *s, pa_device_port *port); /*ditto */
+
+ /* Called to get the list of formats supported by the source, sorted
+ * in descending order of preference. */
+ pa_idxset* (*get_formats)(pa_source *s); /* ditto */
/* Contains copies of the above data so that the real-time worker
* thread can work without access locking */
@@ -126,6 +161,8 @@ struct pa_source {
pa_source_state_t state;
pa_hashmap *outputs;
+ pa_rtpoll *rtpoll;
+
pa_cvolume soft_volume;
pa_bool_t soft_muted:1;
@@ -138,19 +175,39 @@ struct pa_source {
pa_usec_t min_latency; /* we won't go below this latency */
pa_usec_t max_latency; /* An upper limit for the latencies */
- } thread_info;
+
+ pa_usec_t fixed_latency; /* for sources with PA_SOURCE_DYNAMIC_LATENCY this is 0 */
+
+ /* Delayed volume change events are queued here. The events
+ * are stored in expiration order. The one expiring next is in
+ * the head of the list. */
+ PA_LLIST_HEAD(pa_source_volume_change, volume_changes);
+ pa_source_volume_change *volume_changes_tail;
+ /* This value is updated in pa_source_volume_change_apply() and
+ * used only by sources with PA_SOURCE_SYNC_VOLUME. */
+ pa_cvolume current_hw_volume;
+
+ /* The amount of usec volume up events are delayed and volume
+ * down events are made earlier. */
+ uint32_t volume_change_safety_margin;
+ /* Usec delay added to all volume change events, may be negative. */
+ int32_t volume_change_extra_delay;
+} thread_info;
void *userdata;
};
-PA_DECLARE_CLASS(pa_source);
+PA_DECLARE_PUBLIC_CLASS(pa_source);
#define PA_SOURCE(s) pa_source_cast(s)
typedef enum pa_source_message {
PA_SOURCE_MESSAGE_ADD_OUTPUT,
PA_SOURCE_MESSAGE_REMOVE_OUTPUT,
PA_SOURCE_MESSAGE_GET_VOLUME,
+ PA_SOURCE_MESSAGE_SET_SHARED_VOLUME,
+ PA_SOURCE_MESSAGE_SET_VOLUME_SYNCED,
PA_SOURCE_MESSAGE_SET_VOLUME,
+ PA_SOURCE_MESSAGE_SYNC_VOLUMES,
PA_SOURCE_MESSAGE_GET_MUTE,
PA_SOURCE_MESSAGE_SET_MUTE,
PA_SOURCE_MESSAGE_GET_LATENCY,
@@ -160,8 +217,12 @@ typedef enum pa_source_message {
PA_SOURCE_MESSAGE_DETACH,
PA_SOURCE_MESSAGE_SET_LATENCY_RANGE,
PA_SOURCE_MESSAGE_GET_LATENCY_RANGE,
+ PA_SOURCE_MESSAGE_SET_FIXED_LATENCY,
+ PA_SOURCE_MESSAGE_GET_FIXED_LATENCY,
PA_SOURCE_MESSAGE_GET_MAX_REWIND,
PA_SOURCE_MESSAGE_SET_MAX_REWIND,
+ PA_SOURCE_MESSAGE_SET_PORT,
+ PA_SOURCE_MESSAGE_UPDATE_VOLUME_AND_MUTE,
PA_SOURCE_MESSAGE_MAX
} pa_source_message_t;
@@ -173,6 +234,9 @@ typedef struct pa_source_new_data {
pa_module *module;
pa_card *card;
+ pa_hashmap *ports;
+ char *active_port;
+
pa_sample_spec sample_spec;
pa_channel_map channel_map;
pa_cvolume volume;
@@ -184,6 +248,10 @@ typedef struct pa_source_new_data {
pa_bool_t channel_map_is_set:1;
pa_bool_t namereg_fail:1;
+
+ pa_bool_t save_port:1;
+ pa_bool_t save_volume:1;
+ pa_bool_t save_muted:1;
} pa_source_new_data;
pa_source_new_data* pa_source_new_data_init(pa_source_new_data *data);
@@ -192,6 +260,7 @@ void pa_source_new_data_set_sample_spec(pa_source_new_data *data, const pa_sampl
void pa_source_new_data_set_channel_map(pa_source_new_data *data, const pa_channel_map *map);
void pa_source_new_data_set_volume(pa_source_new_data *data, const pa_cvolume *volume);
void pa_source_new_data_set_muted(pa_source_new_data *data, pa_bool_t mute);
+void pa_source_new_data_set_port(pa_source_new_data *data, const char *port);
void pa_source_new_data_done(pa_source_new_data *data);
/*** To be called exclusively by the source driver, from main context */
@@ -221,36 +290,53 @@ void pa_source_mute_changed(pa_source *s, pa_bool_t new_muted);
int pa_source_sync_suspend(pa_source *s);
+void pa_source_update_flags(pa_source *s, pa_source_flags_t mask, pa_source_flags_t value);
+
/*** May be called by everyone, from main context */
/* The returned value is supposed to be in the time domain of the sound card! */
pa_usec_t pa_source_get_latency(pa_source *s);
pa_usec_t pa_source_get_requested_latency(pa_source *s);
void pa_source_get_latency_range(pa_source *s, pa_usec_t *min_latency, pa_usec_t *max_latency);
+pa_usec_t pa_source_get_fixed_latency(pa_source *s);
size_t pa_source_get_max_rewind(pa_source *s);
int pa_source_update_status(pa_source*s);
-int pa_source_suspend(pa_source *s, pa_bool_t suspend);
-int pa_source_suspend_all(pa_core *c, pa_bool_t suspend);
+int pa_source_suspend(pa_source *s, pa_bool_t suspend, pa_suspend_cause_t cause);
+int pa_source_suspend_all(pa_core *c, pa_bool_t suspend, pa_suspend_cause_t cause);
+
+/* Use this instead of checking s->flags & PA_SOURCE_FLAT_VOLUME directly. */
+pa_bool_t pa_source_flat_volume_enabled(pa_source *s);
-void pa_source_set_volume(pa_source *source, const pa_cvolume *volume);
+/* Is the source in passthrough mode? (that is, is this a monitor source for a sink
+ * that has a passthrough sink input connected to it. */
+pa_bool_t pa_source_is_passthrough(pa_source *s);
+
+void pa_source_set_volume(pa_source *source, const pa_cvolume *volume, pa_bool_t sendmsg, pa_bool_t save);
const pa_cvolume *pa_source_get_volume(pa_source *source, pa_bool_t force_refresh);
-void pa_source_set_mute(pa_source *source, pa_bool_t mute);
+
+void pa_source_set_mute(pa_source *source, pa_bool_t mute, pa_bool_t save);
pa_bool_t pa_source_get_mute(pa_source *source, pa_bool_t force_refresh);
pa_bool_t pa_source_update_proplist(pa_source *s, pa_update_mode_t mode, pa_proplist *p);
+int pa_source_set_port(pa_source *s, const char *name, pa_bool_t save);
+
unsigned pa_source_linked_by(pa_source *s); /* Number of connected streams */
unsigned pa_source_used_by(pa_source *s); /* Number of connected streams that are not corked */
unsigned pa_source_check_suspend(pa_source *s); /* Returns how many streams are active that don't allow suspensions */
#define pa_source_get_state(s) ((pa_source_state_t) (s)->state)
/* Moves all inputs away, and stores them in pa_queue */
-pa_queue *pa_source_move_all_start(pa_source *s);
+pa_queue *pa_source_move_all_start(pa_source *s, pa_queue *q);
void pa_source_move_all_finish(pa_source *s, pa_queue *q, pa_bool_t save);
void pa_source_move_all_fail(pa_queue *q);
+pa_idxset* pa_source_get_formats(pa_source *s);
+pa_bool_t pa_source_check_format(pa_source *s, pa_format_info *f);
+pa_idxset* pa_source_check_formats(pa_source *s, pa_idxset *in_formats);
+
/*** To be called exclusively by the source driver, from IO context */
void pa_source_post(pa_source*s, const pa_memchunk *chunk);
@@ -265,11 +351,20 @@ void pa_source_detach_within_thread(pa_source *s);
pa_usec_t pa_source_get_requested_latency_within_thread(pa_source *s);
void pa_source_set_max_rewind_within_thread(pa_source *s, size_t max_rewind);
+
void pa_source_set_latency_range_within_thread(pa_source *s, pa_usec_t min_latency, pa_usec_t max_latency);
+void pa_source_set_fixed_latency_within_thread(pa_source *s, pa_usec_t latency);
+
+void pa_source_update_volume_and_mute(pa_source *s);
+
+pa_bool_t pa_source_volume_change_apply(pa_source *s, pa_usec_t *usec_to_next);
/*** To be called exclusively by source output drivers, from IO context */
-void pa_source_invalidate_requested_latency(pa_source *s);
+void pa_source_invalidate_requested_latency(pa_source *s, pa_bool_t dynamic);
pa_usec_t pa_source_get_latency_within_thread(pa_source *s);
+#define pa_source_assert_io_context(s) \
+ pa_assert(pa_thread_mq_get() || !PA_SOURCE_IS_LINKED((s)->state))
+
#endif
diff --git a/src/pulsecore/start-child.c b/src/pulsecore/start-child.c
index 7774bde6..7f55d4e2 100644
--- a/src/pulsecore/start-child.c
+++ b/src/pulsecore/start-child.c
@@ -40,10 +40,12 @@
#include <pulsecore/core-util.h>
#include <pulsecore/core-error.h>
+#include <pulsecore/pipe.h>
#include "start-child.h"
int pa_start_child_for_read(const char *name, const char *argv1, pid_t *pid) {
+#ifdef HAVE_FORK
pid_t child;
int pipe_fds[2] = { -1, -1 };
@@ -68,23 +70,29 @@ int pa_start_child_for_read(const char *name, const char *argv1, pid_t *pid) {
} else {
/* child */
- pa_reset_priority();
+ pa_reset_personality();
pa_assert_se(pa_close(pipe_fds[0]) == 0);
- pa_assert_se(dup2(pipe_fds[1], 1) == 1);
+ pa_assert_se(dup2(pipe_fds[1], STDOUT_FILENO) == STDOUT_FILENO);
- if (pipe_fds[1] != 1)
+ if (pipe_fds[1] != STDOUT_FILENO)
pa_assert_se(pa_close(pipe_fds[1]) == 0);
- pa_close(0);
- pa_assert_se(open("/dev/null", O_RDONLY) == 0);
+ pa_close(STDIN_FILENO);
+ pa_assert_se(open("/dev/null", O_RDONLY) == STDIN_FILENO);
- pa_close(2);
- pa_assert_se(open("/dev/null", O_WRONLY) == 2);
+ pa_close(STDERR_FILENO);
+ pa_assert_se(open("/dev/null", O_WRONLY) == STDERR_FILENO);
pa_close_all(-1);
pa_reset_sigs(-1);
pa_unblock_sigs(-1);
+ pa_reset_priority();
+ pa_unset_env_recorded();
+
+ /* Make sure our children are not influenced by the
+ * LD_BIND_NOW we set for ourselves. */
+ unsetenv("LD_BIND_NOW");
#ifdef PR_SET_PDEATHSIG
/* On Linux we can use PR_SET_PDEATHSIG to have the helper
@@ -101,6 +109,7 @@ int pa_start_child_for_read(const char *name, const char *argv1, pid_t *pid) {
fail:
pa_close_pipe(pipe_fds);
+#endif /* HAVE_FORK */
return -1;
}
diff --git a/src/pulsecore/strbuf.c b/src/pulsecore/strbuf.c
index 4fc82ded..f131d5cd 100644
--- a/src/pulsecore/strbuf.c
+++ b/src/pulsecore/strbuf.c
@@ -146,7 +146,7 @@ void pa_strbuf_putsn(pa_strbuf *sb, const char *t, size_t l) {
pa_assert(t);
if (!l)
- return;
+ return;
c = pa_xmalloc(PA_ALIGN(sizeof(struct chunk)) + l);
c->length = l;
diff --git a/src/pulsecore/strlist.c b/src/pulsecore/strlist.c
index 0f4ca867..b2ba12ba 100644
--- a/src/pulsecore/strlist.c
+++ b/src/pulsecore/strlist.c
@@ -49,7 +49,7 @@ pa_strlist* pa_strlist_prepend(pa_strlist *l, const char *s) {
memcpy(ITEM_TO_TEXT(n), s, size + 1);
n->next = l;
- return n;
+ return n;
}
char *pa_strlist_tostring(pa_strlist *l) {
diff --git a/src/pulsecore/svolume.orc b/src/pulsecore/svolume.orc
new file mode 100644
index 00000000..3411161c
--- /dev/null
+++ b/src/pulsecore/svolume.orc
@@ -0,0 +1,84 @@
+# This file is part of PulseAudio.
+#
+# Copyright 2010 Lennart Poettering
+# Copyright 2010 Wim Taymans <wim.taymans@collabora.co.uk>
+# Copyright 2010 Arun Raghavan <arun.raghavan@collabora.co.uk>
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published
+# by the Free Software Foundation; either version 2.1 of the License,
+# or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+# USA.
+
+# S16NE 1- and 2-channel volume scaling work as follows:
+#
+# params: samples s (signed 16-bit), volume v (signed 32-bit < 2^31)
+#
+# 32 16 0 (type of operation)
+# sample = | sample | (signed)
+# s = | 0 | sample | (unsigned)
+#
+# if (sample < 0)
+# signc = | 0 | 0xffff | (unsigned)
+# else
+# signc = | 0 | 0 | (unsgined)
+#
+# if (sample < 0)
+# ml = | 0 | -((s*vl) >> 16) | (unsgined)
+# else
+# ml = | 0 | (s*vl) >> 16 | (unsgined)
+#
+# vh = | v >> 16 | (signed, but value is always signed
+# since PA_VOLUME_MAX is 0x0fffffff)
+# mh = | (s * vh) >> 16 | (signed)
+# ml = | ml + mh | (signed)
+# sample = | (ml >> 16) | (signed, saturated)
+
+.function pa_volume_s16ne_orc_1ch
+.dest 2 samples int16_t
+.param 4 v int32_t
+.temp 2 vh
+.temp 4 s
+.temp 4 mh
+.temp 4 ml
+.temp 4 signc
+
+convuwl s, samples
+x2 cmpgtsw signc, 0, s
+x2 andw signc, signc, v
+x2 mulhuw ml, s, v
+subl ml, ml, signc
+convhlw vh, v
+mulswl mh, samples, vh
+addl ml, ml, mh
+convssslw samples, ml
+
+.function pa_volume_s16ne_orc_2ch
+.dest 4 samples int16_t
+.longparam 8 vols
+.temp 8 v
+.temp 4 vh
+.temp 8 s
+.temp 8 mh
+.temp 8 ml
+.temp 8 signc
+
+loadpq v, vols
+x2 convuwl s, samples
+x4 cmpgtsw signc, 0, s
+x4 andw signc, signc, v
+x4 mulhuw ml, s, v
+x2 subl ml, ml, signc
+x2 convhlw vh, v
+x2 mulswl mh, samples, vh
+x2 addl ml, ml, mh
+x2 convssslw samples, ml
diff --git a/src/pulsecore/svolume_arm.c b/src/pulsecore/svolume_arm.c
new file mode 100644
index 00000000..b7797337
--- /dev/null
+++ b/src/pulsecore/svolume_arm.c
@@ -0,0 +1,218 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulsecore/random.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/endianmacros.h>
+
+#include "cpu-arm.h"
+
+#include "sample-util.h"
+
+#if defined (__arm__) && defined (HAVE_ARMV6)
+
+#define MOD_INC() \
+ " subs r0, r6, %2 \n\t" \
+ " itt cs \n\t" \
+ " addcs r0, %1 \n\t" \
+ " movcs r6, r0 \n\t"
+
+static void pa_volume_s16ne_arm(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ int32_t *ve;
+
+ /* Channels must be at least 4, and always a multiple of the original number.
+ * This is also the max amount we overread the volume array, which should
+ * have enough padding. */
+ channels = channels == 3 ? 6 : PA_MAX (4U, channels);
+ ve = volumes + channels;
+
+ __asm__ __volatile__ (
+ " mov r6, %1 \n\t"
+ " mov %3, %3, LSR #1 \n\t" /* length /= sizeof (int16_t) */
+ " tst %3, #1 \n\t" /* check for odd samples */
+ " beq 2f \n\t"
+
+ "1: \n\t"
+ " ldr r0, [r6], #4 \n\t" /* odd samples volumes */
+ " ldrh r2, [%0] \n\t"
+
+ " smulwb r0, r0, r2 \n\t"
+ " ssat r0, #16, r0 \n\t"
+
+ " strh r0, [%0], #2 \n\t"
+
+ MOD_INC()
+
+ "2: \n\t"
+ " mov %3, %3, LSR #1 \n\t"
+ " tst %3, #1 \n\t" /* check for odd samples */
+ " beq 4f \n\t"
+
+ "3: \n\t"
+ " ldrd r2, [r6], #8 \n\t" /* 2 samples at a time */
+ " ldr r0, [%0] \n\t"
+
+ " smulwt r2, r2, r0 \n\t"
+ " smulwb r3, r3, r0 \n\t"
+
+ " ssat r2, #16, r2 \n\t"
+ " ssat r3, #16, r3 \n\t"
+
+ " pkhbt r0, r3, r2, LSL #16 \n\t"
+ " str r0, [%0], #4 \n\t"
+
+ MOD_INC()
+
+ "4: \n\t"
+ " movs %3, %3, LSR #1 \n\t"
+ " beq 6f \n\t"
+
+ "5: \n\t"
+ " ldrd r2, [r6], #8 \n\t" /* 4 samples at a time */
+ " ldrd r4, [r6], #8 \n\t"
+ " ldrd r0, [%0] \n\t"
+
+ " smulwt r2, r2, r0 \n\t"
+ " smulwb r3, r3, r0 \n\t"
+ " smulwt r4, r4, r1 \n\t"
+ " smulwb r5, r5, r1 \n\t"
+
+ " ssat r2, #16, r2 \n\t"
+ " ssat r3, #16, r3 \n\t"
+ " ssat r4, #16, r4 \n\t"
+ " ssat r5, #16, r5 \n\t"
+
+ " pkhbt r0, r3, r2, LSL #16 \n\t"
+ " pkhbt r1, r5, r4, LSL #16 \n\t"
+ " strd r0, [%0], #8 \n\t"
+
+ MOD_INC()
+
+ " subs %3, %3, #1 \n\t"
+ " bne 5b \n\t"
+ "6: \n\t"
+
+ : "+r" (samples), "+r" (volumes), "+r" (ve), "+r" (length)
+ :
+ : "r6", "r5", "r4", "r3", "r2", "r1", "r0", "cc"
+ );
+}
+
+#undef RUN_TEST
+
+#ifdef RUN_TEST
+#define CHANNELS 2
+#define SAMPLES 1022
+#define TIMES 1000
+#define TIMES2 100
+#define PADDING 16
+
+static void run_test(void) {
+ int16_t samples[SAMPLES];
+ int16_t samples_ref[SAMPLES];
+ int16_t samples_orig[SAMPLES];
+ int32_t volumes[CHANNELS + PADDING];
+ int i, j, padding;
+ pa_do_volume_func_t func;
+ pa_usec_t start, stop;
+ int k;
+ pa_usec_t min = INT_MAX, max = 0;
+ double s1 = 0, s2 = 0;
+
+ func = pa_get_volume_func(PA_SAMPLE_S16NE);
+
+ printf("checking ARM %zd\n", sizeof(samples));
+
+ pa_random(samples, sizeof(samples));
+ memcpy(samples_ref, samples, sizeof(samples));
+ memcpy(samples_orig, samples, sizeof(samples));
+
+ for (i = 0; i < CHANNELS; i++)
+ volumes[i] = PA_CLAMP_VOLUME(rand() >> 1);
+ for (padding = 0; padding < PADDING; padding++, i++)
+ volumes[i] = volumes[padding];
+
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ pa_volume_s16ne_arm(samples, volumes, CHANNELS, sizeof(samples));
+ for (i = 0; i < SAMPLES; i++) {
+ if (samples[i] != samples_ref[i]) {
+ printf ("%d: %04x != %04x (%04x * %04x)\n", i, samples[i], samples_ref[i],
+ samples_orig[i], volumes[i % CHANNELS]);
+ }
+ }
+
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples, samples_orig, sizeof(samples));
+ pa_volume_s16ne_arm(samples, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("ARM: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ min = INT_MAX; max = 0;
+ s1 = s2 = 0;
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples_ref, samples_orig, sizeof(samples));
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("ref: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ pa_assert_se(memcmp(samples_ref, samples, sizeof(samples)) == 0);
+}
+#endif
+
+#endif /* defined (__arm__) && defined (HAVE_ARMV6) */
+
+
+void pa_volume_func_init_arm(pa_cpu_arm_flag_t flags) {
+#if defined (__arm__) && defined (HAVE_ARMV6)
+ pa_log_info("Initialising ARM optimized functions.");
+
+#ifdef RUN_TEST
+ run_test();
+#endif
+
+ pa_set_volume_func(PA_SAMPLE_S16NE, (pa_do_volume_func_t) pa_volume_s16ne_arm);
+#endif /* defined (__arm__) && defined (HAVE_ARMV6) */
+}
diff --git a/src/pulsecore/svolume_c.c b/src/pulsecore/svolume_c.c
new file mode 100644
index 00000000..6c0fbf81
--- /dev/null
+++ b/src/pulsecore/svolume_c.c
@@ -0,0 +1,307 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2006 Pierre Ossman <ossman@cendio.se> for Cendio AB
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+
+#include <pulsecore/macro.h>
+#include <pulsecore/g711.h>
+#include <pulsecore/endianmacros.h>
+
+#include "sample-util.h"
+
+static void pa_volume_u8_c(uint8_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ for (channel = 0; length; length--) {
+ int32_t t, hi, lo;
+
+ hi = volumes[channel] >> 16;
+ lo = volumes[channel] & 0xFFFF;
+
+ t = (int32_t) *samples - 0x80;
+ t = ((t * lo) >> 16) + (t * hi);
+ t = PA_CLAMP_UNLIKELY(t, -0x80, 0x7F);
+ *samples++ = (uint8_t) (t + 0x80);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_alaw_c(uint8_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ for (channel = 0; length; length--) {
+ int32_t t, hi, lo;
+
+ hi = volumes[channel] >> 16;
+ lo = volumes[channel] & 0xFFFF;
+
+ t = (int32_t) st_alaw2linear16(*samples);
+ t = ((t * lo) >> 16) + (t * hi);
+ t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
+ *samples++ = (uint8_t) st_13linear2alaw((int16_t) t >> 3);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_ulaw_c(uint8_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ for (channel = 0; length; length--) {
+ int32_t t, hi, lo;
+
+ hi = volumes[channel] >> 16;
+ lo = volumes[channel] & 0xFFFF;
+
+ t = (int32_t) st_ulaw2linear16(*samples);
+ t = ((t * lo) >> 16) + (t * hi);
+ t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
+ *samples++ = (uint8_t) st_14linear2ulaw((int16_t) t >> 2);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s16ne_c(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(int16_t);
+
+ for (channel = 0; length; length--) {
+ int32_t t, hi, lo;
+
+ /* Multiplying the 32bit volume factor with the 16bit
+ * sample might result in an 48bit value. We want to
+ * do without 64 bit integers and hence do the
+ * multiplication independantly for the HI and LO part
+ * of the volume. */
+
+ hi = volumes[channel] >> 16;
+ lo = volumes[channel] & 0xFFFF;
+
+ t = (int32_t)(*samples);
+ t = ((t * lo) >> 16) + (t * hi);
+ t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
+ *samples++ = (int16_t) t;
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s16re_c(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(int16_t);
+
+ for (channel = 0; length; length--) {
+ int32_t t, hi, lo;
+
+ hi = volumes[channel] >> 16;
+ lo = volumes[channel] & 0xFFFF;
+
+ t = (int32_t) PA_INT16_SWAP(*samples);
+ t = ((t * lo) >> 16) + (t * hi);
+ t = PA_CLAMP_UNLIKELY(t, -0x8000, 0x7FFF);
+ *samples++ = PA_INT16_SWAP((int16_t) t);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_float32ne_c(float *samples, float *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(float);
+
+ for (channel = 0; length; length--) {
+ *samples++ *= volumes[channel];
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_float32re_c(float *samples, float *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(float);
+
+ for (channel = 0; length; length--) {
+ float t;
+
+ t = PA_FLOAT32_SWAP(*samples);
+ t *= volumes[channel];
+ *samples++ = PA_FLOAT32_SWAP(t);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s32ne_c(int32_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(int32_t);
+
+ for (channel = 0; length; length--) {
+ int64_t t;
+
+ t = (int64_t)(*samples);
+ t = (t * volumes[channel]) >> 16;
+ t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
+ *samples++ = (int32_t) t;
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s32re_c(int32_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(int32_t);
+
+ for (channel = 0; length; length--) {
+ int64_t t;
+
+ t = (int64_t) PA_INT32_SWAP(*samples);
+ t = (t * volumes[channel]) >> 16;
+ t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
+ *samples++ = PA_INT32_SWAP((int32_t) t);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s24ne_c(uint8_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+ uint8_t *e;
+
+ e = samples + length;
+
+ for (channel = 0; samples < e; samples += 3) {
+ int64_t t;
+
+ t = (int64_t)((int32_t) (PA_READ24NE(samples) << 8));
+ t = (t * volumes[channel]) >> 16;
+ t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
+ PA_WRITE24NE(samples, ((uint32_t) (int32_t) t) >> 8);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s24re_c(uint8_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+ uint8_t *e;
+
+ e = samples + length;
+
+ for (channel = 0; samples < e; samples += 3) {
+ int64_t t;
+
+ t = (int64_t)((int32_t) (PA_READ24RE(samples) << 8));
+ t = (t * volumes[channel]) >> 16;
+ t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
+ PA_WRITE24RE(samples, ((uint32_t) (int32_t) t) >> 8);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s24_32ne_c(uint32_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(uint32_t);
+
+ for (channel = 0; length; length--) {
+ int64_t t;
+
+ t = (int64_t) ((int32_t) (*samples << 8));
+ t = (t * volumes[channel]) >> 16;
+ t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
+ *samples++ = ((uint32_t) ((int32_t) t)) >> 8;
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static void pa_volume_s24_32re_c(uint32_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ unsigned channel;
+
+ length /= sizeof(uint32_t);
+
+ for (channel = 0; length; length--) {
+ int64_t t;
+
+ t = (int64_t) ((int32_t) (PA_UINT32_SWAP(*samples) << 8));
+ t = (t * volumes[channel]) >> 16;
+ t = PA_CLAMP_UNLIKELY(t, -0x80000000LL, 0x7FFFFFFFLL);
+ *samples++ = PA_UINT32_SWAP(((uint32_t) ((int32_t) t)) >> 8);
+
+ if (PA_UNLIKELY(++channel >= channels))
+ channel = 0;
+ }
+}
+
+static pa_do_volume_func_t do_volume_table[] = {
+ [PA_SAMPLE_U8] = (pa_do_volume_func_t) pa_volume_u8_c,
+ [PA_SAMPLE_ALAW] = (pa_do_volume_func_t) pa_volume_alaw_c,
+ [PA_SAMPLE_ULAW] = (pa_do_volume_func_t) pa_volume_ulaw_c,
+ [PA_SAMPLE_S16NE] = (pa_do_volume_func_t) pa_volume_s16ne_c,
+ [PA_SAMPLE_S16RE] = (pa_do_volume_func_t) pa_volume_s16re_c,
+ [PA_SAMPLE_FLOAT32NE] = (pa_do_volume_func_t) pa_volume_float32ne_c,
+ [PA_SAMPLE_FLOAT32RE] = (pa_do_volume_func_t) pa_volume_float32re_c,
+ [PA_SAMPLE_S32NE] = (pa_do_volume_func_t) pa_volume_s32ne_c,
+ [PA_SAMPLE_S32RE] = (pa_do_volume_func_t) pa_volume_s32re_c,
+ [PA_SAMPLE_S24NE] = (pa_do_volume_func_t) pa_volume_s24ne_c,
+ [PA_SAMPLE_S24RE] = (pa_do_volume_func_t) pa_volume_s24re_c,
+ [PA_SAMPLE_S24_32NE] = (pa_do_volume_func_t) pa_volume_s24_32ne_c,
+ [PA_SAMPLE_S24_32RE] = (pa_do_volume_func_t) pa_volume_s24_32re_c
+};
+
+pa_do_volume_func_t pa_get_volume_func(pa_sample_format_t f) {
+ pa_assert(f >= 0);
+ pa_assert(f < PA_SAMPLE_MAX);
+
+ return do_volume_table[f];
+}
+
+void pa_set_volume_func(pa_sample_format_t f, pa_do_volume_func_t func) {
+ pa_assert(f >= 0);
+ pa_assert(f < PA_SAMPLE_MAX);
+
+ do_volume_table[f] = func;
+}
diff --git a/src/pulsecore/svolume_mmx.c b/src/pulsecore/svolume_mmx.c
new file mode 100644
index 00000000..64010810
--- /dev/null
+++ b/src/pulsecore/svolume_mmx.c
@@ -0,0 +1,344 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/rtclock.h>
+
+#include <pulsecore/random.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/endianmacros.h>
+
+#include "cpu-x86.h"
+
+#include "sample-util.h"
+
+#if defined (__i386__) || defined (__amd64__)
+/* in s: 2 int16_t samples
+ * in v: 2 int32_t volumes, fixed point 16:16
+ * out s: contains scaled and clamped int16_t samples.
+ *
+ * We calculate the high 32 bits of a 32x16 multiply which we then
+ * clamp to 16 bits. The calulcation is:
+ *
+ * vl = (v & 0xffff)
+ * vh = (v >> 16)
+ * s = ((s * vl) >> 16) + (s * vh);
+ *
+ * For the first multiply we have to do a sign correction as we need to
+ * multiply a signed int with an unsigned int. Hacker's delight 8-3 gives a
+ * simple formula to correct the sign of the high word after the signed
+ * multiply.
+ */
+#define VOLUME_32x16(s,v) /* .. | vh | vl | */ \
+ " pxor %%mm4, %%mm4 \n\t" /* .. | 0 | 0 | */ \
+ " punpcklwd %%mm4, "#s" \n\t" /* .. | 0 | p0 | */ \
+ " pcmpgtw "#v", %%mm4 \n\t" /* .. | 0 | s(vl) | */ \
+ " pand "#s", %%mm4 \n\t" /* .. | 0 | (p0) | (vl >> 15) & p */ \
+ " movq "#s", %%mm5 \n\t" \
+ " pmulhw "#v", "#s" \n\t" /* .. | 0 | vl*p0 | */ \
+ " paddw %%mm4, "#s" \n\t" /* .. | 0 | vl*p0 | + sign correct */ \
+ " pslld $16, "#s" \n\t" /* .. | vl*p0 | 0 | */ \
+ " psrld $16, "#v" \n\t" /* .. | 0 | vh | */ \
+ " psrad $16, "#s" \n\t" /* .. | vl*p0 | sign extend */ \
+ " pmaddwd %%mm5, "#v" \n\t" /* .. | p0 * vh | */ \
+ " paddd "#s", "#v" \n\t" /* .. | p0 * v0 | */ \
+ " packssdw "#v", "#v" \n\t" /* .. | p1*v1 | p0*v0 | */
+
+/* approximately advances %3 = (%3 + a) % b. This function requires that
+ * a <= b. */
+#define MOD_ADD(a,b) \
+ " add "#a", %3 \n\t" \
+ " mov %3, %4 \n\t" \
+ " sub "#b", %4 \n\t" \
+ " cmovae %4, %3 \n\t"
+
+/* swap 16 bits */
+#define SWAP_16(s) \
+ " movq "#s", %%mm4 \n\t" /* .. | h l | */ \
+ " psrlw $8, %%mm4 \n\t" /* .. | 0 h | */ \
+ " psllw $8, "#s" \n\t" /* .. | l 0 | */ \
+ " por %%mm4, "#s" \n\t" /* .. | l h | */
+
+/* swap 2 registers 16 bits for better pairing */
+#define SWAP_16_2(s1,s2) \
+ " movq "#s1", %%mm4 \n\t" /* .. | h l | */ \
+ " movq "#s2", %%mm5 \n\t" \
+ " psrlw $8, %%mm4 \n\t" /* .. | 0 h | */ \
+ " psrlw $8, %%mm5 \n\t" \
+ " psllw $8, "#s1" \n\t" /* .. | l 0 | */ \
+ " psllw $8, "#s2" \n\t" \
+ " por %%mm4, "#s1" \n\t" /* .. | l h | */ \
+ " por %%mm5, "#s2" \n\t"
+
+static void pa_volume_s16ne_mmx(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ pa_reg_x86 channel, temp;
+
+ /* Channels must be at least 4, and always a multiple of the original number.
+ * This is also the max amount we overread the volume array, which should
+ * have enough padding. */
+ channels = channels == 3 ? 6 : PA_MAX (4U, channels);
+
+ __asm__ __volatile__ (
+ " xor %3, %3 \n\t"
+ " sar $1, %2 \n\t" /* length /= sizeof (int16_t) */
+
+ " test $1, %2 \n\t" /* check for odd samples */
+ " je 2f \n\t"
+
+ " movd (%1, %3, 4), %%mm0 \n\t" /* | v0h | v0l | */
+ " movw (%0), %w4 \n\t" /* .. | p0 | */
+ " movd %4, %%mm1 \n\t"
+ VOLUME_32x16 (%%mm1, %%mm0)
+ " movd %%mm0, %4 \n\t" /* .. | p0*v0 | */
+ " movw %w4, (%0) \n\t"
+ " add $2, %0 \n\t"
+ MOD_ADD ($1, %5)
+
+ "2: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 2 samples at a time */
+ " test $1, %2 \n\t" /* check for odd samples */
+ " je 4f \n\t"
+
+ "3: \n\t" /* do samples in groups of 2 */
+ " movq (%1, %3, 4), %%mm0 \n\t" /* | v1h | v1l | v0h | v0l | */
+ " movd (%0), %%mm1 \n\t" /* .. | p1 | p0 | */
+ VOLUME_32x16 (%%mm1, %%mm0)
+ " movd %%mm0, (%0) \n\t" /* .. | p1*v1 | p0*v0 | */
+ " add $4, %0 \n\t"
+ MOD_ADD ($2, %5)
+
+ "4: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 4 samples at a time */
+ " cmp $0, %2 \n\t"
+ " je 6f \n\t"
+
+ "5: \n\t" /* do samples in groups of 4 */
+ " movq (%1, %3, 4), %%mm0 \n\t" /* | v1h | v1l | v0h | v0l | */
+ " movq 8(%1, %3, 4), %%mm2 \n\t" /* | v3h | v3l | v2h | v2l | */
+ " movd (%0), %%mm1 \n\t" /* .. | p1 | p0 | */
+ " movd 4(%0), %%mm3 \n\t" /* .. | p3 | p2 | */
+ VOLUME_32x16 (%%mm1, %%mm0)
+ VOLUME_32x16 (%%mm3, %%mm2)
+ " movd %%mm0, (%0) \n\t" /* .. | p1*v1 | p0*v0 | */
+ " movd %%mm2, 4(%0) \n\t" /* .. | p3*v3 | p2*v2 | */
+ " add $8, %0 \n\t"
+ MOD_ADD ($4, %5)
+ " dec %2 \n\t"
+ " jne 5b \n\t"
+
+ "6: \n\t"
+ " emms \n\t"
+
+ : "+r" (samples), "+r" (volumes), "+r" (length), "=D" (channel), "=&r" (temp)
+#if defined (__i386__)
+ : "m" ((pa_reg_x86)channels)
+#else
+ : "r" ((pa_reg_x86)channels)
+#endif
+ : "cc"
+ );
+}
+
+static void pa_volume_s16re_mmx(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ pa_reg_x86 channel, temp;
+
+ /* Channels must be at least 4, and always a multiple of the original number.
+ * This is also the max amount we overread the volume array, which should
+ * have enough padding. */
+ channels = channels == 3 ? 6 : PA_MAX (4U, channels);
+
+ __asm__ __volatile__ (
+ " xor %3, %3 \n\t"
+ " sar $1, %2 \n\t" /* length /= sizeof (int16_t) */
+ " pcmpeqw %%mm6, %%mm6 \n\t" /* .. | ffff | ffff | */
+ " pcmpeqw %%mm7, %%mm7 \n\t" /* .. | ffff | ffff | */
+ " pslld $16, %%mm6 \n\t" /* .. | ffff | 0 | */
+ " psrld $31, %%mm7 \n\t" /* .. | 0 | 1 | */
+
+ " test $1, %2 \n\t" /* check for odd samples */
+ " je 2f \n\t"
+
+ " movd (%1, %3, 4), %%mm0 \n\t" /* | v0h | v0l | */
+ " movw (%0), %w4 \n\t" /* .. | p0 | */
+ " rorw $8, %w4 \n\t"
+ " movd %4, %%mm1 \n\t"
+ VOLUME_32x16 (%%mm1, %%mm0)
+ " movd %%mm0, %4 \n\t" /* .. | p0*v0 | */
+ " rorw $8, %w4 \n\t"
+ " movw %w4, (%0) \n\t"
+ " add $2, %0 \n\t"
+ MOD_ADD ($1, %5)
+
+ "2: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 2 samples at a time */
+ " test $1, %2 \n\t" /* check for odd samples */
+ " je 4f \n\t"
+
+ "3: \n\t" /* do samples in groups of 2 */
+ " movq (%1, %3, 4), %%mm0 \n\t" /* | v1h | v1l | v0h | v0l | */
+ " movd (%0), %%mm1 \n\t" /* .. | p1 | p0 | */
+ SWAP_16 (%%mm1)
+ VOLUME_32x16 (%%mm1, %%mm0)
+ SWAP_16 (%%mm0)
+ " movd %%mm0, (%0) \n\t" /* .. | p1*v1 | p0*v0 | */
+ " add $4, %0 \n\t"
+ MOD_ADD ($2, %5)
+
+ "4: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 4 samples at a time */
+ " cmp $0, %2 \n\t"
+ " je 6f \n\t"
+
+ "5: \n\t" /* do samples in groups of 4 */
+ " movq (%1, %3, 4), %%mm0 \n\t" /* | v1h | v1l | v0h | v0l | */
+ " movq 8(%1, %3, 4), %%mm2 \n\t" /* | v3h | v3l | v2h | v2l | */
+ " movd (%0), %%mm1 \n\t" /* .. | p1 | p0 | */
+ " movd 4(%0), %%mm3 \n\t" /* .. | p3 | p2 | */
+ SWAP_16_2 (%%mm1, %%mm3)
+ VOLUME_32x16 (%%mm1, %%mm0)
+ VOLUME_32x16 (%%mm3, %%mm2)
+ SWAP_16_2 (%%mm0, %%mm2)
+ " movd %%mm0, (%0) \n\t" /* .. | p1*v1 | p0*v0 | */
+ " movd %%mm2, 4(%0) \n\t" /* .. | p3*v3 | p2*v2 | */
+ " add $8, %0 \n\t"
+ MOD_ADD ($4, %5)
+ " dec %2 \n\t"
+ " jne 5b \n\t"
+
+ "6: \n\t"
+ " emms \n\t"
+
+ : "+r" (samples), "+r" (volumes), "+r" (length), "=D" (channel), "=&r" (temp)
+#if defined (__i386__)
+ : "m" ((pa_reg_x86)channels)
+#else
+ : "r" ((pa_reg_x86)channels)
+#endif
+ : "cc"
+ );
+}
+
+#undef RUN_TEST
+
+#ifdef RUN_TEST
+#define CHANNELS 2
+#define SAMPLES 1022
+#define TIMES 1000
+#define TIMES2 100
+#define PADDING 16
+
+static void run_test(void) {
+ int16_t samples[SAMPLES];
+ int16_t samples_ref[SAMPLES];
+ int16_t samples_orig[SAMPLES];
+ int32_t volumes[CHANNELS + PADDING];
+ int i, j, padding;
+ pa_do_volume_func_t func;
+ pa_usec_t start, stop;
+ int k;
+ pa_usec_t min = INT_MAX, max = 0;
+ double s1 = 0, s2 = 0;
+
+ func = pa_get_volume_func(PA_SAMPLE_S16NE);
+
+ printf("checking MMX %zd\n", sizeof(samples));
+
+ pa_random(samples, sizeof(samples));
+ /* for (i = 0; i < SAMPLES; i++)
+ samples[i] = -1; */
+ memcpy(samples_ref, samples, sizeof(samples));
+ memcpy(samples_orig, samples, sizeof(samples));
+
+ for (i = 0; i < CHANNELS; i++)
+ volumes[i] = PA_CLAMP_VOLUME(rand() >> 1);
+ /* volumes[i] = 0x0000ffff; */
+ for (padding = 0; padding < PADDING; padding++, i++)
+ volumes[i] = volumes[padding];
+
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ pa_volume_s16ne_mmx(samples, volumes, CHANNELS, sizeof(samples));
+ for (i = 0; i < SAMPLES; i++) {
+ if (samples[i] != samples_ref[i]) {
+ printf("%d: %04x != %04x (%04x * %08x)\n", i, samples[i], samples_ref[i],
+ samples_orig[i], volumes[i % CHANNELS]);
+ }
+ }
+
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples, samples_orig, sizeof(samples));
+ pa_volume_s16ne_mmx(samples, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("MMX: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ min = INT_MAX; max = 0;
+ s1 = s2 = 0;
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples_ref, samples_orig, sizeof(samples));
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("ref: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ pa_assert_se(memcmp(samples_ref, samples, sizeof(samples)) == 0);
+}
+#endif
+
+#endif /* defined (__i386__) || defined (__amd64__) */
+
+
+void pa_volume_func_init_mmx(pa_cpu_x86_flag_t flags) {
+#if defined (__i386__) || defined (__amd64__)
+
+#ifdef RUN_TEST
+ run_test();
+#endif
+
+ if ((flags & PA_CPU_X86_MMX) && (flags & PA_CPU_X86_CMOV)) {
+ pa_log_info("Initialising MMX optimized functions.");
+
+ pa_set_volume_func(PA_SAMPLE_S16NE, (pa_do_volume_func_t) pa_volume_s16ne_mmx);
+ pa_set_volume_func(PA_SAMPLE_S16RE, (pa_do_volume_func_t) pa_volume_s16re_mmx);
+ }
+#endif /* defined (__i386__) || defined (__amd64__) */
+}
diff --git a/src/pulsecore/svolume_orc.c b/src/pulsecore/svolume_orc.c
new file mode 100644
index 00000000..8e1e46cf
--- /dev/null
+++ b/src/pulsecore/svolume_orc.c
@@ -0,0 +1,138 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+ Copyright 2010 Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "cpu-orc.h"
+#include <pulse/rtclock.h>
+#include <pulsecore/sample-util.h>
+#include <pulsecore/random.h>
+#include <pulsecore/svolume-orc-gen.h>
+
+pa_do_volume_func_t fallback;
+
+static void
+pa_volume_s16ne_orc(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length)
+{
+ if (channels == 2) {
+ int64_t v = (int64_t)volumes[1] << 32 | volumes[0];
+ pa_volume_s16ne_orc_2ch (samples, v, ((length / (sizeof(int16_t))) / 2));
+ } else if (channels == 1)
+ pa_volume_s16ne_orc_1ch (samples, volumes[0], length / (sizeof(int16_t)));
+ else
+ fallback(samples, volumes, channels, length);
+}
+
+#undef RUN_TEST
+
+#ifdef RUN_TEST
+#define CHANNELS 2
+#define SAMPLES 1022
+#define TIMES 1000
+#define TIMES2 100
+#define PADDING 16
+
+static void run_test(void) {
+ int16_t samples[SAMPLES];
+ int16_t samples_ref[SAMPLES];
+ int16_t samples_orig[SAMPLES];
+ int32_t volumes[CHANNELS + PADDING];
+ int i, j, padding;
+ pa_do_volume_func_t func;
+ pa_usec_t start, stop;
+ int k;
+ pa_usec_t min = INT_MAX, max = 0;
+ double s1 = 0, s2 = 0;
+
+ func = pa_get_volume_func(PA_SAMPLE_S16NE);
+
+ printf("checking ORC %zd\n", sizeof(samples));
+
+ pa_random(samples, sizeof(samples));
+ memcpy(samples_ref, samples, sizeof(samples));
+ memcpy(samples_orig, samples, sizeof(samples));
+
+ for (i = 0; i < CHANNELS; i++)
+ volumes[i] = PA_CLAMP_VOLUME(rand() >> 1);
+ for (padding = 0; padding < PADDING; padding++, i++)
+ volumes[i] = volumes[padding];
+
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ pa_volume_s16ne_orc(samples, volumes, CHANNELS, sizeof(samples));
+ for (i = 0; i < SAMPLES; i++) {
+ if (samples[i] != samples_ref[i]) {
+ printf ("%d: %04x != %04x (%04x * %04x)\n", i, samples[i], samples_ref[i],
+ samples_orig[i], volumes[i % CHANNELS]);
+ }
+ }
+
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples, samples_orig, sizeof(samples));
+ pa_volume_s16ne_orc(samples, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("ORC: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ min = INT_MAX; max = 0;
+ s1 = s2 = 0;
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples_ref, samples_orig, sizeof(samples));
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("ref: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ pa_assert_se(memcmp(samples_ref, samples, sizeof(samples)) == 0);
+}
+#endif
+
+void pa_volume_func_init_orc(void) {
+ pa_log_info("Initialising ORC optimized functions.");
+
+#ifdef RUN_TEST
+ run_test();
+#endif
+
+ fallback = pa_get_volume_func(PA_SAMPLE_S16NE);
+ pa_set_volume_func(PA_SAMPLE_S16NE, (pa_do_volume_func_t) pa_volume_s16ne_orc);
+}
diff --git a/src/pulsecore/svolume_sse.c b/src/pulsecore/svolume_sse.c
new file mode 100644
index 00000000..f713761a
--- /dev/null
+++ b/src/pulsecore/svolume_sse.c
@@ -0,0 +1,351 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2004-2006 Lennart Poettering
+ Copyright 2009 Wim Taymans <wim.taymans@collabora.co.uk>
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulse/rtclock.h>
+
+#include <pulsecore/random.h>
+#include <pulsecore/macro.h>
+#include <pulsecore/endianmacros.h>
+
+#include "cpu-x86.h"
+
+#include "sample-util.h"
+
+#if defined (__i386__) || defined (__amd64__)
+
+#define VOLUME_32x16(s,v) /* .. | vh | vl | */ \
+ " pxor %%xmm4, %%xmm4 \n\t" /* .. | 0 | 0 | */ \
+ " punpcklwd %%xmm4, "#s" \n\t" /* .. | 0 | p0 | */ \
+ " pcmpgtw "#s", %%xmm4 \n\t" /* .. | 0 | s(p0) | */ \
+ " pand "#v", %%xmm4 \n\t" /* .. | 0 | (vl) | */ \
+ " movdqa "#s", %%xmm5 \n\t" \
+ " pmulhuw "#v", "#s" \n\t" /* .. | 0 | vl*p0 | */ \
+ " psubd %%xmm4, "#s" \n\t" /* .. | 0 | vl*p0 | + sign correct */ \
+ " psrld $16, "#v" \n\t" /* .. | 0 | vh | */ \
+ " pmaddwd %%xmm5, "#v" \n\t" /* .. | p0 * vh | */ \
+ " paddd "#s", "#v" \n\t" /* .. | p0 * v0 | */ \
+ " packssdw "#v", "#v" \n\t" /* .. | p1*v1 | p0*v0 | */
+
+#define MOD_ADD(a,b) \
+ " add "#a", %3 \n\t" /* channel += inc */ \
+ " mov %3, %4 \n\t" \
+ " sub "#b", %4 \n\t" /* tmp = channel - channels */ \
+ " cmovae %4, %3 \n\t" /* if (tmp >= 0) channel = tmp */
+
+/* swap 16 bits */
+#define SWAP_16(s) \
+ " movdqa "#s", %%xmm4 \n\t" /* .. | h l | */ \
+ " psrlw $8, %%xmm4 \n\t" /* .. | 0 h | */ \
+ " psllw $8, "#s" \n\t" /* .. | l 0 | */ \
+ " por %%xmm4, "#s" \n\t" /* .. | l h | */
+
+/* swap 2 registers 16 bits for better pairing */
+#define SWAP_16_2(s1,s2) \
+ " movdqa "#s1", %%xmm4 \n\t" /* .. | h l | */ \
+ " movdqa "#s2", %%xmm5 \n\t" \
+ " psrlw $8, %%xmm4 \n\t" /* .. | 0 h | */ \
+ " psrlw $8, %%xmm5 \n\t" \
+ " psllw $8, "#s1" \n\t" /* .. | l 0 | */ \
+ " psllw $8, "#s2" \n\t" \
+ " por %%xmm4, "#s1" \n\t" /* .. | l h | */ \
+ " por %%xmm5, "#s2" \n\t"
+
+
+static int channel_overread_table[8] = {8,8,8,12,8,10,12,14};
+
+static void pa_volume_s16ne_sse2(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ pa_reg_x86 channel, temp;
+
+ /* Channels must be at least 8 and always a multiple of the original number.
+ * This is also the max amount we overread the volume array, which should
+ * have enough padding. */
+ if (channels < 8)
+ channels = channel_overread_table[channels];
+
+ __asm__ __volatile__ (
+ " xor %3, %3 \n\t"
+ " sar $1, %2 \n\t" /* length /= sizeof (int16_t) */
+
+ " test $1, %2 \n\t" /* check for odd samples */
+ " je 2f \n\t"
+
+ " movd (%1, %3, 4), %%xmm0 \n\t" /* | v0h | v0l | */
+ " movw (%0), %w4 \n\t" /* .. | p0 | */
+ " movd %4, %%xmm1 \n\t"
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ " movd %%xmm0, %4 \n\t" /* .. | p0*v0 | */
+ " movw %w4, (%0) \n\t"
+ " add $2, %0 \n\t"
+ MOD_ADD ($1, %5)
+
+ "2: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 2 samples at a time */
+ " test $1, %2 \n\t"
+ " je 4f \n\t"
+
+ "3: \n\t" /* do samples in groups of 2 */
+ " movq (%1, %3, 4), %%xmm0 \n\t" /* | v1h | v1l | v0h | v0l | */
+ " movd (%0), %%xmm1 \n\t" /* .. | p1 | p0 | */
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ " movd %%xmm0, (%0) \n\t" /* .. | p1*v1 | p0*v0 | */
+ " add $4, %0 \n\t"
+ MOD_ADD ($2, %5)
+
+ "4: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 4 samples at a time */
+ " test $1, %2 \n\t"
+ " je 6f \n\t"
+
+ /* FIXME, we can do aligned access of the volume values if we can guarantee
+ * that the array is 16 bytes aligned, we probably have to do the odd values
+ * after this then. */
+ "5: \n\t" /* do samples in groups of 4 */
+ " movdqu (%1, %3, 4), %%xmm0 \n\t" /* | v3h | v3l .. v0h | v0l | */
+ " movq (%0), %%xmm1 \n\t" /* .. | p3 .. p0 | */
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ " movq %%xmm0, (%0) \n\t" /* .. | p3*v3 .. p0*v0 | */
+ " add $8, %0 \n\t"
+ MOD_ADD ($4, %5)
+
+ "6: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 8 samples at a time */
+ " cmp $0, %2 \n\t"
+ " je 8f \n\t"
+
+ "7: \n\t" /* do samples in groups of 8 */
+ " movdqu (%1, %3, 4), %%xmm0 \n\t" /* | v3h | v3l .. v0h | v0l | */
+ " movdqu 16(%1, %3, 4), %%xmm2 \n\t" /* | v7h | v7l .. v4h | v4l | */
+ " movq (%0), %%xmm1 \n\t" /* .. | p3 .. p0 | */
+ " movq 8(%0), %%xmm3 \n\t" /* .. | p7 .. p4 | */
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ VOLUME_32x16 (%%xmm3, %%xmm2)
+ " movq %%xmm0, (%0) \n\t" /* .. | p3*v3 .. p0*v0 | */
+ " movq %%xmm2, 8(%0) \n\t" /* .. | p7*v7 .. p4*v4 | */
+ " add $16, %0 \n\t"
+ MOD_ADD ($8, %5)
+ " dec %2 \n\t"
+ " jne 7b \n\t"
+ "8: \n\t"
+
+ : "+r" (samples), "+r" (volumes), "+r" (length), "=D" (channel), "=&r" (temp)
+#if defined (__i386__)
+ : "m" ((pa_reg_x86)channels)
+#else
+ : "r" ((pa_reg_x86)channels)
+#endif
+ : "cc"
+ );
+}
+
+static void pa_volume_s16re_sse2(int16_t *samples, int32_t *volumes, unsigned channels, unsigned length) {
+ pa_reg_x86 channel, temp;
+
+ /* Channels must be at least 8 and always a multiple of the original number.
+ * This is also the max amount we overread the volume array, which should
+ * have enough padding. */
+ if (channels < 8)
+ channels = channel_overread_table[channels];
+
+ __asm__ __volatile__ (
+ " xor %3, %3 \n\t"
+ " sar $1, %2 \n\t" /* length /= sizeof (int16_t) */
+
+ " test $1, %2 \n\t" /* check for odd samples */
+ " je 2f \n\t"
+
+ " movd (%1, %3, 4), %%xmm0 \n\t" /* | v0h | v0l | */
+ " movw (%0), %w4 \n\t" /* .. | p0 | */
+ " rorw $8, %w4 \n\t"
+ " movd %4, %%xmm1 \n\t"
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ " movd %%xmm0, %4 \n\t" /* .. | p0*v0 | */
+ " rorw $8, %w4 \n\t"
+ " movw %w4, (%0) \n\t"
+ " add $2, %0 \n\t"
+ MOD_ADD ($1, %5)
+
+ "2: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 2 samples at a time */
+ " test $1, %2 \n\t"
+ " je 4f \n\t"
+
+ "3: \n\t" /* do samples in groups of 2 */
+ " movq (%1, %3, 4), %%xmm0 \n\t" /* | v1h | v1l | v0h | v0l | */
+ " movd (%0), %%xmm1 \n\t" /* .. | p1 | p0 | */
+ SWAP_16 (%%xmm1)
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ SWAP_16 (%%xmm0)
+ " movd %%xmm0, (%0) \n\t" /* .. | p1*v1 | p0*v0 | */
+ " add $4, %0 \n\t"
+ MOD_ADD ($2, %5)
+
+ "4: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 4 samples at a time */
+ " test $1, %2 \n\t"
+ " je 6f \n\t"
+
+ /* FIXME, we can do aligned access of the volume values if we can guarantee
+ * that the array is 16 bytes aligned, we probably have to do the odd values
+ * after this then. */
+ "5: \n\t" /* do samples in groups of 4 */
+ " movdqu (%1, %3, 4), %%xmm0 \n\t" /* | v3h | v3l .. v0h | v0l | */
+ " movq (%0), %%xmm1 \n\t" /* .. | p3 .. p0 | */
+ SWAP_16 (%%xmm1)
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ SWAP_16 (%%xmm0)
+ " movq %%xmm0, (%0) \n\t" /* .. | p3*v3 .. p0*v0 | */
+ " add $8, %0 \n\t"
+ MOD_ADD ($4, %5)
+
+ "6: \n\t"
+ " sar $1, %2 \n\t" /* prepare for processing 8 samples at a time */
+ " cmp $0, %2 \n\t"
+ " je 8f \n\t"
+
+ "7: \n\t" /* do samples in groups of 8 */
+ " movdqu (%1, %3, 4), %%xmm0 \n\t" /* | v3h | v3l .. v0h | v0l | */
+ " movdqu 16(%1, %3, 4), %%xmm2 \n\t" /* | v7h | v7l .. v4h | v4l | */
+ " movq (%0), %%xmm1 \n\t" /* .. | p3 .. p0 | */
+ " movq 8(%0), %%xmm3 \n\t" /* .. | p7 .. p4 | */
+ SWAP_16_2 (%%xmm1, %%xmm3)
+ VOLUME_32x16 (%%xmm1, %%xmm0)
+ VOLUME_32x16 (%%xmm3, %%xmm2)
+ SWAP_16_2 (%%xmm0, %%xmm2)
+ " movq %%xmm0, (%0) \n\t" /* .. | p3*v3 .. p0*v0 | */
+ " movq %%xmm2, 8(%0) \n\t" /* .. | p7*v7 .. p4*v4 | */
+ " add $16, %0 \n\t"
+ MOD_ADD ($8, %5)
+ " dec %2 \n\t"
+ " jne 7b \n\t"
+ "8: \n\t"
+
+ : "+r" (samples), "+r" (volumes), "+r" (length), "=D" (channel), "=&r" (temp)
+#if defined (__i386__)
+ : "m" ((pa_reg_x86)channels)
+#else
+ : "r" ((pa_reg_x86)channels)
+#endif
+ : "cc"
+ );
+}
+
+#undef RUN_TEST
+
+#ifdef RUN_TEST
+#define CHANNELS 2
+#define SAMPLES 1022
+#define TIMES 1000
+#define TIMES2 100
+#define PADDING 16
+
+static void run_test(void) {
+ int16_t samples[SAMPLES];
+ int16_t samples_ref[SAMPLES];
+ int16_t samples_orig[SAMPLES];
+ int32_t volumes[CHANNELS + PADDING];
+ int i, j, padding;
+ pa_do_volume_func_t func;
+ pa_usec_t start, stop;
+ int k;
+ pa_usec_t min = INT_MAX, max = 0;
+ double s1 = 0, s2 = 0;
+
+ func = pa_get_volume_func(PA_SAMPLE_S16NE);
+
+ printf("checking SSE2 %zd\n", sizeof(samples));
+
+ pa_random(samples, sizeof(samples));
+ memcpy(samples_ref, samples, sizeof(samples));
+ memcpy(samples_orig, samples, sizeof(samples));
+
+ for (i = 0; i < CHANNELS; i++)
+ volumes[i] = PA_CLAMP_VOLUME(rand() >> 1);
+ for (padding = 0; padding < PADDING; padding++, i++)
+ volumes[i] = volumes[padding];
+
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ pa_volume_s16ne_sse2(samples, volumes, CHANNELS, sizeof(samples));
+ for (i = 0; i < SAMPLES; i++) {
+ if (samples[i] != samples_ref[i]) {
+ printf ("%d: %04x != %04x (%04x * %04x)\n", i, samples[i], samples_ref[i],
+ samples_orig[i], volumes[i % CHANNELS]);
+ }
+ }
+
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples, samples_orig, sizeof(samples));
+ pa_volume_s16ne_sse2(samples, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("SSE: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ min = INT_MAX; max = 0;
+ s1 = s2 = 0;
+ for (k = 0; k < TIMES2; k++) {
+ start = pa_rtclock_now();
+ for (j = 0; j < TIMES; j++) {
+ memcpy(samples_ref, samples_orig, sizeof(samples));
+ func(samples_ref, volumes, CHANNELS, sizeof(samples));
+ }
+ stop = pa_rtclock_now();
+
+ if (min > (stop - start)) min = stop - start;
+ if (max < (stop - start)) max = stop - start;
+ s1 += stop - start;
+ s2 += (stop - start) * (stop - start);
+ }
+ pa_log_info("ref: %llu usec (min = %llu, max = %llu, stddev = %g).", (long long unsigned int)s1,
+ (long long unsigned int)min, (long long unsigned int)max, sqrt(TIMES2 * s2 - s1 * s1) / TIMES2);
+
+ pa_assert_se(memcmp(samples_ref, samples, sizeof(samples)) == 0);
+}
+#endif
+#endif /* defined (__i386__) || defined (__amd64__) */
+
+void pa_volume_func_init_sse(pa_cpu_x86_flag_t flags) {
+#if defined (__i386__) || defined (__amd64__)
+
+#ifdef RUN_TEST
+ run_test();
+#endif
+
+ if (flags & PA_CPU_X86_SSE2) {
+ pa_log_info("Initialising SSE2 optimized functions.");
+
+ pa_set_volume_func(PA_SAMPLE_S16NE, (pa_do_volume_func_t) pa_volume_s16ne_sse2);
+ pa_set_volume_func(PA_SAMPLE_S16RE, (pa_do_volume_func_t) pa_volume_s16re_sse2);
+ }
+#endif /* defined (__i386__) || defined (__amd64__) */
+}
diff --git a/src/pulsecore/tagstruct.c b/src/pulsecore/tagstruct.c
index 330b7596..a0f1f101 100644
--- a/src/pulsecore/tagstruct.c
+++ b/src/pulsecore/tagstruct.c
@@ -35,7 +35,7 @@
#include <pulse/xmalloc.h>
-#include <pulsecore/winsock.h>
+#include <pulsecore/socket.h>
#include <pulsecore/macro.h>
#include "tagstruct.h"
@@ -228,6 +228,7 @@ void pa_tagstruct_put_channel_map(pa_tagstruct *t, const pa_channel_map *map) {
unsigned i;
pa_assert(t);
+ pa_assert(map);
extend(t, 2 + (size_t) map->channels);
t->data[t->length++] = PA_TAG_CHANNEL_MAP;
@@ -242,6 +243,7 @@ void pa_tagstruct_put_cvolume(pa_tagstruct *t, const pa_cvolume *cvolume) {
pa_volume_t vol;
pa_assert(t);
+ pa_assert(cvolume);
extend(t, 2 + cvolume->channels * sizeof(pa_volume_t));
t->data[t->length++] = PA_TAG_CVOLUME;
@@ -291,6 +293,17 @@ void pa_tagstruct_put_proplist(pa_tagstruct *t, pa_proplist *p) {
pa_tagstruct_puts(t, NULL);
}
+void pa_tagstruct_put_format_info(pa_tagstruct *t, pa_format_info *f) {
+ pa_assert(t);
+ pa_assert(f);
+
+ extend(t, 1);
+
+ t->data[t->length++] = PA_TAG_FORMAT_INFO;
+ pa_tagstruct_putu8(t, (uint8_t) f->encoding);
+ pa_tagstruct_put_proplist(t, f->plist);
+}
+
int pa_tagstruct_gets(pa_tagstruct*t, const char **s) {
int error = 0;
size_t n;
@@ -631,6 +644,37 @@ fail:
return -1;
}
+int pa_tagstruct_get_format_info(pa_tagstruct *t, pa_format_info *f) {
+ size_t saved_rindex;
+ uint8_t encoding;
+
+ pa_assert(t);
+ pa_assert(f);
+
+ if (t->rindex+1 > t->length)
+ return -1;
+
+ if (t->data[t->rindex] != PA_TAG_FORMAT_INFO)
+ return -1;
+
+ saved_rindex = t->rindex;
+ t->rindex++;
+
+ if (pa_tagstruct_getu8(t, &encoding) < 0)
+ goto fail;
+
+ f->encoding = encoding;
+
+ if (pa_tagstruct_get_proplist(t, f->plist) < 0)
+ goto fail;
+
+ return 0;
+
+fail:
+ t->rindex = saved_rindex;
+ return -1;
+}
+
void pa_tagstruct_put(pa_tagstruct *t, ...) {
va_list va;
pa_assert(t);
diff --git a/src/pulsecore/tagstruct.h b/src/pulsecore/tagstruct.h
index 1a99e924..5f729bc6 100644
--- a/src/pulsecore/tagstruct.h
+++ b/src/pulsecore/tagstruct.h
@@ -25,13 +25,12 @@
#include <inttypes.h>
#include <sys/types.h>
#include <sys/time.h>
-#include <time.h>
#include <pulse/sample.h>
+#include <pulse/format.h>
#include <pulse/channelmap.h>
#include <pulse/volume.h>
#include <pulse/proplist.h>
-#include <pulse/gccmacro.h>
#include <pulsecore/macro.h>
@@ -59,7 +58,8 @@ enum {
PA_TAG_CHANNEL_MAP = 'm',
PA_TAG_CVOLUME = 'v',
PA_TAG_PROPLIST = 'P',
- PA_TAG_VOLUME = 'V'
+ PA_TAG_VOLUME = 'V',
+ PA_TAG_FORMAT_INFO = 'f',
};
pa_tagstruct *pa_tagstruct_new(const uint8_t* data, size_t length);
@@ -85,6 +85,7 @@ void pa_tagstruct_put_channel_map(pa_tagstruct *t, const pa_channel_map *map);
void pa_tagstruct_put_cvolume(pa_tagstruct *t, const pa_cvolume *cvolume);
void pa_tagstruct_put_proplist(pa_tagstruct *t, pa_proplist *p);
void pa_tagstruct_put_volume(pa_tagstruct *t, pa_volume_t volume);
+void pa_tagstruct_put_format_info(pa_tagstruct *t, pa_format_info *f);
int pa_tagstruct_get(pa_tagstruct *t, ...);
@@ -102,5 +103,6 @@ int pa_tagstruct_get_channel_map(pa_tagstruct *t, pa_channel_map *map);
int pa_tagstruct_get_cvolume(pa_tagstruct *t, pa_cvolume *v);
int pa_tagstruct_get_proplist(pa_tagstruct *t, pa_proplist *p);
int pa_tagstruct_get_volume(pa_tagstruct *t, pa_volume_t *v);
+int pa_tagstruct_get_format_info(pa_tagstruct *t, pa_format_info *f);
#endif
diff --git a/src/pulsecore/thread-mq.c b/src/pulsecore/thread-mq.c
index 34f92a7e..51fb765b 100644
--- a/src/pulsecore/thread-mq.c
+++ b/src/pulsecore/thread-mq.c
@@ -26,16 +26,9 @@
#include <unistd.h>
#include <errno.h>
-#include <pulse/xmalloc.h>
-
-#include <pulsecore/atomic.h>
-#include <pulsecore/once.h>
-#include <pulsecore/log.h>
#include <pulsecore/thread.h>
#include <pulsecore/semaphore.h>
#include <pulsecore/macro.h>
-#include <pulsecore/core-util.h>
-#include <pulsecore/flist.h>
#include "thread-mq.h"
@@ -59,7 +52,7 @@ static void asyncmsgq_read_cb(pa_mainloop_api*api, pa_io_event* e, int fd, pa_io
pa_memchunk chunk;
/* Check whether there is a message for us to process */
- while (pa_asyncmsgq_get(aq, &object, &code, &data, &offset, &chunk, 0) == 0) {
+ while (pa_asyncmsgq_get(aq, &object, &code, &data, &offset, &chunk, 0) >= 0) {
int ret;
ret = pa_asyncmsgq_dispatch(object, code, data, offset, &chunk);
@@ -104,6 +97,15 @@ void pa_thread_mq_init(pa_thread_mq *q, pa_mainloop_api *mainloop, pa_rtpoll *rt
void pa_thread_mq_done(pa_thread_mq *q) {
pa_assert(q);
+ /* Since we are called from main context we can be sure that the
+ * inq is empty. However, the outq might still contain messages
+ * for the main loop, which we need to dispatch (e.g. release
+ * msgs, other stuff). Hence do so if we aren't currently
+ * dispatching anyway. */
+
+ if (!pa_asyncmsgq_dispatching(q->outq))
+ pa_asyncmsgq_flush(q->outq, TRUE);
+
q->mainloop->io_free(q->read_event);
q->mainloop->io_free(q->write_event);
q->read_event = q->write_event = NULL;
diff --git a/src/pulsecore/thread-mq.h b/src/pulsecore/thread-mq.h
index 3b5e0e78..a1f4b3fe 100644
--- a/src/pulsecore/thread-mq.h
+++ b/src/pulsecore/thread-mq.h
@@ -27,7 +27,7 @@
#include <pulsecore/rtpoll.h>
/* Two way communication between a thread and a mainloop. Before the
- * thread is started a pa_pthread_mq should be initialized and than
+ * thread is started a pa_thread_mq should be initialized and than
* attached to the thread using pa_thread_mq_install(). */
typedef struct pa_thread_mq {
@@ -45,4 +45,12 @@ void pa_thread_mq_install(pa_thread_mq *q);
/* Return the pa_thread_mq object that is set for the current thread */
pa_thread_mq *pa_thread_mq_get(void);
+/* Verify that we are in control context (aka 'main context'). */
+#define pa_assert_ctl_context(s) \
+ pa_assert(!pa_thread_mq_get())
+
+/* Verify that we are in IO context (aka 'thread context'). */
+#define pa_assert_io_context(s) \
+ pa_assert(pa_thread_mq_get())
+
#endif
diff --git a/src/pulsecore/thread-posix.c b/src/pulsecore/thread-posix.c
index fdab270f..3f4ae5c6 100644
--- a/src/pulsecore/thread-posix.c
+++ b/src/pulsecore/thread-posix.c
@@ -28,9 +28,11 @@
#include <sched.h>
#include <errno.h>
+#ifdef __linux__
+#include <sys/prctl.h>
+#endif
+
#include <pulse/xmalloc.h>
-#include <pulsecore/mutex.h>
-#include <pulsecore/once.h>
#include <pulsecore/atomic.h>
#include <pulsecore/macro.h>
@@ -42,6 +44,7 @@ struct pa_thread {
void *userdata;
pa_atomic_t running;
pa_bool_t joined;
+ char *name;
};
struct pa_tls {
@@ -53,9 +56,11 @@ static void thread_free_cb(void *p) {
pa_assert(t);
- if (!t->thread_func)
+ if (!t->thread_func) {
/* This is a foreign thread, we need to free the struct */
+ pa_xfree(t->name);
pa_xfree(t);
+ }
}
PA_STATIC_TLS_DECLARE(current_thread, thread_free_cb);
@@ -64,6 +69,12 @@ static void* internal_thread_func(void *userdata) {
pa_thread *t = userdata;
pa_assert(t);
+#ifdef __linux__
+ prctl(PR_SET_NAME, t->name);
+#elif defined(HAVE_PTHREAD_SETNAME_NP) && defined(OS_IS_DARWIN)
+ pthread_setname_np(t->name);
+#endif
+
t->id = pthread_self();
PA_STATIC_TLS_SET(current_thread, t);
@@ -75,16 +86,15 @@ static void* internal_thread_func(void *userdata) {
return NULL;
}
-pa_thread* pa_thread_new(pa_thread_func_t thread_func, void *userdata) {
+pa_thread* pa_thread_new(const char *name, pa_thread_func_t thread_func, void *userdata) {
pa_thread *t;
pa_assert(thread_func);
- t = pa_xnew(pa_thread, 1);
+ t = pa_xnew0(pa_thread, 1);
+ t->name = pa_xstrdup(name);
t->thread_func = thread_func;
t->userdata = userdata;
- t->joined = FALSE;
- pa_atomic_store(&t->running, 0);
if (pthread_create(&t->id, NULL, internal_thread_func, t) < 0) {
pa_xfree(t);
@@ -112,6 +122,8 @@ void pa_thread_free(pa_thread *t) {
pa_assert(t);
pa_thread_join(t);
+
+ pa_xfree(t->name);
pa_xfree(t);
}
@@ -135,10 +147,8 @@ pa_thread* pa_thread_self(void) {
/* This is a foreign thread, let's create a pthread structure to
* make sure that we can always return a sensible pointer */
- t = pa_xnew(pa_thread, 1);
+ t = pa_xnew0(pa_thread, 1);
t->id = pthread_self();
- t->thread_func = NULL;
- t->userdata = NULL;
t->joined = TRUE;
pa_atomic_store(&t->running, 2);
@@ -159,6 +169,43 @@ void pa_thread_set_data(pa_thread *t, void *userdata) {
t->userdata = userdata;
}
+void pa_thread_set_name(pa_thread *t, const char *name) {
+ pa_assert(t);
+
+ pa_xfree(t->name);
+ t->name = pa_xstrdup(name);
+
+#ifdef __linux__
+ prctl(PR_SET_NAME, name);
+#elif defined(HAVE_PTHREAD_SETNAME_NP) && defined(OS_IS_DARWIN)
+ pthread_setname_np(name);
+#endif
+}
+
+const char *pa_thread_get_name(pa_thread *t) {
+ pa_assert(t);
+
+#ifdef __linux__
+ if (!t->name) {
+ t->name = pa_xmalloc(17);
+
+ if (prctl(PR_GET_NAME, t->name) >= 0)
+ t->name[16] = 0;
+ else {
+ pa_xfree(t->name);
+ t->name = NULL;
+ }
+ }
+#elif defined(HAVE_PTHREAD_GETNAME_NP) && defined(OS_IS_DARWIN)
+ if (!t->name) {
+ t->name = pa_xmalloc0(17);
+ pthread_getname_np(t->id, t->name, 16);
+ }
+#endif
+
+ return t->name;
+}
+
void pa_thread_yield(void) {
#ifdef HAVE_PTHREAD_YIELD
pthread_yield();
diff --git a/src/pulsecore/thread-win32.c b/src/pulsecore/thread-win32.c
index 0a1baa54..89c8c463 100644
--- a/src/pulsecore/thread-win32.c
+++ b/src/pulsecore/thread-win32.c
@@ -28,7 +28,6 @@
#include <windows.h>
#include <pulse/xmalloc.h>
-#include <pulsecore/log.h>
#include <pulsecore/once.h>
#include "thread.h"
@@ -71,8 +70,9 @@ static DWORD WINAPI internal_thread_func(LPVOID param) {
return 0;
}
-pa_thread* pa_thread_new(pa_thread_func_t thread_func, void *userdata) {
+pa_thread* pa_thread_new(const char *name, pa_thread_func_t thread_func, void *userdata) {
pa_thread *t;
+ DWORD thread_id;
assert(thread_func);
@@ -80,7 +80,7 @@ pa_thread* pa_thread_new(pa_thread_func_t thread_func, void *userdata) {
t->thread_func = thread_func;
t->userdata = userdata;
- t->thread = CreateThread(NULL, 0, internal_thread_func, t, 0, NULL);
+ t->thread = CreateThread(NULL, 0, internal_thread_func, t, 0, &thread_id);
if (!t->thread) {
pa_xfree(t);
@@ -123,6 +123,27 @@ pa_thread* pa_thread_self(void) {
return pa_tls_get(thread_tls);
}
+void* pa_thread_get_data(pa_thread *t) {
+ pa_assert(t);
+
+ return t->userdata;
+}
+
+void pa_thread_set_data(pa_thread *t, void *userdata) {
+ pa_assert(t);
+
+ t->userdata = userdata;
+}
+
+void pa_thread_set_name(pa_thread *t, const char *name) {
+ /* Not implemented */
+}
+
+const char *pa_thread_get_name(pa_thread *t) {
+ /* Not implemented */
+ return NULL;
+}
+
void pa_thread_yield(void) {
Sleep(0);
}
diff --git a/src/pulsecore/thread.h b/src/pulsecore/thread.h
index 25eace63..9cabb899 100644
--- a/src/pulsecore/thread.h
+++ b/src/pulsecore/thread.h
@@ -24,6 +24,8 @@
***/
#include <pulse/def.h>
+#include <pulse/gccmacro.h>
+
#include <pulsecore/once.h>
#include <pulsecore/core-util.h>
@@ -35,7 +37,7 @@ typedef struct pa_thread pa_thread;
typedef void (*pa_thread_func_t) (void *userdata);
-pa_thread* pa_thread_new(pa_thread_func_t thread_func, void *userdata);
+pa_thread* pa_thread_new(const char *name, pa_thread_func_t thread_func, void *userdata);
void pa_thread_free(pa_thread *t);
int pa_thread_join(pa_thread *t);
int pa_thread_is_running(pa_thread *t);
@@ -45,6 +47,9 @@ void pa_thread_yield(void);
void* pa_thread_get_data(pa_thread *t);
void pa_thread_set_data(pa_thread *t, void *userdata);
+const char *pa_thread_get_name(pa_thread *t);
+void pa_thread_set_name(pa_thread *t, const char *name);
+
typedef struct pa_tls pa_tls;
pa_tls* pa_tls_new(pa_free_cb_t free_cb);
@@ -55,7 +60,7 @@ void *pa_tls_set(pa_tls *t, void *userdata);
#define PA_STATIC_TLS_DECLARE(name, free_cb) \
static struct { \
pa_once once; \
- pa_tls *tls; \
+ pa_tls *volatile tls; \
} name##_tls = { \
.once = PA_ONCE_INIT, \
.tls = NULL \
@@ -89,7 +94,7 @@ void *pa_tls_set(pa_tls *t, void *userdata);
} \
struct __stupid_useless_struct_to_allow_trailing_semicolon
-#ifdef SUPPORT_TLS___THREAD
+#if defined(SUPPORT_TLS___THREAD) && !defined(OS_IS_WIN32)
/* An optimized version of the above that requires no dynamic
* allocation if the compiler supports __thread */
#define PA_STATIC_TLS_DECLARE_NO_FREE(name) \
diff --git a/src/pulsecore/time-smoother.c b/src/pulsecore/time-smoother.c
index 9d5a0705..be054a5f 100644
--- a/src/pulsecore/time-smoother.c
+++ b/src/pulsecore/time-smoother.c
@@ -24,6 +24,7 @@
#endif
#include <stdio.h>
+#include <math.h>
#include <pulse/sample.h>
#include <pulse/xmalloc.h>
@@ -108,29 +109,11 @@ pa_smoother* pa_smoother_new(
s = pa_xnew(pa_smoother, 1);
s->adjust_time = adjust_time;
s->history_time = history_time;
- s->time_offset = 0;
+ s->min_history = min_history;
s->monotonic = monotonic;
-
- s->px = s->py = 0;
- s->dp = 1;
-
- s->ex = s->ey = s->ry = 0;
- s->de = 1;
-
- s->history_idx = 0;
- s->n_history = 0;
-
- s->last_y = s->last_x = 0;
-
- s->abc_valid = FALSE;
-
- s->paused = FALSE;
s->smoothing = smoothing;
- s->min_history = min_history;
-
- s->paused = paused;
- s->time_offset = s->pause_time = time_offset;
+ pa_smoother_reset(s, time_offset, paused);
return s;
}
@@ -214,6 +197,13 @@ static double avg_gradient(pa_smoother *s, pa_usec_t x) {
int64_t ax = 0, ay = 0, k, t;
double r;
+ /* FIXME: Optimization: Jason Newton suggested that instead of
+ * going through the history on each iteration we could calculated
+ * avg_gradient() as we go.
+ *
+ * Second idea: it might make sense to weight history entries:
+ * more recent entries should matter more than old ones. */
+
/* Too few measurements, assume gradient of 1 */
if (s->n_history < s->min_history)
return 1;
@@ -331,10 +321,8 @@ static void estimate(pa_smoother *s, pa_usec_t x, pa_usec_t *y, double *deriv) {
calc_abc(s);
- tx = (double) x;
-
/* Move to origin */
- tx -= (double) s->ex;
+ tx = (double) (x - s->ex);
/* Horner scheme */
ty = (tx * (s->c + tx * (s->b + tx * s->a)));
@@ -398,7 +386,7 @@ void pa_smoother_put(pa_smoother *s, pa_usec_t x, pa_usec_t y) {
s->abc_valid = FALSE;
#ifdef DEBUG_DATA
- pa_log_debug("%p, put(%llu | %llu) = %llu", s, (unsigned long long) (x + s->time_offset), (unsigned long long) x, (unsigned long long) y);
+ pa_log_debug("%p, put(%llu | %llu) = %llu", s, (unsigned long long) (x + s->time_offset), (unsigned long long) x, (unsigned long long) y);
#endif
}
@@ -454,7 +442,7 @@ void pa_smoother_pause(pa_smoother *s, pa_usec_t x) {
return;
#ifdef DEBUG_DATA
- pa_log_debug("pause(%llu)", (unsigned long long) x);
+ pa_log_debug("pause(%llu)", (unsigned long long) x);
#endif
s->paused = TRUE;
@@ -514,9 +502,26 @@ pa_usec_t pa_smoother_translate(pa_smoother *s, pa_usec_t x, pa_usec_t y_delay)
return (pa_usec_t) llrint((double) y_delay / nde);
}
-void pa_smoother_reset(pa_smoother *s) {
+void pa_smoother_reset(pa_smoother *s, pa_usec_t time_offset, pa_bool_t paused) {
pa_assert(s);
+ s->px = s->py = 0;
+ s->dp = 1;
+
+ s->ex = s->ey = s->ry = 0;
+ s->de = 1;
+
+ s->history_idx = 0;
s->n_history = 0;
+
+ s->last_y = s->last_x = 0;
+
s->abc_valid = FALSE;
+
+ s->paused = paused;
+ s->time_offset = s->pause_time = time_offset;
+
+#ifdef DEBUG_DATA
+ pa_log_debug("reset()");
+#endif
}
diff --git a/src/pulsecore/time-smoother.h b/src/pulsecore/time-smoother.h
index 5244a7e7..63d33e48 100644
--- a/src/pulsecore/time-smoother.h
+++ b/src/pulsecore/time-smoother.h
@@ -52,7 +52,7 @@ void pa_smoother_set_time_offset(pa_smoother *s, pa_usec_t x_offset);
void pa_smoother_pause(pa_smoother *s, pa_usec_t x);
void pa_smoother_resume(pa_smoother *s, pa_usec_t x, pa_bool_t abrupt);
-void pa_smoother_reset(pa_smoother *s);
+void pa_smoother_reset(pa_smoother *s, pa_usec_t time_offset, pa_bool_t paused);
void pa_smoother_fix_now(pa_smoother *s);
diff --git a/src/pulsecore/tokenizer.c b/src/pulsecore/tokenizer.c
index 1eb466dd..a0ade697 100644
--- a/src/pulsecore/tokenizer.c
+++ b/src/pulsecore/tokenizer.c
@@ -27,7 +27,6 @@
#include <stdlib.h>
#include <pulse/xmalloc.h>
-#include <pulse/gccmacro.h>
#include <pulsecore/dynarray.h>
#include <pulsecore/macro.h>
diff --git a/src/pulsecore/usergroup.c b/src/pulsecore/usergroup.c
new file mode 100644
index 00000000..c244865e
--- /dev/null
+++ b/src/pulsecore/usergroup.c
@@ -0,0 +1,364 @@
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Ted Percival
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of the
+ License, or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <sys/types.h>
+#include <errno.h>
+
+#ifdef HAVE_PWD_H
+#include <pwd.h>
+#endif
+
+#ifdef HAVE_GRP_H
+#include <grp.h>
+#endif
+
+#include <pulse/xmalloc.h>
+#include <pulsecore/macro.h>
+
+#include "usergroup.h"
+
+#ifdef HAVE_GRP_H
+
+/* Returns a suitable starting size for a getgrnam_r() or getgrgid_r() buffer,
+ plus the size of a struct group.
+ */
+static size_t starting_getgr_buflen(void) {
+ size_t full_size;
+ long n;
+#ifdef _SC_GETGR_R_SIZE_MAX
+ n = sysconf(_SC_GETGR_R_SIZE_MAX);
+#else
+ n = -1;
+#endif
+ if (n <= 0)
+ n = 512;
+
+ full_size = (size_t) n + sizeof(struct group);
+
+ if (full_size < (size_t) n) /* check for integer overflow */
+ return (size_t) n;
+
+ return full_size;
+}
+
+/* Returns a suitable starting size for a getpwnam_r() or getpwuid_r() buffer,
+ plus the size of a struct passwd.
+ */
+static size_t starting_getpw_buflen(void) {
+ long n;
+ size_t full_size;
+
+#ifdef _SC_GETPW_R_SIZE_MAX
+ n = sysconf(_SC_GETPW_R_SIZE_MAX);
+#else
+ n = -1;
+#endif
+ if (n <= 0)
+ n = 512;
+
+ full_size = (size_t) n + sizeof(struct passwd);
+
+ if (full_size < (size_t) n) /* check for integer overflow */
+ return (size_t) n;
+
+ return full_size;
+}
+
+/* Given a memory allocation (*bufptr) and its length (*buflenptr),
+ double the size of the allocation, updating the given buffer and length
+ arguments. This function should be used in conjunction with the pa_*alloc
+ and pa_xfree functions.
+
+ Unlike realloc(), this function does *not* retain the original buffer's
+ contents.
+
+ Returns 0 on success, nonzero on error. The error cause is indicated by
+ errno.
+ */
+static int expand_buffer_trashcontents(void **bufptr, size_t *buflenptr) {
+ size_t newlen;
+
+ if (!bufptr || !*bufptr || !buflenptr) {
+ errno = EINVAL;
+ return -1;
+ }
+
+ newlen = *buflenptr * 2;
+
+ if (newlen < *buflenptr) {
+ errno = EOVERFLOW;
+ return -1;
+ }
+
+ /* Don't bother retaining memory contents; free & alloc anew */
+ pa_xfree(*bufptr);
+
+ *bufptr = pa_xmalloc(newlen);
+ *buflenptr = newlen;
+
+ return 0;
+}
+
+#ifdef HAVE_GETGRGID_R
+/* Thread-safe getgrgid() replacement.
+ Returned value should be freed using pa_getgrgid_free() when the caller is
+ finished with the returned group data.
+
+ API is the same as getgrgid(), errors are indicated by a NULL return;
+ consult errno for the error cause (zero it before calling).
+ */
+struct group *pa_getgrgid_malloc(gid_t gid) {
+ size_t buflen, getgr_buflen;
+ int err;
+ void *buf;
+ void *getgr_buf;
+ struct group *result = NULL;
+
+ buflen = starting_getgr_buflen();
+ buf = pa_xmalloc(buflen);
+
+ getgr_buflen = buflen - sizeof(struct group);
+ getgr_buf = (char *)buf + sizeof(struct group);
+
+ while ((err = getgrgid_r(gid, (struct group *)buf, getgr_buf, getgr_buflen, &result)) == ERANGE) {
+ if (expand_buffer_trashcontents(&buf, &buflen))
+ break;
+
+ getgr_buflen = buflen - sizeof(struct group);
+ getgr_buf = (char *)buf + sizeof(struct group);
+ }
+
+ if (err || !result) {
+ result = NULL;
+ if (buf) {
+ pa_xfree(buf);
+ buf = NULL;
+ }
+ }
+
+ pa_assert(result == buf || result == NULL);
+
+ return result;
+}
+
+void pa_getgrgid_free(struct group *grp) {
+ pa_xfree(grp);
+}
+
+#else /* !HAVE_GETGRGID_R */
+
+struct group *pa_getgrgid_malloc(gid_t gid) {
+ return getgrgid(gid);
+}
+
+void pa_getgrgid_free(struct group *grp) {
+ /* nothing */
+ return;
+}
+
+#endif /* !HAVE_GETGRGID_R */
+
+#ifdef HAVE_GETGRNAM_R
+/* Thread-safe getgrnam() function.
+ Returned value should be freed using pa_getgrnam_free() when the caller is
+ finished with the returned group data.
+
+ API is the same as getgrnam(), errors are indicated by a NULL return;
+ consult errno for the error cause (zero it before calling).
+ */
+struct group *pa_getgrnam_malloc(const char *name) {
+ size_t buflen, getgr_buflen;
+ int err;
+ void *buf;
+ void *getgr_buf;
+ struct group *result = NULL;
+
+ buflen = starting_getgr_buflen();
+ buf = pa_xmalloc(buflen);
+
+ getgr_buflen = buflen - sizeof(struct group);
+ getgr_buf = (char *)buf + sizeof(struct group);
+
+ while ((err = getgrnam_r(name, (struct group *)buf, getgr_buf, getgr_buflen, &result)) == ERANGE) {
+ if (expand_buffer_trashcontents(&buf, &buflen))
+ break;
+
+ getgr_buflen = buflen - sizeof(struct group);
+ getgr_buf = (char *)buf + sizeof(struct group);
+ }
+
+ if (err || !result) {
+ result = NULL;
+ if (buf) {
+ pa_xfree(buf);
+ buf = NULL;
+ }
+ }
+
+ pa_assert(result == buf || result == NULL);
+
+ return result;
+}
+
+void pa_getgrnam_free(struct group *group) {
+ pa_xfree(group);
+}
+
+#else /* !HAVE_GETGRNAM_R */
+
+struct group *pa_getgrnam_malloc(const char *name) {
+ return getgrnam(name);
+}
+
+void pa_getgrnam_free(struct group *group) {
+ /* nothing */
+ return;
+}
+
+#endif /* HAVE_GETGRNAM_R */
+
+#endif /* HAVE_GRP_H */
+
+#ifdef HAVE_PWD_H
+
+#ifdef HAVE_GETPWNAM_R
+/* Thread-safe getpwnam() function.
+ Returned value should be freed using pa_getpwnam_free() when the caller is
+ finished with the returned passwd data.
+
+ API is the same as getpwnam(), errors are indicated by a NULL return;
+ consult errno for the error cause (zero it before calling).
+ */
+struct passwd *pa_getpwnam_malloc(const char *name) {
+ size_t buflen, getpw_buflen;
+ int err;
+ void *buf;
+ void *getpw_buf;
+ struct passwd *result = NULL;
+
+ buflen = starting_getpw_buflen();
+ buf = pa_xmalloc(buflen);
+
+ getpw_buflen = buflen - sizeof(struct passwd);
+ getpw_buf = (char *)buf + sizeof(struct passwd);
+
+ while ((err = getpwnam_r(name, (struct passwd *)buf, getpw_buf, getpw_buflen, &result)) == ERANGE) {
+ if (expand_buffer_trashcontents(&buf, &buflen))
+ break;
+
+ getpw_buflen = buflen - sizeof(struct passwd);
+ getpw_buf = (char *)buf + sizeof(struct passwd);
+ }
+
+ if (err || !result) {
+ result = NULL;
+ if (buf) {
+ pa_xfree(buf);
+ buf = NULL;
+ }
+ }
+
+ pa_assert(result == buf || result == NULL);
+
+ return result;
+}
+
+void pa_getpwnam_free(struct passwd *passwd) {
+ pa_xfree(passwd);
+}
+
+#else /* !HAVE_GETPWNAM_R */
+
+struct passwd *pa_getpwnam_malloc(const char *name) {
+ return getpwnam(name);
+}
+
+void pa_getpwnam_free(struct passwd *passwd) {
+ /* nothing */
+ return;
+}
+
+#endif /* !HAVE_GETPWNAM_R */
+
+#ifdef HAVE_GETPWUID_R
+/* Thread-safe getpwuid() function.
+ Returned value should be freed using pa_getpwuid_free() when the caller is
+ finished with the returned group data.
+
+ API is the same as getpwuid(), errors are indicated by a NULL return;
+ consult errno for the error cause (zero it before calling).
+ */
+struct passwd *pa_getpwuid_malloc(uid_t uid) {
+ size_t buflen, getpw_buflen;
+ int err;
+ void *buf;
+ void *getpw_buf;
+ struct passwd *result = NULL;
+
+ buflen = starting_getpw_buflen();
+ buf = pa_xmalloc(buflen);
+
+ getpw_buflen = buflen - sizeof(struct passwd);
+ getpw_buf = (char *)buf + sizeof(struct passwd);
+
+ while ((err = getpwuid_r(uid, (struct passwd *)buf, getpw_buf, getpw_buflen, &result)) == ERANGE) {
+ if (expand_buffer_trashcontents(&buf, &buflen))
+ break;
+
+ getpw_buflen = buflen - sizeof(struct passwd);
+ getpw_buf = (char *)buf + sizeof(struct passwd);
+ }
+
+ if (err || !result) {
+ result = NULL;
+ if (buf) {
+ pa_xfree(buf);
+ buf = NULL;
+ }
+ }
+
+ pa_assert(result == buf || result == NULL);
+
+ return result;
+}
+
+void pa_getpwuid_free(struct passwd *passwd) {
+ pa_xfree(passwd);
+}
+
+#else /* !HAVE_GETPWUID_R */
+
+struct passwd *pa_getpwuid_malloc(uid_t uid) {
+ return getpwuid(uid);
+}
+
+void pa_getpwuid_free(struct passwd *passwd) {
+ /* nothing */
+ return;
+}
+
+#endif /* !HAVE_GETPWUID_R */
+
+#endif /* HAVE_PWD_H */
diff --git a/src/pulsecore/usergroup.h b/src/pulsecore/usergroup.h
new file mode 100644
index 00000000..1c091638
--- /dev/null
+++ b/src/pulsecore/usergroup.h
@@ -0,0 +1,51 @@
+#ifndef foousergrouphfoo
+#define foousergrouphfoo
+
+/***
+ This file is part of PulseAudio.
+
+ Copyright 2009 Ted Percival
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of the
+ License, or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#include <sys/types.h>
+
+#ifndef PACKAGE
+#error "Please include config.h before including this file!"
+#endif
+
+#ifdef HAVE_GRP_H
+
+struct group *pa_getgrgid_malloc(gid_t gid);
+void pa_getgrgid_free(struct group *grp);
+
+struct group *pa_getgrnam_malloc(const char *name);
+void pa_getgrnam_free(struct group *group);
+
+#endif /* HAVE_GRP_H */
+
+#ifdef HAVE_PWD_H
+
+struct passwd *pa_getpwuid_malloc(uid_t uid);
+void pa_getpwuid_free(struct passwd *passwd);
+
+struct passwd *pa_getpwnam_malloc(const char *name);
+void pa_getpwnam_free(struct passwd *passwd);
+
+#endif /* HAVE_PWD_H */
+
+#endif /* foousergrouphfoo */
diff --git a/src/pulsecore/vector.h b/src/pulsecore/vector.h
index 924e3cb8..9de3b8cd 100644
--- a/src/pulsecore/vector.h
+++ b/src/pulsecore/vector.h
@@ -23,7 +23,8 @@
#include <inttypes.h>
/* First, define HAVE_VECTOR if we have the gcc vector extensions at all */
-#if defined(__SSE2__) || defined(__ALTIVEC__)
+#if defined(__SSE2__)
+ /* || defined(__ALTIVEC__)*/
#define HAVE_VECTOR
diff --git a/src/pulsecore/x11prop.c b/src/pulsecore/x11prop.c
index 873a76e7..baf5b018 100644
--- a/src/pulsecore/x11prop.c
+++ b/src/pulsecore/x11prop.c
@@ -25,45 +25,124 @@
#include <string.h>
-#include <X11/Xlib.h>
-#include <X11/Xatom.h>
-
#include "x11prop.h"
-void pa_x11_set_prop(Display *d, const char *name, const char *data) {
- Atom a = XInternAtom(d, name, False);
- XChangeProperty(d, RootWindow(d, 0), a, XA_STRING, 8, PropModeReplace, (const unsigned char*) data, (int) (strlen(data)+1));
+#include <pulsecore/macro.h>
+
+#include <xcb/xproto.h>
+
+#define PA_XCB_FORMAT 8
+
+static xcb_screen_t *screen_of_display(xcb_connection_t *xcb, int screen) {
+ const xcb_setup_t *s;
+ xcb_screen_iterator_t iter;
+
+ if ((s = xcb_get_setup(xcb))) {
+ iter = xcb_setup_roots_iterator(s);
+ for (; iter.rem; --screen, xcb_screen_next(&iter))
+ if (0 == screen)
+ return iter.data;
+ }
+ return NULL;
}
-void pa_x11_del_prop(Display *d, const char *name) {
- Atom a = XInternAtom(d, name, False);
- XDeleteProperty(d, RootWindow(d, 0), a);
+void pa_x11_set_prop(xcb_connection_t *xcb, int screen, const char *name, const char *data) {
+ xcb_screen_t *xs;
+ xcb_intern_atom_reply_t *reply;
+
+ pa_assert(xcb);
+ pa_assert(name);
+ pa_assert(data);
+
+ if ((xs = screen_of_display(xcb, screen))) {
+ reply = xcb_intern_atom_reply(xcb,
+ xcb_intern_atom(xcb, 0, strlen(name), name),
+ NULL);
+
+ if (reply) {
+ xcb_change_property(xcb, XCB_PROP_MODE_REPLACE, xs->root, reply->atom,
+ XCB_ATOM_STRING, PA_XCB_FORMAT,
+ (int) strlen(data), (const void*) data);
+
+ free(reply);
+ }
+ }
}
-char* pa_x11_get_prop(Display *d, const char *name, char *p, size_t l) {
- Atom actual_type;
- int actual_format;
- unsigned long nitems;
- unsigned long nbytes_after;
- unsigned char *prop = NULL;
+void pa_x11_del_prop(xcb_connection_t *xcb, int screen, const char *name) {
+ xcb_screen_t *xs;
+ xcb_intern_atom_reply_t *reply;
+
+ pa_assert(xcb);
+ pa_assert(name);
+
+ if ((xs = screen_of_display(xcb, screen))) {
+ reply = xcb_intern_atom_reply(xcb,
+ xcb_intern_atom(xcb, 0, strlen(name), name),
+ NULL);
+
+ if (reply) {
+ xcb_delete_property(xcb, xs->root, reply->atom);
+ free(reply);
+ }
+ }
+}
+
+char* pa_x11_get_prop(xcb_connection_t *xcb, int screen, const char *name, char *p, size_t l) {
char *ret = NULL;
+ int len;
+ xcb_get_property_cookie_t req;
+ xcb_get_property_reply_t* prop = NULL;
+ xcb_screen_t *xs;
+ xcb_intern_atom_reply_t *reply;
+
+ pa_assert(xcb);
+ pa_assert(name);
+ pa_assert(p);
+
+
+ xs = screen_of_display(xcb, screen);
+ /*
+ * Also try and get the settings from the first screen.
+ * This allows for e.g. a Media Center to run on screen 1 (e.g. HDMI) and have
+ * different defaults (e.g. prefer the HDMI sink) than the primary screen 0
+ * which uses the Internal Audio sink.
+ */
+ if (!xs && 0 != screen)
+ xs = screen_of_display(xcb, 0);
+
+ if (xs) {
+ reply = xcb_intern_atom_reply(xcb,
+ xcb_intern_atom(xcb, 0, strlen(name), name),
+ NULL);
+
+ if (!reply)
+ goto finish;
+
+ req = xcb_get_property(xcb, 0, xs->root, reply->atom, XCB_ATOM_STRING, 0, (uint32_t)(l-1));
+ free(reply);
+ prop = xcb_get_property_reply(xcb, req, NULL);
+
+ if (!prop)
+ goto finish;
- Atom a = XInternAtom(d, name, False);
- if (XGetWindowProperty(d, RootWindow(d, 0), a, 0, (long) ((l+2)/4), False, XA_STRING, &actual_type, &actual_format, &nitems, &nbytes_after, &prop) != Success)
- goto finish;
+ if (PA_XCB_FORMAT != prop->format)
+ goto finish;
- if (actual_type != XA_STRING)
- goto finish;
+ len = xcb_get_property_value_length(prop);
+ if (len < 1 || len >= (int)l)
+ goto finish;
- memcpy(p, prop, nitems);
- p[nitems] = 0;
+ memcpy(p, xcb_get_property_value(prop), len);
+ p[len] = 0;
- ret = p;
+ ret = p;
+ }
finish:
if (prop)
- XFree(prop);
+ free(prop);
return ret;
}
diff --git a/src/pulsecore/x11prop.h b/src/pulsecore/x11prop.h
index dc675263..5a121147 100644
--- a/src/pulsecore/x11prop.h
+++ b/src/pulsecore/x11prop.h
@@ -5,6 +5,7 @@
This file is part of PulseAudio.
Copyright 2004-2006 Lennart Poettering
+ Copyright 2010 Colin Guthrie
PulseAudio is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
@@ -24,10 +25,10 @@
#include <sys/types.h>
-#include <X11/Xlib.h>
+#include <xcb/xcb.h>
-void pa_x11_set_prop(Display *d, const char *name, const char *data);
-void pa_x11_del_prop(Display *d, const char *name);
-char* pa_x11_get_prop(Display *d, const char *name, char *p, size_t l);
+void pa_x11_set_prop(xcb_connection_t *xcb, int screen, const char *name, const char *data);
+void pa_x11_del_prop(xcb_connection_t *xcb, int screen, const char *name);
+char* pa_x11_get_prop(xcb_connection_t *xcb, int screen, const char *name, char *p, size_t l);
#endif
diff --git a/src/pulsecore/x11wrap.c b/src/pulsecore/x11wrap.c
index 1960a12f..454507ae 100644
--- a/src/pulsecore/x11wrap.c
+++ b/src/pulsecore/x11wrap.c
@@ -259,6 +259,10 @@ Display *pa_x11_wrapper_get_display(pa_x11_wrapper *w) {
return w->display;
}
+xcb_connection_t *pa_x11_wrapper_get_xcb_connection(pa_x11_wrapper *w) {
+ return XGetXCBConnection(pa_x11_wrapper_get_display(w));
+}
+
void pa_x11_wrapper_kill(pa_x11_wrapper *w) {
pa_x11_client *c, *n;
diff --git a/src/pulsecore/x11wrap.h b/src/pulsecore/x11wrap.h
index b57541f2..fc2e01fe 100644
--- a/src/pulsecore/x11wrap.h
+++ b/src/pulsecore/x11wrap.h
@@ -23,6 +23,7 @@
***/
#include <X11/Xlib.h>
+#include <X11/Xlib-xcb.h>
#include <pulsecore/core.h>
@@ -46,6 +47,9 @@ void pa_x11_wrapper_unref(pa_x11_wrapper* w);
/* Return the X11 display object for this connection */
Display *pa_x11_wrapper_get_display(pa_x11_wrapper *w);
+/* Return the XCB connection object for this connection */
+xcb_connection_t *pa_x11_wrapper_get_xcb_connection(pa_x11_wrapper *w);
+
/* Kill the connection to the X11 display */
void pa_x11_wrapper_kill(pa_x11_wrapper *w);
diff --git a/src/tests/Makefile b/src/tests/Makefile
deleted file mode 120000
index c110232d..00000000
--- a/src/tests/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-../pulse/Makefile \ No newline at end of file
diff --git a/src/tests/alsa-time-test.c b/src/tests/alsa-time-test.c
index 233bbe64..1a572b30 100644
--- a/src/tests/alsa-time-test.c
+++ b/src/tests/alsa-time-test.c
@@ -12,7 +12,7 @@ static uint64_t timespec_us(const struct timespec *ts) {
int main(int argc, char *argv[]) {
const char *dev;
- int r;
+ int r, cap;
snd_pcm_hw_params_t *hwparams;
snd_pcm_sw_params_t *swparams;
snd_pcm_status_t *status;
@@ -38,8 +38,12 @@ int main(int argc, char *argv[]) {
start_us = timespec_us(&start);
dev = argc > 1 ? argv[1] : "front:AudioPCI";
+ cap = argc > 2 ? atoi(argv[2]) : 0;
- r = snd_pcm_open(&pcm, dev, SND_PCM_STREAM_PLAYBACK, 0);
+ if (cap == 0)
+ r = snd_pcm_open(&pcm, dev, SND_PCM_STREAM_PLAYBACK, 0);
+ else
+ r = snd_pcm_open(&pcm, dev, SND_PCM_STREAM_CAPTURE, 0);
assert(r == 0);
r = snd_pcm_hw_params_any(pcm, hwparams);
@@ -78,7 +82,10 @@ int main(int argc, char *argv[]) {
r = snd_pcm_sw_params_current(pcm, swparams);
assert(r == 0);
- r = snd_pcm_sw_params_set_avail_min(pcm, swparams, 1);
+ if (cap == 0)
+ r = snd_pcm_sw_params_set_avail_min(pcm, swparams, 1);
+ else
+ r = snd_pcm_sw_params_set_avail_min(pcm, swparams, 0);
assert(r == 0);
r = snd_pcm_sw_params_set_period_event(pcm, swparams, 0);
@@ -117,13 +124,19 @@ int main(int argc, char *argv[]) {
r = snd_pcm_poll_descriptors(pcm, pollfds, n_pollfd);
assert(r == n_pollfd);
+ if (cap) {
+ r = snd_pcm_start(pcm);
+ assert(r == 0);
+ }
+
for (;;) {
snd_pcm_sframes_t avail, delay;
struct timespec now, timestamp;
unsigned short revents;
- int written = 0;
+ int handled = 0;
uint64_t now_us, timestamp_us;
snd_pcm_state_t state;
+ unsigned long long pos;
r = poll(pollfds, n_pollfd, 0);
assert(r >= 0);
@@ -131,7 +144,10 @@ int main(int argc, char *argv[]) {
r = snd_pcm_poll_descriptors_revents(pcm, pollfds, n_pollfd, &revents);
assert(r == 0);
- assert((revents & ~POLLOUT) == 0);
+ if (cap == 0)
+ assert((revents & ~POLLOUT) == 0);
+ else
+ assert((revents & ~POLLIN) == 0);
avail = snd_pcm_avail(pcm);
assert(avail >= 0);
@@ -152,18 +168,22 @@ int main(int argc, char *argv[]) {
assert(!revents || avail > 0);
- if (avail) {
+ if ((!cap && avail) || (cap && (unsigned)avail >= buffer_size)) {
snd_pcm_sframes_t sframes;
- static const uint16_t samples[2] = { 0, 0 };
+ static const uint16_t psamples[2] = { 0, 0 };
+ uint16_t csamples[2];
- sframes = snd_pcm_writei(pcm, samples, 1);
+ if (cap == 0)
+ sframes = snd_pcm_writei(pcm, psamples, 1);
+ else
+ sframes = snd_pcm_readi(pcm, csamples, 1);
assert(sframes == 1);
- written = 1;
+ handled = 1;
sample_count++;
}
- if (!written &&
+ if (!handled &&
memcmp(&timestamp, &last_timestamp, sizeof(timestamp)) == 0 &&
avail == last_avail &&
delay == last_delay) {
@@ -174,19 +194,26 @@ int main(int argc, char *argv[]) {
now_us = timespec_us(&now);
timestamp_us = timespec_us(&timestamp);
- printf("%llu\t%llu\t%llu\t%li\t%li\t%i\t%i\t%i\n",
+ if (cap == 0)
+ pos = (unsigned long long) ((sample_count - handled - delay) * 1000000LU / 44100);
+ else
+ pos = (unsigned long long) ((sample_count - handled + delay) * 1000000LU / 44100);
+
+ printf("%llu\t%llu\t%llu\t%llu\t%li\t%li\t%i\t%i\t%i\n",
(unsigned long long) (now_us - start_us),
(unsigned long long) (timestamp_us ? timestamp_us - start_us : 0),
- (unsigned long long) ((sample_count - 1 - delay) * 1000000LU / 44100),
+ pos,
+ (unsigned long long) sample_count,
(signed long) avail,
(signed long) delay,
revents,
- written,
+ handled,
state);
- /** When this assert is hit, most likely something bad
- * happened, i.e. the avail jumped suddenly. */
- assert((unsigned) avail <= buffer_size);
+ if (cap == 0)
+ /** When this assert is hit, most likely something bad
+ * happened, i.e. the avail jumped suddenly. */
+ assert((unsigned) avail <= buffer_size);
last_avail = avail;
last_delay = delay;
diff --git a/src/tests/asyncmsgq-test.c b/src/tests/asyncmsgq-test.c
index 40c74f76..96e5a0df 100644
--- a/src/tests/asyncmsgq-test.c
+++ b/src/tests/asyncmsgq-test.c
@@ -25,12 +25,9 @@
#include <stdlib.h>
#include <unistd.h>
-#include <pulse/util.h>
-#include <pulse/xmalloc.h>
#include <pulsecore/asyncmsgq.h>
#include <pulsecore/thread.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
enum {
@@ -80,7 +77,7 @@ int main(int argc, char *argv[]) {
pa_assert_se(q = pa_asyncmsgq_new(0));
- pa_assert_se(t = pa_thread_new(the_thread, q));
+ pa_assert_se(t = pa_thread_new("test", the_thread, q));
printf("Operation A post\n");
pa_asyncmsgq_post(q, NULL, OPERATION_A, NULL, 0, NULL, NULL);
diff --git a/src/tests/asyncq-test.c b/src/tests/asyncq-test.c
index a617e1a0..46bac9f4 100644
--- a/src/tests/asyncq-test.c
+++ b/src/tests/asyncq-test.c
@@ -26,11 +26,9 @@
#include <unistd.h>
#include <pulse/util.h>
-#include <pulse/xmalloc.h>
#include <pulsecore/asyncq.h>
#include <pulsecore/thread.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
static void producer(void *_q) {
@@ -51,7 +49,7 @@ static void consumer(void *_q) {
void *p;
int i;
- sleep(1);
+ pa_msleep(1000);
for (i = 0;; i++) {
p = pa_asyncq_pop(q, TRUE);
@@ -73,8 +71,8 @@ int main(int argc, char *argv[]) {
pa_assert_se(q = pa_asyncq_new(0));
- pa_assert_se(t1 = pa_thread_new(producer, q));
- pa_assert_se(t2 = pa_thread_new(consumer, q));
+ pa_assert_se(t1 = pa_thread_new("producer", producer, q));
+ pa_assert_se(t2 = pa_thread_new("consumer", consumer, q));
pa_thread_free(t1);
pa_thread_free(t2);
diff --git a/src/tests/channelmap-test.c b/src/tests/channelmap-test.c
index 6cf58fb0..70d6a6a9 100644
--- a/src/tests/channelmap-test.c
+++ b/src/tests/channelmap-test.c
@@ -6,7 +6,6 @@
#include <assert.h>
#include <pulse/channelmap.h>
-#include <pulse/gccmacro.h>
int main(int argc, char *argv[]) {
char cm[PA_CHANNEL_MAP_SNPRINT_MAX];
diff --git a/src/tests/connect-stress.c b/src/tests/connect-stress.c
new file mode 100644
index 00000000..eadcf885
--- /dev/null
+++ b/src/tests/connect-stress.c
@@ -0,0 +1,206 @@
+/***
+ This file is part of PulseAudio.
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <signal.h>
+#include <string.h>
+#include <errno.h>
+#include <unistd.h>
+#include <assert.h>
+#include <stdio.h>
+#include <stdlib.h>
+
+#include <pulse/pulseaudio.h>
+#include <pulse/mainloop.h>
+
+#include <pulsecore/sink.h>
+
+/* Set the number of streams such that it allows two simultaneous instances of
+ * connect-stress to be run and not go above the max limit for streams-per-sink.
+ * This leaves enough room for a couple other streams from regular system usage,
+ * which makes a non-error abort less likely (although still easily possible of
+ * playing >=3 streams outside of the test - including internal loopback, rtp,
+ * combine, remap streams etc.) */
+#define NSTREAMS ((PA_MAX_INPUTS_PER_SINK/2) - 1)
+#define NTESTS 1000
+#define SAMPLE_HZ 44100
+
+static pa_context *context = NULL;
+static pa_stream *streams[NSTREAMS];
+static pa_threaded_mainloop *mainloop = NULL;
+
+static const pa_sample_spec sample_spec = {
+ .format = PA_SAMPLE_FLOAT32,
+ .rate = SAMPLE_HZ,
+ .channels = 1
+};
+
+static void context_state_callback(pa_context *c, void *userdata);
+
+static void connect(const char *name, int *try) {
+ int ret;
+ pa_mainloop_api *api;
+
+ /* Set up a new main loop */
+ mainloop = pa_threaded_mainloop_new();
+ assert(mainloop);
+
+ api = pa_threaded_mainloop_get_api(mainloop);
+ context = pa_context_new(api, name);
+ assert(context);
+
+ pa_context_set_state_callback(context, context_state_callback, try);
+
+ /* Connect the context */
+ if (pa_context_connect(context, NULL, 0, NULL) < 0) {
+ fprintf(stderr, "pa_context_connect() failed.\n");
+ abort();
+ }
+
+ ret = pa_threaded_mainloop_start(mainloop);
+ assert(ret == 0);
+}
+
+static void disconnect(void) {
+ int i;
+
+ assert(mainloop);
+ assert(context);
+
+ pa_threaded_mainloop_lock(mainloop);
+
+ for (i = 0; i < NSTREAMS; i++)
+ if (streams[i]) {
+ pa_stream_disconnect(streams[i]);
+ pa_stream_unref(streams[i]);
+ streams[i] = NULL;
+ }
+
+ pa_context_disconnect(context);
+ context = NULL;
+
+ pa_threaded_mainloop_unlock(mainloop);
+ pa_threaded_mainloop_stop(mainloop);
+ pa_threaded_mainloop_free(mainloop);
+ mainloop = NULL;
+}
+
+static const pa_buffer_attr buffer_attr = {
+ .maxlength = SAMPLE_HZ * sizeof(float) * NSTREAMS,
+ .tlength = (uint32_t) -1,
+ .prebuf = 0, /* Setting prebuf to 0 guarantees us the the streams will run synchronously, no matter what */
+ .minreq = (uint32_t) -1,
+ .fragsize = 0
+};
+
+static void stream_write_callback(pa_stream *stream, size_t nbytes, void *userdata) {
+ char silence[8192];
+
+ memset(silence, 0, sizeof(silence));
+
+ while (nbytes) {
+ int n = PA_MIN(sizeof(silence), nbytes);
+ pa_stream_write(stream, silence, n, NULL, 0, 0);
+ nbytes -= n;
+ }
+}
+
+static void stream_state_callback(pa_stream *s, void *userdata) {
+ assert(s);
+
+ switch (pa_stream_get_state(s)) {
+ case PA_STREAM_UNCONNECTED:
+ case PA_STREAM_CREATING:
+ case PA_STREAM_TERMINATED:
+ case PA_STREAM_READY:
+ break;
+
+ default:
+ case PA_STREAM_FAILED:
+ fprintf(stderr, "Stream error: %s\n", pa_strerror(pa_context_errno(pa_stream_get_context(s))));
+ abort();
+ }
+}
+
+static void context_state_callback(pa_context *c, void *userdata) {
+ int *try;
+
+ assert(c);
+ assert(userdata);
+
+ try = (int*)userdata;
+
+ switch (pa_context_get_state(c)) {
+ case PA_CONTEXT_CONNECTING:
+ case PA_CONTEXT_AUTHORIZING:
+ case PA_CONTEXT_SETTING_NAME:
+ break;
+
+ case PA_CONTEXT_READY: {
+
+ int i;
+ fprintf(stderr, "Connection (%d of %d) established.\n", (*try)+1, NTESTS);
+
+ for (i = 0; i < NSTREAMS; i++) {
+ char name[64];
+
+ snprintf(name, sizeof(name), "stream #%i", i);
+ streams[i] = pa_stream_new(c, name, &sample_spec, NULL);
+ assert(streams[i]);
+ pa_stream_set_state_callback(streams[i], stream_state_callback, NULL);
+ pa_stream_set_write_callback(streams[i], stream_write_callback, NULL);
+ pa_stream_connect_playback(streams[i], NULL, &buffer_attr, 0, NULL, NULL);
+ }
+
+ break;
+ }
+
+ case PA_CONTEXT_TERMINATED:
+ fprintf(stderr, "Connection terminated.\n");
+ pa_context_unref(context);
+ context = NULL;
+ break;
+
+ case PA_CONTEXT_FAILED:
+ default:
+ fprintf(stderr, "Context error: %s\n", pa_strerror(pa_context_errno(c)));
+ abort();
+ }
+}
+
+int main(int argc, char *argv[]) {
+ int i;
+
+ for (i = 0; i < NSTREAMS; i++)
+ streams[i] = NULL;
+
+ for (i = 0; i < NTESTS; i++) {
+ connect(argv[0], &i);
+ usleep(rand() % 500000);
+ disconnect();
+ usleep(rand() % 500000);
+ }
+
+ fprintf(stderr, "Done.\n");
+
+ return 0;
+}
diff --git a/src/tests/cpulimit-test.c b/src/tests/cpulimit-test.c
index 9d0f4eef..8bd03417 100644
--- a/src/tests/cpulimit-test.c
+++ b/src/tests/cpulimit-test.c
@@ -22,19 +22,18 @@
#endif
#include <assert.h>
-#include <sys/time.h>
+#include <time.h>
#include <stdlib.h>
#include <stdio.h>
#include <signal.h>
#include <pulse/mainloop.h>
-#include <pulse/gccmacro.h>
#ifdef TEST2
#include <pulse/mainloop-signal.h>
#endif
-#include "../daemon/cpulimit.h"
+#include <daemon/cpulimit.h>
/* A simple example for testing the cpulimit subsystem */
diff --git a/src/tests/envelope-test.c b/src/tests/envelope-test.c
deleted file mode 100644
index 3af3044e..00000000
--- a/src/tests/envelope-test.c
+++ /dev/null
@@ -1,246 +0,0 @@
-/***
- This file is part of PulseAudio.
-
- PulseAudio is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as published
- by the Free Software Foundation; either version 2.1 of the License,
- or (at your option) any later version.
-
- PulseAudio is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public License
- along with PulseAudio; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA.
-***/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-
-#include <pulse/sample.h>
-#include <pulse/volume.h>
-#include <pulse/timeval.h>
-
-#include <pulsecore/envelope.h>
-#include <pulsecore/macro.h>
-#include <pulsecore/endianmacros.h>
-#include <pulsecore/memblock.h>
-#include <pulsecore/sample-util.h>
-
-#include <liboil/liboil.h>
-
-const pa_envelope_def ramp_down = {
- .n_points = 2,
- .points_x = { 100*PA_USEC_PER_MSEC, 300*PA_USEC_PER_MSEC },
- .points_y = {
- .f = { 1.0f, 0.2f },
- .i = { 0x10000, 0x10000/5 }
- }
-};
-
-const pa_envelope_def ramp_up = {
- .n_points = 2,
- .points_x = { 100*PA_USEC_PER_MSEC, 300*PA_USEC_PER_MSEC },
- .points_y = {
- .f = { 0.2f, 1.0f },
- .i = { 0x10000/5, 0x10000 }
- }
-};
-
-const pa_envelope_def ramp_down2 = {
- .n_points = 2,
- .points_x = { 50*PA_USEC_PER_MSEC, 900*PA_USEC_PER_MSEC },
- .points_y = {
- .f = { 0.8f, 0.7f },
- .i = { 0x10000*4/5, 0x10000*7/10 }
- }
-};
-
-const pa_envelope_def ramp_up2 = {
- .n_points = 2,
- .points_x = { 50*PA_USEC_PER_MSEC, 900*PA_USEC_PER_MSEC },
- .points_y = {
- .f = { 0.7f, 0.9f },
- .i = { 0x10000*7/10, 0x10000*9/10 }
- }
-};
-
-static void dump_block(const pa_sample_spec *ss, const pa_memchunk *chunk) {
- void *d;
- unsigned i;
-
- static unsigned j = 0;
-
- d = pa_memblock_acquire(chunk->memblock);
-
- switch (ss->format) {
-
- case PA_SAMPLE_U8:
- case PA_SAMPLE_ULAW:
- case PA_SAMPLE_ALAW: {
- uint8_t *u = d;
-
- for (i = 0; i < chunk->length / pa_frame_size(ss); i++)
- printf("0x%02x ", *(u++));
-
- break;
- }
-
- case PA_SAMPLE_S16NE:
- case PA_SAMPLE_S16RE: {
- int16_t *u = d;
-
- for (i = 0; i < chunk->length / pa_frame_size(ss); i++)
- printf("%i\t%i\n", j++, *(u++));
-
- break;
- }
-
- case PA_SAMPLE_S32NE:
- case PA_SAMPLE_S32RE: {
- int32_t *u = d;
-
- for (i = 0; i < chunk->length / pa_frame_size(ss); i++)
- printf("%i\t%i\n", j++, *(u++));
-
- break;
- }
-
- case PA_SAMPLE_FLOAT32NE:
- case PA_SAMPLE_FLOAT32RE: {
- float *u = d;
-
- for (i = 0; i < chunk->length / pa_frame_size(ss); i++) {
- printf("%i\t%1.3g\n", j++, PA_MAYBE_FLOAT32_SWAP(ss->format == PA_SAMPLE_FLOAT32RE, *u));
- u++;
- }
-
- break;
- }
-
- default:
- pa_assert_not_reached();
- }
-
- printf("\n");
-
- pa_memblock_release(chunk->memblock);
-}
-
-static pa_memblock * generate_block(pa_mempool *pool, const pa_sample_spec *ss) {
- pa_memblock *block;
- void *d;
- unsigned n_samples;
-
- block = pa_memblock_new(pool, pa_bytes_per_second(ss));
- n_samples = (unsigned) (pa_memblock_get_length(block) / pa_sample_size(ss));
-
- d = pa_memblock_acquire(block);
-
- switch (ss->format) {
-
- case PA_SAMPLE_S16NE:
- case PA_SAMPLE_S16RE: {
- int16_t *i;
-
- for (i = d; n_samples > 0; n_samples--, i++)
- *i = 0x7FFF;
-
- break;
- }
-
- case PA_SAMPLE_S32NE:
- case PA_SAMPLE_S32RE: {
- int32_t *i;
-
- for (i = d; n_samples > 0; n_samples--, i++)
- *i = 0x7FFFFFFF;
-
- break;
- }
-
- case PA_SAMPLE_FLOAT32RE:
- case PA_SAMPLE_FLOAT32NE: {
- float *f;
-
- for (f = d; n_samples > 0; n_samples--, f++)
- *f = PA_MAYBE_FLOAT32_SWAP(ss->format == PA_SAMPLE_FLOAT32RE, 1.0f);
-
- break;
- }
-
- default:
- pa_assert_not_reached();
- }
-
- pa_memblock_release(block);
- return block;
-}
-
-int main(int argc, char *argv[]) {
- pa_mempool *pool;
- pa_memblock *block;
- pa_memchunk chunk;
- pa_envelope *envelope;
- pa_envelope_item *item1, *item2;
-
- const pa_sample_spec ss = {
- .format = PA_SAMPLE_S16NE,
- .channels = 1,
- .rate = 200
- };
-
- const pa_cvolume v = {
- .channels = 1,
- .values = { PA_VOLUME_NORM, PA_VOLUME_NORM/2 }
- };
-
- oil_init();
- pa_log_set_level(PA_LOG_DEBUG);
-
- pa_assert_se(pool = pa_mempool_new(FALSE, 0));
- pa_assert_se(envelope = pa_envelope_new(&ss));
-
- block = generate_block(pool, &ss);
-
- chunk.memblock = pa_memblock_ref(block);
- chunk.length = pa_memblock_get_length(block);
- chunk.index = 0;
-
- pa_volume_memchunk(&chunk, &ss, &v);
-
- item1 = pa_envelope_add(envelope, &ramp_down);
- item2 = pa_envelope_add(envelope, &ramp_down2);
- pa_envelope_apply(envelope, &chunk);
- dump_block(&ss, &chunk);
-
- pa_memblock_unref(chunk.memblock);
-
- chunk.memblock = pa_memblock_ref(block);
- chunk.length = pa_memblock_get_length(block);
- chunk.index = 0;
-
- item1 = pa_envelope_replace(envelope, item1, &ramp_up);
- item2 = pa_envelope_replace(envelope, item2, &ramp_up2);
- pa_envelope_apply(envelope, &chunk);
- dump_block(&ss, &chunk);
-
- pa_memblock_unref(chunk.memblock);
-
- pa_envelope_remove(envelope, item1);
- pa_envelope_remove(envelope, item2);
- pa_envelope_free(envelope);
-
- pa_memblock_unref(block);
-
- pa_mempool_free(pool);
-
- return 0;
-}
diff --git a/src/tests/extended-test.c b/src/tests/extended-test.c
new file mode 100644
index 00000000..631fdc89
--- /dev/null
+++ b/src/tests/extended-test.c
@@ -0,0 +1,197 @@
+/***
+ This file is part of PulseAudio.
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <signal.h>
+#include <errno.h>
+#include <unistd.h>
+#include <assert.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <math.h>
+
+#include <pulse/pulseaudio.h>
+#include <pulse/mainloop.h>
+
+#define NSTREAMS 4
+#define SINE_HZ 440
+#define SAMPLE_HZ 8000
+
+static pa_context *context = NULL;
+static pa_stream *streams[NSTREAMS];
+static pa_mainloop_api *mainloop_api = NULL;
+
+static float data[SAMPLE_HZ]; /* one second space */
+
+static int n_streams_ready = 0;
+
+static const pa_buffer_attr buffer_attr = {
+ .maxlength = SAMPLE_HZ*sizeof(float)*NSTREAMS, /* exactly space for the entire play time */
+ .tlength = (uint32_t) -1,
+ .prebuf = 0, /* Setting prebuf to 0 guarantees us the the streams will run synchronously, no matter what */
+ .minreq = (uint32_t) -1,
+ .fragsize = 0
+};
+
+static void nop_free_cb(void *p) {}
+
+static void underflow_cb(struct pa_stream *s, void *userdata) {
+ int i = (int) (long) userdata;
+
+ fprintf(stderr, "Stream %i finished\n", i);
+
+ if (++n_streams_ready >= 2*NSTREAMS) {
+ fprintf(stderr, "We're done\n");
+ mainloop_api->quit(mainloop_api, 0);
+ }
+}
+
+/* This routine is called whenever the stream state changes */
+static void stream_state_callback(pa_stream *s, void *userdata) {
+ assert(s);
+
+ switch (pa_stream_get_state(s)) {
+ case PA_STREAM_UNCONNECTED:
+ case PA_STREAM_CREATING:
+ case PA_STREAM_TERMINATED:
+ break;
+
+ case PA_STREAM_READY: {
+
+ int r, i = (int) (long) userdata;
+
+ fprintf(stderr, "Writing data to stream %i.\n", i);
+
+ r = pa_stream_write(s, data, sizeof(data), nop_free_cb, (int64_t) sizeof(data) * (int64_t) i, PA_SEEK_ABSOLUTE);
+ assert(r == 0);
+
+ /* Be notified when this stream is drained */
+ pa_stream_set_underflow_callback(s, underflow_cb, userdata);
+
+ /* All streams have been set up, let's go! */
+ if (++n_streams_ready >= NSTREAMS) {
+ fprintf(stderr, "Uncorking\n");
+ pa_operation_unref(pa_stream_cork(s, 0, NULL, NULL));
+ }
+
+ break;
+ }
+
+ default:
+ case PA_STREAM_FAILED:
+ fprintf(stderr, "Stream error: %s\n", pa_strerror(pa_context_errno(pa_stream_get_context(s))));
+ abort();
+ }
+}
+
+/* This is called whenever the context status changes */
+static void context_state_callback(pa_context *c, void *userdata) {
+ assert(c);
+
+ switch (pa_context_get_state(c)) {
+ case PA_CONTEXT_CONNECTING:
+ case PA_CONTEXT_AUTHORIZING:
+ case PA_CONTEXT_SETTING_NAME:
+ break;
+
+ case PA_CONTEXT_READY: {
+
+ int i;
+ fprintf(stderr, "Connection established.\n");
+
+ for (i = 0; i < NSTREAMS; i++) {
+ char name[64];
+ pa_format_info *formats[1];
+
+ formats[0] = pa_format_info_new();
+ formats[0]->encoding = PA_ENCODING_PCM;
+ pa_format_info_set_sample_format(formats[0], PA_SAMPLE_FLOAT32);
+ pa_format_info_set_rate(formats[0], SAMPLE_HZ);
+ pa_format_info_set_channels(formats[0], 1);
+
+ fprintf(stderr, "Creating stream %i\n", i);
+
+ snprintf(name, sizeof(name), "stream #%i", i);
+
+ streams[i] = pa_stream_new_extended(c, name, formats, 1, NULL);
+ assert(streams[i]);
+ pa_stream_set_state_callback(streams[i], stream_state_callback, (void*) (long) i);
+ pa_stream_connect_playback(streams[i], NULL, &buffer_attr, PA_STREAM_START_CORKED, NULL, i == 0 ? NULL : streams[0]);
+
+ pa_format_info_free(formats[0]);
+ }
+
+ break;
+ }
+
+ case PA_CONTEXT_TERMINATED:
+ mainloop_api->quit(mainloop_api, 0);
+ break;
+
+ case PA_CONTEXT_FAILED:
+ default:
+ fprintf(stderr, "Context error: %s\n", pa_strerror(pa_context_errno(c)));
+ abort();
+ }
+}
+
+int main(int argc, char *argv[]) {
+ pa_mainloop* m = NULL;
+ int i, ret = 0;
+
+ for (i = 0; i < SAMPLE_HZ; i++)
+ data[i] = (float) sin(((double) i/SAMPLE_HZ)*2*M_PI*SINE_HZ)/2;
+
+ for (i = 0; i < NSTREAMS; i++)
+ streams[i] = NULL;
+
+ /* Set up a new main loop */
+ m = pa_mainloop_new();
+ assert(m);
+
+ mainloop_api = pa_mainloop_get_api(m);
+
+ context = pa_context_new(mainloop_api, argv[0]);
+ assert(context);
+
+ pa_context_set_state_callback(context, context_state_callback, NULL);
+
+ /* Connect the context */
+ if (pa_context_connect(context, NULL, 0, NULL) < 0) {
+ fprintf(stderr, "pa_context_connect() failed.\n");
+ goto quit;
+ }
+
+ if (pa_mainloop_run(m, &ret) < 0)
+ fprintf(stderr, "pa_mainloop_run() failed.\n");
+
+quit:
+ pa_context_unref(context);
+
+ for (i = 0; i < NSTREAMS; i++)
+ if (streams[i])
+ pa_stream_unref(streams[i]);
+
+ pa_mainloop_free(m);
+
+ return ret;
+}
diff --git a/src/tests/flist-test.c b/src/tests/flist-test.c
index 64c0add2..69152041 100644
--- a/src/tests/flist-test.c
+++ b/src/tests/flist-test.c
@@ -87,7 +87,7 @@ int main(int argc, char* argv[]) {
flist = pa_flist_new(0);
for (i = 0; i < THREADS_MAX; i++) {
- threads[i] = pa_thread_new(thread_func, pa_sprintf_malloc("Thread #%i", i+1));
+ threads[i] = pa_thread_new("test", thread_func, pa_sprintf_malloc("Thread #%i", i+1));
assert(threads[i]);
}
diff --git a/src/tests/format-test.c b/src/tests/format-test.c
new file mode 100644
index 00000000..888db8c9
--- /dev/null
+++ b/src/tests/format-test.c
@@ -0,0 +1,106 @@
+/***
+ This file is part of PulseAudio.
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <stdlib.h>
+
+#include <pulsecore/macro.h>
+#include <pulse/format.h>
+
+#define INIT(f) f = pa_format_info_new()
+#define DEINIT(f) pa_format_info_free(f);
+#define REINIT(f) { DEINIT(f); INIT(f); }
+
+int main(int argc, char *argv[]) {
+ pa_format_info *f1 = NULL, *f2 = NULL;
+ int rates1[] = { 32000, 44100, 48000 };
+ const char *strings[] = { "thing1", "thing2", "thing3" };
+
+ /* 1. Simple fixed format int check */
+ INIT(f1); INIT(f2);
+ f1->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int(f1, PA_PROP_FORMAT_RATE, 32000);
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int(f2, PA_PROP_FORMAT_RATE, 44100);
+ pa_assert(!pa_format_info_is_compatible(f1, f2));
+
+ /* 2. Check int array membership - positive */
+ REINIT(f1); REINIT(f2);
+ f1->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int_array(f1, PA_PROP_FORMAT_RATE, rates1, PA_ELEMENTSOF(rates1));
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int(f2, PA_PROP_FORMAT_RATE, 44100);
+ pa_assert(pa_format_info_is_compatible(f1, f2));
+ pa_assert(pa_format_info_is_compatible(f2, f1));
+
+ /* 3. Check int array memebership - negative */
+ REINIT(f2);
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int(f2, PA_PROP_FORMAT_RATE, 96000);
+ pa_assert(!pa_format_info_is_compatible(f1, f2));
+ pa_assert(!pa_format_info_is_compatible(f2, f1));
+
+ /* 4. Check int range - positive */
+ REINIT(f1); REINIT(f2);
+ f1->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int_range(f1, PA_PROP_FORMAT_RATE, 32000, 48000);
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int(f2, PA_PROP_FORMAT_RATE, 44100);
+ pa_assert(pa_format_info_is_compatible(f1, f2));
+ pa_assert(pa_format_info_is_compatible(f2, f1));
+
+ /* 5. Check int range - negative */
+ REINIT(f2);
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_int(f2, PA_PROP_FORMAT_RATE, 96000);
+ pa_assert(!pa_format_info_is_compatible(f1, f2));
+ pa_assert(!pa_format_info_is_compatible(f2, f1));
+
+ /* 6. Simple fixed format string check */
+ REINIT(f1); REINIT(f2);
+ f1->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_string(f1, "format.test_string", "thing1");
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_string(f2, "format.test_string", "notthing1");
+ pa_assert(!pa_format_info_is_compatible(f1, f2));
+
+ /* 7. Check string array membership - positive */
+ REINIT(f1); REINIT(f2);
+ f1->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_string_array(f1, "format.test_string", strings, PA_ELEMENTSOF(strings));
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_string(f2, "format.test_string", "thing3");
+ pa_assert(pa_format_info_is_compatible(f1, f2));
+ pa_assert(pa_format_info_is_compatible(f2, f1));
+
+ /* 8. Check string array memebership - negative */
+ REINIT(f2);
+ f2->encoding = PA_ENCODING_AC3_IEC61937;
+ pa_format_info_set_prop_string(f2, "format.test_string", "thing5");
+ pa_assert(!pa_format_info_is_compatible(f1, f2));
+ pa_assert(!pa_format_info_is_compatible(f2, f1));
+
+ DEINIT(f1);
+ DEINIT(f2);
+
+ return 0;
+}
diff --git a/src/tests/get-binary-name-test.c b/src/tests/get-binary-name-test.c
index a34e38fd..4afe81b3 100644
--- a/src/tests/get-binary-name-test.c
+++ b/src/tests/get-binary-name-test.c
@@ -21,14 +21,34 @@
#include <config.h>
#endif
-#include <limits.h>
#include <stdio.h>
+#include <string.h>
#include <pulse/util.h>
+#include <pulse/xmalloc.h>
int main(int argc, char *argv[]) {
- char exename[PATH_MAX];
+ char *exename;
+ size_t allocated = 128;
+
+ for (;;) {
+ exename = pa_xmalloc(allocated);
+
+ if (!pa_get_binary_name(exename, allocated)) {
+ printf("failed to read binary name\n");
+ pa_xfree(exename);
+ break;
+ }
+
+ if (strlen(exename) < allocated - 1) {
+ printf("%s\n", exename);
+ pa_xfree(exename);
+ break;
+ }
+
+ pa_xfree(exename);
+ allocated *= 2;
+ }
- printf("%s\n", pa_get_binary_name(exename, sizeof(exename)));
return 0;
}
diff --git a/src/tests/interpol-test.c b/src/tests/interpol-test.c
index 0c906d3e..ffe4ab38 100644
--- a/src/tests/interpol-test.c
+++ b/src/tests/interpol-test.c
@@ -28,8 +28,6 @@
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
-#include <getopt.h>
-#include <math.h>
#include <pulse/pulseaudio.h>
#include <pulse/mainloop.h>
@@ -43,20 +41,37 @@ static pa_context *context = NULL;
static pa_stream *stream = NULL;
static pa_mainloop_api *mainloop_api = NULL;
static pa_bool_t playback = TRUE;
+static pa_usec_t latency = 0;
static void stream_write_cb(pa_stream *p, size_t nbytes, void *userdata) {
/* Just some silence */
- pa_assert_se(pa_stream_write(p, pa_xmalloc0(nbytes), nbytes, pa_xfree, 0, PA_SEEK_RELATIVE) == 0);
+
+ for (;;) {
+ void *data;
+
+ pa_assert_se((nbytes = pa_stream_writable_size(p)) != (size_t) -1);
+
+ if (nbytes <= 0)
+ break;
+
+ pa_assert_se(pa_stream_begin_write(p, &data, &nbytes) == 0);
+ pa_memzero(data, nbytes);
+ pa_assert_se(pa_stream_write(p, data, nbytes, NULL, 0, PA_SEEK_RELATIVE) == 0);
+ }
}
static void stream_read_cb(pa_stream *p, size_t nbytes, void *userdata) {
- /* We don't care, just drop the data */
+ /* We don't care about the data, just drop it */
- while (pa_stream_readable_size(p) > 0) {
- const void *d;
- size_t b;
+ for (;;) {
+ const void *data;
- pa_assert_se(pa_stream_peek(p, &d, &b) == 0);
+ pa_assert_se((nbytes = pa_stream_readable_size(p)) != (size_t) -1);
+
+ if (nbytes <= 0)
+ break;
+
+ pa_assert_se(pa_stream_peek(p, &data, &nbytes) == 0);
pa_assert_se(pa_stream_drop(p) == 0);
}
}
@@ -82,27 +97,36 @@ static void context_state_callback(pa_context *c, void *userdata) {
case PA_CONTEXT_READY: {
pa_stream_flags_t flags = PA_STREAM_AUTO_TIMING_UPDATE;
-
+ pa_buffer_attr attr;
static const pa_sample_spec ss = {
.format = PA_SAMPLE_S16LE,
.rate = 44100,
.channels = 2
};
+ pa_zero(attr);
+ attr.maxlength = (uint32_t) -1;
+ attr.tlength = latency > 0 ? (uint32_t) pa_usec_to_bytes(latency, &ss) : (uint32_t) -1;
+ attr.prebuf = (uint32_t) -1;
+ attr.minreq = (uint32_t) -1;
+ attr.fragsize = (uint32_t) -1;
+
#ifdef INTERPOLATE
flags |= PA_STREAM_INTERPOLATE_TIMING;
#endif
+ if (latency > 0)
+ flags |= PA_STREAM_ADJUST_LATENCY;
+
fprintf(stderr, "Connection established.\n");
- stream = pa_stream_new(c, "interpol-test", &ss, NULL);
- assert(stream);
+ pa_assert_se(stream = pa_stream_new(c, "interpol-test", &ss, NULL));
if (playback) {
- pa_assert_se(pa_stream_connect_playback(stream, NULL, NULL, flags, NULL, NULL) == 0);
+ pa_assert_se(pa_stream_connect_playback(stream, NULL, &attr, flags, NULL, NULL) == 0);
pa_stream_set_write_callback(stream, stream_write_cb, NULL);
} else {
- pa_assert_se(pa_stream_connect_record(stream, NULL, NULL, flags) == 0);
+ pa_assert_se(pa_stream_connect_record(stream, NULL, &attr, flags) == 0);
pa_stream_set_read_callback(stream, stream_read_cb, NULL);
}
@@ -123,7 +147,7 @@ static void context_state_callback(pa_context *c, void *userdata) {
int main(int argc, char *argv[]) {
pa_threaded_mainloop* m = NULL;
- int k, r;
+ int k;
struct timeval start, last_info = { 0, 0 };
pa_usec_t old_t = 0, old_rtc = 0;
#ifdef CORK
@@ -134,24 +158,22 @@ int main(int argc, char *argv[]) {
playback = argc <= 1 || !pa_streq(argv[1], "-r");
- /* Set up a new main loop */
- m = pa_threaded_mainloop_new();
- assert(m);
-
- mainloop_api = pa_threaded_mainloop_get_api(m);
+ latency =
+ (argc >= 2 && !pa_streq(argv[1], "-r")) ? atoi(argv[1]) :
+ (argc >= 3 ? atoi(argv[2]) : 0);
- context = pa_context_new(mainloop_api, argv[0]);
- assert(context);
+ /* Set up a new main loop */
+ pa_assert_se(m = pa_threaded_mainloop_new());
+ pa_assert_se(mainloop_api = pa_threaded_mainloop_get_api(m));
+ pa_assert_se(context = pa_context_new(mainloop_api, argv[0]));
pa_context_set_state_callback(context, context_state_callback, NULL);
- r = pa_context_connect(context, NULL, 0, NULL);
- assert(r >= 0);
+ pa_assert_se(pa_context_connect(context, NULL, 0, NULL) >= 0);
pa_gettimeofday(&start);
- r = pa_threaded_mainloop_start(m);
- assert(r >= 0);
+ pa_assert_se(pa_threaded_mainloop_start(m) >= 0);
/* #ifdef CORK */
for (k = 0; k < 20000; k++)
@@ -160,7 +182,7 @@ int main(int argc, char *argv[]) {
/* #endif */
{
pa_bool_t success = FALSE, changed = FALSE;
- pa_usec_t t, rtc;
+ pa_usec_t t, rtc, d;
struct timeval now, tv;
pa_bool_t playing = FALSE;
@@ -169,7 +191,8 @@ int main(int argc, char *argv[]) {
if (stream) {
const pa_timing_info *info;
- if (pa_stream_get_time(stream, &t) >= 0)
+ if (pa_stream_get_time(stream, &t) >= 0 &&
+ pa_stream_get_latency(stream, &d, NULL) >= 0)
success = TRUE;
if ((info = pa_stream_get_timing_info(stream))) {
@@ -191,14 +214,16 @@ int main(int argc, char *argv[]) {
pa_bool_t cork_now;
#endif
rtc = pa_timeval_diff(&now, &start);
- printf("%i\t%llu\t%llu\t%llu\t%llu\t%lli\t%u\t%u\n", k,
+ printf("%i\t%llu\t%llu\t%llu\t%llu\t%lli\t%u\t%u\t%llu\t%llu\n", k,
(unsigned long long) rtc,
(unsigned long long) t,
(unsigned long long) (rtc-old_rtc),
(unsigned long long) (t-old_t),
(signed long long) rtc - (signed long long) t,
changed,
- playing);
+ playing,
+ (unsigned long long) latency,
+ (unsigned long long) d);
fflush(stdout);
old_t = t;
diff --git a/src/tests/ipacl-test.c b/src/tests/ipacl-test.c
index f89665cd..be9caadf 100644
--- a/src/tests/ipacl-test.c
+++ b/src/tests/ipacl-test.c
@@ -8,9 +8,6 @@
#include <assert.h>
#include <string.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
@@ -20,14 +17,11 @@
#ifdef HAVE_NETINET_IP_H
#include <netinet/ip.h>
#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
-
-#include "../pulsecore/winsock.h"
-#include "../pulsecore/macro.h"
+#include <pulsecore/socket.h>
+#include <pulsecore/macro.h>
#include <pulsecore/ipacl.h>
+#include <pulsecore/arpa-inet.h>
int main(int argc, char *argv[]) {
struct sockaddr_in sa;
@@ -91,8 +85,10 @@ int main(int argc, char *argv[]) {
close(fd);
#ifdef HAVE_IPV6
- fd = socket(PF_INET6, SOCK_STREAM, 0);
- assert(fd >= 0);
+ if ( (fd = socket(PF_INET6, SOCK_STREAM, 0)) < 0 ) {
+ printf("Unable to open IPv6 socket, IPv6 tests ignored");
+ return 0;
+ }
memset(&sa6, 0, sizeof(sa6));
sa6.sin6_family = AF_INET6;
diff --git a/src/tests/lock-autospawn-test.c b/src/tests/lock-autospawn-test.c
index c754e230..9ba61296 100644
--- a/src/tests/lock-autospawn-test.c
+++ b/src/tests/lock-autospawn-test.c
@@ -23,9 +23,9 @@
#include <config.h>
#endif
-#include <sys/poll.h>
#include <string.h>
+#include <pulsecore/poll.h>
#include <pulsecore/macro.h>
#include <pulsecore/thread.h>
#include <pulsecore/lock-autospawn.h>
@@ -69,7 +69,7 @@ static void thread_func2(void *k) {
pollfd.fd = fd;
pollfd.events = POLLIN;
- pa_assert_se(poll(&pollfd, 1, -1) == 1);
+ pa_assert_se(pa_poll(&pollfd, 1, -1) == 1);
pa_log("%i, woke up", PA_PTR_TO_INT(k));
}
@@ -88,10 +88,10 @@ static void thread_func2(void *k) {
int main(int argc, char**argv) {
pa_thread *a, *b, *c, *d;
- pa_assert_se((a = pa_thread_new(thread_func, PA_INT_TO_PTR(1))));
- pa_assert_se((b = pa_thread_new(thread_func2, PA_INT_TO_PTR(2))));
- pa_assert_se((c = pa_thread_new(thread_func2, PA_INT_TO_PTR(3))));
- pa_assert_se((d = pa_thread_new(thread_func, PA_INT_TO_PTR(4))));
+ pa_assert_se((a = pa_thread_new("test1", thread_func, PA_INT_TO_PTR(1))));
+ pa_assert_se((b = pa_thread_new("test2", thread_func2, PA_INT_TO_PTR(2))));
+ pa_assert_se((c = pa_thread_new("test3", thread_func2, PA_INT_TO_PTR(3))));
+ pa_assert_se((d = pa_thread_new("test4", thread_func, PA_INT_TO_PTR(4))));
pa_thread_join(a);
pa_thread_join(b);
diff --git a/src/tests/mainloop-test.c b/src/tests/mainloop-test.c
index 4ca63513..ab23de43 100644
--- a/src/tests/mainloop-test.c
+++ b/src/tests/mainloop-test.c
@@ -26,10 +26,11 @@
#include <sys/time.h>
#include <assert.h>
+#include <pulse/rtclock.h>
#include <pulse/timeval.h>
-#include <pulse/gccmacro.h>
#include <pulsecore/core-util.h>
+#include <pulsecore/core-rtclock.h>
#ifdef GLIB_MAIN_LOOP
@@ -46,7 +47,7 @@ static pa_defer_event *de;
static void iocb(pa_mainloop_api*a, pa_io_event *e, int fd, pa_io_event_flags_t f, void *userdata) {
unsigned char c;
- (void) read(fd, &c, sizeof(c));
+ pa_assert_se(read(fd, &c, sizeof(c)) >= 0);
fprintf(stderr, "IO EVENT: %c\n", c < 32 ? '.' : c);
a->defer_enable(de, 1);
}
@@ -99,9 +100,7 @@ int main(int argc, char *argv[]) {
de = a->defer_new(a, dcb, NULL);
assert(de);
- pa_gettimeofday(&tv);
- tv.tv_sec += 10;
- te = a->time_new(a, &tv, tcb, NULL);
+ te = a->time_new(a, pa_timeval_rtstore(&tv, pa_rtclock_now() + 2 * PA_USEC_PER_SEC, TRUE), tcb, NULL);
#if defined(GLIB_MAIN_LOOP)
g_main_loop_run(glib_main_loop);
diff --git a/src/tests/mcalign-test.c b/src/tests/mcalign-test.c
index 92e3e14e..75a71dd1 100644
--- a/src/tests/mcalign-test.c
+++ b/src/tests/mcalign-test.c
@@ -29,8 +29,6 @@
#include <stdlib.h>
#include <time.h>
-#include <pulse/gccmacro.h>
-
#include <pulsecore/core-util.h>
#include <pulsecore/mcalign.h>
diff --git a/src/tests/memblockq-test.c b/src/tests/memblockq-test.c
index ec3f5426..b6c60039 100644
--- a/src/tests/memblockq-test.c
+++ b/src/tests/memblockq-test.c
@@ -29,23 +29,39 @@
#include <pulsecore/memblockq.h>
#include <pulsecore/log.h>
+static void dump_chunk(const pa_memchunk *chunk) {
+ size_t n;
+ void *q;
+ char *e;
+
+ pa_assert(chunk);
+
+ q = pa_memblock_acquire(chunk->memblock);
+ for (e = (char*) q + chunk->index, n = 0; n < chunk->length; n++, e++)
+ printf("%c", *e);
+ pa_memblock_release(chunk->memblock);
+}
+
static void dump(pa_memblockq *bq) {
- printf(">");
+ pa_memchunk out;
- for (;;) {
- pa_memchunk out;
- char *e;
- size_t n;
- void *q;
+ pa_assert(bq);
+ /* First let's dump this as fixed block */
+ printf("FIXED >");
+ pa_memblockq_peek_fixed_size(bq, 64, &out);
+ dump_chunk(&out);
+ pa_memblock_unref(out.memblock);
+ printf("<\n");
+
+ /* Then let's dump the queue manually */
+ printf("MANUAL>");
+
+ for (;;) {
if (pa_memblockq_peek(bq, &out) < 0)
break;
- q = pa_memblock_acquire(out.memblock);
- for (e = (char*) q + out.index, n = 0; n < out.length; n++)
- printf("%c", *e);
- pa_memblock_release(out.memblock);
-
+ dump_chunk(&out);
pa_memblock_unref(out.memblock);
pa_memblockq_drop(bq, out.length);
}
@@ -65,12 +81,12 @@ int main(int argc, char *argv[]) {
p = pa_mempool_new(FALSE, 0);
- silence.memblock = pa_memblock_new_fixed(p, (char*) "__", 2, 1);
+ silence.memblock = pa_memblock_new_fixed(p, (char*) "__", 2, 1);
assert(silence.memblock);
silence.index = 0;
silence.length = pa_memblock_get_length(silence.memblock);
- bq = pa_memblockq_new(0, 40, 10, 2, 4, 4, 40, &silence);
+ bq = pa_memblockq_new(0, 200, 10, 2, 4, 4, 40, &silence);
assert(bq);
chunk1.memblock = pa_memblock_new_fixed(p, (char*) "11", 2, 1);
diff --git a/src/tests/mix-test.c b/src/tests/mix-test.c
index ac4b57b5..7c05b8ed 100644
--- a/src/tests/mix-test.c
+++ b/src/tests/mix-test.c
@@ -26,20 +26,11 @@
#include <pulse/sample.h>
#include <pulse/volume.h>
-#include <pulsecore/resampler.h>
#include <pulsecore/macro.h>
#include <pulsecore/endianmacros.h>
#include <pulsecore/memblock.h>
#include <pulsecore/sample-util.h>
-#include <liboil/liboil.h>
-
-static float swap_float(float a) {
- uint32_t *b = (uint32_t*) &a;
- *b = PA_UINT32_SWAP(*b);
- return a;
-}
-
static void dump_block(const pa_sample_spec *ss, const pa_memchunk *chunk) {
void *d;
unsigned i;
@@ -69,6 +60,8 @@ static void dump_block(const pa_sample_spec *ss, const pa_memchunk *chunk) {
break;
}
+ case PA_SAMPLE_S24_32NE:
+ case PA_SAMPLE_S24_32RE:
case PA_SAMPLE_S32NE:
case PA_SAMPLE_S32RE: {
uint32_t *u = d;
@@ -79,12 +72,24 @@ static void dump_block(const pa_sample_spec *ss, const pa_memchunk *chunk) {
break;
}
+ case PA_SAMPLE_S24NE:
+ case PA_SAMPLE_S24RE: {
+ uint8_t *u = d;
+
+ for (i = 0; i < chunk->length / pa_frame_size(ss); i++) {
+ printf("0x%02x%02x%02xx ", *u, *(u+1), *(u+2));
+ u += 3;
+ }
+
+ break;
+ }
+
case PA_SAMPLE_FLOAT32NE:
case PA_SAMPLE_FLOAT32RE: {
float *u = d;
for (i = 0; i < chunk->length / pa_frame_size(ss); i++) {
- printf("%1.5f ", ss->format == PA_SAMPLE_FLOAT32NE ? *u : swap_float(*u));
+ printf("%1.5f ", ss->format == PA_SAMPLE_FLOAT32NE ? *u : PA_FLOAT32_SWAP(*u));
u++;
}
@@ -113,73 +118,72 @@ static pa_memblock* generate_block(pa_mempool *pool, const pa_sample_spec *ss) {
case PA_SAMPLE_U8:
case PA_SAMPLE_ULAW:
case PA_SAMPLE_ALAW: {
- uint8_t *u = d;
+ static const uint8_t u8_samples[] = {
+ 0x00, 0xFF, 0x7F, 0x80, 0x9f,
+ 0x3f, 0x01, 0xF0, 0x20, 0x21
+ };
- u[0] = 0x00;
- u[1] = 0xFF;
- u[2] = 0x7F;
- u[3] = 0x80;
- u[4] = 0x9f;
- u[5] = 0x3f;
- u[6] = 0x1;
- u[7] = 0xF0;
- u[8] = 0x20;
- u[9] = 0x21;
+ memcpy(d, u8_samples, sizeof(u8_samples));
break;
}
case PA_SAMPLE_S16NE:
case PA_SAMPLE_S16RE: {
- uint16_t *u = d;
+ static const uint16_t u16_samples[] = {
+ 0x0000, 0xFFFF, 0x7FFF, 0x8000, 0x9fff,
+ 0x3fff, 0x0001, 0xF000, 0x0020, 0x0021
+ };
- u[0] = 0x0000;
- u[1] = 0xFFFF;
- u[2] = 0x7FFF;
- u[3] = 0x8000;
- u[4] = 0x9fff;
- u[5] = 0x3fff;
- u[6] = 0x1;
- u[7] = 0xF000;
- u[8] = 0x20;
- u[9] = 0x21;
+ memcpy(d, u16_samples, sizeof(u16_samples));
break;
}
+ case PA_SAMPLE_S24_32NE:
+ case PA_SAMPLE_S24_32RE:
case PA_SAMPLE_S32NE:
case PA_SAMPLE_S32RE: {
- uint32_t *u = d;
+ static const uint32_t u32_samples[] = {
+ 0x00000001, 0xFFFF0002, 0x7FFF0003, 0x80000004, 0x9fff0005,
+ 0x3fff0006, 0x00010007, 0xF0000008, 0x00200009, 0x0021000A
+ };
+
+ memcpy(d, u32_samples, sizeof(u32_samples));
+ break;
+ }
- u[0] = 0x00000001;
- u[1] = 0xFFFF0002;
- u[2] = 0x7FFF0003;
- u[3] = 0x80000004;
- u[4] = 0x9fff0005;
- u[5] = 0x3fff0006;
- u[6] = 0x10007;
- u[7] = 0xF0000008;
- u[8] = 0x200009;
- u[9] = 0x21000A;
+ case PA_SAMPLE_S24NE:
+ case PA_SAMPLE_S24RE: {
+ /* Need to be on a byte array because they are not aligned */
+ static const uint8_t u24_samples[] = {
+ 0x00, 0x00, 0x01,
+ 0xFF, 0xFF, 0x02,
+ 0x7F, 0xFF, 0x03,
+ 0x80, 0x00, 0x04,
+ 0x9f, 0xff, 0x05,
+ 0x3f, 0xff, 0x06,
+ 0x01, 0x00, 0x07,
+ 0xF0, 0x00, 0x08,
+ 0x20, 0x00, 0x09,
+ 0x21, 0x00, 0x0A
+ };
+
+ memcpy(d, u24_samples, sizeof(u24_samples));
break;
}
case PA_SAMPLE_FLOAT32NE:
case PA_SAMPLE_FLOAT32RE: {
float *u = d;
+ static const float float_samples[] = {
+ 0.0f, -1.0f, 1.0f, 4711.0f, 0.222f,
+ 0.33f, -.3f, 99.0f, -0.555f, -.123f
+ };
- u[0] = 0.0f;
- u[1] = -1.0f;
- u[2] = 1.0f;
- u[3] = 4711.0f;
- u[4] = 0.222f;
- u[5] = 0.33f;
- u[6] = -.3f;
- u[7] = 99.0f;
- u[8] = -0.555f;
- u[9] = -.123f;
-
- if (ss->format == PA_SAMPLE_FLOAT32RE)
+ if (ss->format == PA_SAMPLE_FLOAT32RE) {
for (i = 0; i < 10; i++)
- u[i] = swap_float(u[i]);
+ u[i] = PA_FLOAT32_SWAP(float_samples[i]);
+ } else
+ memcpy(d, float_samples, sizeof(float_samples));
break;
}
@@ -198,7 +202,6 @@ int main(int argc, char *argv[]) {
pa_sample_spec a;
pa_cvolume v;
- oil_init();
pa_log_set_level(PA_LOG_DEBUG);
pa_assert_se(pool = pa_mempool_new(FALSE, 0));
diff --git a/src/tests/once-test.c b/src/tests/once-test.c
new file mode 100644
index 00000000..8a9995da
--- /dev/null
+++ b/src/tests/once-test.c
@@ -0,0 +1,111 @@
+/***
+ This file is part of PulseAudio.
+
+ PulseAudio is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published
+ by the Free Software Foundation; either version 2.1 of the License,
+ or (at your option) any later version.
+
+ PulseAudio is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with PulseAudio; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ USA.
+***/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#ifdef HAVE_PTHREAD
+#include <pthread.h>
+#endif
+
+#include <pulsecore/thread.h>
+#include <pulsecore/once.h>
+#include <pulsecore/log.h>
+#include <pulsecore/core-util.h>
+#include <pulsecore/atomic.h>
+#include <pulse/xmalloc.h>
+
+static pa_once once = PA_ONCE_INIT;
+static volatile unsigned n_run = 0;
+static const char * volatile ran_by = NULL;
+#ifdef HAVE_PTHREAD
+static pthread_barrier_t barrier;
+#endif
+static unsigned n_cpu;
+
+#define N_ITERATIONS 500
+#define N_THREADS 100
+
+static void once_func(void) {
+ n_run++;
+ ran_by = (const char*) pa_thread_get_data(pa_thread_self());
+}
+
+static void thread_func(void *data) {
+#ifdef HAVE_PTHREAD
+ int r;
+
+#ifdef HAVE_PTHREAD_SETAFFINITY_NP
+ static pa_atomic_t i_cpu = PA_ATOMIC_INIT(0);
+ cpu_set_t mask;
+
+ CPU_ZERO(&mask);
+ CPU_SET((size_t) (pa_atomic_inc(&i_cpu) % n_cpu), &mask);
+ pa_assert_se(pthread_setaffinity_np(pthread_self(), sizeof(mask), &mask) == 0);
+#endif
+
+ /* pa_log("started up: %s", data); */
+
+ r = pthread_barrier_wait(&barrier);
+ pa_assert(r == 0 || r == PTHREAD_BARRIER_SERIAL_THREAD);
+#endif /* HAVE_PTHREAD */
+
+ pa_run_once(&once, once_func);
+}
+
+int main(int argc, char *argv[]) {
+ unsigned n, i;
+
+ n_cpu = pa_ncpus();
+
+ for (n = 0; n < N_ITERATIONS; n++) {
+ pa_thread* threads[N_THREADS];
+
+#ifdef HAVE_PTHREAD
+ pa_assert_se(pthread_barrier_init(&barrier, NULL, N_THREADS) == 0);
+#endif
+
+ /* Yes, kinda ugly */
+ pa_zero(once);
+
+ for (i = 0; i < N_THREADS; i++)
+ threads[i] = pa_thread_new("once", thread_func, pa_sprintf_malloc("Thread #%i", i+1));
+
+ for (i = 0; i < N_THREADS; i++)
+ pa_thread_join(threads[i]);
+
+ pa_assert(n_run == 1);
+ pa_log("ran by %s", ran_by);
+
+ for (i = 0; i < N_THREADS; i++) {
+ pa_xfree(pa_thread_get_data(threads[i]));
+ pa_thread_free(threads[i]);
+ }
+
+ n_run = 0;
+ ran_by = NULL;
+
+#ifdef HAVE_PTHREAD
+ pa_assert_se(pthread_barrier_destroy(&barrier) == 0);
+#endif
+ }
+
+ return 0;
+}
diff --git a/src/tests/pacat-simple.c b/src/tests/pacat-simple.c
index d4224e11..7d119c44 100644
--- a/src/tests/pacat-simple.c
+++ b/src/tests/pacat-simple.c
@@ -29,7 +29,6 @@
#include <pulse/simple.h>
#include <pulse/error.h>
-#include <pulse/gccmacro.h>
#define BUFSIZE 1024
diff --git a/src/tests/parec-simple.c b/src/tests/parec-simple.c
index 9f19ff47..dfa43f0f 100644
--- a/src/tests/parec-simple.c
+++ b/src/tests/parec-simple.c
@@ -28,7 +28,6 @@
#include <pulse/simple.h>
#include <pulse/error.h>
-#include <pulse/gccmacro.h>
#define BUFSIZE 1024
diff --git a/src/tests/queue-test.c b/src/tests/queue-test.c
index 7ee2693d..b21775e8 100644
--- a/src/tests/queue-test.c
+++ b/src/tests/queue-test.c
@@ -25,11 +25,8 @@
#include <stdlib.h>
#include <unistd.h>
-#include <pulse/util.h>
-#include <pulse/xmalloc.h>
#include <pulsecore/queue.h>
#include <pulsecore/log.h>
-#include <pulsecore/core-util.h>
#include <pulsecore/macro.h>
int main(int argc, char *argv[]) {
diff --git a/src/tests/remix-test.c b/src/tests/remix-test.c
index 9d110d6b..19f5582b 100644
--- a/src/tests/remix-test.c
+++ b/