|
|
#1 |
|
Junior Member
|
Get Winamp Volume
Unfortunately there is no api that will return the current volume of winamp. I have managed to find a way (it is messy) but it does return the volume.
What you have to do is extract the volume from the winamp ini file. The only problem is that this value is not current - it is the volume that was set when the user last exited winamp (and therefore triggered the ini file to be written). What I have done is to refresh the volume when winamp is idle (i.e. not playing!) by restarting winamp and hence updating the ini file. I can then extract the volume which is now as up2date as possible. I told you this is messy but its the only way I can find to retrieve the volume. If anyone knows of a way to update the ini file in any other way other than restarting winamp, please let me know! Mr Biscuit |
|
|
|
|
|
#2 |
|
Junior Member
Join Date: Feb 2003
Posts: 7
|
are you sure about that?
I was just looking at a component that allows you to control winamp...called mp3remote and it has no problem reading/setting the volume so there must be a way to do it.
The control iz here: http://www.mindblastsoftware.com/ind...page=mp3remote It does not seem to work with winamp 3 though so you'll have to use the earlier versions. |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Feb 2003
Posts: 7
|
OOOOPSssss sorry that control does not tell u volume level
I'm sorry I made a mistake the above component does not tell u the volume level it just let's u adjust the volume. Sorry for the mistake.
|
|
|
|
|
|
#4 |
|
Senior Member
|
You can get the current volume from winamp.
I can do it in VB. I just have to find my code sheet so hold on. |
|
|
|
|
|
#5 |
|
Senior Member
|
Sub WinAMP_GetVolume(VolumeValue As Long)
If hwndWinamp = 0 Then MsgBox "WinAMP window not found yet...", vbOKOnly + vbCritical, "WinAMP Not Found" Exit Sub End If If VolumeValue < 0 Or VolumeValue > 255 Then Exit Sub End If SendMessage hwndWinamp, WM_USER, VolumeValue, WA_GETVOLUME End Sub |
|
|
|
|
|
#6 |
|
Junior Member
Join Date: Mar 2002
Posts: 18
|
jmoschetti45, that is for Winamp 2 ... how can you get the volume in Winamp3?
|
|
|
|
|
|
#7 |
|
Senior Member
|
sorry but with that I can't help you much because all I can do in 3.x is play, pause, ect. Nothing complex yet.
|
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|