We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSound,  Music Libraries › === Minim Error === === Volume is not supported.
Page Index Toggle Pages: 1
=== Minim Error === === Volume is not supported. (Read 1532 times)
=== Minim Error === === Volume is not supported.
Dec 29th, 2009, 10:33am
 
Hy,

I wanna control the volume in my project.

So i tried:

groove.setVolume(0.5);

the result was:
=== Minim Error ===
=== Volume is not supported

(and nothing happening really to the volume)


Is there an easier way? Or what did I wrong?


Greetings & thanks
nicolas



edit: it looks like the minim reference site is down. is somewhere else the reference?
Re: === Minim Error === === Volume is not supported.
Reply #1 - Jan 13th, 2010, 11:14am
 
try Code:
groove.setGain(0.5); 




cheers, * jns
Re: === Minim Error === === Volume is not supported.
Reply #2 - Jan 19th, 2010, 10:49am
 
Not all machines support setGain o setVolume, try using the hasControl() method of the Minim AudioPlayer class:
Code:

import ddf.minim.*;

AudioPlayer player;
boolean hasVolume;

void setup()
{
// [...] your stuffs

hasVolume = player.hasControl(Controller.VOLUME);
}

draw()
{
if(hasVolume){
player.setVolume(myVolume);
} else {
player.setGain(myVolume);
}
}


check the reference for methods signatures
Page Index Toggle Pages: 1