|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.beadsproject.beads.data.Buffer
public class Buffer
A Buffer stores a one-dimensional buffer of floats for use as a wavetable or a window.
BufferFactory
,
Serialized FormField Summary | |
---|---|
float[] |
buf
The buffer data. |
static Buffer |
NOISE
|
static Buffer |
SAW
|
static Buffer |
SINE
|
static Buffer |
SQUARE
|
static java.util.Hashtable<java.lang.String,Buffer> |
staticBufs
A static storage area for common buffers, such as a sine wave. |
Constructor Summary | |
---|---|
Buffer(int size)
Instantiates a new buffer. |
Method Summary | |
---|---|
float |
getValueFraction(float fraction)
Returns the value of the buffer at the given fraction along its length (0 = start, 1 = end). |
float |
getValueIndex(int index)
Returns the value of the buffer at a specific index. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.util.Hashtable<java.lang.String,Buffer> staticBufs
BufferFactory
to keep track of common buffers.
public final float[] buf
public static final Buffer SINE
public static final Buffer SAW
public static final Buffer SQUARE
public static final Buffer NOISE
Constructor Detail |
---|
public Buffer(int size)
size
- the size of the buffer.Method Detail |
---|
public float getValueFraction(float fraction)
fraction
- the point along the buffer to inspect.
public float getValueIndex(int index)
index
- the index to inspect.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |