Ticket #314 (closed defect: fixed)

Opened 3 months ago

Last modified 6 days ago

Setting initial volume via pa_stream_connect_playback() does not work

Reported by: slomo Assigned to: lennart
Priority: normal Milestone: 0.9.12
Component: daemon Severity: normal
Keywords: Cc:

Description

Hi, with pulseaudio 0.9.10 (the current Debian package) it's not possible to set the initial volume via pa_stream_connect_playback(). This doesn't work with my own code and doesn't work with paplay.

The backend used is ALSA and the ymfpci driver.

Change History

06/26/08 19:09:02 changed by lennart

You are aware that this won't change the sink volume, but only the sink input volume?

Also, note that stuff like module-volume-restore might overwrite what you specified.

06/27/08 11:04:05 changed by slomo

No, I wasn't aware of that. But then paplay's volume parameter is confusing, I'd expect it to simply scale the audio played according to that volume.

To specify a bit more what I want, I'm adding a volume property to the GStreamer pulsesink. This should act as if the audio is simply scaled.

My plan was to a) set a initial volume according to that property and b) adjust the volume whenever this property is changed. How can I do that? Is it possible at all? For b) there seems to be pa_context_set_sink_volume_by_index(), right?

08/15/08 14:52:47 changed by lennart

I think we have a misunderstanding here what a "sink" is. The GstPulseSink? wraps a "sink input" in pulse talk, which then connects to a proper "sink".

I think the problem you might be encountering is that module-volume-restore overwrites the volume you passed from what it restored. I need to fix that.

10/01/08 01:44:15 changed by lennart

  • status changed from new to closed.
  • resolution set to fixed.

It is now fixed if you use the new module-stream-restore instead of module-volume-restore. m-s-r has been made made the default in 0.9.12.

10/01/08 03:30:18 changed by lennart

  • milestone set to 0.9.12.