|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.vwp.sound.mod.modplay.player.ModuleState
public class ModuleState
This is the heart of the player code. This represents the state of the playing module
Constructor Summary | |
---|---|
ModuleState(Module module,
Mixer mixer)
Creates a ModuleState playing the supplied module and using the supplied mixer |
Method Summary | |
---|---|
int |
getDivision()
|
int |
getDivisionsInPattern()
|
Mixer |
getMixer()
|
Module |
getModule()
|
int |
getPatternsInModule()
|
int |
getPosition()
|
int |
getTick()
|
int |
getTicksInDivision()
|
void |
jump(int position,
int division,
int tick)
jump to the given module position |
boolean |
play()
play one "tick" of the module. |
void |
setBpm(int bpm)
sets the beats per minute |
void |
setPatternDelay(int delay)
causes the current division to be played delay times. |
void |
setPosition(int position)
Changes the currently playing pattern to the pattern at the given position |
void |
setSpeed(int speed)
sets the speed (a.k.a ticksInDivision) |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ModuleState(Module module, Mixer mixer)
module
- module to be playedmixer
- the mixer...Method Detail |
---|
public boolean play() throws PlayerException
PlayerException
public Module getModule()
public Mixer getMixer()
public int getPosition()
public int getPatternsInModule()
public int getDivisionsInPattern()
public int getTicksInDivision()
public int getTick()
public int getDivision()
public void setPosition(int position)
position
- the position to playpublic void setSpeed(int speed)
speed
- new speed of modulepublic void setBpm(int bpm)
bpm
- beats per minutepublic void jump(int position, int division, int tick)
position
- the pattern position to jump todivision
- the division to jump totick
- the tick to jump topublic void setPatternDelay(int delay)
delay
times. Any notes, or effects
started in this division should not be reset each time the division is played
delay
- the times to play the current division
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |