public abstract class SequentialDataCommon extends java.lang.Object implements SequentialData
Modifier and Type | Field and Description |
---|---|
protected int |
maxFrames |
protected int |
numFrames |
Constructor and Description |
---|
SequentialDataCommon() |
Modifier and Type | Method and Description |
---|---|
abstract int |
getChannelsPerFrame() |
int |
getMaxFrames() |
int |
getNumFrames() |
abstract double |
getRateScaler(int index,
double synthesisRate)
Get rate to play the data.
|
int |
getReleaseBegin() |
int |
getReleaseEnd() |
int |
getSustainBegin() |
int |
getSustainEnd()
SustainEnd value is the frame index of the frame just past the end of the loop.
|
abstract double |
readDouble(int index)
Read a value from the sample independently from the internal storage format.
|
void |
setNumFrames(int numFrames)
Set number of frames of data.
|
void |
setReleaseBegin(int releaseBegin) |
void |
setReleaseEnd(int releaseEnd)
ReleaseEnd value is the frame index of the frame just past the end of the loop.
|
void |
setSustainBegin(int sustainBegin) |
void |
setSustainEnd(int sustainEnd)
SustainEnd value is the frame index of the frame just past the end of the loop.
|
abstract void |
writeDouble(int index,
double value)
Write a value at the given index.
|
public abstract void writeDouble(int index, double value)
SequentialData
writeDouble
in interface SequentialData
index
- sample index is ((frameIndex * channelsPerFrame) + channelIndex)value
- the value to be writtenpublic abstract double readDouble(int index)
SequentialData
readDouble
in interface SequentialData
index
- sample index is ((frameIndex * channelsPerFrame) + channelIndex)public abstract double getRateScaler(int index, double synthesisRate)
SequentialData
getRateScaler
in interface SequentialData
public abstract int getChannelsPerFrame()
getChannelsPerFrame
in interface SequentialData
public int getMaxFrames()
public void setNumFrames(int numFrames)
public int getNumFrames()
getNumFrames
in interface SequentialData
public int getSustainBegin()
getSustainBegin
in interface SequentialData
public int getSustainEnd()
SequentialData
getSustainEnd
in interface SequentialData
public int getReleaseBegin()
getReleaseBegin
in interface SequentialData
public int getReleaseEnd()
getReleaseEnd
in interface SequentialData
public void setSustainBegin(int sustainBegin)
public void setSustainEnd(int sustainEnd)
sustainEnd
- public void setReleaseBegin(int releaseBegin)
public void setReleaseEnd(int releaseEnd)
releaseEnd
-