Author Topic: VUMeter Plugin  (Read 50568 times)

hiccup

  • Hero Member
  • *****
  • Posts: 9107
I lied.
So did Katie, and same as with you, we're much the better of it.
So please tell us more sweet little lies.
Last Edit: September 11, 2024, 10:34:46 PM by hiccup

BoringName

  • Sr. Member
  • ****
  • Posts: 916
So did Katie, and we're the better of it.
So please tell us more sweet little lies.

I was visualizing this when I typed that but Steely Dan works too.

boroda

  • Hero Member
  • *****
  • Posts: 5171
It's great, but wouldn't it be better to add an option to the plugin to import zipped meters (and unpack them on importing) manually?

Do you mean have a button that opens a file dialog where the user can select a downloaded zip and it will import it into the VUSkins folder, so the user doesn't have to try and find the folder themselves?

yes.

It's not a bad idea but with the differences between portable and installed and issues with file permissions associated with the installed versions, which I think you alluded to with the additional support comment, I don't think I could be arsed. I can imagine scenarios where users dump some in the Musicbee\plugin folder and import others and I don't like the idea of moving users files around to consolidate them on startup (if required).

of course, it's up to you, and this is not some problem personally for me, but i'm just using "Plugins\ASR Presets" folder as some "predefined presets repository" and "<MB AppData>\ASR Presets" as "presets working folder" in AT&RT plugin to avoid any duplication. all predefined prests are copied by plugin from the 1st folder to the 2nd one on clicking "install all" button, and additional presets can be installed manually (from any folder) by clicking "import" button.

Not surprised, only had my first experience with 11 fixing a friends laptop last week and I hated how hard it seemed to find basic info. They have just moved things around for the sake of it to justify a new version number. I usually skip every second version anyway so I'll wait for 12 although I expect that will be worse than 11 with AI rubbish.

the only good news for me is that all AI rubbish won't work (and don't work in win11, which i don't use for other reasons) in russia, anyway.

hiccup

  • Hero Member
  • *****
  • Posts: 9107
…but Steely Dan works too.
It should. It's probably the greatest pop/jazz band/duo ever.

And,  lying is such an underestimated craft.
Last Edit: September 11, 2024, 10:57:21 PM by hiccup

hiccup

  • Hero Member
  • *****
  • Posts: 9107
New version…
Damn!
Things are looking very good now.

This has certainly been worth the 7 year wait.
After me now enjoying where we're at, I'll maybe put on my critical-hat later to see if I'm able to find some more possible improvements.
But not now. It's just great!

sveakul

  • Hero Member
  • *****
  • Posts: 3264
It's set to fill the size of the panel. If you want it smaller you can just resize it. If I set it to half the panel, the other half will be blank. I can't resize the panels programatically.
But only the dual meter version "fills the size of the panel" using correct aspect ratio, as you can see below.  With the panel size unchanged, selecting "single meter" blows up the size past what the panel size is still set at--in other words, it doesn't use the panel space aspect ratio.  I can't fit the whole meter in the space then without enlarging the panel, which I don't have the space on my skin to do--the single meter image itself is not resizable.  Surely that can be fixed?

Add dual meter to panel space:



Change to "Single Meter" in menu:


phred

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 10266
There's a graphical glitch in hiccup's DejaVU Compact skin. He's of the opinion that it's a plugin issue and not a skin issue. But I don't see this on any other skin. The glitch extends beyond the frame of the meter and moves with the needle.
Original post to hiccup is here: https://getmusicbee.com/forum/index.php?topic=41696.msg227410#msg227410
Download the latest MusicBee v3.6 patch from here.
Unzip into your MusicBee directory and overwrite existing files.

----------
The FAQ
The Wiki
Custom Forum Search
Posting screenshots is here

hiccup

  • Hero Member
  • *****
  • Posts: 9107
Dadgummit
Needle action now seems so good that I don't think I care much about having any sort of peak indicators/lamps/LEDs anymore.
While it may be visually intriguing, and it could be some 'fun' having it, it's probably not much of a concrete added value, and perhaps not worth a lot of time or effort trying to get to work. Just saying.

hiccup

  • Hero Member
  • *****
  • Posts: 9107
There's a graphical glitch in hiccup's DejaVU Compact skin. He's of the opinion that it's a plugin issue and not a skin issue. But I don't see this on any other skin. The glitch extends beyond the frame of the meter and moves with the needle.
Original post to hiccup is here: https://getmusicbee.com/forum/index.php?topic=41696.msg227410#msg227410

I am now having some doubt if this may indeed be a flaw in my VU meter and not something caused by the plugin.
I was probably wrong in thinking that it was caused by the plugin.
So thanks for reporting, and I will look into it a bit better later.
After having enjoyed the bliss and glory of finally having a VU meter to begin with some more.

BoringName

  • Sr. Member
  • ****
  • Posts: 916
Surely that can be fixed?

