On Thu, 2012-07-19 at 14:35 -0300, Flavio Ceolin wrote: > Hi floks, > > I'm trying to implement support for audio envelopes on pulse audio and > several doubts come to me. First i've checked that we already had > support for it, but it was removed. So my first doubt is, there were > problems with this code or it was removed just because no one was using ? There were problems with the code. I don't remember what exactly was broken, though. But at least I didn't like the concurrency handling: I really dislike doing inter-thread communication by using shared variables. Instead, message passing should be used, in my opinion. > For purpose tests, i've re-applied the old code (doing just the necessary > things to compile). So far so good, it was pretty easy. Now i've other > questions: > > 1) Should evenlopes be applied in source too, or just in the sink ? Probably also in sources, but I think you don't need to care about sources at this point. Once it's done for sinks, then we can copy it to sources. > 2) How an application should use this code, AFAIK this code is not being > exported. What's your use case? If we are talking about sink volume ramping, I don't see the need for a client interface at all, because it should be done automatically by the server. > Besides these points, i would enjoy any kind of tip/idea related with > this subject. You'll need to keep rewinds in mind. That is, if a rewind affects the envelope, you need to update the envelope state accordingly. -- Tanu