[pulseaudio-discuss] Re(surrect): [PATCH] vala: Add bindings for libpulse-simple

2014-04-01 Thread Bálint Réczey
Hi,

There has been a proposed patch sent to this list [1] which has been
accepted in email [2] but never committed.
Could someone with commit access please commit it?

Thanks,
Balint

[1] 
http://lists.freedesktop.org/archives/pulseaudio-discuss/2012-January/012731.html
[2] 
http://lists.freedesktop.org/archives/pulseaudio-discuss/2012-February/012896.html
___
pulseaudio-discuss mailing list
pulseaudio-discuss@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss


Re: [pulseaudio-discuss] On scaling the HRIR in module-virtual-surround-sink

2014-04-01 Thread Niels Ole Salscheider
Hello Alexander,

On Tuesday 11 March 2014, 15:00:31, Tanu Kaskinen wrote:
 On Sun, 2014-03-09 at 00:57 +0600, Alexander E. Patrakov wrote:
  Hello.
  
  [Do not blindly apply patches from this e-mail! They mutually exclusive,
  and I don't have a firm opinion which one of them is correct.]
  
  Today I tried to improve the existing module-virtual-surround-sink (but
  the same issue also affects the IIR-based rewrite that is still sitting
  on my laptop). The problem is: the current normalization code does not
  do what it is designed to do. The module clips on some testcases. Let me
  copy-paste the problematic code for easy discussion.
 
 snip
 
  Thoughts?
 
 My thoughts:
 
 The scaling should be put in its own function with a comment that
 explains why the scaling is done, a high level description of how the
 scaling algorithm works, and a note that it's unclear whether the
 algorithm actually makes sense. Something like this could be included
 too: This algorithm doesn't pretend to be perfect, it's just something
 that appears to work (not too quiet, no audible clipping) on the
 material that it has been tested on. If you find a real-world example
 where this algorithm results in audible clipping, please write a patch
 that adjusts the scaling factor constants or improves the algorithm (or
 if you can't write a patch, at least report the problem to the
 PulseAudio mailing list or bug tracker).

Would you like to write such a patch or should I do it? Or do you have an idea 
for a better heuristic?

Regards,

Ole
___
pulseaudio-discuss mailing list
pulseaudio-discuss@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss


Re: [pulseaudio-discuss] On scaling the HRIR in module-virtual-surround-sink

2014-04-01 Thread Alexander E. Patrakov
2014-04-02 1:48 GMT+06:00 Niels Ole Salscheider
niels_...@salscheider-online.de:

 Would you like to write such a patch or should I do it? Or do you have an idea
 for a better heuristic?

I do have an idea for a possibly-better heuristic (see below).
However, I have caught a cold, and there is also an extraordinary
number of DNS queries we (SafeDNS) get from Turkish users right now,
leading to server load issues. So, my health and my work are
priorities now :(

So, please submit a patch.

A possibly-better but untested heuristic is as follows, and I do
intend to implement it later, after the Turkish YouTube/DNS situation
settles.

1. Collect spectrum and inter-channel correlation data from some music
DVDs, take an average.

2. Synthesize a short signal that has roughly the same characteristics.

3. Filter it through the A-weighing filter (see the transfer function
in Wikipedia, it is a rational function = the filter is implementable
as IIR).

4. Store the result as a short sequence of samples in PA source code.

5. When loading a filter from a wav file, apply it to the test signal
from step (4).

6. Take the sum of squares of samples sent to the left headphone. This
(due to A-weighing) would represent the subjective loudness of the
filtered music.

7. Compare that to the sum of squares of samples sent through the
conventional downmixer. Compensate accordingly by scaling the loaded
filter.

The result should be that the audio filtered through your module and
through the conventional downmixer (in src/pulsecore/resampler.c), in
average for the music material, would be of the same subjective
loudness. I am not sure if that would be sufficient to eliminate the
clipping, but we can always multiply the result by the fudge factor
later if needed.

-- 
Alexander E. Patrakov
___
pulseaudio-discuss mailing list
pulseaudio-discuss@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss