It is currently December 10th, 2018, 6:36 pm

AudioLevel

Share your custom plugins and applications to enhance Rainmeter.
User avatar
jsmorley
Developer
Posts: 18445
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

AudioDevice skin

jsmorley » December 24th, 2014, 1:26 pm

It can be useful when creating or debugging a skin that uses the AudioLevel plugin to know what the default Windows Output or Input device is, and have a list of available devices with the ID number you need to set in the skin if you are monitoring a device other than the default.

This skin will give you all the information, and allow you to copy the values to the Windows Clipboard, so you can copy and paste those rather long ID numbers into your skin if needed.

Requires the latest Rainmeter beta 3.2 r2326 or later from http://rainmeter.net. Also requires Windows Vista or later.
AudioDevice_1.0.rmskin
1.jpg
2.jpg
Clipboard:
Windows Default Output Device:

Device Name: Speakers (Realtek High Definition Audio)
Device ID: {5c106e65-26b4-4d05-a9bf-b207a71e9eaa}
Device Format: 48000Hz PCM 32b 2ch
Device Status: 1

Device List:

{2d89ffff-c125-43eb-baa6-e6c484865e74} Realtek Digital Output(Optical) (Realtek High Definition Audio)
{2f760934-76a8-4ff7-9562-e7d5293e3eb7} 4 - Digital Display Audio (AMD High Definition Audio Device)
{36c86755-6d3d-499b-9aee-5eb1155a17c6} 2 - Digital Display Audio (AMD High Definition Audio Device)
{5c106e65-26b4-4d05-a9bf-b207a71e9eaa} Speakers (Realtek High Definition Au
{f9613a2a-495d-431f-92d3-4cb658f469e4} 6 -
You do not have the required permissions to view the files attached to this post.
thekey
Posts: 56
Joined: July 25th, 2013, 4:13 pm

Re: New Plugin: AudioLevel

thekey » January 6th, 2015, 1:33 pm

Since I haven't gotten a response to my post earlier:
thekey wrote:Does anyone else experience this bug and possibly know of a fix for this plugin "stalling" when using a PLAY bang? When playing music or other audio it works perfectly as intended, but if I have a skin utilize the play bang to produce a sound the visualization stalls out above the "zero" value. It happens with both my custom skin utilizing this plugin and the example one.

I noticed that it does not provide this problem when Windows Media Center is open, and the problem goes away momentarily when Windows produces a sound such as a dialog box opening.
Maybe if i add a gif recording it will make more sense toward getting a response.

Also for the record, the only thing I had done to the skin was change the bar colors and location, where left channel is on top, right channel is its "reflection" on the bottom (which i did since in all likelihood all my music/sounds will be similar on both channels). This happens with the default skin as well. Is there a workaround?
You do not have the required permissions to view the files attached to this post.
User avatar
berrypicker
Posts: 5
Joined: May 12th, 2014, 5:01 am

Re: New Plugin: AudioLevel

berrypicker » January 18th, 2015, 5:02 am

When switching audio outputs (i.e. speakers to headphones), I have to manually refresh the skin in order for the visualizer to work with the new output. Is there a workaround for this?
User avatar
dgrace
Developer
Posts: 265
Joined: June 28th, 2014, 8:32 am
Location: Tokyo, Japan

Re: New Plugin: AudioLevel

dgrace » January 19th, 2015, 3:04 am

berrypicker wrote:When switching audio outputs (i.e. speakers to headphones), I have to manually refresh the skin in order for the visualizer to work with the new output. Is there a workaround for this?
If you're physically disconnecting the cable from one or the other, the DeviceStatus should change. You can then key on this in a measure and do a [!Refresh] - the example skin does this. If both outputs are always valid and you're changing the destination output inside some other app, I'm not sure how the plugin would know to take any action - you'll need to do it manually.

dave
User avatar
.raptor
Posts: 220
Joined: April 3rd, 2013, 11:03 pm
Location: Norway

Re: New Plugin: AudioLevel

.raptor » January 27th, 2015, 6:52 pm

Love this plugin! :rosegift:

Even made me write lua :oops:
You do not have the required permissions to view the files attached to this post.
drakulaboy
Posts: 165
Joined: June 29th, 2014, 8:35 pm

Re: New Plugin: AudioLevel

drakulaboy » January 27th, 2015, 9:26 pm

.raptor nice, show some action, and can you share the lua script? :oops:
User avatar
.raptor
Posts: 220
Joined: April 3rd, 2013, 11:03 pm
Location: Norway

Re: New Plugin: AudioLevel

.raptor » January 27th, 2015, 10:48 pm

drakulaboy wrote:.raptor nice, show some action, and can you share the lua script? :oops:
Well, this is very very alpha at the moment. Currently only works with the current setup, and with Spotify. The spectrum works fine without spotify aswell, but no progress then. Also, if you edit size or anything, please remember that things might get weird... :lol:

(The sexy clock is Elegance2)

EDIT: would also love to know why the bottom part of the spectrum kinda clings together. if i play a tone at a certain frequency i can get the bars in the top end to stand out as singles, but at the bottom end its minimum 5 :confused:
(probably doesn't show the issue very well, but here is a gif anyhow)
Image
You do not have the required permissions to view the files attached to this post.
User avatar
dgrace
Developer
Posts: 265
Joined: June 28th, 2014, 8:32 am
Location: Tokyo, Japan

Re: New Plugin: AudioLevel

dgrace » January 28th, 2015, 12:22 am

.raptor wrote:EDIT: would also love to know why the bottom part of the spectrum kinda clings together. if i play a tone at a certain frequency i can get the bars in the top end to stand out as singles, but at the bottom end its minimum 5 :confused:
It's because of the way the FFT works. When you transform the signal to the frequency domain, the FFT splits up the frequencies linearly, i.e. if you sampling freq is 48khz and you did a 48-point FFT, you'd get frequency values for 0hz, 1000hz, 2000hz, 3000hz, etc. But our ears don't hear that way, we hear in log scale down to about 20hz. So what we'd like is bars for 20hz, 25hz, 33hz, 42hz, 60hz, etc. To get that kind of resolution at the bottom end, you need to use a LOT more points in the FFT. The more points you use, the more the CPU goes up, and the longer delay between what you're hearing and what you see in the meter. So it's a tradeoff. You can try ignoring the really low frequencies by setting your FreqMin value higher, or try increasing the FFTSize.

The other way to implement it would be a bank of bandpass filters on the signal, rather than an FFT. I doubt I'll get around to it though, honestly.

dave
User avatar
.raptor
Posts: 220
Joined: April 3rd, 2013, 11:03 pm
Location: Norway

Re: New Plugin: AudioLevel

.raptor » January 28th, 2015, 12:38 am

dgrace wrote: It's because of the way the FFT works. When you transform the signal to the frequency domain, the FFT splits up the frequencies linearly, i.e. if you sampling freq is 48khz and you did a 48-point FFT, you'd get frequency values for 0hz, 1000hz, 2000hz, 3000hz, etc. But our ears don't hear that way, we hear in log scale down to about 20hz. So what we'd like is bars for 20hz, 25hz, 33hz, 42hz, 60hz, etc. To get that kind of resolution at the bottom end, you need to use a LOT more points in the FFT. The more points you use, the more the CPU goes up, and the longer delay between what you're hearing and what you see in the meter. So it's a tradeoff. You can try ignoring the really low frequencies by setting your FreqMin value higher, or try increasing the FFTSize.

The other way to implement it would be a bank of bandpass filters on the signal, rather than an FFT. I doubt I'll get around to it though, honestly.

dave

Ah, had a feeling it had something to do with that. Silly ears, not tuned to my pretty desktop :(

Either way, thank you so much for this plugin, I'm having a blast!
Image
Godmode_Off
Posts: 4
Joined: January 28th, 2015, 7:34 am

Re: New Plugin: AudioLevel

Godmode_Off » January 28th, 2015, 7:57 am

Hi Dave! :)
dgrace wrote: I've tried - it appears to be a bug in Windows. See thread here:

http://social.msdn.microsoft.com/Forums/windowsdesktop/en-US/c7ba0a04-46ce-43ff-ad15-ce8932c00171/loopback-recording-causes-digital-stuttering?forum=windowspro-audiodevelopment

I've already implemented the workaround they discuss there but it's still glitchy in some cases. Unfortunately from my side all the data looks exactly the same - there's no way to know when it's happening; it all looks like valid data. Sorry, wish I had better news on that one.

dave
Sorry for hanging on to this, but I'm getting the same bug. Since it seems not solveable on a plugin level, can we talk about workarounds for skins?

One thing that works for me is constantly looping silence in the background when loading any skin that uses your plugin, like:

Code: Select all

[Rainmeter]
Update=1000
OnRefreshAction=PlayLoop "silence.wav"

...
Is there anything that speaks against it? Or is there maybe a more elegant way to implement this/get the same effect?

Regards