|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
This interface specifies that the implementing class is capable of volume fades.
| Field Summary | |
|---|---|
static long |
DEFAULT_FADE_DURATION
Default fade duration in milliseconds. |
static int |
DEFAULT_SLEEP_INTERVAL
Default interval in milliseconds between incremental volume changes during fades. |
| Method Summary | |
|---|---|
void |
fade(double targetPercent)
Fade from the current multiplier to the target multiplier, over the default duration and with the default interval between volume changes. |
void |
fade(double targetPercent,
long duration)
Fade from the current multiplier to the target mulitplier, over the given duration and with the default interval between volume changes. |
void |
fade(double targetPercent,
long duration,
int steps)
Fade from the current multiplier to the target multiplier, over the given duration and in the given number of steps. |
double |
getFadeMultiplier()
Returns the current fade multiplier. |
boolean |
isFading()
Whether a fade is in progress |
void |
setFadeMultiplier(double multiplier)
Sets the current fade multiplier, thereby also stopping any fading. |
void |
updateVolume()
Update the volume to reflect the current fade multiplier. |
| Field Detail |
|---|
static final long DEFAULT_FADE_DURATION
static final int DEFAULT_SLEEP_INTERVAL
| Method Detail |
|---|
double getFadeMultiplier()
void setFadeMultiplier(double multiplier)
multiplier - the new fade multiplierboolean isFading()
true if a fade is in progress, false
otherwisevoid fade(double targetPercent)
targetPercent - the target volume percentage after the fade
void fade(double targetPercent,
long duration)
targetPercent - the target volume percentage after the fadeduration - the duration of the fade in milliseconds
void fade(double targetPercent,
long duration,
int steps)
targetPercent - the target volume percentage after the fadeduration - the duration of the fade in millisecondssteps - the number of volume changes during the fadevoid updateVolume()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||