-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
improve audio level display #197
Conversation
After a first profiling session with voctogui I realized a CPU usage peak at audioleveldisplay.py:22(on_draw). This drawing routine uses move-to and line-to to create a gradient for displaying the audio levels which I found quite expensive. I replaced it by code which draws four rectangles for every channel by using cairo gradients which works much faster. By doing this I accidentally changed the look quite a bit, because the gradient calculation is now a little different. I don't know the original goal for the look but one can now easily change the gradient look by changing the values of XXX_fade in lines 50..53 and the gradient stops themselves in lines 57..59, 62..64, 67..69 and 72..74. So for example if you like to have a larger green zone we could add another green stop and so start the yellow a bit higher. Suggestions welcome.
also reduced code amount gradient stops now could be changed in gradient() in line 24 and brightnesses in line 64..67
text is now rendered over the most right channel bar and inverted if this bar gets bright
@fightling Would mind if I enable branch restrictions on the master-branch so that it can no longer be directly pushed to? This might help to avoid such accidents which I also have done more then once. |
+1 enable branch restrictions on the master-branch
which I also have done
I think everyone does that ;)
…On Wed, Apr 18, 2018 at 4:17 AM, Peter ***@***.***> wrote:
@fightling <https://github.com/fightling> Would mind if I enable branch
restrictions on the master-branch so that it can no longer be directly
pushed to? This might help to avoid such accidents which I also have done
more then once.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#197 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AABauQg-Xc8jAdNya-OIAuagLsw2W5_Wks5tpwS8gaJpZM4TZHD0>
.
--
Carl K
|
Yes, please! I'm so sorry! I just didn't realized that I had switched
back to master to get a comparison screen shot from the original
version! shame on me.
…On 18.04.2018 15:51, Carl Karsten wrote:
+1 enable branch restrictions on the master-branch
> which I also have done
I think everyone does that ;)
On Wed, Apr 18, 2018 at 4:17 AM, Peter ***@***.***> wrote:
> @fightling <https://github.com/fightling> Would mind if I enable branch
> restrictions on the master-branch so that it can no longer be directly
> pushed to? This might help to avoid such accidents which I also have
done
> more then once.
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub
> <#197 (comment)>,
or mute
> the thread
>
<https://github.com/notifications/unsubscribe-auth/AABauQg-Xc8jAdNya-OIAuagLsw2W5_Wks5tpwS8gaJpZM4TZHD0>
> .
>
--
Carl K
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#197 (comment)>, or
mute the thread
<https://github.com/notifications/unsubscribe-auth/AACpkYrgrOLok7OlTmWmmWv9PcdQokpeks5tp0T4gaJpZM4TZHD0>.
--
Regards, Patrick
DON'T PANIC!
If you like privacy get my PGP key from: hkp://pool.sks-keyservers.net
or download from: http://patsite.de/pgp.asc
|
@fightling no worries, happened to everyone. I enabled branch protection for master ans also force-push-removed your commits from there, because they still failed the travis build. Please ensure to merge your PRs into the git@c3voc.de:voctomix.git repo, as the github-repo is only a mirror (which is overwritten by the state of the above mentioned repo). Anyone of the VOC core team can add your ssh-key there, you cann mail/chat it to me if you want. |
The travis warnings are not originated in the files I have changed. I already have a patch to fix all these warnings lying in my local repro. But at least in one case I'm not sure that my change is neutral and correct. Should I push it into a new branch review/fixing-pep8-warnings or something similar and then we can discuss my changes? |
@fightling absolutely! I'll take a closer look at this PR later this day. |
Merged to get travis fixed from pull request:Review/fix travis issues #198
Merged master to get travis fixes |
@fightling I guess you decided to not center the text for better readability? I kind'a liked them better centered, but I guess that's a case of personal opinion :D |
Improved CPU usage and look of the audio level display
After a first profiling session with voctogui I realized a CPU usage
peak at audioleveldisplay.py:22(on_draw). This drawing routine uses
move-to and line-to to create a gradient for displaying the audio levels
which I found quite expensive. I replaced it by code which draws four
rectangles for every channel by using cairo gradients which works much
faster.
Sorry for the temporary mess on the master branch where I accidentally committed eight changes which I have already reverted.