Two ways to fix it.
1. Unlock the aspect ratio so it becomes a squished mess.
2. Add a margin and justify options so you can centre it or display it on either side if the panel.


If use skin colour is selected those black parts would be the colour of the current skin.

I don't want to do option 1 so option 2 is what I will implement at some point, unless someone can think of a better idea.

Dadgummit
Needle action now seems so good

That's good to know, I actually forgot to adjust the number of samples to average like I was going to do. All I did was adjust the sample interval back down to what I had initially before I was mucking around with the RMS values from the API peak values command.

BoringName

  • Sr. Member
  • ****
  • Posts: 916
I am now having some doubt if this may indeed be a flaw in my VU meter and not something caused by the plugin.

Technically it's not a glitch. The needle has been rotated to an angle that places it outside the bounds of the background image and foreground image. This has to occur for some skins to work properly. The issue is the panel hasn't been resized vertically to the size of the skin so it's showing the out of bounds part of the needle. The easy solution is to just drag the top of the panel down until the black area is gone.

I guess if I'm going to be adding options for margins to the sides of the meter I should also draw over the empty parts at the top so people can have some blank space at the top of the meter to make their layouts look more aesthetic.

edit: I did notice there is a visual issue if you make it quite big, A vertical line where both halves join. Not sure if that's a problem with OpenGL or if I'm out by one pixel somewhere. Due to the images getting scaled it can introduce some artifacts, especially on diagonal/curved edges. Straight edges are usually ok though, I'll check it out.
Last Edit: September 12, 2024, 04:24:24 AM by BoringName

hiccup

  • Hero Member
  • *****
  • Posts: 9107
Technically it's not a glitch. The needle has been rotated to an angle that places it outside the bounds of the background image and foreground image. This has to occur for some skins to work properly.
I just checked, and all the images (background, needle, glass) in this VU meter skin of mine have the exact same size properties. (the height being 291px)
So I was assuming that would also be the restricted displayed playground. (as AIMP also behaves)
It's kind of interesting that your plugin also displays what happens beyond that fixed area, but it probably shouldn't?
Are you aware of any VU meter skin that requires this?

BoringName

  • Sr. Member
  • ****
  • Posts: 916
It's kind of interesting that your plugin also displays what happens beyond that fixed area, but it probably shouldn't?

They all do it, the difference is they create the panel for them to be displayed in and draw the meter inside it. Anything that goes outside the bounds of the image isn't seen by the user. Because the panel it's drawn in is always the correct size.

With musicbee I insert an OpenGL element into the panel which can be made to any size by the user. So my draw space is the whole panel and I don't control it's size. When I draw the meter I have the aspect locked down, so I draw it to the width of the panel and the height is determined by the aspect ratio of the original image. If the panel height is greater than the aspect of the image, it won't fill the whole panel which exposes elements that go out of bounds.

If I didn't lock the aspect ratio, the meter would always fill the panel and you would never see out of bounds elements but then the user has to muck around trying to resize the panel to get the aspect right. I thought maintaining the aspect ratio was more important than some empty space in the draw space that I thought most people would just resize to make go away.

It shouldn't be a problem, I can just add a final step to draw over any empty space at the top of the panel with either black or the current MB skin colour and that will hide any out of bounds objects.

I figured out the problem with the vertical line when merged skins are set to a large size, it will be fixed in the next version.

sveakul

  • Hero Member
  • *****
  • Posts: 3264
Surely that can be fixed?

Two ways to fix it.
1. Unlock the aspect ratio so it becomes a squished mess.
2. Add a margin and justify options so you can centre it or display it on either side if the panel.


If use skin colour is selected those black parts would be the colour of the current skin.

I don't want to do option 1 so option 2 is what I will implement at some point, unless someone can think of a better idea.
My impression was that conforming the single meter to the existing window while maintaining the aspect ratio of the meter interface wouldn't turn it into a squished mess, but that the meter itself would be reduced in size proportionately accurate to itself--naturally resulting in black parts on either the top/bottom or sides of the meter, depending on its original dimensions, just like album art is on most player panels..  It doesn't need to FILL the space, just fit inside it and be "centered" therein, naturally resulting in some empty "black" space either on the sides or its top/bottom depending on its original dimensions.  I think this is what you have illustrated and are proposing in fix #2--if so, I'm completely on board! :)

sveakul

  • Hero Member
  • *****
  • Posts: 3264
Needle action now seems so good that I don't think I care much about having any sort of peak indicators/lamps/LEDs anymore.
While it may be visually intriguing, and it could be some 'fun' having it, it's probably not much of a concrete added value, and perhaps not worth a lot of time or effort trying to get to work. Just saying.
Three of the LVU-type LED meters;  personally I hope BoringName can add that format!  Presented larger than need be, these resize proportionally to fit whatever the AIMP Visualization window is dragged to by the user:



Last Edit: September 12, 2024, 09:32:22 AM by sveakul