net.sf.fmj.media
Class AbstractGainControl
java.lang.Object
net.sf.fmj.media.AbstractGainControl
- All Implemented Interfaces:
- Control, GainControl
public abstract class AbstractGainControl
- extends java.lang.Object
- implements GainControl
Base class to help implement GainControl
.
- Author:
- Ken Larson
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractGainControl
public AbstractGainControl()
getControlComponent
public java.awt.Component getControlComponent()
- Specified by:
getControlComponent
in interface Control
addGainChangeListener
public void addGainChangeListener(GainChangeListener listener)
- Specified by:
addGainChangeListener
in interface GainControl
levelToDb
protected static float levelToDb(float level)
dBToLevel
protected static float dBToLevel(float db)
removeGainChangeListener
public void removeGainChangeListener(GainChangeListener listener)
- Specified by:
removeGainChangeListener
in interface GainControl
notifyListenersGainChangeEvent
protected void notifyListenersGainChangeEvent()
notifyListenersGainChangeEvent
protected void notifyListenersGainChangeEvent(GainChangeEvent event)
getMute
public boolean getMute()
- Specified by:
getMute
in interface GainControl
setMute
public void setMute(boolean mute)
- Specified by:
setMute
in interface GainControl
getSavedLevelDuringMute
protected float getSavedLevelDuringMute()
getDB
public float getDB()
- Specified by:
getDB
in interface GainControl
setDB
public float setDB(float gain)
- Specified by:
setDB
in interface GainControl