|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.lang.Thread
codesimian.AllSound
public class AllSound
| Nested Class Summary | |
|---|---|
static interface |
AllSound.ByteMaker
Provides the bytes to be played through audio output. |
| Nested classes/interfaces inherited from class java.lang.Thread |
|---|
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
| Field Summary |
|---|
| Fields inherited from class java.lang.Thread |
|---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
| Method Summary | |
|---|---|
static byte[] |
doubleToByte(double[] soundData,
int bytesPerDouble,
boolean bigEndian)
double range is -1 to 1. |
static byte[] |
floatsToBytes(float[] soundData,
int bytesPerFloat)
double range is -1 to 1. |
static javax.sound.sampled.AudioFormat |
makeAudioFormat()
|
static void |
play(AllSound.ByteMaker playMeContinuously)
plays until playMeContinuously.getBytes() returns null |
static void |
play(byte[] playTheseBytes)
interruptes a ByteMaker if its playing, but will wait on other byte arrays to play |
static void |
play(byte[] playTheseBytes,
int preferredThreadPriority)
|
static void |
play(double[] convertToBytesThenPlay)
similar to play(byte[]) |
static void |
r(javax.sound.sampled.AudioFormat f)
I removed this stuff from run() so I could call it from other places |
static void |
removeByteMaker()
|
void |
run()
Thread |
static void |
silent()
erases all sound from the buffer asap and stops playing sound |
static int |
soundBufSiz()
quantity of audio samples. |
static void |
startIfNotStarted()
|
| Methods inherited from class java.lang.Thread |
|---|
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public static int soundBufSiz()
public void run()
run in interface java.lang.Runnablerun in class java.lang.Threadpublic static void play(AllSound.ByteMaker playMeContinuously)
public static void removeByteMaker()
public static void silent()
public static void play(byte[] playTheseBytes)
public static void play(byte[] playTheseBytes,
int preferredThreadPriority)
public static void play(double[] convertToBytesThenPlay)
public static javax.sound.sampled.AudioFormat makeAudioFormat()
public static byte[] doubleToByte(double[] soundData,
int bytesPerDouble,
boolean bigEndian)
public static byte[] floatsToBytes(float[] soundData,
int bytesPerFloat)
public static void r(javax.sound.sampled.AudioFormat f)
public static void startIfNotStarted()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||