GNOME Bugzilla – Bug 748068
equalizer: not changing settings dynamically
Last modified: 2015-09-09 03:16:14 UTC
Created attachment 301863 [details] [review] we need update_coefficients () to run for the dynamic changes in the bands' properties When doing something like this the audio is clearly equalized. gst-launch-1.0 filesrc location=sample.mp3 ! mad ! audioconvert ! equalizer-3bands band1=-12.0 band2=-24.0 ! audioconvert ! autoaudiosink But when running the equalizer application in tests/examples/equalizer/, moving the sliders doesn't change the audio at all.
The equalizer application to test this is: gst-plugins-good/tests/examples/equalizer/demo
Comment on attachment 301863 [details] [review] we need update_coefficients () to run for the dynamic changes in the bands' properties Additionally you should ideally check in transform_ip() if it is passthrough or not with the current coefficients. Also changing the coefficients should disable passthrough mode (unless changed back to doing nothing). So in theory this commit shouldn't be necessary, unless a) bug in basetransform or b) we don't unset passthrough when properties change
OK. I will check if it is A or B tomorrow.
So it is B. Passthrough isn't being unset when the properties change. Writing a fix for that now.
Created attachment 302085 [details] [review] equalizer: fix dynamic changes on bands Move the passthrough check from the transform function to when the gain properties are changed. Currently when we are in passthrough, even after the gains change the passthrough check never happens because it is inside the transform function which doesn't run. This fix moves this check to the set_property() function, so whenever the gain coefficient changes we check if they are all 0.0 and we can passthrough. I also set the passthrough to TRUE at init because the gains default to 0, so we can passthrough until any gain property is changed. Tested with both gst-launch-1.0 (properties set before rolling) and test/examples/equalizer/demo (everything default to 0.0 and changed dynamically while rolling).
Comment on attachment 302085 [details] [review] equalizer: fix dynamic changes on bands Makes sense but please explain in the commit message why checking in transform_ip() is not useful (as it will never be called in passthrough)
Review of attachment 302085 [details] [review]: commit c884a3b3a5569aa8ada440e423b90618b74b01ab
Thanks Sebastian :)
Hi, Excuse the intrusion into a closed bug, but blease, can backport it to Gstreamer 1.4? I delayed a new version of Pragha at least two months thinking that my code had a problem.. and just now I found this bug. I work with Debian and Fedora, and both use this branch, which has the bug, and surely all stable distributions have it. Regards, Matias.